From f5f13c4f6b6fe3b4d98e349dfd7db59339803436 Mon Sep 17 00:00:00 2001 From: Michael Lando Date: Sun, 19 Feb 2017 12:35:04 +0200 Subject: [PATCH] push addional code Change-Id: Ia427bb3460cda3a896f8faced2de69eaf3807b74 Signed-off-by: Michael Lando --- openecomp-be/.gitignore | 13 + .../action-library-rest-services/pom.xml | 130 + .../openecomp/sdcrests/action/rest/Actions.java | 206 + .../rest/mapping/MapActionToActionResponseDto.java | 42 + .../sdcrests/action/rest/services/ActionsImpl.java | 1212 + .../action-library-rest-types/pom.xml | 37 + .../sdcrests/action/types/ActionResponseDto.java | 149 + .../sdcrests/action/types/ActionVersionDto.java | 38 + .../sdcrests/action/types/ListResponseWrapper.java | 70 + .../action-library-rest/pom.xml | 22 + .../application-config-rest-services/pom.xml | 62 + .../rest/ApplicationConfiguration.java | 69 + ...licationConfigEntityToApplicationConfigDto.java | 34 + ...MapConfigurationDataToConfigurationDataDto.java | 34 + .../services/ApplicationConfigurationImpl.java | 87 + .../application-config-rest-types/pom.xml | 17 + .../types/ApplicationConfigDto.java | 43 + .../types/ConfigurationDataDto.java | 50 + .../application-config-rest/pom.xml | 23 + .../onboarding-rest-war/pom.xml | 183 + .../server/filters/ActionAuthenticationFilter.java | 115 + .../server/filters/ActionAuthorizationFilter.java | 71 + .../server/filters/ActionLibraryPrivilege.java | 59 + .../server/interceptors/DefaultOutput.java | 182 + .../interceptors/EmptyOutputOutInterceptor.java | 63 + .../server/interceptors/InternalEmptyObject.java | 34 + .../listeners/OnboardingAppStartupListener.java | 43 + .../src/main/resources/keyfile.txt | 27 + .../src/main/webapp/WEB-INF/beans-services.xml | 70 + .../src/main/webapp/WEB-INF/jetty-web.xml | 8 + .../src/main/webapp/WEB-INF/web.xml | 95 + .../onboarding-rest-war/templates/markdown.hbs | 105 + .../onboarding-rest-war/templates/operation.hbs | 73 + .../onboarding-rest-war/templates/security.hbs | 88 + .../templates/strapdown.html.hbs | 11 + .../openecomp-sdc-common-rest/pom.xml | 47 + .../openecomp/sdcrests/common/RestConstants.java | 29 + .../sdcrests/common/mapping/MapErrorCodeToDto.java | 34 + .../common/mapping/MapErrorMessageToDto.java | 33 + .../sdcrests/common/types/ErrorCodeDto.java | 53 + .../sdcrests/common/types/ErrorMessageDto.java | 44 + .../sdcrests/errors/DefaultExceptionMapper.java | 163 + .../openecomp/sdcrests/mapping/MappingBase.java | 104 + .../versioning/types/VersioningAction.java | 28 + .../wrappers/GenericCollectionWrapper.java | 107 + .../sdcrests/wrappers/StringWrapperResponse.java | 42 + .../errorCodesToResponseStatusMapping.json | 9 + openecomp-be/api/openecomp-sdc-rest-webapp/pom.xml | 29 + .../sequence-rest/pom.xml | 15 + .../openecomp/sdcrests/service/rest/Service.java | 24 + .../service/rest/services/ServiceImpl.java | 26 + .../validation-rest/pom.xml | 23 + .../validation-rest-services/pom.xml | 144 + .../sdcrests/validation/rest/Validation.java | 52 + ...ionFileResponseToValidationFileResponseDto.java | 34 + .../validation/rest/services/ValidationImpl.java | 63 + .../validation-rest/validation-rest-types/pom.xml | 32 + .../types/ValidationFileResponseDto.java | 36 + .../vendor-license-rest/pom.xml | 24 + .../vendor-license-rest-services/pom.xml | 133 + .../vendorlicense/rest/EntitlementPools.java | 105 + .../sdcrests/vendorlicense/rest/FeatureGroups.java | 108 + .../vendorlicense/rest/LicenseAgreements.java | 109 + .../vendorlicense/rest/LicenseKeyGroups.java | 104 + .../vendorlicense/rest/VendorLicenseModels.java | 111 + .../MapChoiceOrOtherDtoToChoiceOrOther.java | 36 + .../MapChoiceOrOtherToChoiceOrOtherDto.java | 35 + ...lementPoolEntityToEntitlementPoolEntityDto.java | 53 + ...ementPoolRequestDtoToEntitlementPoolEntity.java | 51 + ...tureGroupDescriptorDtoToFeatureGroupEntity.java | 36 + ...tureGroupEntityToFeatureGroupDescriptorDto.java | 35 + ...ementDescriptorDtoToLicenseAgreementEntity.java | 38 + ...ementEntityToLicenseAgreementDescriptorDto.java | 38 + ...seKeyGroupEntityToLicenseKeyGroupEntityDto.java | 40 + ...eKeyGroupRequestDtoToLicenseKeyGroupEntity.java | 38 + ...pMultiChoiceOrOtherDtoToMultiChoiceOrOther.java | 36 + ...pMultiChoiceOrOtherToMultiChoiceOrOtherDto.java | 35 + ...eModelRequestDtoToVendorLicenseModelEntity.java | 36 + ...rLicenseModelToVendorLicenseModelEntityDto.java | 60 + .../rest/services/EntitlementPoolsImpl.java | 157 + .../rest/services/FeatureGroupsImpl.java | 169 + .../rest/services/LicenseAgreementsImpl.java | 186 + .../rest/services/LicenseKeyGroupsImpl.java | 159 + .../rest/services/VendorLicenseModelsImpl.java | 135 + .../vendor-license-rest-types/pom.xml | 30 + .../vendorlicense/types/ChoiceOrOtherDto.java | 75 + .../types/EntitlementPoolEntityDto.java | 48 + .../types/EntitlementPoolRequestDto.java | 144 + .../types/FeatureGroupDescriptorDto.java | 59 + .../vendorlicense/types/FeatureGroupEntityDto.java | 69 + .../vendorlicense/types/FeatureGroupModelDto.java | 66 + .../types/FeatureGroupRequestDto.java | 48 + .../types/FeatureGroupUpdateRequestDto.java | 48 + .../types/LicenseAgreementDescriptorDto.java | 74 + .../types/LicenseAgreementEntityDto.java | 51 + .../types/LicenseAgreementModelDto.java | 47 + .../types/LicenseAgreementRequestDto.java | 39 + .../types/LicenseAgreementUpdateRequestDto.java | 38 + .../types/LicenseKeyGroupEntityDto.java | 45 + .../types/LicenseKeyGroupRequestDto.java | 74 + .../vendorlicense/types/MultiChoiceOrOtherDto.java | 79 + .../types/VendorLicenseModelActionRequestDto.java | 36 + .../types/VendorLicenseModelEntityDto.java | 85 + .../types/VendorLicenseModelRequestDto.java | 62 + .../validation/ChoiceOrOtherSequenceProvider.java | 45 + .../MultiChoiceOrOtherSequenceProvider.java | 47 + .../types/validation/OtherChoiceValidation.java | 24 + .../vendor-software-products-rest/pom.xml | 23 + .../vendor-software-products-rest-services/pom.xml | 144 + .../sdcrests/vsp/rest/ComponentProcesses.java | 168 + .../sdcrests/vsp/rest/ComponentUploads.java | 104 + .../openecomp/sdcrests/vsp/rest/Components.java | 142 + .../org/openecomp/sdcrests/vsp/rest/Networks.java | 107 + .../java/org/openecomp/sdcrests/vsp/rest/Nics.java | 144 + .../org/openecomp/sdcrests/vsp/rest/Processes.java | 151 + .../sdcrests/vsp/rest/VendorSoftwareProducts.java | 193 + .../mapping/MapComponentDataToComponentDto.java | 35 + .../mapping/MapComponentEntityToComponentDto.java | 37 + .../MapComponentRequestDtoToComponentEntity.java | 38 + .../mapping/MapCompositionEntityResponseToDto.java | 47 + .../MapCompositionEntityValidationDataToDto.java | 44 + .../vsp/rest/mapping/MapMibUploadStatusToDto.java | 33 + .../rest/mapping/MapNetworkEntityToNetworkDto.java | 37 + .../MapNetworkRequestDtoToNetworkEntity.java | 37 + .../vsp/rest/mapping/MapNetworkToNetworkDto.java | 33 + .../vsp/rest/mapping/MapNicEntityToNicDto.java | 37 + .../rest/mapping/MapNicRequestDtoToNicEntity.java | 37 + .../sdcrests/vsp/rest/mapping/MapNicToNicDto.java | 35 + .../mapping/MapPackageInfoToPackageInfoDto.java | 42 + .../MapProcessEntityToProcessEntityDto.java | 36 + .../MapProcessRequestDtoToProcessEntity.java | 34 + ...ionnaireResponseToQuestionnaireResponseDto.java | 35 + ...pUploadFileResponseToUploadFileResponseDto.java | 36 + .../rest/mapping/MapValidationResponseToDto.java | 90 + ...edVendorSoftwareProductInfoToVspDetailsDto.java | 74 + .../mapping/MapVspDescriptionDtoToVspDetails.java | 56 + .../mapping/MspVspDetailsToVspCreationDto.java | 32 + .../vsp/rest/services/ComponentProcessesImpl.java | 144 + .../vsp/rest/services/ComponentUploadsImpl.java | 87 + .../sdcrests/vsp/rest/services/ComponentsImpl.java | 145 + .../sdcrests/vsp/rest/services/NetworksImpl.java | 115 + .../sdcrests/vsp/rest/services/NicsImpl.java | 140 + .../sdcrests/vsp/rest/services/ProcessesImpl.java | 89 + .../rest/services/VendorSoftwareProductsImpl.java | 228 + .../vendor-software-products-rest-types/pom.xml | 32 + .../vendorsoftwareproducts/types/ComponentDto.java | 35 + .../types/ComponentRequestDto.java | 53 + .../types/CompositionDataEntityDto.java | 24 + .../types/CompositionEntityResponseDto.java | 51 + .../types/CompositionEntityValidationDataDto.java | 65 + .../types/MibUploadStatusDto.java | 46 + .../vendorsoftwareproducts/types/NetworkDto.java | 34 + .../types/NetworkRequestDto.java | 47 + .../vendorsoftwareproducts/types/NicDto.java | 43 + .../types/NicRequestDto.java | 52 + .../types/PackageInfoDto.java | 124 + .../types/ProcessEntityDto.java | 42 + .../types/ProcessRequestDto.java | 47 + .../types/QuestionnaireResponseDto.java | 42 + .../types/QuestionnaireValidationResultDto.java | 42 + .../types/TranslatedFileDataDto.java | 97 + .../types/UploadFileResponseDto.java | 63 + .../types/ValidationResponseDto.java | 77 + .../types/VendorSoftwareProductAction.java | 29 + .../VersionSoftwareProductActionRequestDto.java | 33 + .../types/VspCreationDto.java | 33 + .../types/VspDescriptionDto.java | 115 + .../types/VspDetailsDto.java | 97 + .../types/validation/CustomJsonValidator.java | 40 + .../types/validation/IsValidJson.java | 77 + openecomp-be/api/pom.xml | 22 + .../backend/openecomp-sdc-action-manager/pom.xml | 87 + .../org/openecomp/sdc/action/ActionManager.java | 66 + .../sdc/action/impl/ActionManagerImpl.java | 1217 + .../java/org/openecomp/sdc/action/ActionTest.java | 1207 + .../src/test/resources/test_artifact_file.txt | 2 + .../test/resources/test_artifact_update_file.txt | 2 + .../test-output/Default suite/Default test.html | 324 + .../test-output/Default suite/Default test.xml | 53 + .../test-output/Default suite/testng-failed.xml | 16 + .../test-output/bullet_point.png | Bin 0 -> 356 bytes .../test-output/collapseall.gif | Bin 0 -> 157 bytes .../test-output/emailable-report.html | 2 + .../test-output/failed.png | Bin 0 -> 977 bytes .../test-output/index.html | 1231 + .../test-output/jquery-1.7.1.min.js | 4 + .../TEST-com.amdocs.asdc.action.ActionTest.xml | 53 + .../test-output/navigator-bullet.png | Bin 0 -> 352 bytes .../old/Default suite/Default test.properties | 1 + .../test-output/old/Default suite/classes.html | 228 + .../test-output/old/Default suite/groups.html | 3 + .../test-output/old/Default suite/index.html | 6 + .../test-output/old/Default suite/main.html | 2 + .../old/Default suite/methods-alphabetical.html | 104 + .../old/Default suite/methods-not-run.html | 2 + .../test-output/old/Default suite/methods.html | 104 + .../old/Default suite/reporter-output.html | 1 + .../test-output/old/Default suite/testng.xml.html | 1 + .../test-output/old/Default suite/toc.html | 30 + .../test-output/old/index.html | 9 + .../test-output/passed.png | Bin 0 -> 1019 bytes .../test-output/skipped.png | Bin 0 -> 967 bytes .../test-output/testng-failed.xml | 16 + .../test-output/testng-reports.css | 309 + .../test-output/testng-reports.js | 122 + .../test-output/testng-results.xml | 223 + .../test-output/testng.css | 9 + .../pom.xml | 55 + .../ApplicationConfigManager.java | 35 + .../impl/ApplicationConfigManagerImpl.java | 63 + .../ApplicationConfigManagerTest.java | 64 + .../openecomp-sdc-validation-manager/pom.xml | 78 + .../sdc/validation/UploadValidationManager.java | 34 + .../validation/errors/ValidationErrorCodes.java | 26 + .../errors/ValidationInvalidErrorBuilder.java | 75 + .../impl/UploadValidationManagerImpl.java | 161 + .../validation/types/ValidationFileResponse.java | 36 + .../sdc/validation/types/ValidationFileStatus.java | 26 + .../openecomp-sdc-vendor-license-manager/pom.xml | 103 + .../sdc/vendorlicense/VendorLicenseManager.java | 115 + .../impl/VendorLicenseManagerImpl.java | 558 + .../sdc/vendorlicense/ArtifactTestUtils.java | 252 + .../sdc/vendorlicense/EntitlementPoolTest.java | 275 + .../sdc/vendorlicense/FeatureGroupTest.java | 202 + .../sdc/vendorlicense/LicenseAgreementTest.java | 218 + .../sdc/vendorlicense/LicenseKeyGroupTest.java | 162 + .../sdc/vendorlicense/VendorLicenseModelTest.java | 402 + .../impl/VendorLicenseArtifactsServiceTest.java | 141 + .../pom.xml | 147 + .../VendorSoftwareProductManager.java | 173 + ...rNonFinalVendorSoftwareProductErrorBuilder.java | 59 + .../errors/FileCreationErrorBuilder.java | 56 + .../errors/MibUploadErrorBuilder.java | 59 + .../errors/PackageInvalidErrorBuilder.java | 60 + .../errors/PackageNotFoundErrorBuilder.java | 71 + .../TranslationFileCreationErrorBuilder.java | 60 + .../errors/UploadInvalidErrorBuilder.java | 82 + .../errors/VendorSoftwareProductErrorCodes.java | 48 + .../VendorSoftwareProductInvalidErrorBuilder.java | 60 + .../VendorSoftwareProductNotFoundErrorBuilder.java | 54 + .../impl/VendorSoftwareProductManagerImpl.java | 1567 + .../services/CompositionDataExtractor.java | 386 + .../services/CompositionEntityDataManager.java | 257 + .../services/SchemaGenerator.java | 70 + .../services/SchemaGeneratorConfig.java | 184 + .../types/CompositionEntityResponse.java | 53 + .../types/CompositionEntityValidationData.java | 122 + .../types/ExtractCompositionDataContext.java | 204 + .../vendorsoftwareproduct/types/LicensingData.java | 45 + .../types/QuestionnaireResponse.java | 42 + .../types/QuestionnaireValidationResult.java | 39 + .../types/UploadFileResponse.java | 143 + .../types/UploadFileStatus.java | 26 + .../types/UploadFileStructure.java | 40 + .../types/ValidationResponse.java | 157 + .../types/VersionedVendorSoftwareProductInfo.java | 53 + .../ComponentCompositionSchemaInput.java | 43 + .../ComponentQuestionnaireSchemaInput.java | 42 + .../types/schemagenerator/MibUploadStatus.java | 51 + .../NetworkCompositionSchemaInput.java | 43 + .../schemagenerator/NicCompositionSchemaInput.java | 55 + .../schemagenerator/SchemaTemplateContext.java | 26 + .../types/schemagenerator/SchemaTemplateInput.java | 25 + .../util/CompilationUtil.java | 126 + .../util/VendorSoftwareProductUtils.java | 254 + .../ComponentProcessesTest.java | 46 + .../sdc/vendorsoftwareproduct/ComponentsTest.java | 329 + .../ComponentsUploadTest.java | 159 + .../sdc/vendorsoftwareproduct/NetworksTest.java | 292 + .../sdc/vendorsoftwareproduct/NicsTest.java | 346 + .../sdc/vendorsoftwareproduct/ProcessesTest.java | 473 + .../sdc/vendorsoftwareproduct/VSPCommon.java | 78 + .../sdc/vendorsoftwareproduct/VSPFullTest.java | 194 + .../VendorSoftwareProductManagerTest.java | 672 + .../services/CompositionDataExtractorTest.java | 280 + .../services/CompositionEntityDataManagerTest.java | 141 + .../services/QuestionnaireSchemaTest.java | 64 + .../services/QuestionnaireValidatorTest.java | 74 + .../services/SchemaGeneratorTest.java | 244 + .../tree/HeatTreeManagerTest.java | 102 + .../vendorsoftwareproduct/tree/TreeBaseTest.java | 33 + .../vendorsoftwareproduct/tree/UploadFileTest.java | 90 + .../HeatCleanup/HeatCleanupOnNewUploadTest.java | 167 + .../validation/UploadFileValidationTest.java | 199 + .../test/resources/emptyComposition/MANIFEST.json | 11 + .../resources/emptyComposition/ep-jsa_net.yaml | 21 + .../componentsWithPort/ComponentsWithPortST.yaml | 428 + .../fullComposition/MainServiceTemplate.yaml | 473 + .../networks/MainServiceTemplate.yaml | 829 + .../onlyComponents/OnlyComponentsST.yaml | 350 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 235 + .../substitution/MainServiceTemplate.yaml | 139 + .../substitution/nested1ServiceTemplate.yaml | 241 + .../substitution/nested2ServiceTemplate.yaml | 135 + ...stractSubstituteGlobalTypesServiceTemplate.yaml | 47 + .../CinderVolumeGlobalTypesServiceTemplate.yaml | 176 + .../CommonGlobalTypesServiceTemplate.yaml | 213 + ...ntrailNetworkRuleGlobalTypeServiceTemplate.yaml | 117 + ...ailVirtualNetworkGlobalTypeServiceTemplate.yaml | 71 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 93 + .../NativeTypesServiceTemplateServiceTemplate.yaml | 194 + .../NeutronNetGlobalTypesServiceTemplate.yaml | 97 + .../NeutronPortGlobalTypesServiceTemplate.yaml | 151 + ...ronSecurityRulesGlobalTypesServiceTemplate.yaml | 116 + .../NovaServerGlobalTypesServiceTemplate.yaml | 249 + .../test/resources/fullComposition/MANIFEST.json | 17 + .../fullComposition/hot-mog-0108-bs1271.env | 60 + .../fullComposition/hot-mog-0108-bs1271.yml | 733 + .../src/test/resources/invalidTypes/MANIFEST.json | 42 + .../resources/invalidTypes/MMSC_Capacity_Line.yml | 3223 ++ .../invalidTypes/MMSC_Capacity_Line_1.env | 111 + .../test/resources/invalidTypes/SG_ECA_MGMT.yaml | 76 + .../src/test/resources/invalidTypes/cmaui.env | 17 + .../src/test/resources/invalidTypes/cmaui.yml | 202 + .../src/test/resources/invalidTypes/eca_oam.env | 20 + .../src/test/resources/invalidTypes/eca_oam.yaml | 383 + .../src/test/resources/invalidTypes/eca_oam_2.yaml | 383 + .../test/resources/invalidTypes/sg_eca_mgmt.env | 7 + .../src/test/resources/legalUpload/MANIFEST.json | 20 + .../src/test/resources/legalUpload/create_stack.sh | 1 + .../legalUpload/vmme_small_create_fsb.env | 8 + .../legalUpload/vmme_small_create_fsb.yml | 54 + .../src/test/resources/legalUpload2/MANIFEST.json | 29 + .../test/resources/legalUpload2/create_stack.sh | 1 + .../src/test/resources/legalUpload2/vmme_small.env | 97 + .../src/test/resources/legalUpload2/vmme_small.yml | 661 + .../legalUpload2/vmme_small_create_fsb.env | 8 + .../legalUpload2/vmme_small_create_fsb.yml | 54 + .../src/test/resources/missingYml/MANIFEST.json | 20 + .../src/test/resources/missingYml/create_stack.sh | 1 + .../resources/missingYml/vmme_small_create_fsb.env | 8 + .../src/test/resources/nimbus/HEAT.meta | 215 + .../src/test/resources/nimbus/MANIFEST.json | 113 + .../src/test/resources/nimbus/cloud-nimbus.sh | 12 + .../nimbus/hot-nimbus-oam-volumes_v1.0.env | 6 + .../nimbus/hot-nimbus-oam-volumes_v1.0.yaml | 45 + .../test/resources/nimbus/hot-nimbus-oam_v1.0.env | 18 + .../test/resources/nimbus/hot-nimbus-oam_v1.0.yaml | 109 + .../nimbus/hot-nimbus-pcm-volumes_v1.0.env | 4 + .../nimbus/hot-nimbus-pcm-volumes_v1.0.yaml | 28 + .../test/resources/nimbus/hot-nimbus-pcm_v1.0.env | 16 + .../test/resources/nimbus/hot-nimbus-pcm_v1.0.yaml | 80 + .../test/resources/nimbus/hot-nimbus-ppd_v1.0.yaml | 286 + .../test/resources/nimbus/hot-nimbus-ppd_v1.1.env | 35 + .../test/resources/nimbus/hot-nimbus-pps_v1.0.env | 11 + .../test/resources/nimbus/hot-nimbus-pps_v1.0.yaml | 121 + .../test/resources/nimbus/hot-nimbus-psm_v1.0.env | 10 + .../test/resources/nimbus/hot-nimbus-psm_v1.0.yaml | 199 + .../nimbus/hot-nimbus-swift-container_v1.0.env | 3 + .../nimbus/hot-nimbus-swift-container_v1.0.yaml | 30 + .../src/test/resources/nimbus/mount_iso_script.sh | 34 + .../src/test/resources/nimbus/nested-oam_v1.0.yaml | 156 + .../src/test/resources/nimbus/nested-pcm_v1.0.yaml | 150 + .../src/test/resources/nimbus/nested-ppd_v1.0.yaml | 333 + .../src/test/resources/nimbus/nested-pps_v1.0.yaml | 99 + .../src/test/resources/nimbus/nested-psm_v1.0.yaml | 99 + .../src/test/resources/nimbus/nimbus-ethernet | 5 + .../src/test/resources/nimbus/nimbus-ethernet-gw | 6 + .../src/test/resources/notZipFile | 1 + .../resources/quesionnaire/invalidComponent.json | 34 + .../test/resources/quesionnaire/invalidNic.json | 36 + .../resources/quesionnaire/validComponent.json | 34 + .../src/test/resources/quesionnaire/validNic.json | 30 + .../input/heat_missing_from_manifast.yaml | 250 + .../tree/missing_manifest/input/mainValid.yaml | 250 + .../tree/missing_manifest/input/validHeat.yaml | 250 + .../tree/nested_resource_group/MANIFEST.json | 17 + .../resources/tree/nested_resource_group/addOn.yml | 31 + .../tree/nested_resource_group/nested.yml | 56 + .../resources/tree/nested_volume/MANIFEST.json | 16 + .../resources/tree/nested_volume/base_mobt.yaml | 26 + .../hot_mobt_volume_attach_nested.yaml | 28 + .../resources/tree/valid_tree/input/MANIFEST.json | 39 + .../input/heat_missing_from_manifast.yaml | 250 + .../resources/tree/valid_tree/input/mainValid.yaml | 250 + .../resources/tree/valid_tree/input/validHeat.yaml | 250 + .../test/resources/validation/zips/emptyZip.zip | Bin 0 -> 22 bytes .../validation/zips/missingManifestInZip.zip | Bin 0 -> 397 bytes .../validation/zips/various/710-ResourceGroup.zip | Bin 0 -> 2811 bytes .../resources/validation/zips/various/MMSC.zip | Bin 0 -> 21273 bytes .../validation/zips/various/MNS OAM FW.zip | Bin 0 -> 9111 bytes .../resources/validation/zips/various/VOTA.zip | Bin 0 -> 41421 bytes .../zips/various/base_module_mns_oam.zip | Bin 0 -> 11092 bytes .../validation/zips/various/cmd-frwl-v302.zip | Bin 0 -> 8239 bytes .../validation/zips/various/noError/GWv12.zip | Bin 0 -> 9312 bytes .../zips/various/noError/MNS OAM FW fix.zip | Bin 0 -> 9199 bytes .../various/noError/base_module_mns_oam_fixed.zip | Bin 0 -> 11073 bytes .../zips/various/noError/cmd-frwl-v302.zip | Bin 0 -> 8264 bytes .../zips/various/noError/vDBE_fix_with_warr.zip | Bin 0 -> 2752 bytes .../validation/zips/various/noError/vDNS.zip | Bin 0 -> 3499 bytes .../validation/zips/various/segw_heat_c3-base.zip | Bin 0 -> 4026 bytes .../resources/validation/zips/various/vDBE.zip | Bin 0 -> 2750 bytes .../resources/validation/zips/various/vDNS.zip | Bin 0 -> 3480 bytes .../validation/zips/various/vDNS_21_8.zip | Bin 0 -> 3480 bytes .../resources/validation/zips/various/vProb.zip | Bin 0 -> 33429 bytes .../validation/zips/various/vProbe_FE_081816.zip | Bin 0 -> 33443 bytes .../zips/various/vid_test_pcrf_base_template.zip | Bin 0 -> 4223 bytes .../validation/zips/zipFileWithFolder.zip | Bin 0 -> 290 bytes .../resources/vspmanager/zips/emptyComposition.zip | Bin 0 -> 722 bytes .../test/resources/vspmanager/zips/emptyZip.zip | Bin 0 -> 22 bytes .../resources/vspmanager/zips/fullComposition.zip | Bin 0 -> 3905 bytes .../resources/vspmanager/zips/invalidTypes.zip | Bin 0 -> 16465 bytes .../test/resources/vspmanager/zips/legalUpload.zip | Bin 0 -> 1315 bytes .../resources/vspmanager/zips/legalUpload2.zip | Bin 0 -> 4622 bytes .../test/resources/vspmanager/zips/missingYml.zip | Bin 0 -> 838 bytes .../src/test/resources/vspmanager/zips/nimbus.zip | Bin 0 -> 17485 bytes .../src/test/resources/vspmanager/zips/vDNS.zip | Bin 0 -> 3480 bytes .../resources/vspmanager/zips/withoutManifest.zip | Bin 0 -> 970 bytes .../vspmanager/zips/zipFileWithFolder.zip | Bin 0 -> 290 bytes .../src/test/resources/withNetwork/MANIFEST.json | 21 + .../resources/withNetwork/hot-mog-0108-bs1271.env | 60 + .../resources/withNetwork/hot-mog-0108-bs1271.yml | 733 + .../src/test/resources/withNetwork/network.yml | 733 + .../test/resources/withNetwork/zip/withNetwork.zip | Bin 0 -> 6442 bytes .../test/resources/withoutManifest/create_stack.sh | 1 + .../withoutManifest/vmme_small_create_fsb.env | 8 + .../withoutManifest/vmme_small_create_fsb.yml | 54 + openecomp-be/backend/pom.xml | 26 + openecomp-be/configuration/pom.xml | 15 + openecomp-be/lib/openecomp-common-lib/pom.xml | 46 + .../sdc/common/errors/BaseErrorBuilder.java | 33 + .../openecomp/sdc/common/errors/CoreException.java | 39 + .../openecomp/sdc/common/errors/ErrorCategory.java | 64 + .../org/openecomp/sdc/common/errors/ErrorCode.java | 105 + .../sdc/common/errors/ErrorCodeAndMessage.java | 88 + .../sdc/common/errors/GeneralErrorBuilder.java | 53 + .../sdc/common/errors/JsonMappingErrorBuilder.java | 53 + .../sdc/common/errors/ValidationErrorBuilder.java | 68 + .../org/openecomp/sdc/common/utils/AsdcCommon.java | 31 + .../openecomp-config-lib/pom.xml | 48 + .../applicationconfig/ApplicationConfig.java | 35 + .../ApplicationConfigFactory.java | 31 + .../dao/ApplicationConfigDao.java | 33 + .../dao/ApplicationConfigDaoFactory.java | 32 + .../impl/ApplicationConfigDaoCassandraImpl.java | 115 + .../dao/impl/ApplicationConfigDaoFactoryImpl.java | 33 + .../dao/type/ApplicationConfigEntity.java | 79 + .../impl/ApplicationConfigFactoryImpl.java | 34 + .../impl/ApplicationConfigImpl.java | 74 + .../applicationconfig/type/ConfigurationData.java | 48 + .../src/main/resources/factoryConfiguration.json | 4 + .../src/main/resources/logback.xml | 90 + .../dao/ApplicationConfigImplDaoTest.java | 88 + .../test/resources/questionnaire/testTemplate.txt | 12 + .../openecomp-facade-api/pom.xml | 31 + .../core/factory/api/AbstractFactory.java | 81 + .../core/factory/impl/AbstractFactoryBase.java | 212 + .../openecomp-facade-core/pom.xml | 36 + .../core/factory/AbstractContextFactory.java | 27 + .../core/factory/FactoriesConfigImpl.java | 61 + .../org/openecomp/core/factory/FactoryConfig.java | 46 + .../core/factory/api/AbstractComponentFactory.java | 105 + .../core/factory/api/FactoriesConfiguration.java | 29 + .../openecomp-facade-lib/pom.xml | 34 + .../openecomp-nosqldb-api/pom.xml | 40 + .../main/java/org/openecomp/core/dao/BaseDao.java | 36 + .../org/openecomp/core/dao/UniqueValueDao.java | 28 + .../openecomp/core/dao/UniqueValueDaoFactory.java | 30 + .../core/dao/types/UniqueValueEntity.java | 58 + .../org/openecomp/core/nosqldb/api/NoSqlDb.java | 37 + .../core/nosqldb/factory/NoSqlDbFactory.java | 34 + .../org/openecomp/core/util/UniqueValueUtil.java | 127 + .../src/main/resources/cassandraStatements.json | 6 + .../src/main/resources/factoryConfiguration.json | 4 + .../openecomp-nosqldb-core/pom.xml | 60 + .../openecomp/core/dao/impl/CassandraBaseDao.java | 50 + .../core/dao/impl/UniqueValueCassandraDaoImpl.java | 65 + .../core/dao/impl/UniqueValueDaoFactoryImpl.java | 33 + .../cassandra/CassandraNoSqlDbFactoryImpl.java | 43 + .../impl/cassandra/CassandraNoSqlDbImpl.java | 104 + .../impl/cassandra/CassandraSessionFactory.java | 124 + .../core/nosqldb/util/CassandraUtils.java | 92 + .../core/nosqldb/util/ConfigurationManager.java | 234 + .../src/main/resources/configuration.yaml | 253 + .../org/openecomp/core/nosqldb/NoSqlDbTest.java | 48 + .../core/utilities/Yaml/YamlUtilTest.java | 47 + .../core/utilities/json/JsonUtilTest.java | 13 + .../src/test/java/testobjects/yaml/InnerP.java | 25 + .../src/test/java/testobjects/yaml/Parameter.java | 68 + .../src/test/java/testobjects/yaml/YamlFile.java | 37 + .../openecomp-nosqldb-lib/pom.xml | 36 + .../openecomp-utilities-lib/pom.xml | 82 + .../openecomp/core/utilities/CommonMethods.java | 555 + .../core/utilities/file/FileContentHandler.java | 88 + .../openecomp/core/utilities/file/FileUtils.java | 286 + .../utilities/json/JsonSchemaDataGenerator.java | 185 + .../openecomp/core/utilities/json/JsonUtil.java | 187 + .../openecomp/core/utilities/yaml/YamlUtil.java | 289 + .../json/JsonSchemaDataGeneratorTest.java | 50 + .../core/utilities/json/JsonUtilTest.java | 40 + .../src/test/resources/jsonUtil/json/a.json | 12 + .../test/resources/jsonUtil/json/a_invalid.json | 13 + .../resources/jsonUtil/json_schema/aSchema.json | 60 + .../resources/jsonUtil/json_schema/nicSchema.json | 118 + .../json_schema/schemaWithInvalidDefault.json | 67 + .../json_schema/schemaWithRefsAndDefaults.json | 71 + openecomp-be/lib/openecomp-core-lib/pom.xml | 23 + openecomp-be/lib/openecomp-heat-lib/pom.xml | 59 + .../heat/datatypes/DefinedHeatParameterTypes.java | 110 + .../openecomp/sdc/heat/datatypes/HeatBoolean.java | 96 + .../sdc/heat/datatypes/manifest/FileData.java | 107 + .../heat/datatypes/manifest/ManifestContent.java | 63 + .../sdc/heat/datatypes/manifest/ManifestFile.java | 43 + .../sdc/heat/datatypes/model/Constraint.java | 78 + .../sdc/heat/datatypes/model/Environment.java | 35 + .../sdc/heat/datatypes/model/GroupTypeValues.java | 49 + .../datatypes/model/HeatOrchestrationTemplate.java | 90 + .../heat/datatypes/model/HeatPseudoParameters.java | 61 + .../heat/datatypes/model/HeatResourcesTypes.java | 206 + .../openecomp/sdc/heat/datatypes/model/Output.java | 42 + .../sdc/heat/datatypes/model/Parameter.java | 90 + .../sdc/heat/datatypes/model/ParameterGroup.java | 53 + .../sdc/heat/datatypes/model/ParameterType.java | 42 + .../sdc/heat/datatypes/model/PolicyTypes.java | 61 + .../datatypes/model/PropertiesMapKeyTypes.java | 42 + .../sdc/heat/datatypes/model/Resource.java | 92 + .../model/ResourceReferenceFunctions.java | 44 + .../model/ResourceTypeToMessageString.java | 55 + .../sdc/heat/datatypes/structure/Artifact.java | 105 + .../datatypes/structure/HeatStructureTree.java | 467 + .../structure/ValidationStructureList.java | 40 + .../openecomp/sdc/heat/services/ErrorCodes.java | 25 + .../openecomp/sdc/heat/services/HeatConstants.java | 34 + .../sdc/heat/services/HeatStructureUtil.java | 261 + .../sdc/heat/services/manifest/ManifestUtil.java | 176 + .../sdc/heat/services/tree/HeatTreeManager.java | 298 + .../heat/services/tree/HeatTreeManagerUtil.java | 43 + .../sdc/heat/datatypes/model/EnvironmentTest.java | 38 + .../model/HeatOrchestrationTemplateTest.java | 122 + .../src/test/resources/mock/model/envSettings.env | 36 + .../src/test/resources/mock/model/testHeat.yml | 524 + .../openecomp-sdc-action-api/pom.xml | 45 + .../org/openecomp/sdc/action/ActionConstants.java | 104 + .../sdc/action/dao/ActionArtifactDao.java | 34 + .../sdc/action/dao/ActionArtifactDaoFactory.java | 31 + .../org/openecomp/sdc/action/dao/ActionDao.java | 51 + .../openecomp/sdc/action/dao/ActionDaoFactory.java | 31 + .../sdc/action/dao/types/ActionArtifactEntity.java | 89 + .../sdc/action/dao/types/ActionEntity.java | 224 + .../sdc/action/dao/types/EcompComponentEntity.java | 73 + .../sdc/action/errors/ActionErrorConstants.java | 136 + .../sdc/action/errors/ActionException.java | 52 + .../sdc/action/errors/ActionExceptionMapper.java | 114 + .../sdc/action/errors/ActionExceptionResponse.java | 66 + .../sdc/action/logging/CategoryLogLevel.java | 29 + .../openecomp/sdc/action/logging/StatusCode.java | 26 + .../org/openecomp/sdc/action/types/Action.java | 255 + .../openecomp/sdc/action/types/ActionArtifact.java | 139 + .../sdc/action/types/ActionArtifactProtection.java | 26 + .../sdc/action/types/ActionLogResponseCode.java | 90 + .../openecomp/sdc/action/types/ActionRequest.java | 40 + .../openecomp/sdc/action/types/ActionStatus.java | 28 + .../sdc/action/types/ActionSubOperation.java | 59 + .../openecomp/sdc/action/types/EcompComponent.java | 104 + .../org/openecomp/sdc/action/util/ActionUtil.java | 372 + .../src/main/resources/factoryConfiguration.json | 4 + .../openecomp-sdc-action-core/pom.xml | 37 + .../dao/impl/ActionArtifactDaoFactoryImpl.java | 33 + .../sdc/action/dao/impl/ActionArtifactDaoImpl.java | 150 + .../sdc/action/dao/impl/ActionDaoFactoryImpl.java | 33 + .../sdc/action/dao/impl/ActionDaoImpl.java | 583 + openecomp-be/lib/openecomp-sdc-action-lib/pom.xml | 25 + .../lib/openecomp-sdc-datatypes-lib/pom.xml | 38 + .../openecomp/sdc/datatypes/error/ErrorLevel.java | 25 + .../sdc/datatypes/error/ErrorMessage.java | 91 + .../openecomp/sdc/datatypes/model/AsdcModel.java | 24 + .../model/heat/ForbiddenHeatResourceTypes.java | 56 + .../openecomp-sdc-enrichment-api/pom.xml | 46 + .../EnrichmentArtifactsServiceFactory.java | 33 + .../core/enrichment/EnrichmentConstants.java | 29 + .../core/enrichment/api/EnrichmentManager.java | 43 + .../EnrichmentArtifactsService.java | 29 + .../factory/EnrichmentManagerFactory.java | 32 + .../core/enrichment/types/CeilometerInfo.java | 71 + .../enrichment/types/ComponentArtifactType.java | 34 + .../enrichment/types/ComponentCeilometerInfo.java | 36 + .../core/enrichment/types/ComponentMibInfo.java | 45 + .../core/enrichment/types/EntityInfo.java | 27 + .../openecomp/core/enrichment/types/MibInfo.java | 45 + .../src/main/resources/factoryConfiguration.json | 4 + .../openecomp-sdc-enrichment-core/pom.xml | 90 + .../EnrichmentArtifactsServiceFactoryImpl.java | 34 + .../EnrichmentArtifactsServiceImpl.java | 61 + .../impl/EnrichmentManagerFactoryImpl.java | 34 + .../sdc/enrichment/impl/EnrichmentManagerImpl.java | 84 + .../enrichment/impl/EnrichmentManagerImplTest.java | 245 + .../all/OnlyComponentsST.yaml | 350 + .../all/OnlyComponentsST_01.yaml | 350 + .../extractServiceComposition/all/VariouseST.yaml | 363 + .../all/expectedOutput/OnlyComponentsST.yaml | 550 + .../all/expectedOutput/OnlyComponentsST_01.yaml | 550 + .../all/expectedOutput/VariouseST.yaml | 363 + .../onlyComponents/OnlyComponentsST.yaml | 350 + .../onlyComponents/OnlyComponentsST_01.yaml | 350 + .../expectedOutput/OnlyComponentsST.yaml | 550 + .../expectedOutput/OnlyComponentsST_01.yaml | 550 + ...stractSubstituteGlobalTypesServiceTemplate.yaml | 47 + .../CinderVolumeGlobalTypesServiceTemplate.yaml | 176 + .../CommonGlobalTypesServiceTemplate.yaml | 213 + ...ntrailNetworkRuleGlobalTypeServiceTemplate.yaml | 117 + ...ailVirtualNetworkGlobalTypeServiceTemplate.yaml | 71 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 93 + .../NativeTypesServiceTemplateServiceTemplate.yaml | 194 + .../NeutronNetGlobalTypesServiceTemplate.yaml | 97 + .../NeutronPortGlobalTypesServiceTemplate.yaml | 151 + ...ronSecurityRulesGlobalTypesServiceTemplate.yaml | 116 + .../NovaServerGlobalTypesServiceTemplate.yaml | 249 + .../openecomp-sdc-enrichment-impl/pom.xml | 102 + .../openecomp/sdc/enrichment/EnrichmentInfo.java | 63 + .../enrichment/factory/EnricherHandlerFactory.java | 32 + .../impl/EnricherHandlerFactoryImpl.java | 33 + .../sdc/enrichment/impl/EnricherHandlerImpl.java | 89 + .../artifact/ExternalArtifactEnricher.java | 106 + .../enrichment/impl/tosca/CeilometerEnricher.java | 112 + .../sdc/enrichment/impl/tosca/ComponentInfo.java | 47 + .../sdc/enrichment/impl/tosca/SnmpEnricher.java | 38 + .../sdc/enrichment/impl/tosca/ToscaEnricher.java | 73 + .../openecomp/sdc/enrichment/inter/Enricher.java | 45 + .../sdc/enrichment/inter/EnricherHandler.java | 41 + .../src/main/resources/factoryConfiguration.json | 3 + .../lib/openecomp-sdc-enrichment-lib/pom.xml | 41 + .../openecomp-sdc-model-api/pom.xml | 49 + .../core/model/dao/EnrichedServiceArtifactDao.java | 28 + .../dao/EnrichedServiceArtifactDaoFactory.java | 32 + .../core/model/dao/EnrichedServiceModelDao.java | 42 + .../model/dao/EnrichedServiceModelDaoFactory.java | 32 + .../core/model/dao/EnrichedServiceTemplateDao.java | 26 + .../dao/EnrichedServiceTemplateDaoFactory.java | 32 + .../core/model/dao/ServiceArtifactDao.java | 44 + .../core/model/dao/ServiceArtifactDaoFactory.java | 32 + .../core/model/dao/ServiceArtifactDaoInter.java | 44 + .../openecomp/core/model/dao/ServiceModelDao.java | 40 + .../core/model/dao/ServiceModelDaoFactory.java | 31 + .../core/model/dao/ServiceTemplateDao.java | 44 + .../core/model/dao/ServiceTemplateDaoFactory.java | 32 + .../core/model/dao/ServiceTemplateDaoInter.java | 46 + .../model/types/EnrichedServiceArtifactEntity.java | 136 + .../model/types/EnrichedServiceTemplateEntity.java | 154 + .../core/model/types/ServiceArtifact.java | 29 + .../core/model/types/ServiceArtifactEntity.java | 136 + .../openecomp/core/model/types/ServiceElement.java | 77 + .../core/model/types/ServiceElementEntity.java | 31 + .../core/model/types/ServiceTemplate.java | 38 + .../core/model/types/ServiceTemplateEntity.java | 154 + .../src/main/resources/factoryConfiguration.json | 8 + .../openecomp-sdc-model-core/pom.xml | 65 + .../sdc/model/impl/AbstractServiceModelDao.java | 191 + .../openecomp-sdc-model-impl/pom.xml | 61 + ...chedServiceArtifactDaoCassandraFactoryImpl.java | 36 + .../EnrichedServiceArtifactDaoCassandraImpl.java | 137 + .../impl/EnrichedServiceModelDaoFactoryImpl.java | 34 + .../model/impl/EnrichedServiceModelDaoImpl.java | 44 + ...chedServiceTemplateDaoCassandraFactoryImpl.java | 36 + .../EnrichedServiceTemplateDaoCassandraImpl.java | 147 + .../ServiceArtifactDaoCassandraFactoryImpl.java | 34 + .../impl/ServiceArtifactDaoCassandraImpl.java | 139 + .../sdc/model/impl/ServiceModelDaoFactoryImpl.java | 34 + .../sdc/model/impl/ServiceModelDaoImpl.java | 38 + .../ServiceTemplateDaoCassandraFactoryImpl.java | 34 + .../impl/ServiceTemplateDaoCassandraImpl.java | 145 + openecomp-be/lib/openecomp-sdc-model-lib/pom.xml | 43 + .../openecomp-sdc-translator-api/pom.xml | 43 + .../core/translator/api/HeatToToscaTranslator.java | 48 + .../translator/datatypes/TranslatorOutput.java | 48 + .../factory/HeatToToscaTranslatorFactory.java | 33 + .../src/main/resources/factoryConfiguration.json | 3 + .../openecomp-sdc-translator-core/pom.xml | 89 + .../datatypes/heattotosca/AttachedResourceId.java | 65 + .../heattotosca/ResourceReferenceType.java | 25 + .../heattotosca/to/FileDataCollection.java | 123 + .../heattotosca/to/ResourceFileDataAndIDs.java | 70 + .../datatypes/heattotosca/to/TranslateTo.java | 132 + .../heattotosca/to/TranslatedHeatResource.java | 49 + .../HeatToToscaTranslatorFactoryImpl.java | 34 + .../heattotosca/HeatToToscaTranslatorImpl.java | 134 + .../translator/services/heattotosca/Constants.java | 60 + .../services/heattotosca/HeatToToscaUtil.java | 503 + .../services/heattotosca/ResourceTranslation.java | 37 + .../heattotosca/ResourceTranslationFactory.java | 107 + .../services/heattotosca/TranslationContext.java | 172 + .../services/heattotosca/TranslationService.java | 344 + .../IncorrectResourceReferenceErrorBuilder.java | 51 + .../errors/InvalidPropertyValueErrorBuilder.java | 47 + .../MissingMandatoryPropertyErrorBuilder.java | 43 + .../NotInSyncNumberOfInterfacesErrorBuilder.java | 44 + ...ReferenceToUnsupportedResourceErrorBuilder.java | 52 + .../ResourceNotFoundInHeatFileErrorBuilder.java | 52 + .../heattotosca/errors/TranslatorErrorCodes.java | 31 + .../globaltypes/AbstractSubstituteGlobalType.java | 167 + .../globaltypes/CinderVolumeGlobalType.java | 242 + .../heattotosca/globaltypes/CommonGlobalTypes.java | 500 + .../ContrailAbstractSubstituteGlobalType.java | 196 + .../globaltypes/ContrailComputeGlobalType.java | 128 + .../globaltypes/ContrailNetworkRuleGlobalType.java | 227 + .../globaltypes/ContrailPortGlobalType.java | 107 + .../ContrailV2NetworkRuleGlobalType.java | 274 + ...ontrailV2VirtualMachineInterfaceGlobalType.java | 136 + .../ContrailV2VirtualNetworkGlobalType.java | 239 + .../ContrailVirtualNetworkGlobalType.java | 134 + .../globaltypes/GlobalTypesGenerator.java | 128 + .../heattotosca/globaltypes/GlobalTypesUtil.java | 69 + .../globaltypes/NeutronNetGlobalType.java | 143 + .../globaltypes/NeutronPortGlobalType.java | 203 + .../NeutronSecurityRulesGlobalType.java | 175 + .../globaltypes/NovaServerGlobalType.java | 307 + .../helper/ContrailTranslationHelper.java | 65 + .../heattotosca/helper/NameExtractorService.java | 33 + .../heattotosca/helper/PropertyRegexMatcher.java | 69 + .../helper/VolumeTranslationHelper.java | 172 + .../helper/impl/NameExtractorServiceImpl.java | 95 + .../heattotosca/impl/BaseResourceConnection.java | 174 + ...ntrailV2VmInterfaceToNetResourceConnection.java | 139 + .../impl/NovaAndPortResourceConnectionHelper.java | 106 + .../impl/NovaToVolResourceConnection.java | 228 + .../impl/PortToNetResourceConnection.java | 200 + .../heattotosca/impl/ResourceTranslationBase.java | 456 + ...ourceTranslationCinderVolumeAttachmentImpl.java | 202 + .../impl/ResourceTranslationCinderVolumeImpl.java | 77 + ...esourceTranslationContrailAttachPolicyImpl.java | 141 + ...sourceTranslationContrailNetworkPolicyImpl.java | 53 + ...urceTranslationContrailServiceInstanceImpl.java | 663 + ...urceTranslationContrailServiceTemplateImpl.java | 100 + ...urceTranslationContrailV2NetworkPolicyImpl.java | 49 + ...rceTranslationContrailV2VirtualNetworkImpl.java | 209 + ...sourceTranslationContrailV2VmInterfaceImpl.java | 126 + ...ourceTranslationContrailVirtualNetworkImpl.java | 51 + .../impl/ResourceTranslationDefaultImpl.java | 41 + .../impl/ResourceTranslationNestedImpl.java | 781 + .../impl/ResourceTranslationNeutronNetImpl.java | 52 + .../impl/ResourceTranslationNeutronPortImpl.java | 233 + ...esourceTranslationNeutronSecurityGroupImpl.java | 47 + .../impl/ResourceTranslationNeutronSubnetImpl.java | 170 + .../ResourceTranslationNovaServerGroupsImpl.java | 119 + .../impl/ResourceTranslationNovaServerImpl.java | 419 + .../impl/ResourceTranslationResourceGroupImpl.java | 202 + .../SecurityRulesToPortResourceConnection.java | 203 + .../TranslatorHeatToToscaFunctionConverter.java | 410 + .../TranslatorHeatToToscaParameterConverter.java | 271 + .../TranslatorHeatToToscaPropertyConverter.java | 146 + .../src/main/resources/heatToToscaMapping.json | 298 + .../org/openecomp/sdc/translator/TestUtils.java | 43 + .../nested/multi/Translate_Heat_Nested_Multi.java | 17 + .../nestedvolumelocal/NestedVolumelocal.java | 17 + .../NestedVolumeSeperateFile.java | 17 + .../TranslateHeatNestedRecursiveTest.java | 43 + .../Translate_Heat_Nested_From_Multi_Base.java | 18 + .../NestedAndSeparateVolTranslationTest.java | 22 + .../nested/single/TranslateHeatNestedSingle.java | 17 + .../outputs/HeatOutputConversionTest.java | 50 + .../parameters/HeatParameterConversionTest.java | 54 + .../resources/ContrailNetworkRuleTest.java | 18 + .../resources/OSContrailVirtualNetworkTest.java | 18 + .../heattotosca/resources/OSNeutronNetTest.java | 17 + .../heattotosca/resources/OSNovaServerTest.java | 17 + .../sharedresource/HeatSharedResourceTest.java | 19 + .../heattotosca/GlobalTypesGeneratorTest.java | 18 + .../hotmog/HotMogTranslationTest.java | 17 + .../vmmesmall/VmmeSmallTranslationTest.java | 17 + .../helper/impl/NameExtractorServiceImplTest.java | 118 + .../impl/BaseResourceTranslationTest.java | 130 + ...ilV2VMInterfaceToNetResourceConnectionTest.java | 46 + .../DependsOnResourceBaseTranslationlTest.java | 15 + .../impl/MultipleHeatTranslationTest.java | 31 + .../impl/NovaToVolResourceConnectionTest.java | 91 + ...railV2VirtualNetworkResourceConnectionTest.java | 45 + .../impl/PortToNetResourceConnectionTest.java | 38 + ...eTranslationCinderVolumeAttachmentImplTest.java | 52 + .../ResourceTranslationCinderVolumeImplTest.java | 15 + ...TranslationContrailServiceInstanceImplTest.java | 72 + ...TranslationContrailServiceTemplateImplTest.java | 55 + .../impl/ResourceTranslationContrailV2Test.java | 56 + ...ceTranslationContrailV2VMInterfaceImplTest.java | 36 + .../ResourceTranslationNeutronPortImplTest.java | 17 + ...rceTranslationNeutronSecurityGroupImplTest.java | 19 + ...esourceTranslationNovaServerGroupsImplTest.java | 16 + .../ResourceTranslationResourceGroupImplTest.java | 110 + .../SecurityGroupToNovaResourceConnectionTest.java | 24 + .../SecurityRulesToPortResourceConnectionTest.java | 55 + ...TranslatorHeatToToscaFunctionConverterTest.java | 68 + .../test/resources/mock/ep-jsa-si/ep-jsa-si.env | 14 + .../test/resources/mock/ep-jsa-si/ep-jsa-si.yaml | 76 + .../test/resources/mock/ep-jsa-si/ep-jsa_net.env | 4 + .../test/resources/mock/ep-jsa-si/ep-jsa_net.yaml | 26 + .../test/resources/mock/ep-jsa-si/master-jsa.env | 6 + .../test/resources/mock/ep-jsa-si/master-jsa.yaml | 57 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 236 + .../expectedoutputfiles/MainServiceTemplate.yaml | 240 + .../nested-pcm_v0.1ServiceTemplate.yaml | 207 + .../nested-pcm_v0.1_2ServiceTemplate.yaml | 193 + .../mock/heat/nested/multi/inputs/MANIFEST.json | 30 + .../nested/multi/inputs/hot-nimbus-pcm_v0.4.env | 14 + .../nested/multi/inputs/hot-nimbus-pcm_v0.4.yaml | 82 + .../nested/multi/inputs/hot-nimbus-pcm_v0.4_2.yaml | 79 + .../heat/nested/multi/inputs/nested-pcm_v0.1.yaml | 114 + .../nested/multi/inputs/nested-pcm_v0.1_2.yaml | 120 + .../mock/heat/nested/multi/inputs/nimbus-ethernet | 0 .../GlobalSubstitutionTypesServiceTemplate.yaml | 166 + .../expectedoutputfiles/MainServiceTemplate.yaml | 240 + .../mvs.nested.heatServiceTemplate.yaml | 320 + .../multiple_resource_groups/inputs/MANIFEST.json | 19 + .../inputs/mvs.nested.heat.yaml | 165 + .../inputs/mvs.vfmodule.heat.yaml | 158 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 267 + .../expectedoutputfiles/MainServiceTemplate.yaml | 241 + .../nested2levelServiceTemplate.yaml | 175 + .../expectedoutputfiles/nestedServiceTemplate.yaml | 217 + .../heat/nested/nested2levels/inputs/MANIFEST.json | 27 + .../heat/nested/nested2levels/inputs/addOn.yml | 26 + .../mock/heat/nested/nested2levels/inputs/base.yml | 58 + .../heat/nested/nested2levels/inputs/nested.yml | 65 + .../nested/nested2levels/inputs/nested2level.yml | 59 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 472 + .../expectedoutputfiles/MainServiceTemplate.yaml | 241 + .../nested2levelServiceTemplate.yaml | 217 + .../nested3levelServiceTemplate.yaml | 175 + .../expectedoutputfiles/nestedServiceTemplate.yaml | 247 + .../heat/nested/nested3levels/inputs/MANIFEST.json | 32 + .../heat/nested/nested3levels/inputs/addOn.yml | 26 + .../mock/heat/nested/nested3levels/inputs/base.yml | 58 + .../heat/nested/nested3levels/inputs/nested.yml | 65 + .../nested/nested3levels/inputs/nested2level.yml | 65 + .../nested/nested3levels/inputs/nested3level.yml | 59 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 79 + .../expectedoutputfiles/MainServiceTemplate.yaml | 65 + .../nested-pcm_v0.1ServiceTemplate.yaml | 91 + .../nested/nestedvolumelocal/inputs/MANIFEST.json | 14 + .../inputs/hot-nimbus-pcm_v0.4.yaml | 22 + .../nestedvolumelocal/inputs/nested-pcm_v0.1.yaml | 29 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 79 + .../expectedoutputfiles/MainServiceTemplate.yaml | 72 + .../nested-pcm_v0.1ServiceTemplate.yaml | 91 + .../nestedvolumeseperatefile/inputs/MANIFEST.json | 17 + .../inputs/hot-nimbus-pcm_v0.4.yaml | 23 + .../inputs/nested-pcm_v0.1.yaml | 31 + .../nestedvolumeseperatefile/inputs/volume.yaml | 14 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 330 + .../expectedoutputfiles/MainServiceTemplate.yaml | 240 + .../nested-pcm_v0.1ServiceTemplate.yaml | 291 + .../nested-pcm_v0.1_2ServiceTemplate.yaml | 205 + .../heat/nested/recursive/inputs/MANIFEST.json | 26 + .../recursive/inputs/hot-nimbus-pcm_v0.4.env | 14 + .../recursive/inputs/hot-nimbus-pcm_v0.4.yaml | 82 + .../recursive/inputs/hot-nimbus-pcm_v0.4_2.yaml | 79 + .../nested/recursive/inputs/nested-pcm_v0.1.yaml | 138 + .../nested/recursive/inputs/nested-pcm_v0.1_2.yaml | 110 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 161 + .../expectedoutputfiles/MainServiceTemplate.yaml | 569 + .../mvs.nested.heatServiceTemplate.yaml | 254 + .../resourceGroupIndexVar/inputs/MANIFEST.json | 19 + .../inputs/mvs.nested.heat.yaml | 129 + .../inputs/mvs.vfmodule.heat.yaml | 228 + .../resourceGroupInvalid/inputs/MANIFEST.json | 19 + .../inputs/mvs.nested.heat.yaml | 129 + .../inputs/mvs.vfmodule.heat.yaml | 166 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 153 + .../expectedoutputfiles/MainServiceTemplate.yaml | 246 + .../dns_nested_01ServiceTemplate.yaml | 249 + .../nested/resourceGroupMDNS/inputs/MANIFEST.json | 37 + .../nested/resourceGroupMDNS/inputs/base_dns.env | 8 + .../nested/resourceGroupMDNS/inputs/base_dns.yaml | 43 + .../nested/resourceGroupMDNS/inputs/dns_az_01.env | 21 + .../nested/resourceGroupMDNS/inputs/dns_az_01.yaml | 94 + .../resourceGroupMDNS/inputs/dns_nested_01.yaml | 127 + .../resourceGroupMDNS/inputs/nimbus-willows-2.pem | 27 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 161 + .../expectedoutputfiles/MainServiceTemplate.yaml | 223 + .../mvs.nested.heatServiceTemplate.yaml | 254 + .../nested/resource_group/inputs/MANIFEST.json | 19 + .../resource_group/inputs/mvs.nested.heat.yaml | 129 + .../resource_group/inputs/mvs.vfmodule.heat.yaml | 163 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 166 + .../expectedoutputfiles/MainServiceTemplate.yaml | 195 + .../mvs.nested.heatServiceTemplate.yaml | 320 + .../inputs/MANIFEST.json | 19 + .../inputs/mvs.nested.heat.yaml | 165 + .../inputs/mvs.vfmodule.heat.yaml | 105 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 137 + .../expectedoutputfiles/MainServiceTemplate.yaml | 216 + .../nested-pcm_v0.1ServiceTemplate.yaml | 207 + .../reusenestedfrommultibase/inputs/MANIFEST.json | 23 + .../inputs/hot-nimbus-pcm_v0.4.env | 14 + .../inputs/hot-nimbus-pcm_v0.4.yaml | 82 + .../inputs/hot-nimbus-pcm_v0.4_2.yaml | 71 + .../inputs/nested-pcm_v0.1.yaml | 114 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 137 + .../expectedoutputfiles/MainServiceTemplate.yaml | 236 + .../nested-pcm_v0.1ServiceTemplate.yaml | 207 + .../mock/heat/nested/single/inputs/MANIFEST.json | 20 + .../nested/single/inputs/hot-nimbus-pcm_v0.4.env | 14 + .../nested/single/inputs/hot-nimbus-pcm_v0.4.yaml | 94 + .../heat/nested/single/inputs/nested-pcm_v0.1.yaml | 114 + .../expectedoutputfiles/MainServiceTemplate.yaml | 86 + .../mock/heat/outputs/inputs/MANIFEST.json | 11 + .../mock/heat/outputs/inputs/outputs.yaml | 48 + .../expectedoutputfiles/MainServiceTemplate.yaml | 181 + .../mock/heat/parameters/inputs/MANIFEST.json | 17 + .../mock/heat/parameters/inputs/parameters.env | 6 + .../mock/heat/parameters/inputs/parameters.yaml | 101 + .../expectedoutputfiles/MainServiceTemplate.yaml | 197 + .../OS_Contrail_Network_Rule/inputs/MANIFEST.json | 12 + .../inputs/network_policy_chain.yaml | 117 + .../expectedoutputfiles/MainServiceTemplate.yaml | 1308 + .../inputs/MANIFEST.json | 21 + .../inputs/nimbus-ethernet.sh | 0 .../inputs/vmme_small.env | 97 + .../inputs/vmme_small.yml | 722 + .../expectedoutputfiles/MainServiceTemplate.yaml | 219 + .../resources/OS_Neutron_Net/inputs/MANIFEST.json | 17 + .../resources/OS_Neutron_Net/inputs/ep-jsa_net.env | 4 + .../OS_Neutron_Net/inputs/ep-jsa_net.yaml | 135 + .../expectedoutputfiles/MainServiceTemplate.yaml | 602 + .../resources/OS_Nova_Server/inputs/MANIFEST.json | 25 + .../resources/OS_Nova_Server/inputs/ep-jsa_net.env | 4 + .../OS_Nova_Server/inputs/ep-jsa_net.yaml | 411 + .../OS_Nova_Server/inputs/nimbus-ethernet | 0 .../OS_Nova_Server/inputs/nimbus-ethernet-gw | 0 .../expectedoutputfiles/MainServiceTemplate.yaml | 95 + .../mock/heat/sharedresources/inputs/MANIFEST.json | 12 + .../inputs/sharedDefinitionOutParam.yaml | 45 + .../expectedOutput/validationOutput.json | 1 + .../overallexample/inputs/MANIFEST.json | 83 + .../overallexample/inputs/MMSC_Capacity_Line.yml | 3234 ++ .../overallexample/inputs/MMSC_Capacity_Line_1.env | 111 + .../overallexample/inputs/NETWORK_OUT.yaml | 76 + .../overallexample/inputs/SG_ECA_MGMT.yaml | 81 + .../overallexample/inputs/VOLUME.yaml | 76 + .../overallexample/inputs/VOLUME_OUT.yaml | 76 + .../overallexample/inputs/art.sh | 1 + .../overallexample/inputs/cmaui.env | 15 + .../overallexample/inputs/cmaui.yml | 179 + .../overallexample/inputs/cmaui_net.yaml | 76 + .../overallexample/inputs/eca_oam.env | 20 + .../overallexample/inputs/eca_oam.yaml | 453 + .../overallexample/inputs/eca_oam_nested.yaml | 406 + .../overallexample/inputs/nested1.yaml | 430 + .../overallexample/inputs/nested2.yaml | 431 + .../overallexample/inputs/network_out.env | 7 + .../overallexample/inputs/sg_eca_mgmt.env | 7 + .../overallexample/inputs/volume.env | 7 + .../overallexample/inputs/volume_out.env | 7 + .../expectedOutput/MainServiceTemplate.yaml | 4518 +++ .../multiHeat/allHeatsAreBase/inputs/MANIFEST.json | 37 + .../allHeatsAreBase/inputs/MMSC_Capacity_Line.yml | 3219 ++ .../inputs/MMSC_Capacity_Line_1.env | 111 + .../allHeatsAreBase/inputs/SG_ECA_MGMT.yaml | 76 + .../multiHeat/allHeatsAreBase/inputs/cmaui.env | 15 + .../multiHeat/allHeatsAreBase/inputs/cmaui.yml | 171 + .../multiHeat/allHeatsAreBase/inputs/eca_oam.env | 20 + .../multiHeat/allHeatsAreBase/inputs/eca_oam.yaml | 379 + .../allHeatsAreBase/inputs/sg_eca_mgmt.env | 7 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 347 + .../expectedOutput/MainServiceTemplate.yaml | 4193 +++ .../expectedOutput/eca_oamServiceTemplate.yaml | 569 + .../referencedHeatResources/inputs/MANIFEST.json | 37 + .../inputs/MMSC_Capacity_Line.yml | 3219 ++ .../inputs/MMSC_Capacity_Line_1.env | 111 + .../inputs/SG_ECA_MGMT.yaml | 76 + .../referencedHeatResources/inputs/cmaui.env | 15 + .../referencedHeatResources/inputs/cmaui.yml | 171 + .../referencedHeatResources/inputs/eca_oam.env | 20 + .../referencedHeatResources/inputs/eca_oam.yaml | 407 + .../referencedHeatResources/inputs/sg_eca_mgmt.env | 7 + .../expectedoutputfiles/MainServiceTemplate.yaml | 305 + .../inputfiles/MANIFEST.json | 12 + .../inputfiles/main.yml | 223 + .../expectedoutputfiles/MainServiceTemplate.yaml | 291 + .../inputfiles/MANIFEST.json | 12 + .../inputfiles/main.yml | 203 + .../expectedoutputfiles/MainServiceTemplate.yaml | 193 + .../inputfiles/MANIFEST.json | 12 + .../inputfiles/main.yml | 153 + .../expectedoutputfiles/MainServiceTemplate.yaml | 225 + .../simple/inputfiles/MANIFEST.json | 12 + .../simple/inputfiles/main.yml | 153 + .../expectedoutputfiles/MainServiceTemplate.yaml | 190 + .../multi/inputfiles/MANIFEST.json | 17 + .../multi/inputfiles/addOn.yml | 72 + .../multi/inputfiles/main.yml | 28 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 117 + .../expectedoutputfiles/MainServiceTemplate.yaml | 81 + .../expectedoutputfiles/nestedServiceTemplate.yaml | 181 + .../nested/inputfiles/MANIFEST.json | 17 + .../nested/inputfiles/main.yml | 27 + .../nested/inputfiles/nested.yml | 68 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 254 + .../expectedoutputfiles/MainServiceTemplate.yaml | 152 + .../nested1ServiceTemplate.yaml | 279 + .../nested2ServiceTemplate.yaml | 146 + .../shared/inputfiles/MANIFEST.json | 27 + .../shared/inputfiles/addOn.yml | 32 + .../shared/inputfiles/main.yml | 29 + .../shared/inputfiles/nested1.yml | 110 + .../shared/inputfiles/nested2.yml | 48 + .../expectedoutputfiles/MainServiceTemplate.yaml | 215 + .../inputfiles/MANIFEST.json | 11 + .../inputfiles/hot_template.yml | 131 + .../expectedoutputfiles/MainServiceTemplate.yaml | 131 + .../inputfiles/MANIFEST.json | 11 + .../inputfiles/hot_template.yml | 79 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 83 + .../expectedoutputfiles/MainServiceTemplate.yaml | 401 + .../service_instance_1ServiceTemplate.yaml | 407 + .../service_instance_2ServiceTemplate.yaml | 319 + .../diffServiceTemplate/inputfiles/MANIFEST.json | 12 + .../diffServiceTemplate/inputfiles/OCS-fw.yml | 213 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 64 + .../expectedoutputfiles/MainServiceTemplate.yaml | 300 + .../service_instanceServiceTemplate.yaml | 411 + .../oneServiceInstance/inputfiles/MANIFEST.json | 17 + .../inputfiles/lcp1_mss.oam-fw_si.yaml | 153 + .../lcp1_mss.oam-fw_si_with_comments.env | 26 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 64 + .../expectedoutputfiles/MainServiceTemplate.yaml | 441 + .../service_instance_1ServiceTemplate.yaml | 407 + .../service_instance_2ServiceTemplate.yaml | 407 + .../sameServiceTemplate/inputfiles/MANIFEST.json | 12 + .../sameServiceTemplate/inputfiles/OCS-fw.yml | 213 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 71 + .../expectedoutputfiles/MainServiceTemplate.yaml | 407 + .../service_instanceServiceTemplate.yaml | 451 + .../sharedNetworkMulti/inputfiles/MANIFEST.json | 17 + .../sharedNetworkMulti/inputfiles/OCS-fw.yml | 173 + .../sharedNetworkMulti/inputfiles/network_base.yml | 47 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 154 + .../expectedoutputfiles/MainServiceTemplate.yaml | 90 + .../expectedoutputfiles/OCS-fwServiceTemplate.yaml | 294 + .../service_instanceServiceTemplate.yaml | 275 + .../sharedNetworkNested/inputfiles/MANIFEST.json | 16 + .../sharedNetworkNested/inputfiles/OCS-fw.yml | 163 + .../sharedNetworkNested/inputfiles/main.yml | 30 + .../expectedoutputfiles/MainServiceTemplate.yaml | 265 + .../listNet/inputfiles/MANIFEST.json | 11 + .../listNet/inputfiles/hot_template.yml | 177 + .../expectedoutputfiles/MainServiceTemplate.yaml | 203 + .../oneNet/inputfiles/MANIFEST.json | 11 + .../oneNet/inputfiles/hot_template.yml | 128 + ...stractSubstituteGlobalTypesServiceTemplate.yaml | 88 + .../CinderVolumeGlobalTypesServiceTemplate.yaml | 178 + .../CommonGlobalTypesServiceTemplate.yaml | 354 + ...stractSubstituteGlobalTypesServiceTemplate.yaml | 166 + .../ContrailComputeGlobalTypesServiceTemplate.yaml | 89 + ...ntrailNetworkRuleGlobalTypeServiceTemplate.yaml | 131 + .../ContrailPortGlobalTypesServiceTemplate.yaml | 64 + ...railV2NetworkRuleGlobalTypeServiceTemplate.yaml | 156 + ...lMachineInterfaceGlobalTypeServiceTemplate.yaml | 69 + ...lV2VirtualNetworkGlobalTypeServiceTemplate.yaml | 139 + ...ailVirtualNetworkGlobalTypeServiceTemplate.yaml | 84 + .../expectedoutputfiles/MainServiceTemplate.yaml | 196 + .../NativeTypesServiceTemplateServiceTemplate.yaml | 205 + .../NeutronNetGlobalTypesServiceTemplate.yaml | 97 + .../NeutronPortGlobalTypesServiceTemplate.yaml | 151 + ...ronSecurityRulesGlobalTypesServiceTemplate.yaml | 116 + .../NovaServerGlobalTypesServiceTemplate.yaml | 249 + .../global_types/inputfiles/MANIFEST.json | 11 + .../global_types/inputfiles/hot_template.yml | 122 + .../expectedoutputfiles/MainServiceTemplate.yaml | 1459 + .../hot-mog-0108-bs1271/inputfiles/MANIFEST.json | 17 + .../inputfiles/hot-mog-0108-bs1271.env | 60 + .../inputfiles/hot-mog-0108-bs1271.yml | 733 + .../inputfiles/MANIFEST.json | 99 + .../inputfiles/cloud-nimbus.sh | 12 + .../inputfiles/hot-nimbus-oam-volumes_v1.0.env | 6 + .../inputfiles/hot-nimbus-oam-volumes_v1.0.yaml | 45 + .../inputfiles/hot-nimbus-oam_v1.0.env | 18 + .../inputfiles/hot-nimbus-oam_v1.0.yaml | 109 + .../inputfiles/hot-nimbus-pcm-volumes_v1.0.env | 4 + .../inputfiles/hot-nimbus-pcm-volumes_v1.0.yaml | 28 + .../inputfiles/hot-nimbus-pcm_v1.0.env | 16 + .../inputfiles/hot-nimbus-pcm_v1.0.yaml | 80 + .../inputfiles/hot-nimbus-ppd_v1.0.yaml | 286 + .../inputfiles/hot-nimbus-ppd_v1.1.env | 35 + .../inputfiles/hot-nimbus-pps_v1.0.env | 11 + .../inputfiles/hot-nimbus-pps_v1.0.yaml | 121 + .../inputfiles/hot-nimbus-psm_v1.0.env | 10 + .../inputfiles/hot-nimbus-psm_v1.0.yaml | 199 + .../inputfiles/nested-oam_v1.0.yaml | 156 + .../inputfiles/nested-pcm_v1.0.yaml | 150 + .../inputfiles/nested-ppd_v1.0.yaml | 333 + .../inputfiles/nested-pps_v1.0.yaml | 99 + .../inputfiles/nested-psm_v1.0.yaml | 99 + .../inputfiles/nimbus-ethernet | 5 + .../inputfiles/nimbus-ethernet-gw | 6 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 642 + .../out/MainServiceTemplate.yaml | 1646 + .../out/nested-oam_v1.0ServiceTemplate.yaml | 225 + .../out/nested-pcm_v1.0ServiceTemplate.yaml | 216 + .../out/nested-ppd_v1.0ServiceTemplate.yaml | 464 + .../out/nested-pps_v1.0ServiceTemplate.yaml | 160 + .../out/nested-psm_v1.0ServiceTemplate.yaml | 160 + .../expectedoutputfiles/MainServiceTemplate.yaml | 115 + .../inputfiles/MANIFEST.json | 11 + .../inputfiles/hot_template.yml | 49 + .../expectedoutputfiles/MainServiceTemplate.yaml | 169 + .../inputfiles/MANIFEST.json | 11 + .../inputfiles/hot_template.yml | 57 + .../expectedoutputfiles/MainServiceTemplate.yaml | 603 + .../novaservergroups/inputfiles/MANIFEST.json | 11 + .../novaservergroups/inputfiles/hot_template.yml | 383 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 187 + .../expectedoutputfiles/MainServiceTemplate.yaml | 194 + .../expectedoutputfiles/nestedServiceTemplate.yaml | 279 + .../innernestedconnection/inputfiles/MANIFEST.json | 24 + .../innernestedconnection/inputfiles/a_vol.yml | 32 + .../innernestedconnection/inputfiles/main.yml | 77 + .../innernestedconnection/inputfiles/nested.yml | 170 + .../expectedoutputfiles/MainServiceTemplate.yaml | 276 + .../multiconnection/inputfiles/MANIFEST.json | 17 + .../multiconnection/inputfiles/addOn.yml | 168 + .../multiconnection/inputfiles/main.yml | 31 + .../expectedoutputfiles/MainServiceTemplate.yaml | 314 + .../multinotconnected/inputfiles/MANIFEST.json | 17 + .../multinotconnected/inputfiles/addOn.yml | 171 + .../multinotconnected/inputfiles/main.yml | 128 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 109 + .../expectedoutputfiles/MainServiceTemplate.yaml | 76 + .../expectedoutputfiles/nestedServiceTemplate.yaml | 150 + .../nestedconnection/inputfiles/MANIFEST.json | 17 + .../nestedconnection/inputfiles/main.yml | 26 + .../nestedconnection/inputfiles/nested.yml | 55 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 109 + .../expectedoutputfiles/MainServiceTemplate.yaml | 146 + .../expectedoutputfiles/nestedServiceTemplate.yaml | 150 + .../nestednotconnected/inputfiles/MANIFEST.json | 17 + .../nestednotconnected/inputfiles/main.yml | 64 + .../nestednotconnected/inputfiles/nested.yml | 55 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 158 + .../expectedoutputfiles/MainServiceTemplate.yaml | 114 + .../expectedoutputfiles/nestedServiceTemplate.yaml | 212 + .../inputfiles/MANIFEST.json | 22 + .../sharednestedconnection/inputfiles/addOn.yml | 30 + .../sharednestedconnection/inputfiles/main.yml | 32 + .../sharednestedconnection/inputfiles/nested.yml | 87 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 158 + .../expectedoutputfiles/MainServiceTemplate.yaml | 181 + .../expectedoutputfiles/nestedServiceTemplate.yaml | 212 + .../inputfiles/MANIFEST.json | 22 + .../sharednestednotconnected/inputfiles/addOn.yml | 30 + .../sharednestednotconnected/inputfiles/main.yml | 70 + .../sharednestednotconnected/inputfiles/nested.yml | 87 + .../expectedoutputfiles/MainServiceTemplate.yaml | 326 + .../expectedoutputfiles/MainServiceTemplate.yaml | 104 + .../inputfiles/addOn.yml | 30 + .../expectedoutputfiles/MainServiceTemplate.yaml | 143 + .../multi/inputfiles/MANIFEST.json | 17 + .../multi/inputfiles/addOn.yml | 48 + .../multi/inputfiles/main.yml | 20 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 106 + .../expectedoutputfiles/MainServiceTemplate.yaml | 225 + .../expectedoutputfiles/nestedServiceTemplate.yaml | 145 + .../nested/inputfiles/MANIFEST.json | 17 + .../nested/inputfiles/main.yml | 140 + .../nested/inputfiles/nested.yml | 45 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 251 + .../expectedoutputfiles/MainServiceTemplate.yaml | 334 + .../nested1ServiceTemplate.yaml | 252 + .../nested2ServiceTemplate.yaml | 146 + .../shared/inputfiles/MANIFEST.json | 27 + .../shared/inputfiles/addOn.yml | 32 + .../shared/inputfiles/main.yml | 174 + .../shared/inputfiles/nested1.yml | 86 + .../shared/inputfiles/nested2.yml | 48 + .../expectedoutputfiles/MainServiceTemplate.yaml | 143 + .../multi/inputfiles/MANIFEST.json | 17 + .../porttonetconnection/multi/inputfiles/addOn.yml | 48 + .../porttonetconnection/multi/inputfiles/main.yml | 20 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 134 + .../expectedoutputfiles/MainServiceTemplate.yaml | 110 + .../expectedoutputfiles/nestedServiceTemplate.yaml | 203 + .../nested/inputfiles/MANIFEST.json | 17 + .../porttonetconnection/nested/inputfiles/main.yml | 42 + .../nested/inputfiles/nested.yml | 67 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 251 + .../expectedoutputfiles/MainServiceTemplate.yaml | 172 + .../nested1ServiceTemplate.yaml | 252 + .../nested2ServiceTemplate.yaml | 146 + .../shared/inputfiles/MANIFEST.json | 27 + .../shared/inputfiles/addOn.yml | 38 + .../porttonetconnection/shared/inputfiles/main.yml | 39 + .../shared/inputfiles/nested1.yml | 86 + .../shared/inputfiles/nested2.yml | 48 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 106 + .../expectedoutputfiles/MainServiceTemplate.yaml | 85 + .../expectedoutputfiles/nestedServiceTemplate.yaml | 145 + .../inputfiles/MANIFEST.json | 17 + .../inputfiles/main.yml | 31 + .../inputfiles/nested.yml | 45 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 177 + .../expectedoutputfiles/MainServiceTemplate.yaml | 131 + .../nested1ServiceTemplate.yaml | 252 + .../inputfiles/MANIFEST.json | 22 + .../inputfiles/addOn.yml | 32 + .../inputfiles/main.yml | 29 + .../inputfiles/nested1.yml | 86 + .../expectedoutputfiles/MainServiceTemplate.yaml | 634 + .../inputfiles/MANIFEST.json | 27 + .../inputfiles/addOn1.yml | 57 + .../inputfiles/addOn2.yml | 57 + .../inputfiles/addOn3.yml | 67 + .../inputfiles/main.yml | 311 + .../expectedoutputfiles/MainServiceTemplate.yaml | 1077 + .../inputfiles/FEAdd_On_Module_QRouterCloudConfig | 39 + .../FEAdd_On_Module_QRouterTemplate.yaml | 216 + .../inputfiles/FEAdd_On_Module_vLBAgentCloudConfig | 53 + .../FEAdd_On_Module_vLBAgentTemplate.yaml | 303 + .../inputfiles/FEAdd_On_Module_vLBCloudConfig | 41 + .../inputfiles/FEAdd_On_Module_vLBTemplate.yaml | 287 + .../inputfiles/FEAdd_On_Module_vProbeCloudConfig | 50 + .../inputfiles/FEAdd_On_Module_vProbeTemplate.yaml | 308 + .../inputfiles/FEBase_Module.env | 91 + .../inputfiles/FEBase_Module.yaml | 670 + .../inputfiles/MANIFEST.json | 89 + .../inputfiles/call_home.py | 97 + .../inputfiles/check_availability.py | 34 + .../inputfiles/qrouterdependencies.json | 35 + .../inputfiles/register_status.py | 126 + .../inputfiles/vlbagentdependencies_with_vLB.json | 46 + .../vlbagentdependencies_without_vLB.json | 39 + .../inputfiles/vlbdependencies.json | 43 + .../inputfiles/vprobedependencies.json | 49 + .../inputfiles/wait_for_resources.py | 84 + .../expectedoutputfiles/MainServiceTemplate.yaml | 340 + .../inputfiles/MANIFEST.json | 17 + .../inputfiles/addOn.yml | 72 + .../inputfiles/main.yml | 58 + .../expectedoutputfiles/MainServiceTemplate.yaml | 222 + .../expectedoutputfiles/nestedServiceTemplate.yaml | 175 + .../inputfiles/MANIFEST.json | 17 + .../inputfiles/main.yml | 58 + .../inputfiles/nested.yml | 58 + .../expectedoutputfiles/MainServiceTemplate.yaml | 241 + .../expectedoutputfiles/nestedServiceTemplate.yaml | 175 + .../inputfiles/MANIFEST.json | 22 + .../inputfiles/addOn.yml | 26 + .../inputfiles/main.yml | 58 + .../inputfiles/nested.yml | 59 + .../expectedoutputfiles/MainServiceTemplate.yaml | 332 + .../expectedoutputfiles/MainServiceTemplate.yaml | 231 + .../inputfiles/MANIFEST.json | 22 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 119 + .../expectedoutputfiles/MainServiceTemplate.yaml | 243 + .../expectedoutputfiles/nestedServiceTemplate.yaml | 174 + .../inputfiles/MANIFEST.json | 22 + .../inputfiles/addOn.yml | 31 + .../inputfiles/main.yml | 58 + .../inputfiles/nested.yml | 58 + .../expectedoutputfiles/MainServiceTemplate.yaml | 1267 + .../vmme_small/inputfiles/MANIFEST.json | 27 + .../vmme_small/inputfiles/vmme_small.env | 97 + .../vmme_small/inputfiles/vmme_small.yml | 644 + .../inputfiles/vmme_small_create_fsb.env | 8 + .../inputfiles/vmme_small_create_fsb.yml | 54 + .../nested_with_inner_vol/inputfiles/MANIFEST.json | 24 + .../nested_with_inner_vol/inputfiles/a_vol.yml | 24 + .../nested_with_inner_vol/inputfiles/main.yml | 71 + .../nested_with_inner_vol/inputfiles/nested.yml | 116 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 146 + .../out/MainServiceTemplate.yaml | 150 + .../out/nestedServiceTemplate.yaml | 242 + .../expectedoutputfiles/MainServiceTemplate.yaml | 194 + .../inputfiles/MANIFEST.json | 11 + .../inputfiles/hot_template.yml | 131 + .../expectedoutputfiles/MainServiceTemplate.yaml | 203 + .../inputfiles/MANIFEST.json | 19 + .../inputfiles/a_vol.yml | 24 + .../inputfiles/hot_template.yml | 112 + .../expectedoutputfiles/MainServiceTemplate.yaml | 189 + .../inputfiles/MANIFEST.json | 16 + .../inputfiles/a_vol.yml | 20 + .../inputfiles/hot_template.yml | 112 + .../test/resources/mock/testManifestFormat.json | 59 + .../mock/vmme_small_create_fsb/MANIFEST.json | 29 + .../mock/vmme_small_create_fsb/create_stack.sh | 1 + .../mock/vmme_small_create_fsb/vmme_small.env | 97 + .../mock/vmme_small_create_fsb/vmme_small.yml | 676 + .../vmme_small_create_fsb.env | 8 + .../vmme_small_create_fsb.yml | 54 + .../lib/openecomp-sdc-translator-lib/pom.xml | 37 + .../openecomp-sdc-validation-api/pom.xml | 38 + .../core/validation/api/ValidationManager.java | 35 + .../errors/ErrorMessagesFormatBuilder.java | 30 + .../openecomp/core/validation/errors/Messages.java | 117 + .../factory/ValidationManagerFactory.java | 32 + .../core/validation/interfaces/Validator.java | 36 + .../validation/types/FileValidationContext.java | 53 + .../validation/types/GlobalValidationContext.java | 142 + .../core/validation/types/MessageContainer.java | 82 + .../validation/types/MessageContainerUtil.java | 64 + .../src/main/resources/factoryConfiguration.json | 3 + .../main/resources/validationConfiguration.json | 24 + .../openecomp-sdc-validation-core/pom.xml | 93 + .../impl/ValidationManagerFactoryImpl.java | 34 + .../sdc/validation/impl/ValidationManagerImpl.java | 69 + .../validation/utils/ValidationConfiguration.java | 37 + .../utils/ValidationConfigurationManager.java | 74 + .../validation/utils/ValidationManagerUtil.java | 65 + .../validation/utils/ValidatorConfiguration.java | 51 + .../heat/services/tree/HeatTreeManagerTest.java | 51 + .../heatTreeValidationOutput/MANIFEST.json | 35 + .../hot-nimbus-pps_v1.0.env | 12 + .../hot-nimbus-pps_v1.0.yaml | 94 + .../hot-nimbus-psm_v1.0.env | 12 + .../hot-nimbus-psm_v1.0.yaml | 109 + .../hot-nimbus-psm_volume.yaml | 21 + .../heatTreeValidationOutput/nested-pps_v1.0.yaml | 98 + .../openecomp-sdc-validation-impl/pom.xml | 100 + .../impl/util/HeatValidationService.java | 323 + .../impl/util/ResourceValidationHeatValidator.java | 617 + .../impl/validators/EcompGuideLineValidator.java | 784 + .../validation/impl/validators/HeatValidator.java | 469 + .../impl/validators/ManifestValidator.java | 153 + .../validation/impl/validators/YamlValidator.java | 97 + .../impl/validators/ErrorMessagesTest.java | 25 + .../impl/validators/ValidatorBaseTest.java | 84 + .../validators/EcompGuideLineValidatorTest.java | 281 + .../validators/EcompNamingConventionTest.java | 104 + .../validators/validators/HeatValidatorTest.java | 356 + .../validators/ManifestValidatorTest.java | 125 + .../validators/validators/YamlValidatorTest.java | 89 + .../negative/MANIFEST.json | 27 + .../negative/first.env | 0 .../negative/first.yaml | 14 + .../negative/firstVol.yaml | 1 + .../negative/second.yaml | 14 + .../positive/MANIFEST.json | 27 + .../positive/first.env | 0 .../positive/first.yaml | 14 + .../positive/firstVol.yaml | 1 + .../positive/second.yaml | 14 + .../negative/MANIFEST.json | 27 + .../negative/first.env | 0 .../negative/first.yaml | 18 + .../negative/firstVol.yaml | 1 + .../negative/second.yaml | 14 + .../positive/MANIFEST.json | 27 + .../positive/first.env | 0 .../positive/first.yaml | 21 + .../positive/firstVol.yaml | 1 + .../positive/second.yaml | 14 + .../negative/MANIFEST.json | 27 + .../negative/first.env | 0 .../negative/first.yaml | 14 + .../negative/firstVol.yaml | 1 + .../negative/second.yaml | 14 + .../positive/MANIFEST.json | 27 + .../positive/first.env | 0 .../positive/first.yaml | 14 + .../positive/firstVol.yaml | 1 + .../positive/second.yaml | 14 + .../negative/MANIFEST.json | 27 + .../negative/first.env | 0 .../negative/first.yaml | 14 + .../negative/firstVol.yaml | 1 + .../negative/second.yaml | 14 + .../positive/MANIFEST.json | 27 + .../positive/first.env | 0 .../positive/first.yaml | 14 + .../positive/firstVol.yaml | 1 + .../positive/second.yaml | 14 + .../negative/MANIFEST.json | 27 + .../baseHeatDoesNotExposeVolume/negative/first.env | 0 .../negative/first.yaml | 14 + .../negative/firstVol.yaml | 1 + .../negative/second.yaml | 14 + .../positive/MANIFEST.json | 27 + .../baseHeatDoesNotExposeVolume/positive/first.env | 0 .../positive/first.yaml | 14 + .../positive/firstVol.yaml | 1 + .../positive/second.yaml | 14 + .../negative/MANIFEST.json | 27 + .../heatFloatingIpResourceType/negative/first.env | 0 .../heatFloatingIpResourceType/negative/first.yaml | 25 + .../negative/firstVol.yaml | 19 + .../negative/second.yaml | 14 + .../positive/MANIFEST.json | 27 + .../heatFloatingIpResourceType/positive/first.env | 0 .../heatFloatingIpResourceType/positive/first.yaml | 37 + .../positive/firstVol.yaml | 19 + .../positive/second.yaml | 14 + .../negative/MANIFEST.json | 27 + .../negative/first.env | 0 .../negative/first.yaml | 37 + .../negative/firstVol.yaml | 19 + .../negative/second.yaml | 14 + .../positive/MANIFEST.json | 27 + .../positive/first.env | 0 .../positive/first.yaml | 52 + .../positive/firstVol.yaml | 19 + .../positive/second.yaml | 14 + .../negative/MANIFEST.json | 27 + .../negative/first.env | 0 .../negative/first.yaml | 58 + .../negative/firstVol.yaml | 19 + .../negative/second.yaml | 14 + .../positive/MANIFEST.json | 27 + .../positive/first.env | 0 .../positive/first.yaml | 43 + .../positive/firstVol.yaml | 19 + .../positive/second.yaml | 14 + .../negative/MANIFEST.json | 27 + .../negative/first.env | 0 .../negative/first.yaml | 41 + .../negative/firstVol.yaml | 19 + .../negative/second.yaml | 14 + .../positive/MANIFEST.json | 27 + .../positive/first.env | 0 .../positive/first.yaml | 37 + .../positive/firstVol.yaml | 19 + .../positive/second.yaml | 14 + .../negative/MANIFEST.json | 27 + .../negative/first.env | 0 .../negative/first.yaml | 27 + .../negative/firstVol.yaml | 19 + .../negative/second.yaml | 14 + .../positive/MANIFEST.json | 27 + .../positive/first.env | 0 .../positive/first.yaml | 26 + .../positive/firstVol.yaml | 19 + .../positive/second.yaml | 14 + .../negative/MANIFEST.json | 27 + .../negative/first.env | 0 .../negative/first.yaml | 43 + .../negative/firstVol.yaml | 19 + .../negative/second.yaml | 14 + .../positive/MANIFEST.json | 27 + .../positive/first.env | 0 .../positive/first.yaml | 57 + .../positive/firstVol.yaml | 19 + .../positive/second.yaml | 14 + .../negative/MANIFEST.json | 27 + .../negative/first.env | 0 .../negative/first.yaml | 40 + .../negative/firstVol.yaml | 19 + .../negative/second.yaml | 14 + .../positive/MANIFEST.json | 27 + .../positive/first.env | 0 .../positive/first.yaml | 39 + .../positive/firstVol.yaml | 19 + .../positive/second.yaml | 14 + .../negative/MANIFEST.json | 27 + .../negative/first.env | 0 .../negative/first.yaml | 28 + .../negative/firstVol.yaml | 19 + .../negative/second.yaml | 14 + .../positive/MANIFEST.json | 27 + .../positive/first.env | 0 .../positive/first.yaml | 33 + .../positive/firstVol.yaml | 19 + .../positive/second.yaml | 14 + .../heatVolumeExpose/negative/MANIFEST.json | 27 + .../heatVolumeExpose/negative/first.env | 0 .../heatVolumeExpose/negative/first.yaml | 14 + .../heatVolumeExpose/negative/firstVol.yaml | 19 + .../heatVolumeExpose/negative/second.yaml | 14 + .../heatVolumeExpose/positive/MANIFEST.json | 27 + .../heatVolumeExpose/positive/first.env | 0 .../heatVolumeExpose/positive/first.yaml | 14 + .../heatVolumeExpose/positive/firstVol.yaml | 19 + .../heatVolumeExpose/positive/second.yaml | 14 + .../missingBaseHeat/MANIFEST.json | 27 + .../missingBaseHeat/first.env | 0 .../missingBaseHeat/first.yaml | 14 + .../missingBaseHeat/firstVol.yaml | 1 + .../missingBaseHeat/second.yaml | 14 + .../multiBaseHeat/MANIFEST.json | 27 + .../multiBaseHeat/first.env | 0 .../multiBaseHeat/first.yaml | 0 .../multiBaseHeat/firstVol.yaml | 0 .../multiBaseHeat/second.yaml | 0 .../expected_output/expected_output.json | 38 + .../availability_zone_name/input/MANIFEST.json | 17 + .../input/hot-nimbus-pps_v1.0.env | 12 + .../input/hot-nimbus-pps_v1.0.yaml | 92 + .../expected_output/expected_output.json | 34 + .../floating_ip_resource_type/input/MANIFEST.json | 17 + .../input/hot-nimbus-pps_v1.0.env | 12 + .../input/hot-nimbus-pps_v1.0.yaml | 71 + .../expected_output/expected_output.json | 42 + .../neutron_port_fixed_ip_name/input/MANIFEST.json | 17 + .../input/hot-nimbus-pps_v1.0.env | 12 + .../input/hot-nimbus-pps_v1.0.yaml | 128 + .../expected_output/expected_output.json | 50 + .../nova_server_name/input/MANIFEST.json | 17 + .../nova_server_name/input/hot-nimbus-pps_v1.0.env | 12 + .../input/hot-nimbus-pps_v1.0.yaml | 138 + .../negative_test/input/MANIFEST.json | 17 + .../negative_test/input/hot-nimbus-pps_v1.0.env | 11 + .../negative_test/input/hot-nimbus-pps_v1.0.yaml | 60 + .../input/MANIFEST.json | 11 + .../input/hot-nimbus-pps_v1.0.yaml | 43 + .../negative_test/input/MANIFEST.json | 17 + .../negative_test/input/hot-nimbus-pps_v1.0.env | 12 + .../negative_test/input/hot-nimbus-pps_v1.0.yaml | 54 + .../expected_output/expected_output.json | 1 + .../positive_test/input/MANIFEST.json | 51 + .../positive_test/input/hot-nimbus-pps_v1.0.env | 11 + .../positive_test/input/hot-nimbus-pps_v1.0.yaml | 121 + .../positive_test/input/hot-nimbus-psm_v1.0.env | 10 + .../positive_test/input/hot-nimbus-psm_v1.0.yaml | 199 + .../positive_test/input/nested-pps_v1.0.yaml | 97 + .../positive_test/input/nested-psm_v1.0.yaml | 97 + .../env_empty_value/input/MANIFEST.json | 17 + .../env_empty_value/input/env_empty_value.env | 3 + .../env_empty_value/input/env_empty_value.yaml | 122 + .../negative_test/input/MANIFEST.json | 35 + .../negative_test/input/hot-nimbus-pps_v1.0.env | 11 + .../negative_test/input/hot-nimbus-pps_v1.0.yaml | 50 + .../expected_output/expected_output.json | 1 + .../positive_test/input/MANIFEST.json | 51 + .../positive_test/input/hot-nimbus-pps_v1.0.env | 11 + .../positive_test/input/hot-nimbus-pps_v1.0.yaml | 121 + .../positive_test/input/hot-nimbus-psm_v1.0.env | 10 + .../positive_test/input/hot-nimbus-psm_v1.0.yaml | 199 + .../positive_test/input/nested-pps_v1.0.yaml | 97 + .../positive_test/input/nested-psm_v1.0.yaml | 97 + .../negative_test/input/MANIFEST.json | 21 + .../negative_test/input/hot-nimbus-psm_v1.0.env | 10 + .../negative_test/input/hot-nimbus-psm_v1.0.yaml | 72 + .../negative_test/input/nested-psm_v1.0.yaml | 103 + .../expected_output/expected_output.json | 1 + .../positive_test/input/MANIFEST.json | 51 + .../positive_test/input/hot-nimbus-pps_v1.0.env | 11 + .../positive_test/input/hot-nimbus-pps_v1.0.yaml | 121 + .../positive_test/input/hot-nimbus-psm_v1.0.env | 10 + .../positive_test/input/hot-nimbus-psm_v1.0.yaml | 204 + .../positive_test/input/nested-pps_v1.0.yaml | 97 + .../positive_test/input/nested-psm_v1.0.yaml | 103 + .../negative_test/input/MANIFEST.json | 21 + .../negative_test/input/hot-nimbus-psm_v1.0.env | 10 + .../negative_test/input/hot-nimbus-psm_v1.0.yaml | 55 + .../expected_output/expected_output.json | 1 + .../positive_test/input/MANIFEST.json | 51 + .../positive_test/input/hot-nimbus-pps_v1.0.env | 11 + .../positive_test/input/hot-nimbus-pps_v1.0.yaml | 121 + .../positive_test/input/hot-nimbus-psm_v1.0.env | 10 + .../positive_test/input/hot-nimbus-psm_v1.0.yaml | 199 + .../positive_test/input/nested-pps_v1.0.yaml | 97 + .../positive_test/input/nested-psm_v1.0.yaml | 97 + .../negative_test/input/MANIFEST.json | 11 + .../negative_test/input/hot-nimbus-pps_v1.0.yaml | 31 + .../negative_test/input/MANIFEST.json | 11 + .../negative_test/input/hot-nimbus-psm_v1.0.yaml | 52 + .../input/MANIFEST.json | 17 + .../input/hot-nimbus-pps_v1.0.env | 11 + .../input/hot-nimbus-pps_v1.0.yaml | 69 + .../negative_test/input/MANIFEST.json | 45 + .../negative_test/input/hot-nimbus-psm_v1.0.env | 10 + .../negative_test/input/hot-nimbus-psm_v1.0.yaml | 56 + .../input/nested-points-to-hot-nimbus-psm.yaml | 60 + .../negative_test/input/nested-psm_v1.0.yaml | 47 + .../negative_test/input/yaml-point-to-itself.yaml | 21 + .../expected_output/expected_output.json | 1 + .../positive_test/input/MANIFEST.json | 51 + .../positive_test/input/hot-nimbus-pps_v1.0.env | 11 + .../positive_test/input/hot-nimbus-pps_v1.0.yaml | 121 + .../positive_test/input/hot-nimbus-psm_v1.0.env | 10 + .../positive_test/input/hot-nimbus-psm_v1.0.yaml | 199 + .../positive_test/input/nested-pps_v1.0.yaml | 97 + .../positive_test/input/nested-psm_v1.0.yaml | 97 + .../negative_test/input/MANIFEST.json | 17 + .../negative_test/input/hot-nimbus-psm_v1.0.env | 10 + .../negative_test/input/hot-nimbus-psm_v1.0.yaml | 92 + .../expected_output/expected_output.json | 1 + .../positive_test/input/MANIFEST.json | 51 + .../positive_test/input/hot-nimbus-pps_v1.0.env | 11 + .../positive_test/input/hot-nimbus-pps_v1.0.yaml | 121 + .../positive_test/input/hot-nimbus-psm_v1.0.env | 10 + .../positive_test/input/hot-nimbus-psm_v1.0.yaml | 236 + .../positive_test/input/nested-pps_v1.0.yaml | 97 + .../positive_test/input/nested-psm_v1.0.yaml | 97 + .../negative_test/input/MANIFEST.json | 17 + .../negative_test/input/hot-nimbus-psm_v1.0.env | 10 + .../negative_test/input/hot-nimbus-psm_v1.0.yaml | 95 + .../expected_output/expected_output.json | 1 + .../positive_test/input/MANIFEST.json | 51 + .../positive_test/input/hot-nimbus-pps_v1.0.env | 11 + .../positive_test/input/hot-nimbus-pps_v1.0.yaml | 121 + .../positive_test/input/hot-nimbus-psm_v1.0.env | 10 + .../positive_test/input/hot-nimbus-psm_v1.0.yaml | 233 + .../positive_test/input/nested-pps_v1.0.yaml | 97 + .../positive_test/input/nested-psm_v1.0.yaml | 97 + .../negative_test/input/MANIFEST.json | 51 + .../negative_test/input/hot-nimbus-pps_v1.0.env | 11 + .../negative_test/input/hot-nimbus-pps_v1.0.yaml | 121 + .../negative_test/input/hot-nimbus-psm_v1.0.env | 10 + .../negative_test/input/hot-nimbus-psm_v1.0.yaml | 199 + .../negative_test/input/nested-pps_v1.0.yaml | 97 + .../negative_test/input/nested-psm_v1.0.yaml | 97 + .../expected_output/expected_output.json | 42 + .../positive_test/input/MANIFEST.json | 51 + .../positive_test/input/hot-nimbus-pps_v1.0.env | 11 + .../positive_test/input/hot-nimbus-pps_v1.0.yaml | 121 + .../positive_test/input/hot-nimbus-psm_v1.0.env | 10 + .../positive_test/input/hot-nimbus-psm_v1.0.yaml | 199 + .../positive_test/input/nested-pps_v1.0.yaml | 99 + .../positive_test/input/nested-psm_v1.0.yaml | 99 + .../negative_test/input/MANIFEST.json | 17 + .../negative_test/input/hot-nimbus-psm_v1.0.env | 8 + .../negative_test/input/hot-nimbus-psm_v1.0.yaml | 116 + .../expected_output/expected_output.json | 1 + .../positive_test/input/MANIFEST.json | 51 + .../positive_test/input/hot-nimbus-pps_v1.0.env | 11 + .../positive_test/input/hot-nimbus-pps_v1.0.yaml | 121 + .../positive_test/input/hot-nimbus-psm_v1.0.env | 10 + .../positive_test/input/hot-nimbus-psm_v1.0.yaml | 199 + .../positive_test/input/nested-pps_v1.0.yaml | 114 + .../positive_test/input/nested-psm_v1.0.yaml | 112 + .../negative_test/input/MANIFEST.json | 51 + .../negative_test/input/hot-nimbus-pps_v1.0.env | 11 + .../negative_test/input/hot-nimbus-pps_v1.0.yaml | 121 + .../negative_test/input/hot-nimbus-psm_v1.0.env | 10 + .../negative_test/input/hot-nimbus-psm_v1.0.yaml | 199 + .../negative_test/input/nested-pps_v1.0.yaml | 99 + .../negative_test/input/nested-psm_v1.0.yaml | 99 + .../expected_output/expected_output.json | 1 + .../positive_test/input/MANIFEST.json | 51 + .../positive_test/input/hot-nimbus-pps_v1.0.env | 11 + .../positive_test/input/hot-nimbus-pps_v1.0.yaml | 121 + .../positive_test/input/hot-nimbus-psm_v1.0.env | 10 + .../positive_test/input/hot-nimbus-psm_v1.0.yaml | 199 + .../positive_test/input/nested-pps_v1.0.yaml | 99 + .../positive_test/input/nested-psm_v1.0.yaml | 99 + .../negative_test/input/MANIFEST.json | 21 + .../negative_test/input/hot-nimbus-pps_v1.0.env | 11 + .../negative_test/input/hot-nimbus-pps_v1.0.yaml | 49 + .../negative_test/input/nested-pps_v1.0.yaml | 74 + .../expected_output/expected_output.json | 1 + .../positive_test/input/MANIFEST.json | 51 + .../positive_test/input/hot-nimbus-pps_v1.0.env | 11 + .../positive_test/input/hot-nimbus-pps_v1.0.yaml | 121 + .../positive_test/input/hot-nimbus-psm_v1.0.env | 10 + .../positive_test/input/hot-nimbus-psm_v1.0.yaml | 199 + .../positive_test/input/nested-pps_v1.0.yaml | 97 + .../positive_test/input/nested-psm_v1.0.yaml | 97 + .../pseudo_parameters/input/MANIFEST.json | 11 + .../pseudo_parameters/input/pseudo_parameters.yml | 61 + .../negative_test/input/MANIFEST.json | 11 + .../negative_test/input/hot-nimbus-pps_v1.0.yaml | 99 + .../expected_output/expected_output.json | 1 + .../positive_test/input/MANIFEST.json | 51 + .../positive_test/input/artifact.sh | 99 + .../positive_test/input/cloud-nimbus.sh | 99 + .../positive_test/input/hot-nimbus-pps_v1.0.env | 11 + .../positive_test/input/hot-nimbus-pps_v1.0.yaml | 121 + .../positive_test/input/hot-nimbus-psm_v1.0.env | 10 + .../positive_test/input/hot-nimbus-psm_v1.0.yaml | 212 + .../positive_test/input/nested-pps_v1.0.yaml | 99 + .../positive_test/input/nested-psm_v1.0.yaml | 99 + .../positive_test/input/nimbus-ethernet | 99 + .../negative_test/input/MANIFEST.json | 11 + .../negative_test/input/hot-nimbus-psm_v1.0.yaml | 102 + .../negative_test/input/yamlFile.yaml | 47 + .../negative_test/input/MANIFEST.json | 15 + .../negative_test/input/hot-nimbus-pps_v1.0.yaml | 16 + .../expected_output/expected_output.json | 1 + .../positive_test/input/MANIFEST.json | 51 + .../positive_test/input/hot-nimbus-pps_v1.0.env | 11 + .../positive_test/input/hot-nimbus-pps_v1.0.yaml | 121 + .../positive_test/input/hot-nimbus-psm_v1.0.env | 10 + .../positive_test/input/hot-nimbus-psm_v1.0.yaml | 199 + .../positive_test/input/nested-pps_v1.0.yaml | 97 + .../positive_test/input/nested-psm_v1.0.yaml | 97 + .../negative_test/input/MANIFEST.json | 19 + .../negative_test/input/hot-nimbus-pps_v1.0.yaml | 59 + .../negative_test/input/hot-nimbus-psm_v1.0.yaml | 98 + .../input/nested-from-resources-group.yaml | 105 + .../negative_test/input/nested-pps_v1.0.yaml | 52 + .../expected_output/expected_output.json | 1 + .../positive_test/input/MANIFEST.json | 51 + .../positive_test/input/hot-nimbus-pps_v1.0.env | 11 + .../positive_test/input/hot-nimbus-pps_v1.0.yaml | 144 + .../positive_test/input/hot-nimbus-psm_v1.0.env | 10 + .../positive_test/input/hot-nimbus-psm_v1.0.yaml | 288 + .../input/nested-from-resources-group.yaml | 97 + .../positive_test/input/nested-pps_v1.0.yaml | 97 + .../positive_test/input/nested-psm_v1.0.yaml | 97 + .../input/MANIFEST.json | 17 + .../input/baseFile.yaml | 43 + .../input/notBaseFile.yaml | 26 + .../input/MANIFEST.json | 17 + .../input/hot-nimbus-pps_v1.0.env | 11 + .../input/hot-nimbus-pps_v1.0.yaml | 68 + .../input/MANIFEST.json | 17 + .../input/hot-nimbus-pps_v1.0.env | 11 + .../input/hot-nimbus-pps_v1.0.yaml | 67 + .../negative_test/input/MANIFEST.json | 17 + .../negative_test/input/hot-nimbus-pps_v1.0.env | 11 + .../negative_test/input/hot-nimbus-pps_v1.0.yaml | 70 + .../expected_output/expected_output.json | 1 + .../positive_test/input/MANIFEST.json | 51 + .../positive_test/input/hot-nimbus-pps_v1.0.env | 11 + .../positive_test/input/hot-nimbus-pps_v1.0.yaml | 144 + .../positive_test/input/hot-nimbus-psm_v1.0.env | 10 + .../positive_test/input/hot-nimbus-psm_v1.0.yaml | 199 + .../positive_test/input/nested-pps_v1.0.yaml | 97 + .../positive_test/input/nested-psm_v1.0.yaml | 97 + .../shared_resources/input/MANIFEST.json | 17 + .../shared_resources/input/hot-nimbus-pps_v1.0.env | 11 + .../input/hot-nimbus-pps_v1.0.yaml | 90 + .../negative_test/input/MANIFEST.json | 35 + .../negative_test/input/hot-nimbus-pps_v1.0.env | 11 + .../negative_test/input/hot-nimbus-pps_v1.0.yaml | 125 + .../negative_test/input/hot-nimbus-psm_v1.0.env | 10 + .../negative_test/input/hot-nimbus-psm_v1.0.yaml | 207 + .../negative_test/input/nested-pps_v1.0.yaml | 103 + .../negative_test/input/nested-psm_v1.0.yaml | 103 + .../expected_output/expected_output.json | 1 + .../positive_test/input/MANIFEST.json | 17 + .../positive_test/input/hot-nimbus-psm_v1.0.env | 10 + .../positive_test/input/hot-nimbus-psm_v1.0.yaml | 50 + .../manifestValidator/envInRoot/MANIFEST.json | 22 + .../manifestValidator/envInRoot/first.env | 0 .../manifestValidator/envInRoot/first.yaml | 14 + .../manifestValidator/envInRoot/second.env | 0 .../invalidFileTypeInManifest/MANIFEST.json | 24 + .../invalidFileTypeInManifest/illegalTypeFile.yaml | 0 .../single.env.illegalSuffix | 0 .../single.yaml.illegalSuffix | 0 .../singleVol.yaml.illegalSuffix | 0 .../invalidManifest/MANIFEST.json | 21 + .../manifestValidator/invalidManifest/single.env | 0 .../manifestValidator/invalidManifest/single.yaml | 0 .../invalidManifest/singleVol.yaml | 0 .../missingFileInManifest/MANIFEST.json | 22 + .../missingFileInManifest/extraFile.env | 0 .../missingFileInManifest/single.env | 0 .../missingFileInManifest/single.yaml | 0 .../missingFileInManifest/singleVol.yaml | 0 .../missingFileInManifestAndInZip/MANIFEST.json | 21 + .../missingFileInManifestAndInZip/extraFile.env | 0 .../missingFileInManifestAndInZip/single.env | 0 .../missingFileInManifestAndInZip/single.yaml | 0 .../missingFileInZip/MANIFEST.json | 21 + .../manifestValidator/missingFileInZip/single.env | 0 .../manifestValidator/missingFileInZip/single.yaml | 0 .../manifestValidator/validFiles/MANIFEST.json | 21 + .../manifestValidator/validFiles/single.env | 0 .../manifestValidator/validFiles/single.yaml | 0 .../manifestValidator/validFiles/singleVol.yaml | 0 .../validators/yaml_validator/duplicateKey.yaml | 30 + .../validators/yaml_validator/emptyYaml.yaml | 0 .../yaml_validator/invalidTabYamlStructure.yaml | 24 + .../yaml_validator/invalidYamlStructure.yaml | 30 + .../input/MANIFEST.json | 39 + .../input/heat_missing_from_manifast.yaml | 250 + .../input/mainValid.yaml | 250 + .../input/validHeat.yaml | 250 + .../expected_output/expected_output.json | 46 + .../input/MANIFEST.json | 39 + .../input/heat_missing_from_manifast.yaml | 250 + .../input/invalidYamlTab.yaml | 250 + .../invalid_additionalSpaceBeforeProperty.yaml | 250 + .../input/invalid_duplicateKey.yaml | 25 + .../input/invalid_empty.yml | 0 .../input/invalid_yamlInXMLFormat.yaml | 4 + .../input/validHeat.yaml | 250 + .../yaml_validator/valid_yaml/input/MANIFEST.json | 39 + .../input/heat_missing_from_manifast.yaml | 250 + .../yaml_validator/valid_yaml/input/mainValid.yaml | 250 + .../yaml_validator/valid_yaml/input/validHeat.yaml | 250 + .../validators/yaml_validator/input/MANIFEST.json | 39 + .../input/heat_missing_from_manifast.yaml | 250 + .../validators/yaml_validator/input/mainValid.yaml | 250 + .../validators/yaml_validator/input/validHeat.yaml | 250 + .../lib/openecomp-sdc-validation-lib/pom.xml | 38 + .../openecomp-sdc-vendor-license-api/pom.xml | 57 + .../sdc/vendorlicense/HealingServiceFactory.java | 32 + .../VendorLicenseArtifactServiceFactory.java | 33 + .../sdc/vendorlicense/VendorLicenseConstants.java | 43 + .../sdc/vendorlicense/dao/EntitlementPoolDao.java | 38 + .../dao/EntitlementPoolDaoFactory.java | 31 + .../sdc/vendorlicense/dao/FeatureGroupDao.java | 47 + .../vendorlicense/dao/FeatureGroupDaoFactory.java | 31 + .../sdc/vendorlicense/dao/LicenseAgreementDao.java | 40 + .../dao/LicenseAgreementDaoFactory.java | 31 + .../sdc/vendorlicense/dao/LicenseKeyGroupDao.java | 34 + .../dao/LicenseKeyGroupDaoFactory.java | 32 + .../vendorlicense/dao/VendorLicenseModelDao.java | 29 + .../dao/VendorLicenseModelDaoFactory.java | 32 + .../dao/types/AggregationFunction.java | 27 + .../sdc/vendorlicense/dao/types/ChoiceOrOther.java | 154 + .../vendorlicense/dao/types/EntitlementMetric.java | 37 + .../dao/types/EntitlementPoolEntity.java | 370 + .../vendorlicense/dao/types/EntitlementTime.java | 30 + .../dao/types/FeatureGroupEntity.java | 203 + .../vendorlicense/dao/types/FeatureGroupModel.java | 75 + .../dao/types/LicenseAgreementEntity.java | 182 + .../dao/types/LicenseAgreementModel.java | 45 + .../dao/types/LicenseKeyGroupEntity.java | 231 + .../vendorlicense/dao/types/LicenseKeyType.java | 27 + .../sdc/vendorlicense/dao/types/LicenseTerm.java | 28 + .../dao/types/MultiChoiceOrOther.java | 172 + .../vendorlicense/dao/types/OperationalScope.java | 32 + .../sdc/vendorlicense/dao/types/ThresholdUnit.java | 26 + .../dao/types/VendorLicenseModelEntity.java | 153 + .../dao/types/xml/AggregationFunctionForXml.java | 33 + .../dao/types/xml/EntitlementMetricForXml.java | 33 + .../dao/types/xml/EntitlementTimeForXml.java | 33 + .../dao/types/xml/LicenseKeyTypeForXml.java | 33 + .../dao/types/xml/ThresholdForXml.java | 42 + .../sdc/vendorlicense/errors/JsonErrorBuilder.java | 51 + .../errors/LicensingDataInvalidErrorBuilder.java | 49 + .../SubmitUncompletedLicenseModelErrorBuilder.java | 50 + .../errors/VendorLicenseErrorCodes.java | 28 + .../VendorLicenseModelNotFoundErrorBuilder.java | 48 + .../vendorlicense/facade/VendorLicenseFacade.java | 89 + .../facade/VendorLicenseFacadeFactory.java | 32 + .../sdc/vendorlicense/healing/HealingService.java | 31 + .../VendorLicenseArtifactsService.java | 32 + .../types/VersionedVendorLicenseModel.java | 54 + .../src/main/resources/factoryConfiguration.json | 11 + .../openecomp-sdc-vendor-license-core/pom.xml | 48 + .../SimpleHealingServiceServiceFactoryImpl.java | 34 + .../VendorLicenseArtifactServiceFactoryImpl.java | 34 + .../dao/impl/EntitlementPoolCassandraDaoImpl.java | 148 + .../dao/impl/EntitlementPoolDaoFactoryImpl.java | 33 + .../dao/impl/FeatureGroupCassandraDaoImpl.java | 206 + .../dao/impl/FeatureGroupDaoFactoryImpl.java | 33 + .../dao/impl/LicenseAgreementCassandraDaoImpl.java | 160 + .../dao/impl/LicenseAgreementDaoFactoryImpl.java | 33 + .../dao/impl/LicenseKeyGroupCassandraDaoImpl.java | 130 + .../dao/impl/LicenseKeyGroupDaoFactoryImpl.java | 33 + .../impl/VendorLicenseModelCassandraDaoImpl.java | 91 + .../dao/impl/VendorLicenseModelDaoFactoryImpl.java | 34 + .../impl/VendorLicenseFacadeFactoryImpl.java | 33 + .../facade/impl/VendorLicenseFacadeImpl.java | 478 + .../healing/impl/SimpleHealingServiceImpl.java | 63 + .../impl/VendorLicenseArtifactsServiceImpl.java | 200 + .../impl/types/FeatureGroupForArtifact.java | 60 + .../impl/types/VendorLicenseArtifact.java | 80 + .../impl/types/VnfLicenseArtifact.java | 97 + .../licenseartifacts/impl/types/XmlArtifact.java | 54 + ...itlementPoolEntityForVendorLicenseArtifact.java | 100 + .../MixinEntitlementPoolEntityForVnfArtifact.java | 100 + .../impl/types/mixins/MixinFeatureGroupEntity.java | 62 + .../impl/types/mixins/MixinFeatureGroupModel.java | 61 + ...enseKeyGroupEntityForVendorLicenseArtifact.java | 72 + .../MixinLicenseKeyGroupEntityForVnfArtifact.java | 74 + .../lib/openecomp-sdc-vendor-license-lib/pom.xml | 24 + .../pom.xml | 63 + .../VendorSoftwareProductConstants.java | 38 + .../dao/ComponentArtifactDao.java | 40 + .../dao/ComponentArtifactDaoFactory.java | 32 + .../vendorsoftwareproduct/dao/ComponentDao.java | 38 + .../dao/ComponentDaoFactory.java | 31 + .../sdc/vendorsoftwareproduct/dao/NetworkDao.java | 33 + .../dao/NetworkDaoFactory.java | 31 + .../sdc/vendorsoftwareproduct/dao/NicDao.java | 40 + .../vendorsoftwareproduct/dao/NicDaoFactory.java | 31 + .../vendorsoftwareproduct/dao/PackageInfoDao.java | 33 + .../dao/PackageInfoDaoFactory.java | 31 + .../dao/ProcessArtifactDao.java | 32 + .../dao/ProcessArtifactDaoFactory.java | 32 + .../sdc/vendorsoftwareproduct/dao/ProcessDao.java | 30 + .../dao/ProcessDaoFactory.java | 31 + .../vendorsoftwareproduct/dao/UploadDataDao.java | 34 + .../dao/UploadDataDaoFactory.java | 31 + .../dao/VendorSoftwareProductDao.java | 140 + .../dao/VendorSoftwareProductDaoFactory.java | 34 + .../dao/VendorSoftwareProductInfoDao.java | 30 + .../dao/VendorSoftwareProductInfoDaoFactory.java | 32 + .../dao/VspQuestionnaireDao.java | 32 + .../dao/VspQuestionnaireDaoFactory.java | 32 + .../sdc/vendorsoftwareproduct/dao/type/Action.java | 27 + .../dao/type/ComponentArtifactEntity.java | 140 + .../dao/type/ComponentEntity.java | 199 + .../dao/type/CompositionEntity.java | 40 + .../dao/type/NetworkEntity.java | 183 + .../vendorsoftwareproduct/dao/type/NicEntity.java | 203 + .../dao/type/PackageInfo.java | 176 + .../dao/type/ProcessArtifactEntity.java | 128 + .../dao/type/ProcessEntity.java | 179 + .../dao/type/TranslatedFileData.java | 97 + .../dao/type/UploadDataEntity.java | 135 + .../vendorsoftwareproduct/dao/type/VspDetails.java | 242 + .../dao/type/VspQuestionnaireEntity.java | 111 + .../types/composition/Component.java | 44 + .../types/composition/ComponentData.java | 80 + .../types/composition/CompositionData.java | 44 + .../types/composition/CompositionDataEntity.java | 24 + .../types/composition/CompositionEntityId.java | 64 + .../types/composition/CompositionEntityType.java | 28 + .../types/composition/Network.java | 67 + .../types/composition/NetworkType.java | 26 + .../types/composition/Nic.java | 102 + .../src/main/resources/factoryConfiguration.json | 14 + .../pom.xml | 67 + .../impl/ComponentArtifactDaoCassandraImpl.java | 159 + .../dao/impl/ComponentArtifactDaoFactoryImpl.java | 33 + .../dao/impl/ComponentDaoCassandraImpl.java | 139 + .../dao/impl/ComponentDaoFactoryImpl.java | 33 + .../dao/impl/NetworkDaoCassandraImpl.java | 127 + .../dao/impl/NetworkDaoFactoryImpl.java | 33 + .../dao/impl/NicDaoCassandraImpl.java | 148 + .../dao/impl/NicDaoFactoryImpl.java | 33 + .../dao/impl/PackageInfoDaoFactoryImpl.java | 33 + .../dao/impl/PackageInfoDaoImpl.java | 103 + .../dao/impl/ProcessArtifactDaoCassandraImpl.java | 82 + .../dao/impl/ProcessArtifactDaoFactoryImpl.java | 33 + .../dao/impl/ProcessDaoCassandraImpl.java | 139 + .../dao/impl/ProcessDaoFactoryImpl.java | 33 + .../dao/impl/UploadDataDaoFactoryImpl.java | 33 + .../dao/impl/UploadDataDaoImpl.java | 92 + .../impl/VendorSoftwareProductDaoFactoryImpl.java | 33 + .../dao/impl/VendorSoftwareProductDaoImpl.java | 349 + .../VendorSoftwareProductInfoDaoFactoryImpl.java | 34 + .../dao/impl/VendorSoftwareProductInfoDaoImpl.java | 83 + .../dao/impl/VspQuestionnaireDaoCassandraImpl.java | 72 + .../dao/impl/VspQuestionnaireDaoFactoryImpl.java | 33 + .../dao/ServiceModelDaoFactoryTest.java | 97 + .../pom.xml | 23 + .../openecomp-sdc-versioning-api/pom.xml | 71 + .../sdc/versioning/VersioningManager.java | 57 + .../sdc/versioning/VersioningManagerFactory.java | 31 + .../openecomp/sdc/versioning/VersioningUtil.java | 187 + .../sdc/versioning/dao/VersionHistoryDao.java | 27 + .../versioning/dao/VersionHistoryDaoFactory.java | 30 + .../sdc/versioning/dao/VersionInfoDao.java | 28 + .../sdc/versioning/dao/VersionInfoDaoFactory.java | 30 + .../sdc/versioning/dao/VersionInfoDeletedDao.java | 29 + .../dao/VersionInfoDeletedDaoFactory.java | 32 + .../sdc/versioning/dao/VersionableDao.java | 25 + .../sdc/versioning/dao/VersionableEntityDao.java | 34 + .../dao/VersionableEntityDaoFactory.java | 31 + .../versioning/dao/types/UserCandidateVersion.java | 56 + .../sdc/versioning/dao/types/Version.java | 119 + .../versioning/dao/types/VersionHistoryEntity.java | 90 + .../dao/types/VersionInfoDeletedEntity.java | 126 + .../versioning/dao/types/VersionInfoEntity.java | 126 + .../sdc/versioning/dao/types/VersionStatus.java | 28 + .../sdc/versioning/dao/types/VersionType.java | 26 + .../versioning/dao/types/VersionableEntity.java | 43 + .../versioning/dao/types/VersionableEntityId.java | 53 + .../CheckinOnEntityLockedByOtherErrorBuilder.java | 52 + .../CheckinOnUnlockedEntityErrorBuilder.java | 46 + .../errors/CheckoutOnLockedEntityErrorBuilder.java | 51 + .../errors/DeleteOnLockedEntityErrorBuilder.java | 49 + .../EditOnEntityLockedByOtherErrorBuilder.java | 50 + .../errors/EditOnUnlockedEntityErrorBuilder.java | 48 + .../errors/EntityAlreadyExistErrorBuilder.java | 46 + .../errors/EntityAlreadyFinalizedErrorBuilder.java | 51 + .../errors/EntityNotExistErrorBuilder.java | 46 + .../RequestedVersionInvalidErrorBuilder.java | 40 + .../SubmitLockedEntityNotAllowedErrorBuilder.java | 49 + ...oCheckoutOnEntityLockedByOtherErrorBuilder.java | 53 + .../UndoCheckoutOnUnlockedEntityErrorBuilder.java | 50 + .../VersionableSubEntityNotFoundErrorBuilder.java | 77 + .../versioning/errors/VersioningErrorCodes.java | 43 + .../sdc/versioning/types/UniqueValueMetadata.java | 49 + .../sdc/versioning/types/VersionInfo.java | 97 + .../versioning/types/VersionableEntityAction.java | 26 + .../types/VersionableEntityMetadata.java | 78 + .../src/main/resources/factoryConfiguration.json | 7 + .../openecomp-sdc-versioning-core/pom.xml | 61 + .../dao/impl/VersionHistoryCassandraDaoImpl.java | 69 + .../dao/impl/VersionHistoryDaoFactoryImpl.java | 33 + .../dao/impl/VersionInfoDaoFactoryImpl.java | 33 + .../versioning/dao/impl/VersionInfoDaoImpl.java | 66 + .../dao/impl/VersionInfoDeletedDaoFactoryImpl.java | 34 + .../dao/impl/VersionInfoDeletedDaoImpl.java | 65 + .../impl/VersionableEntityDaoCassandraImpl.java | 159 + .../dao/impl/VersionableEntityDaoFactoryImpl.java | 33 + .../impl/VersioningManagerFactoryImpl.java | 33 + .../sdc/versioning/impl/VersioningManagerImpl.java | 468 + .../sdc/versioning/VersioningManagerTest.java | 364 + .../lib/openecomp-sdc-versioning-lib/pom.xml | 23 + openecomp-be/lib/openecomp-tosca-lib/pom.xml | 66 + .../sdc/tosca/datatypes/ToscaArtifactType.java | 39 + .../sdc/tosca/datatypes/ToscaCapabilityType.java | 52 + .../sdc/tosca/datatypes/ToscaDataType.java | 84 + .../sdc/tosca/datatypes/ToscaElementTypes.java | 25 + .../sdc/tosca/datatypes/ToscaFunctions.java | 43 + .../sdc/tosca/datatypes/ToscaGroupType.java | 40 + .../sdc/tosca/datatypes/ToscaNodeType.java | 162 + .../sdc/tosca/datatypes/ToscaPolicyType.java | 43 + .../sdc/tosca/datatypes/ToscaRelationshipType.java | 44 + .../sdc/tosca/datatypes/ToscaServiceModel.java | 72 + .../tosca/datatypes/model/ArtifactDefinition.java | 69 + .../sdc/tosca/datatypes/model/ArtifactType.java | 83 + .../tosca/datatypes/model/AttributeDefinition.java | 85 + .../datatypes/model/CapabilityAssignment.java | 45 + .../datatypes/model/CapabilityDefinition.java | 113 + .../model/CapabilityFilterDefinition.java | 35 + .../sdc/tosca/datatypes/model/CapabilityType.java | 82 + .../sdc/tosca/datatypes/model/Constraint.java | 181 + .../sdc/tosca/datatypes/model/DataType.java | 73 + .../sdc/tosca/datatypes/model/Directive.java | 40 + .../sdc/tosca/datatypes/model/EntrySchema.java | 65 + .../sdc/tosca/datatypes/model/GroupDefinition.java | 64 + .../sdc/tosca/datatypes/model/GroupType.java | 82 + .../sdc/tosca/datatypes/model/Import.java | 61 + .../tosca/datatypes/model/InterfaceDefinition.java | 24 + .../sdc/tosca/datatypes/model/InterfaceType.java | 24 + .../sdc/tosca/datatypes/model/Metadata.java | 55 + .../sdc/tosca/datatypes/model/NodeFilter.java | 47 + .../sdc/tosca/datatypes/model/NodeTemplate.java | 127 + .../sdc/tosca/datatypes/model/NodeType.java | 125 + .../tosca/datatypes/model/ParameterDefinition.java | 99 + .../tosca/datatypes/model/PolicyDefinition.java | 63 + .../sdc/tosca/datatypes/model/PolicyType.java | 73 + .../tosca/datatypes/model/PropertyDefinition.java | 112 + .../sdc/tosca/datatypes/model/PropertyType.java | 117 + .../datatypes/model/RelationshipTemplate.java | 99 + .../tosca/datatypes/model/RelationshipType.java | 93 + .../datatypes/model/RequirementAssignment.java | 70 + .../datatypes/model/RequirementDefinition.java | 82 + .../sdc/tosca/datatypes/model/Scalar.java | 34 + .../sdc/tosca/datatypes/model/ServiceTemplate.java | 144 + .../sdc/tosca/datatypes/model/Status.java | 42 + .../tosca/datatypes/model/SubstitutionMapping.java | 54 + .../sdc/tosca/datatypes/model/Template.java | 24 + .../tosca/datatypes/model/TopologyTemplate.java | 114 + .../model/heatextend/ParameterDefinitionExt.java | 55 + .../model/heatextend/PropertyTypeExt.java | 85 + .../InvalidAddActionNullEntityErrorBuilder.java | 58 + .../InvalidRequirementAssignmentErrorBuilder.java | 57 + .../sdc/tosca/errors/ToscaErrorCodes.java | 36 + .../ToscaInvalidEntryNotFoundErrorBuilder.java | 55 + ...aInvalidSubstituteNodeTemplateErrorBuilder.java | 55 + ...bstituteNodeTemplatePropertiesErrorBuilder.java | 59 + ...lidSubstitutionServiceTemplateErrorBuilder.java | 57 + ...ngSubstitutionMappingForReqCapErrorBuilder.java | 88 + .../errors/ToscaNodeTypeNotFoundErrorBuilder.java | 46 + .../tosca/exceptions/CsarCreationErrorBuilder.java | 43 + .../CsarMissingEntryPointErrorBuilder.java | 44 + .../sdc/tosca/services/DataModelUtil.java | 588 + .../sdc/tosca/services/ToscaAnalyzerService.java | 66 + .../sdc/tosca/services/ToscaConstants.java | 65 + .../sdc/tosca/services/ToscaFileOutputService.java | 34 + .../services/ToscaNativeTypesServiceTemplate.java | 309 + .../openecomp/sdc/tosca/services/ToscaUtil.java | 151 + .../services/impl/ToscaAnalyzerServiceImpl.java | 467 + .../impl/ToscaFileOutputServiceCsarImpl.java | 158 + .../services/yamlutil/ToscaExtensionYamlUtil.java | 93 + .../java/org/openecomp/sdc/tosca/TestUtil.java | 71 + .../sdc/tosca/datatypes/PropertyTypeTest.java | 20 + .../sdc/tosca/datatypes/ToscaModelTest.java | 282 + .../datatypes/model/CapabilityDefinitionTest.java | 101 + .../datatypes/model/RequirementDefinitionTest.java | 40 + .../sdc/tosca/services/DataModelUtilTest.java | 104 + .../impl/ToscaAnalyzerServiceImplTest.java | 472 + .../impl/ToscaFileOutputServiceCsarImplTest.java | 150 + .../NestedServiceTemplateReqTest.yaml | 176 + .../ServiceTemplateSubstituteTest.yaml | 89 + .../toscasubstitution/MainServiceTemplate.yaml | 75 + .../toscasubstitution/nestedServiceTemplate.yaml | 130 + ...stractSubstituteGlobalTypesServiceTemplate.yaml | 47 + .../CinderVolumeGlobalTypesServiceTemplate.yaml | 176 + .../CommonGlobalTypesServiceTemplate.yaml | 210 + ...ntrailNetworkRuleGlobalTypeServiceTemplate.yaml | 117 + ...ailVirtualNetworkGlobalTypeServiceTemplate.yaml | 71 + .../GlobalSubstitutionTypesServiceTemplate.yaml | 93 + .../NativeTypesServiceTemplateServiceTemplate.yaml | 194 + .../NeutronNetGlobalTypesServiceTemplate.yaml | 97 + .../NeutronPortGlobalTypesServiceTemplate.yaml | 151 + ...ronSecurityRulesGlobalTypesServiceTemplate.yaml | 116 + .../NovaServerGlobalTypesServiceTemplate.yaml | 249 + .../test/resources/mock/model/serviceTemplate.yaml | 116 + .../mock/model/serviceTemplateHeatExtend.yaml | 117 + openecomp-be/lib/pom.xml | 30 + openecomp-be/logs/ASDC/Debug.1.log.zip | Bin 0 -> 146911 bytes openecomp-be/logs/ASDC/Debug.2.log.zip | Bin 0 -> 130246 bytes openecomp-be/logs/ASDC/Debug.3.log.zip | Bin 0 -> 158231 bytes openecomp-be/logs/ASDC/Debug.4.log.zip | Bin 0 -> 149071 bytes openecomp-be/logs/ASDC/Debug.5.log.zip | Bin 0 -> 150749 bytes openecomp-be/logs/ASDC/Debug.6.log.zip | Bin 0 -> 168721 bytes openecomp-be/pom.xml | 158 + openecomp-be/readMe.txt | 42 + .../action_library_client/action_library_client.py | 704 + .../scripts/action_library_client/doc/TESTPLAN.TXT | 10 + .../test/scenarios/Backout.json | 45 + .../test/scenarios/Copy_image.json | 45 + .../test/scenarios/Healthcheck.json | 45 + .../test/scenarios/Reboot.json | 45 + .../scripts/action_library_client/test/seq.txt | 1 + .../test/test_action_library_client.py | 154 + .../test/test_action_library_client_integration.py | 329 + .../tools/build/scripts/cassandra-commands.json | 76 + .../generate-application-config-insert-cql.sh | 64 + .../build/scripts/generate-cassandra-alter-cql.sh | 40 + .../build/scripts/generate-cassandra-drop-cql.sh | 40 + .../build/scripts/generate-cassandra-init-cql.sh | 44 + openecomp-be/tools/build/scripts/parse-json.py | 83 + .../database/monitoring/component/ceilometer.ftl | 67 + .../schemaTemplates/composition/component.ftl | 28 + .../schemaTemplates/composition/network.ftl | 25 + .../database/schemaTemplates/composition/nic.ftl | 36 + .../schemaTemplates/questionnaire/component.ftl | 327 + .../database/schemaTemplates/questionnaire/nic.ftl | 120 + .../database/schemaTemplates/questionnaire/vsp.ftl | 89 + openecomp-be/tools/migration/1607_to_1610.py | 281 + openecomp-be/tools/migration/README | 88 + openecomp-be/tools/scripts/generate-manifest.py | 435 + .../tools/swagger-ui/WEB-INF/jetty-web.xml | 8 + openecomp-be/tools/swagger-ui/api-docs/api.html | 13140 ++++++++ openecomp-be/tools/swagger-ui/api-docs/api.json | 4676 +++ openecomp-be/tools/swagger-ui/assembly/swagger.xml | 76 + openecomp-be/tools/swagger-ui/css/ncso-style.css | 8659 +++++ openecomp-be/tools/swagger-ui/css/print.css | 1175 + openecomp-be/tools/swagger-ui/css/reset.css | 125 + openecomp-be/tools/swagger-ui/css/screen.css | 1282 + openecomp-be/tools/swagger-ui/css/style.css | 250 + openecomp-be/tools/swagger-ui/css/typography.css | 26 + .../swagger-ui/fonts/droid-sans-v6-latin-700.eot | Bin 0 -> 22922 bytes .../swagger-ui/fonts/droid-sans-v6-latin-700.svg | 411 + .../swagger-ui/fonts/droid-sans-v6-latin-700.ttf | Bin 0 -> 40513 bytes .../swagger-ui/fonts/droid-sans-v6-latin-700.woff | Bin 0 -> 25992 bytes .../swagger-ui/fonts/droid-sans-v6-latin-700.woff2 | Bin 0 -> 11480 bytes .../fonts/droid-sans-v6-latin-regular.eot | Bin 0 -> 22008 bytes .../fonts/droid-sans-v6-latin-regular.svg | 403 + .../fonts/droid-sans-v6-latin-regular.ttf | Bin 0 -> 39069 bytes .../fonts/droid-sans-v6-latin-regular.woff | Bin 0 -> 24868 bytes .../fonts/droid-sans-v6-latin-regular.woff2 | Bin 0 -> 11304 bytes openecomp-be/tools/swagger-ui/images/Thumbs.db | Bin 0 -> 6656 bytes .../tools/swagger-ui/images/explorer_icons.png | Bin 0 -> 5763 bytes .../tools/swagger-ui/images/favicon-16x16.png | Bin 0 -> 645 bytes .../tools/swagger-ui/images/favicon-32x32.png | Bin 0 -> 1654 bytes openecomp-be/tools/swagger-ui/images/favicon.ico | Bin 0 -> 1150 bytes .../tools/swagger-ui/images/logo_small.png | Bin 0 -> 770 bytes .../tools/swagger-ui/images/pet_store_api.png | Bin 0 -> 824 bytes openecomp-be/tools/swagger-ui/images/throbber.gif | Bin 0 -> 9257 bytes .../tools/swagger-ui/images/wordnik_api.png | Bin 0 -> 980 bytes openecomp-be/tools/swagger-ui/index.html | 328 + openecomp-be/tools/swagger-ui/lang/en.js | 73 + openecomp-be/tools/swagger-ui/lang/es.js | 72 + openecomp-be/tools/swagger-ui/lang/ja.js | 73 + openecomp-be/tools/swagger-ui/lang/pt.js | 73 + openecomp-be/tools/swagger-ui/lang/ru.js | 72 + openecomp-be/tools/swagger-ui/lang/tr.js | 73 + openecomp-be/tools/swagger-ui/lang/translator.js | 59 + openecomp-be/tools/swagger-ui/lang/zh-cn.js | 73 + openecomp-be/tools/swagger-ui/lib/backbone-min.js | 35 + .../tools/swagger-ui/lib/handlebars-2.0.0.js | 48 + .../tools/swagger-ui/lib/highlight.7.3.pack.js | 21 + .../tools/swagger-ui/lib/jquery-1.8.0.min.js | 22 + .../tools/swagger-ui/lib/jquery.ba-bbq.min.js | 38 + .../tools/swagger-ui/lib/jquery.slideto.min.js | 21 + .../tools/swagger-ui/lib/jquery.wiggle.min.js | 28 + openecomp-be/tools/swagger-ui/lib/marked.js | 1292 + openecomp-be/tools/swagger-ui/lib/swagger-oauth.js | 310 + .../tools/swagger-ui/lib/underscore-min.js | 26 + .../tools/swagger-ui/lib/underscore-min.map | 1 + openecomp-be/tools/swagger-ui/o2c.html | 20 + openecomp-be/tools/swagger-ui/pom.xml | 77 + openecomp-be/tools/swagger-ui/swagger-ui.js | 32311 +++++++++++++++++++ openecomp-be/tools/swagger-ui/swagger-ui.min.js | 32 + openecomp-be/tools/test.push | 1 + pom.xml | 2 +- .../sdc-normatives/files/default/normatives.tar.gz | Bin 49376 -> 49377 bytes 2148 files changed, 290537 insertions(+), 1 deletion(-) create mode 100644 openecomp-be/.gitignore create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/action-library-rest-services/pom.xml create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/action-library-rest-services/src/main/java/org/openecomp/sdcrests/action/rest/Actions.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/action-library-rest-services/src/main/java/org/openecomp/sdcrests/action/rest/mapping/MapActionToActionResponseDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/action-library-rest-services/src/main/java/org/openecomp/sdcrests/action/rest/services/ActionsImpl.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/action-library-rest-types/pom.xml create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/action-library-rest-types/src/main/java/org/openecomp/sdcrests/action/types/ActionResponseDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/action-library-rest-types/src/main/java/org/openecomp/sdcrests/action/types/ActionVersionDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/action-library-rest-types/src/main/java/org/openecomp/sdcrests/action/types/ListResponseWrapper.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/pom.xml create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/application-config-rest-services/pom.xml create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/application-config-rest-services/src/main/java/org/openecomp/sdcrests/applicationconfig/rest/ApplicationConfiguration.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/application-config-rest-services/src/main/java/org/openecomp/sdcrests/applicationconfig/rest/mapping/MapApplicationConfigEntityToApplicationConfigDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/application-config-rest-services/src/main/java/org/openecomp/sdcrests/applicationconfig/rest/mapping/MapConfigurationDataToConfigurationDataDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/application-config-rest-services/src/main/java/org/openecomp/sdcrests/applicationconfig/rest/services/ApplicationConfigurationImpl.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/application-config-rest-types/pom.xml create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/application-config-rest-types/src/main/java/org/openecomp/sdcrests/applicationconfiguration/types/ApplicationConfigDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/application-config-rest-types/src/main/java/org/openecomp/sdcrests/applicationconfiguration/types/ConfigurationDataDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/pom.xml create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/pom.xml create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/java/org/openecomp/server/filters/ActionAuthenticationFilter.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/java/org/openecomp/server/filters/ActionAuthorizationFilter.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/java/org/openecomp/server/filters/ActionLibraryPrivilege.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/java/org/openecomp/server/interceptors/DefaultOutput.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/java/org/openecomp/server/interceptors/EmptyOutputOutInterceptor.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/java/org/openecomp/server/interceptors/InternalEmptyObject.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/java/org/openecomp/server/listeners/OnboardingAppStartupListener.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/resources/keyfile.txt create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/webapp/WEB-INF/beans-services.xml create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/webapp/WEB-INF/jetty-web.xml create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/webapp/WEB-INF/web.xml create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/templates/markdown.hbs create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/templates/operation.hbs create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/templates/security.hbs create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/templates/strapdown.html.hbs create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/pom.xml create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/common/RestConstants.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/common/mapping/MapErrorCodeToDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/common/mapping/MapErrorMessageToDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/common/types/ErrorCodeDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/common/types/ErrorMessageDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/errors/DefaultExceptionMapper.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/mapping/MappingBase.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/versioning/types/VersioningAction.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/wrappers/GenericCollectionWrapper.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/wrappers/StringWrapperResponse.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/resources/errorCodesToResponseStatusMapping.json create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/pom.xml create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/sequence-rest/pom.xml create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/sequence-rest/src/main/java/org/openecomp/sdcrests/service/rest/Service.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/sequence-rest/src/main/java/org/openecomp/sdcrests/service/rest/services/ServiceImpl.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/validation-rest/pom.xml create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/validation-rest/validation-rest-services/pom.xml create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/validation-rest/validation-rest-services/src/main/java/org/openecomp/sdcrests/validation/rest/Validation.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/validation-rest/validation-rest-services/src/main/java/org/openecomp/sdcrests/validation/rest/mapping/MapValidationFileResponseToValidationFileResponseDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/validation-rest/validation-rest-services/src/main/java/org/openecomp/sdcrests/validation/rest/services/ValidationImpl.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/validation-rest/validation-rest-types/pom.xml create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/validation-rest/validation-rest-types/src/main/java/org/openecomp/sdcrests/validation/types/ValidationFileResponseDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/pom.xml create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/pom.xml create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/EntitlementPools.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/FeatureGroups.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/LicenseAgreements.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/LicenseKeyGroups.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/VendorLicenseModels.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapChoiceOrOtherDtoToChoiceOrOther.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapChoiceOrOtherToChoiceOrOtherDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapEntitlementPoolEntityToEntitlementPoolEntityDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapEntitlementPoolRequestDtoToEntitlementPoolEntity.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapFeatureGroupDescriptorDtoToFeatureGroupEntity.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapFeatureGroupEntityToFeatureGroupDescriptorDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapLicenseAgreementDescriptorDtoToLicenseAgreementEntity.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapLicenseAgreementEntityToLicenseAgreementDescriptorDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapLicenseKeyGroupEntityToLicenseKeyGroupEntityDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapLicenseKeyGroupRequestDtoToLicenseKeyGroupEntity.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapMultiChoiceOrOtherDtoToMultiChoiceOrOther.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapMultiChoiceOrOtherToMultiChoiceOrOtherDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapVendorLicenseModelRequestDtoToVendorLicenseModelEntity.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapVersionedVendorLicenseModelToVendorLicenseModelEntityDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/services/EntitlementPoolsImpl.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/services/FeatureGroupsImpl.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/services/LicenseAgreementsImpl.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/services/LicenseKeyGroupsImpl.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/services/VendorLicenseModelsImpl.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/pom.xml create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/ChoiceOrOtherDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/EntitlementPoolEntityDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/EntitlementPoolRequestDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/FeatureGroupDescriptorDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/FeatureGroupEntityDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/FeatureGroupModelDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/FeatureGroupRequestDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/FeatureGroupUpdateRequestDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/LicenseAgreementDescriptorDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/LicenseAgreementEntityDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/LicenseAgreementModelDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/LicenseAgreementRequestDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/LicenseAgreementUpdateRequestDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/LicenseKeyGroupEntityDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/LicenseKeyGroupRequestDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/MultiChoiceOrOtherDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/VendorLicenseModelActionRequestDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/VendorLicenseModelEntityDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/VendorLicenseModelRequestDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/validation/ChoiceOrOtherSequenceProvider.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/validation/MultiChoiceOrOtherSequenceProvider.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/validation/OtherChoiceValidation.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/pom.xml create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/pom.xml create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/ComponentProcesses.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/ComponentUploads.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/Components.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/Networks.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/Nics.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/Processes.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/VendorSoftwareProducts.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapComponentDataToComponentDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapComponentEntityToComponentDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapComponentRequestDtoToComponentEntity.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapCompositionEntityResponseToDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapCompositionEntityValidationDataToDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapMibUploadStatusToDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapNetworkEntityToNetworkDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapNetworkRequestDtoToNetworkEntity.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapNetworkToNetworkDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapNicEntityToNicDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapNicRequestDtoToNicEntity.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapNicToNicDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapPackageInfoToPackageInfoDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapProcessEntityToProcessEntityDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapProcessRequestDtoToProcessEntity.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapQuestionnaireResponseToQuestionnaireResponseDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapUploadFileResponseToUploadFileResponseDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapValidationResponseToDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapVersionedVendorSoftwareProductInfoToVspDetailsDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapVspDescriptionDtoToVspDetails.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MspVspDetailsToVspCreationDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/services/ComponentProcessesImpl.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/services/ComponentUploadsImpl.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/services/ComponentsImpl.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/services/NetworksImpl.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/services/NicsImpl.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/services/ProcessesImpl.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/services/VendorSoftwareProductsImpl.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/pom.xml create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/ComponentDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/ComponentRequestDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/CompositionDataEntityDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/CompositionEntityResponseDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/CompositionEntityValidationDataDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/MibUploadStatusDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/NetworkDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/NetworkRequestDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/NicDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/NicRequestDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/PackageInfoDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/ProcessEntityDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/ProcessRequestDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/QuestionnaireResponseDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/QuestionnaireValidationResultDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/TranslatedFileDataDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/UploadFileResponseDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/ValidationResponseDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/VendorSoftwareProductAction.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/VersionSoftwareProductActionRequestDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/VspCreationDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/VspDescriptionDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/VspDetailsDto.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/validation/CustomJsonValidator.java create mode 100644 openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/validation/IsValidJson.java create mode 100644 openecomp-be/api/pom.xml create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/pom.xml create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/src/main/java/org/openecomp/sdc/action/ActionManager.java create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/src/main/java/org/openecomp/sdc/action/impl/ActionManagerImpl.java create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/src/test/java/org/openecomp/sdc/action/ActionTest.java create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/src/test/resources/test_artifact_file.txt create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/src/test/resources/test_artifact_update_file.txt create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/test-output/Default suite/Default test.html create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/test-output/Default suite/Default test.xml create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/test-output/Default suite/testng-failed.xml create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/test-output/bullet_point.png create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/test-output/collapseall.gif create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/test-output/emailable-report.html create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/test-output/failed.png create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/test-output/index.html create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/test-output/jquery-1.7.1.min.js create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/test-output/junitreports/TEST-com.amdocs.asdc.action.ActionTest.xml create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/test-output/navigator-bullet.png create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/Default test.properties create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/classes.html create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/groups.html create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/index.html create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/main.html create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/methods-alphabetical.html create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/methods-not-run.html create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/methods.html create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/reporter-output.html create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/testng.xml.html create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/toc.html create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/index.html create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/test-output/passed.png create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/test-output/skipped.png create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/test-output/testng-failed.xml create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/test-output/testng-reports.css create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/test-output/testng-reports.js create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/test-output/testng-results.xml create mode 100644 openecomp-be/backend/openecomp-sdc-action-manager/test-output/testng.css create mode 100644 openecomp-be/backend/openecomp-sdc-application-config-manager/pom.xml create mode 100644 openecomp-be/backend/openecomp-sdc-application-config-manager/src/main/java/org/openecomp/sdc/applicationconfig/ApplicationConfigManager.java create mode 100644 openecomp-be/backend/openecomp-sdc-application-config-manager/src/main/java/org/openecomp/sdc/applicationconfig/impl/ApplicationConfigManagerImpl.java create mode 100644 openecomp-be/backend/openecomp-sdc-application-config-manager/src/test/java/org/openecomp/sdc/applicationconfig/ApplicationConfigManagerTest.java create mode 100644 openecomp-be/backend/openecomp-sdc-validation-manager/pom.xml create mode 100644 openecomp-be/backend/openecomp-sdc-validation-manager/src/main/java/org/openecomp/sdc/validation/UploadValidationManager.java create mode 100644 openecomp-be/backend/openecomp-sdc-validation-manager/src/main/java/org/openecomp/sdc/validation/errors/ValidationErrorCodes.java create mode 100644 openecomp-be/backend/openecomp-sdc-validation-manager/src/main/java/org/openecomp/sdc/validation/errors/ValidationInvalidErrorBuilder.java create mode 100644 openecomp-be/backend/openecomp-sdc-validation-manager/src/main/java/org/openecomp/sdc/validation/impl/UploadValidationManagerImpl.java create mode 100644 openecomp-be/backend/openecomp-sdc-validation-manager/src/main/java/org/openecomp/sdc/validation/types/ValidationFileResponse.java create mode 100644 openecomp-be/backend/openecomp-sdc-validation-manager/src/main/java/org/openecomp/sdc/validation/types/ValidationFileStatus.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-license-manager/pom.xml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/main/java/org/openecomp/sdc/vendorlicense/VendorLicenseManager.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/main/java/org/openecomp/sdc/vendorlicense/impl/VendorLicenseManagerImpl.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/test/java/org/openecomp/sdc/vendorlicense/ArtifactTestUtils.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/test/java/org/openecomp/sdc/vendorlicense/EntitlementPoolTest.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/test/java/org/openecomp/sdc/vendorlicense/FeatureGroupTest.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/test/java/org/openecomp/sdc/vendorlicense/LicenseAgreementTest.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/test/java/org/openecomp/sdc/vendorlicense/LicenseKeyGroupTest.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/test/java/org/openecomp/sdc/vendorlicense/VendorLicenseModelTest.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/test/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/VendorLicenseArtifactsServiceTest.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/pom.xml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/VendorSoftwareProductManager.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/CreatePackageForNonFinalVendorSoftwareProductErrorBuilder.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/FileCreationErrorBuilder.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/MibUploadErrorBuilder.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/PackageInvalidErrorBuilder.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/PackageNotFoundErrorBuilder.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/TranslationFileCreationErrorBuilder.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/UploadInvalidErrorBuilder.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/VendorSoftwareProductErrorCodes.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/VendorSoftwareProductInvalidErrorBuilder.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/VendorSoftwareProductNotFoundErrorBuilder.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/impl/VendorSoftwareProductManagerImpl.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/services/CompositionDataExtractor.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/services/CompositionEntityDataManager.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/services/SchemaGenerator.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/services/SchemaGeneratorConfig.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/CompositionEntityResponse.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/CompositionEntityValidationData.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/ExtractCompositionDataContext.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/LicensingData.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/QuestionnaireResponse.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/QuestionnaireValidationResult.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/UploadFileResponse.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/UploadFileStatus.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/UploadFileStructure.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/ValidationResponse.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/VersionedVendorSoftwareProductInfo.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/schemagenerator/ComponentCompositionSchemaInput.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/schemagenerator/ComponentQuestionnaireSchemaInput.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/schemagenerator/MibUploadStatus.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/schemagenerator/NetworkCompositionSchemaInput.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/schemagenerator/NicCompositionSchemaInput.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/schemagenerator/SchemaTemplateContext.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/schemagenerator/SchemaTemplateInput.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/util/CompilationUtil.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/util/VendorSoftwareProductUtils.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/ComponentProcessesTest.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/ComponentsTest.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/ComponentsUploadTest.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/NetworksTest.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/NicsTest.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/ProcessesTest.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/VSPCommon.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/VSPFullTest.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/VendorSoftwareProductManagerTest.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/services/CompositionDataExtractorTest.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/services/CompositionEntityDataManagerTest.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/services/QuestionnaireSchemaTest.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/services/QuestionnaireValidatorTest.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/services/SchemaGeneratorTest.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/tree/HeatTreeManagerTest.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/tree/TreeBaseTest.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/tree/UploadFileTest.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/upload/HeatCleanup/HeatCleanupOnNewUploadTest.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/upload/validation/UploadFileValidationTest.java create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/emptyComposition/MANIFEST.json create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/emptyComposition/ep-jsa_net.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/componentsWithPort/ComponentsWithPortST.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/fullComposition/MainServiceTemplate.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/networks/MainServiceTemplate.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/onlyComponents/OnlyComponentsST.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/substitution/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/substitution/MainServiceTemplate.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/substitution/nested1ServiceTemplate.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/substitution/nested2ServiceTemplate.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/AbstractSubstituteGlobalTypesServiceTemplate.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/CinderVolumeGlobalTypesServiceTemplate.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/CommonGlobalTypesServiceTemplate.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/ContrailNetworkRuleGlobalTypeServiceTemplate.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NativeTypesServiceTemplateServiceTemplate.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NeutronNetGlobalTypesServiceTemplate.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NeutronPortGlobalTypesServiceTemplate.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NeutronSecurityRulesGlobalTypesServiceTemplate.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NovaServerGlobalTypesServiceTemplate.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/fullComposition/MANIFEST.json create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/fullComposition/hot-mog-0108-bs1271.env create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/fullComposition/hot-mog-0108-bs1271.yml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/MANIFEST.json create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/MMSC_Capacity_Line.yml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/MMSC_Capacity_Line_1.env create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/SG_ECA_MGMT.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/cmaui.env create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/cmaui.yml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/eca_oam.env create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/eca_oam.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/eca_oam_2.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/sg_eca_mgmt.env create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload/MANIFEST.json create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload/create_stack.sh create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload/vmme_small_create_fsb.env create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload/vmme_small_create_fsb.yml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload2/MANIFEST.json create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload2/create_stack.sh create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload2/vmme_small.env create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload2/vmme_small.yml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload2/vmme_small_create_fsb.env create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload2/vmme_small_create_fsb.yml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/missingYml/MANIFEST.json create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/missingYml/create_stack.sh create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/missingYml/vmme_small_create_fsb.env create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/HEAT.meta create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/MANIFEST.json create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/cloud-nimbus.sh create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-oam-volumes_v1.0.env create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-oam-volumes_v1.0.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-oam_v1.0.env create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-oam_v1.0.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-pcm-volumes_v1.0.env create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-pcm-volumes_v1.0.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-pcm_v1.0.env create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-pcm_v1.0.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-ppd_v1.0.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-ppd_v1.1.env create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-pps_v1.0.env create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-psm_v1.0.env create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-psm_v1.0.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-swift-container_v1.0.env create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-swift-container_v1.0.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/mount_iso_script.sh create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/nested-oam_v1.0.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/nested-pcm_v1.0.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/nested-ppd_v1.0.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/nested-pps_v1.0.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/nested-psm_v1.0.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/nimbus-ethernet create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/nimbus-ethernet-gw create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/notZipFile create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/quesionnaire/invalidComponent.json create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/quesionnaire/invalidNic.json create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/quesionnaire/validComponent.json create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/quesionnaire/validNic.json create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/missing_manifest/input/heat_missing_from_manifast.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/missing_manifest/input/mainValid.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/missing_manifest/input/validHeat.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/nested_resource_group/MANIFEST.json create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/nested_resource_group/addOn.yml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/nested_resource_group/nested.yml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/nested_volume/MANIFEST.json create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/nested_volume/base_mobt.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/nested_volume/hot_mobt_volume_attach_nested.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/valid_tree/input/MANIFEST.json create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/valid_tree/input/heat_missing_from_manifast.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/valid_tree/input/mainValid.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/valid_tree/input/validHeat.yaml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/emptyZip.zip create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/missingManifestInZip.zip create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/710-ResourceGroup.zip create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/MMSC.zip create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/MNS OAM FW.zip create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/VOTA.zip create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/base_module_mns_oam.zip create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/cmd-frwl-v302.zip create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/noError/GWv12.zip create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/noError/MNS OAM FW fix.zip create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/noError/base_module_mns_oam_fixed.zip create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/noError/cmd-frwl-v302.zip create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/noError/vDBE_fix_with_warr.zip create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/noError/vDNS.zip create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/segw_heat_c3-base.zip create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/vDBE.zip create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/vDNS.zip create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/vDNS_21_8.zip create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/vProb.zip create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/vProbe_FE_081816.zip create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/vid_test_pcrf_base_template.zip create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/zipFileWithFolder.zip create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/vspmanager/zips/emptyComposition.zip create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/vspmanager/zips/emptyZip.zip create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/vspmanager/zips/fullComposition.zip create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/vspmanager/zips/invalidTypes.zip create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/vspmanager/zips/legalUpload.zip create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/vspmanager/zips/legalUpload2.zip create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/vspmanager/zips/missingYml.zip create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/vspmanager/zips/nimbus.zip create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/vspmanager/zips/vDNS.zip create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/vspmanager/zips/withoutManifest.zip create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/vspmanager/zips/zipFileWithFolder.zip create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/withNetwork/MANIFEST.json create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/withNetwork/hot-mog-0108-bs1271.env create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/withNetwork/hot-mog-0108-bs1271.yml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/withNetwork/network.yml create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/withNetwork/zip/withNetwork.zip create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/withoutManifest/create_stack.sh create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/withoutManifest/vmme_small_create_fsb.env create mode 100644 openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/withoutManifest/vmme_small_create_fsb.yml create mode 100644 openecomp-be/backend/pom.xml create mode 100644 openecomp-be/configuration/pom.xml create mode 100644 openecomp-be/lib/openecomp-common-lib/pom.xml create mode 100644 openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/errors/BaseErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/errors/CoreException.java create mode 100644 openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/errors/ErrorCategory.java create mode 100644 openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/errors/ErrorCode.java create mode 100644 openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/errors/ErrorCodeAndMessage.java create mode 100644 openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/errors/GeneralErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/errors/JsonMappingErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/errors/ValidationErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/utils/AsdcCommon.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/pom.xml create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/ApplicationConfig.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/ApplicationConfigFactory.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/dao/ApplicationConfigDao.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/dao/ApplicationConfigDaoFactory.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/dao/impl/ApplicationConfigDaoCassandraImpl.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/dao/impl/ApplicationConfigDaoFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/dao/type/ApplicationConfigEntity.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/impl/ApplicationConfigFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/impl/ApplicationConfigImpl.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/type/ConfigurationData.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/resources/factoryConfiguration.json create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/resources/logback.xml create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/test/java/org/openecomp/sdc/applicationconfig/dao/ApplicationConfigImplDaoTest.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/test/resources/questionnaire/testTemplate.txt create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-api/pom.xml create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-api/src/main/java/org/openecomp/core/factory/api/AbstractFactory.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-api/src/main/java/org/openecomp/core/factory/impl/AbstractFactoryBase.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-core/pom.xml create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-core/src/main/java/org/openecomp/core/factory/AbstractContextFactory.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-core/src/main/java/org/openecomp/core/factory/FactoriesConfigImpl.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-core/src/main/java/org/openecomp/core/factory/FactoryConfig.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-core/src/main/java/org/openecomp/core/factory/api/AbstractComponentFactory.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-core/src/main/java/org/openecomp/core/factory/api/FactoriesConfiguration.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/pom.xml create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/pom.xml create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/java/org/openecomp/core/dao/BaseDao.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/java/org/openecomp/core/dao/UniqueValueDao.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/java/org/openecomp/core/dao/UniqueValueDaoFactory.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/java/org/openecomp/core/dao/types/UniqueValueEntity.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/java/org/openecomp/core/nosqldb/api/NoSqlDb.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/java/org/openecomp/core/nosqldb/factory/NoSqlDbFactory.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/java/org/openecomp/core/util/UniqueValueUtil.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/resources/cassandraStatements.json create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/resources/factoryConfiguration.json create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/pom.xml create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/java/org/openecomp/core/dao/impl/CassandraBaseDao.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/java/org/openecomp/core/dao/impl/UniqueValueCassandraDaoImpl.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/java/org/openecomp/core/dao/impl/UniqueValueDaoFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/java/org/openecomp/core/nosqldb/impl/cassandra/CassandraNoSqlDbFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/java/org/openecomp/core/nosqldb/impl/cassandra/CassandraNoSqlDbImpl.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/java/org/openecomp/core/nosqldb/impl/cassandra/CassandraSessionFactory.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/java/org/openecomp/core/nosqldb/util/CassandraUtils.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/java/org/openecomp/core/nosqldb/util/ConfigurationManager.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/resources/configuration.yaml create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/test/java/org/openecomp/core/nosqldb/NoSqlDbTest.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/test/java/org/openecomp/core/utilities/Yaml/YamlUtilTest.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/test/java/org/openecomp/core/utilities/json/JsonUtilTest.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/test/java/testobjects/yaml/InnerP.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/test/java/testobjects/yaml/Parameter.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/test/java/testobjects/yaml/YamlFile.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/pom.xml create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/pom.xml create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/main/java/org/openecomp/core/utilities/CommonMethods.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/main/java/org/openecomp/core/utilities/file/FileContentHandler.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/main/java/org/openecomp/core/utilities/file/FileUtils.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/main/java/org/openecomp/core/utilities/json/JsonSchemaDataGenerator.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/main/java/org/openecomp/core/utilities/json/JsonUtil.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/main/java/org/openecomp/core/utilities/yaml/YamlUtil.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/test/java/org/openecomp/core/utilities/json/JsonSchemaDataGeneratorTest.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/test/java/org/openecomp/core/utilities/json/JsonUtilTest.java create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/test/resources/jsonUtil/json/a.json create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/test/resources/jsonUtil/json/a_invalid.json create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/test/resources/jsonUtil/json_schema/aSchema.json create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/test/resources/jsonUtil/json_schema/nicSchema.json create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/test/resources/jsonUtil/json_schema/schemaWithInvalidDefault.json create mode 100644 openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/test/resources/jsonUtil/json_schema/schemaWithRefsAndDefaults.json create mode 100644 openecomp-be/lib/openecomp-core-lib/pom.xml create mode 100644 openecomp-be/lib/openecomp-heat-lib/pom.xml create mode 100644 openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/DefinedHeatParameterTypes.java create mode 100644 openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/HeatBoolean.java create mode 100644 openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/manifest/FileData.java create mode 100644 openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/manifest/ManifestContent.java create mode 100644 openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/manifest/ManifestFile.java create mode 100644 openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/Constraint.java create mode 100644 openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/Environment.java create mode 100644 openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/GroupTypeValues.java create mode 100644 openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/HeatOrchestrationTemplate.java create mode 100644 openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/HeatPseudoParameters.java create mode 100644 openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/HeatResourcesTypes.java create mode 100644 openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/Output.java create mode 100644 openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/Parameter.java create mode 100644 openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/ParameterGroup.java create mode 100644 openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/ParameterType.java create mode 100644 openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/PolicyTypes.java create mode 100644 openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/PropertiesMapKeyTypes.java create mode 100644 openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/Resource.java create mode 100644 openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/ResourceReferenceFunctions.java create mode 100644 openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/ResourceTypeToMessageString.java create mode 100644 openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/structure/Artifact.java create mode 100644 openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/structure/HeatStructureTree.java create mode 100644 openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/structure/ValidationStructureList.java create mode 100644 openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/services/ErrorCodes.java create mode 100644 openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/services/HeatConstants.java create mode 100644 openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/services/HeatStructureUtil.java create mode 100644 openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/services/manifest/ManifestUtil.java create mode 100644 openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/services/tree/HeatTreeManager.java create mode 100644 openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/services/tree/HeatTreeManagerUtil.java create mode 100644 openecomp-be/lib/openecomp-heat-lib/src/test/java/org/openecomp/sdc/heat/datatypes/model/EnvironmentTest.java create mode 100644 openecomp-be/lib/openecomp-heat-lib/src/test/java/org/openecomp/sdc/heat/datatypes/model/HeatOrchestrationTemplateTest.java create mode 100644 openecomp-be/lib/openecomp-heat-lib/src/test/resources/mock/model/envSettings.env create mode 100644 openecomp-be/lib/openecomp-heat-lib/src/test/resources/mock/model/testHeat.yml create mode 100644 openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/pom.xml create mode 100644 openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/ActionConstants.java create mode 100644 openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/dao/ActionArtifactDao.java create mode 100644 openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/dao/ActionArtifactDaoFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/dao/ActionDao.java create mode 100644 openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/dao/ActionDaoFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/dao/types/ActionArtifactEntity.java create mode 100644 openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/dao/types/ActionEntity.java create mode 100644 openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/dao/types/EcompComponentEntity.java create mode 100644 openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/errors/ActionErrorConstants.java create mode 100644 openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/errors/ActionException.java create mode 100644 openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/errors/ActionExceptionMapper.java create mode 100644 openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/errors/ActionExceptionResponse.java create mode 100644 openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/logging/CategoryLogLevel.java create mode 100644 openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/logging/StatusCode.java create mode 100644 openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/Action.java create mode 100644 openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/ActionArtifact.java create mode 100644 openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/ActionArtifactProtection.java create mode 100644 openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/ActionLogResponseCode.java create mode 100644 openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/ActionRequest.java create mode 100644 openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/ActionStatus.java create mode 100644 openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/ActionSubOperation.java create mode 100644 openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/EcompComponent.java create mode 100644 openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/util/ActionUtil.java create mode 100644 openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/resources/factoryConfiguration.json create mode 100644 openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-core/pom.xml create mode 100644 openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-core/src/main/java/org/openecomp/sdc/action/dao/impl/ActionArtifactDaoFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-core/src/main/java/org/openecomp/sdc/action/dao/impl/ActionArtifactDaoImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-core/src/main/java/org/openecomp/sdc/action/dao/impl/ActionDaoFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-core/src/main/java/org/openecomp/sdc/action/dao/impl/ActionDaoImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-action-lib/pom.xml create mode 100644 openecomp-be/lib/openecomp-sdc-datatypes-lib/pom.xml create mode 100644 openecomp-be/lib/openecomp-sdc-datatypes-lib/src/main/java/org/openecomp/sdc/datatypes/error/ErrorLevel.java create mode 100644 openecomp-be/lib/openecomp-sdc-datatypes-lib/src/main/java/org/openecomp/sdc/datatypes/error/ErrorMessage.java create mode 100644 openecomp-be/lib/openecomp-sdc-datatypes-lib/src/main/java/org/openecomp/sdc/datatypes/model/AsdcModel.java create mode 100644 openecomp-be/lib/openecomp-sdc-datatypes-lib/src/main/java/org/openecomp/sdc/datatypes/model/heat/ForbiddenHeatResourceTypes.java create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/pom.xml create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/EnrichmentArtifactsServiceFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/EnrichmentConstants.java create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/api/EnrichmentManager.java create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/enrichmentartifacts/EnrichmentArtifactsService.java create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/factory/EnrichmentManagerFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/types/CeilometerInfo.java create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/types/ComponentArtifactType.java create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/types/ComponentCeilometerInfo.java create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/types/ComponentMibInfo.java create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/types/EntityInfo.java create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/types/MibInfo.java create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/resources/factoryConfiguration.json create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/pom.xml create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/main/java/org/openecomp/sdc/enrichment/EnrichmentArtifactsServiceFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/main/java/org/openecomp/sdc/enrichment/enrichmentartifacts/EnrichmentArtifactsServiceImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/main/java/org/openecomp/sdc/enrichment/impl/EnrichmentManagerFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/main/java/org/openecomp/sdc/enrichment/impl/EnrichmentManagerImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/java/org/openecomp/sdc/enrichment/impl/EnrichmentManagerImplTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/all/OnlyComponentsST.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/all/OnlyComponentsST_01.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/all/VariouseST.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/all/expectedOutput/OnlyComponentsST.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/all/expectedOutput/OnlyComponentsST_01.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/all/expectedOutput/VariouseST.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/onlyComponents/OnlyComponentsST.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/onlyComponents/OnlyComponentsST_01.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/onlyComponents/expectedOutput/OnlyComponentsST.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/onlyComponents/expectedOutput/OnlyComponentsST_01.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/AbstractSubstituteGlobalTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/CinderVolumeGlobalTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/CommonGlobalTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/ContrailNetworkRuleGlobalTypeServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NativeTypesServiceTemplateServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NeutronNetGlobalTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NeutronPortGlobalTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NeutronSecurityRulesGlobalTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NovaServerGlobalTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/pom.xml create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/EnrichmentInfo.java create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/factory/EnricherHandlerFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/EnricherHandlerFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/EnricherHandlerImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/external/artifact/ExternalArtifactEnricher.java create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/tosca/CeilometerEnricher.java create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/tosca/ComponentInfo.java create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/tosca/SnmpEnricher.java create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/tosca/ToscaEnricher.java create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/inter/Enricher.java create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/inter/EnricherHandler.java create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/resources/factoryConfiguration.json create mode 100644 openecomp-be/lib/openecomp-sdc-enrichment-lib/pom.xml create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/pom.xml create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/EnrichedServiceArtifactDao.java create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/EnrichedServiceArtifactDaoFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/EnrichedServiceModelDao.java create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/EnrichedServiceModelDaoFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/EnrichedServiceTemplateDao.java create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/EnrichedServiceTemplateDaoFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/ServiceArtifactDao.java create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/ServiceArtifactDaoFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/ServiceArtifactDaoInter.java create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/ServiceModelDao.java create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/ServiceModelDaoFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/ServiceTemplateDao.java create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/ServiceTemplateDaoFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/ServiceTemplateDaoInter.java create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/types/EnrichedServiceArtifactEntity.java create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/types/EnrichedServiceTemplateEntity.java create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/types/ServiceArtifact.java create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/types/ServiceArtifactEntity.java create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/types/ServiceElement.java create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/types/ServiceElementEntity.java create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/types/ServiceTemplate.java create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/types/ServiceTemplateEntity.java create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/resources/factoryConfiguration.json create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-core/pom.xml create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-core/src/main/java/org/openecomp/sdc/model/impl/AbstractServiceModelDao.java create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/pom.xml create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/EnrichedServiceArtifactDaoCassandraFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/EnrichedServiceArtifactDaoCassandraImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/EnrichedServiceModelDaoFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/EnrichedServiceModelDaoImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/EnrichedServiceTemplateDaoCassandraFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/EnrichedServiceTemplateDaoCassandraImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/ServiceArtifactDaoCassandraFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/ServiceArtifactDaoCassandraImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/ServiceModelDaoFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/ServiceModelDaoImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/ServiceTemplateDaoCassandraFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/ServiceTemplateDaoCassandraImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-model-lib/pom.xml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-api/pom.xml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-api/src/main/java/org/openecomp/core/translator/api/HeatToToscaTranslator.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-api/src/main/java/org/openecomp/core/translator/datatypes/TranslatorOutput.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-api/src/main/java/org/openecomp/core/translator/factory/HeatToToscaTranslatorFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-api/src/main/resources/factoryConfiguration.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/pom.xml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/datatypes/heattotosca/AttachedResourceId.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/datatypes/heattotosca/ResourceReferenceType.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/datatypes/heattotosca/to/FileDataCollection.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/datatypes/heattotosca/to/ResourceFileDataAndIDs.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/datatypes/heattotosca/to/TranslateTo.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/datatypes/heattotosca/to/TranslatedHeatResource.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/impl/heattotosca/HeatToToscaTranslatorFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/impl/heattotosca/HeatToToscaTranslatorImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/Constants.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/HeatToToscaUtil.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/ResourceTranslation.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/ResourceTranslationFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/TranslationContext.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/TranslationService.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/errors/IncorrectResourceReferenceErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/errors/InvalidPropertyValueErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/errors/MissingMandatoryPropertyErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/errors/NotInSyncNumberOfInterfacesErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/errors/ReferenceToUnsupportedResourceErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/errors/ResourceNotFoundInHeatFileErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/errors/TranslatorErrorCodes.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/AbstractSubstituteGlobalType.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/CinderVolumeGlobalType.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/CommonGlobalTypes.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/ContrailAbstractSubstituteGlobalType.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/ContrailComputeGlobalType.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/ContrailNetworkRuleGlobalType.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/ContrailPortGlobalType.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/ContrailV2NetworkRuleGlobalType.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/ContrailV2VirtualMachineInterfaceGlobalType.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/ContrailV2VirtualNetworkGlobalType.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/ContrailVirtualNetworkGlobalType.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/GlobalTypesGenerator.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/GlobalTypesUtil.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/NeutronNetGlobalType.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/NeutronPortGlobalType.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/NeutronSecurityRulesGlobalType.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/NovaServerGlobalType.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/helper/ContrailTranslationHelper.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/helper/NameExtractorService.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/helper/PropertyRegexMatcher.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/helper/VolumeTranslationHelper.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/helper/impl/NameExtractorServiceImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/BaseResourceConnection.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ContrailV2VmInterfaceToNetResourceConnection.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/NovaAndPortResourceConnectionHelper.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/NovaToVolResourceConnection.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/PortToNetResourceConnection.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationBase.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationCinderVolumeAttachmentImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationCinderVolumeImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailAttachPolicyImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailNetworkPolicyImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailServiceInstanceImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailServiceTemplateImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailV2NetworkPolicyImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailV2VirtualNetworkImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailV2VmInterfaceImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailVirtualNetworkImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationDefaultImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNestedImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNeutronNetImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNeutronPortImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNeutronSecurityGroupImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNeutronSubnetImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNovaServerGroupsImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNovaServerImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationResourceGroupImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/SecurityRulesToPortResourceConnection.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/mapping/TranslatorHeatToToscaFunctionConverter.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/mapping/TranslatorHeatToToscaParameterConverter.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/mapping/TranslatorHeatToToscaPropertyConverter.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/resources/heatToToscaMapping.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/TestUtils.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/nested/multi/Translate_Heat_Nested_Multi.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/nested/nestedvolumelocal/NestedVolumelocal.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/nested/nestedvolumeseperatefile/NestedVolumeSeperateFile.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/nested/recursive/TranslateHeatNestedRecursiveTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/nested/reusenestedfrommultibase/Translate_Heat_Nested_From_Multi_Base.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/nested/separatevol/NestedAndSeparateVolTranslationTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/nested/single/TranslateHeatNestedSingle.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/outputs/HeatOutputConversionTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/parameters/HeatParameterConversionTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/resources/ContrailNetworkRuleTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/resources/OSContrailVirtualNetworkTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/resources/OSNeutronNetTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/resources/OSNovaServerTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/sharedresource/HeatSharedResourceTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/GlobalTypesGeneratorTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/fullvfexample/hotmog/HotMogTranslationTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/fullvfexample/vmmesmall/VmmeSmallTranslationTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/helper/impl/NameExtractorServiceImplTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/BaseResourceTranslationTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ContrailV2VMInterfaceToNetResourceConnectionTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/DependsOnResourceBaseTranslationlTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/MultipleHeatTranslationTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/NovaToVolResourceConnectionTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/PortToContrailV2VirtualNetworkResourceConnectionTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/PortToNetResourceConnectionTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationCinderVolumeAttachmentImplTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationCinderVolumeImplTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailServiceInstanceImplTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailServiceTemplateImplTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailV2Test.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailV2VMInterfaceImplTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNeutronPortImplTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNeutronSecurityGroupImplTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNovaServerGroupsImplTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationResourceGroupImplTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/SecurityGroupToNovaResourceConnectionTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/SecurityRulesToPortResourceConnectionTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/mapping/TranslatorHeatToToscaFunctionConverterTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/ep-jsa-si/ep-jsa-si.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/ep-jsa-si/ep-jsa-si.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/ep-jsa-si/ep-jsa_net.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/ep-jsa-si/ep-jsa_net.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/ep-jsa-si/master-jsa.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/ep-jsa-si/master-jsa.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/expectedoutputfiles/nested-pcm_v0.1ServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/expectedoutputfiles/nested-pcm_v0.1_2ServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/inputs/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/inputs/hot-nimbus-pcm_v0.4.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/inputs/hot-nimbus-pcm_v0.4.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/inputs/hot-nimbus-pcm_v0.4_2.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/inputs/nested-pcm_v0.1.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/inputs/nested-pcm_v0.1_2.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/inputs/nimbus-ethernet create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multiple_resource_groups/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multiple_resource_groups/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multiple_resource_groups/expectedoutputfiles/mvs.nested.heatServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multiple_resource_groups/inputs/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multiple_resource_groups/inputs/mvs.nested.heat.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multiple_resource_groups/inputs/mvs.vfmodule.heat.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/expectedoutputfiles/nested2levelServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/expectedoutputfiles/nestedServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/inputs/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/inputs/addOn.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/inputs/base.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/inputs/nested.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/inputs/nested2level.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/expectedoutputfiles/nested2levelServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/expectedoutputfiles/nested3levelServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/expectedoutputfiles/nestedServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/inputs/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/inputs/addOn.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/inputs/base.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/inputs/nested.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/inputs/nested2level.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/inputs/nested3level.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumelocal/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumelocal/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumelocal/expectedoutputfiles/nested-pcm_v0.1ServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumelocal/inputs/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumelocal/inputs/hot-nimbus-pcm_v0.4.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumelocal/inputs/nested-pcm_v0.1.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumeseperatefile/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumeseperatefile/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumeseperatefile/expectedoutputfiles/nested-pcm_v0.1ServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumeseperatefile/inputs/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumeseperatefile/inputs/hot-nimbus-pcm_v0.4.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumeseperatefile/inputs/nested-pcm_v0.1.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumeseperatefile/inputs/volume.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/expectedoutputfiles/nested-pcm_v0.1ServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/expectedoutputfiles/nested-pcm_v0.1_2ServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/inputs/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/inputs/hot-nimbus-pcm_v0.4.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/inputs/hot-nimbus-pcm_v0.4.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/inputs/hot-nimbus-pcm_v0.4_2.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/inputs/nested-pcm_v0.1.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/inputs/nested-pcm_v0.1_2.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupIndexVar/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupIndexVar/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupIndexVar/expectedoutputfiles/mvs.nested.heatServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupIndexVar/inputs/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupIndexVar/inputs/mvs.nested.heat.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupIndexVar/inputs/mvs.vfmodule.heat.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupInvalid/inputs/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupInvalid/inputs/mvs.nested.heat.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupInvalid/inputs/mvs.vfmodule.heat.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/expectedoutputfiles/dns_nested_01ServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/inputs/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/inputs/base_dns.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/inputs/base_dns.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/inputs/dns_az_01.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/inputs/dns_az_01.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/inputs/dns_nested_01.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/inputs/nimbus-willows-2.pem create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group/expectedoutputfiles/mvs.nested.heatServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group/inputs/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group/inputs/mvs.nested.heat.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group/inputs/mvs.vfmodule.heat.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group_with_dynamic_count/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group_with_dynamic_count/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group_with_dynamic_count/expectedoutputfiles/mvs.nested.heatServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group_with_dynamic_count/inputs/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group_with_dynamic_count/inputs/mvs.nested.heat.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group_with_dynamic_count/inputs/mvs.vfmodule.heat.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/reusenestedfrommultibase/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/reusenestedfrommultibase/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/reusenestedfrommultibase/expectedoutputfiles/nested-pcm_v0.1ServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/reusenestedfrommultibase/inputs/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/reusenestedfrommultibase/inputs/hot-nimbus-pcm_v0.4.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/reusenestedfrommultibase/inputs/hot-nimbus-pcm_v0.4.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/reusenestedfrommultibase/inputs/hot-nimbus-pcm_v0.4_2.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/reusenestedfrommultibase/inputs/nested-pcm_v0.1.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/single/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/single/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/single/expectedoutputfiles/nested-pcm_v0.1ServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/single/inputs/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/single/inputs/hot-nimbus-pcm_v0.4.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/single/inputs/hot-nimbus-pcm_v0.4.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/single/inputs/nested-pcm_v0.1.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/outputs/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/outputs/inputs/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/outputs/inputs/outputs.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/parameters/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/parameters/inputs/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/parameters/inputs/parameters.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/parameters/inputs/parameters.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Contrail_Network_Rule/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Contrail_Network_Rule/inputs/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Contrail_Network_Rule/inputs/network_policy_chain.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Contrail_VirtualNetwork/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Contrail_VirtualNetwork/inputs/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Contrail_VirtualNetwork/inputs/nimbus-ethernet.sh create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Contrail_VirtualNetwork/inputs/vmme_small.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Contrail_VirtualNetwork/inputs/vmme_small.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Neutron_Net/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Neutron_Net/inputs/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Neutron_Net/inputs/ep-jsa_net.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Neutron_Net/inputs/ep-jsa_net.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Nova_Server/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Nova_Server/inputs/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Nova_Server/inputs/ep-jsa_net.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Nova_Server/inputs/ep-jsa_net.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Nova_Server/inputs/nimbus-ethernet create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Nova_Server/inputs/nimbus-ethernet-gw create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/sharedresources/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/sharedresources/inputs/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/sharedresources/inputs/sharedDefinitionOutParam.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/expectedOutput/validationOutput.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/MMSC_Capacity_Line.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/MMSC_Capacity_Line_1.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/NETWORK_OUT.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/SG_ECA_MGMT.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/VOLUME.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/VOLUME_OUT.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/art.sh create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/cmaui.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/cmaui.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/cmaui_net.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/eca_oam.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/eca_oam.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/eca_oam_nested.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/nested1.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/nested2.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/network_out.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/sg_eca_mgmt.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/volume.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/volume_out.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/expectedOutput/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/MMSC_Capacity_Line.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/MMSC_Capacity_Line_1.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/SG_ECA_MGMT.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/cmaui.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/cmaui.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/eca_oam.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/eca_oam.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/sg_eca_mgmt.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/expectedOutput/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/expectedOutput/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/expectedOutput/eca_oamServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/MMSC_Capacity_Line.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/MMSC_Capacity_Line_1.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/SG_ECA_MGMT.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/cmaui.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/cmaui.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/eca_oam.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/eca_oam.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/sg_eca_mgmt.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/ContrailV2_MultiPolicy_single_net_translation/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/ContrailV2_MultiPolicy_single_net_translation/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/ContrailV2_MultiPolicy_single_net_translation/inputfiles/main.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/ContrailV2_Multi_net_single_policy_translation/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/ContrailV2_Multi_net_single_policy_translation/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/ContrailV2_Multi_net_single_policy_translation/inputfiles/main.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/invalid_policy_resource_type/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/invalid_policy_resource_type/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/invalid_policy_resource_type/inputfiles/main.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/simple/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/simple/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/simple/inputfiles/main.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/multi/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/multi/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/multi/inputfiles/addOn.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/multi/inputfiles/main.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/nested/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/nested/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/nested/expectedoutputfiles/nestedServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/nested/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/nested/inputfiles/main.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/nested/inputfiles/nested.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/expectedoutputfiles/nested1ServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/expectedoutputfiles/nested2ServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/inputfiles/addOn.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/inputfiles/main.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/inputfiles/nested1.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/inputfiles/nested2.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/baseResourceTranslation/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/baseResourceTranslation/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/baseResourceTranslation/inputfiles/hot_template.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/cinder_volume_translation/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/cinder_volume_translation/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/cinder_volume_translation/inputfiles/hot_template.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/diffServiceTemplate/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/diffServiceTemplate/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/diffServiceTemplate/expectedoutputfiles/service_instance_1ServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/diffServiceTemplate/expectedoutputfiles/service_instance_2ServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/diffServiceTemplate/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/diffServiceTemplate/inputfiles/OCS-fw.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/oneServiceInstance/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/oneServiceInstance/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/oneServiceInstance/expectedoutputfiles/service_instanceServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/oneServiceInstance/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/oneServiceInstance/inputfiles/lcp1_mss.oam-fw_si.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/oneServiceInstance/inputfiles/lcp1_mss.oam-fw_si_with_comments.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sameServiceTemplate/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sameServiceTemplate/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sameServiceTemplate/expectedoutputfiles/service_instance_1ServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sameServiceTemplate/expectedoutputfiles/service_instance_2ServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sameServiceTemplate/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sameServiceTemplate/inputfiles/OCS-fw.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkMulti/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkMulti/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkMulti/expectedoutputfiles/service_instanceServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkMulti/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkMulti/inputfiles/OCS-fw.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkMulti/inputfiles/network_base.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkNested/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkNested/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkNested/expectedoutputfiles/OCS-fwServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkNested/expectedoutputfiles/service_instanceServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkNested/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkNested/inputfiles/OCS-fw.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkNested/inputfiles/main.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrailv2VMinterface/listNet/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrailv2VMinterface/listNet/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrailv2VMinterface/listNet/inputfiles/hot_template.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrailv2VMinterface/oneNet/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrailv2VMinterface/oneNet/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrailv2VMinterface/oneNet/inputfiles/hot_template.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/AbstractSubstituteGlobalTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/CinderVolumeGlobalTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/CommonGlobalTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/ContrailComputeGlobalTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/ContrailNetworkRuleGlobalTypeServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/ContrailPortGlobalTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/ContrailV2NetworkRuleGlobalTypeServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/ContrailV2VirtualNetworkGlobalTypeServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/NativeTypesServiceTemplateServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/NeutronNetGlobalTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/NeutronPortGlobalTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/NeutronSecurityRulesGlobalTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/NovaServerGlobalTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/inputfiles/hot_template.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-mog-0108-bs1271/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-mog-0108-bs1271/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-mog-0108-bs1271/inputfiles/hot-mog-0108-bs1271.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-mog-0108-bs1271/inputfiles/hot-mog-0108-bs1271.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/cloud-nimbus.sh create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-oam-volumes_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-oam-volumes_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-oam_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-oam_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-pcm-volumes_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-pcm-volumes_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-pcm_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-pcm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-ppd_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-ppd_v1.1.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-pps_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-psm_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/nested-oam_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/nested-pcm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/nested-ppd_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/nested-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/nested-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/nimbus-ethernet create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/nimbus-ethernet-gw create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/out/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/out/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/out/nested-oam_v1.0ServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/out/nested-pcm_v1.0ServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/out/nested-ppd_v1.0ServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/out/nested-pps_v1.0ServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/out/nested-psm_v1.0ServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/neutron_port_translation/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/neutron_port_translation/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/neutron_port_translation/inputfiles/hot_template.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/neutron_security_group_translation/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/neutron_security_group_translation/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/neutron_security_group_translation/inputfiles/hot_template.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novaservergroups/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novaservergroups/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novaservergroups/inputfiles/hot_template.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/innernestedconnection/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/innernestedconnection/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/innernestedconnection/expectedoutputfiles/nestedServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/innernestedconnection/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/innernestedconnection/inputfiles/a_vol.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/innernestedconnection/inputfiles/main.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/innernestedconnection/inputfiles/nested.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/multiconnection/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/multiconnection/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/multiconnection/inputfiles/addOn.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/multiconnection/inputfiles/main.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/multinotconnected/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/multinotconnected/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/multinotconnected/inputfiles/addOn.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/multinotconnected/inputfiles/main.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestedconnection/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestedconnection/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestedconnection/expectedoutputfiles/nestedServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestedconnection/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestedconnection/inputfiles/main.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestedconnection/inputfiles/nested.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestednotconnected/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestednotconnected/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestednotconnected/expectedoutputfiles/nestedServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestednotconnected/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestednotconnected/inputfiles/main.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestednotconnected/inputfiles/nested.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestedconnection/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestedconnection/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestedconnection/expectedoutputfiles/nestedServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestedconnection/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestedconnection/inputfiles/addOn.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestedconnection/inputfiles/main.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestedconnection/inputfiles/nested.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestednotconnected/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestednotconnected/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestednotconnected/expectedoutputfiles/nestedServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestednotconnected/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestednotconnected/inputfiles/addOn.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestednotconnected/inputfiles/main.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestednotconnected/inputfiles/nested.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumemulticonnection/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumesharednestedconnection/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumesharednestedconnection/inputfiles/addOn.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/multi/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/multi/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/multi/inputfiles/addOn.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/multi/inputfiles/main.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/nested/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/nested/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/nested/expectedoutputfiles/nestedServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/nested/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/nested/inputfiles/main.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/nested/inputfiles/nested.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/expectedoutputfiles/nested1ServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/expectedoutputfiles/nested2ServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/inputfiles/addOn.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/inputfiles/main.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/inputfiles/nested1.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/inputfiles/nested2.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/multi/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/multi/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/multi/inputfiles/addOn.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/multi/inputfiles/main.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/nested/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/nested/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/nested/expectedoutputfiles/nestedServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/nested/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/nested/inputfiles/main.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/nested/inputfiles/nested.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/expectedoutputfiles/nested1ServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/expectedoutputfiles/nested2ServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/inputfiles/addOn.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/inputfiles/main.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/inputfiles/nested1.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/inputfiles/nested2.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetresourcegroupconnection/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetresourcegroupconnection/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetresourcegroupconnection/expectedoutputfiles/nestedServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetresourcegroupconnection/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetresourcegroupconnection/inputfiles/main.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetresourcegroupconnection/inputfiles/nested.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttosharednetresourcegrouplinking/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttosharednetresourcegrouplinking/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttosharednetresourcegrouplinking/expectedoutputfiles/nested1ServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttosharednetresourcegrouplinking/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttosharednetresourcegrouplinking/inputfiles/addOn.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttosharednetresourcegrouplinking/inputfiles/main.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttosharednetresourcegrouplinking/inputfiles/nested1.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securitygrouptonovaconnectionmulti/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securitygrouptonovaconnectionmulti/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securitygrouptonovaconnectionmulti/inputfiles/addOn1.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securitygrouptonovaconnectionmulti/inputfiles/addOn2.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securitygrouptonovaconnectionmulti/inputfiles/addOn3.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securitygrouptonovaconnectionmulti/inputfiles/main.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEAdd_On_Module_QRouterCloudConfig create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEAdd_On_Module_QRouterTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEAdd_On_Module_vLBAgentCloudConfig create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEAdd_On_Module_vLBAgentTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEAdd_On_Module_vLBCloudConfig create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEAdd_On_Module_vLBTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEAdd_On_Module_vProbeCloudConfig create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEAdd_On_Module_vProbeTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEBase_Module.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEBase_Module.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/call_home.py create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/check_availability.py create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/qrouterdependencies.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/register_status.py create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/vlbagentdependencies_with_vLB.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/vlbagentdependencies_without_vLB.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/vlbdependencies.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/vprobedependencies.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/wait_for_resources.py create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectionmulti/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectionmulti/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectionmulti/inputfiles/addOn.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectionmulti/inputfiles/main.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportnestedconnection/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportnestedconnection/expectedoutputfiles/nestedServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportnestedconnection/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportnestedconnection/inputfiles/main.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportnestedconnection/inputfiles/nested.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityruletosharedportlinking/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityruletosharedportlinking/expectedoutputfiles/nestedServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityruletosharedportlinking/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityruletosharedportlinking/inputfiles/addOn.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityruletosharedportlinking/inputfiles/main.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityruletosharedportlinking/inputfiles/nested.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnectionmulti/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportlinking/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportlinking/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportresourcegrouplinking/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportresourcegrouplinking/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportresourcegrouplinking/expectedoutputfiles/nestedServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportresourcegrouplinking/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportresourcegrouplinking/inputfiles/addOn.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportresourcegrouplinking/inputfiles/main.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportresourcegrouplinking/inputfiles/nested.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vmme_small/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vmme_small/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vmme_small/inputfiles/vmme_small.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vmme_small/inputfiles/vmme_small.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vmme_small/inputfiles/vmme_small_create_fsb.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vmme_small/inputfiles/vmme_small_create_fsb.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/nested_with_inner_vol/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/nested_with_inner_vol/inputfiles/a_vol.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/nested_with_inner_vol/inputfiles/main.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/nested_with_inner_vol/inputfiles/nested.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/nested_with_inner_vol/out/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/nested_with_inner_vol/out/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/nested_with_inner_vol/out/nestedServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_and_attach_one_file/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_and_attach_one_file/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_and_attach_one_file/inputfiles/hot_template.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_file_nested_in_main_file_in_manifest/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_file_nested_in_main_file_in_manifest/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_file_nested_in_main_file_in_manifest/inputfiles/a_vol.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_file_nested_in_main_file_in_manifest/inputfiles/hot_template.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_file_parallel_to_main_file/expectedoutputfiles/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_file_parallel_to_main_file/inputfiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_file_parallel_to_main_file/inputfiles/a_vol.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_file_parallel_to_main_file/inputfiles/hot_template.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/testManifestFormat.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/vmme_small_create_fsb/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/vmme_small_create_fsb/create_stack.sh create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/vmme_small_create_fsb/vmme_small.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/vmme_small_create_fsb/vmme_small.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/vmme_small_create_fsb/vmme_small_create_fsb.env create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/vmme_small_create_fsb/vmme_small_create_fsb.yml create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/pom.xml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/pom.xml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/api/ValidationManager.java create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/errors/ErrorMessagesFormatBuilder.java create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/errors/Messages.java create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/factory/ValidationManagerFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/interfaces/Validator.java create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/types/FileValidationContext.java create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/types/GlobalValidationContext.java create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/types/MessageContainer.java create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/types/MessageContainerUtil.java create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/resources/factoryConfiguration.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/resources/validationConfiguration.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/pom.xml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/main/java/org/openecomp/sdc/validation/impl/ValidationManagerFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/main/java/org/openecomp/sdc/validation/impl/ValidationManagerImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/main/java/org/openecomp/sdc/validation/utils/ValidationConfiguration.java create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/main/java/org/openecomp/sdc/validation/utils/ValidationConfigurationManager.java create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/main/java/org/openecomp/sdc/validation/utils/ValidationManagerUtil.java create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/main/java/org/openecomp/sdc/validation/utils/ValidatorConfiguration.java create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/test/java/org/openecomp/sdc/heat/services/tree/HeatTreeManagerTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/test/resources/heatTreeValidationOutput/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/test/resources/heatTreeValidationOutput/hot-nimbus-pps_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/test/resources/heatTreeValidationOutput/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/test/resources/heatTreeValidationOutput/hot-nimbus-psm_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/test/resources/heatTreeValidationOutput/hot-nimbus-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/test/resources/heatTreeValidationOutput/hot-nimbus-psm_volume.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/test/resources/heatTreeValidationOutput/nested-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/pom.xml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/main/java/org/openecomp/sdc/validation/impl/util/HeatValidationService.java create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/main/java/org/openecomp/sdc/validation/impl/util/ResourceValidationHeatValidator.java create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/main/java/org/openecomp/sdc/validation/impl/validators/EcompGuideLineValidator.java create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/main/java/org/openecomp/sdc/validation/impl/validators/HeatValidator.java create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/main/java/org/openecomp/sdc/validation/impl/validators/ManifestValidator.java create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/main/java/org/openecomp/sdc/validation/impl/validators/YamlValidator.java create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/java/org/openecomp/sdc/validation/impl/validators/ErrorMessagesTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/java/org/openecomp/sdc/validation/impl/validators/ValidatorBaseTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/java/org/openecomp/sdc/validation/impl/validators/validators/EcompGuideLineValidatorTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/java/org/openecomp/sdc/validation/impl/validators/validators/EcompNamingConventionTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/java/org/openecomp/sdc/validation/impl/validators/validators/HeatValidatorTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/java/org/openecomp/sdc/validation/impl/validators/validators/ManifestValidatorTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/java/org/openecomp/sdc/validation/impl/validators/validators/YamlValidatorTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/negative/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/negative/first.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/negative/first.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/negative/firstVol.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/negative/second.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/positive/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/positive/first.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/positive/first.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/positive/firstVol.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/positive/second.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/negative/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/negative/first.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/negative/first.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/negative/firstVol.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/negative/second.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/positive/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/positive/first.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/positive/first.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/positive/firstVol.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/positive/second.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/negative/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/negative/first.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/negative/first.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/negative/firstVol.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/negative/second.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/positive/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/positive/first.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/positive/first.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/positive/firstVol.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/positive/second.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/negative/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/negative/first.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/negative/first.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/negative/firstVol.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/negative/second.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/positive/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/positive/first.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/positive/first.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/positive/firstVol.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/positive/second.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/negative/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/negative/first.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/negative/first.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/negative/firstVol.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/negative/second.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/positive/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/positive/first.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/positive/first.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/positive/firstVol.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/positive/second.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/negative/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/negative/first.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/negative/first.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/negative/firstVol.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/negative/second.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/positive/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/positive/first.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/positive/first.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/positive/firstVol.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/positive/second.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/negative/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/negative/first.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/negative/first.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/negative/firstVol.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/negative/second.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/positive/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/positive/first.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/positive/first.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/positive/firstVol.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/positive/second.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/negative/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/negative/first.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/negative/first.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/negative/firstVol.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/negative/second.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/positive/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/positive/first.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/positive/first.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/positive/firstVol.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/positive/second.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/negative/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/negative/first.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/negative/first.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/negative/firstVol.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/negative/second.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/positive/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/positive/first.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/positive/first.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/positive/firstVol.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/positive/second.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/negative/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/negative/first.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/negative/first.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/negative/firstVol.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/negative/second.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/positive/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/positive/first.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/positive/first.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/positive/firstVol.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/positive/second.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/negative/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/negative/first.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/negative/first.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/negative/firstVol.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/negative/second.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/positive/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/positive/first.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/positive/first.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/positive/firstVol.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/positive/second.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/negative/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/negative/first.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/negative/first.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/negative/firstVol.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/negative/second.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/positive/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/positive/first.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/positive/first.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/positive/firstVol.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/positive/second.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/negative/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/negative/first.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/negative/first.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/negative/firstVol.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/negative/second.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/positive/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/positive/first.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/positive/first.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/positive/firstVol.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/positive/second.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/negative/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/negative/first.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/negative/first.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/negative/firstVol.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/negative/second.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/positive/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/positive/first.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/positive/first.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/positive/firstVol.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/positive/second.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/missingBaseHeat/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/missingBaseHeat/first.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/missingBaseHeat/first.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/missingBaseHeat/firstVol.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/missingBaseHeat/second.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/multiBaseHeat/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/multiBaseHeat/first.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/multiBaseHeat/first.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/multiBaseHeat/firstVol.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/multiBaseHeat/second.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/availability_zone_name/expected_output/expected_output.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/availability_zone_name/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/availability_zone_name/input/hot-nimbus-pps_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/availability_zone_name/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/floating_ip_resource_type/expected_output/expected_output.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/floating_ip_resource_type/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/floating_ip_resource_type/input/hot-nimbus-pps_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/floating_ip_resource_type/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/neutron_port_fixed_ip_name/expected_output/expected_output.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/neutron_port_fixed_ip_name/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/neutron_port_fixed_ip_name/input/hot-nimbus-pps_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/neutron_port_fixed_ip_name/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/nova_server_name/expected_output/expected_output.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/nova_server_name/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/nova_server_name/input/hot-nimbus-pps_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/nova_server_name/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/default_value_align_with_type/negative_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/default_value_align_with_type/negative_test/input/hot-nimbus-pps_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/default_value_align_with_type/negative_test/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/depends_on_points_to_existing_resource/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/depends_on_points_to_existing_resource/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/negative_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/negative_test/input/hot-nimbus-pps_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/negative_test/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/positive_test/expected_output/expected_output.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/positive_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/positive_test/input/hot-nimbus-pps_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/positive_test/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/positive_test/input/hot-nimbus-psm_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/positive_test/input/hot-nimbus-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/positive_test/input/nested-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/positive_test/input/nested-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_empty_value/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_empty_value/input/env_empty_value.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_empty_value/input/env_empty_value.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/negative_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/negative_test/input/hot-nimbus-pps_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/negative_test/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/positive_test/expected_output/expected_output.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/positive_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/positive_test/input/hot-nimbus-pps_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/positive_test/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/positive_test/input/hot-nimbus-psm_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/positive_test/input/hot-nimbus-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/positive_test/input/nested-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/positive_test/input/nested-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/negative_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/negative_test/input/hot-nimbus-psm_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/negative_test/input/hot-nimbus-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/negative_test/input/nested-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/positive_test/expected_output/expected_output.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/positive_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/positive_test/input/hot-nimbus-pps_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/positive_test/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/positive_test/input/hot-nimbus-psm_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/positive_test/input/hot-nimbus-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/positive_test/input/nested-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/positive_test/input/nested-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/negative_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/negative_test/input/hot-nimbus-psm_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/negative_test/input/hot-nimbus-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/positive_test/expected_output/expected_output.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/positive_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/positive_test/input/hot-nimbus-pps_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/positive_test/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/positive_test/input/hot-nimbus-psm_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/positive_test/input/hot-nimbus-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/positive_test/input/nested-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/positive_test/input/nested-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_resource_value_valid/negative_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_resource_value_valid/negative_test/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/invalid_heat_format/negative_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/invalid_heat_format/negative_test/input/hot-nimbus-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/network_policy_associated_with_attach_policy/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/network_policy_associated_with_attach_policy/input/hot-nimbus-pps_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/network_policy_associated_with_attach_policy/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/negative_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/negative_test/input/hot-nimbus-psm_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/negative_test/input/hot-nimbus-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/negative_test/input/nested-points-to-hot-nimbus-psm.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/negative_test/input/nested-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/negative_test/input/yaml-point-to-itself.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/positive_test/expected_output/expected_output.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/positive_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/positive_test/input/hot-nimbus-pps_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/positive_test/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/positive_test/input/hot-nimbus-psm_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/positive_test/input/hot-nimbus-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/positive_test/input/nested-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/positive_test/input/nested-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/negative_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/negative_test/input/hot-nimbus-psm_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/negative_test/input/hot-nimbus-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/positive_test/expected_output/expected_output.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/positive_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/positive_test/input/hot-nimbus-pps_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/positive_test/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/positive_test/input/hot-nimbus-psm_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/positive_test/input/hot-nimbus-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/positive_test/input/nested-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/positive_test/input/nested-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/negative_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/negative_test/input/hot-nimbus-psm_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/negative_test/input/hot-nimbus-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/positive_test/expected_output/expected_output.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/positive_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/positive_test/input/hot-nimbus-pps_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/positive_test/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/positive_test/input/hot-nimbus-psm_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/positive_test/input/hot-nimbus-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/positive_test/input/nested-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/positive_test/input/nested-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/negative_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/negative_test/input/hot-nimbus-pps_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/negative_test/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/negative_test/input/hot-nimbus-psm_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/negative_test/input/hot-nimbus-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/negative_test/input/nested-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/negative_test/input/nested-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/positive_test/expected_output/expected_output.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/positive_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/positive_test/input/hot-nimbus-pps_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/positive_test/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/positive_test/input/hot-nimbus-psm_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/positive_test/input/hot-nimbus-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/positive_test/input/nested-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/positive_test/input/nested-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/negative_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/negative_test/input/hot-nimbus-psm_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/negative_test/input/hot-nimbus-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/positive_test/expected_output/expected_output.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/positive_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/positive_test/input/hot-nimbus-pps_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/positive_test/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/positive_test/input/hot-nimbus-psm_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/positive_test/input/hot-nimbus-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/positive_test/input/nested-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/positive_test/input/nested-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/negative_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/negative_test/input/hot-nimbus-pps_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/negative_test/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/negative_test/input/hot-nimbus-psm_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/negative_test/input/hot-nimbus-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/negative_test/input/nested-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/negative_test/input/nested-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/positive_test/expected_output/expected_output.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/positive_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/positive_test/input/hot-nimbus-pps_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/positive_test/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/positive_test/input/hot-nimbus-psm_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/positive_test/input/hot-nimbus-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/positive_test/input/nested-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/positive_test/input/nested-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/negative_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/negative_test/input/hot-nimbus-pps_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/negative_test/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/negative_test/input/nested-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/positive_test/expected_output/expected_output.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/positive_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/positive_test/input/hot-nimbus-pps_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/positive_test/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/positive_test/input/hot-nimbus-psm_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/positive_test/input/hot-nimbus-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/positive_test/input/nested-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/positive_test/input/nested-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/pseudo_parameters/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/pseudo_parameters/input/pseudo_parameters.yml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/negative_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/negative_test/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/expected_output/expected_output.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/artifact.sh create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/cloud-nimbus.sh create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/hot-nimbus-pps_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/hot-nimbus-psm_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/hot-nimbus-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/nested-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/nested-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/nimbus-ethernet create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_group_invalid_type/negative_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_group_invalid_type/negative_test/input/hot-nimbus-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_group_invalid_type/negative_test/input/yamlFile.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/negative_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/negative_test/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/positive_test/expected_output/expected_output.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/positive_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/positive_test/input/hot-nimbus-pps_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/positive_test/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/positive_test/input/hot-nimbus-psm_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/positive_test/input/hot-nimbus-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/positive_test/input/nested-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/positive_test/input/nested-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/negative_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/negative_test/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/negative_test/input/hot-nimbus-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/negative_test/input/nested-from-resources-group.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/negative_test/input/nested-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/expected_output/expected_output.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/input/hot-nimbus-pps_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/input/hot-nimbus-psm_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/input/hot-nimbus-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/input/nested-from-resources-group.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/input/nested-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/input/nested-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/security_group_base_file_no_ports/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/security_group_base_file_no_ports/input/baseFile.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/security_group_base_file_no_ports/input/notBaseFile.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/security_group_called_by_port/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/security_group_called_by_port/input/hot-nimbus-pps_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/security_group_called_by_port/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_group_called_by_nova_server/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_group_called_by_nova_server/input/hot-nimbus-pps_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_group_called_by_nova_server/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/negative_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/negative_test/input/hot-nimbus-pps_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/negative_test/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/positive_test/expected_output/expected_output.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/positive_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/positive_test/input/hot-nimbus-pps_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/positive_test/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/positive_test/input/hot-nimbus-psm_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/positive_test/input/hot-nimbus-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/positive_test/input/nested-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/positive_test/input/nested-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/shared_resources/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/shared_resources/input/hot-nimbus-pps_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/shared_resources/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/negative_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/negative_test/input/hot-nimbus-pps_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/negative_test/input/hot-nimbus-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/negative_test/input/hot-nimbus-psm_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/negative_test/input/hot-nimbus-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/negative_test/input/nested-pps_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/negative_test/input/nested-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/positive_test/expected_output/expected_output.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/positive_test/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/positive_test/input/hot-nimbus-psm_v1.0.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/positive_test/input/hot-nimbus-psm_v1.0.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/envInRoot/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/envInRoot/first.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/envInRoot/first.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/envInRoot/second.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/invalidFileTypeInManifest/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/invalidFileTypeInManifest/illegalTypeFile.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/invalidFileTypeInManifest/single.env.illegalSuffix create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/invalidFileTypeInManifest/single.yaml.illegalSuffix create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/invalidFileTypeInManifest/singleVol.yaml.illegalSuffix create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/invalidManifest/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/invalidManifest/single.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/invalidManifest/single.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/invalidManifest/singleVol.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInManifest/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInManifest/extraFile.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInManifest/single.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInManifest/single.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInManifest/singleVol.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInManifestAndInZip/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInManifestAndInZip/extraFile.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInManifestAndInZip/single.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInManifestAndInZip/single.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInZip/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInZip/single.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInZip/single.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/validFiles/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/validFiles/single.env create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/validFiles/single.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/validFiles/singleVol.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/duplicateKey.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/emptyYaml.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalidTabYamlStructure.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalidYamlStructure.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_duplicate_key/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_duplicate_key/input/heat_missing_from_manifast.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_duplicate_key/input/mainValid.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_duplicate_key/input/validHeat.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/expected_output/expected_output.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/input/heat_missing_from_manifast.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/input/invalidYamlTab.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/input/invalid_additionalSpaceBeforeProperty.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/input/invalid_duplicateKey.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/input/invalid_empty.yml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/input/invalid_yamlInXMLFormat.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/input/validHeat.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/valid_yaml/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/valid_yaml/input/heat_missing_from_manifast.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/valid_yaml/input/mainValid.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/valid_yaml/input/validHeat.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/org/openecomp/validation/validators/yaml_validator/input/MANIFEST.json create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/org/openecomp/validation/validators/yaml_validator/input/heat_missing_from_manifast.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/org/openecomp/validation/validators/yaml_validator/input/mainValid.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/org/openecomp/validation/validators/yaml_validator/input/validHeat.yaml create mode 100644 openecomp-be/lib/openecomp-sdc-validation-lib/pom.xml create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/pom.xml create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/HealingServiceFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/VendorLicenseArtifactServiceFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/VendorLicenseConstants.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/EntitlementPoolDao.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/EntitlementPoolDaoFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/FeatureGroupDao.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/FeatureGroupDaoFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/LicenseAgreementDao.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/LicenseAgreementDaoFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/LicenseKeyGroupDao.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/LicenseKeyGroupDaoFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/VendorLicenseModelDao.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/VendorLicenseModelDaoFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/AggregationFunction.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/ChoiceOrOther.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/EntitlementMetric.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/EntitlementPoolEntity.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/EntitlementTime.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/FeatureGroupEntity.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/FeatureGroupModel.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/LicenseAgreementEntity.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/LicenseAgreementModel.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/LicenseKeyGroupEntity.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/LicenseKeyType.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/LicenseTerm.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/MultiChoiceOrOther.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/OperationalScope.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/ThresholdUnit.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/VendorLicenseModelEntity.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/xml/AggregationFunctionForXml.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/xml/EntitlementMetricForXml.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/xml/EntitlementTimeForXml.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/xml/LicenseKeyTypeForXml.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/xml/ThresholdForXml.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/errors/JsonErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/errors/LicensingDataInvalidErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/errors/SubmitUncompletedLicenseModelErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/errors/VendorLicenseErrorCodes.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/errors/VendorLicenseModelNotFoundErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/facade/VendorLicenseFacade.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/facade/VendorLicenseFacadeFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/healing/HealingService.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/VendorLicenseArtifactsService.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/types/VersionedVendorLicenseModel.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/resources/factoryConfiguration.json create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/pom.xml create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/SimpleHealingServiceServiceFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/VendorLicenseArtifactServiceFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/EntitlementPoolCassandraDaoImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/EntitlementPoolDaoFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/FeatureGroupCassandraDaoImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/FeatureGroupDaoFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/LicenseAgreementCassandraDaoImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/LicenseAgreementDaoFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/LicenseKeyGroupCassandraDaoImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/LicenseKeyGroupDaoFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/VendorLicenseModelCassandraDaoImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/VendorLicenseModelDaoFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/facade/impl/VendorLicenseFacadeFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/facade/impl/VendorLicenseFacadeImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/healing/impl/SimpleHealingServiceImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/VendorLicenseArtifactsServiceImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/FeatureGroupForArtifact.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/VendorLicenseArtifact.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/VnfLicenseArtifact.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/XmlArtifact.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/mixins/MixinEntitlementPoolEntityForVendorLicenseArtifact.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/mixins/MixinEntitlementPoolEntityForVnfArtifact.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/mixins/MixinFeatureGroupEntity.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/mixins/MixinFeatureGroupModel.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/mixins/MixinLicenseKeyGroupEntityForVendorLicenseArtifact.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/mixins/MixinLicenseKeyGroupEntityForVnfArtifact.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-license-lib/pom.xml create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/pom.xml create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/VendorSoftwareProductConstants.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ComponentArtifactDao.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ComponentArtifactDaoFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ComponentDao.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ComponentDaoFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/NetworkDao.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/NetworkDaoFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/NicDao.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/NicDaoFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/PackageInfoDao.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/PackageInfoDaoFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ProcessArtifactDao.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ProcessArtifactDaoFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ProcessDao.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ProcessDaoFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/UploadDataDao.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/UploadDataDaoFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/VendorSoftwareProductDao.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/VendorSoftwareProductDaoFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/VendorSoftwareProductInfoDao.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/VendorSoftwareProductInfoDaoFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/VspQuestionnaireDao.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/VspQuestionnaireDaoFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/Action.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/ComponentArtifactEntity.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/ComponentEntity.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/CompositionEntity.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/NetworkEntity.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/NicEntity.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/PackageInfo.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/ProcessArtifactEntity.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/ProcessEntity.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/TranslatedFileData.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/UploadDataEntity.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/VspDetails.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/VspQuestionnaireEntity.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/Component.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/ComponentData.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/CompositionData.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/CompositionDataEntity.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/CompositionEntityId.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/CompositionEntityType.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/Network.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/NetworkType.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/Nic.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/resources/factoryConfiguration.json create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/pom.xml create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/ComponentArtifactDaoCassandraImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/ComponentArtifactDaoFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/ComponentDaoCassandraImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/ComponentDaoFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/NetworkDaoCassandraImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/NetworkDaoFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/NicDaoCassandraImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/NicDaoFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/PackageInfoDaoFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/PackageInfoDaoImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/ProcessArtifactDaoCassandraImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/ProcessArtifactDaoFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/ProcessDaoCassandraImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/ProcessDaoFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/UploadDataDaoFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/UploadDataDaoImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/VendorSoftwareProductDaoFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/VendorSoftwareProductDaoImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/VendorSoftwareProductInfoDaoFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/VendorSoftwareProductInfoDaoImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/VspQuestionnaireDaoCassandraImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/VspQuestionnaireDaoFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ServiceModelDaoFactoryTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/pom.xml create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/pom.xml create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/VersioningManager.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/VersioningManagerFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/VersioningUtil.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionHistoryDao.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionHistoryDaoFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionInfoDao.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionInfoDaoFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionInfoDeletedDao.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionInfoDeletedDaoFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionableDao.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionableEntityDao.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionableEntityDaoFactory.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/UserCandidateVersion.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/Version.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/VersionHistoryEntity.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/VersionInfoDeletedEntity.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/VersionInfoEntity.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/VersionStatus.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/VersionType.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/VersionableEntity.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/VersionableEntityId.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/CheckinOnEntityLockedByOtherErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/CheckinOnUnlockedEntityErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/CheckoutOnLockedEntityErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/DeleteOnLockedEntityErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/EditOnEntityLockedByOtherErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/EditOnUnlockedEntityErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/EntityAlreadyExistErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/EntityAlreadyFinalizedErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/EntityNotExistErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/RequestedVersionInvalidErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/SubmitLockedEntityNotAllowedErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/UndoCheckoutOnEntityLockedByOtherErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/UndoCheckoutOnUnlockedEntityErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/VersionableSubEntityNotFoundErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/VersioningErrorCodes.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/types/UniqueValueMetadata.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/types/VersionInfo.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/types/VersionableEntityAction.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/types/VersionableEntityMetadata.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/resources/factoryConfiguration.json create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/pom.xml create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionHistoryCassandraDaoImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionHistoryDaoFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionInfoDaoFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionInfoDaoImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionInfoDeletedDaoFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionInfoDeletedDaoImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionableEntityDaoCassandraImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionableEntityDaoFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/impl/VersioningManagerFactoryImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/impl/VersioningManagerImpl.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/test/java/org/openecomp/sdc/versioning/VersioningManagerTest.java create mode 100644 openecomp-be/lib/openecomp-sdc-versioning-lib/pom.xml create mode 100644 openecomp-be/lib/openecomp-tosca-lib/pom.xml create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaArtifactType.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaCapabilityType.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaDataType.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaElementTypes.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaFunctions.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaGroupType.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaNodeType.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaPolicyType.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaRelationshipType.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaServiceModel.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/ArtifactDefinition.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/ArtifactType.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/AttributeDefinition.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/CapabilityAssignment.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/CapabilityDefinition.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/CapabilityFilterDefinition.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/CapabilityType.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/Constraint.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/DataType.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/Directive.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/EntrySchema.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/GroupDefinition.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/GroupType.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/Import.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/InterfaceDefinition.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/InterfaceType.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/Metadata.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/NodeFilter.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/NodeTemplate.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/NodeType.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/ParameterDefinition.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/PolicyDefinition.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/PolicyType.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/PropertyDefinition.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/PropertyType.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/RelationshipTemplate.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/RelationshipType.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/RequirementAssignment.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/RequirementDefinition.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/Scalar.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/ServiceTemplate.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/Status.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/SubstitutionMapping.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/Template.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/TopologyTemplate.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/heatextend/ParameterDefinitionExt.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/heatextend/PropertyTypeExt.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/InvalidAddActionNullEntityErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/InvalidRequirementAssignmentErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/ToscaErrorCodes.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/ToscaInvalidEntryNotFoundErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/ToscaInvalidSubstituteNodeTemplateErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/ToscaInvalidSubstituteNodeTemplatePropertiesErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/ToscaInvalidSubstitutionServiceTemplateErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/ToscaMissingSubstitutionMappingForReqCapErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/ToscaNodeTypeNotFoundErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/exceptions/CsarCreationErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/exceptions/CsarMissingEntryPointErrorBuilder.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/DataModelUtil.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/ToscaAnalyzerService.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/ToscaConstants.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/ToscaFileOutputService.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/ToscaNativeTypesServiceTemplate.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/ToscaUtil.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/impl/ToscaAnalyzerServiceImpl.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/impl/ToscaFileOutputServiceCsarImpl.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/yamlutil/ToscaExtensionYamlUtil.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/test/java/org/openecomp/sdc/tosca/TestUtil.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/test/java/org/openecomp/sdc/tosca/datatypes/PropertyTypeTest.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/test/java/org/openecomp/sdc/tosca/datatypes/ToscaModelTest.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/test/java/org/openecomp/sdc/tosca/datatypes/model/CapabilityDefinitionTest.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/test/java/org/openecomp/sdc/tosca/datatypes/model/RequirementDefinitionTest.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/test/java/org/openecomp/sdc/tosca/services/DataModelUtilTest.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/test/java/org/openecomp/sdc/tosca/services/impl/ToscaAnalyzerServiceImplTest.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/test/java/org/openecomp/sdc/tosca/services/impl/ToscaFileOutputServiceCsarImplTest.java create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/analyzerService/NestedServiceTemplateReqTest.yaml create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/analyzerService/ServiceTemplateSubstituteTest.yaml create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/analyzerService/toscasubstitution/MainServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/analyzerService/toscasubstitution/nestedServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/AbstractSubstituteGlobalTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/CinderVolumeGlobalTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/CommonGlobalTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/ContrailNetworkRuleGlobalTypeServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/GlobalSubstitutionTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/NativeTypesServiceTemplateServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/NeutronNetGlobalTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/NeutronPortGlobalTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/NeutronSecurityRulesGlobalTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/NovaServerGlobalTypesServiceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/model/serviceTemplate.yaml create mode 100644 openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/model/serviceTemplateHeatExtend.yaml create mode 100644 openecomp-be/lib/pom.xml create mode 100644 openecomp-be/logs/ASDC/Debug.1.log.zip create mode 100644 openecomp-be/logs/ASDC/Debug.2.log.zip create mode 100644 openecomp-be/logs/ASDC/Debug.3.log.zip create mode 100644 openecomp-be/logs/ASDC/Debug.4.log.zip create mode 100644 openecomp-be/logs/ASDC/Debug.5.log.zip create mode 100644 openecomp-be/logs/ASDC/Debug.6.log.zip create mode 100644 openecomp-be/pom.xml create mode 100644 openecomp-be/readMe.txt create mode 100644 openecomp-be/tools/build/scripts/action_library_client/action_library_client.py create mode 100644 openecomp-be/tools/build/scripts/action_library_client/doc/TESTPLAN.TXT create mode 100644 openecomp-be/tools/build/scripts/action_library_client/test/scenarios/Backout.json create mode 100644 openecomp-be/tools/build/scripts/action_library_client/test/scenarios/Copy_image.json create mode 100644 openecomp-be/tools/build/scripts/action_library_client/test/scenarios/Healthcheck.json create mode 100644 openecomp-be/tools/build/scripts/action_library_client/test/scenarios/Reboot.json create mode 100644 openecomp-be/tools/build/scripts/action_library_client/test/seq.txt create mode 100644 openecomp-be/tools/build/scripts/action_library_client/test/test_action_library_client.py create mode 100644 openecomp-be/tools/build/scripts/action_library_client/test/test_action_library_client_integration.py create mode 100644 openecomp-be/tools/build/scripts/cassandra-commands.json create mode 100644 openecomp-be/tools/build/scripts/generate-application-config-insert-cql.sh create mode 100644 openecomp-be/tools/build/scripts/generate-cassandra-alter-cql.sh create mode 100644 openecomp-be/tools/build/scripts/generate-cassandra-drop-cql.sh create mode 100644 openecomp-be/tools/build/scripts/generate-cassandra-init-cql.sh create mode 100644 openecomp-be/tools/build/scripts/parse-json.py create mode 100644 openecomp-be/tools/install/database/monitoring/component/ceilometer.ftl create mode 100644 openecomp-be/tools/install/database/schemaTemplates/composition/component.ftl create mode 100644 openecomp-be/tools/install/database/schemaTemplates/composition/network.ftl create mode 100644 openecomp-be/tools/install/database/schemaTemplates/composition/nic.ftl create mode 100644 openecomp-be/tools/install/database/schemaTemplates/questionnaire/component.ftl create mode 100644 openecomp-be/tools/install/database/schemaTemplates/questionnaire/nic.ftl create mode 100644 openecomp-be/tools/install/database/schemaTemplates/questionnaire/vsp.ftl create mode 100644 openecomp-be/tools/migration/1607_to_1610.py create mode 100644 openecomp-be/tools/migration/README create mode 100644 openecomp-be/tools/scripts/generate-manifest.py create mode 100644 openecomp-be/tools/swagger-ui/WEB-INF/jetty-web.xml create mode 100644 openecomp-be/tools/swagger-ui/api-docs/api.html create mode 100644 openecomp-be/tools/swagger-ui/api-docs/api.json create mode 100644 openecomp-be/tools/swagger-ui/assembly/swagger.xml create mode 100644 openecomp-be/tools/swagger-ui/css/ncso-style.css create mode 100644 openecomp-be/tools/swagger-ui/css/print.css create mode 100644 openecomp-be/tools/swagger-ui/css/reset.css create mode 100644 openecomp-be/tools/swagger-ui/css/screen.css create mode 100644 openecomp-be/tools/swagger-ui/css/style.css create mode 100644 openecomp-be/tools/swagger-ui/css/typography.css create mode 100644 openecomp-be/tools/swagger-ui/fonts/droid-sans-v6-latin-700.eot create mode 100644 openecomp-be/tools/swagger-ui/fonts/droid-sans-v6-latin-700.svg create mode 100644 openecomp-be/tools/swagger-ui/fonts/droid-sans-v6-latin-700.ttf create mode 100644 openecomp-be/tools/swagger-ui/fonts/droid-sans-v6-latin-700.woff create mode 100644 openecomp-be/tools/swagger-ui/fonts/droid-sans-v6-latin-700.woff2 create mode 100644 openecomp-be/tools/swagger-ui/fonts/droid-sans-v6-latin-regular.eot create mode 100644 openecomp-be/tools/swagger-ui/fonts/droid-sans-v6-latin-regular.svg create mode 100644 openecomp-be/tools/swagger-ui/fonts/droid-sans-v6-latin-regular.ttf create mode 100644 openecomp-be/tools/swagger-ui/fonts/droid-sans-v6-latin-regular.woff create mode 100644 openecomp-be/tools/swagger-ui/fonts/droid-sans-v6-latin-regular.woff2 create mode 100644 openecomp-be/tools/swagger-ui/images/Thumbs.db create mode 100644 openecomp-be/tools/swagger-ui/images/explorer_icons.png create mode 100644 openecomp-be/tools/swagger-ui/images/favicon-16x16.png create mode 100644 openecomp-be/tools/swagger-ui/images/favicon-32x32.png create mode 100644 openecomp-be/tools/swagger-ui/images/favicon.ico create mode 100644 openecomp-be/tools/swagger-ui/images/logo_small.png create mode 100644 openecomp-be/tools/swagger-ui/images/pet_store_api.png create mode 100644 openecomp-be/tools/swagger-ui/images/throbber.gif create mode 100644 openecomp-be/tools/swagger-ui/images/wordnik_api.png create mode 100644 openecomp-be/tools/swagger-ui/index.html create mode 100644 openecomp-be/tools/swagger-ui/lang/en.js create mode 100644 openecomp-be/tools/swagger-ui/lang/es.js create mode 100644 openecomp-be/tools/swagger-ui/lang/ja.js create mode 100644 openecomp-be/tools/swagger-ui/lang/pt.js create mode 100644 openecomp-be/tools/swagger-ui/lang/ru.js create mode 100644 openecomp-be/tools/swagger-ui/lang/tr.js create mode 100644 openecomp-be/tools/swagger-ui/lang/translator.js create mode 100644 openecomp-be/tools/swagger-ui/lang/zh-cn.js create mode 100644 openecomp-be/tools/swagger-ui/lib/backbone-min.js create mode 100644 openecomp-be/tools/swagger-ui/lib/handlebars-2.0.0.js create mode 100644 openecomp-be/tools/swagger-ui/lib/highlight.7.3.pack.js create mode 100644 openecomp-be/tools/swagger-ui/lib/jquery-1.8.0.min.js create mode 100644 openecomp-be/tools/swagger-ui/lib/jquery.ba-bbq.min.js create mode 100644 openecomp-be/tools/swagger-ui/lib/jquery.slideto.min.js create mode 100644 openecomp-be/tools/swagger-ui/lib/jquery.wiggle.min.js create mode 100644 openecomp-be/tools/swagger-ui/lib/marked.js create mode 100644 openecomp-be/tools/swagger-ui/lib/swagger-oauth.js create mode 100644 openecomp-be/tools/swagger-ui/lib/underscore-min.js create mode 100644 openecomp-be/tools/swagger-ui/lib/underscore-min.map create mode 100644 openecomp-be/tools/swagger-ui/o2c.html create mode 100644 openecomp-be/tools/swagger-ui/pom.xml create mode 100644 openecomp-be/tools/swagger-ui/swagger-ui.js create mode 100644 openecomp-be/tools/swagger-ui/swagger-ui.min.js create mode 100644 openecomp-be/tools/test.push diff --git a/openecomp-be/.gitignore b/openecomp-be/.gitignore new file mode 100644 index 0000000000..2c9567e1a0 --- /dev/null +++ b/openecomp-be/.gitignore @@ -0,0 +1,13 @@ +target +package +.settings +.project +.classpath +.idea + +*.log + +### idea files +*.iml +*.ipr +*.iws diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/action-library-rest-services/pom.xml b/openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/action-library-rest-services/pom.xml new file mode 100644 index 0000000000..23ba4e8c64 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/action-library-rest-services/pom.xml @@ -0,0 +1,130 @@ + + + 4.0.0 + + + org.openecomp.sdc.onboarding + action-library-rest + 1.0.0-SNAPSHOT + + + action-library-rest-services + + + + + ${project.build.directory}/generated-sources/error-codes + + + + + ${project.groupId} + action-library-rest-types + ${project.version} + + + + + org.springframework + spring-core + ${spring.framework.version} + + + org.springframework + spring-context + ${spring.framework.version} + + + org.springframework + spring-context-support + ${spring.framework.version} + + + org.springframework + spring-web + ${spring.framework.version} + + + org.springframework + spring-beans + ${spring.framework.version} + + + + + org.apache.cxf + cxf-rt-frontend-jaxrs + ${cxf.version} + + + + org.apache.httpcomponents + httpclient + ${http.client.version} + + + org.apache.httpcomponents + httpcore + ${http.client.version} + + + + javax.ws.rs + javax.ws.rs-api + ${ws.rs.version} + + + + + cglib + cglib-nodep + ${cglib.nodep.version} + runtime + + + + + javax.inject + javax.inject + ${javax.inject.version} + provided + + + org.openecomp.sdc + openecomp-sdc-action-manager + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-action-api + ${project.version} + + + org.openecomp.sdc.sdc_common + openecomp-logging-api + ${project.version} + + + + + + + + org.apache.maven.plugins + maven-surefire-plugin + + + test/core/unittest/offline/** + + true + + + + + + + + + \ No newline at end of file diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/action-library-rest-services/src/main/java/org/openecomp/sdcrests/action/rest/Actions.java b/openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/action-library-rest-services/src/main/java/org/openecomp/sdcrests/action/rest/Actions.java new file mode 100644 index 0000000000..c7e3bbddec --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/action-library-rest-services/src/main/java/org/openecomp/sdcrests/action/rest/Actions.java @@ -0,0 +1,206 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.action.rest; + +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import org.apache.cxf.jaxrs.ext.multipart.Attachment; +import org.apache.cxf.jaxrs.ext.multipart.Multipart; +import org.openecomp.sdcrests.action.types.ActionResponseDto; +import org.springframework.validation.annotation.Validated; + +import javax.servlet.http.HttpServletRequest; +import javax.ws.rs.Consumes; +import javax.ws.rs.DELETE; +import javax.ws.rs.GET; +import javax.ws.rs.HeaderParam; +import javax.ws.rs.POST; +import javax.ws.rs.PUT; +import javax.ws.rs.Path; +import javax.ws.rs.PathParam; +import javax.ws.rs.Produces; +import javax.ws.rs.QueryParam; +import javax.ws.rs.core.Context; +import javax.ws.rs.core.MediaType; +import javax.ws.rs.core.Response; + +/** + * Defines various CRUD API that can be performed on Action. + */ +@Path("/workflow/v1.0/actions") +@Produces(MediaType.APPLICATION_JSON) +@Consumes(MediaType.APPLICATION_JSON) +@Api(value = "Actions") +@Validated +public interface Actions { + + /** + * List All Major, Last Minor and Candidate version if any for Given Action Invariant UUID + * + * @return List of All Major, Last Minor and Candidate version if any Of Action with given + actionInvariantUuId. If actionUUID is provided then only action with given actionInvariantUuId + and actionUUID + */ + @GET + @Path("/{actionInvariantUUID}") + @ApiOperation(value = "List Actions For Given Action Invariant UUID", responseContainer = "List") + Response getActionsByActionInvariantUuId( + @PathParam("actionInvariantUUID") String actionInvariantUuId, + @QueryParam("version") String actionUuId, @Context HttpServletRequest servletRequest); + + /** + * Get list of actions based on a filter criteria. If no filter is sent all actions will + be returned + * + * @return List Of Last Major and Last Minor of All Actions based on filter criteria + */ + @GET + @ApiOperation(value = "List Filtered Actions ", + notes = "Get list of actions based on a filter criteria | If no filter is sent all actions " + + "will be returned", + responseContainer = "List") + Response getFilteredActions(@QueryParam("vendor") String vendor, + @QueryParam("category") String category, + @QueryParam("name") String name, + @QueryParam("modelId") String modelId, + @QueryParam("componentId") String componentId, + @Context HttpServletRequest servletRequest); + + /** + * List ECOMP Components supported by Action Library. + * + * @return List of ECOMP Components supported by Action Library. + */ + @GET + @Path("/components") + @ApiOperation(value = "List ECOMP Components supported by Action Library", + responseContainer = "List") + Response getEcompComponents(@Context HttpServletRequest servletRequest); + + /** + * Create a new Action based on request JSON. + * + * @return Metadata object {@link ActionResponseDto ActionResponseDto} object for created Action. + */ + @POST + @ApiOperation(value = "Create a new Action") + Response createAction(String requestJson, @Context HttpServletRequest servletRequest); + + /** + * Update an existing action with parameters provided in requestJson. + * + * @return Metadata object {@link ActionResponseDto ActionResponseDto} object for created Action. + */ + @PUT + @Path("/{actionInvariantUUID}") + @ApiOperation(value = "Update an existing action") + Response updateAction(@PathParam("actionInvariantUUID") String actionInvariantUuId, + String requestJson, @Context HttpServletRequest servletRequest); + + /** + * Delete an action. + * + * @param actionInvariantUuId Invariant UUID of the action to be deleted. + * @param servletRequest Servlet request object. + * @return Empty response object. + */ + @DELETE + @Path("/{actionInvariantUUID}") + @ApiOperation(value = "Delete Action") + Response deleteAction(@PathParam("actionInvariantUUID") String actionInvariantUuId, + @Context HttpServletRequest servletRequest); + + /** + * Performs Checkout/Undo_Checkout/Checkin/Submit Operation on Action. + * + * @return Metadata object {@link ActionResponseDto ActionResponseDto} object for created Action. + */ + @POST + @Path("/{actionInvariantUUID}") + @ApiOperation(value = "Actions on a action", + notes = "Performs one of the following actions on a action: |" + + "Checkout: Locks it for edits by other users. Only the locking user sees the edited " + + "version.|" + + "Undo_Checkout: Unlocks it and deletes the edits that were done.|" + + "Checkin: Unlocks it and activates the edited version to all users.| " + + "Submit: Finalize its active version.|") + Response actOnAction(@PathParam("actionInvariantUUID") String actionInvariantUuId, + String requestJson, @Context HttpServletRequest servletRequest); + + /** + * Upload an artifact to an action. + * + * @param actionInvariantUuId Invariant UUID of the action to which the artifact is uploaded. + * @param artifactName Name of the artifact. + * @param artifactLabel Label of the artifact. + * @param artifactCategory Category of the artifact. + * @param artifactDescription Description of the artifact. + * @param artifactProtection Artifact protection mode. + * @param checksum Checksum of the artifact. + * @param artifactToUpload Artifact content object. + * @param servletRequest Servlet request object. + * @return Generated UUID of the uploaded artifact. + */ + @POST + @Path("/{actionInvariantUUID}/artifacts") + @ApiOperation(value = "Upload new Artifact") + @Consumes(MediaType.MULTIPART_FORM_DATA) + Response uploadArtifact(@PathParam("actionInvariantUUID") String actionInvariantUuId, + @Multipart(value = "artifactName", required = false) String artifactName, + @Multipart(value = "artifactLabel", required = false) String artifactLabel, + @Multipart(value = "artifactCategory", required = false) String artifactCategory, + @Multipart(value = "artifactDescription", required = false) String artifactDescription, + @Multipart(value = "artifactProtection", required = false) String artifactProtection, + @HeaderParam("Content-MD5") String checksum, + @Multipart(value = "uploadArtifact", required = false) Attachment artifactToUpload, + @Context HttpServletRequest servletRequest); + + @GET + @Path("/{actionUUID}/artifacts/{artifactUUID}") + @Produces(MediaType.APPLICATION_OCTET_STREAM) + @ApiOperation(value = "Downloads artifact for action") + Response downloadArtifact(@PathParam("actionUUID") String actionUuId, + @PathParam("artifactUUID") String artifactUuId, + @Context HttpServletRequest servletRequest); + + @DELETE + @Path("/{actionInvariantUUID}/artifacts/{artifactUUID}") + @ApiOperation(value = "Delete Artifact") + Response deleteArtifact(@PathParam("actionInvariantUUID") String actionInvariantUuId, + @PathParam("artifactUUID") String artifactUuId, + @Context HttpServletRequest servletRequest); + + @PUT + @Path("/{actionInvariantUUID}/artifacts/{artifactUUID}") + @ApiOperation(value = "Update an existing artifact") + @Consumes(MediaType.MULTIPART_FORM_DATA) + Response updateArtifact(@PathParam("actionInvariantUUID") String actionInvariantUuId, + @PathParam("artifactUUID") String artifactUuId, + @Multipart(value = "artifactName", required = false) String artifactName, + @Multipart(value = "artifactLabel", required = false) String artifactLabel, + @Multipart(value = "artifactCategory", required = false) String artifactCategory, + @Multipart(value = "artifactDescription", required = false) String artifactDescription, + @Multipart(value = "artifactProtection", required = false) String artifactProtection, + @HeaderParam("Content-MD5") String checksum, + @Multipart(value = "updateArtifact", required = false) Attachment artifactToUpdate, + @Context HttpServletRequest servletRequest); + +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/action-library-rest-services/src/main/java/org/openecomp/sdcrests/action/rest/mapping/MapActionToActionResponseDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/action-library-rest-services/src/main/java/org/openecomp/sdcrests/action/rest/mapping/MapActionToActionResponseDto.java new file mode 100644 index 0000000000..27d3f482c7 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/action-library-rest-services/src/main/java/org/openecomp/sdcrests/action/rest/mapping/MapActionToActionResponseDto.java @@ -0,0 +1,42 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.action.rest.mapping; + +import org.openecomp.sdc.action.types.Action; +import org.openecomp.sdcrests.action.types.ActionResponseDto; +import org.openecomp.sdcrests.mapping.MappingBase; + + +/** + * Maps Source Action Object To Action Response DTO. + */ +public class MapActionToActionResponseDto extends MappingBase { + + @Override + public void doMapping(Action source, ActionResponseDto target) { + target.setActionUuId(source.getActionUuId()); + target.setActionInvariantUuId(source.getActionInvariantUuId()); + target.setVersion(source.getVersion()); + if (source.getStatus() != null) { + target.setStatus(source.getStatus().name()); + } + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/action-library-rest-services/src/main/java/org/openecomp/sdcrests/action/rest/services/ActionsImpl.java b/openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/action-library-rest-services/src/main/java/org/openecomp/sdcrests/action/rest/services/ActionsImpl.java new file mode 100644 index 0000000000..7e9cca0e0b --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/action-library-rest-services/src/main/java/org/openecomp/sdcrests/action/rest/services/ActionsImpl.java @@ -0,0 +1,1212 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.action.rest.services; + +import static org.openecomp.sdc.action.ActionConstants.ACTION_REQUEST_PARAM_END_POINT_URI; +import static org.openecomp.sdc.action.ActionConstants.ACTION_REQUEST_PARAM_NAME; +import static org.openecomp.sdc.action.ActionConstants.ACTION_REQUEST_PARAM_SUPPORTED_COMPONENTS; +import static org.openecomp.sdc.action.ActionConstants.ACTION_REQUEST_PARAM_SUPPORTED_MODELS; +import static org.openecomp.sdc.action.ActionConstants.ARTIFACT_FILE; +import static org.openecomp.sdc.action.ActionConstants.ARTIFACT_NAME; +import static org.openecomp.sdc.action.ActionConstants.BE_FQDN; +import static org.openecomp.sdc.action.ActionConstants.CATEGORY_LOG_LEVEL; +import static org.openecomp.sdc.action.ActionConstants.CLIENT_IP; +import static org.openecomp.sdc.action.ActionConstants.ERROR_DESCRIPTION; +import static org.openecomp.sdc.action.ActionConstants.FILTER_TYPE_CATEGORY; +import static org.openecomp.sdc.action.ActionConstants.FILTER_TYPE_ECOMP_COMPONENT; +import static org.openecomp.sdc.action.ActionConstants.FILTER_TYPE_MODEL; +import static org.openecomp.sdc.action.ActionConstants.FILTER_TYPE_NAME; +import static org.openecomp.sdc.action.ActionConstants.FILTER_TYPE_NONE; +import static org.openecomp.sdc.action.ActionConstants.FILTER_TYPE_VENDOR; +import static org.openecomp.sdc.action.ActionConstants.INSTANCE_UUID; +import static org.openecomp.sdc.action.ActionConstants.LOCAL_ADDR; +import static org.openecomp.sdc.action.ActionConstants.MAX_ACTION_ARTIFACT_SIZE; +import static org.openecomp.sdc.action.ActionConstants.MDC_ASDC_INSTANCE_UUID; +import static org.openecomp.sdc.action.ActionConstants.PARTNER_NAME; +import static org.openecomp.sdc.action.ActionConstants.REMOTE_HOST; +import static org.openecomp.sdc.action.ActionConstants.REQUEST_EMPTY_BODY; +import static org.openecomp.sdc.action.ActionConstants.REQUEST_ID; +import static org.openecomp.sdc.action.ActionConstants.REQUEST_TYPE_CREATE_ACTION; +import static org.openecomp.sdc.action.ActionConstants.REQUEST_TYPE_UPDATE_ACTION; +import static org.openecomp.sdc.action.ActionConstants.REQUEST_TYPE_VERSION_ACTION; +import static org.openecomp.sdc.action.ActionConstants.SERVICE_INSTANCE_ID; +import static org.openecomp.sdc.action.ActionConstants.SERVICE_METRIC_BEGIN_TIMESTAMP; +import static org.openecomp.sdc.action.ActionConstants.SERVICE_NAME; +import static org.openecomp.sdc.action.ActionConstants.STATUS; +import static org.openecomp.sdc.action.ActionConstants.STATUS_CODE; +import static org.openecomp.sdc.action.ActionConstants.SUPPORTED_COMPONENTS_ID; +import static org.openecomp.sdc.action.ActionConstants.SUPPORTED_MODELS_VERSION_ID; +import static org.openecomp.sdc.action.ActionConstants.TARGET_ENTITY; +import static org.openecomp.sdc.action.ActionConstants.TARGET_ENTITY_API; +import static org.openecomp.sdc.action.ActionConstants.TARGET_SERVICE_NAME; +import static org.openecomp.sdc.action.ActionConstants.TIMESTAMP; +import static org.openecomp.sdc.action.ActionConstants.UPDATED_BY; +import static org.openecomp.sdc.action.ActionConstants.X_ECOMP_INSTANCE_ID_HEADER_PARAM; +import static org.openecomp.sdc.action.ActionConstants.X_ECOMP_REQUEST_ID_HEADER_PARAM; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ARTIFACT_CHECKSUM_ERROR_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ARTIFACT_INVALID_NAME; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ARTIFACT_INVALID_NAME_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ARTIFACT_INVALID_PROTECTION_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ARTIFACT_READ_FILE_ERROR; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ARTIFACT_TOO_BIG_ERROR; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ARTIFACT_TOO_BIG_ERROR_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ENTITY_INTERNAL_SERVER_ERROR_MSG; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ENTITY_NOT_EXIST; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ENTITY_NOT_EXIST_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_FILTER_MULTIPLE_QUERY_PARAM_NOT_SUPPORTED; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_INTERNAL_SERVER_ERR_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_INVALID_INSTANCE_ID_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_INVALID_PARAM_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_INVALID_REQUEST_BODY_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_INVALID_REQUEST_ID_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_INVALID_SEARCH_CRITERIA; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_MULT_SEARCH_CRITERIA; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_REQUEST_ARTIFACT_CHECKSUM_ERROR; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_REQUEST_ARTIFACT_INVALID_PROTECTION_VALUE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_REQUEST_ARTIFACT_OPERATION_ALLOWED; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_REQUEST_BODY_EMPTY; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_REQUEST_CONTENT_TYPE_INVALID; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_REQUEST_ECOMP_INSTANCE_ID_INVALID; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_REQUEST_ECOMP_REQUEST_ID_INVALID; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_REQUEST_FILTER_PARAM_INVALID; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_REQUEST_INVALID_GENERIC_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_REQUEST_INVALID_NAME; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_REQUEST_MISSING_MANDATORY_PARAM; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_UNSUPPORTED_OPERATION; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_UPDATE_NOT_ALLOWED_CODE; +import static org.openecomp.sdc.action.util.ActionUtil.actionErrorLogProcessor; +import static org.openecomp.sdc.action.util.ActionUtil.actionLogPostProcessor; + +import org.apache.commons.codec.digest.DigestUtils; +import org.apache.commons.lang3.StringUtils; +import org.apache.cxf.jaxrs.ext.multipart.Attachment; +import org.openecomp.core.logging.api.Logger; +import org.openecomp.core.logging.api.LoggerFactory; +import org.openecomp.core.utilities.file.FileUtils; +import org.openecomp.core.utilities.json.JsonUtil; +import org.openecomp.sdc.action.ActionConstants; +import org.openecomp.sdc.action.ActionManager; +import org.openecomp.sdc.action.errors.ActionErrorConstants; +import org.openecomp.sdc.action.errors.ActionException; +import org.openecomp.sdc.action.logging.CategoryLogLevel; +import org.openecomp.sdc.action.logging.StatusCode; +import org.openecomp.sdc.action.types.Action; +import org.openecomp.sdc.action.types.ActionArtifact; +import org.openecomp.sdc.action.types.ActionArtifactProtection; +import org.openecomp.sdc.action.types.ActionRequest; +import org.openecomp.sdc.action.types.EcompComponent; +import org.openecomp.sdcrests.action.rest.Actions; +import org.openecomp.sdcrests.action.rest.mapping.MapActionToActionResponseDto; +import org.openecomp.sdcrests.action.types.ActionResponseDto; +import org.openecomp.sdcrests.action.types.ActionVersionDto; +import org.openecomp.sdcrests.action.types.ListResponseWrapper; +import org.openecomp.sdcrests.wrappers.StringWrapperResponse; +import org.slf4j.MDC; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.context.annotation.Scope; +import org.springframework.stereotype.Service; +import org.springframework.validation.annotation.Validated; + +import java.io.File; +import java.io.FileOutputStream; +import java.io.IOException; +import java.io.InputStream; +import java.text.DateFormat; +import java.text.SimpleDateFormat; +import java.util.ArrayList; +import java.util.Date; +import java.util.HashMap; +import java.util.LinkedHashMap; +import java.util.List; +import java.util.Map; +import java.util.TimeZone; +import javax.inject.Named; +import javax.servlet.http.HttpServletRequest; +import javax.ws.rs.core.Response; + + + +/** + * Implements various CRUD API that can be performed on Action. + */ +@SuppressWarnings("ALL") +@Named +@Service("actions") +@Scope(value = "prototype") +@Validated +public class ActionsImpl implements Actions { + + @Autowired + private ActionManager actionManager; + private final Logger log = (Logger) LoggerFactory.getLogger(this.getClass().getName()); + + private String whitespaceCharacters = "\\s" /* dummy empty string for homogeneity */ + + "\\u0009" // CHARACTER TABULATION + + "\\u000A" // LINE FEED (LF) + + "\\u000B" // LINE TABULATION + + "\\u000C" // FORM FEED (FF) + + "\\u000D" // CARRIAGE RETURN (CR) + + "\\u0020" // SPACE + + "\\u0085" // NEXT LINE (NEL) + + "\\u00A0" // NO-BREAK SPACE + + "\\u1680" // OGHAM SPACE MARK + + "\\u180E" // MONGOLIAN VOWEL SEPARATOR + + "\\u2000" // EN QUAD + + "\\u2001" // EM QUAD + + "\\u2002" // EN SPACE + + "\\u2003" // EM SPACE + + "\\u2004" // THREE-PER-EM SPACE + + "\\u2005" // FOUR-PER-EM SPACE + + "\\u2006" // SIX-PER-EM SPACE + + "\\u2007" // FIGURE SPACE + + "\\u2008" // PUNCTUATION SPACE + + "\\u2009" // THIN SPACE + + "\\u200A" // HAIR SPACE + + "\\u2028" // LINE SEPARATOR + + "\\u2029" // PARAGRAPH SEPARATOR + + "\\u202F" // NARROW NO-BREAK SPACE + + "\\u205F" // MEDIUM MATHEMATICAL SPACE + + "\\u3000" // IDEOGRAPHIC SPACE + ; + private String invalidFilenameChars = "#<>$+%!`&*'|{}?\"=/:@\\\\"; + private String whitespaceRegex = ".*[" + whitespaceCharacters + "].*"; + private String invalidFilenameRegex = ".*[" + whitespaceCharacters + invalidFilenameChars + "].*"; + + /** + * Calculate the checksum for a given input. + * + * @param input Byte array for which the checksum has to be calculated. + * @return Calculated checksum of the input byte array. + */ + private static String calculateCheckSum(byte[] input) { + String checksum = null; + if (input != null) { + checksum = DigestUtils.md5Hex(input); + } + return checksum; + } + + /** + * Convert timestamp to UTC format date string. + * + * @param timeStamp UTC timestamp to be converted to the UTC Date format. + * @return UTC formatted Date string from timestamp. + */ + public static String getUTCDateStringFromTimestamp(Date timeStamp) { + DateFormat df = new SimpleDateFormat("dd MMM yyyy kk:mm:ss z"); + df.setTimeZone(TimeZone.getTimeZone("GMT")); + return df.format(timeStamp); + } + /** + * Initialize MDC for logging the current request + * @param actionInvariantId Action Invariant Id if available (null otherwise) + * @param servletRequest Request Contecxt object + * @param requestType Current action request (CRUD of Action, Artifact, Version operations) + */ + private void initializeRequestMDC(HttpServletRequest servletRequest, String actionInvariantId, ActionRequest requestType){ + MDC.put(REQUEST_ID, servletRequest.getHeader(X_ECOMP_REQUEST_ID_HEADER_PARAM)); + MDC.put(PARTNER_NAME, servletRequest.getRemoteUser()); + MDC.put(INSTANCE_UUID, MDC_ASDC_INSTANCE_UUID); + MDC.put(SERVICE_METRIC_BEGIN_TIMESTAMP, String.valueOf(System.currentTimeMillis())); + MDC.put(STATUS_CODE, StatusCode.COMPLETE.name()); + MDC.put(SERVICE_NAME, requestType.name()); + MDC.put(CLIENT_IP, MDC.get(REMOTE_HOST)); + MDC.put(SERVICE_INSTANCE_ID, actionInvariantId); + MDC.put(LOCAL_ADDR, MDC.get("ServerIPAddress")); + MDC.put(BE_FQDN, MDC.get("ServerFQDN")); + + if(log.isDebugEnabled()) + MDC.put(CATEGORY_LOG_LEVEL, CategoryLogLevel.DEBUG.name()); + else if(log.isInfoEnabled()) + MDC.put(CATEGORY_LOG_LEVEL, CategoryLogLevel.INFO.name()); + else if(log.isWarnEnabled()) + MDC.put(CATEGORY_LOG_LEVEL, CategoryLogLevel.WARN.name()); + else if(log.isErrorEnabled()) + MDC.put(CATEGORY_LOG_LEVEL, CategoryLogLevel.ERROR.name()); + } + + @Override + public Response getActionsByActionInvariantUuId(String invariantId, String actionUuId, + HttpServletRequest servletRequest) { + ListResponseWrapper responseList = new ListResponseWrapper(); + + try{ + log.debug(" entering getActionsByActionInvariantUUID "); + initializeRequestMDC(servletRequest, invariantId, ActionRequest.GET_ACTIONS_INVARIANT_ID); + MDC.put(SERVICE_INSTANCE_ID, invariantId); + + if(StringUtils.isEmpty(servletRequest.getQueryString())){ + responseList = getActionsByInvId(servletRequest,invariantId); + } else{ + Response response = getActionByUUID(servletRequest, invariantId, actionUuId); + actionLogPostProcessor(StatusCode.COMPLETE, true); + return response; + } + } catch (ActionException e){ + actionLogPostProcessor(StatusCode.ERROR, e.getErrorCode(), e.getDescription(), true); + actionErrorLogProcessor(CategoryLogLevel.ERROR, e.getErrorCode(), e.getDescription()); + log.error(""); + throw e; + } catch (Exception e){ + actionLogPostProcessor(StatusCode.ERROR, true); + actionErrorLogProcessor(CategoryLogLevel.ERROR, ACTION_INTERNAL_SERVER_ERR_CODE, ACTION_ENTITY_INTERNAL_SERVER_ERROR_MSG); + log.error(""); + throw e; + } finally { + finalAuditMetricsLogProcessor(ActionRequest.GET_ACTIONS_INVARIANT_ID.name()); + } + + log.debug(" exit getActionsByActionInvariantUUID " ); + actionLogPostProcessor(StatusCode.COMPLETE, true); + return Response.ok(responseList).build(); + } + + private ListResponseWrapper getActionsByInvId(HttpServletRequest servletRequest, String invariantId){ + log.debug(" entering getActionsByInvId with invariantId= " + invariantId ); + ListResponseWrapper responseList = new ListResponseWrapper(); + if(StringUtils.isEmpty(servletRequest.getQueryString())){ + Map errorMap = validateRequestHeaders(servletRequest); + Map queryParamErrors = validateQueryParam(invariantId); + errorMap.putAll(queryParamErrors); + if(errorMap.isEmpty()) { + List actions = actionManager.getActionsByActionInvariantUuId(invariantId); + List versionList = new ArrayList(); + for (Action action : actions) { + ActionResponseDto responseDTO = createResponseDTO(action); + versionList.add(responseDTO); + } + responseList .setVersions(versionList); + responseList.setActionList(null); + + } else{ + checkAndThrowError(errorMap); + } + } + log.debug(" exit getActionsByInvId with invariantId= " + invariantId ); + return responseList; + } + + private Response getActionByUUID(HttpServletRequest servletRequest, String invariantID, String actionUUID) throws ActionException{ + int noOfFilterParams = 0; + Response response = null; + log.debug(" entering getActionByUUID with invariantID= " + invariantID + " and actionUUID= " + actionUUID); + if(!StringUtils.isEmpty(actionUUID)) { + noOfFilterParams ++; + response = getActionsByUniqueID(actionUUID, servletRequest, invariantID); + } + if(noOfFilterParams == 0) + throw new ActionException(ACTION_INVALID_SEARCH_CRITERIA, ACTION_REQUEST_FILTER_PARAM_INVALID); + + log.debug(" exit getActionByUUID with invariantID= " + invariantID + " and actionUUID= " + actionUUID); + return response; + } + + private void finalAuditMetricsLogProcessor(String targetServiceName) { + MDC.put(TARGET_SERVICE_NAME, targetServiceName); + MDC.put(TARGET_ENTITY, TARGET_ENTITY_API); + log.metrics(""); + log.audit(""); + } + + @Override + public Response getEcompComponents(HttpServletRequest servletRequest) { + try { + log.debug(" entering getECOMPComponents "); + initializeRequestMDC(servletRequest, "", ActionRequest.GET_ECOMP_COMPONENTS); + //Validate request syntax before passing to the manager + Map errorMap = validateRequestHeaders(servletRequest); + checkAndThrowError(errorMap); + ListResponseWrapper response = new ListResponseWrapper(); + List ecompComponents = actionManager.getEcompComponents(); + response.setActionList(null); + response.setComponentList(ecompComponents); + log.debug(" exit getECOMPComponents "); + actionLogPostProcessor(StatusCode.COMPLETE, true); + return Response.ok(response).build(); + }catch (ActionException e){ + actionLogPostProcessor(StatusCode.ERROR, e.getErrorCode(), e.getDescription(), true); + actionErrorLogProcessor(CategoryLogLevel.ERROR, e.getErrorCode(), e.getDescription()); + log.error(""); + throw e; + } + catch (Exception e){ + actionLogPostProcessor(StatusCode.ERROR, true); + actionErrorLogProcessor(CategoryLogLevel.ERROR, ACTION_INTERNAL_SERVER_ERR_CODE, ACTION_ENTITY_INTERNAL_SERVER_ERROR_MSG); + log.error(""); + throw e; + } + finally { + finalAuditMetricsLogProcessor(ActionRequest.GET_ECOMP_COMPONENTS.name()); + } + } + + @Override + public Response getFilteredActions(String vendor, String category, String name, String modelId, + String componentId, HttpServletRequest servletRequest) { + try { + log.debug(" entering getFilteredActions "); + int noOfFilterParams = 0; + Response response = null; + initializeRequestMDC(servletRequest, "", ActionRequest.GET_FILTERED_ACTIONS); + if (!StringUtils.isEmpty(vendor)) { + noOfFilterParams++; + } + if (!StringUtils.isEmpty(category)) { + noOfFilterParams++; + } + if (!StringUtils.isEmpty(name)) { + noOfFilterParams++; + } + if (!StringUtils.isEmpty(modelId)) { + noOfFilterParams++; + } + if (!StringUtils.isEmpty(componentId)) { + noOfFilterParams++; + } + if (StringUtils.isEmpty(servletRequest.getQueryString())) { + response = getAllActions(servletRequest); + log.debug(" exit getFilteredActions "); + actionLogPostProcessor(StatusCode.COMPLETE, true); + return response; + } + if (noOfFilterParams > 1) { + throw new ActionException(ACTION_MULT_SEARCH_CRITERIA, + ACTION_FILTER_MULTIPLE_QUERY_PARAM_NOT_SUPPORTED); + } + if (noOfFilterParams == 0) { + throw new ActionException(ACTION_INVALID_SEARCH_CRITERIA, + ACTION_REQUEST_FILTER_PARAM_INVALID); + } + ListResponseWrapper responseList = null; + if (!StringUtils.isEmpty(vendor)) { + response = getActionsByVendor(vendor, servletRequest); + } else if (!StringUtils.isEmpty(category)) { + response = getActionsByCategory(category, servletRequest); + } else if (!StringUtils.isEmpty(name)) { + response = getActionsByName(name, servletRequest); + } else if (!StringUtils.isEmpty(modelId)) { + response = getActionsByModel(modelId, servletRequest); + } else if (!StringUtils.isEmpty(componentId)) { + response = getActionsByECOMPComponent(componentId, servletRequest); + } else { + throw new ActionException(ACTION_INVALID_PARAM_CODE, ACTION_REQUEST_FILTER_PARAM_INVALID); + } + log.debug(" exit getFilteredActions "); + actionLogPostProcessor(StatusCode.COMPLETE, true); + return response; + } + catch (ActionException e){ + actionLogPostProcessor(StatusCode.ERROR, e.getErrorCode(), e.getDescription(), true); + actionErrorLogProcessor(CategoryLogLevel.ERROR, e.getErrorCode(), e.getDescription()); + log.error(""); + throw e; + } + catch (Exception e){ + actionLogPostProcessor(StatusCode.ERROR, true); + actionErrorLogProcessor(CategoryLogLevel.ERROR, ACTION_INTERNAL_SERVER_ERR_CODE, ACTION_ENTITY_INTERNAL_SERVER_ERROR_MSG); + log.error(""); + throw e; + } + finally { + finalAuditMetricsLogProcessor(ActionRequest.GET_FILTERED_ACTIONS.name()); + } + } + + @Override + public Response createAction(String requestJson, HttpServletRequest servletRequest) { + try { + initializeRequestMDC(servletRequest, null, ActionRequest.CREATE_ACTION); + log.debug(" entering API createAction "); + Map errorMap = validateRequestHeaders(servletRequest); + Map requestBodyErrors = + validateRequestBody(REQUEST_TYPE_CREATE_ACTION, requestJson); + errorMap.putAll(requestBodyErrors); + ActionResponseDto actionResponseDto = new ActionResponseDto(); + if (errorMap.isEmpty()) { + String user = servletRequest.getRemoteUser(); + Action action = JsonUtil.json2Object(requestJson, Action.class); + action.setData(requestJson); + Action responseAction = actionManager.createAction(action, user); + MDC.put(SERVICE_INSTANCE_ID, responseAction.getActionInvariantUuId()); + new MapActionToActionResponseDto().doMapping(responseAction, actionResponseDto); + } else { + checkAndThrowError(errorMap); + } + actionLogPostProcessor(StatusCode.COMPLETE, true); + log.debug(" exit API createAction with ActionInvariantUUID= " + MDC.get(SERVICE_INSTANCE_ID)); + return Response.ok(actionResponseDto).build(); + }catch (ActionException e){ + actionLogPostProcessor(StatusCode.ERROR, e.getErrorCode(), e.getDescription(), true); + actionErrorLogProcessor(CategoryLogLevel.ERROR, e.getErrorCode(), e.getDescription()); + log.error(""); + throw e; + }catch (Exception e){ + actionLogPostProcessor(StatusCode.ERROR, true); + actionErrorLogProcessor(CategoryLogLevel.ERROR, ACTION_INTERNAL_SERVER_ERR_CODE, ACTION_ENTITY_INTERNAL_SERVER_ERROR_MSG); + log.error(e.getMessage()); + throw e; + }finally { + finalAuditMetricsLogProcessor(ActionRequest.CREATE_ACTION.name()); + } + + } + + @Override + public Response updateAction(String actionInvariantUuId, String requestJson, + HttpServletRequest servletRequest) { + try { + initializeRequestMDC(servletRequest, actionInvariantUuId, ActionRequest.UPDATE_ACTION); + log.debug(" entering API updateAction "); + Map errorMap = validateRequestHeaders(servletRequest); + Map requestBodyErrors = + validateRequestBody(REQUEST_TYPE_UPDATE_ACTION, requestJson); + errorMap.putAll(requestBodyErrors); + ActionResponseDto actionResponseDto = new ActionResponseDto(); + if (errorMap.isEmpty()) { + String user = servletRequest.getRemoteUser(); + Action action = JsonUtil.json2Object(requestJson, Action.class); + action.setActionInvariantUuId(actionInvariantUuId); + action.setData(requestJson); + Action updatedAction = actionManager.updateAction(action, user); + new MapActionToActionResponseDto().doMapping(updatedAction, actionResponseDto); + } else { + checkAndThrowError(errorMap); + } + actionLogPostProcessor(StatusCode.COMPLETE, true); + log.debug(" exit API updateAction "); + return Response.ok(actionResponseDto).build(); + }catch (ActionException e){ + actionLogPostProcessor(StatusCode.ERROR, e.getErrorCode(), e.getDescription(), true); + actionErrorLogProcessor(CategoryLogLevel.ERROR, e.getErrorCode(), e.getDescription()); + log.error(""); + throw e; + }catch (Exception e){ + actionLogPostProcessor(StatusCode.ERROR, true); + actionErrorLogProcessor(CategoryLogLevel.ERROR, ACTION_INTERNAL_SERVER_ERR_CODE, ACTION_ENTITY_INTERNAL_SERVER_ERROR_MSG); + log.error(e.getMessage()); + throw e; + }finally { + finalAuditMetricsLogProcessor(ActionRequest.UPDATE_ACTION.name()); + } + } + + @Override + public Response deleteAction(String actionInvariantUuId, HttpServletRequest servletRequest) { + try { + log.debug(" entering API deleteAction "); + initializeRequestMDC(servletRequest, actionInvariantUuId, ActionRequest.DELETE_ACTION); + Map errorMap = validateRequestHeaders(servletRequest); + if (errorMap.isEmpty()) { + String user = servletRequest.getRemoteUser(); + actionManager.deleteAction(actionInvariantUuId, user); + } else { + checkAndThrowError(errorMap); + } + actionLogPostProcessor(StatusCode.COMPLETE, true); + log.debug(" exit API deleteAction "); + return Response.ok(new ActionResponseDto()).build(); + }catch (ActionException e){ + actionLogPostProcessor(StatusCode.ERROR, e.getErrorCode(), e.getDescription(), true); + actionErrorLogProcessor(CategoryLogLevel.ERROR, e.getErrorCode(), e.getDescription()); + log.error(MDC.get(ERROR_DESCRIPTION)); + throw e; + }catch (Exception e){ + actionLogPostProcessor(StatusCode.ERROR,true); + actionErrorLogProcessor(CategoryLogLevel.ERROR, ACTION_INTERNAL_SERVER_ERR_CODE, ACTION_ENTITY_INTERNAL_SERVER_ERROR_MSG); + log.error(e.getMessage()); + throw e; + }finally { + finalAuditMetricsLogProcessor(ActionRequest.DELETE_ACTION.name()); + } + } + + @Override + public Response actOnAction(String actionInvariantUuId, String requestJson, + HttpServletRequest servletRequest) { + Response response = null; + try { + initializeRequestMDC(servletRequest,actionInvariantUuId,ActionRequest.ACTION_VERSIONING); + log.debug("entering actOnAction with invariantUUID= "+ actionInvariantUuId + " and requestJSON= "+ requestJson ); + Map errorMap = validateRequestHeaders(servletRequest); + Map requestBodyErrors = + validateRequestBody(REQUEST_TYPE_VERSION_ACTION, requestJson); + errorMap.putAll(requestBodyErrors); + ActionVersionDto versionDTO = JsonUtil.json2Object(requestJson, ActionVersionDto.class); + checkAndThrowError(errorMap); + + String status = versionDTO.getStatus(); + Action action = new Action(); + String user = servletRequest.getRemoteUser(); + switch (status) { + case "Checkout": + action = actionManager.checkout(actionInvariantUuId, user); + break; + case "Undo_Checkout": + actionManager.undoCheckout(actionInvariantUuId, user); + StringWrapperResponse responseText = new StringWrapperResponse(); + responseText.setValue(ActionConstants.UNDO_CHECKOUT_RESPONSE_TEXT); + response = Response + .status(Response.Status.OK) + .entity(responseText) + .build(); + return response; + case "Checkin": + action = actionManager.checkin(actionInvariantUuId, user); + break; + case "Submit": + action = actionManager.submit(actionInvariantUuId, user); + break; + default: + throw new ActionException(ACTION_INVALID_PARAM_CODE, + String.format(ACTION_UNSUPPORTED_OPERATION, status)); + } + + ActionResponseDto actionResponseDto = new ActionResponseDto(); + new MapActionToActionResponseDto().doMapping(action, actionResponseDto); + response = Response.ok(actionResponseDto).build(); + actionLogPostProcessor(StatusCode.COMPLETE,true); + }catch (ActionException e){ + actionLogPostProcessor(StatusCode.ERROR, e.getErrorCode(), e.getDescription(), true); + actionErrorLogProcessor(CategoryLogLevel.ERROR, e.getErrorCode(), e.getDescription()); + log.error(MDC.get(ERROR_DESCRIPTION)); + throw e; + }catch (Exception e){ + actionLogPostProcessor(StatusCode.ERROR,true); + actionErrorLogProcessor(CategoryLogLevel.ERROR, ACTION_INTERNAL_SERVER_ERR_CODE, ACTION_ENTITY_INTERNAL_SERVER_ERROR_MSG); + log.error(e.getMessage()); + throw e; + }finally { + finalAuditMetricsLogProcessor(ActionRequest.ACTION_VERSIONING.name()); + log.debug("exit actOnAction with invariantUUID= "+ actionInvariantUuId + " and requestJSON= "+ requestJson ); + } + return response; + } + + @Override + public Response uploadArtifact(String actionInvariantUuId, + String artifactName, + String artifactLabel, + String artifactCategory, + String artifactDescription, + String artifactProtection, + String checksum, + Attachment artifactToUpload, + HttpServletRequest servletRequest) { + Response response = null; + try { + initializeRequestMDC(servletRequest,actionInvariantUuId, ActionRequest.UPLOAD_ARTIFACT); + log.debug("entering uploadArtifact with actionInvariantUUID= "+ actionInvariantUuId + "artifactName= "+ artifactName ); + response = uploadArtifactInternal(actionInvariantUuId, artifactName, artifactLabel, artifactCategory, artifactDescription, artifactProtection, checksum, artifactToUpload, servletRequest); + actionLogPostProcessor(StatusCode.COMPLETE,true); + log.debug("exiting uploadArtifact with actionInvariantUUID= "+ actionInvariantUuId + "artifactName= "+ artifactName ); + }catch (ActionException e){ + actionLogPostProcessor(StatusCode.ERROR, e.getErrorCode(), e.getDescription(), true); + actionErrorLogProcessor(CategoryLogLevel.ERROR, e.getErrorCode(), e.getDescription()); + log.error(MDC.get(ERROR_DESCRIPTION)); + throw e; + }catch (Exception e){ + actionLogPostProcessor(StatusCode.ERROR,true); + actionErrorLogProcessor(CategoryLogLevel.ERROR, ACTION_INTERNAL_SERVER_ERR_CODE, ACTION_ENTITY_INTERNAL_SERVER_ERROR_MSG); + log.error(e.getMessage()); + throw e; + }finally { + finalAuditMetricsLogProcessor(ActionRequest.UPLOAD_ARTIFACT.name()); + } + log.debug("exiting uploadArtifact with actionInvariantUUID= "+ actionInvariantUuId + "artifactName= "+ artifactName ); + return response; + } + + private Response uploadArtifactInternal(String actionInvariantUuId, + String artifactName, + String artifactLabel, + String artifactCategory, + String artifactDescription, + String artifactProtection, + String checksum, + Attachment artifactToUpload, + HttpServletRequest servletRequest) { + ListResponseWrapper responseList = null; + byte[] payload = null; + Map errorMap = validateRequestHeaders(servletRequest); + //Artifact name empty validation + if(StringUtils.isEmpty(artifactName)){ + errorMap.put(ACTION_REQUEST_INVALID_GENERIC_CODE, ACTION_REQUEST_MISSING_MANDATORY_PARAM + ARTIFACT_NAME); + }else{ + //Artifact name syntax check for whitespaces and invalid characters + if(artifactName.matches(invalidFilenameRegex)){ + errorMap.put(ACTION_ARTIFACT_INVALID_NAME_CODE, ACTION_ARTIFACT_INVALID_NAME); + } + } + + //Content-Type Header Validation + String contentType = servletRequest.getContentType(); + if(StringUtils.isEmpty(contentType)){ + errorMap.put(ACTION_REQUEST_INVALID_GENERIC_CODE, ACTION_REQUEST_CONTENT_TYPE_INVALID); + } + + if(artifactToUpload == null){ + throw new ActionException(ACTION_REQUEST_INVALID_GENERIC_CODE, ACTION_REQUEST_MISSING_MANDATORY_PARAM + ARTIFACT_FILE); + } + + InputStream artifactInputStream = null; + try { + artifactInputStream = artifactToUpload.getDataHandler().getInputStream(); + } catch (IOException e) { + throw new ActionException(ACTION_INTERNAL_SERVER_ERR_CODE, ACTION_ARTIFACT_READ_FILE_ERROR); + } + + payload = FileUtils.toByteArray(artifactInputStream); + //Validate Artifact size + if(payload != null && payload.length > MAX_ACTION_ARTIFACT_SIZE){ + throw new ActionException(ACTION_ARTIFACT_TOO_BIG_ERROR_CODE, ACTION_ARTIFACT_TOO_BIG_ERROR); + } + + //Validate Checksum + if(StringUtils.isEmpty(checksum) || !checksum.equalsIgnoreCase(calculateCheckSum(payload))){ + errorMap.put(ACTION_ARTIFACT_CHECKSUM_ERROR_CODE, ACTION_REQUEST_ARTIFACT_CHECKSUM_ERROR); + } + + //Validate artifact protection values + if(StringUtils.isEmpty(artifactProtection)) + artifactProtection = ActionArtifactProtection.readWrite.name(); + + if(!artifactProtection.equals(ActionArtifactProtection.readOnly.name()) && !artifactProtection.equals(ActionArtifactProtection.readWrite.name())){ + errorMap.put(ACTION_ARTIFACT_INVALID_PROTECTION_CODE, ACTION_REQUEST_ARTIFACT_INVALID_PROTECTION_VALUE); + } + + ActionArtifact uploadedArtifact = new ActionArtifact(); + if(errorMap.isEmpty()){ + String user = servletRequest.getRemoteUser(); + ActionArtifact upload = new ActionArtifact(); + upload.setArtifactName(artifactName); + upload.setArtifactLabel(artifactLabel); + upload.setArtifactDescription(artifactDescription); + upload.setArtifact(payload); + upload.setArtifactCategory(artifactCategory); + upload.setArtifactProtection(artifactProtection); + uploadedArtifact = actionManager.uploadArtifact(upload, actionInvariantUuId, user); + } + else{ + checkAndThrowError(errorMap); + } + return Response.ok(uploadedArtifact).build(); + } + + @Override + public Response downloadArtifact(String actionUuId, String artifactUuId, + HttpServletRequest servletRequest) { + Response response = null; + try { + initializeRequestMDC(servletRequest, "", ActionRequest.DOWNLOAD_ARTIFACT); + log.debug(" entering downloadArtifact with actionUUID= " + actionUuId + " and artifactUUID= " + artifactUuId); + response = downloadArtifactInternal(actionUuId, artifactUuId, servletRequest); + actionLogPostProcessor(StatusCode.COMPLETE, true); + }catch (ActionException e){ + actionLogPostProcessor(StatusCode.ERROR, e.getErrorCode(), e.getDescription(), true); + actionErrorLogProcessor(CategoryLogLevel.ERROR, e.getErrorCode(), e.getDescription()); + log.error(MDC.get(ERROR_DESCRIPTION)); + throw e; + }catch (Exception e){ + actionLogPostProcessor(StatusCode.ERROR,true); + actionErrorLogProcessor(CategoryLogLevel.ERROR, ACTION_INTERNAL_SERVER_ERR_CODE, ACTION_ENTITY_INTERNAL_SERVER_ERROR_MSG); + log.error(e.getMessage()); + throw e; + }finally { + finalAuditMetricsLogProcessor(ActionRequest.DOWNLOAD_ARTIFACT.name()); + } + log.debug(" exit downloadArtifact with actionUUID= " + actionUuId + " and artifactUUID= " + artifactUuId); + return response; + } + + public Response downloadArtifactInternal(String actionUuId, String artifactUuId, + HttpServletRequest servletRequest) { + ActionArtifact actionartifact = null; + Map errorMap = validateRequestHeaders(servletRequest); + Map queryParamErrors = validateQueryParam(actionUuId); + errorMap.putAll(queryParamErrors); + queryParamErrors = validateQueryParam(artifactUuId); + errorMap.putAll(queryParamErrors); + if (errorMap.isEmpty()) { + actionartifact = actionManager.downloadArtifact(actionUuId, artifactUuId); + } else { + checkAndThrowError(errorMap); + } + + return createArtifactDownloadResponse(actionartifact); + } + + @Override + public Response deleteArtifact(String actionInvariantUuId, String artifactUuId, + HttpServletRequest servletRequest) { + Response response=null; + try { + initializeRequestMDC(servletRequest, actionInvariantUuId, ActionRequest.DELETE_ARTIFACT); + log.debug(" entering deleteArtifact with actionInvariantUUID= " + actionInvariantUuId + " and artifactUUID= " + artifactUuId); + response = deleteArtifactInternal(actionInvariantUuId, artifactUuId, servletRequest); + log.debug(" exit deleteArtifact with actionInvariantUUID= " + actionInvariantUuId + " and artifactUUID= " + artifactUuId); + actionLogPostProcessor(StatusCode.COMPLETE, true); + }catch (ActionException e){ + actionLogPostProcessor(StatusCode.ERROR, e.getErrorCode(), e.getDescription(), true); + actionErrorLogProcessor(CategoryLogLevel.ERROR, e.getErrorCode(), e.getDescription()); + log.error(MDC.get(ERROR_DESCRIPTION)); + throw e; + }catch (Exception e){ + actionLogPostProcessor(StatusCode.ERROR,true); + actionErrorLogProcessor(CategoryLogLevel.ERROR, ACTION_INTERNAL_SERVER_ERR_CODE, ACTION_ENTITY_INTERNAL_SERVER_ERROR_MSG); + log.error(e.getMessage()); + throw e; + }finally { + finalAuditMetricsLogProcessor(ActionRequest.DELETE_ARTIFACT.name()); + } + return response; + } + + public Response deleteArtifactInternal(String actionInvariantUuId, String artifactUuId, + HttpServletRequest servletRequest) { + Map errorMap = validateRequestHeaders(servletRequest); + Map queryParamErrors = validateQueryParam(actionInvariantUuId); + errorMap.putAll(queryParamErrors); + queryParamErrors = validateQueryParam(artifactUuId); + errorMap.putAll(queryParamErrors); + if (errorMap.isEmpty()) { + actionManager + .deleteArtifact(actionInvariantUuId, artifactUuId, servletRequest.getRemoteUser()); + } else { + checkAndThrowError(errorMap); + } + return Response.ok().build(); + } + + @Override + public Response updateArtifact(String actionInvariantUuId, String artifactUuId, + String artifactName, String artifactLabel, String artifactCategory, + String artifactDescription, String artifactProtection, + String checksum, Attachment artifactToUpdate, + HttpServletRequest servletRequest) { + Response response=null; + log.debug(" entering updateArtifact with actionInvariantUUID= " + actionInvariantUuId + " and artifactUUID= " + artifactUuId + " and artifactName= "+artifactName+" and artifactLabel= "+ artifactLabel+" and artifactCategory= "+artifactCategory+" and artifactDescription= "+artifactDescription+" and artifactProtection= "+artifactProtection+" and checksum= "+checksum); + try { + initializeRequestMDC(servletRequest, actionInvariantUuId, ActionRequest.UPDATE_ARTIFACT); + response = updateArtifactInternal(actionInvariantUuId, artifactUuId, artifactName, artifactLabel, artifactCategory, artifactDescription, artifactProtection, checksum, artifactToUpdate, servletRequest); + actionLogPostProcessor(StatusCode.COMPLETE, true); + }catch (ActionException e){ + actionLogPostProcessor(StatusCode.ERROR, e.getErrorCode(), e.getDescription(), true); + actionErrorLogProcessor(CategoryLogLevel.ERROR, e.getErrorCode(), e.getDescription()); + log.error(MDC.get(ERROR_DESCRIPTION)); + throw e; + }catch (Exception e){ + actionLogPostProcessor(StatusCode.ERROR,true); + actionErrorLogProcessor(CategoryLogLevel.ERROR, ACTION_INTERNAL_SERVER_ERR_CODE, ACTION_ENTITY_INTERNAL_SERVER_ERROR_MSG); + log.error(e.getMessage()); + throw e; + }finally { + finalAuditMetricsLogProcessor(ActionRequest.UPDATE_ARTIFACT.name()); + } + log.debug(" exit updateArtifact with actionInvariantUUID= " + actionInvariantUuId + " and artifactUUID= " + artifactUuId + " and artifactName= "+artifactName+" and artifactLabel= "+ artifactLabel+" and artifactCategory= "+artifactCategory+" and artifactDescription= "+artifactDescription+" and artifactProtection= "+artifactProtection+" and checksum= "+checksum); + return response; + } + + public Response updateArtifactInternal(String actionInvariantUuId, String artifactUuId, + String artifactName, String artifactLabel, String artifactCategory, + String artifactDescription, String artifactProtection, + String checksum, Attachment artifactToUpdate, + HttpServletRequest servletRequest) { + byte[] payload = null; + Map errorMap = validateRequestHeaders(servletRequest); + //Content-Type Header Validation + String contentType = servletRequest.getContentType(); + if (StringUtils.isEmpty(contentType)) { + errorMap.put(ACTION_REQUEST_INVALID_GENERIC_CODE, ACTION_REQUEST_CONTENT_TYPE_INVALID); + } + + if (artifactToUpdate != null) { + InputStream artifactInputStream = null; + try { + artifactInputStream = artifactToUpdate.getDataHandler().getInputStream(); + } catch (IOException e) { + throw new ActionException(ACTION_INTERNAL_SERVER_ERR_CODE, ACTION_ARTIFACT_READ_FILE_ERROR); + } + + payload = FileUtils.toByteArray(artifactInputStream); + //Validate Artifact size + if (payload != null && payload.length > MAX_ACTION_ARTIFACT_SIZE) { + throw new ActionException(ACTION_ARTIFACT_TOO_BIG_ERROR_CODE, + ACTION_ARTIFACT_TOO_BIG_ERROR); + } + + //Validate Checksum + if (StringUtils.isEmpty(checksum) || !checksum.equalsIgnoreCase(calculateCheckSum(payload))) { + errorMap.put(ACTION_ARTIFACT_CHECKSUM_ERROR_CODE, ACTION_REQUEST_ARTIFACT_CHECKSUM_ERROR); + } + } + + if (artifactProtection != null && (artifactProtection.isEmpty() || + (!artifactProtection.equals(ActionArtifactProtection.readOnly.name()) && + !artifactProtection.equals(ActionArtifactProtection.readWrite.name())))) { + errorMap.put(ACTION_ARTIFACT_INVALID_PROTECTION_CODE, + ACTION_REQUEST_ARTIFACT_INVALID_PROTECTION_VALUE); + } + + ActionArtifact updateArtifact = new ActionArtifact(); + if (errorMap.isEmpty()) { + String user = servletRequest.getRemoteUser(); + ActionArtifact update = new ActionArtifact(); + update.setArtifactUuId(artifactUuId); + update.setArtifactName(artifactName); + update.setArtifactLabel(artifactLabel); + update.setArtifactDescription(artifactDescription); + update.setArtifact(payload); + update.setArtifactCategory(artifactCategory); + update.setArtifactProtection(artifactProtection); + actionManager.updateArtifact(update, actionInvariantUuId, user); + } else { + checkAndThrowError(errorMap); + } + return Response.ok().build(); + //return Response.status(Response.Status.OK).entity("Artifact successfully updated").build(); + } + + /** + * Get List of all actions + */ + private Response getAllActions(HttpServletRequest servletRequest) { + ListResponseWrapper responseList = null; + Map errorMap = validateRequestHeaders(servletRequest); + if (errorMap.isEmpty()) { + List actions = actionManager.getFilteredActions(FILTER_TYPE_NONE, null); + responseList = createResponse(actions); + } else { + checkAndThrowError(errorMap); + } + + return Response.ok(responseList).build(); + } + + /** + * Get Actions by ECOMP component ID + */ + private Response getActionsByECOMPComponent(String componentID, + HttpServletRequest servletRequest) { + ListResponseWrapper responseList = null; + Map errorMap = validateRequestHeaders(servletRequest); + ; + Map queryParamErrors = validateQueryParam(componentID); + errorMap.putAll(queryParamErrors); + if (errorMap.isEmpty()) { + List actions = + actionManager.getFilteredActions(FILTER_TYPE_ECOMP_COMPONENT, componentID); + responseList = createResponse(actions); + } else { + checkAndThrowError(errorMap); + } + return Response.ok(responseList).build(); + } + + /** + * Get Actions by Model ID + */ + private Response getActionsByModel(String modelId, HttpServletRequest servletRequest) { + ListResponseWrapper responseList = null; + Map errorMap = validateRequestHeaders(servletRequest); + Map queryParamErrors = validateQueryParam(modelId); + errorMap.putAll(queryParamErrors); + if (errorMap.isEmpty()) { + List actions = actionManager.getFilteredActions(FILTER_TYPE_MODEL, modelId); + responseList = createResponse(actions); + } else { + checkAndThrowError(errorMap); + } + return Response.ok(responseList).build(); + } + + /** + * Get all actions with given action name + */ + private Response getActionsByName(String name, HttpServletRequest servletRequest) { + ListResponseWrapper responseList = null; + Map errorMap = validateRequestHeaders(servletRequest); + Map queryParamErrors = validateQueryParam(name); + errorMap.putAll(queryParamErrors); + if (errorMap.isEmpty()) { + List actions = actionManager.getFilteredActions(FILTER_TYPE_NAME, name); + responseList = createResponse(actions); + } else { + checkAndThrowError(errorMap); + } + return Response.ok(responseList).build(); + } + + /** + * Get an action with given ActionUUID + */ + private Response getActionsByUniqueID(String actionUUID, HttpServletRequest servletRequest, + String actionInvariantUUID) { + Map errorMap = validateRequestHeaders(servletRequest); + Map responseDTO = new LinkedHashMap<>(); + Map queryParamErrors = validateQueryParam(actionUUID); + errorMap.putAll(queryParamErrors); + if (errorMap.isEmpty()) { + Action action = actionManager.getActionsByActionUuId(actionUUID); + if (action.getActionInvariantUuId() != null && + action.getActionInvariantUuId().equalsIgnoreCase(actionInvariantUUID)) { + responseDTO = JsonUtil.json2Object(action.getData(), LinkedHashMap.class); + responseDTO.put(STATUS, action.getStatus().name()); + responseDTO.put(TIMESTAMP, getUTCDateStringFromTimestamp(action.getTimestamp())); + responseDTO.put(UPDATED_BY, action.getUser()); + } else { + throw new ActionException(ACTION_ENTITY_NOT_EXIST_CODE, ACTION_ENTITY_NOT_EXIST); + } + } else { + checkAndThrowError(errorMap); + } + return Response.ok(responseDTO).build(); + } + + /** + * Get all actions with given Vendor Name + */ + private Response getActionsByVendor(String vendor, HttpServletRequest servletRequest) { + //Validate request syntax before passing to the manager + ListResponseWrapper responseList = null; + Map errorMap = validateRequestHeaders(servletRequest); + Map queryParamErrors = validateQueryParam(vendor); + errorMap.putAll(queryParamErrors); + if (errorMap.isEmpty()) { + List actions = actionManager.getFilteredActions(FILTER_TYPE_VENDOR, vendor); + responseList = createResponse(actions); + } else { + checkAndThrowError(errorMap); + } + return Response.ok(responseList).build(); + } + + /** + * Get all actions with given Category Name + */ + private Response getActionsByCategory(String category, HttpServletRequest servletRequest) { + //Validate request syntax before passing to the manager + ListResponseWrapper responseList = null; + Map errorMap = validateRequestHeaders(servletRequest); + Map queryParamErrors = validateQueryParam(category); + errorMap.putAll(queryParamErrors); + if (errorMap.isEmpty()) { + List actions = actionManager.getFilteredActions(FILTER_TYPE_CATEGORY, category); + responseList = createResponse(actions); + } else { + checkAndThrowError(errorMap); + } + return Response.ok(responseList).build(); + } + + /** + * Validates mandatory headers in the request + * + * @param servletRequest Servlet Request object + * @return Map of error codes and description found in the request headers + */ + private Map validateRequestHeaders(HttpServletRequest servletRequest) { + Map errorMap = new LinkedHashMap<>(); + //Syntactic generic request parameter validations + String ecompRequestId = servletRequest.getHeader(X_ECOMP_REQUEST_ID_HEADER_PARAM); + if (StringUtils.isEmpty(ecompRequestId)) { + errorMap.put(ACTION_INVALID_REQUEST_ID_CODE, ACTION_REQUEST_ECOMP_REQUEST_ID_INVALID); + } + + String ecompInstanceId = servletRequest.getHeader(X_ECOMP_INSTANCE_ID_HEADER_PARAM); + if (StringUtils.isEmpty(ecompInstanceId)) { + errorMap.put(ACTION_INVALID_INSTANCE_ID_CODE, ACTION_REQUEST_ECOMP_INSTANCE_ID_INVALID); + } + return errorMap; + } + + /** + * Validates query parameter in the request + * + * @param queryParam Query Parameter to be validated + * @return Map of error codes and description found in the query parameter + */ + private Map validateQueryParam(String queryParam) { + Map queryParamErrors = new LinkedHashMap<>(); + if (StringUtils.isEmpty(queryParam)) { + queryParamErrors + .put(ACTION_INVALID_PARAM_CODE, ACTION_REQUEST_MISSING_MANDATORY_PARAM + queryParam); + } + return queryParamErrors; + } + + /** + * Validate request body based on request type + * + * @param requestJSON Raw request json body as string + * @return Map of error codes and description found in the request body + */ + private Map validateRequestBody(String requestType, String requestJSON) { + Map requestBodyErrorMap = new LinkedHashMap<>(); + if (StringUtils.isEmpty(requestJSON) || requestJSON.equals(REQUEST_EMPTY_BODY)) { + requestBodyErrorMap.put(ACTION_INVALID_REQUEST_BODY_CODE, ACTION_REQUEST_BODY_EMPTY); + } else { + switch (requestType) { + case REQUEST_TYPE_CREATE_ACTION: + case REQUEST_TYPE_UPDATE_ACTION: + //Semantic request specific validations + Action action = JsonUtil.json2Object(requestJSON, Action.class); + if (StringUtils.isEmpty(action.getName())) { + setErrorValue(ACTION_REQUEST_INVALID_GENERIC_CODE, ACTION_REQUEST_PARAM_NAME, + requestBodyErrorMap); + } else { + //Added check for action name not allowing whitespaces + if (action.getName().matches(whitespaceRegex)) { + requestBodyErrorMap + .put(ACTION_ARTIFACT_INVALID_NAME_CODE, ACTION_REQUEST_INVALID_NAME); + } + } + + if (StringUtils.isEmpty(action.getEndpointUri())) { + setErrorValue(ACTION_REQUEST_INVALID_GENERIC_CODE, ACTION_REQUEST_PARAM_END_POINT_URI, + requestBodyErrorMap); + } + if (action.getSupportedModels() != null && + !isIDPresentInMap(action.getSupportedModels(), SUPPORTED_MODELS_VERSION_ID)) { + setErrorValue(ACTION_REQUEST_INVALID_GENERIC_CODE, + ACTION_REQUEST_PARAM_SUPPORTED_MODELS, requestBodyErrorMap); + } + if (action.getSupportedComponents() != null && + !isIDPresentInMap(action.getSupportedComponents(), SUPPORTED_COMPONENTS_ID)) { + setErrorValue(ACTION_REQUEST_INVALID_GENERIC_CODE, + ACTION_REQUEST_PARAM_SUPPORTED_COMPONENTS, requestBodyErrorMap); + } + if (action.getArtifacts() != null) { + setErrorValue(ACTION_UPDATE_NOT_ALLOWED_CODE, ACTION_REQUEST_ARTIFACT_OPERATION_ALLOWED, + requestBodyErrorMap); + } + break; + } + + } + return requestBodyErrorMap; + } + + /** + * Populates Given Error Map with Given Error Code and Error MEssage + */ + private void setErrorValue(String key, String message, Map errorMap) { + String errorMessage = errorMap.get(key); + if (errorMessage != null) { + message = errorMessage + ", " + message; + } else { + switch (key) { + case ACTION_REQUEST_INVALID_GENERIC_CODE: + message = ACTION_REQUEST_MISSING_MANDATORY_PARAM + message; + break; + } + } + errorMap.put(key, message); + } + + /** + * Returns true if given key exists in List of HashMap + */ + private boolean isIDPresentInMap(List> map, String idName) { + if (map != null && !map.isEmpty()) { + for (HashMap entry : map) { + if (StringUtils.isEmpty(entry.get(idName))) { + return false; + } + } + } + return true; + } + + /** + * @throws ActionException if given ErrorMap is not empty. + * All error messages at given time are thrown in one single exception + */ + private void checkAndThrowError(Map errorMap) { + if (errorMap.size() > 1) { + //Multiple errors detected .. Send the response with a common error code for multiple errors + throw new ActionException(ACTION_REQUEST_INVALID_GENERIC_CODE, + StringUtils.join(errorMap.values(), ", ")); + } else if (errorMap.size() == 1) { + String svcPolicyExceptionCode = errorMap.entrySet().iterator().next().getKey(); + throw new ActionException(svcPolicyExceptionCode, + errorMap.get(svcPolicyExceptionCode)); + } + } + + /** + * Populates ActionResponseDto based on given Action + */ + private ActionResponseDto createResponseDTO(Action action) { + String data = action.getData(); + ActionResponseDto responseDTO = JsonUtil.json2Object(data, ActionResponseDto.class); + responseDTO.setStatus(action.getStatus().name()); + responseDTO.setTimestamp(getUTCDateStringFromTimestamp(action.getTimestamp())); + //if(!action.getUser().equals(DELETE_ACTION_USER)) + responseDTO.setUpdatedBy(action.getUser()); + return responseDTO; + } + + /** + * Creates response based on given list of actions + */ + private ListResponseWrapper createResponse(List actions) { + ListResponseWrapper responseList = new ListResponseWrapper(); + for (Action action : actions) { + ActionResponseDto responseDTO = createResponseDTO(action); + responseList.add(responseDTO); + } + return responseList; + } + + + private Response createArtifactDownloadResponse(ActionArtifact actionartifact) { + if (actionartifact != null && actionartifact.getArtifact() != null) { + byte[] artifactsBytes = actionartifact.getArtifact(); + File artifactFile = new File(actionartifact.getArtifactName()); + try { + FileOutputStream fos = new FileOutputStream(artifactFile); + fos.write(artifactsBytes); + fos.close(); + } catch (IOException e) { + throw new ActionException(ACTION_INTERNAL_SERVER_ERR_CODE, + ACTION_ENTITY_INTERNAL_SERVER_ERROR_MSG); + } + Response.ResponseBuilder responseBuilder = Response.ok(artifactFile); + responseBuilder.header("Content-Disposition", + "attachment; filename=" + actionartifact.getArtifactName()); + responseBuilder.header("Content-MD5", CalcMD5CheckSum(artifactsBytes)); + responseBuilder.header("Content-Length", artifactFile.length()); + return responseBuilder.build(); + } else { + throw new ActionException(ActionErrorConstants.ACTION_ARTIFACT_ENTITY_NOT_EXIST_CODE, + ActionErrorConstants.ACTION_ARTIFACT_ENTITY_NOT_EXIST); + } + } + + private String CalcMD5CheckSum(byte[] input) { + String checksum = null; + if (input != null) { + checksum = DigestUtils.md5Hex(input).toUpperCase(); + System.out.println("checksum : " + checksum); + } + return checksum; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/action-library-rest-types/pom.xml b/openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/action-library-rest-types/pom.xml new file mode 100644 index 0000000000..18a52bd940 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/action-library-rest-types/pom.xml @@ -0,0 +1,37 @@ + + + 4.0.0 + + org.openecomp.sdc.onboarding + action-library-rest + 1.0.0-SNAPSHOT + ../ + + + action-library-rest-types + action-library-rest-types + + + + + + org.openecomp.sdc + openecomp-sdc-common-rest + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-action-api + ${project.version} + + + + + + \ No newline at end of file diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/action-library-rest-types/src/main/java/org/openecomp/sdcrests/action/types/ActionResponseDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/action-library-rest-types/src/main/java/org/openecomp/sdcrests/action/types/ActionResponseDto.java new file mode 100644 index 0000000000..ff2a934f83 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/action-library-rest-types/src/main/java/org/openecomp/sdcrests/action/types/ActionResponseDto.java @@ -0,0 +1,149 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.action.types; + + +import java.util.HashMap; +import java.util.List; + +/** + * Defines DTO used for Action Response. + */ +public class ActionResponseDto { + + String actionUuId; + String actionInvariantUuId; + String name; + String displayName; + String version; + String description; + String status; + String timestamp; + String updatedBy; + List vendorList; + List categoryList; + List> supportedModels; + List> supportedComponents; + + public String getActionUuId() { + return actionUuId; + } + + public void setActionUuId(String actionUuId) { + this.actionUuId = actionUuId; + } + + public String getActionInvariantUuId() { + return actionInvariantUuId; + } + + public void setActionInvariantUuId(String actionInvariantUuId) { + this.actionInvariantUuId = actionInvariantUuId; + } + + public String getVersion() { + return version; + } + + public void setVersion(String version) { + this.version = version; + } + + public String getStatus() { + return status; + } + + public void setStatus(String status) { + this.status = status; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getDisplayName() { + return displayName; + } + + public void setDisplayName(String displayName) { + this.displayName = displayName; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public List getCategoryList() { + return categoryList; + } + + public void setCategoryList(List categoryList) { + this.categoryList = categoryList; + } + + public List getVendorList() { + return vendorList; + } + + public void setVendorList(List vendorList) { + this.vendorList = vendorList; + } + + public List> getSupportedComponents() { + return supportedComponents; + } + + public void setSupportedComponents(List> supportedComponents) { + this.supportedComponents = supportedComponents; + } + + public List> getSupportedModels() { + return supportedModels; + } + + public void setSupportedModels(List> supportedModels) { + this.supportedModels = supportedModels; + } + + public String getTimestamp() { + return timestamp; + } + + public void setTimestamp(String timeStamp) { + this.timestamp = timeStamp; + } + + public String getUpdatedBy() { + return updatedBy; + } + + public void setUpdatedBy(String updatedBy) { + this.updatedBy = updatedBy; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/action-library-rest-types/src/main/java/org/openecomp/sdcrests/action/types/ActionVersionDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/action-library-rest-types/src/main/java/org/openecomp/sdcrests/action/types/ActionVersionDto.java new file mode 100644 index 0000000000..1b3a5cb445 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/action-library-rest-types/src/main/java/org/openecomp/sdcrests/action/types/ActionVersionDto.java @@ -0,0 +1,38 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.action.types; + +/** + * Defines DTO for capturing input for versioning operations. + */ +public class ActionVersionDto { + + String status; + + public String getStatus() { + return status; + } + + public void setStatus(String workflowActionStatus) { + this.status = workflowActionStatus.trim(); + } + +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/action-library-rest-types/src/main/java/org/openecomp/sdcrests/action/types/ListResponseWrapper.java b/openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/action-library-rest-types/src/main/java/org/openecomp/sdcrests/action/types/ListResponseWrapper.java new file mode 100644 index 0000000000..0ae8504db5 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/action-library-rest-types/src/main/java/org/openecomp/sdcrests/action/types/ListResponseWrapper.java @@ -0,0 +1,70 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.action.types; + +import org.openecomp.sdc.action.types.EcompComponent; + +import java.util.ArrayList; +import java.util.List; + +/** + * Defines DTO used for creating Response with list of {@link ActionResponseDto } + * or list of {@link EcompComponent }. + */ +public class ListResponseWrapper { + + List actionList; + List componentList; + List versions; + + + public ListResponseWrapper() { + this.actionList = new ArrayList<>(); + } + + public List getVersions() { + return versions; + } + + public void setVersions(List versions) { + this.versions = versions; + } + + public List getActionList() { + return actionList; + } + + public void setActionList(List actionList) { + this.actionList = actionList; + } + + public List getComponentList() { + return componentList; + } + + public void setComponentList(List componentList) { + this.componentList = componentList; + } + + public void add(ActionResponseDto e0) { + this.getActionList().add(e0); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/pom.xml b/openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/pom.xml new file mode 100644 index 0000000000..482675fb53 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/action-library-rest/pom.xml @@ -0,0 +1,22 @@ + + + 4.0.0 + + org.openecomp.sdc + openecomp-sdc-rest-webapp + 1.0.0-SNAPSHOT + ../ + + org.openecomp.sdc.onboarding + action-library-rest + action-library-rest + pom + + + + /action-library-rest-services + /action-library-rest-types + + \ No newline at end of file diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/application-config-rest-services/pom.xml b/openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/application-config-rest-services/pom.xml new file mode 100644 index 0000000000..a5979798d2 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/application-config-rest-services/pom.xml @@ -0,0 +1,62 @@ + + + 4.0.0 + + + org.openecomp.sdc + application-config-rest + 1.0.0-SNAPSHOT + + + application-config-rest-services + + + + + + io.swagger + swagger-annotations + 1.5.3 + + + javax.ws.rs + javax.ws.rs-api + ${ws.rs.version} + + + org.springframework + spring-context + ${spring.framework.version} + + + javax.inject + javax.inject + 1 + + + org.openecomp.sdc + openecomp-sdc-application-config-manager + ${project.version} + + + org.openecomp.sdc + application-config-rest-types + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-common-rest + ${project.version} + + + + org.apache.cxf + cxf-rt-frontend-jaxrs + ${cxf.version} + + + + + \ No newline at end of file diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/application-config-rest-services/src/main/java/org/openecomp/sdcrests/applicationconfig/rest/ApplicationConfiguration.java b/openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/application-config-rest-services/src/main/java/org/openecomp/sdcrests/applicationconfig/rest/ApplicationConfiguration.java new file mode 100644 index 0000000000..df743a6a93 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/application-config-rest-services/src/main/java/org/openecomp/sdcrests/applicationconfig/rest/ApplicationConfiguration.java @@ -0,0 +1,69 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.applicationconfig.rest; + +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import org.apache.cxf.jaxrs.ext.multipart.Multipart; +import org.openecomp.sdcrests.applicationconfiguration.types.ConfigurationDataDto; +import org.springframework.validation.annotation.Validated; + +import java.io.InputStream; +import javax.ws.rs.Consumes; +import javax.ws.rs.GET; +import javax.ws.rs.POST; +import javax.ws.rs.Path; +import javax.ws.rs.PathParam; +import javax.ws.rs.Produces; +import javax.ws.rs.QueryParam; +import javax.ws.rs.core.MediaType; +import javax.ws.rs.core.Response; + + +@Path("/v1.0/application-configuration") +@Produces(MediaType.APPLICATION_JSON) +@Consumes(MediaType.APPLICATION_JSON) +@Api(value = "Application Configuration") +@Validated +public interface ApplicationConfiguration { + + @POST + @Path("/") + @Consumes(MediaType.MULTIPART_FORM_DATA) + @ApiOperation(value = "Insert JSON schema into application config table") + Response insertToTable(@QueryParam("namespace") String namespace, @QueryParam("key") String key, + @Multipart("value") InputStream fileContainingSchema); + + + @GET + @Path("/{namespace}/{key}") + @ApiOperation(value = "Get JSON schema by namespace and key", + response = ConfigurationDataDto.class) + Response getFromTable(@PathParam("namespace") String namespace, @PathParam("key") String key); + + + @GET + @Path("/{namespace}") + @ApiOperation(value = "Get List of keys and values by namespace", + responseContainer = "List") + Response getListOfConfigurationByNamespaceFromTable(@PathParam("namespace") String namespace); + +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/application-config-rest-services/src/main/java/org/openecomp/sdcrests/applicationconfig/rest/mapping/MapApplicationConfigEntityToApplicationConfigDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/application-config-rest-services/src/main/java/org/openecomp/sdcrests/applicationconfig/rest/mapping/MapApplicationConfigEntityToApplicationConfigDto.java new file mode 100644 index 0000000000..4d43e37769 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/application-config-rest-services/src/main/java/org/openecomp/sdcrests/applicationconfig/rest/mapping/MapApplicationConfigEntityToApplicationConfigDto.java @@ -0,0 +1,34 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.applicationconfig.rest.mapping; + +import org.openecomp.core.utilities.applicationconfig.dao.type.ApplicationConfigEntity; +import org.openecomp.sdcrests.applicationconfiguration.types.ApplicationConfigDto; +import org.openecomp.sdcrests.mapping.MappingBase; + +public class MapApplicationConfigEntityToApplicationConfigDto + extends MappingBase { + @Override + public void doMapping(ApplicationConfigEntity source, ApplicationConfigDto target) { + target.setKey(source.getKey()); + target.setValue(source.getValue()); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/application-config-rest-services/src/main/java/org/openecomp/sdcrests/applicationconfig/rest/mapping/MapConfigurationDataToConfigurationDataDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/application-config-rest-services/src/main/java/org/openecomp/sdcrests/applicationconfig/rest/mapping/MapConfigurationDataToConfigurationDataDto.java new file mode 100644 index 0000000000..6865c676ec --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/application-config-rest-services/src/main/java/org/openecomp/sdcrests/applicationconfig/rest/mapping/MapConfigurationDataToConfigurationDataDto.java @@ -0,0 +1,34 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.applicationconfig.rest.mapping; + +import org.openecomp.core.utilities.applicationconfig.type.ConfigurationData; +import org.openecomp.sdcrests.applicationconfiguration.types.ConfigurationDataDto; +import org.openecomp.sdcrests.mapping.MappingBase; + +public class MapConfigurationDataToConfigurationDataDto + extends MappingBase { + @Override + public void doMapping(ConfigurationData source, ConfigurationDataDto target) { + target.setValue(source.getValue()); + target.setTimeStamp(source.getTimeStamp()); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/application-config-rest-services/src/main/java/org/openecomp/sdcrests/applicationconfig/rest/services/ApplicationConfigurationImpl.java b/openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/application-config-rest-services/src/main/java/org/openecomp/sdcrests/applicationconfig/rest/services/ApplicationConfigurationImpl.java new file mode 100644 index 0000000000..81f7251fdc --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/application-config-rest-services/src/main/java/org/openecomp/sdcrests/applicationconfig/rest/services/ApplicationConfigurationImpl.java @@ -0,0 +1,87 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.applicationconfig.rest.services; + +import org.openecomp.core.utilities.applicationconfig.dao.type.ApplicationConfigEntity; +import org.openecomp.core.utilities.applicationconfig.type.ConfigurationData; +import org.openecomp.core.utilities.file.FileUtils; +import org.openecomp.sdc.applicationconfig.ApplicationConfigManager; +import org.openecomp.sdcrests.applicationconfig.rest.ApplicationConfiguration; +import org.openecomp.sdcrests.applicationconfig.rest.mapping.MapApplicationConfigEntityToApplicationConfigDto; +import org.openecomp.sdcrests.applicationconfig.rest.mapping.MapConfigurationDataToConfigurationDataDto; +import org.openecomp.sdcrests.applicationconfiguration.types.ApplicationConfigDto; +import org.openecomp.sdcrests.applicationconfiguration.types.ConfigurationDataDto; +import org.openecomp.sdcrests.wrappers.GenericCollectionWrapper; + +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.context.annotation.Scope; +import org.springframework.stereotype.Service; + +import java.io.InputStream; +import java.util.Collection; +import javax.inject.Named; + +import javax.ws.rs.core.Response; + +@Named +@Service("applicationConfiguration") +@Scope(value = "prototype") +public class ApplicationConfigurationImpl implements ApplicationConfiguration { + + @Autowired + private ApplicationConfigManager applicationConfigManager; + + + @Override + public Response insertToTable(String namespace, String key, InputStream fileContainingSchema) { + String value = new String(FileUtils.toByteArray(fileContainingSchema)); + + applicationConfigManager.insertIntoTable(namespace, key, value); + + return Response.ok().build(); + } + + @Override + public Response getFromTable(String namespace, String key) { + ConfigurationData value = applicationConfigManager.getFromTable(namespace, key); + ConfigurationDataDto valueDto = new MapConfigurationDataToConfigurationDataDto() + .applyMapping(value, ConfigurationDataDto.class); + + return Response.ok(valueDto).build(); + } + + @Override + public Response getListOfConfigurationByNamespaceFromTable(String namespace) { + Collection applicationConfigEntities = + applicationConfigManager.getListOfConfigurationByNamespace(namespace); + GenericCollectionWrapper applicationConfigWrapper = + new GenericCollectionWrapper<>(); + MapApplicationConfigEntityToApplicationConfigDto mapper = + new MapApplicationConfigEntityToApplicationConfigDto(); + + for (ApplicationConfigEntity applicationConfigEntity : applicationConfigEntities) { + applicationConfigWrapper + .add(mapper.applyMapping(applicationConfigEntity, ApplicationConfigDto.class)); + } + + return Response.ok(applicationConfigWrapper).build(); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/application-config-rest-types/pom.xml b/openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/application-config-rest-types/pom.xml new file mode 100644 index 0000000000..52d592d4bf --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/application-config-rest-types/pom.xml @@ -0,0 +1,17 @@ + + + 4.0.0 + + + org.openecomp.sdc + application-config-rest + 1.0.0-SNAPSHOT + + + org.openecomp.sdc + application-config-rest-types + + + \ No newline at end of file diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/application-config-rest-types/src/main/java/org/openecomp/sdcrests/applicationconfiguration/types/ApplicationConfigDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/application-config-rest-types/src/main/java/org/openecomp/sdcrests/applicationconfiguration/types/ApplicationConfigDto.java new file mode 100644 index 0000000000..4d2f160d51 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/application-config-rest-types/src/main/java/org/openecomp/sdcrests/applicationconfiguration/types/ApplicationConfigDto.java @@ -0,0 +1,43 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.applicationconfiguration.types; + +public class ApplicationConfigDto { + + private String key; + private String value; + + public String getKey() { + return key; + } + + public void setKey(String key) { + this.key = key; + } + + public String getValue() { + return value; + } + + public void setValue(String value) { + this.value = value; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/application-config-rest-types/src/main/java/org/openecomp/sdcrests/applicationconfiguration/types/ConfigurationDataDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/application-config-rest-types/src/main/java/org/openecomp/sdcrests/applicationconfiguration/types/ConfigurationDataDto.java new file mode 100644 index 0000000000..fcabcf5e89 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/application-config-rest-types/src/main/java/org/openecomp/sdcrests/applicationconfiguration/types/ConfigurationDataDto.java @@ -0,0 +1,50 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.applicationconfiguration.types; + +public class ConfigurationDataDto { + private String value; + private long timeStamp; + + public ConfigurationDataDto(String value, long timeStamp) { + this.value = value; + this.timeStamp = timeStamp; + } + + public ConfigurationDataDto() { + } + + public String getValue() { + return value; + } + + public void setValue(String value) { + this.value = value; + } + + public long getTimeStamp() { + return timeStamp; + } + + public void setTimeStamp(long timeStamp) { + this.timeStamp = timeStamp; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/pom.xml b/openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/pom.xml new file mode 100644 index 0000000000..cc1fbbbe6b --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/application-config-rest/pom.xml @@ -0,0 +1,23 @@ + + + 4.0.0 + + + org.openecomp.sdc + openecomp-sdc-rest-webapp + 1.0.0-SNAPSHOT + + + org.openecomp.sdc + application-config-rest + pom + + + + application-config-rest-services + application-config-rest-types + + + \ No newline at end of file diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/pom.xml b/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/pom.xml new file mode 100644 index 0000000000..0dea1b3ff9 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/pom.xml @@ -0,0 +1,183 @@ + + 4.0.0 + + + org.openecomp.sdc + openecomp-sdc-rest-webapp + 1.0.0-SNAPSHOT + + org.openecomp.sdc.onboarding + onboarding-be + onboarding-rest-war + war + + + + + + org.openecomp.sdc.onboarding + vendor-license-rest-services + ${project.version} + + + org.openecomp.sdc.onboarding + vendor-software-products-rest-services + ${project.version} + + + org.openecomp.sdc.onboarding + validation-rest-services + ${project.version} + + + + org.openecomp.sdc + application-config-rest-services + ${project.version} + + + org.openecomp.sdc.onboarding + action-library-rest-services + ${project.version} + + + javax.servlet + servlet-api + ${javax.servlet.version} + + + + org.codehaus.jackson + jackson-jaxrs + ${org.codehaus.jackson.version} + + + org.codehaus.jackson + jackson-core-asl + ${org.codehaus.jackson.version} + + + javax.inject + javax.inject + 1 + + + org.openecomp.sdc + openecomp-sdc-vendor-software-product-manager + ${project.version} + + + org.eclipse.jetty + jetty-servlets + 9.0.6.v20130930 + + + org.openecomp.sdc + openecomp-sdc-application-config-manager + ${project.version} + + + org.codehaus.groovy + groovy-all + 2.4.7 + + + org.codehaus.janino + janino + compile + + + org.codehaus.janino + commons-compiler + 3.0.6 + compile + + + org.springframework + spring-web + + + + + + + + + org.apache.maven.plugins + maven-compiler-plugin + + + + org.apache.maven.plugins + maven-surefire-plugin + + + test/core/unittest/offline/** + + true + + + buildNumber + ${buildNumber} + + + + + + maven-war-plugin + 2.1.1 + + true + + + + ${basedir}/target/generated/swagger-ui + + + + + + com.github.kongchen + swagger-maven-plugin + 3.1.0 + + + + false + org.openecomp.sdcrests + http + /onboarding-api + + Rest API + v1.0, build #${buildNumber} + Rest API Documentation + + http://www.github.com/kongchen/swagger-maven-plugin + + + ${basedir}/templates/strapdown.html.hbs + ${basedir}/target/generated/api.html + ${basedir}/target/generated/swagger-ui + + + + + + compile + + generate + + + + + + + + + + \ No newline at end of file diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/java/org/openecomp/server/filters/ActionAuthenticationFilter.java b/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/java/org/openecomp/server/filters/ActionAuthenticationFilter.java new file mode 100644 index 0000000000..6e9b4dbe25 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/java/org/openecomp/server/filters/ActionAuthenticationFilter.java @@ -0,0 +1,115 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.server.filters; + +import java.io.IOException; +import java.security.Principal; +import java.util.Base64; + +import javax.servlet.Filter; +import javax.servlet.FilterChain; +import javax.servlet.FilterConfig; +import javax.servlet.ServletException; +import javax.servlet.ServletRequest; +import javax.servlet.ServletResponse; +import javax.servlet.http.HttpServletRequest; +import javax.servlet.http.HttpServletRequestWrapper; +import javax.servlet.http.HttpServletResponse; + +public class ActionAuthenticationFilter implements Filter { + + private boolean runningOnLocal = true; + + @Override + public void destroy() { + + } + + @Override + public void doFilter(ServletRequest arg0, ServletResponse arg1, FilterChain arg2) + throws IOException, ServletException { + if (runningOnLocal) { + + HttpServletRequest httpRequest = (HttpServletRequest) arg0; + String authorizationHeader = httpRequest.getHeader("Authorization"); + if (authorizationHeader != null && !authorizationHeader.isEmpty()) { + String username; + try { + String base64Credentials = + httpRequest.getHeader("Authorization").replace("Basic", "").trim(); + String decodedCredentials = new String(Base64.getDecoder().decode(base64Credentials)); + username = decodedCredentials.substring(0, decodedCredentials.indexOf(":")); + } catch (Exception e0) { + setResponseStatus((HttpServletResponse) arg1, HttpServletResponse.SC_FORBIDDEN); + return; + } + if (username.startsWith("AUTH")) { + HttpServletRequestWrapper servletRequest = new HttpServletRequestWrapper(httpRequest) { + @Override + public java.lang.String getRemoteUser() { + return getUserPrincipal().getName(); + } + + @Override + public Principal getUserPrincipal() { + return () -> username.substring(0, username.indexOf("-")); + } + + @Override + public boolean isUserInRole(String role) { + try { + ActionLibraryPrivilege requiredPrivilege = + ActionLibraryPrivilege.getPrivilege(httpRequest.getMethod()); + ActionLibraryPrivilege userPrivilege = ActionLibraryPrivilege + .valueOf(username.substring(username.indexOf("-") + 1).toUpperCase()); + return userPrivilege.ordinal() >= requiredPrivilege.ordinal(); + } catch (Exception e0) { + return false; + } + } + }; + arg2.doFilter(servletRequest, arg1); + } else { + setResponseStatus((HttpServletResponse) arg1, HttpServletResponse.SC_FORBIDDEN); + } + } else { + setResponseStatus((HttpServletResponse) arg1, HttpServletResponse.SC_UNAUTHORIZED); + } + } else { + //call super doFilter of cadi authentication filter + } + + + } + + private void setResponseStatus(HttpServletResponse response, int status) { + response.setStatus(status); + } + + @Override + public void init(FilterConfig arg0) throws ServletException { + /*runningOnLocal = System.getProperty("file.separator").equals("\\"); + if (!runningOnLocal){ + // call to super init of cadi filter as we are not running on windows + }*/ + } + +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/java/org/openecomp/server/filters/ActionAuthorizationFilter.java b/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/java/org/openecomp/server/filters/ActionAuthorizationFilter.java new file mode 100644 index 0000000000..ba9c7537f4 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/java/org/openecomp/server/filters/ActionAuthorizationFilter.java @@ -0,0 +1,71 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.server.filters; + +import java.io.IOException; + +import javax.servlet.Filter; +import javax.servlet.FilterChain; +import javax.servlet.FilterConfig; +import javax.servlet.ServletException; +import javax.servlet.ServletRequest; +import javax.servlet.ServletResponse; +import javax.servlet.http.HttpServletRequest; +import javax.servlet.http.HttpServletResponse; + +public class ActionAuthorizationFilter implements Filter { + + private boolean runningOnLocal = true; + + @Override + public void destroy() { + } + + @Override + public void doFilter(ServletRequest arg0, ServletResponse arg1, FilterChain arg2) + throws IOException, ServletException { + + if (runningOnLocal) { + HttpServletRequest httpRequest = (HttpServletRequest) arg0; + if (httpRequest.isUserInRole(httpRequest.getMethod().toUpperCase())) { + arg2.doFilter(arg0, arg1); + } else { + setResponseStatus((HttpServletResponse) arg1, HttpServletResponse.SC_FORBIDDEN); + } + } else { + //call super doFilter of cadi authorization filter with relavant info as and when available + } + + } + + private void setResponseStatus(HttpServletResponse response, int status) { + response.setStatus(status); + } + + @Override + public void init(FilterConfig arg0) throws ServletException { + /*runningOnLocal = System.getProperty("file.separator").equals("\\"); + if (!runningOnLocal){ + // call to super init of cadi filter as we are not running on windows + }*/ + } + +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/java/org/openecomp/server/filters/ActionLibraryPrivilege.java b/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/java/org/openecomp/server/filters/ActionLibraryPrivilege.java new file mode 100644 index 0000000000..c34af00830 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/java/org/openecomp/server/filters/ActionLibraryPrivilege.java @@ -0,0 +1,59 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.server.filters; + +public enum ActionLibraryPrivilege { + + RETRIEVE, CREATE, UPDATE, DELETE; + + /** + * + * @param operation . + * @return actionLibraryPrivilege + */ + public static ActionLibraryPrivilege getPrivilege(String operation) { + + ActionLibraryPrivilege toReturn; + + switch (operation) { + + case "GET": + toReturn = RETRIEVE; + break; + case "POST": + toReturn = CREATE; + break; + case "PUT": + toReturn = UPDATE; + break; + case "DELETE": + toReturn = DELETE; + break; + default: + toReturn = null; + break; + + } + + return toReturn; + + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/java/org/openecomp/server/interceptors/DefaultOutput.java b/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/java/org/openecomp/server/interceptors/DefaultOutput.java new file mode 100644 index 0000000000..b2e1119a78 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/java/org/openecomp/server/interceptors/DefaultOutput.java @@ -0,0 +1,182 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.server.interceptors; + +import java.io.Serializable; +import java.lang.annotation.Annotation; +import java.net.URI; +import java.util.Date; +import java.util.Locale; +import java.util.Map; +import java.util.Set; + +import javax.ws.rs.core.EntityTag; +import javax.ws.rs.core.GenericType; +import javax.ws.rs.core.Link; +import javax.ws.rs.core.MediaType; +import javax.ws.rs.core.MultivaluedMap; +import javax.ws.rs.core.NewCookie; +import javax.ws.rs.core.Response; + +public class DefaultOutput extends Response implements Serializable { + + private static final long serialVersionUID = 8061802931931401706L; + + private final int status; + private final Object entity; + private MultivaluedMap metadata; + + public DefaultOutput(int s0, Object e0) { + this.status = s0; + this.entity = e0; + } + public Object getEntity() { + return entity; + } + + @Override + public T readEntity(Class asClass) { + return null; + } + + @Override + public T readEntity(GenericType genericType) { + return null; + } + + @Override + public T readEntity(Class asClass, Annotation[] annotations) { + return null; + } + + @Override + public T readEntity(GenericType var1, Annotation[] var2) { + return null; + } + + @Override + public boolean hasEntity() throws IllegalStateException { + return false; + } + + @Override + public boolean bufferEntity() { + return false; + } + + @Override + public void close() { + } + + @Override + public MediaType getMediaType() { + return null; + } + + @Override + public Locale getLanguage() { + return null; + } + + @Override + public int getLength() { + return 0; + } + + @Override + public Set getAllowedMethods() { + return null; + } + + @Override + public Map getCookies() { + return null; + } + + @Override + public EntityTag getEntityTag() { + return null; + } + + @Override + public Date getDate() { + return null; + } + + @Override + public Date getLastModified() { + return null; + } + + @Override + public URI getLocation() { + return null; + } + + @Override + public Set getLinks() { + return null; + } + + @Override + public boolean hasLink(String s0) { + return false; + } + + @Override + public Link getLink(String s0) { + return null; + } + + @Override + public Link.Builder getLinkBuilder(String s0) { + return null; + } + + public int getStatus() { + return status; + } + + @Override + public StatusType getStatusInfo() { + return null; + } + + void addMetadata(MultivaluedMap meta) { + this.metadata = meta; + } + + public MultivaluedMap getMetadata() { + // don't worry about cloning for now + return metadata; + } + + @Override + public MultivaluedMap getStringHeaders() { + return null; + } + + @Override + public String getHeaderString(String s0) { + return null; + } + +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/java/org/openecomp/server/interceptors/EmptyOutputOutInterceptor.java b/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/java/org/openecomp/server/interceptors/EmptyOutputOutInterceptor.java new file mode 100644 index 0000000000..4e2f56834f --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/java/org/openecomp/server/interceptors/EmptyOutputOutInterceptor.java @@ -0,0 +1,63 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.server.interceptors; + +import org.apache.cxf.interceptor.AbstractOutDatabindingInterceptor; +import org.apache.cxf.interceptor.Fault; +import org.apache.cxf.message.Message; +import org.apache.cxf.message.MessageContentsList; +import org.apache.cxf.phase.Phase; + +import javax.inject.Named; +import javax.ws.rs.core.Response; + +@Named +public class EmptyOutputOutInterceptor extends AbstractOutDatabindingInterceptor { + + public EmptyOutputOutInterceptor() { + // To be executed in post logical phase before marshal phase + super(Phase.POST_LOGICAL); + } + + /** + * Intercepts a message. + * Interceptors should NOT invoke handleMessage or handleFault + * on the next interceptor - the interceptor chain will + * take care of this. + * + * @param message input message. + */ + public void handleMessage(Message message) throws Fault { + //get the message + MessageContentsList objs = MessageContentsList.getContentsList(message); + if (objs.get(0) instanceof Response) { + //check if response is present but entity inside it is null the set a default entity + int status = ((Response) objs.get(0)).getStatus(); + Object entity = ((Response) objs.get(0)).getEntity(); + // in case of staus 200 and entity is null send InternalEmptyObject in output. + if (entity == null && status == 200) { + DefaultOutput defaultOutput = new DefaultOutput(status, new InternalEmptyObject()); + defaultOutput.addMetadata(((Response) objs.get(0)).getMetadata()); + objs.set(0, defaultOutput); + } + } + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/java/org/openecomp/server/interceptors/InternalEmptyObject.java b/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/java/org/openecomp/server/interceptors/InternalEmptyObject.java new file mode 100644 index 0000000000..d2b24bde77 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/java/org/openecomp/server/interceptors/InternalEmptyObject.java @@ -0,0 +1,34 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.server.interceptors; + +import org.codehaus.jackson.annotate.JsonAutoDetect; + +import java.io.Serializable; + +/** + * This class is for Internal use only. + * Please don't use this class. + */ +@JsonAutoDetect +public class InternalEmptyObject implements Serializable { + +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/java/org/openecomp/server/listeners/OnboardingAppStartupListener.java b/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/java/org/openecomp/server/listeners/OnboardingAppStartupListener.java new file mode 100644 index 0000000000..2ea0ee2f66 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/java/org/openecomp/server/listeners/OnboardingAppStartupListener.java @@ -0,0 +1,43 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.server.listeners; + + +import org.springframework.web.context.ContextLoaderListener; + +import javax.servlet.ServletContextEvent; +import javax.servlet.ServletContextListener; + +public class OnboardingAppStartupListener implements ServletContextListener { + + ContextLoaderListener springListener; + + @Override + public void contextInitialized(ServletContextEvent servletContextEvent) { + springListener = new ContextLoaderListener(); + springListener.initWebApplicationContext(servletContextEvent.getServletContext()); + } + + @Override + public void contextDestroyed(ServletContextEvent servletContextEvent) { + springListener.closeWebApplicationContext(servletContextEvent.getServletContext()); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/resources/keyfile.txt b/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/resources/keyfile.txt new file mode 100644 index 0000000000..d6c2c253f8 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/resources/keyfile.txt @@ -0,0 +1,27 @@ +hfLSGGYWU2SyTlltV0HVwU6o3GtrtccAU8aFwq65OHsl6JeEAirXaNl73xz2uTrfiFqVJD7GTxXr +_qlY4BnLFZ7q3KNRZ0VQssjF_REjB8p7YMkEiTzbJL0pSaI6s0GRotuM432Jbsoksh8WZeui7svx +I_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aw9LBeGoMbqzHzWl93inEsTyLutMPA8xSIj5kySLIcJCXq9-RMp8cnOYy8TY9Jix +oaB2u4ofHDDrrMzKY88ZPdMiGQX2BNdsOG6o4ifSVyyYwIWBtQvtO7SDvGhRUGEV1JHloBdIos0M +87SMERYd_UPKK_yl2RaqloQZRlDSgUR7i0hoqrhtPe5Ef4cJFX_CSt_oQnEu0JatwAuwybkLLPbO +mArd3rtrOh-uR_0Y77zb7Uw4H5_oX_ANIecH0sgRcvQESaq-ioYrvS94VqvxU8ByuxqxJLMo90Rc +oOAk3pq0b-16x_WRxWTfbnnNLDSQ_DwS-Xeav1nPwm-ELy1AVEQdpgbjONThjkZp3AuljaH_1Fs4 +u0A8HeCgIa4g7jsvIRxw6zLKspYENdvoHvQLWGRpaA-vfT3i3lR0MEu53v8M9hI8U8MqJo_J0xe6 +z2mtQWPiCLtW99vTqhKOm621_GNYmp10TEXVMkXumEk2rTgLBDaFEFwpgS5LqkEOObVChd9jx9oa +DW4LjhzO1EE5twGvbTiRAJsO6j5UNTonGFLLttYKq9CMvDiBZ8-whFGOM8D2qAWYiwDCI-dLqwat +jxQP1cYKGHMS2-VJ5QJa6EINEx2zo3VmnHYCE9gM71fC26018Y2T-sQfE1MRE9SU_Xma7Qbl5OBp +IflyJCTyhZfgFlqU9f2cq12bjoNuMrgOlKwap6325LGZK1XsmsHuHmASRE4-E-qmQY7GI9oJLmbl +425swlxRA-mr1eGZU0hK3ZFjz_4clBMLJBYMFYhdGzi4VYGPzaO0z0wNJzOQf3V5NbReFjxl \ No newline at end of file diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/webapp/WEB-INF/beans-services.xml b/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/webapp/WEB-INF/beans-services.xml new file mode 100644 index 0000000000..5eb2b98cd5 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/webapp/WEB-INF/beans-services.xml @@ -0,0 +1,70 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/webapp/WEB-INF/jetty-web.xml b/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/webapp/WEB-INF/jetty-web.xml new file mode 100644 index 0000000000..80d8dd70cb --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/webapp/WEB-INF/jetty-web.xml @@ -0,0 +1,8 @@ + + + + + /onboarding-api + diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/webapp/WEB-INF/web.xml b/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/webapp/WEB-INF/web.xml new file mode 100644 index 0000000000..68b7758609 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/src/main/webapp/WEB-INF/web.xml @@ -0,0 +1,95 @@ + + + + + + + + contextConfigLocation + WEB-INF/beans-services.xml + + + + + org.openecomp.server.listeners.OnboardingAppStartupListener + + + + cross-origin + org.eclipse.jetty.servlets.CrossOriginFilter + + allowedOrigins + * + + + allowedMethods + * + + + allowedHeaders + * + + + + + AuthN + org.openecomp.server.filters.ActionAuthenticationFilter + + + AuthZ + org.openecomp.server.filters.ActionAuthorizationFilter + + + cross-origin + /* + + + AuthN + /workflow/v1.0/actions/* + + + AuthZ + /workflow/v1.0/actions/* + + + LoggingServletFilter + org.openecomp.core.logging.servlet.LoggingFilter + + + + LoggingServletFilter + /* + + + + CXFServlet + CXF Servlet + + org.apache.cxf.transport.servlet.CXFServlet + + + redirects-list + + /docs/(\S)+\.json + + + + redirect-attributes + + javax.servlet.include.request_uri + + + + redirect-servlet-name + default + + 1 + + + CXFServlet + /* + + + diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/templates/markdown.hbs b/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/templates/markdown.hbs new file mode 100644 index 0000000000..cc87c38244 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/templates/markdown.hbs @@ -0,0 +1,105 @@ +#{{#info}}{{title}} + + +## {{join schemes " | "}}://{{host}}{{basePath}} + + +{{description}} + +{{#contact}} +[**Contact the developer**](mailto:{{email}}) +{{/contact}} + +**Version** {{version}} + +{{#license}}[**{{name}}**]({{url}}){{/license}} + +{{/info}} + +{{#if consumes}}**Consumes:** {{join consumes ", "}}{{/if}} + +{{#if produces}}**Produces:** {{join produces ", "}}{{/if}} + +{{#if securityDefinitions}} +# Security Definitions +{{/if}} +{{> security}} + +# APIs + +{{#each paths}} +## {{@key}} +{{#this}} +{{#get}} +### GET +{{> operation}} +{{/get}} + +{{#put}} +### PUT +{{> operation}} +{{/put}} + +{{#post}} +### POST + +{{> operation}} + +{{/post}} + +{{#delete}} +### DELETE +{{> operation}} +{{/delete}} + +{{#option}} +### OPTION +{{> operation}} +{{/option}} + +{{#patch}} +### PATCH +{{> operation}} +{{/patch}} + +{{#head}} +### HEAD +{{> operation}} +{{/head}} + +{{/this}} +{{/each}} + +# Definitions +{{#each definitions}} +## {{@key}} + + + + + + + + + + {{#each this.properties}} + + + + + + + + {{/each}} +
nametyperequireddescriptionexample
{{@key}} + {{#ifeq type "array"}} + {{#items.$ref}} + {{type}}[{{basename items.$ref}}] + {{/items.$ref}} + {{^items.$ref}}{{type}}[{{items.type}}]{{/items.$ref}} + {{else}} + {{#$ref}}{{basename $ref}}{{/$ref}} + {{^$ref}}{{type}}{{#format}} ({{format}}){{/format}}{{/$ref}} + {{/ifeq}} + {{#required}}required{{/required}}{{^required}}optional{{/required}}{{#description}}{{{description}}}{{/description}}{{^description}}-{{/description}}{{example}}
+{{/each}} \ No newline at end of file diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/templates/operation.hbs b/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/templates/operation.hbs new file mode 100644 index 0000000000..375d4f7701 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/templates/operation.hbs @@ -0,0 +1,73 @@ +{{#deprecated}}-deprecated-{{/deprecated}} +{{summary}} + +{{description}} + +{{#if externalDocs.url}}{{externalDocs.description}}. [See external documents for more details]({{externalDocs.url}}) +{{/if}} + +{{#if security}} +#### Security +{{/if}} + +{{#security}} +{{#each this}} +* {{@key}} +{{#this}} * {{this}} +{{/this}} +{{/each}} +{{/security}} + +#### Request + +{{#if consumes}} +**Content-Type: ** {{join consumes ", "}}{{/if}} + +##### Parameters +{{#if parameters}} + + + + + + + + + +{{/if}} + +{{#parameters}} + + + + + + +{{#ifeq in "body"}} + +{{else}} + {{#ifeq type "array"}} + + {{else}} + + {{/ifeq}} +{{/ifeq}} + +{{/parameters}} +{{#if parameters}} +
NameLocated inRequiredDescriptionDefaultSchema
{{name}}{{in}}{{#if required}}yes{{else}}no{{/if}}{{description}}{{#if pattern}} (**Pattern**: `{{pattern}}`){{/if}}{{#if defaultValue}}{{defaultValue}}{{else}} - {{/if}} + {{#ifeq schema.type "array"}}Array[{{basename schema.items.$ref}}]{{/ifeq}} + {{#schema.$ref}}{{basename schema.$ref}} {{/schema.$ref}} + Array[{{items.type}}] ({{collectionFormat}}){{type}} {{#format}}({{format}}){{/format}}
+{{/if}} + + +#### Response + +{{#if produces}}**Content-Type: ** {{join produces ", "}}{{/if}} + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +{{#each responses}}| {{@key}} | {{description}} | {{#schema.$ref}}{{basename schema.$ref}}{{/schema.$ref}}{{#ifeq schema.type "array"}}Array[{{basename schema.items.$ref}}]{{/ifeq}}{{^schema}} - {{/schema}}| +{{/each}} \ No newline at end of file diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/templates/security.hbs b/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/templates/security.hbs new file mode 100644 index 0000000000..04f86e8380 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/templates/security.hbs @@ -0,0 +1,88 @@ +{{#each securityDefinitions}} +### {{@key}} +{{#this}} +{{#ifeq type "oauth2"}} + + + + + +{{#if description}} + + + + +{{/if}} +{{#if authorizationUrl}} + + + + +{{/if}} +{{#if flow}} + + + + +{{/if}} +{{#if tokenUrl}} + + + + +{{/if}} +{{#if scopes}} + + +{{#each scopes}} + + + + +{{/each}} + +{{/if}} +
type{{type}}
description{{description}}
authorizationUrl{{authorizationUrl}}
flow{{flow}}
tokenUrl{{tokenUrl}}
scopes{{@key}}{{this}}
+{{/ifeq}} +{{#ifeq type "apiKey"}} + + + + + +{{#if description}} + + + + +{{/if}} +{{#if name}} + + + + +{{/if}} +{{#if in}} + + + + +{{/if}} +
type{{type}}
description{{description}}
name{{name}}
in{{in}}
+{{/ifeq}} +{{#ifeq type "basic"}} + + + + + +{{#if description}} + + + + +{{/if}} +
type{{type}}
description{{description}}
+{{/ifeq}} +{{/this}} +{{/each}} \ No newline at end of file diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/templates/strapdown.html.hbs b/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/templates/strapdown.html.hbs new file mode 100644 index 0000000000..fe722ab6f1 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/templates/strapdown.html.hbs @@ -0,0 +1,11 @@ + + +API Document + + + +{{>markdown}} + + + + \ No newline at end of file diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/pom.xml b/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/pom.xml new file mode 100644 index 0000000000..764fb84db4 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/pom.xml @@ -0,0 +1,47 @@ + + + 4.0.0 + + + org.openecomp.sdc + openecomp-sdc-rest-webapp + 1.0.0-SNAPSHOT + + + openecomp-sdc-common-rest + openecomp-sdc-common-rest + + + + + org.openecomp.core + openecomp-utilities-lib + ${project.version} + + + org.openecomp.core + openecomp-common-lib + ${project.version} + + + org.hibernate + hibernate-validator + ${hibernate.validator.version} + + + javax.ws.rs + javax.ws.rs-api + ${ws.rs.version} + + + + io.swagger + swagger-core + ${swagger.version} + compile + + + + \ No newline at end of file diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/common/RestConstants.java b/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/common/RestConstants.java new file mode 100644 index 0000000000..499bd6e785 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/common/RestConstants.java @@ -0,0 +1,29 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.common; + +public class RestConstants { + public static final String USER_HEADER_PARAM = "USER_ID"; + public static final String USER_MISSING_ERROR_MSG = + "Field does not conform to predefined criteria : user : may not be null"; + public static final String INVALID_JSON_ERROR_MESSAGE = + "Field does not conform to predefined criteria : body :must be in JSON format"; +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/common/mapping/MapErrorCodeToDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/common/mapping/MapErrorCodeToDto.java new file mode 100644 index 0000000000..cad5c69899 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/common/mapping/MapErrorCodeToDto.java @@ -0,0 +1,34 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.common.mapping; + +import org.openecomp.sdc.common.errors.ErrorCode; +import org.openecomp.sdcrests.common.types.ErrorCodeDto; +import org.openecomp.sdcrests.mapping.MappingBase; + +public class MapErrorCodeToDto extends MappingBase { + @Override + public void doMapping(ErrorCode source, ErrorCodeDto target) { + target.setId(source.id()); + target.setCategory(source.category()); + target.setMessage(source.message()); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/common/mapping/MapErrorMessageToDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/common/mapping/MapErrorMessageToDto.java new file mode 100644 index 0000000000..83c7b15980 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/common/mapping/MapErrorMessageToDto.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.common.mapping; + +import org.openecomp.sdc.datatypes.error.ErrorMessage; +import org.openecomp.sdcrests.common.types.ErrorMessageDto; +import org.openecomp.sdcrests.mapping.MappingBase; + +public class MapErrorMessageToDto extends MappingBase { + @Override + public void doMapping(ErrorMessage source, ErrorMessageDto target) { + target.setMessage(source.getMessage()); + target.setLevel(source.getLevel()); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/common/types/ErrorCodeDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/common/types/ErrorCodeDto.java new file mode 100644 index 0000000000..3615f89afc --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/common/types/ErrorCodeDto.java @@ -0,0 +1,53 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.common.types; + +import org.openecomp.sdc.common.errors.ErrorCategory; + +public class ErrorCodeDto { + private String id; + private String message; + private ErrorCategory category; + + public String getId() { + return id; + } + + public void setId(String id) { + this.id = id; + } + + public String getMessage() { + return message; + } + + public void setMessage(String message) { + this.message = message; + } + + public ErrorCategory getCategory() { + return category; + } + + public void setCategory(ErrorCategory category) { + this.category = category; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/common/types/ErrorMessageDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/common/types/ErrorMessageDto.java new file mode 100644 index 0000000000..f63a9b0ced --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/common/types/ErrorMessageDto.java @@ -0,0 +1,44 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.common.types; + +import org.openecomp.sdc.datatypes.error.ErrorLevel; + +public class ErrorMessageDto { + private ErrorLevel level; + private String message; + + public ErrorLevel getLevel() { + return level; + } + + public void setLevel(ErrorLevel level) { + this.level = level; + } + + public String getMessage() { + return message; + } + + public void setMessage(String message) { + this.message = message; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/errors/DefaultExceptionMapper.java b/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/errors/DefaultExceptionMapper.java new file mode 100644 index 0000000000..67da814f48 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/errors/DefaultExceptionMapper.java @@ -0,0 +1,163 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.errors; + +import org.codehaus.jackson.map.JsonMappingException; +import org.hibernate.validator.internal.engine.path.PathImpl; +import org.openecomp.core.utilities.CommonMethods; +import org.openecomp.core.utilities.file.FileUtils; +import org.openecomp.core.utilities.json.JsonUtil; +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; +import org.openecomp.sdc.common.errors.ErrorCodeAndMessage; +import org.openecomp.sdc.common.errors.GeneralErrorBuilder; +import org.openecomp.sdc.common.errors.JsonMappingErrorBuilder; +import org.openecomp.sdc.common.errors.ValidationErrorBuilder; +import org.slf4j.LoggerFactory; + +import java.util.ArrayList; +import java.util.List; +import java.util.Map; +import java.util.Set; +import javax.validation.ConstraintViolation; +import javax.validation.ConstraintViolationException; +import javax.validation.Path; +import javax.ws.rs.core.MediaType; +import javax.ws.rs.core.Response; +import javax.ws.rs.ext.ExceptionMapper; + +public class DefaultExceptionMapper implements ExceptionMapper { + private static final String ERROR_CODES_TO_RESPONSE_STATUS_MAPPING_FILE = + "errorCodesToResponseStatusMapping.json"; + private static Map errorCodeToResponseStatus = JsonUtil + .json2Object(FileUtils.getFileInputStream(ERROR_CODES_TO_RESPONSE_STATUS_MAPPING_FILE), + Map.class); + private static org.slf4j.Logger logger = LoggerFactory.getLogger(DefaultExceptionMapper.class); + + @Override + public Response toResponse(Exception e0) { + Response response; + if (e0 instanceof CoreException) { + response = transform(CoreException.class.cast(e0)); + } else if (e0 instanceof ConstraintViolationException) { + response = transform(ConstraintViolationException.class.cast(e0)); + + } else if (e0 instanceof JsonMappingException) { + response = transform(JsonMappingException.class.cast(e0)); + + } else { + response = transform(e0); + } + + List contentTypes = new ArrayList<>(); + contentTypes.add(MediaType.APPLICATION_JSON); + response.getMetadata().put("Content-Type", contentTypes); + return response; + } + + private Response transform(CoreException coreException) { + Response response; + ErrorCode code = coreException.code(); + logger.error(code.message(), coreException); + + if (coreException.code().category().equals(ErrorCategory.APPLICATION)) { + if (Response.Status.NOT_FOUND.name().equals(errorCodeToResponseStatus.get(code.id()))) { + response = Response + .status(Response.Status.NOT_FOUND) + .entity(toEntity(Response.Status.NOT_FOUND, code)) + .build(); + } else if (Response.Status.BAD_REQUEST.name() + .equals(errorCodeToResponseStatus.get(code.id()))) { + response = Response + .status(Response.Status.BAD_REQUEST) + .entity(toEntity(Response.Status.BAD_REQUEST, code)) + .build(); + } else { + response = Response + .status(Response.Status.EXPECTATION_FAILED) + .entity(toEntity(Response.Status.EXPECTATION_FAILED, code)) + .build(); + } + } else { + response = Response + .status(Response.Status.INTERNAL_SERVER_ERROR) + .entity(toEntity(Response.Status.INTERNAL_SERVER_ERROR, code)) + .build(); + } + + + return response; + } + + private Response transform(ConstraintViolationException validationException) { + Set> constraintViolationSet = + validationException.getConstraintViolations(); + String message; + + String fieldName = null; + if (!CommonMethods.isEmpty(constraintViolationSet)) { + // getting the first violation message for the output response. + ConstraintViolation constraintViolation = constraintViolationSet.iterator().next(); + message = constraintViolation.getMessage(); + fieldName = getFieldName(constraintViolation.getPropertyPath()); + + } else { + message = validationException.getMessage(); + } + + ErrorCode validationErrorCode = new ValidationErrorBuilder(message, fieldName).build(); + + logger.error(validationErrorCode.message(), validationException); + return Response + .status(Response.Status.EXPECTATION_FAILED) //error 417 + .entity(toEntity(Response.Status.EXPECTATION_FAILED, validationErrorCode)) + .build(); + } + + + private Response transform(JsonMappingException jsonMappingException) { + ErrorCode jsonMappingErrorCode = new JsonMappingErrorBuilder().build(); + logger.error(jsonMappingErrorCode.message(), jsonMappingException); + return Response + .status(Response.Status.EXPECTATION_FAILED) //error 417 + .entity(toEntity(Response.Status.EXPECTATION_FAILED, jsonMappingErrorCode)) + .build(); + } + + private Response transform(Exception e0) { + ErrorCode generalErrorCode = new GeneralErrorBuilder(e0.getMessage()).build(); + logger.error(generalErrorCode.message(), e0); + return Response + .status(Response.Status.INTERNAL_SERVER_ERROR) + .entity(toEntity(Response.Status.INTERNAL_SERVER_ERROR, generalErrorCode)) + .build(); + } + + private String getFieldName(Path propertyPath) { + return ((PathImpl) propertyPath).getLeafNode().toString(); + } + + private Object toEntity(Response.Status status, ErrorCode code) { + return new ErrorCodeAndMessage(status, code); + } + +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/mapping/MappingBase.java b/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/mapping/MappingBase.java new file mode 100644 index 0000000000..7382ef72eb --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/mapping/MappingBase.java @@ -0,0 +1,104 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.mapping; + +/** + * Base class for all mapping classes. Mapping classes will perform data mapping from source object + * to target object Base class provides following
+ *
    + *
  1. provides life cycle of mapping class , first mapSimpleProperties is called and then + * mapComplexProperties is called.
  2. + *
  3. methods mapSimpleProperties and mapComplexProperties with default implementation, + * these should be overridden by concrete mapping classes for writing mapping logic.
  4. + *
+ */ + +public abstract class MappingBase { + + /** + * Method is called for starting mapping from source object to target object method sets context + * in the thread locale and than calls mapSimpleProperties and mapComplexProperties respectively. + * + * @param source : source object for mapping + * @param clazz : target Class for mapping + * @return T - instance of type T + */ + + public final T applyMapping(final S source, Class clazz) { + T target = (T) instantiateTarget(clazz); + if (source == null || target == null) { + //TODO: what what? + } else { + preMapping(source, target); + doMapping(source, target); + postMapping(source, target); + + } + return target; + + } + + /** + * This method is called before the doMapping method. + */ + + public void preMapping(final S source, T target) { + } + + /** + * The actual method that does the mapping between the source + * to target objects. + * This method is being called automatically as part of the mapper class. + * This method must be override (it is abstract) by the mapper class. + * + * @param source - the source object. + * @param target - the target object. + */ + + public abstract void doMapping(final S source, T target); + + /** + * This method is called after the doMapping method. + */ + + public void postMapping(final S source, T target) { + } + + /** + * Creates the instance of the input class. + * + * @return Object + */ + + private Object instantiateTarget(final Class clazz) { + Object object = null; + try { + object = clazz.newInstance(); + + } catch (InstantiationException | IllegalAccessException e0) { + //Do nothing + } + return object; + + } + +} + diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/versioning/types/VersioningAction.java b/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/versioning/types/VersioningAction.java new file mode 100644 index 0000000000..8cb5a061b9 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/versioning/types/VersioningAction.java @@ -0,0 +1,28 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.versioning.types; + +public enum VersioningAction { + Checkout, + Undo_Checkout, + Checkin, + Submit; +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/wrappers/GenericCollectionWrapper.java b/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/wrappers/GenericCollectionWrapper.java new file mode 100644 index 0000000000..b8d47e4ef3 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/wrappers/GenericCollectionWrapper.java @@ -0,0 +1,107 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.wrappers; + +import java.io.Serializable; +import java.util.ArrayList; +import java.util.List; + +/** + * This class represents a generic collection wrapper to be used by paginated results. + * + * @param the type parameter + */ +public class GenericCollectionWrapper implements Serializable { + private static final long serialVersionUID = 1L; + + private List results; + private int listCount; + + /** + * Instantiates a new Generic collection wrapper. + */ + public GenericCollectionWrapper() { + this.results = new ArrayList<>(); + } + + /** + * Instantiates a new Generic collection wrapper. + * + * @param list the list + * @param listCount the list count + */ + public GenericCollectionWrapper(List list, int listCount) { + if (!list.isEmpty()) { + this.results = list; + this.listCount = listCount; + } + } + + /** + * Gets results. + * + * @return the results + */ + public List getResults() { + return results; + } + + /** + * Sets results. + * + * @param results the results + */ + public void setResults(List results) { + this.results = results; + } + + /** + * Gets list count. + * + * @return the list count + */ + public int getListCount() { + return listCount; + } + + /** + * Sets list count. + * + * @param listCount the list count + */ + public void setListCount(int listCount) { + this.listCount = listCount; + } + + /** + * Add boolean. + * + * @param e0 the e 0 + * @return the boolean + */ + public boolean add(T e0) { + if (this.getResults().add(e0)) { + this.setListCount(this.getResults().size()); + return true; + } + return false; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/wrappers/StringWrapperResponse.java b/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/wrappers/StringWrapperResponse.java new file mode 100644 index 0000000000..d472eb9d14 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/java/org/openecomp/sdcrests/wrappers/StringWrapperResponse.java @@ -0,0 +1,42 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.wrappers; + +public class StringWrapperResponse { + private String value; + + public StringWrapperResponse() { + } + + public StringWrapperResponse(String value) { + super(); + this.value = value; + } + + public String getValue() { + return value; + } + + public void setValue(String value) { + this.value = value; + } + +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/resources/errorCodesToResponseStatusMapping.json b/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/resources/errorCodesToResponseStatusMapping.json new file mode 100644 index 0000000000..e4c6962847 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/openecomp-sdc-common-rest/src/main/resources/errorCodesToResponseStatusMapping.json @@ -0,0 +1,9 @@ +{ + "VSP_NOT_FOUND": "NOT_FOUND", + "VSP_INVALID": "BAD_REQUEST", + "UPLOAD_INVALID" : "PRECONDITION_FAILED", + "PACKAGE_NOT_FOUND": "NOT_FOUND", + "PACKAGE_INVALID": "BAD_REQUEST", + "VENDOR_LICENSE_MODEL_NOT_FOUND": "NOT_FOUND", + "VENDOR_LICENSE_ENTITY_NOT_FOUND": "NOT_FOUND" +} \ No newline at end of file diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/pom.xml b/openecomp-be/api/openecomp-sdc-rest-webapp/pom.xml new file mode 100644 index 0000000000..7d20b19016 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/pom.xml @@ -0,0 +1,29 @@ + + 4.0.0 + + + org.openecomp.sdc + openecomp-sdc-api + 1.0.0-SNAPSHOT + ../ + + + openecomp-sdc-rest-webapp + openecomp-sdc-rest-webapp + pom + + + + + /openecomp-sdc-common-rest + /vendor-license-rest + /onboarding-rest-war + /vendor-software-products-rest + /sequence-rest + /validation-rest + /action-library-rest + /application-config-rest + + + \ No newline at end of file diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/sequence-rest/pom.xml b/openecomp-be/api/openecomp-sdc-rest-webapp/sequence-rest/pom.xml new file mode 100644 index 0000000000..68f021c16b --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/sequence-rest/pom.xml @@ -0,0 +1,15 @@ + + + + openecomp-sdc-rest-webapp + org.openecomp.sdc + 1.0.0-SNAPSHOT + + 4.0.0 + + sequence-rest + + + \ No newline at end of file diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/sequence-rest/src/main/java/org/openecomp/sdcrests/service/rest/Service.java b/openecomp-be/api/openecomp-sdc-rest-webapp/sequence-rest/src/main/java/org/openecomp/sdcrests/service/rest/Service.java new file mode 100644 index 0000000000..3e1a107b81 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/sequence-rest/src/main/java/org/openecomp/sdcrests/service/rest/Service.java @@ -0,0 +1,24 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.service.rest; + +public interface Service { +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/sequence-rest/src/main/java/org/openecomp/sdcrests/service/rest/services/ServiceImpl.java b/openecomp-be/api/openecomp-sdc-rest-webapp/sequence-rest/src/main/java/org/openecomp/sdcrests/service/rest/services/ServiceImpl.java new file mode 100644 index 0000000000..030d4a9c1d --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/sequence-rest/src/main/java/org/openecomp/sdcrests/service/rest/services/ServiceImpl.java @@ -0,0 +1,26 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.service.rest.services; + +import org.openecomp.sdcrests.service.rest.Service; + +public class ServiceImpl implements Service { +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/validation-rest/pom.xml b/openecomp-be/api/openecomp-sdc-rest-webapp/validation-rest/pom.xml new file mode 100644 index 0000000000..1db9db948c --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/validation-rest/pom.xml @@ -0,0 +1,23 @@ + + + 4.0.0 + + + org.openecomp.sdc + openecomp-sdc-rest-webapp + 1.0.0-SNAPSHOT + + + org.openecomp.sdc.onboarding + validation-rest + validation-rest + pom + + + + /validation-rest-services + /validation-rest-types + + \ No newline at end of file diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/validation-rest/validation-rest-services/pom.xml b/openecomp-be/api/openecomp-sdc-rest-webapp/validation-rest/validation-rest-services/pom.xml new file mode 100644 index 0000000000..793cdc0d42 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/validation-rest/validation-rest-services/pom.xml @@ -0,0 +1,144 @@ + + + 4.0.0 + + + org.openecomp.sdc.onboarding + validation-rest + 1.0.0-SNAPSHOT + + + validation-rest-services + + + + + org.springframework + spring-core + ${spring.framework.version} + + + org.springframework + spring-context + ${spring.framework.version} + + + org.springframework + spring-context-support + ${spring.framework.version} + + + org.springframework + spring-web + ${spring.framework.version} + + + org.springframework + spring-beans + ${spring.framework.version} + + + + + org.apache.cxf + cxf-rt-frontend-jaxrs + ${cxf.version} + + + + org.apache.httpcomponents + httpclient + ${http.client.version} + + + + javax.ws.rs + javax.ws.rs-api + ${ws.rs.version} + + + + + cglib + cglib-nodep + ${cglib.nodep.version} + runtime + + + + + javax.inject + javax.inject + ${javax.inject.version} + provided + + + javax.ws.rs + javax.ws.rs-api + ${ws.rs.version} + + + com.sun.jersey + jersey-core + 1.19.1 + + + javax.ws.rs + jsr311-api + + + + + io.swagger + swagger-annotations + 1.5.3 + + + org.openecomp.sdc.onboarding + validation-rest-types + ${project.version} + + + com.fasterxml.jackson.core + jackson-annotations + 2.7.4 + + + com.fasterxml.jackson.dataformat + jackson-dataformat-xml + 2.7.4 + + + org.codehaus.woodstox + woodstox-core-asl + 4.4.1 + + + + org.openecomp.sdc + openecomp-sdc-vendor-software-product-manager + ${project.version} + + + + + + + + + + org.apache.maven.plugins + maven-surefire-plugin + + + test/core/unittest/offline/** + + true + + + + + + \ No newline at end of file diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/validation-rest/validation-rest-services/src/main/java/org/openecomp/sdcrests/validation/rest/Validation.java b/openecomp-be/api/openecomp-sdc-rest-webapp/validation-rest/validation-rest-services/src/main/java/org/openecomp/sdcrests/validation/rest/Validation.java new file mode 100644 index 0000000000..5a1955c0dd --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/validation-rest/validation-rest-services/src/main/java/org/openecomp/sdcrests/validation/rest/Validation.java @@ -0,0 +1,52 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.validation.rest; + +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import org.apache.cxf.jaxrs.ext.multipart.Multipart; +import org.springframework.validation.annotation.Validated; + +import java.io.InputStream; +import javax.ws.rs.Consumes; +import javax.ws.rs.POST; +import javax.ws.rs.Path; +import javax.ws.rs.PathParam; +import javax.ws.rs.Produces; +import javax.ws.rs.core.MediaType; +import javax.ws.rs.core.Response; + + +@Path("/v1.0/validation") +@Produces(MediaType.APPLICATION_JSON) +@Consumes(MediaType.APPLICATION_JSON) +@Api(value = "Validation") +@Validated +public interface Validation { + + + @POST + @Path("{type}/validate") + @Consumes(MediaType.MULTIPART_FORM_DATA) + @ApiOperation(value = "Validate a package") + Response validateFile(@PathParam("type") String type, + @Multipart("validate") InputStream fileToValidate); +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/validation-rest/validation-rest-services/src/main/java/org/openecomp/sdcrests/validation/rest/mapping/MapValidationFileResponseToValidationFileResponseDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/validation-rest/validation-rest-services/src/main/java/org/openecomp/sdcrests/validation/rest/mapping/MapValidationFileResponseToValidationFileResponseDto.java new file mode 100644 index 0000000000..bd8639b682 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/validation-rest/validation-rest-services/src/main/java/org/openecomp/sdcrests/validation/rest/mapping/MapValidationFileResponseToValidationFileResponseDto.java @@ -0,0 +1,34 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.validation.rest.mapping; + + +import org.openecomp.sdc.validation.types.ValidationFileResponse; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.validation.types.ValidationFileResponseDto; + +public class MapValidationFileResponseToValidationFileResponseDto + extends MappingBase { + @Override + public void doMapping(ValidationFileResponse source, ValidationFileResponseDto target) { + target.setValidationData(source.getValidationData()); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/validation-rest/validation-rest-services/src/main/java/org/openecomp/sdcrests/validation/rest/services/ValidationImpl.java b/openecomp-be/api/openecomp-sdc-rest-webapp/validation-rest/validation-rest-services/src/main/java/org/openecomp/sdcrests/validation/rest/services/ValidationImpl.java new file mode 100644 index 0000000000..88a173de84 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/validation-rest/validation-rest-services/src/main/java/org/openecomp/sdcrests/validation/rest/services/ValidationImpl.java @@ -0,0 +1,63 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.validation.rest.services; + +import org.openecomp.sdc.validation.UploadValidationManager; +import org.openecomp.sdc.validation.types.ValidationFileResponse; +import org.openecomp.sdcrests.validation.rest.Validation; +import org.openecomp.sdcrests.validation.rest.mapping.MapValidationFileResponseToValidationFileResponseDto; +import org.openecomp.sdcrests.validation.types.ValidationFileResponseDto; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.context.annotation.Scope; +import org.springframework.stereotype.Service; + +import java.io.IOException; +import java.io.InputStream; +import javax.inject.Named; +import javax.ws.rs.core.Response; + + +@Named +@Service("validation") +@Scope(value = "prototype") +public class ValidationImpl implements Validation { + + @Autowired + private UploadValidationManager uploadValidationManager; + + @Override + public Response validateFile(String type, InputStream fileToValidate) { + ValidationFileResponse validationFileResponse = null; + try { + validationFileResponse = uploadValidationManager.validateFile(type, fileToValidate); + } catch (IOException e0) { + throw new RuntimeException(e0); + } + + ValidationFileResponseDto validationFileResponseDto = + new MapValidationFileResponseToValidationFileResponseDto() + .applyMapping(validationFileResponse, ValidationFileResponseDto.class); + + return Response.ok(validationFileResponseDto).build(); + } + + +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/validation-rest/validation-rest-types/pom.xml b/openecomp-be/api/openecomp-sdc-rest-webapp/validation-rest/validation-rest-types/pom.xml new file mode 100644 index 0000000000..fa844f891c --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/validation-rest/validation-rest-types/pom.xml @@ -0,0 +1,32 @@ + + + 4.0.0 + + + org.openecomp.sdc.onboarding + validation-rest + 1.0.0-SNAPSHOT + ../ + + + validation-rest-types + validation-rest-types + + + + + + org.openecomp.sdc + openecomp-sdc-common-rest + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-validation-manager + ${project.version} + + + + \ No newline at end of file diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/validation-rest/validation-rest-types/src/main/java/org/openecomp/sdcrests/validation/types/ValidationFileResponseDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/validation-rest/validation-rest-types/src/main/java/org/openecomp/sdcrests/validation/types/ValidationFileResponseDto.java new file mode 100644 index 0000000000..75e59973e3 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/validation-rest/validation-rest-types/src/main/java/org/openecomp/sdcrests/validation/types/ValidationFileResponseDto.java @@ -0,0 +1,36 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.validation.types; + +import org.openecomp.sdc.heat.datatypes.structure.ValidationStructureList; + +public class ValidationFileResponseDto { + + private ValidationStructureList validationData; + + public ValidationStructureList getValidationData() { + return validationData; + } + + public void setValidationData(ValidationStructureList validationData) { + this.validationData = validationData; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/pom.xml b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/pom.xml new file mode 100644 index 0000000000..6c8a7376a2 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/pom.xml @@ -0,0 +1,24 @@ + + 4.0.0 + + + org.openecomp.sdc + openecomp-sdc-rest-webapp + 1.0.0-SNAPSHOT + ../ + + + org.openecomp.sdc.onboarding + vendor-license-rest + vendor-license-rest + pom + + + + + /vendor-license-rest-services + /vendor-license-rest-types + + + \ No newline at end of file diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/pom.xml b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/pom.xml new file mode 100644 index 0000000000..86f7ebde14 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/pom.xml @@ -0,0 +1,133 @@ + + 4.0.0 + + + org.openecomp.sdc.onboarding + vendor-license-rest + 1.0.0-SNAPSHOT + ../ + + + vendor-license-rest-services + vendor-license-rest-services + + + + + + ${project.build.directory}/generated-sources/error-codes + + + + + ${project.groupId} + vendor-license-rest-types + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-vendor-license-api + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-vendor-license-manager + ${project.version} + + + + + + org.springframework + spring-core + ${spring.framework.version} + + + org.springframework + spring-context + ${spring.framework.version} + + + org.springframework + spring-context-support + ${spring.framework.version} + + + org.springframework + spring-web + ${spring.framework.version} + + + org.springframework + spring-beans + ${spring.framework.version} + + + + + org.apache.cxf + cxf-rt-frontend-jaxrs + ${cxf.version} + + + + org.apache.httpcomponents + httpclient + ${http.client.version} + + + org.apache.httpcomponents + httpcore + ${http.client.version} + + + + javax.ws.rs + javax.ws.rs-api + ${ws.rs.version} + + + + + cglib + cglib-nodep + ${cglib.nodep.version} + runtime + + + + + javax.inject + javax.inject + ${javax.inject.version} + provided + + + org.openecomp.sdc + openecomp-sdc-vendor-software-product-manager + ${project.version} + + + + + + + + + org.apache.maven.plugins + maven-surefire-plugin + + + test/core/unittest/offline/** + + true + + + + + + + + + \ No newline at end of file diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/EntitlementPools.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/EntitlementPools.java new file mode 100644 index 0000000000..9dea767f7d --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/EntitlementPools.java @@ -0,0 +1,105 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.rest; + +import static org.openecomp.sdcrests.common.RestConstants.USER_HEADER_PARAM; +import static org.openecomp.sdcrests.common.RestConstants.USER_MISSING_ERROR_MSG; + +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import io.swagger.annotations.ApiParam; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdcrests.vendorlicense.types.EntitlementPoolEntityDto; +import org.openecomp.sdcrests.vendorlicense.types.EntitlementPoolRequestDto; +import org.springframework.validation.annotation.Validated; + +import javax.validation.Valid; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Pattern; +import javax.ws.rs.Consumes; +import javax.ws.rs.DELETE; +import javax.ws.rs.GET; +import javax.ws.rs.HeaderParam; +import javax.ws.rs.POST; +import javax.ws.rs.PUT; +import javax.ws.rs.Path; +import javax.ws.rs.PathParam; +import javax.ws.rs.Produces; +import javax.ws.rs.QueryParam; +import javax.ws.rs.core.MediaType; +import javax.ws.rs.core.Response; + +@Path("/v1.0/vendor-license-models/{vlmId}/entitlement-pools") +@Produces(MediaType.APPLICATION_JSON) +@Consumes(MediaType.APPLICATION_JSON) +@Api(value = "Vendor License Model - Entitlement Pools") +@Validated +public interface EntitlementPools { + @GET + @Path("/") + @ApiOperation(value = "List vendor entitlement pools", + response = EntitlementPoolEntityDto.class, + responseContainer = "List") + Response listEntitlementPools( + @ApiParam(value = "Vendor license model Id") @PathParam("vlmId") String vlmId, + @Pattern(regexp = Version.VERSION_REGEX, message = Version.VERSION_STRING_VIOLATION_MSG) + @QueryParam("version") String version, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) String user); + + @POST + @Path("/") + @ApiOperation(value = "Create vendor entitlement pool") + Response createEntitlementPool(@Valid EntitlementPoolRequestDto request, + @ApiParam(value = "Vendor license model Id") @PathParam("vlmId") + String vlmId, + @NotNull(message = USER_MISSING_ERROR_MSG) + @HeaderParam(USER_HEADER_PARAM) String user); + + @PUT + @Path("/{entitlementPoolId}") + @ApiOperation(value = "Update vendor entitlement pool") + Response updateEntitlementPool(@Valid EntitlementPoolRequestDto request, + @ApiParam(value = "Vendor license model Id") @PathParam("vlmId") + String vlmId, + @NotNull(message = USER_MISSING_ERROR_MSG) + @PathParam("entitlementPoolId") String entitlementPoolId, + @HeaderParam(USER_HEADER_PARAM) String user); + + @GET + @Path("/{entitlementPoolId}") + @ApiOperation(value = "Get vendor entitlement pool", + response = EntitlementPoolEntityDto.class) + Response getEntitlementPool( + @ApiParam(value = "Vendor license model Id") @PathParam("vlmId") String vlmId, + @Pattern(regexp = Version.VERSION_REGEX, message = Version.VERSION_STRING_VIOLATION_MSG) + @QueryParam("version") String version, + @PathParam("entitlementPoolId") String entitlementPoolId, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) String user); + + @DELETE + @Path("/{entitlementPoolId}") + @ApiOperation(value = "Delete vendor entitlement pool") + Response deleteEntitlementPool( + @ApiParam(value = "Vendor license model Id") @PathParam("vlmId") String vlmId, + @PathParam("entitlementPoolId") String entitlementPoolId, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) String user); + +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/FeatureGroups.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/FeatureGroups.java new file mode 100644 index 0000000000..f5ad973cb0 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/FeatureGroups.java @@ -0,0 +1,108 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.rest; + +import static org.openecomp.sdcrests.common.RestConstants.USER_HEADER_PARAM; +import static org.openecomp.sdcrests.common.RestConstants.USER_MISSING_ERROR_MSG; + +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import io.swagger.annotations.ApiParam; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdcrests.vendorlicense.types.FeatureGroupEntityDto; +import org.openecomp.sdcrests.vendorlicense.types.FeatureGroupModelDto; +import org.openecomp.sdcrests.vendorlicense.types.FeatureGroupRequestDto; +import org.openecomp.sdcrests.vendorlicense.types.FeatureGroupUpdateRequestDto; +import org.springframework.validation.annotation.Validated; + +import javax.validation.Valid; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Pattern; +import javax.ws.rs.Consumes; +import javax.ws.rs.DELETE; +import javax.ws.rs.GET; +import javax.ws.rs.HeaderParam; +import javax.ws.rs.POST; +import javax.ws.rs.PUT; +import javax.ws.rs.Path; +import javax.ws.rs.PathParam; +import javax.ws.rs.Produces; +import javax.ws.rs.QueryParam; +import javax.ws.rs.core.MediaType; +import javax.ws.rs.core.Response; + +@Path("/v1.0/vendor-license-models/{vlmId}/feature-groups") +@Produces(MediaType.APPLICATION_JSON) +@Consumes(MediaType.APPLICATION_JSON) +@Api(value = "Vendor License Model - Feature Groups") +@Validated +public interface FeatureGroups { + + @GET + @Path("/") + @ApiOperation(value = "List vendor feature groups", + response = FeatureGroupEntityDto.class, + responseContainer = "List") + Response listFeatureGroups( + @ApiParam(value = "Vendor license model Id") @PathParam("vlmId") String vlmId, + @Pattern(regexp = Version.VERSION_REGEX, message = Version.VERSION_STRING_VIOLATION_MSG) + @QueryParam("version") String version, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) String user); + + @POST + @Path("/") + @ApiOperation(value = "Create vendor feature group") + Response createFeatureGroup(@Valid FeatureGroupRequestDto request, + @ApiParam(value = "Vendor license model Id") @PathParam("vlmId") + String vlmId, + @NotNull(message = USER_MISSING_ERROR_MSG) + @HeaderParam(USER_HEADER_PARAM) String user); + + @PUT + @Path("/{featureGroupId}") + @ApiOperation(value = "Update vendor feature group") + Response updateFeatureGroup(@Valid FeatureGroupUpdateRequestDto request, + @ApiParam(value = "Vendor license model Id") @PathParam("vlmId") + String vlmId, + @PathParam("featureGroupId") String featureGroupId, + @NotNull(message = USER_MISSING_ERROR_MSG) + @HeaderParam(USER_HEADER_PARAM) String user); + + @GET + @Path("/{featureGroupId}") + @ApiOperation(value = "Get vendor feature group", + response = FeatureGroupModelDto.class) + Response getFeatureGroup( + @ApiParam(value = "Vendor license model Id") @PathParam("vlmId") String vlmId, + @Pattern(regexp = Version.VERSION_REGEX, message = Version.VERSION_STRING_VIOLATION_MSG) + @QueryParam("version") String version, + @PathParam("featureGroupId") String featureGroupId, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) String user); + + @DELETE + @Path("/{featureGroupId}") + @ApiOperation(value = "Delete vendor feature group") + Response deleteFeatureGroup( + @ApiParam(value = "Vendor license model Id") @PathParam("vlmId") String vlmId, + @PathParam("featureGroupId") String featureGroupId, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) String user); + +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/LicenseAgreements.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/LicenseAgreements.java new file mode 100644 index 0000000000..28d9f5a32f --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/LicenseAgreements.java @@ -0,0 +1,109 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.rest; + +import static org.openecomp.sdcrests.common.RestConstants.USER_HEADER_PARAM; +import static org.openecomp.sdcrests.common.RestConstants.USER_MISSING_ERROR_MSG; + +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import io.swagger.annotations.ApiParam; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdcrests.vendorlicense.types.LicenseAgreementEntityDto; +import org.openecomp.sdcrests.vendorlicense.types.LicenseAgreementModelDto; +import org.openecomp.sdcrests.vendorlicense.types.LicenseAgreementRequestDto; +import org.openecomp.sdcrests.vendorlicense.types.LicenseAgreementUpdateRequestDto; +import org.springframework.validation.annotation.Validated; + +import javax.validation.Valid; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Pattern; +import javax.ws.rs.Consumes; +import javax.ws.rs.DELETE; +import javax.ws.rs.GET; +import javax.ws.rs.HeaderParam; +import javax.ws.rs.POST; +import javax.ws.rs.PUT; +import javax.ws.rs.Path; +import javax.ws.rs.PathParam; +import javax.ws.rs.Produces; +import javax.ws.rs.QueryParam; +import javax.ws.rs.core.MediaType; +import javax.ws.rs.core.Response; + +@Path("/v1.0/vendor-license-models/{vlmId}/license-agreements") +@Produces(MediaType.APPLICATION_JSON) +@Consumes(MediaType.APPLICATION_JSON) +@Api(value = "Vendor License Model - License Agreements") +@Validated + +public interface LicenseAgreements { + + @GET + @Path("/") + @ApiOperation(value = "List vendor license agreements", + response = LicenseAgreementEntityDto.class, + responseContainer = "List") + Response listLicenseAgreements( + @ApiParam(value = "Vendor license model Id") @PathParam("vlmId") String vlmId, + @Pattern(regexp = Version.VERSION_REGEX, message = Version.VERSION_STRING_VIOLATION_MSG) + @QueryParam("version") String version, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) String user); + + @POST + @Path("/") + @ApiOperation(value = "Create vendor license agreement") + Response createLicenseAgreement(@Valid LicenseAgreementRequestDto request, + @ApiParam(value = "Vendor license model Id") @PathParam("vlmId") + String vlmId, + @NotNull(message = USER_MISSING_ERROR_MSG) + @HeaderParam(USER_HEADER_PARAM) String user); + + @PUT + @Path("/{licenseAgreementId}") + @ApiOperation(value = "Update vendor license agreement") + Response updateLicenseAgreement(@Valid LicenseAgreementUpdateRequestDto request, + @ApiParam(value = "Vendor license model Id") @PathParam("vlmId") + String vlmId, + @PathParam("licenseAgreementId") String licenseAgreementId, + @NotNull(message = USER_MISSING_ERROR_MSG) + @HeaderParam(USER_HEADER_PARAM) String user); + + @GET + @Path("/{licenseAgreementId}") + @ApiOperation(value = "Get vendor license agreement", + response = LicenseAgreementModelDto.class) + Response getLicenseAgreement( + @ApiParam(value = "Vendor license model Id") @PathParam("vlmId") String vlmId, + @Pattern(regexp = Version.VERSION_REGEX, message = Version.VERSION_STRING_VIOLATION_MSG) + @QueryParam("version") String version, + @PathParam("licenseAgreementId") String licenseAgreementId, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) String user); + + @DELETE + @Path("/{licenseAgreementId}") + @ApiOperation(value = "Delete vendor license agreement") + Response deleteLicenseAgreement( + @ApiParam(value = "Vendor license model Id") @PathParam("vlmId") String vlmId, + @PathParam("licenseAgreementId") String licenseAgreementId, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) String user); + +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/LicenseKeyGroups.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/LicenseKeyGroups.java new file mode 100644 index 0000000000..d66945d63c --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/LicenseKeyGroups.java @@ -0,0 +1,104 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.rest; + +import static org.openecomp.sdcrests.common.RestConstants.USER_HEADER_PARAM; +import static org.openecomp.sdcrests.common.RestConstants.USER_MISSING_ERROR_MSG; + +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import io.swagger.annotations.ApiParam; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdcrests.vendorlicense.types.LicenseKeyGroupEntityDto; +import org.openecomp.sdcrests.vendorlicense.types.LicenseKeyGroupRequestDto; +import org.springframework.validation.annotation.Validated; + +import javax.validation.Valid; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Pattern; +import javax.ws.rs.Consumes; +import javax.ws.rs.DELETE; +import javax.ws.rs.GET; +import javax.ws.rs.HeaderParam; +import javax.ws.rs.POST; +import javax.ws.rs.PUT; +import javax.ws.rs.Path; +import javax.ws.rs.PathParam; +import javax.ws.rs.Produces; +import javax.ws.rs.QueryParam; +import javax.ws.rs.core.MediaType; +import javax.ws.rs.core.Response; + +@Path("/v1.0/vendor-license-models/{vlmId}/license-key-groups") +@Produces(MediaType.APPLICATION_JSON) +@Consumes(MediaType.APPLICATION_JSON) +@Api(value = "Vendor License Model - License Key Groups") +@Validated +public interface LicenseKeyGroups { + @GET + @Path("/") + @ApiOperation(value = "List vendor license key groups", + response = LicenseKeyGroupEntityDto.class, + responseContainer = "List") + Response listLicenseKeyGroups( + @ApiParam(value = "Vendor license model Id") @PathParam("vlmId") String vlmId, + @Pattern(regexp = Version.VERSION_REGEX, message = Version.VERSION_STRING_VIOLATION_MSG) + @QueryParam("version") String version, + @HeaderParam(USER_HEADER_PARAM) String user); + + @POST + @Path("/") + @ApiOperation(value = "Create vendor license key group") + Response createLicenseKeyGroup(@Valid LicenseKeyGroupRequestDto request, + @ApiParam(value = "Vendor license model Id") @PathParam("vlmId") + String vlmId, + @NotNull(message = USER_MISSING_ERROR_MSG) + @HeaderParam(USER_HEADER_PARAM) String user); + + @PUT + @Path("/{licenseKeyGroupId}") + @ApiOperation(value = "Update vendor license key group") + Response updateLicenseKeyGroup(@Valid LicenseKeyGroupRequestDto request, + @ApiParam(value = "Vendor license model Id") @PathParam("vlmId") + String vlmId, + @PathParam("licenseKeyGroupId") String licenseKeyGroupId, + @NotNull(message = USER_MISSING_ERROR_MSG) + @HeaderParam(USER_HEADER_PARAM) String user); + + @GET + @Path("/{licenseKeyGroupId}") + @ApiOperation(value = "Get vendor license key group", + response = LicenseKeyGroupEntityDto.class) + Response getLicenseKeyGroup( + @ApiParam(value = "Vendor license model Id") @PathParam("vlmId") String vlmId, + @Pattern(regexp = Version.VERSION_REGEX, message = Version.VERSION_STRING_VIOLATION_MSG) + @QueryParam("version") String version, + @PathParam("licenseKeyGroupId") String licenseKeyGroupId, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) String user); + + @DELETE + @Path("/{licenseKeyGroupId}") + @ApiOperation(value = "Delete vendor license key group") + Response deleteLicenseKeyGroup( + @ApiParam(value = "Vendor license model Id") @PathParam("vlmId") String vlmId, + @PathParam("licenseKeyGroupId") String licenseKeyGroupId, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) String user); +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/VendorLicenseModels.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/VendorLicenseModels.java new file mode 100644 index 0000000000..15fc9bf0d9 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/VendorLicenseModels.java @@ -0,0 +1,111 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.rest; + +import static org.openecomp.sdcrests.common.RestConstants.USER_MISSING_ERROR_MSG; + +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import io.swagger.annotations.ApiParam; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdcrests.common.RestConstants; +import org.openecomp.sdcrests.vendorlicense.types.VendorLicenseModelActionRequestDto; +import org.openecomp.sdcrests.vendorlicense.types.VendorLicenseModelEntityDto; +import org.openecomp.sdcrests.vendorlicense.types.VendorLicenseModelRequestDto; +import org.springframework.validation.annotation.Validated; + +import javax.validation.Valid; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Pattern; +import javax.ws.rs.Consumes; +import javax.ws.rs.DELETE; +import javax.ws.rs.GET; +import javax.ws.rs.HeaderParam; +import javax.ws.rs.POST; +import javax.ws.rs.PUT; +import javax.ws.rs.Path; +import javax.ws.rs.PathParam; +import javax.ws.rs.Produces; +import javax.ws.rs.QueryParam; +import javax.ws.rs.core.MediaType; +import javax.ws.rs.core.Response; + +@Path("/v1.0/vendor-license-models") +@Produces(MediaType.APPLICATION_JSON) +@Consumes(MediaType.APPLICATION_JSON) +@Api(value = "Vendor License Models") +@Validated +public interface VendorLicenseModels { + + @GET + @Path("/") + @ApiOperation(value = "List vendor license models", + response = VendorLicenseModelEntityDto.class, + responseContainer = "List") + Response listLicenseModels(@ApiParam( + value = "Currently supported value: 'Final' - only vendor License models with final versions " + + "will be return - with their latest final version") + @QueryParam("versionFilter") String versionFilter, + @NotNull(message = USER_MISSING_ERROR_MSG) + @HeaderParam(RestConstants.USER_HEADER_PARAM) String user); + + @POST + @Path("/") + @ApiOperation(value = "Create vendor license model") + Response createLicenseModel(@Valid VendorLicenseModelRequestDto request, + @NotNull(message = USER_MISSING_ERROR_MSG) + @HeaderParam(RestConstants.USER_HEADER_PARAM) String user); + + @PUT + @Path("/{vlmId}") + @ApiOperation(value = "Update vendor license model") + Response updateLicenseModel(@Valid VendorLicenseModelRequestDto request, + @ApiParam(value = "Vendor license model Id") @PathParam("vlmId") + String vlmId, @NotNull(message = USER_MISSING_ERROR_MSG) + @HeaderParam(RestConstants.USER_HEADER_PARAM) String user); + + @GET + @Path("/{vlmId}") + @ApiOperation(value = "Get vendor license model", + response = VendorLicenseModelEntityDto.class) + Response getLicenseModel( + @ApiParam(value = "Vendor license model Id") @PathParam("vlmId") String vlmId, + @Pattern(regexp = Version.VERSION_REGEX, message = Version.VERSION_STRING_VIOLATION_MSG) + @QueryParam("version") String version, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(RestConstants.USER_HEADER_PARAM) + String user); + + @DELETE + @Path("/{vlmId}") + @ApiOperation(value = "Delete vendor license model") + Response deleteLicenseModel( + @ApiParam(value = "Vendor license model Id") @PathParam("vlmId") String vlmId, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(RestConstants.USER_HEADER_PARAM) + String user); + + @PUT + @Path("/{vlmId}/actions") + @ApiOperation(value = "Update vendor license model") + Response actOnLicenseModel(@Valid VendorLicenseModelActionRequestDto request, + @ApiParam(value = "Vendor license model Id") @PathParam("vlmId") + String vlmId, @NotNull(message = USER_MISSING_ERROR_MSG) + @HeaderParam(RestConstants.USER_HEADER_PARAM) String user); +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapChoiceOrOtherDtoToChoiceOrOther.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapChoiceOrOtherDtoToChoiceOrOther.java new file mode 100644 index 0000000000..28eeb29018 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapChoiceOrOtherDtoToChoiceOrOther.java @@ -0,0 +1,36 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.rest.mapping; + +import org.openecomp.sdc.vendorlicense.dao.types.ChoiceOrOther; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.vendorlicense.types.ChoiceOrOtherDto; + +public class MapChoiceOrOtherDtoToChoiceOrOther + extends MappingBase { + + @Override + public void doMapping(ChoiceOrOtherDto source, ChoiceOrOther target) { + target.setChoice(source.getChoice()); + target.setOther(source.getOther()); + target.setResult(null); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapChoiceOrOtherToChoiceOrOtherDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapChoiceOrOtherToChoiceOrOtherDto.java new file mode 100644 index 0000000000..2d686110d5 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapChoiceOrOtherToChoiceOrOtherDto.java @@ -0,0 +1,35 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.rest.mapping; + +import org.openecomp.sdc.vendorlicense.dao.types.ChoiceOrOther; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.vendorlicense.types.ChoiceOrOtherDto; + +public class MapChoiceOrOtherToChoiceOrOtherDto + extends MappingBase { + + @Override + public void doMapping(ChoiceOrOther source, ChoiceOrOtherDto target) { + target.setChoice(source.getChoice()); + target.setOther(source.getOther()); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapEntitlementPoolEntityToEntitlementPoolEntityDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapEntitlementPoolEntityToEntitlementPoolEntityDto.java new file mode 100644 index 0000000000..c9f4ab894b --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapEntitlementPoolEntityToEntitlementPoolEntityDto.java @@ -0,0 +1,53 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.rest.mapping; + +import org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.vendorlicense.types.ChoiceOrOtherDto; +import org.openecomp.sdcrests.vendorlicense.types.EntitlementPoolEntityDto; +import org.openecomp.sdcrests.vendorlicense.types.MultiChoiceOrOtherDto; + +public class MapEntitlementPoolEntityToEntitlementPoolEntityDto + extends MappingBase { + @Override + public void doMapping(EntitlementPoolEntity source, EntitlementPoolEntityDto target) { + target.setId(source.getId()); + target.setName(source.getName()); + target.setDescription(source.getDescription()); + target.setThresholdValue(source.getThresholdValue()); + target.setThresholdUnits(source.getThresholdUnit()); + target.setIncrements(source.getIncrements()); + + MapChoiceOrOtherToChoiceOrOtherDto choiceOrOtherMapper = + new MapChoiceOrOtherToChoiceOrOtherDto(); + target.setEntitlementMetric( + choiceOrOtherMapper.applyMapping(source.getEntitlementMetric(), ChoiceOrOtherDto.class)); + target.setAggregationFunction( + choiceOrOtherMapper.applyMapping(source.getAggregationFunction(), ChoiceOrOtherDto.class)); + target.setOperationalScope(new MapMultiChoiceOrOtherToMultiChoiceOrOtherDto() + .applyMapping(source.getOperationalScope(), MultiChoiceOrOtherDto.class)); + target.setTime(choiceOrOtherMapper.applyMapping(source.getTime(), ChoiceOrOtherDto.class)); + target.setManufacturerReferenceNumber(source.getManufacturerReferenceNumber()); + + target.setReferencingFeatureGroups(source.getReferencingFeatureGroups()); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapEntitlementPoolRequestDtoToEntitlementPoolEntity.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapEntitlementPoolRequestDtoToEntitlementPoolEntity.java new file mode 100644 index 0000000000..fe626e374c --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapEntitlementPoolRequestDtoToEntitlementPoolEntity.java @@ -0,0 +1,51 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.rest.mapping; + +import org.openecomp.sdc.vendorlicense.dao.types.ChoiceOrOther; +import org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity; +import org.openecomp.sdc.vendorlicense.dao.types.MultiChoiceOrOther; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.vendorlicense.types.EntitlementPoolRequestDto; + +public class MapEntitlementPoolRequestDtoToEntitlementPoolEntity + extends MappingBase { + @Override + public void doMapping(EntitlementPoolRequestDto source, EntitlementPoolEntity target) { + target.setName(source.getName()); + target.setDescription(source.getDescription()); + target.setThresholdValue(source.getThresholdValue()); + target.setThresholdUnit(source.getThresholdUnits()); + target.setIncrements(source.getIncrements()); + + MapChoiceOrOtherDtoToChoiceOrOther choiceOrOtherMapper = + new MapChoiceOrOtherDtoToChoiceOrOther(); + target.setEntitlementMetric( + choiceOrOtherMapper.applyMapping(source.getEntitlementMetric(), ChoiceOrOther.class)); + target.setAggregationFunction( + choiceOrOtherMapper.applyMapping(source.getAggregationFunction(), ChoiceOrOther.class)); + target.setOperationalScope(new MapMultiChoiceOrOtherDtoToMultiChoiceOrOther() + .applyMapping(source.getOperationalScope(), MultiChoiceOrOther.class)); + target.setTime(choiceOrOtherMapper.applyMapping(source.getTime(), ChoiceOrOther.class)); + + target.setManufacturerReferenceNumber(source.getManufacturerReferenceNumber()); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapFeatureGroupDescriptorDtoToFeatureGroupEntity.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapFeatureGroupDescriptorDtoToFeatureGroupEntity.java new file mode 100644 index 0000000000..91239e2655 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapFeatureGroupDescriptorDtoToFeatureGroupEntity.java @@ -0,0 +1,36 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.rest.mapping; + +import org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.vendorlicense.types.FeatureGroupDescriptorDto; + + +public class MapFeatureGroupDescriptorDtoToFeatureGroupEntity + extends MappingBase { + @Override + public void doMapping(FeatureGroupDescriptorDto source, FeatureGroupEntity target) { + target.setName(source.getName()); + target.setDescription(source.getDescription()); + target.setPartNumber(source.getPartNumber()); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapFeatureGroupEntityToFeatureGroupDescriptorDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapFeatureGroupEntityToFeatureGroupDescriptorDto.java new file mode 100644 index 0000000000..70f5666bcb --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapFeatureGroupEntityToFeatureGroupDescriptorDto.java @@ -0,0 +1,35 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.rest.mapping; + +import org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.vendorlicense.types.FeatureGroupDescriptorDto; + +public class MapFeatureGroupEntityToFeatureGroupDescriptorDto + extends MappingBase { + @Override + public void doMapping(FeatureGroupEntity source, FeatureGroupDescriptorDto target) { + target.setName(source.getName()); + target.setDescription(source.getDescription()); + target.setPartNumber(source.getPartNumber()); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapLicenseAgreementDescriptorDtoToLicenseAgreementEntity.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapLicenseAgreementDescriptorDtoToLicenseAgreementEntity.java new file mode 100644 index 0000000000..f5ea8414d5 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapLicenseAgreementDescriptorDtoToLicenseAgreementEntity.java @@ -0,0 +1,38 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.rest.mapping; + +import org.openecomp.sdc.vendorlicense.dao.types.ChoiceOrOther; +import org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementEntity; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.vendorlicense.types.LicenseAgreementDescriptorDto; + +public class MapLicenseAgreementDescriptorDtoToLicenseAgreementEntity + extends MappingBase { + @Override + public void doMapping(LicenseAgreementDescriptorDto source, LicenseAgreementEntity target) { + target.setName(source.getName()); + target.setDescription(source.getDescription()); + target.setLicenseTerm(new MapChoiceOrOtherDtoToChoiceOrOther() + .applyMapping(source.getLicenseTerm(), ChoiceOrOther.class)); + target.setRequirementsAndConstrains(source.getRequirementsAndConstrains()); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapLicenseAgreementEntityToLicenseAgreementDescriptorDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapLicenseAgreementEntityToLicenseAgreementDescriptorDto.java new file mode 100644 index 0000000000..2fd4f669cf --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapLicenseAgreementEntityToLicenseAgreementDescriptorDto.java @@ -0,0 +1,38 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.rest.mapping; + +import org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementEntity; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.vendorlicense.types.ChoiceOrOtherDto; +import org.openecomp.sdcrests.vendorlicense.types.LicenseAgreementDescriptorDto; + +public class MapLicenseAgreementEntityToLicenseAgreementDescriptorDto + extends MappingBase { + @Override + public void doMapping(LicenseAgreementEntity source, LicenseAgreementDescriptorDto target) { + target.setName(source.getName()); + target.setDescription(source.getDescription()); + target.setLicenseTerm(new MapChoiceOrOtherToChoiceOrOtherDto() + .applyMapping(source.getLicenseTerm(), ChoiceOrOtherDto.class)); + target.setRequirementsAndConstrains(source.getRequirementsAndConstrains()); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapLicenseKeyGroupEntityToLicenseKeyGroupEntityDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapLicenseKeyGroupEntityToLicenseKeyGroupEntityDto.java new file mode 100644 index 0000000000..38384711b1 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapLicenseKeyGroupEntityToLicenseKeyGroupEntityDto.java @@ -0,0 +1,40 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.rest.mapping; + +import org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyGroupEntity; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.vendorlicense.types.LicenseKeyGroupEntityDto; +import org.openecomp.sdcrests.vendorlicense.types.MultiChoiceOrOtherDto; + +public class MapLicenseKeyGroupEntityToLicenseKeyGroupEntityDto + extends MappingBase { + @Override + public void doMapping(LicenseKeyGroupEntity source, LicenseKeyGroupEntityDto target) { + target.setId(source.getId()); + target.setName(source.getName()); + target.setDescription(source.getDescription()); + target.setType(source.getType()); + target.setOperationalScope(new MapMultiChoiceOrOtherToMultiChoiceOrOtherDto() + .applyMapping(source.getOperationalScope(), MultiChoiceOrOtherDto.class)); + target.setReferencingFeatureGroups(source.getReferencingFeatureGroups()); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapLicenseKeyGroupRequestDtoToLicenseKeyGroupEntity.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapLicenseKeyGroupRequestDtoToLicenseKeyGroupEntity.java new file mode 100644 index 0000000000..aee27c8521 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapLicenseKeyGroupRequestDtoToLicenseKeyGroupEntity.java @@ -0,0 +1,38 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.rest.mapping; + +import org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyGroupEntity; +import org.openecomp.sdc.vendorlicense.dao.types.MultiChoiceOrOther; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.vendorlicense.types.LicenseKeyGroupRequestDto; + +public class MapLicenseKeyGroupRequestDtoToLicenseKeyGroupEntity + extends MappingBase { + @Override + public void doMapping(LicenseKeyGroupRequestDto source, LicenseKeyGroupEntity target) { + target.setName(source.getName()); + target.setDescription(source.getDescription()); + target.setType(source.getType()); + target.setOperationalScope(new MapMultiChoiceOrOtherDtoToMultiChoiceOrOther() + .applyMapping(source.getOperationalScope(), MultiChoiceOrOther.class)); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapMultiChoiceOrOtherDtoToMultiChoiceOrOther.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapMultiChoiceOrOtherDtoToMultiChoiceOrOther.java new file mode 100644 index 0000000000..320bf67bdf --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapMultiChoiceOrOtherDtoToMultiChoiceOrOther.java @@ -0,0 +1,36 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.rest.mapping; + +import org.openecomp.sdc.vendorlicense.dao.types.MultiChoiceOrOther; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.vendorlicense.types.MultiChoiceOrOtherDto; + +public class MapMultiChoiceOrOtherDtoToMultiChoiceOrOther + extends MappingBase { + + @Override + public void doMapping(MultiChoiceOrOtherDto source, MultiChoiceOrOther target) { + target.setChoices(source.getChoices()); + target.setOther(source.getOther()); + target.setResults(null); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapMultiChoiceOrOtherToMultiChoiceOrOtherDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapMultiChoiceOrOtherToMultiChoiceOrOtherDto.java new file mode 100644 index 0000000000..9649053fb4 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapMultiChoiceOrOtherToMultiChoiceOrOtherDto.java @@ -0,0 +1,35 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.rest.mapping; + +import org.openecomp.sdc.vendorlicense.dao.types.MultiChoiceOrOther; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.vendorlicense.types.MultiChoiceOrOtherDto; + +public class MapMultiChoiceOrOtherToMultiChoiceOrOtherDto + extends MappingBase { + + @Override + public void doMapping(MultiChoiceOrOther source, MultiChoiceOrOtherDto target) { + target.setChoices(source.getChoices()); + target.setOther(source.getOther()); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapVendorLicenseModelRequestDtoToVendorLicenseModelEntity.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapVendorLicenseModelRequestDtoToVendorLicenseModelEntity.java new file mode 100644 index 0000000000..1117a2db9f --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapVendorLicenseModelRequestDtoToVendorLicenseModelEntity.java @@ -0,0 +1,36 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.rest.mapping; + +import org.openecomp.sdc.vendorlicense.dao.types.VendorLicenseModelEntity; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.vendorlicense.types.VendorLicenseModelRequestDto; + + +public class MapVendorLicenseModelRequestDtoToVendorLicenseModelEntity + extends MappingBase { + @Override + public void doMapping(VendorLicenseModelRequestDto source, VendorLicenseModelEntity target) { + target.setVendorName(source.getVendorName()); + target.setDescription(source.getDescription()); + target.setIconRef(source.getIconRef()); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapVersionedVendorLicenseModelToVendorLicenseModelEntityDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapVersionedVendorLicenseModelToVendorLicenseModelEntityDto.java new file mode 100644 index 0000000000..a53d5c9e36 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/mapping/MapVersionedVendorLicenseModelToVendorLicenseModelEntityDto.java @@ -0,0 +1,60 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.rest.mapping; + +import org.openecomp.core.utilities.CommonMethods; +import org.openecomp.sdc.vendorlicense.dao.types.VendorLicenseModelEntity; +import org.openecomp.sdc.vendorlicense.types.VersionedVendorLicenseModel; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.types.VersionInfo; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.vendorlicense.types.VendorLicenseModelEntityDto; + +import java.util.stream.Collectors; + +public class MapVersionedVendorLicenseModelToVendorLicenseModelEntityDto + extends MappingBase { + @Override + public void doMapping(VersionedVendorLicenseModel source, VendorLicenseModelEntityDto target) { + VendorLicenseModelEntity sourceVlm = source.getVendorLicenseModel(); + target.setId(sourceVlm.getId()); + target.setVendorName(sourceVlm.getVendorName()); + target.setDescription(sourceVlm.getDescription()); + target.setIconRef(sourceVlm.getIconRef()); + + VersionInfo versionInfo = source.getVersionInfo(); + if (versionInfo != null) { + target.setVersion(versionInfo.getActiveVersion().toString()); + target.setStatus(versionInfo.getStatus()); + target.setLockingUser(versionInfo.getLockingUser()); + + if (!CommonMethods.isEmpty(versionInfo.getViewableVersions())) { + target.setViewableVersions(versionInfo.getViewableVersions().stream().map(Version::toString) + .collect(Collectors.toList())); + } + + if (!CommonMethods.isEmpty(versionInfo.getFinalVersions())) { + target.setFinalVersions(versionInfo.getFinalVersions().stream().map(Version::toString) + .collect(Collectors.toList())); + } + } + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/services/EntitlementPoolsImpl.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/services/EntitlementPoolsImpl.java new file mode 100644 index 0000000000..ab9800e612 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/services/EntitlementPoolsImpl.java @@ -0,0 +1,157 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.rest.services; + +import org.openecomp.sdc.vendorlicense.VendorLicenseManager; +import org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity; +import org.openecomp.sdc.versioning.dao.types.Version; + +import org.openecomp.sdcrests.vendorlicense.rest.EntitlementPools; +import org.openecomp.sdcrests.vendorlicense.rest.mapping.MapEntitlementPoolEntityToEntitlementPoolEntityDto; +import org.openecomp.sdcrests.vendorlicense.rest.mapping.MapEntitlementPoolRequestDtoToEntitlementPoolEntity; +import org.openecomp.sdcrests.vendorlicense.types.EntitlementPoolEntityDto; +import org.openecomp.sdcrests.vendorlicense.types.EntitlementPoolRequestDto; +import org.openecomp.sdcrests.wrappers.GenericCollectionWrapper; +import org.openecomp.sdcrests.wrappers.StringWrapperResponse; + +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.context.annotation.Scope; +import org.springframework.stereotype.Service; + +import java.util.Collection; +import javax.inject.Named; +import javax.ws.rs.core.Response; + +@Named +@Service("entitlementPools") +@Scope(value = "prototype") +public class EntitlementPoolsImpl implements EntitlementPools { + + @Autowired + private VendorLicenseManager vendorLicenseManager; + + /** + * List entitlement pools response. + * + * @param vlmId the vlm id + * @param version the version + * @param user the user + * @return the response + */ + public Response listEntitlementPools(String vlmId, String version, String user) { + Collection entitlementPools = + vendorLicenseManager.listEntitlementPools(vlmId, Version.valueOf(version), user); + + GenericCollectionWrapper result = new GenericCollectionWrapper<>(); + MapEntitlementPoolEntityToEntitlementPoolEntityDto outputMapper = + new MapEntitlementPoolEntityToEntitlementPoolEntityDto(); + for (EntitlementPoolEntity ep : entitlementPools) { + result.add(outputMapper.applyMapping(ep, EntitlementPoolEntityDto.class)); + } + + return Response.ok(result).build(); + } + + /** + * Create entitlement pool response. + * + * @param request the request + * @param vlmId the vlm id + * @param user the user + * @return the response + */ + public Response createEntitlementPool(EntitlementPoolRequestDto request, String vlmId, + String user) { + EntitlementPoolEntity entitlementPoolEntity = + new MapEntitlementPoolRequestDtoToEntitlementPoolEntity() + .applyMapping(request, EntitlementPoolEntity.class); + entitlementPoolEntity.setVendorLicenseModelId(vlmId); + + EntitlementPoolEntity createdEntitlementPool = + vendorLicenseManager.createEntitlementPool(entitlementPoolEntity, user); + StringWrapperResponse result = + createdEntitlementPool != null ? new StringWrapperResponse(createdEntitlementPool.getId()) + : null; + + return Response.ok(result).build(); + } + + /** + * Update entitlement pool response. + * + * @param request the request + * @param vlmId the vlm id + * @param entitlementPoolId the entitlement pool id + * @param user the user + * @return the response + */ + public Response updateEntitlementPool(EntitlementPoolRequestDto request, String vlmId, + String entitlementPoolId, String user) { + EntitlementPoolEntity entitlementPoolEntity = + new MapEntitlementPoolRequestDtoToEntitlementPoolEntity() + .applyMapping(request, EntitlementPoolEntity.class); + + entitlementPoolEntity.setVendorLicenseModelId(vlmId); + entitlementPoolEntity.setId(entitlementPoolId); + + vendorLicenseManager.updateEntitlementPool(entitlementPoolEntity, user); + return Response.ok().build(); + } + + /** + * Gets entitlement pool. + * + * @param vlmId the vlm id + * @param version the version + * @param entitlementPoolId the entitlement pool id + * @param user the user + * @return the entitlement pool + */ + public Response getEntitlementPool(String vlmId, String version, String entitlementPoolId, + String user) { + EntitlementPoolEntity epInput = new EntitlementPoolEntity(); + epInput.setVendorLicenseModelId(vlmId); + epInput.setVersion(Version.valueOf(version)); + epInput.setId(entitlementPoolId); + EntitlementPoolEntity entitlementPool = vendorLicenseManager.getEntitlementPool(epInput, user); + + EntitlementPoolEntityDto entitlementPoolEntityDto = entitlementPool == null ? null : + new MapEntitlementPoolEntityToEntitlementPoolEntityDto() + .applyMapping(entitlementPool, EntitlementPoolEntityDto.class); + return Response.ok(entitlementPoolEntityDto).build(); + } + + /** + * Delete entitlement pool response. + * + * @param vlmId the vlm id + * @param entitlementPoolId the entitlement pool id + * @param user the user + * @return the response + */ + public Response deleteEntitlementPool(String vlmId, String entitlementPoolId, String user) { + EntitlementPoolEntity epInput = new EntitlementPoolEntity(); + epInput.setVendorLicenseModelId(vlmId); + epInput.setId(entitlementPoolId); + vendorLicenseManager.deleteEntitlementPool(epInput, user); + return Response.ok().build(); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/services/FeatureGroupsImpl.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/services/FeatureGroupsImpl.java new file mode 100644 index 0000000000..daf35f9ee6 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/services/FeatureGroupsImpl.java @@ -0,0 +1,169 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.rest.services; + +import org.openecomp.core.utilities.CommonMethods; +import org.openecomp.sdc.vendorlicense.VendorLicenseManager; +import org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity; +import org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity; +import org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupModel; +import org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyGroupEntity; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdcrests.vendorlicense.rest.FeatureGroups; +import org.openecomp.sdcrests.vendorlicense.rest.mapping.MapEntitlementPoolEntityToEntitlementPoolEntityDto; +import org.openecomp.sdcrests.vendorlicense.rest.mapping.MapFeatureGroupDescriptorDtoToFeatureGroupEntity; +import org.openecomp.sdcrests.vendorlicense.rest.mapping.MapFeatureGroupEntityToFeatureGroupDescriptorDto; +import org.openecomp.sdcrests.vendorlicense.rest.mapping.MapLicenseKeyGroupEntityToLicenseKeyGroupEntityDto; +import org.openecomp.sdcrests.vendorlicense.types.EntitlementPoolEntityDto; +import org.openecomp.sdcrests.vendorlicense.types.FeatureGroupEntityDto; +import org.openecomp.sdcrests.vendorlicense.types.FeatureGroupModelDto; +import org.openecomp.sdcrests.vendorlicense.types.FeatureGroupRequestDto; +import org.openecomp.sdcrests.vendorlicense.types.FeatureGroupUpdateRequestDto; +import org.openecomp.sdcrests.vendorlicense.types.LicenseKeyGroupEntityDto; +import org.openecomp.sdcrests.wrappers.GenericCollectionWrapper; +import org.openecomp.sdcrests.wrappers.StringWrapperResponse; + +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.context.annotation.Scope; +import org.springframework.stereotype.Service; + +import java.util.Collection; +import java.util.HashSet; +import javax.inject.Named; +import javax.ws.rs.core.Response; + + +@Named +@Service("featureGroups") +@Scope(value = "prototype") +public class FeatureGroupsImpl implements FeatureGroups { + + @Autowired + private VendorLicenseManager vendorLicenseManager; + + @Override + public Response listFeatureGroups(String vlmId, String version, String user) { + Collection featureGroupEntities = + vendorLicenseManager.listFeatureGroups(vlmId, Version.valueOf(version), user); + + MapFeatureGroupEntityToFeatureGroupDescriptorDto outputMapper = + new MapFeatureGroupEntityToFeatureGroupDescriptorDto(); + GenericCollectionWrapper results = new GenericCollectionWrapper<>(); + + for (FeatureGroupEntity fg : featureGroupEntities) { + FeatureGroupEntityDto fgDto = new FeatureGroupEntityDto(); + fgDto.setId(fg.getId()); + fgDto.setLicenseKeyGroupsIds(fg.getLicenseKeyGroupIds()); + fgDto.setEntitlementPoolsIds(fg.getEntitlementPoolIds()); + fgDto.setReferencingLicenseAgreements(fg.getReferencingLicenseAgreements()); + outputMapper.doMapping(fg, fgDto); + results.add(fgDto); + } + + return Response.ok(results).build(); + } + + @Override + public Response createFeatureGroup(FeatureGroupRequestDto request, String vlmId, String user) { + FeatureGroupEntity featureGroupEntity = new MapFeatureGroupDescriptorDtoToFeatureGroupEntity() + .applyMapping(request, FeatureGroupEntity.class); + featureGroupEntity.setVendorLicenseModelId(vlmId); + featureGroupEntity.setLicenseKeyGroupIds(request.getAddedLicenseKeyGroupsIds()); + featureGroupEntity.setEntitlementPoolIds(request.getAddedEntitlementPoolsIds()); + + FeatureGroupEntity createdFeatureGroup = + vendorLicenseManager.createFeatureGroup(featureGroupEntity, user); + + StringWrapperResponse result = + createdFeatureGroup != null ? new StringWrapperResponse(createdFeatureGroup.getId()) : null; + return Response.ok(result).build(); + } + + @Override + public Response updateFeatureGroup(FeatureGroupUpdateRequestDto request, String vlmId, + String featureGroupId, String user) { + FeatureGroupEntity featureGroupEntity = new MapFeatureGroupDescriptorDtoToFeatureGroupEntity() + .applyMapping(request, FeatureGroupEntity.class); + featureGroupEntity.setVendorLicenseModelId(vlmId); + featureGroupEntity.setId(featureGroupId); + + vendorLicenseManager + .updateFeatureGroup(featureGroupEntity, request.getAddedLicenseKeyGroupsIds(), + request.getRemovedLicenseKeyGroupsIds(), request.getAddedEntitlementPoolsIds(), + request.getRemovedEntitlementPoolsIds(), user); + return Response.ok().build(); + } + + @Override + public Response getFeatureGroup(String vlmId, String version, String featureGroupId, + String user) { + FeatureGroupEntity fgInput = new FeatureGroupEntity(); + fgInput.setVendorLicenseModelId(vlmId); + fgInput.setVersion(Version.valueOf(version)); + fgInput.setId(featureGroupId); + FeatureGroupModel featureGroupModel = vendorLicenseManager.getFeatureGroupModel(fgInput, user); + + if (featureGroupModel == null) { + return Response.ok().build(); + } + + FeatureGroupModelDto fgmDto = new FeatureGroupModelDto(); + fgmDto.setId(featureGroupModel.getFeatureGroup().getId()); + fgmDto.setReferencingLicenseAgreements( + featureGroupModel.getFeatureGroup().getReferencingLicenseAgreements()); + new MapFeatureGroupEntityToFeatureGroupDescriptorDto() + .doMapping(featureGroupModel.getFeatureGroup(), fgmDto); + + if (!CommonMethods.isEmpty(featureGroupModel.getLicenseKeyGroups())) { + fgmDto.setLicenseKeyGroups(new HashSet<>()); + + MapLicenseKeyGroupEntityToLicenseKeyGroupEntityDto lkgMapper = + new MapLicenseKeyGroupEntityToLicenseKeyGroupEntityDto(); + for (LicenseKeyGroupEntity lkg : featureGroupModel.getLicenseKeyGroups()) { + fgmDto.getLicenseKeyGroups() + .add(lkgMapper.applyMapping(lkg, LicenseKeyGroupEntityDto.class)); + } + } + + if (!CommonMethods.isEmpty(featureGroupModel.getEntitlementPools())) { + fgmDto.setEntitlementPools(new HashSet<>()); + + MapEntitlementPoolEntityToEntitlementPoolEntityDto epMapper = + new MapEntitlementPoolEntityToEntitlementPoolEntityDto(); + for (EntitlementPoolEntity ep : featureGroupModel.getEntitlementPools()) { + fgmDto.getEntitlementPools().add(epMapper.applyMapping(ep, EntitlementPoolEntityDto.class)); + + } + } + + return Response.ok(fgmDto).build(); + } + + @Override + public Response deleteFeatureGroup(String vlmId, String featureGroupId, String user) { + FeatureGroupEntity fgInput = new FeatureGroupEntity(); + fgInput.setVendorLicenseModelId(vlmId); + fgInput.setId(featureGroupId); + vendorLicenseManager.deleteFeatureGroup(fgInput, user); + return Response.ok().build(); + } + +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/services/LicenseAgreementsImpl.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/services/LicenseAgreementsImpl.java new file mode 100644 index 0000000000..d87be05998 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/services/LicenseAgreementsImpl.java @@ -0,0 +1,186 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.rest.services; + +import org.openecomp.core.utilities.CommonMethods; +import org.openecomp.sdc.vendorlicense.VendorLicenseManager; +import org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity; +import org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementEntity; +import org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementModel; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdcrests.vendorlicense.rest.LicenseAgreements; +import org.openecomp.sdcrests.vendorlicense.rest.mapping.MapFeatureGroupEntityToFeatureGroupDescriptorDto; +import org.openecomp.sdcrests.vendorlicense.rest.mapping.MapLicenseAgreementDescriptorDtoToLicenseAgreementEntity; +import org.openecomp.sdcrests.vendorlicense.rest.mapping.MapLicenseAgreementEntityToLicenseAgreementDescriptorDto; +import org.openecomp.sdcrests.vendorlicense.types.FeatureGroupEntityDto; +import org.openecomp.sdcrests.vendorlicense.types.LicenseAgreementEntityDto; +import org.openecomp.sdcrests.vendorlicense.types.LicenseAgreementModelDto; +import org.openecomp.sdcrests.vendorlicense.types.LicenseAgreementRequestDto; +import org.openecomp.sdcrests.vendorlicense.types.LicenseAgreementUpdateRequestDto; +import org.openecomp.sdcrests.wrappers.GenericCollectionWrapper; +import org.openecomp.sdcrests.wrappers.StringWrapperResponse; + +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.context.annotation.Scope; +import org.springframework.stereotype.Service; + +import java.util.Collection; +import java.util.HashSet; +import javax.inject.Named; +import javax.ws.rs.core.Response; + +@Named +@Service("licenseAgreements") +@Scope(value = "prototype") +public class LicenseAgreementsImpl implements LicenseAgreements { + + @Autowired + private VendorLicenseManager vendorLicenseManager; + + /** + * List license agreements response. + * + * @param vlmId the vlm id + * @param version the version + * @param user the user + * @return the response + */ + public Response listLicenseAgreements(String vlmId, String version, String user) { + Collection licenseAgreements = + vendorLicenseManager.listLicenseAgreements(vlmId, Version.valueOf(version), user); + + GenericCollectionWrapper results = new GenericCollectionWrapper<>(); + MapLicenseAgreementEntityToLicenseAgreementDescriptorDto outputMapper = + new MapLicenseAgreementEntityToLicenseAgreementDescriptorDto(); + for (LicenseAgreementEntity lae : licenseAgreements) { + LicenseAgreementEntityDto laeDto = new LicenseAgreementEntityDto(); + laeDto.setId(lae.getId()); + laeDto.setFeatureGroupsIds(lae.getFeatureGroupIds()); + outputMapper.doMapping(lae, laeDto); + results.add(laeDto); + } + + return Response.ok(results).build(); + } + + /** + * Create license agreement response. + * + * @param request the request + * @param vlmId the vlm id + * @param user the user + * @return the response + */ + public Response createLicenseAgreement(LicenseAgreementRequestDto request, String vlmId, + String user) { + LicenseAgreementEntity licenseAgreementEntity = + new MapLicenseAgreementDescriptorDtoToLicenseAgreementEntity() + .applyMapping(request, LicenseAgreementEntity.class); + licenseAgreementEntity.setVendorLicenseModelId(vlmId); + licenseAgreementEntity.setFeatureGroupIds(request.getAddedFeatureGroupsIds()); + + LicenseAgreementEntity createdLicenseAgreement = + vendorLicenseManager.createLicenseAgreement(licenseAgreementEntity, user); + StringWrapperResponse result = + createdLicenseAgreement != null ? new StringWrapperResponse(createdLicenseAgreement.getId()) + : null; + + return Response.ok(result).build(); + } + + /** + * Update license agreement response. + * + * @param request the request + * @param vlmId the vlm id + * @param licenseAgreementId the license agreement id + * @param user the user + * @return the response + */ + public Response updateLicenseAgreement(LicenseAgreementUpdateRequestDto request, String vlmId, + String licenseAgreementId, String user) { + LicenseAgreementEntity licenseAgreementEntity = + new MapLicenseAgreementDescriptorDtoToLicenseAgreementEntity() + .applyMapping(request, LicenseAgreementEntity.class); + licenseAgreementEntity.setVendorLicenseModelId(vlmId); + licenseAgreementEntity.setId(licenseAgreementId); + + vendorLicenseManager + .updateLicenseAgreement(licenseAgreementEntity, request.getAddedFeatureGroupsIds(), + request.getRemovedFeatureGroupsIds(), user); + return Response.ok().build(); + } + + /** + * Gets license agreement. + * + * @param vlmId the vlm id + * @param version the version + * @param licenseAgreementId the license agreement id + * @param user the user + * @return the license agreement + */ + public Response getLicenseAgreement(String vlmId, String version, String licenseAgreementId, + String user) { + LicenseAgreementModel licenseAgreementModel = vendorLicenseManager + .getLicenseAgreementModel(vlmId, Version.valueOf(version), licenseAgreementId, user); + + if (licenseAgreementModel == null) { + return Response.ok().build(); + } + + LicenseAgreementModelDto lamDto = new LicenseAgreementModelDto(); + lamDto.setId(licenseAgreementModel.getLicenseAgreement().getId()); + new MapLicenseAgreementEntityToLicenseAgreementDescriptorDto() + .doMapping(licenseAgreementModel.getLicenseAgreement(), lamDto); + + if (!CommonMethods.isEmpty(licenseAgreementModel.getFeatureGroups())) { + lamDto.setFeatureGroups(new HashSet<>()); + + MapFeatureGroupEntityToFeatureGroupDescriptorDto fgMapper = + new MapFeatureGroupEntityToFeatureGroupDescriptorDto(); + for (FeatureGroupEntity fg : licenseAgreementModel.getFeatureGroups()) { + FeatureGroupEntityDto fgeDto = new FeatureGroupEntityDto(); + fgeDto.setId(fg.getId()); + fgeDto.setEntitlementPoolsIds(fg.getEntitlementPoolIds()); + fgeDto.setLicenseKeyGroupsIds(fg.getLicenseKeyGroupIds()); + fgMapper.doMapping(fg, fgeDto); + + lamDto.getFeatureGroups().add(fgeDto); + } + } + + return Response.ok(lamDto).build(); + } + + /** + * Delete license agreement response. + * + * @param vlmId the vlm id + * @param licenseAgreementId the license agreement id + * @param user the user + * @return the response + */ + public Response deleteLicenseAgreement(String vlmId, String licenseAgreementId, String user) { + vendorLicenseManager.deleteLicenseAgreement(vlmId, licenseAgreementId, user); + return Response.ok().build(); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/services/LicenseKeyGroupsImpl.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/services/LicenseKeyGroupsImpl.java new file mode 100644 index 0000000000..6ef7e194b8 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/services/LicenseKeyGroupsImpl.java @@ -0,0 +1,159 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.rest.services; + +import org.openecomp.sdc.vendorlicense.VendorLicenseManager; +import org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyGroupEntity; +import org.openecomp.sdc.versioning.dao.types.Version; + +import org.openecomp.sdcrests.vendorlicense.rest.LicenseKeyGroups; +import org.openecomp.sdcrests.vendorlicense.rest.mapping.MapLicenseKeyGroupEntityToLicenseKeyGroupEntityDto; +import org.openecomp.sdcrests.vendorlicense.rest.mapping.MapLicenseKeyGroupRequestDtoToLicenseKeyGroupEntity; +import org.openecomp.sdcrests.vendorlicense.types.LicenseKeyGroupEntityDto; +import org.openecomp.sdcrests.vendorlicense.types.LicenseKeyGroupRequestDto; +import org.openecomp.sdcrests.wrappers.GenericCollectionWrapper; +import org.openecomp.sdcrests.wrappers.StringWrapperResponse; + +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.context.annotation.Scope; +import org.springframework.stereotype.Service; +import org.springframework.validation.annotation.Validated; + +import java.util.Collection; +import javax.inject.Named; +import javax.ws.rs.core.Response; + +@Named +@Service("licenseKeyGroups") +@Scope(value = "prototype") +@Validated +public class LicenseKeyGroupsImpl implements LicenseKeyGroups { + + @Autowired + private VendorLicenseManager vendorLicenseManager; + + /** + * List license key groups response. + * + * @param vlmId the vlm id + * @param version the version + * @param user the user + * @return the response + */ + public Response listLicenseKeyGroups(String vlmId, String version, String user) { + Collection licenseKeyGroups = + vendorLicenseManager.listLicenseKeyGroups(vlmId, Version.valueOf(version), user); + + GenericCollectionWrapper result = new GenericCollectionWrapper<>(); + MapLicenseKeyGroupEntityToLicenseKeyGroupEntityDto outputMapper = + new MapLicenseKeyGroupEntityToLicenseKeyGroupEntityDto(); + for (LicenseKeyGroupEntity ep : licenseKeyGroups) { + result.add(outputMapper.applyMapping(ep, LicenseKeyGroupEntityDto.class)); + } + + return Response.ok(result).build(); + } + + /** + * Create license key group response. + * + * @param request the request + * @param vlmId the vlm id + * @param user the user + * @return the response + */ + public Response createLicenseKeyGroup(LicenseKeyGroupRequestDto request, String vlmId, + String user) { + LicenseKeyGroupEntity licenseKeyGroupEntity = + new MapLicenseKeyGroupRequestDtoToLicenseKeyGroupEntity() + .applyMapping(request, LicenseKeyGroupEntity.class); + licenseKeyGroupEntity.setVendorLicenseModelId(vlmId); + + LicenseKeyGroupEntity createdLicenseKeyGroup = + vendorLicenseManager.createLicenseKeyGroup(licenseKeyGroupEntity, user); + StringWrapperResponse result = + createdLicenseKeyGroup != null ? new StringWrapperResponse(createdLicenseKeyGroup.getId()) + : null; + + return Response.ok(result).build(); + } + + /** + * Update license key group response. + * + * @param request the request + * @param vlmId the vlm id + * @param licenseKeyGroupId the license key group id + * @param user the user + * @return the response + */ + public Response updateLicenseKeyGroup(LicenseKeyGroupRequestDto request, String vlmId, + String licenseKeyGroupId, String user) { + LicenseKeyGroupEntity licenseKeyGroupEntity = + new MapLicenseKeyGroupRequestDtoToLicenseKeyGroupEntity() + .applyMapping(request, LicenseKeyGroupEntity.class); + + licenseKeyGroupEntity.setVendorLicenseModelId(vlmId); + licenseKeyGroupEntity.setId(licenseKeyGroupId); + + vendorLicenseManager.updateLicenseKeyGroup(licenseKeyGroupEntity, user); + return Response.ok().build(); + } + + /** + * Gets license key group. + * + * @param vlmId the vlm id + * @param version the version + * @param licenseKeyGroupId the license key group id + * @param user the user + * @return the license key group + */ + public Response getLicenseKeyGroup(String vlmId, String version, String licenseKeyGroupId, + String user) { + LicenseKeyGroupEntity lkgInput = new LicenseKeyGroupEntity(); + lkgInput.setVendorLicenseModelId(vlmId); + lkgInput.setVersion(Version.valueOf(version)); + lkgInput.setId(licenseKeyGroupId); + LicenseKeyGroupEntity licenseKeyGroup = vendorLicenseManager.getLicenseKeyGroup(lkgInput, user); + + LicenseKeyGroupEntityDto licenseKeyGroupEntityDto = licenseKeyGroup == null ? null : + new MapLicenseKeyGroupEntityToLicenseKeyGroupEntityDto() + .applyMapping(licenseKeyGroup, LicenseKeyGroupEntityDto.class); + return Response.ok(licenseKeyGroupEntityDto).build(); + } + + /** + * Delete license key group response. + * + * @param vlmId the vlm id + * @param licenseKeyGroupId the license key group id + * @param user the user + * @return the response + */ + public Response deleteLicenseKeyGroup(String vlmId, String licenseKeyGroupId, String user) { + LicenseKeyGroupEntity lkgInput = new LicenseKeyGroupEntity(); + lkgInput.setVendorLicenseModelId(vlmId); + lkgInput.setId(licenseKeyGroupId); + vendorLicenseManager.deleteLicenseKeyGroup(lkgInput, user); + return Response.ok().build(); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/services/VendorLicenseModelsImpl.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/services/VendorLicenseModelsImpl.java new file mode 100644 index 0000000000..c63da86e7a --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-services/src/main/java/org/openecomp/sdcrests/vendorlicense/rest/services/VendorLicenseModelsImpl.java @@ -0,0 +1,135 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.rest.services; + +import org.openecomp.sdc.vendorlicense.VendorLicenseManager; +import org.openecomp.sdc.vendorlicense.dao.types.VendorLicenseModelEntity; +import org.openecomp.sdc.vendorlicense.types.VersionedVendorLicenseModel; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdcrests.vendorlicense.rest.VendorLicenseModels; +import org.openecomp.sdcrests.vendorlicense.rest.mapping.MapVendorLicenseModelRequestDtoToVendorLicenseModelEntity; +import org.openecomp.sdcrests.vendorlicense.rest.mapping.MapVersionedVendorLicenseModelToVendorLicenseModelEntityDto; +import org.openecomp.sdcrests.vendorlicense.types.VendorLicenseModelActionRequestDto; +import org.openecomp.sdcrests.vendorlicense.types.VendorLicenseModelEntityDto; +import org.openecomp.sdcrests.vendorlicense.types.VendorLicenseModelRequestDto; +import org.openecomp.sdcrests.wrappers.GenericCollectionWrapper; +import org.openecomp.sdcrests.wrappers.StringWrapperResponse; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.context.annotation.Scope; +import org.springframework.stereotype.Service; +import org.springframework.validation.annotation.Validated; + +import java.util.Collection; +import javax.inject.Named; +import javax.ws.rs.core.Response; + + + +@Named +@Service("vendorLicenseModels") +@Scope(value = "prototype") +@Validated +public class VendorLicenseModelsImpl implements VendorLicenseModels { + + @Autowired + private VendorLicenseManager vendorLicenseManager; + + @Override + public Response listLicenseModels(String versionFilter, String user) { + Collection versionedVendorLicenseModels = + vendorLicenseManager.listVendorLicenseModels(versionFilter, user); + + GenericCollectionWrapper results = + new GenericCollectionWrapper<>(); + MapVersionedVendorLicenseModelToVendorLicenseModelEntityDto outputMapper = + new MapVersionedVendorLicenseModelToVendorLicenseModelEntityDto(); + for (VersionedVendorLicenseModel versionedVlm : versionedVendorLicenseModels) { + results.add(outputMapper.applyMapping(versionedVlm, VendorLicenseModelEntityDto.class)); + } + + return Response.ok(results).build(); + } + + @Override + public Response createLicenseModel(VendorLicenseModelRequestDto request, String user) { + VendorLicenseModelEntity vendorLicenseModelEntity = + new MapVendorLicenseModelRequestDtoToVendorLicenseModelEntity() + .applyMapping(request, VendorLicenseModelEntity.class); + VendorLicenseModelEntity createdVendorLicenseModel = + vendorLicenseManager.createVendorLicenseModel(vendorLicenseModelEntity, user); + StringWrapperResponse result = createdVendorLicenseModel != null ? new StringWrapperResponse( + createdVendorLicenseModel.getId()) : null; + + return Response.ok(result).build(); + } + + @Override + public Response updateLicenseModel(VendorLicenseModelRequestDto request, String vlmId, + String user) { + VendorLicenseModelEntity vendorLicenseModelEntity = + new MapVendorLicenseModelRequestDtoToVendorLicenseModelEntity() + .applyMapping(request, VendorLicenseModelEntity.class); + vendorLicenseModelEntity.setId(vlmId); + + vendorLicenseManager.updateVendorLicenseModel(vendorLicenseModelEntity, user); + return Response.ok().build(); + } + + @Override + public Response getLicenseModel(String vlmId, String version, String user) { + VersionedVendorLicenseModel versionedVlm = + vendorLicenseManager.getVendorLicenseModel(vlmId, Version.valueOf(version), user); + + VendorLicenseModelEntityDto vlmDto = versionedVlm == null ? null : + new MapVersionedVendorLicenseModelToVendorLicenseModelEntityDto() + .applyMapping(versionedVlm, VendorLicenseModelEntityDto.class); + return Response.ok(vlmDto).build(); + } + + @Override + public Response deleteLicenseModel(String vlmId, String user) { + vendorLicenseManager.deleteVendorLicenseModel(vlmId, user); + return Response.ok().build(); + } + + @Override + public Response actOnLicenseModel(VendorLicenseModelActionRequestDto request, String vlmId, + String user) { + + switch (request.getAction()) { + case Checkout: + vendorLicenseManager.checkout(vlmId, user); + break; + case Undo_Checkout: + vendorLicenseManager.undoCheckout(vlmId, user); + break; + case Checkin: + vendorLicenseManager.checkin(vlmId, user); + break; + case Submit: + vendorLicenseManager.submit(vlmId, user); + break; + default: + } + + return Response.ok().build(); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/pom.xml b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/pom.xml new file mode 100644 index 0000000000..1b0319dcf3 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/pom.xml @@ -0,0 +1,30 @@ + + 4.0.0 + + + org.openecomp.sdc.onboarding + vendor-license-rest + 1.0.0-SNAPSHOT + ../ + + + vendor-license-rest-types + vendor-license-rest-types + + + + + + org.openecomp.sdc + openecomp-sdc-common-rest + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-vendor-license-manager + ${project.version} + + + + \ No newline at end of file diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/ChoiceOrOtherDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/ChoiceOrOtherDto.java new file mode 100644 index 0000000000..ba8f57f79f --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/ChoiceOrOtherDto.java @@ -0,0 +1,75 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.types; + +import org.hibernate.validator.group.GroupSequenceProvider; +import org.openecomp.sdcrests.vendorlicense.types.validation.ChoiceOrOtherSequenceProvider; +import org.openecomp.sdcrests.vendorlicense.types.validation.OtherChoiceValidation; + +import javax.validation.constraints.NotNull; + +@GroupSequenceProvider(value = ChoiceOrOtherSequenceProvider.class) +public class ChoiceOrOtherDto> { + @NotNull + private E choice; + @NotNull(message = "may not be null when choice is set to 'Other'.", + groups = OtherChoiceValidation.class) + private String other; + + public E getChoice() { + return choice; + } + + public void setChoice(E choice) { + this.choice = choice; + } + + public String getOther() { + return other; + } + + public void setOther(String other) { + this.other = other; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (obj == null || getClass() != obj.getClass()) { + return false; + } + + ChoiceOrOtherDto that = (ChoiceOrOtherDto) obj; + + return choice != null ? choice.equals(that.choice) + : that.choice == null && (other != null ? other.equals(that.other) : that.other == null); + + } + + @Override + public int hashCode() { + int result = choice != null ? choice.hashCode() : 0; + result = 31 * result + (other != null ? other.hashCode() : 0); + return result; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/EntitlementPoolEntityDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/EntitlementPoolEntityDto.java new file mode 100644 index 0000000000..5ed40b00b7 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/EntitlementPoolEntityDto.java @@ -0,0 +1,48 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.types; + + +import io.swagger.annotations.ApiModel; + +import java.util.Set; + +@ApiModel(value = "EntitlementPoolEntity") +public class EntitlementPoolEntityDto extends EntitlementPoolRequestDto { + private String id; + private Set referencingFeatureGroups; + + public String getId() { + return id; + } + + public void setId(String id) { + this.id = id; + } + + public Set getReferencingFeatureGroups() { + return referencingFeatureGroups; + } + + public void setReferencingFeatureGroups(Set referencingFeatureGroups) { + this.referencingFeatureGroups = referencingFeatureGroups; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/EntitlementPoolRequestDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/EntitlementPoolRequestDto.java new file mode 100644 index 0000000000..b70504e20e --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/EntitlementPoolRequestDto.java @@ -0,0 +1,144 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.types; + +import io.swagger.annotations.ApiModel; +import org.openecomp.sdc.vendorlicense.dao.types.AggregationFunction; +import org.openecomp.sdc.vendorlicense.dao.types.EntitlementMetric; +import org.openecomp.sdc.vendorlicense.dao.types.EntitlementTime; +import org.openecomp.sdc.vendorlicense.dao.types.OperationalScope; +import org.openecomp.sdc.vendorlicense.dao.types.ThresholdUnit; + +import javax.validation.Valid; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; + +@ApiModel(value = "EntitlementPoolRequest") +public class EntitlementPoolRequestDto { + + @NotNull + @Size(max = 120) + private String name; + @NotNull + @Size(max = 1000) + private String description; + @NotNull + private int thresholdValue; + @NotNull + private ThresholdUnit thresholdUnits; + @NotNull + @Valid + private ChoiceOrOtherDto entitlementMetric; + @Size(max = 120) + private String increments; + @NotNull + @Valid + private ChoiceOrOtherDto aggregationFunction; + @NotNull + @Valid + private MultiChoiceOrOtherDto operationalScope; + @NotNull + @Valid + private ChoiceOrOtherDto time; + @NotNull + @Size(max = 100) + private String manufacturerReferenceNumber; + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public int getThresholdValue() { + return thresholdValue; + } + + public void setThresholdValue(int thresholdValue) { + this.thresholdValue = thresholdValue; + } + + public ThresholdUnit getThresholdUnits() { + return thresholdUnits; + } + + public void setThresholdUnits(ThresholdUnit thresholdUnits) { + this.thresholdUnits = thresholdUnits; + } + + public ChoiceOrOtherDto getEntitlementMetric() { + return entitlementMetric; + } + + public void setEntitlementMetric(ChoiceOrOtherDto entitlementMetric) { + this.entitlementMetric = entitlementMetric; + } + + public String getIncrements() { + return increments; + } + + public void setIncrements(String increments) { + this.increments = increments; + } + + public ChoiceOrOtherDto getAggregationFunction() { + return aggregationFunction; + } + + public void setAggregationFunction(ChoiceOrOtherDto aggregationFunction) { + this.aggregationFunction = aggregationFunction; + } + + public MultiChoiceOrOtherDto getOperationalScope() { + return operationalScope; + } + + public void setOperationalScope(MultiChoiceOrOtherDto operationalScope) { + this.operationalScope = operationalScope; + } + + public ChoiceOrOtherDto getTime() { + return time; + } + + public void setTime(ChoiceOrOtherDto time) { + this.time = time; + } + + public String getManufacturerReferenceNumber() { + return manufacturerReferenceNumber; + } + + public void setManufacturerReferenceNumber(String manufacturerReferenceNumber) { + this.manufacturerReferenceNumber = manufacturerReferenceNumber; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/FeatureGroupDescriptorDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/FeatureGroupDescriptorDto.java new file mode 100644 index 0000000000..5c1f8f2cfc --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/FeatureGroupDescriptorDto.java @@ -0,0 +1,59 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.types; + +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; + +public class FeatureGroupDescriptorDto { + @NotNull + @Size(max = 120) + private String name; + @NotNull + @Size(max = 1000) + private String description; + @NotNull + private String partNumber; + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public String getPartNumber() { + return partNumber; + } + + public void setPartNumber(String partNumber) { + this.partNumber = partNumber; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/FeatureGroupEntityDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/FeatureGroupEntityDto.java new file mode 100644 index 0000000000..a1d1edddcf --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/FeatureGroupEntityDto.java @@ -0,0 +1,69 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.types; + +import io.swagger.annotations.ApiModel; + +import java.util.Set; + +import javax.validation.constraints.Size; + + +@ApiModel(value = "FeatureGroupEntity") +public class FeatureGroupEntityDto extends FeatureGroupDescriptorDto { + private String id; + private Set licenseKeyGroupsIds; + @Size(min = 1) + private Set entitlementPoolsIds; + private Set referencingLicenseAgreements; + + public String getId() { + return id; + } + + public void setId(String id) { + this.id = id; + } + + public Set getLicenseKeyGroupsIds() { + return licenseKeyGroupsIds; + } + + public void setLicenseKeyGroupsIds(Set licenseKeyGroupsIds) { + this.licenseKeyGroupsIds = licenseKeyGroupsIds; + } + + public Set getEntitlementPoolsIds() { + return entitlementPoolsIds; + } + + public void setEntitlementPoolsIds(Set entitlementPoolsIds) { + this.entitlementPoolsIds = entitlementPoolsIds; + } + + public Set getReferencingLicenseAgreements() { + return referencingLicenseAgreements; + } + + public void setReferencingLicenseAgreements(Set referencingLicenseAgreements) { + this.referencingLicenseAgreements = referencingLicenseAgreements; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/FeatureGroupModelDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/FeatureGroupModelDto.java new file mode 100644 index 0000000000..1572320bb1 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/FeatureGroupModelDto.java @@ -0,0 +1,66 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.types; + +import io.swagger.annotations.ApiModel; + +import java.util.Collection; +import java.util.Set; + +@ApiModel(value = "FeatureGroupModel") +public class FeatureGroupModelDto extends FeatureGroupDescriptorDto { + private String id; + private Set referencingLicenseAgreements; + private Collection licenseKeyGroups; + private Collection entitlementPools; + + public String getId() { + return id; + } + + public void setId(String id) { + this.id = id; + } + + public Set getReferencingLicenseAgreements() { + return referencingLicenseAgreements; + } + + public void setReferencingLicenseAgreements(Set referencingLicenseAgreements) { + this.referencingLicenseAgreements = referencingLicenseAgreements; + } + + public Collection getLicenseKeyGroups() { + return licenseKeyGroups; + } + + public void setLicenseKeyGroups(Collection licenseKeyGroups) { + this.licenseKeyGroups = licenseKeyGroups; + } + + public Collection getEntitlementPools() { + return entitlementPools; + } + + public void setEntitlementPools(Collection entitlementPools) { + this.entitlementPools = entitlementPools; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/FeatureGroupRequestDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/FeatureGroupRequestDto.java new file mode 100644 index 0000000000..282e797f1b --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/FeatureGroupRequestDto.java @@ -0,0 +1,48 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.types; + +import io.swagger.annotations.ApiModel; + +import java.util.Set; + +@ApiModel(value = "FeatureGroupRequest") +public class FeatureGroupRequestDto extends FeatureGroupDescriptorDto { + + private Set addedLicenseKeyGroupsIds; + private Set addedEntitlementPoolsIds; + + public Set getAddedLicenseKeyGroupsIds() { + return addedLicenseKeyGroupsIds; + } + + public void setAddedLicenseKeyGroupsIds(Set addedLicenseKeyGroupsIds) { + this.addedLicenseKeyGroupsIds = addedLicenseKeyGroupsIds; + } + + public Set getAddedEntitlementPoolsIds() { + return addedEntitlementPoolsIds; + } + + public void setAddedEntitlementPoolsIds(Set addedEntitlementPoolsIds) { + this.addedEntitlementPoolsIds = addedEntitlementPoolsIds; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/FeatureGroupUpdateRequestDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/FeatureGroupUpdateRequestDto.java new file mode 100644 index 0000000000..002e48bb2c --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/FeatureGroupUpdateRequestDto.java @@ -0,0 +1,48 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.types; + +import io.swagger.annotations.ApiModel; + +import java.util.Set; + +@ApiModel(value = "FeatureGroupUpdateRequest") +public class FeatureGroupUpdateRequestDto extends FeatureGroupRequestDto { + + private Set removedLicenseKeyGroupsIds; + private Set removedEntitlementPoolsIds; + + public Set getRemovedLicenseKeyGroupsIds() { + return removedLicenseKeyGroupsIds; + } + + public void setRemovedLicenseKeyGroupsIds(Set removedLicenseKeyGroupsIds) { + this.removedLicenseKeyGroupsIds = removedLicenseKeyGroupsIds; + } + + public Set getRemovedEntitlementPoolsIds() { + return removedEntitlementPoolsIds; + } + + public void setRemovedEntitlementPoolsIds(Set removedEntitlementPoolsIds) { + this.removedEntitlementPoolsIds = removedEntitlementPoolsIds; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/LicenseAgreementDescriptorDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/LicenseAgreementDescriptorDto.java new file mode 100644 index 0000000000..acfc130ed1 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/LicenseAgreementDescriptorDto.java @@ -0,0 +1,74 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.types; + +import org.openecomp.sdc.vendorlicense.dao.types.LicenseTerm; + +import javax.validation.Valid; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; + +public class LicenseAgreementDescriptorDto { + + @NotNull + @Size(max = 120) + private String name; + @NotNull + @Size(max = 1000) + private String description; + @NotNull + @Valid + private ChoiceOrOtherDto licenseTerm; + @Size(max = 1000) + private String requirementsAndConstrains; + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public ChoiceOrOtherDto getLicenseTerm() { + return licenseTerm; + } + + public void setLicenseTerm(ChoiceOrOtherDto licenseTerm) { + this.licenseTerm = licenseTerm; + } + + public String getRequirementsAndConstrains() { + return requirementsAndConstrains; + } + + public void setRequirementsAndConstrains(String requirementsAndConstrains) { + this.requirementsAndConstrains = requirementsAndConstrains; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/LicenseAgreementEntityDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/LicenseAgreementEntityDto.java new file mode 100644 index 0000000000..b0a8f65995 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/LicenseAgreementEntityDto.java @@ -0,0 +1,51 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.types; + + +import io.swagger.annotations.ApiModel; + +import java.util.Set; +import javax.validation.constraints.Size; + + +@ApiModel(value = "LicenseAgreementEntity") +public class LicenseAgreementEntityDto extends LicenseAgreementDescriptorDto { + private String id; + @Size(min = 1) + private Set featureGroupsIds; + + public String getId() { + return id; + } + + public void setId(String id) { + this.id = id; + } + + public Set getFeatureGroupsIds() { + return featureGroupsIds; + } + + public void setFeatureGroupsIds(Set featureGroupsIds) { + this.featureGroupsIds = featureGroupsIds; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/LicenseAgreementModelDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/LicenseAgreementModelDto.java new file mode 100644 index 0000000000..a3460c321f --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/LicenseAgreementModelDto.java @@ -0,0 +1,47 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.types; + +import io.swagger.annotations.ApiModel; + +import java.util.Set; + +@ApiModel(value = "LicenseAgreementModel") +public class LicenseAgreementModelDto extends LicenseAgreementDescriptorDto { + private String id; + private Set featureGroups; + + public String getId() { + return id; + } + + public void setId(String id) { + this.id = id; + } + + public Set getFeatureGroups() { + return featureGroups; + } + + public void setFeatureGroups(Set featureGroups) { + this.featureGroups = featureGroups; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/LicenseAgreementRequestDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/LicenseAgreementRequestDto.java new file mode 100644 index 0000000000..3830bdb713 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/LicenseAgreementRequestDto.java @@ -0,0 +1,39 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.types; + +import io.swagger.annotations.ApiModel; + +import java.util.Set; + +@ApiModel(value = "LicenseAgreementRequest") +public class LicenseAgreementRequestDto extends LicenseAgreementDescriptorDto { + + private Set addedFeatureGroupsIds; + + public Set getAddedFeatureGroupsIds() { + return addedFeatureGroupsIds; + } + + public void setAddedFeatureGroupsIds(Set addedFeatureGroupsIds) { + this.addedFeatureGroupsIds = addedFeatureGroupsIds; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/LicenseAgreementUpdateRequestDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/LicenseAgreementUpdateRequestDto.java new file mode 100644 index 0000000000..2590bcf519 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/LicenseAgreementUpdateRequestDto.java @@ -0,0 +1,38 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.types; + +import io.swagger.annotations.ApiModel; + +import java.util.Set; + +@ApiModel(value = "LicenseAgreementUpdateRequest") +public class LicenseAgreementUpdateRequestDto extends LicenseAgreementRequestDto { + private Set removedFeatureGroupsIds; + + public Set getRemovedFeatureGroupsIds() { + return removedFeatureGroupsIds; + } + + public void setRemovedFeatureGroupsIds(Set removedFeatureGroupsIds) { + this.removedFeatureGroupsIds = removedFeatureGroupsIds; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/LicenseKeyGroupEntityDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/LicenseKeyGroupEntityDto.java new file mode 100644 index 0000000000..9fab60fe27 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/LicenseKeyGroupEntityDto.java @@ -0,0 +1,45 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.types; + + +import java.util.Set; + +public class LicenseKeyGroupEntityDto extends LicenseKeyGroupRequestDto { + private String id; + private Set referencingFeatureGroups; + + public String getId() { + return id; + } + + public void setId(String id) { + this.id = id; + } + + public Set getReferencingFeatureGroups() { + return referencingFeatureGroups; + } + + public void setReferencingFeatureGroups(Set referencingFeatureGroups) { + this.referencingFeatureGroups = referencingFeatureGroups; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/LicenseKeyGroupRequestDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/LicenseKeyGroupRequestDto.java new file mode 100644 index 0000000000..0df2e3251f --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/LicenseKeyGroupRequestDto.java @@ -0,0 +1,74 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.types; + +import org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyType; +import org.openecomp.sdc.vendorlicense.dao.types.OperationalScope; + +import javax.validation.Valid; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; + +public class LicenseKeyGroupRequestDto { + @NotNull + @Size(max = 120) + private String name; + @NotNull + @Size(max = 1000) + private String description; + @NotNull + private LicenseKeyType type; + @NotNull + @Valid + private MultiChoiceOrOtherDto operationalScope; + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public LicenseKeyType getType() { + return type; + } + + public void setType(LicenseKeyType type) { + this.type = type; + } + + public MultiChoiceOrOtherDto getOperationalScope() { + return operationalScope; + } + + public void setOperationalScope(MultiChoiceOrOtherDto operationalScope) { + this.operationalScope = operationalScope; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/MultiChoiceOrOtherDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/MultiChoiceOrOtherDto.java new file mode 100644 index 0000000000..5a88e4c72f --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/MultiChoiceOrOtherDto.java @@ -0,0 +1,79 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.types; + +import org.hibernate.validator.group.GroupSequenceProvider; +import org.openecomp.sdcrests.vendorlicense.types.validation.MultiChoiceOrOtherSequenceProvider; +import org.openecomp.sdcrests.vendorlicense.types.validation.OtherChoiceValidation; + +import java.util.Set; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; + + +@GroupSequenceProvider(value = MultiChoiceOrOtherSequenceProvider.class) +public class MultiChoiceOrOtherDto> { + @NotNull + @Size(min = 1, message = "must contain at least 1 choice.") + private Set choices; + @NotNull(message = "may not be null when choices is set to 'Other'.", + groups = OtherChoiceValidation.class) + private String other; + + public Set getChoices() { + return choices; + } + + public void setChoices(Set choices) { + this.choices = choices; + } + + public String getOther() { + return other; + } + + public void setOther(String other) { + this.other = other; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (obj == null || getClass() != obj.getClass()) { + return false; + } + + MultiChoiceOrOtherDto that = (MultiChoiceOrOtherDto) obj; + + return choices != null ? choices.equals(that.choices) + : that.choices == null && (other != null ? other.equals(that.other) : that.other == null); + + } + + @Override + public int hashCode() { + int result = choices != null ? choices.hashCode() : 0; + result = 31 * result + (other != null ? other.hashCode() : 0); + return result; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/VendorLicenseModelActionRequestDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/VendorLicenseModelActionRequestDto.java new file mode 100644 index 0000000000..cfae94ce35 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/VendorLicenseModelActionRequestDto.java @@ -0,0 +1,36 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.types; + +import org.openecomp.sdcrests.versioning.types.VersioningAction; + +public class VendorLicenseModelActionRequestDto { + + private VersioningAction action; + + public VersioningAction getAction() { + return action; + } + + public void setAction(VersioningAction action) { + this.action = action; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/VendorLicenseModelEntityDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/VendorLicenseModelEntityDto.java new file mode 100644 index 0000000000..6c10f8fbe2 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/VendorLicenseModelEntityDto.java @@ -0,0 +1,85 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.types; + +import io.swagger.annotations.ApiModel; +import org.openecomp.sdc.versioning.dao.types.VersionStatus; + + +import java.util.List; + +@ApiModel(value = "VendorLicenseModelEntity") +public class VendorLicenseModelEntityDto extends VendorLicenseModelRequestDto { + private String id; + private String version; + private VersionStatus status; + private String lockingUser; + private List viewableVersions; + private List finalVersions; + + public String getId() { + return id; + } + + public void setId(String id) { + this.id = id; + } + + public String getVersion() { + return version; + } + + public void setVersion(String version) { + this.version = version; + } + + public VersionStatus getStatus() { + return status; + } + + public void setStatus(VersionStatus status) { + this.status = status; + } + + public String getLockingUser() { + return lockingUser; + } + + public void setLockingUser(String lockingUser) { + this.lockingUser = lockingUser; + } + + public List getViewableVersions() { + return viewableVersions; + } + + public void setViewableVersions(List viewableVersions) { + this.viewableVersions = viewableVersions; + } + + public List getFinalVersions() { + return finalVersions; + } + + public void setFinalVersions(List finalVersions) { + this.finalVersions = finalVersions; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/VendorLicenseModelRequestDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/VendorLicenseModelRequestDto.java new file mode 100644 index 0000000000..57b936a57f --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/VendorLicenseModelRequestDto.java @@ -0,0 +1,62 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.types; + +import io.swagger.annotations.ApiModel; + +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; + +@ApiModel(value = "VendorLicenseModelRequest") +public class VendorLicenseModelRequestDto { + @NotNull + @Size(max = 25) + private String vendorName; + @NotNull + @Size(max = 1000) + private String description; + @NotNull + private String iconRef; + + public String getVendorName() { + return vendorName; + } + + public void setVendorName(String vendorName) { + this.vendorName = vendorName; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public String getIconRef() { + return iconRef; + } + + public void setIconRef(String iconRef) { + this.iconRef = iconRef; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/validation/ChoiceOrOtherSequenceProvider.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/validation/ChoiceOrOtherSequenceProvider.java new file mode 100644 index 0000000000..8be0ba3231 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/validation/ChoiceOrOtherSequenceProvider.java @@ -0,0 +1,45 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.types.validation; + +import org.hibernate.validator.spi.group.DefaultGroupSequenceProvider; +import org.openecomp.sdc.vendorlicense.dao.types.ChoiceOrOther; +import org.openecomp.sdcrests.vendorlicense.types.ChoiceOrOtherDto; + +import java.util.ArrayList; +import java.util.List; + +public class ChoiceOrOtherSequenceProvider + implements DefaultGroupSequenceProvider { + + @Override + public List> getValidationGroups(ChoiceOrOtherDto choiceOrOther) { + List> sequence = new ArrayList<>(); + sequence.add(ChoiceOrOtherDto.class); + + if (choiceOrOther != null && choiceOrOther.getChoice() != null + && ChoiceOrOther.OTHER_ENUM_VALUE.equals(choiceOrOther.getChoice().name())) { + sequence.add(OtherChoiceValidation.class); + } + + return sequence; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/validation/MultiChoiceOrOtherSequenceProvider.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/validation/MultiChoiceOrOtherSequenceProvider.java new file mode 100644 index 0000000000..7cc9bbd2a2 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/validation/MultiChoiceOrOtherSequenceProvider.java @@ -0,0 +1,47 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.types.validation; + +import org.hibernate.validator.spi.group.DefaultGroupSequenceProvider; +import org.openecomp.sdc.vendorlicense.dao.types.MultiChoiceOrOther; +import org.openecomp.sdcrests.vendorlicense.types.MultiChoiceOrOtherDto; + +import java.util.ArrayList; +import java.util.List; + +public class MultiChoiceOrOtherSequenceProvider + implements DefaultGroupSequenceProvider { + + @Override + public List> getValidationGroups(MultiChoiceOrOtherDto multiChoiceOrOther) { + List> sequence = new ArrayList<>(); + sequence.add(MultiChoiceOrOtherDto.class); + + if (multiChoiceOrOther != null && multiChoiceOrOther.getChoices() != null + && multiChoiceOrOther.getChoices().size() == 1 + && MultiChoiceOrOther.OTHER_ENUM_VALUE + .equals((((Enum) (multiChoiceOrOther.getChoices().iterator().next())).name()))) { + sequence.add(OtherChoiceValidation.class); + } + + return sequence; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/validation/OtherChoiceValidation.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/validation/OtherChoiceValidation.java new file mode 100644 index 0000000000..ff682dd8b5 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-license-rest/vendor-license-rest-types/src/main/java/org/openecomp/sdcrests/vendorlicense/types/validation/OtherChoiceValidation.java @@ -0,0 +1,24 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorlicense.types.validation; + +public interface OtherChoiceValidation { +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/pom.xml b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/pom.xml new file mode 100644 index 0000000000..8bd67d6a07 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/pom.xml @@ -0,0 +1,23 @@ + + + 4.0.0 + + + org.openecomp.sdc + openecomp-sdc-rest-webapp + 1.0.0-SNAPSHOT + + + org.openecomp.sdc.onboarding + vendor-software-products-rest + vendor-software-products-rest + pom + + + + /vendor-software-products-rest-services + /vendor-software-products-rest-types + + \ No newline at end of file diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/pom.xml b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/pom.xml new file mode 100644 index 0000000000..7869edfa01 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/pom.xml @@ -0,0 +1,144 @@ + + + 4.0.0 + + + org.openecomp.sdc.onboarding + vendor-software-products-rest + 1.0.0-SNAPSHOT + + + vendor-software-products-rest-services + + + + + org.springframework + spring-core + ${spring.framework.version} + + + org.springframework + spring-context + ${spring.framework.version} + + + org.springframework + spring-context-support + ${spring.framework.version} + + + org.springframework + spring-web + ${spring.framework.version} + + + org.springframework + spring-beans + ${spring.framework.version} + + + + + org.apache.cxf + cxf-rt-frontend-jaxrs + ${cxf.version} + + + + org.apache.httpcomponents + httpclient + ${http.client.version} + + + + javax.ws.rs + javax.ws.rs-api + ${ws.rs.version} + + + + + cglib + cglib-nodep + ${cglib.nodep.version} + runtime + + + + + javax.inject + javax.inject + ${javax.inject.version} + provided + + + javax.ws.rs + javax.ws.rs-api + ${ws.rs.version} + + + com.sun.jersey + jersey-core + 1.19.1 + + + javax.ws.rs + jsr311-api + + + + + io.swagger + swagger-annotations + 1.5.3 + + + org.openecomp.sdc.onboarding + vendor-software-products-rest-types + ${project.version} + + + com.fasterxml.jackson.core + jackson-annotations + 2.7.4 + + + com.fasterxml.jackson.dataformat + jackson-dataformat-xml + 2.7.4 + + + org.codehaus.woodstox + woodstox-core-asl + 4.4.1 + + + + org.openecomp.sdc + openecomp-sdc-vendor-software-product-manager + ${project.version} + + + + + + + + + + org.apache.maven.plugins + maven-surefire-plugin + + + test/core/unittest/offline/** + + true + + + + + + \ No newline at end of file diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/ComponentProcesses.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/ComponentProcesses.java new file mode 100644 index 0000000000..3fae16cf7f --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/ComponentProcesses.java @@ -0,0 +1,168 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vsp.rest; + +import static org.openecomp.sdcrests.common.RestConstants.USER_HEADER_PARAM; +import static org.openecomp.sdcrests.common.RestConstants.USER_MISSING_ERROR_MSG; + +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import io.swagger.annotations.ApiParam; +import org.apache.cxf.jaxrs.ext.multipart.Attachment; +import org.apache.cxf.jaxrs.ext.multipart.Multipart; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.ProcessEntityDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.ProcessRequestDto; +import org.springframework.validation.annotation.Validated; + +import javax.validation.Valid; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Pattern; +import javax.ws.rs.Consumes; +import javax.ws.rs.DELETE; +import javax.ws.rs.GET; +import javax.ws.rs.HeaderParam; +import javax.ws.rs.POST; +import javax.ws.rs.PUT; +import javax.ws.rs.Path; +import javax.ws.rs.PathParam; +import javax.ws.rs.Produces; +import javax.ws.rs.QueryParam; +import javax.ws.rs.core.MediaType; +import javax.ws.rs.core.Response; + +@Path("/v1.0/vendor-software-products/{vspId}/components/{componentId}/processes") +@Produces(MediaType.APPLICATION_JSON) +@Consumes(MediaType.APPLICATION_JSON) +@Api(value = "Vendor Software Product Component Processes") +@Validated +public interface ComponentProcesses { + @GET + @Path("/") + @ApiOperation(value = "List vendor software product component processes", + response = ProcessEntityDto.class, + responseContainer = "List") + Response list(@ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @ApiParam(value = "Vendor software product component Id") @PathParam("componentId") + String componentId, + @Pattern(regexp = Version.VERSION_REGEX, + message = Version.VERSION_STRING_VIOLATION_MSG) @QueryParam("version") + String version, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) + String user); + + @DELETE + @Path("/") + @ApiOperation(value = "Delete vendor software product processes", + responseContainer = "List") + Response deleteList( + @ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @ApiParam(value = "Vendor software product component Id") @PathParam("componentId") + String componentId, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) String user); + + @POST + @Path("/") + @ApiOperation(value = "Create a vendor software product process") + Response create(@Valid ProcessRequestDto request, + @ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @ApiParam(value = "Vendor software product component Id") + @PathParam("componentId") String componentId, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) + String user); + + @GET + @Path("/{processId}") + @ApiOperation(value = "Get vendor software product process", + response = ProcessEntityDto.class) + Response get(@ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @ApiParam(value = "Vendor software product component Id") @PathParam("componentId") + String componentId, + @ApiParam(value = "Vendor software product process Id") @PathParam("processId") + String processId, + @Pattern(regexp = Version.VERSION_REGEX, + message = Version.VERSION_STRING_VIOLATION_MSG) @QueryParam("version") + String version, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) + String user); + + @DELETE + @Path("/{processId}") + @ApiOperation(value = "Delete vendor software product process") + Response delete(@ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @ApiParam(value = "Vendor software product component Id") + @PathParam("componentId") String componentId, + @ApiParam(value = "Vendor software product process Id") @PathParam("processId") + String processId, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) + String user); + + @PUT + @Path("/{processId}") + @ApiOperation(value = "Update vendor software product process") + Response update(@Valid ProcessRequestDto request, + @ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @ApiParam(value = "Vendor software product component Id") + @PathParam("componentId") String componentId, + @ApiParam(value = "Vendor software product process Id") @PathParam("processId") + String processId, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) + String user); + + @GET + @Path("/{processId}/upload") + @Produces(MediaType.APPLICATION_OCTET_STREAM) + @ApiOperation(value = "Get vendor software product process uploaded file") + Response getUploadedFile( + @ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @ApiParam(value = "Vendor software product component Id") @PathParam("componentId") + String componentId, + @ApiParam(value = "Vendor software product process Id") @PathParam("processId") + String processId, + @Pattern(regexp = Version.VERSION_REGEX, message = Version.VERSION_STRING_VIOLATION_MSG) + @QueryParam("version") String version, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) String user); + + @DELETE + @Path("/{processId}/upload") + @ApiOperation(value = "Delete vendor software product process uploaded file") + Response deleteUploadedFile( + @ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @ApiParam(value = "Vendor software product component Id") @PathParam("componentId") + String componentId, + @ApiParam(value = "Vendor software product process Id") @PathParam("processId") + String processId, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) String user); + + @POST + @Path("/{processId}/upload") + @Consumes(MediaType.MULTIPART_FORM_DATA) + @ApiOperation(value = "Update vendor software product process upload") + Response uploadFile(@Multipart("upload") Attachment attachment, + @ApiParam(value = "Vendor software product Id") @PathParam("vspId") + String vspId, + @ApiParam(value = "Vendor software product component Id") + @PathParam("componentId") String componentId, + @ApiParam(value = "Vendor software product process Id") + @PathParam("processId") String processId, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) + String user); +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/ComponentUploads.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/ComponentUploads.java new file mode 100644 index 0000000000..c7ad2f7fe5 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/ComponentUploads.java @@ -0,0 +1,104 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vsp.rest; + +import static org.openecomp.sdcrests.common.RestConstants.USER_HEADER_PARAM; +import static org.openecomp.sdcrests.common.RestConstants.USER_MISSING_ERROR_MSG; + +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import io.swagger.annotations.ApiParam; +import org.apache.cxf.jaxrs.ext.multipart.Attachment; +import org.apache.cxf.jaxrs.ext.multipart.Multipart; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.MibUploadStatusDto; +import org.springframework.validation.annotation.Validated; + +import javax.validation.constraints.NotNull; +import javax.ws.rs.Consumes; +import javax.ws.rs.DELETE; +import javax.ws.rs.GET; +import javax.ws.rs.HeaderParam; +import javax.ws.rs.POST; +import javax.ws.rs.Path; +import javax.ws.rs.PathParam; +import javax.ws.rs.Produces; +import javax.ws.rs.core.MediaType; +import javax.ws.rs.core.Response; + + +@Path("/v1.0/vendor-software-products/{vspId}/components/{componentId}/monitors") +@Produces(MediaType.APPLICATION_JSON) +@Consumes(MediaType.APPLICATION_JSON) +@Api(value = "Vendor Software Product Component MIB Uploads") +@Validated +public interface ComponentUploads { + @POST + @Path("/snmp-trap/upload") + @Consumes(MediaType.MULTIPART_FORM_DATA) + @ApiOperation(value = "Upload vendor software product MIB Trap Definitions file") + Response uploadTrapMibFile(@Multipart("upload") Attachment attachment, + @ApiParam(value = "Vendor software product Id") @PathParam("vspId") + String vspId, + @ApiParam(value = "Vendor software product component Id") + @PathParam("componentId") String componentId, + @NotNull(message = USER_MISSING_ERROR_MSG) + @HeaderParam(USER_HEADER_PARAM) String user); + + @DELETE + @Path("/snmp-trap") + @ApiOperation(value = "Delete vendor software product MIB Trap Definitions file") + Response deleteTrapMibFile( + @ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @ApiParam(value = "Vendor software product component Id") @PathParam("componentId") + String componentId, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) String user); + + @POST + @Path("/snmp/upload") + @Consumes(MediaType.MULTIPART_FORM_DATA) + @ApiOperation(value = "Upload vendor software product MIB Poll Definitions file") + Response uploadPollMibFile(@Multipart("upload") Attachment attachment, + @ApiParam(value = "Vendor software product Id") @PathParam("vspId") + String vspId, + @ApiParam(value = "Vendor software product component Id") + @PathParam("componentId") String componentId, + @NotNull(message = USER_MISSING_ERROR_MSG) + @HeaderParam(USER_HEADER_PARAM) String user); + + @DELETE + @Path("/snmp") + @ApiOperation(value = "Delete vendor software product MIB Poll Definitions file") + Response deletePollMibFile( + @ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @ApiParam(value = "Vendor software product component Id") @PathParam("componentId") + String componentId, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) String user); + + @GET + @Path("/snmp/") + @ApiOperation(value = "Get the filenames of uploaded MIB definitions", + response = MibUploadStatusDto.class) + Response list(@ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @ApiParam(value = "Vendor software product component Id") @PathParam("componentId") + String componentId, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) + String user); +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/Components.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/Components.java new file mode 100644 index 0000000000..949a40cfbb --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/Components.java @@ -0,0 +1,142 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vsp.rest; + +import static org.openecomp.sdcrests.common.RestConstants.USER_HEADER_PARAM; +import static org.openecomp.sdcrests.common.RestConstants.USER_MISSING_ERROR_MSG; + +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import io.swagger.annotations.ApiParam; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.ComponentData; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.ComponentDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.ComponentRequestDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.QuestionnaireResponseDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.validation.IsValidJson; +import org.springframework.validation.annotation.Validated; + +import javax.validation.Valid; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Pattern; +import javax.ws.rs.Consumes; +import javax.ws.rs.DELETE; +import javax.ws.rs.GET; +import javax.ws.rs.HeaderParam; +import javax.ws.rs.POST; +import javax.ws.rs.PUT; +import javax.ws.rs.Path; +import javax.ws.rs.PathParam; +import javax.ws.rs.Produces; +import javax.ws.rs.QueryParam; +import javax.ws.rs.core.MediaType; +import javax.ws.rs.core.Response; + +@Path("/v1.0/vendor-software-products/{vspId}/components") +@Produces(MediaType.APPLICATION_JSON) +@Consumes(MediaType.APPLICATION_JSON) +@Api(value = "Vendor Software Product Components") +@Validated +public interface Components { + @GET + @Path("/") + @ApiOperation(value = "List vendor software product components", + response = ComponentDto.class, + responseContainer = "List") + Response list(@ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @Pattern(regexp = Version.VERSION_REGEX, + message = Version.VERSION_STRING_VIOLATION_MSG) @QueryParam("version") + String version, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) + String user); + + @DELETE + @Path("/") + @ApiOperation(value = "Delete vendor software product components", + responseContainer = "List") + Response deleteList( + @ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) String user); + + @POST + @Path("/") + @ApiOperation(value = "Create a vendor software product component") + Response create(@Valid ComponentRequestDto request, + @ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) + String user); + + @GET + @Path("/{componentId}") + @ApiOperation(value = "Get vendor software product component", + response = ComponentData.class, + responseContainer = "CompositionEntityResponse") + Response get(@ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @ApiParam(value = "Vendor software product component Id") @PathParam("componentId") + String componentId, + @Pattern(regexp = Version.VERSION_REGEX, + message = Version.VERSION_STRING_VIOLATION_MSG) @QueryParam("version") + String version, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) + String user); + + @DELETE + @Path("/{componentId}") + @ApiOperation(value = "Delete vendor software product component") + Response delete(@ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @ApiParam(value = "Vendor software product component Id") + @PathParam("componentId") String componentId, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) + String user); + + @PUT + @Path("/{componentId}") + @ApiOperation(value = "Update vendor software product component") + Response update(@Valid ComponentRequestDto request, + @ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @ApiParam(value = "Vendor software product component Id") + @PathParam("componentId") String componentId, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) + String user); + + @GET + @Path("/{componentId}/questionnaire") + @ApiOperation(value = "Get vendor software product component questionnaire", + response = QuestionnaireResponseDto.class) + Response getQuestionnaire( + @ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @ApiParam(value = "Vendor software product component Id") @PathParam("componentId") + String componentId, + @Pattern(regexp = Version.VERSION_REGEX, message = Version.VERSION_STRING_VIOLATION_MSG) + @QueryParam("version") String version, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) String user); + + @PUT + @Path("/{componentId}/questionnaire") + @ApiOperation(value = "Update vendor software product component questionnaire") + Response updateQuestionnaire(@NotNull @IsValidJson String questionnaireData, + @ApiParam(value = "Vendor software product Id") @PathParam("vspId") + String vspId, + @ApiParam(value = "Vendor software product component Id") + @PathParam("componentId") String componentId, + @NotNull(message = USER_MISSING_ERROR_MSG) + @HeaderParam(USER_HEADER_PARAM) String user); +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/Networks.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/Networks.java new file mode 100644 index 0000000000..5c7c9d7bd8 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/Networks.java @@ -0,0 +1,107 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vsp.rest; + +import static org.openecomp.sdcrests.common.RestConstants.USER_HEADER_PARAM; +import static org.openecomp.sdcrests.common.RestConstants.USER_MISSING_ERROR_MSG; + +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import io.swagger.annotations.ApiParam; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.NetworkDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.NetworkRequestDto; +import org.springframework.validation.annotation.Validated; + +import javax.validation.Valid; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Pattern; +import javax.ws.rs.Consumes; +import javax.ws.rs.DELETE; +import javax.ws.rs.GET; +import javax.ws.rs.HeaderParam; +import javax.ws.rs.POST; +import javax.ws.rs.PUT; +import javax.ws.rs.Path; +import javax.ws.rs.PathParam; +import javax.ws.rs.Produces; +import javax.ws.rs.QueryParam; +import javax.ws.rs.core.MediaType; +import javax.ws.rs.core.Response; + +@Path("/v1.0/vendor-software-products/{vspId}/networks") +@Produces(MediaType.APPLICATION_JSON) +@Consumes(MediaType.APPLICATION_JSON) +@Api(value = "Vendor Software Product Networks") +@Validated +public interface Networks { + @GET + @Path("/") + @ApiOperation(value = "List vendor software product networks", + response = NetworkDto.class, + responseContainer = "List") + Response list(@ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @Pattern(regexp = Version.VERSION_REGEX, + message = Version.VERSION_STRING_VIOLATION_MSG) @QueryParam("version") + String version, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) + String user); + + @POST + @Path("/") + @ApiOperation(value = "Create a vendor software product network") + Response create(@Valid NetworkRequestDto request, + @ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) + String user); + + @GET + @Path("/{networkId}") + @ApiOperation(value = "Get vendor software product network", + response = NetworkDto.class) + Response get(@ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @ApiParam(value = "Vendor software product network Id") @PathParam("networkId") + String networkId, + @Pattern(regexp = Version.VERSION_REGEX, + message = Version.VERSION_STRING_VIOLATION_MSG) @QueryParam("version") + String version, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) + String user); + + @DELETE + @Path("/{networkId}") + @ApiOperation(value = "Delete vendor software product network") + Response delete(@ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @ApiParam(value = "Vendor software product network Id") @PathParam("networkId") + String networkId, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) + String user); + + @PUT + @Path("/{networkId}") + @ApiOperation(value = "Update vendor software product network") + Response update(@Valid NetworkRequestDto request, + @ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @ApiParam(value = "Vendor software product network Id") @PathParam("networkId") + String networkId, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) + String user); +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/Nics.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/Nics.java new file mode 100644 index 0000000000..8cf26a405b --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/Nics.java @@ -0,0 +1,144 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vsp.rest; + +import static org.openecomp.sdcrests.common.RestConstants.USER_HEADER_PARAM; +import static org.openecomp.sdcrests.common.RestConstants.USER_MISSING_ERROR_MSG; + +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import io.swagger.annotations.ApiParam; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.NicDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.NicRequestDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.QuestionnaireResponseDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.validation.IsValidJson; +import org.springframework.validation.annotation.Validated; + +import javax.validation.Valid; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Pattern; +import javax.ws.rs.Consumes; +import javax.ws.rs.DELETE; +import javax.ws.rs.GET; +import javax.ws.rs.HeaderParam; +import javax.ws.rs.POST; +import javax.ws.rs.PUT; +import javax.ws.rs.Path; +import javax.ws.rs.PathParam; +import javax.ws.rs.Produces; +import javax.ws.rs.QueryParam; +import javax.ws.rs.core.MediaType; +import javax.ws.rs.core.Response; + +@Path("/v1.0/vendor-software-products/{vspId}/components/{componentId}/nics") +@Produces(MediaType.APPLICATION_JSON) +@Consumes(MediaType.APPLICATION_JSON) +@Api(value = "Vendor Software Product Component NICs") +@Validated +public interface Nics { + @GET + @Path("/") + @ApiOperation(value = "List vendor software product component NICs", + response = NicDto.class, + responseContainer = "List") + Response list(@ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @ApiParam(value = "Vendor software product component Id") @PathParam("componentId") + String componentId, + @Pattern(regexp = Version.VERSION_REGEX, + message = Version.VERSION_STRING_VIOLATION_MSG) @QueryParam("version") + String version, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) + String user); + + @POST + @Path("/") + @ApiOperation(value = "Create a vendor software product NIC") + Response create(@Valid NicRequestDto request, + @ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @ApiParam(value = "Vendor software product component Id") + @PathParam("componentId") String componentId, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) + String user); + + @GET + @Path("/{nicId}") + @ApiOperation(value = "Get vendor software product NIC", + response = NicDto.class) + Response get(@ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @ApiParam(value = "Vendor software product component Id") @PathParam("componentId") + String componentId, + @ApiParam(value = "Vendor software product NIC Id") @PathParam("nicId") String nicId, + @Pattern(regexp = Version.VERSION_REGEX, + message = Version.VERSION_STRING_VIOLATION_MSG) @QueryParam("version") + String version, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) + String user); + + @DELETE + @Path("/{nicId}") + @ApiOperation(value = "Delete vendor software product NIC") + Response delete(@ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @ApiParam(value = "Vendor software product component Id") + @PathParam("componentId") String componentId, + @ApiParam(value = "Vendor software product NIC Id") @PathParam("nicId") + String nicId, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) + String user); + + @PUT + @Path("/{nicId}") + @ApiOperation(value = "Update vendor software product NIC") + Response update(@Valid NicRequestDto request, + @ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @ApiParam(value = "Vendor software product component Id") + @PathParam("componentId") String componentId, + @ApiParam(value = "Vendor software product NIC Id") @PathParam("nicId") + String nicId, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) + String user); + + @GET + @Path("/{nicId}/questionnaire") + @ApiOperation(value = "Get vendor software product component NIC questionnaire", + response = QuestionnaireResponseDto.class) + Response getQuestionnaire( + @ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @ApiParam(value = "Vendor software product component Id") @PathParam("componentId") + String componentId, + @ApiParam(value = "Vendor software product NIC Id") @PathParam("nicId") String nicId, + @Pattern(regexp = Version.VERSION_REGEX, message = Version.VERSION_STRING_VIOLATION_MSG) + @QueryParam("version") String version, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) String user); + + @PUT + @Path("/{nicId}/questionnaire") + @ApiOperation(value = "Update vendor software product component NIC questionnaire") + Response updateQuestionnaire(@NotNull @IsValidJson String questionnaireData, + @ApiParam(value = "Vendor software product Id") @PathParam("vspId") + String vspId, + @ApiParam(value = "Vendor software product component Id") + @PathParam("componentId") String componentId, + @ApiParam(value = "Vendor software product NIC Id") + @PathParam("nicId") String nicId, + @NotNull(message = USER_MISSING_ERROR_MSG) + @HeaderParam(USER_HEADER_PARAM) String user); +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/Processes.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/Processes.java new file mode 100644 index 0000000000..b5c74587e4 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/Processes.java @@ -0,0 +1,151 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vsp.rest; + +import static org.openecomp.sdcrests.common.RestConstants.USER_HEADER_PARAM; +import static org.openecomp.sdcrests.common.RestConstants.USER_MISSING_ERROR_MSG; + +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import io.swagger.annotations.ApiParam; +import org.apache.cxf.jaxrs.ext.multipart.Attachment; +import org.apache.cxf.jaxrs.ext.multipart.Multipart; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.ProcessEntityDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.ProcessRequestDto; + +import org.springframework.validation.annotation.Validated; + +import javax.validation.Valid; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Pattern; +import javax.ws.rs.Consumes; +import javax.ws.rs.DELETE; +import javax.ws.rs.GET; +import javax.ws.rs.HeaderParam; +import javax.ws.rs.POST; +import javax.ws.rs.PUT; +import javax.ws.rs.Path; +import javax.ws.rs.PathParam; +import javax.ws.rs.Produces; +import javax.ws.rs.QueryParam; +import javax.ws.rs.core.MediaType; +import javax.ws.rs.core.Response; + +@Path("/v1.0/vendor-software-products/{vspId}/processes") +@Produces(MediaType.APPLICATION_JSON) +@Consumes(MediaType.APPLICATION_JSON) +@Api(value = "Vendor Software Product Processes") +@Validated +public interface Processes { + @GET + @Path("/") + @ApiOperation(value = "List vendor software product processes", + response = ProcessEntityDto.class, + responseContainer = "List") + Response list(@ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @Pattern(regexp = Version.VERSION_REGEX, + message = Version.VERSION_STRING_VIOLATION_MSG) @QueryParam("version") + String version, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) + String user); + + @DELETE + @Path("/") + @ApiOperation(value = "Delete vendor software product processes", + responseContainer = "List") + Response deleteList( + @ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) String user); + + @POST + @Path("/") + @ApiOperation(value = "Create a vendor software product process") + Response create(@Valid ProcessRequestDto request, + @ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) + String user); + + @GET + @Path("/{processId}") + @ApiOperation(value = "Get vendor software product process", + response = ProcessEntityDto.class) + Response get(@ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @ApiParam(value = "Vendor software product process Id") @PathParam("processId") + String processId, + @Pattern(regexp = Version.VERSION_REGEX, + message = Version.VERSION_STRING_VIOLATION_MSG) @QueryParam("version") + String version, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) + String user); + + @DELETE + @Path("/{processId}") + @ApiOperation(value = "Delete vendor software product process") + Response delete(@ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @ApiParam(value = "Vendor software product process Id") @PathParam("processId") + String processId, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) + String user); + + @PUT + @Path("/{processId}") + @ApiOperation(value = "Update vendor software product process") + Response update(@Valid ProcessRequestDto request, + @ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @ApiParam(value = "Vendor software product process Id") @PathParam("processId") + String processId, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) + String user); + + @GET + @Path("/{processId}/upload") + @Produces(MediaType.APPLICATION_OCTET_STREAM) + @ApiOperation(value = "Get vendor software product process uploaded file") + Response getUploadedFile( + @ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @ApiParam(value = "Vendor software product process Id") @PathParam("processId") + String processId, + @Pattern(regexp = Version.VERSION_REGEX, message = Version.VERSION_STRING_VIOLATION_MSG) + @QueryParam("version") String version, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) String user); + + @DELETE + @Path("/{processId}/upload") + @ApiOperation(value = "Delete vendor software product process uploaded file") + Response deleteUploadedFile( + @ApiParam(value = "Vendor software product Id") @PathParam("vspId") String vspId, + @ApiParam(value = "Vendor software product process Id") @PathParam("processId") + String processId, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) String user); + + @POST + @Path("/{processId}/upload") + @Consumes(MediaType.MULTIPART_FORM_DATA) + @ApiOperation(value = "Update vendor software product process upload") + Response uploadFile(@Multipart("upload") Attachment attachment, + @ApiParam(value = "Vendor software product Id") @PathParam("vspId") + String vspId, + @ApiParam(value = "Vendor software product process Id") + @PathParam("processId") String processId, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) + String user); +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/VendorSoftwareProducts.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/VendorSoftwareProducts.java new file mode 100644 index 0000000000..259ef723c6 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/VendorSoftwareProducts.java @@ -0,0 +1,193 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vsp.rest; + +import static org.openecomp.sdcrests.common.RestConstants.USER_HEADER_PARAM; +import static org.openecomp.sdcrests.common.RestConstants.USER_MISSING_ERROR_MSG; + +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import io.swagger.annotations.ApiParam; + +import org.apache.cxf.jaxrs.ext.multipart.Multipart; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.PackageInfoDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.QuestionnaireResponseDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.UploadFileResponseDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.VersionSoftwareProductActionRequestDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.VspCreationDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.VspDescriptionDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.validation.IsValidJson; +import org.springframework.validation.annotation.Validated; + +import java.io.File; +import java.io.IOException; +import java.io.InputStream; +import javax.validation.Valid; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Pattern; +import javax.ws.rs.Consumes; +import javax.ws.rs.DELETE; +import javax.ws.rs.GET; +import javax.ws.rs.HeaderParam; +import javax.ws.rs.POST; +import javax.ws.rs.PUT; +import javax.ws.rs.Path; +import javax.ws.rs.PathParam; +import javax.ws.rs.Produces; +import javax.ws.rs.QueryParam; +import javax.ws.rs.core.MediaType; +import javax.ws.rs.core.Response; + + +@Path("/v1.0/vendor-software-products") +@Produces(MediaType.APPLICATION_JSON) +@Consumes(MediaType.APPLICATION_JSON) +@Api(value = "Vendor Software Products") +@Validated +public interface VendorSoftwareProducts { + + @POST + @Path("/") + @ApiOperation(value = "Create a new vendor software product", + response = VspCreationDto.class) + Response createNewVsp(@Valid VspDescriptionDto vspDescriptionDto, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) + String user); + + @GET + @Path("/") + @ApiOperation(value = "Get list of vendor software products and their description", + responseContainer = "List") + Response getVspList(@ApiParam( + value = "Currently supported values: 'Final' - only vendor software products with final " + + "version will be return - with their latest final version") + @QueryParam("versionFilter") String versionFilter, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) + String user); + + @GET + @Path("/packages") + @ApiOperation(value = "Get list of translated CSAR files details", + response = PackageInfoDto.class, + responseContainer = "List") + Response listPackages(@ApiParam("Category") @QueryParam("category") String category, + @ApiParam("Sub-category") @QueryParam("subCategory") String subCategory, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) + String user); + + @GET + @Path("/{vspId}") + @ApiOperation(value = "Get details of a vendor software product") + Response getVspDetails(@PathParam("vspId") String vspId, + @Pattern(regexp = Version.VERSION_REGEX, + message = Version.VERSION_STRING_VIOLATION_MSG) @QueryParam("version") + String version, + @NotNull(message = USER_MISSING_ERROR_MSG) + @HeaderParam(USER_HEADER_PARAM) String user); + + @PUT + @Path("/{vspId}") + @ApiOperation(value = "Update an existing vendor software product") + Response updateVsp(@PathParam("vspId") String vspId, @Valid VspDescriptionDto vspDescriptionDto, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) + String user); + + @DELETE + @Path("/{vspId}") + @ApiOperation(value = "Deletes vendor software product by given id") + Response deleteVsp(@PathParam("vspId") String vspId, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) + String user); + + @POST + @Path("{vspId}/upload") + @Consumes(MediaType.MULTIPART_FORM_DATA) + @ApiOperation(value = "Uploads a HEAT package to translate", + response = UploadFileResponseDto.class) + Response uploadFile(@PathParam("vspId") String vspId, + @Multipart("upload") InputStream heatFileToUpload, + @NotNull(message = USER_MISSING_ERROR_MSG) @HeaderParam(USER_HEADER_PARAM) + String user); + + @GET + @Path("/{vspId}/downloadHeat") + @Produces(MediaType.APPLICATION_OCTET_STREAM) + @ApiOperation(value = "Get uploaded HEAT file", + notes = "Downloads the latest HEAT package", + response = File.class) + Response getLatestHeatPackage(@PathParam("vspId") String vspId, + /*@NotNull(message = USER_MISSING_ERROR_MSG)*/ + @HeaderParam(USER_HEADER_PARAM) String user); + + + @PUT + @Path("/{vspId}/actions") + @ApiOperation(value = "Actions on a vendor software product", + notes = "Performs one of the following actions on a vendor software product: |" + + "Checkout: Locks it for edits by other users. Only the locking user sees the edited " + + "version.|" + + "Undo_Checkout: Unlocks it and deletes the edits that were done.|" + + "Checkin: Unlocks it and activates the edited version to all users.| " + + "Submit: Finalize its active version.|" + + "Create_Package: Creates a CSAR zip file.|") + /*@ApiResponses(value = { + @ApiResponse(code = 200, message = "Action succeeded"), + @ApiResponse(code = 417, message = "Validation before submit has failed", + response = ValidationResponseDto.class)})*/ + Response actOnVendorSoftwareProduct(@PathParam("vspId") String vspId, + VersionSoftwareProductActionRequestDto request, + @NotNull(message = USER_MISSING_ERROR_MSG) + @HeaderParam(USER_HEADER_PARAM) String user) + throws IOException; + + @GET + @Path("/packages/{vspId}") + @Produces(MediaType.APPLICATION_OCTET_STREAM) + @ApiOperation(value = "Get translated CSAR file", + notes = "Exports translated file to a zip file", + response = File.class) + Response getTranslatedFile(@PathParam("vspId") String vspId, + @Pattern(regexp = Version.VERSION_REGEX, + message = Version.VERSION_STRING_VIOLATION_MSG) + @QueryParam("version") String version, + /*@NotNull(message = USER_MISSING_ERROR_MSG)*/ + @HeaderParam(USER_HEADER_PARAM) String user); + + @GET + @Path("/{vspId}/questionnaire") + @ApiOperation(value = "Get vendor software product questionnaire", + response = QuestionnaireResponseDto.class) + Response getQuestionnaire(@PathParam("vspId") String vspId, + @Pattern(regexp = Version.VERSION_REGEX, + message = Version.VERSION_STRING_VIOLATION_MSG) + @QueryParam("version") String version, + @NotNull(message = USER_MISSING_ERROR_MSG) + @HeaderParam(USER_HEADER_PARAM) String user); + + @PUT + @Path("/{vspId}/questionnaire") + @ApiOperation(value = "Update vendor software product questionnaire") + Response updateQuestionnaire(@NotNull @IsValidJson String questionnaireData, + @PathParam("vspId") String vspId, + @NotNull(message = USER_MISSING_ERROR_MSG) + @HeaderParam(USER_HEADER_PARAM) String user); +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapComponentDataToComponentDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapComponentDataToComponentDto.java new file mode 100644 index 0000000000..e448ed6ca7 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapComponentDataToComponentDto.java @@ -0,0 +1,35 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vsp.rest.mapping; + +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.ComponentData; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.ComponentDto; + +public class MapComponentDataToComponentDto extends MappingBase { + @Override + public void doMapping(ComponentData source, ComponentDto target) { + target.setName(source.getName()); + target.setDisplayName( + source.getDisplayName() == null ? source.getName() : source.getDisplayName()); + target.setDescription(source.getDescription()); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapComponentEntityToComponentDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapComponentEntityToComponentDto.java new file mode 100644 index 0000000000..8878581d1c --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapComponentEntityToComponentDto.java @@ -0,0 +1,37 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vsp.rest.mapping; + +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.ComponentData; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.ComponentDto; + +public class MapComponentEntityToComponentDto extends MappingBase { + @Override + public void doMapping(ComponentEntity source, ComponentDto target) { + target.setId(source.getId()); + ComponentData component = source.getComponentCompositionData(); + if (component != null) { + new MapComponentDataToComponentDto().doMapping(component, target); + } + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapComponentRequestDtoToComponentEntity.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapComponentRequestDtoToComponentEntity.java new file mode 100644 index 0000000000..ce9e32770c --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapComponentRequestDtoToComponentEntity.java @@ -0,0 +1,38 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vsp.rest.mapping; + +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.ComponentData; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.ComponentRequestDto; + +public class MapComponentRequestDtoToComponentEntity + extends MappingBase { + @Override + public void doMapping(ComponentRequestDto source, ComponentEntity target) { + ComponentData component = new ComponentData(); + component.setName(source.getName()); + component.setDisplayName(source.getDisplayName()); + component.setDescription(source.getDescription()); + target.setComponentCompositionData(component); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapCompositionEntityResponseToDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapCompositionEntityResponseToDto.java new file mode 100644 index 0000000000..b5b7ccdfee --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapCompositionEntityResponseToDto.java @@ -0,0 +1,47 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vsp.rest.mapping; + +import org.openecomp.sdc.vendorsoftwareproduct.types.CompositionEntityResponse; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionDataEntity; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.CompositionDataEntityDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.CompositionEntityResponseDto; + +public class MapCompositionEntityResponseToDto> + extends MappingBase, CompositionEntityResponseDto> { + private M dataMapper; + private Class targetDataClass; + + public MapCompositionEntityResponseToDto(M dataMapper, Class targetDataClass) { + this.dataMapper = dataMapper; + this.targetDataClass = targetDataClass; + } + + @Override + public void doMapping(CompositionEntityResponse source, + CompositionEntityResponseDto target) { + target.setId(source.getId()); + target.setSchema(source.getSchema()); + target.setData(dataMapper.applyMapping(source.getData(), targetDataClass)); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapCompositionEntityValidationDataToDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapCompositionEntityValidationDataToDto.java new file mode 100644 index 0000000000..cb726dfc79 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapCompositionEntityValidationDataToDto.java @@ -0,0 +1,44 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vsp.rest.mapping; + +import org.apache.commons.collections4.CollectionUtils; +import org.openecomp.sdc.vendorsoftwareproduct.types.CompositionEntityValidationData; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.CompositionEntityValidationDataDto; + +import java.util.stream.Collectors; + +public class MapCompositionEntityValidationDataToDto + extends MappingBase { + @Override + public void doMapping(CompositionEntityValidationData source, + CompositionEntityValidationDataDto target) { + target.setEntityType(source.getEntityType()); + target.setEntityId(source.getEntityId()); + target.setErrors(source.getErrors()); + if (CollectionUtils.isNotEmpty(source.getSubEntitiesValidationData())) { + target.setSubEntitiesValidationData(source.getSubEntitiesValidationData().stream() + .map(sub -> applyMapping(sub, CompositionEntityValidationDataDto.class)) + .collect(Collectors.toList())); + } + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapMibUploadStatusToDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapMibUploadStatusToDto.java new file mode 100644 index 0000000000..d69e078ac1 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapMibUploadStatusToDto.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vsp.rest.mapping; + +import org.openecomp.sdc.vendorsoftwareproduct.types.schemagenerator.MibUploadStatus; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.MibUploadStatusDto; + +public class MapMibUploadStatusToDto extends MappingBase { + @Override + public void doMapping(MibUploadStatus source, MibUploadStatusDto target) { + target.setSnmpPoll(source.getSnmpPoll()); + target.setSnmpTrap(source.getSnmpTrap()); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapNetworkEntityToNetworkDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapNetworkEntityToNetworkDto.java new file mode 100644 index 0000000000..1d79f35769 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapNetworkEntityToNetworkDto.java @@ -0,0 +1,37 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vsp.rest.mapping; + +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.NetworkEntity; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.Network; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.NetworkDto; + +public class MapNetworkEntityToNetworkDto extends MappingBase { + @Override + public void doMapping(NetworkEntity source, NetworkDto target) { + target.setId(source.getId()); + Network network = source.getNetworkCompositionData(); + if (network != null) { + new MapNetworkToNetworkDto().doMapping(network, target); + } + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapNetworkRequestDtoToNetworkEntity.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapNetworkRequestDtoToNetworkEntity.java new file mode 100644 index 0000000000..00395c4b99 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapNetworkRequestDtoToNetworkEntity.java @@ -0,0 +1,37 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vsp.rest.mapping; + +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.NetworkEntity; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.Network; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.NetworkRequestDto; + +public class MapNetworkRequestDtoToNetworkEntity + extends MappingBase { + @Override + public void doMapping(NetworkRequestDto source, NetworkEntity target) { + Network network = new Network(); + network.setName(source.getName()); + network.setDhcp(source.isDhcp()); + target.setNetworkCompositionData(network); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapNetworkToNetworkDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapNetworkToNetworkDto.java new file mode 100644 index 0000000000..dd819de1a6 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapNetworkToNetworkDto.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vsp.rest.mapping; + +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.Network; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.NetworkDto; + +public class MapNetworkToNetworkDto extends MappingBase { + @Override + public void doMapping(Network source, NetworkDto target) { + target.setName(source.getName()); + target.setDhcp(source.isDhcp()); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapNicEntityToNicDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapNicEntityToNicDto.java new file mode 100644 index 0000000000..2af7e2ff6b --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapNicEntityToNicDto.java @@ -0,0 +1,37 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vsp.rest.mapping; + +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.Nic; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.NicDto; + +public class MapNicEntityToNicDto extends MappingBase { + @Override + public void doMapping(NicEntity source, NicDto target) { + target.setId(source.getId()); + Nic nic = source.getNicCompositionData(); + if (nic != null) { + new MapNicToNicDto().doMapping(nic, target); + } + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapNicRequestDtoToNicEntity.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapNicRequestDtoToNicEntity.java new file mode 100644 index 0000000000..4744364ea6 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapNicRequestDtoToNicEntity.java @@ -0,0 +1,37 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vsp.rest.mapping; + +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.Nic; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.NicRequestDto; + +public class MapNicRequestDtoToNicEntity extends MappingBase { + @Override + public void doMapping(NicRequestDto source, NicEntity target) { + Nic nic = new Nic(); + nic.setName(source.getName()); + nic.setDescription(source.getDescription()); + nic.setNetworkId(source.getNetworkId()); + target.setNicCompositionData(nic); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapNicToNicDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapNicToNicDto.java new file mode 100644 index 0000000000..2fcfd36b3f --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapNicToNicDto.java @@ -0,0 +1,35 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vsp.rest.mapping; + +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.Nic; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.NicDto; + +public class MapNicToNicDto extends MappingBase { + @Override + public void doMapping(Nic source, NicDto target) { + target.setName(source.getName()); + target.setDescription(source.getDescription()); + target.setNetworkId(source.getNetworkId()); + target.setNetworkName(source.getNetworkName()); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapPackageInfoToPackageInfoDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapPackageInfoToPackageInfoDto.java new file mode 100644 index 0000000000..9cd365480e --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapPackageInfoToPackageInfoDto.java @@ -0,0 +1,42 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vsp.rest.mapping; + +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.PackageInfo; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.PackageInfoDto; + +public class MapPackageInfoToPackageInfoDto extends MappingBase { + @Override + public void doMapping(PackageInfo source, PackageInfoDto target) { + target.setDisplayName(source.getDisplayName()); + target.setVspName(source.getVspName()); + target.setPackageId(source.getVspId()); + target.setDescription(source.getVspDescription()); + target.setVersion(source.getVersion() == null ? null : source.getVersion().toString()); + target.setPackageType(source.getPackageType()); + target.setCategory(source.getCategory()); + target.setSubCategory(source.getSubCategory()); + target.setPackageChecksum(source.getPackageChecksum()); + target.setVendorRelease(source.getVendorRelease()); + target.setVendorName(source.getVendorName()); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapProcessEntityToProcessEntityDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapProcessEntityToProcessEntityDto.java new file mode 100644 index 0000000000..5842a30b70 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapProcessEntityToProcessEntityDto.java @@ -0,0 +1,36 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vsp.rest.mapping; + +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.ProcessEntityDto; + +public class MapProcessEntityToProcessEntityDto + extends MappingBase { + @Override + public void doMapping(ProcessEntity source, ProcessEntityDto target) { + target.setId(source.getId()); + target.setName(source.getName()); + target.setDescription(source.getDescription()); + target.setArtifactName(source.getArtifactName()); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapProcessRequestDtoToProcessEntity.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapProcessRequestDtoToProcessEntity.java new file mode 100644 index 0000000000..1fd35d1960 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapProcessRequestDtoToProcessEntity.java @@ -0,0 +1,34 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vsp.rest.mapping; + +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.ProcessRequestDto; + +public class MapProcessRequestDtoToProcessEntity + extends MappingBase { + @Override + public void doMapping(ProcessRequestDto source, ProcessEntity target) { + target.setName(source.getName()); + target.setDescription(source.getDescription()); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapQuestionnaireResponseToQuestionnaireResponseDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapQuestionnaireResponseToQuestionnaireResponseDto.java new file mode 100644 index 0000000000..23fdf385e4 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapQuestionnaireResponseToQuestionnaireResponseDto.java @@ -0,0 +1,35 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vsp.rest.mapping; + +import org.openecomp.sdc.vendorsoftwareproduct.types.QuestionnaireResponse; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.QuestionnaireResponseDto; + +public class MapQuestionnaireResponseToQuestionnaireResponseDto + extends MappingBase { + + @Override + public void doMapping(QuestionnaireResponse source, QuestionnaireResponseDto target) { + target.setData(source.getData()); + target.setSchema(source.getSchema()); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapUploadFileResponseToUploadFileResponseDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapUploadFileResponseToUploadFileResponseDto.java new file mode 100644 index 0000000000..29b6701413 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapUploadFileResponseToUploadFileResponseDto.java @@ -0,0 +1,36 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vsp.rest.mapping; + + +import org.openecomp.sdc.vendorsoftwareproduct.types.UploadFileResponse; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.UploadFileResponseDto; + +public class MapUploadFileResponseToUploadFileResponseDto + extends MappingBase { + @Override + public void doMapping(UploadFileResponse source, UploadFileResponseDto target) { + target.setStatus(source.getStatus()); + target.setErrors(source.getErrors()); + target.setFileNames(source.getFileNames()); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapValidationResponseToDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapValidationResponseToDto.java new file mode 100644 index 0000000000..68bc97d1a6 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapValidationResponseToDto.java @@ -0,0 +1,90 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vsp.rest.mapping; + +import org.apache.commons.collections.CollectionUtils; +import org.apache.commons.collections4.MapUtils; +import org.openecomp.sdc.common.errors.ErrorCode; +import org.openecomp.sdc.datatypes.error.ErrorMessage; +import org.openecomp.sdc.vendorsoftwareproduct.types.QuestionnaireValidationResult; +import org.openecomp.sdc.vendorsoftwareproduct.types.ValidationResponse; +import org.openecomp.sdcrests.common.mapping.MapErrorCodeToDto; +import org.openecomp.sdcrests.common.mapping.MapErrorMessageToDto; +import org.openecomp.sdcrests.common.types.ErrorCodeDto; +import org.openecomp.sdcrests.common.types.ErrorMessageDto; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.CompositionEntityValidationDataDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.QuestionnaireValidationResultDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.ValidationResponseDto; + + +import java.util.Collection; +import java.util.List; +import java.util.Map; +import java.util.stream.Collectors; + +public class MapValidationResponseToDto + extends MappingBase { + private static Map> mapUploadDataErrors( + Map> uploadDataErrors) { + if (MapUtils.isEmpty(uploadDataErrors)) { + return null; + } + return uploadDataErrors.entrySet().stream().collect( + Collectors.toMap(entry -> entry.getKey(), entry -> mapErrorMessages(entry.getValue()))); + } + + private static QuestionnaireValidationResultDto mapQuestionnaireValidationResult( + QuestionnaireValidationResult questionnaireValidationResult) { + if (questionnaireValidationResult == null) { + return null; + } + QuestionnaireValidationResultDto questionnaireValidationResultDto = + new QuestionnaireValidationResultDto(); + questionnaireValidationResultDto.setValid(questionnaireValidationResult.isValid()); + questionnaireValidationResultDto.setValidationData(new MapCompositionEntityValidationDataToDto() + .applyMapping(questionnaireValidationResult.getValidationData(), + CompositionEntityValidationDataDto.class)); + return questionnaireValidationResultDto; + } + + private static List mapErrorMessages(List errorMessages) { + return errorMessages == null ? null : errorMessages.stream().map( + errorMessage -> new MapErrorMessageToDto() + .applyMapping(errorMessage, ErrorMessageDto.class)).collect(Collectors.toList()); + } + + private static Collection mapErrorCodes(Collection errorCodes) { + return CollectionUtils.isEmpty(errorCodes) ? null : errorCodes.stream() + .map(errorCode -> new MapErrorCodeToDto().applyMapping(errorCode, ErrorCodeDto.class)) + .collect(Collectors.toList()); + } + + @Override + public void doMapping(ValidationResponse source, ValidationResponseDto target) { + target.setValid(source.isValid()); + target.setVspErrors(mapErrorCodes(source.getVspErrors())); + target.setLicensingDataErrors(mapErrorCodes(source.getLicensingDataErrors())); + target.setUploadDataErrors(mapUploadDataErrors(source.getUploadDataErrors())); + target.setQuestionnaireValidationResult( + mapQuestionnaireValidationResult(source.getQuestionnaireValidationResult())); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapVersionedVendorSoftwareProductInfoToVspDetailsDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapVersionedVendorSoftwareProductInfoToVspDetailsDto.java new file mode 100644 index 0000000000..9f03f7ff0d --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapVersionedVendorSoftwareProductInfoToVspDetailsDto.java @@ -0,0 +1,74 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vsp.rest.mapping; + +import org.openecomp.core.utilities.CommonMethods; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.VspDetails; +import org.openecomp.sdc.vendorsoftwareproduct.types.LicensingData; +import org.openecomp.sdc.vendorsoftwareproduct.types.VersionedVendorSoftwareProductInfo; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.VspDetailsDto; + +import java.util.stream.Collectors; + +public class MapVersionedVendorSoftwareProductInfoToVspDetailsDto + extends MappingBase { + + @Override + public void doMapping(VersionedVendorSoftwareProductInfo source, VspDetailsDto target) { + VspDetails vsp = source.getVspDetails(); + + target.setId(vsp.getId()); + target.setVersion(vsp.getVersion().toString()); + target.setName(vsp.getName()); + target.setDescription(vsp.getDescription()); + target.setCategory(vsp.getCategory()); + target.setSubCategory(vsp.getSubCategory()); + target.setVendorId(vsp.getVendorId()); + target.setVendorName(vsp.getVendorName()); + target.setLicensingVersion(vsp.getVlmVersion() == null ? null : vsp.getVlmVersion().toString()); + + if (vsp.getLicenseAgreement() != null || vsp.getFeatureGroups() != null) { + LicensingData licensingData = new LicensingData(); + licensingData.setLicenseAgreement(vsp.getLicenseAgreement()); + licensingData.setFeatureGroups(vsp.getFeatureGroups()); + target.setLicensingData(licensingData); + } + + target.setValidationData(vsp.getValidationDataStructure()); + + target.setStatus(source.getVersionInfo().getStatus()); + target.setLockingUser(source.getVersionInfo().getLockingUser()); + + if (!CommonMethods.isEmpty(source.getVersionInfo().getViewableVersions())) { + target.setViewableVersions( + source.getVersionInfo().getViewableVersions().stream().map(Version::toString) + .collect(Collectors.toList())); + } + + if (!CommonMethods.isEmpty(source.getVersionInfo().getFinalVersions())) { + target.setFinalVersions( + source.getVersionInfo().getFinalVersions().stream().map(Version::toString) + .collect(Collectors.toList())); + } + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapVspDescriptionDtoToVspDetails.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapVspDescriptionDtoToVspDetails.java new file mode 100644 index 0000000000..77093fe682 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MapVspDescriptionDtoToVspDetails.java @@ -0,0 +1,56 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vsp.rest.mapping; + +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.VspDetails; +import org.openecomp.sdc.vendorsoftwareproduct.types.LicensingData; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.VspDescriptionDto; + +import java.util.regex.Pattern; + +public class MapVspDescriptionDtoToVspDetails extends MappingBase { + + @Override + public void doMapping(VspDescriptionDto source, VspDetails target) { + target.setName(source.getName()); + target.setDescription(source.getDescription()); + target.setCategory(source.getCategory()); + target.setSubCategory(source.getSubCategory()); + target.setIcon(source.getIcon()); + target.setVendorName(source.getVendorName()); + target.setVendorId(source.getVendorId()); + + String vlmVersion = source.getLicensingVersion(); + if (vlmVersion != null) { + target.setVlmVersion( + Pattern.compile(Version.VERSION_REGEX).matcher(vlmVersion).find() ? Version + .valueOf(vlmVersion) : null); + } + + LicensingData licensingData = source.getLicensingData(); + if (licensingData != null) { + target.setLicenseAgreement(licensingData.getLicenseAgreement()); + target.setFeatureGroups(licensingData.getFeatureGroups()); + } + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MspVspDetailsToVspCreationDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MspVspDetailsToVspCreationDto.java new file mode 100644 index 0000000000..a2de1741a3 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/mapping/MspVspDetailsToVspCreationDto.java @@ -0,0 +1,32 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vsp.rest.mapping; + +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.VspDetails; +import org.openecomp.sdcrests.mapping.MappingBase; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.VspCreationDto; + +public class MspVspDetailsToVspCreationDto extends MappingBase { + @Override + public void doMapping(VspDetails source, VspCreationDto target) { + target.setVspId(source.getId()); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/services/ComponentProcessesImpl.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/services/ComponentProcessesImpl.java new file mode 100644 index 0000000000..2b16fea6c0 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/services/ComponentProcessesImpl.java @@ -0,0 +1,144 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vsp.rest.services; + +import org.apache.cxf.jaxrs.ext.multipart.Attachment; +import org.openecomp.sdc.vendorsoftwareproduct.VendorSoftwareProductManager; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.ProcessEntityDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.ProcessRequestDto; +import org.openecomp.sdcrests.vsp.rest.ComponentProcesses; +import org.openecomp.sdcrests.vsp.rest.mapping.MapProcessEntityToProcessEntityDto; +import org.openecomp.sdcrests.vsp.rest.mapping.MapProcessRequestDtoToProcessEntity; +import org.openecomp.sdcrests.wrappers.GenericCollectionWrapper; +import org.openecomp.sdcrests.wrappers.StringWrapperResponse; + +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.context.annotation.Scope; +import org.springframework.stereotype.Service; + +import java.io.File; +import java.io.InputStream; +import java.util.Collection; +import javax.inject.Named; +import javax.ws.rs.core.Response; + + +@Named +@Service("componentProcesses") +@Scope(value = "prototype") +public class ComponentProcessesImpl implements ComponentProcesses { + @Autowired + private VendorSoftwareProductManager vendorSoftwareProductManager; + + @Override + public Response list(String vspId, String componentId, String version, String user) { + Collection processes = vendorSoftwareProductManager + .listProcesses(vspId, Version.valueOf(version), componentId, user); + + MapProcessEntityToProcessEntityDto mapper = new MapProcessEntityToProcessEntityDto(); + GenericCollectionWrapper results = new GenericCollectionWrapper<>(); + for (ProcessEntity process : processes) { + results.add(mapper.applyMapping(process, ProcessEntityDto.class)); + } + + return Response.ok(results).build(); + } + + @Override + public Response deleteList(String vspId, String componentId, String user) { + vendorSoftwareProductManager.deleteProcesses(vspId, componentId, user); + return Response.ok().build(); + } + + @Override + public Response create(ProcessRequestDto request, String vspId, String componentId, String user) { + ProcessEntity process = + new MapProcessRequestDtoToProcessEntity().applyMapping(request, ProcessEntity.class); + process.setVspId(vspId); + process.setComponentId(componentId); + + ProcessEntity createdProcess = vendorSoftwareProductManager.createProcess(process, user); + return Response + .ok(createdProcess != null ? new StringWrapperResponse(createdProcess.getId()) : null) + .build(); + } + + @Override + public Response get(String vspId, String componentId, String processId, String version, + String user) { + ProcessEntity process = vendorSoftwareProductManager + .getProcess(vspId, Version.valueOf(version), componentId, processId, user); + ProcessEntityDto result = + new MapProcessEntityToProcessEntityDto().applyMapping(process, ProcessEntityDto.class); + return Response.ok(result).build(); + } + + @Override + public Response delete(String vspId, String componentId, String processId, String user) { + vendorSoftwareProductManager.deleteProcess(vspId, componentId, processId, user); + return Response.ok().build(); + } + + @Override + public Response update(ProcessRequestDto request, String vspId, String componentId, + String processId, String user) { + ProcessEntity processEntity = + new MapProcessRequestDtoToProcessEntity().applyMapping(request, ProcessEntity.class); + processEntity.setVspId(vspId); + processEntity.setComponentId(componentId); + processEntity.setId(processId); + + vendorSoftwareProductManager.updateProcess(processEntity, user); + return Response.ok().build(); + } + + @Override + public Response getUploadedFile(String vspId, String componentId, String processId, + String version, String user) { + File file = vendorSoftwareProductManager + .getProcessArtifact(vspId, Version.valueOf(version), componentId, processId, user); + + Response.ResponseBuilder response = Response.ok(file); + if (file == null) { + return Response.status(Response.Status.NOT_FOUND).build(); + } + response.header("Content-Disposition", "attachment; filename=" + file.getName()); + return response.build(); + } + + @Override + public Response deleteUploadedFile(String vspId, String componentId, String processId, + String user) { + vendorSoftwareProductManager.deleteProcessArtifact(vspId, componentId, processId, user); + return Response.ok().build(); + } + + @Override + public Response uploadFile(Attachment attachment, String vspId, String componentId, + String processId, String user) { + vendorSoftwareProductManager.uploadProcessArtifact(attachment.getObject(InputStream.class), + attachment.getContentDisposition().getParameter("filename"), vspId, componentId, processId, + user); + return Response.ok().build(); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/services/ComponentUploadsImpl.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/services/ComponentUploadsImpl.java new file mode 100644 index 0000000000..3cd384d7e7 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/services/ComponentUploadsImpl.java @@ -0,0 +1,87 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vsp.rest.services; + +import org.apache.cxf.jaxrs.ext.multipart.Attachment; +import org.openecomp.sdc.vendorsoftwareproduct.VendorSoftwareProductManager; +import org.openecomp.sdc.vendorsoftwareproduct.types.schemagenerator.MibUploadStatus; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.MibUploadStatusDto; +import org.openecomp.sdcrests.vsp.rest.ComponentUploads; +import org.openecomp.sdcrests.vsp.rest.mapping.MapMibUploadStatusToDto; + +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.context.annotation.Scope; +import org.springframework.stereotype.Service; +import org.springframework.validation.annotation.Validated; + +import java.io.InputStream; +import javax.inject.Named; +import javax.ws.rs.core.Response; + +@Named +@Service("componentUploads") +@Scope(value = "prototype") +@Validated +public class ComponentUploadsImpl implements ComponentUploads { + @Autowired + private VendorSoftwareProductManager vendorSoftwareProductManager; + + @Override + public Response uploadTrapMibFile(Attachment attachment, String vspId, String componentId, + String user) { + vendorSoftwareProductManager.uploadComponentMib(attachment.getObject(InputStream.class), + attachment.getContentDisposition().getParameter("filename"), vspId, componentId, true, + user); + return Response.ok().build(); + } + + @Override + public Response deleteTrapMibFile(String vspId, String componentId, String user) { + vendorSoftwareProductManager.deleteComponentMib(vspId, componentId, true, user); + return Response.ok().build(); + } + + @Override + public Response uploadPollMibFile(Attachment attachment, String vspId, String componentId, + String user) { + vendorSoftwareProductManager.uploadComponentMib(attachment.getObject(InputStream.class), + attachment.getContentDisposition().getParameter("filename"), vspId, componentId, false, + user); + return Response.ok().build(); + } + + @Override + public Response deletePollMibFile(String vspId, String componentId, String user) { + vendorSoftwareProductManager.deleteComponentMib(vspId, componentId, false, user); + return Response.ok().build(); + } + + @Override + public Response list(String vspId, String componentId, String user) { + MibUploadStatus response = + vendorSoftwareProductManager.listMibFilenames(vspId, componentId, user); + + MibUploadStatusDto returnEntity = + new MapMibUploadStatusToDto().applyMapping(response, MibUploadStatusDto.class); + return Response.status(Response.Status.OK).entity(returnEntity).build(); + + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/services/ComponentsImpl.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/services/ComponentsImpl.java new file mode 100644 index 0000000000..cba9abbdbc --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/services/ComponentsImpl.java @@ -0,0 +1,145 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vsp.rest.services; + +import org.apache.commons.collections4.CollectionUtils; +import org.openecomp.sdc.vendorsoftwareproduct.VendorSoftwareProductManager; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity; +import org.openecomp.sdc.vendorsoftwareproduct.types.CompositionEntityResponse; +import org.openecomp.sdc.vendorsoftwareproduct.types.CompositionEntityValidationData; +import org.openecomp.sdc.vendorsoftwareproduct.types.QuestionnaireResponse; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.ComponentData; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.ComponentDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.ComponentRequestDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.CompositionEntityResponseDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.CompositionEntityValidationDataDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.QuestionnaireResponseDto; +import org.openecomp.sdcrests.vsp.rest.Components; +import org.openecomp.sdcrests.vsp.rest.mapping.MapComponentDataToComponentDto; +import org.openecomp.sdcrests.vsp.rest.mapping.MapComponentEntityToComponentDto; +import org.openecomp.sdcrests.vsp.rest.mapping.MapComponentRequestDtoToComponentEntity; +import org.openecomp.sdcrests.vsp.rest.mapping.MapCompositionEntityResponseToDto; +import org.openecomp.sdcrests.vsp.rest.mapping.MapCompositionEntityValidationDataToDto; +import org.openecomp.sdcrests.vsp.rest.mapping.MapQuestionnaireResponseToQuestionnaireResponseDto; +import org.openecomp.sdcrests.wrappers.GenericCollectionWrapper; +import org.openecomp.sdcrests.wrappers.StringWrapperResponse; + +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.context.annotation.Scope; +import org.springframework.stereotype.Service; + +import java.util.Collection; +import javax.inject.Named; +import javax.ws.rs.core.Response; + + +@Named +@Service("components") +@Scope(value = "prototype") +public class ComponentsImpl implements Components { + @Autowired + private VendorSoftwareProductManager vendorSoftwareProductManager; + + @Override + public Response list(String vspId, String version, String user) { + Collection components = + vendorSoftwareProductManager.listComponents(vspId, Version.valueOf(version), user); + + MapComponentEntityToComponentDto mapper = new MapComponentEntityToComponentDto(); + GenericCollectionWrapper results = new GenericCollectionWrapper<>(); + for (ComponentEntity component : components) { + results.add(mapper.applyMapping(component, ComponentDto.class)); + } + + return Response.ok(results).build(); + } + + @Override + public Response deleteList(String vspId, String user) { + vendorSoftwareProductManager.deleteComponents(vspId, user); + return Response.ok().build(); + } + + @Override + public Response create(ComponentRequestDto request, String vspId, String user) { + ComponentEntity component = + new MapComponentRequestDtoToComponentEntity().applyMapping(request, ComponentEntity.class); + component.setVspId(vspId); + ComponentEntity createdComponent = + vendorSoftwareProductManager.createComponent(component, user); + return Response + .ok(createdComponent != null ? new StringWrapperResponse(createdComponent.getId()) : null) + .build(); + } + + @Override + public Response get(String vspId, String componentId, String version, String user) { + CompositionEntityResponse response = vendorSoftwareProductManager + .getComponent(vspId, Version.valueOf(version), componentId, user); + + CompositionEntityResponseDto responseDto = new CompositionEntityResponseDto<>(); + new MapCompositionEntityResponseToDto<>(new MapComponentDataToComponentDto(), + ComponentDto.class).doMapping(response, responseDto); + return Response.ok(responseDto).build(); + } + + @Override + public Response delete(String vspId, String componentId, String user) { + vendorSoftwareProductManager.deleteComponent(vspId, componentId, user); + return Response.ok().build(); + } + + @Override + public Response update(ComponentRequestDto request, String vspId, String componentId, + String user) { + ComponentEntity componentEntity = + new MapComponentRequestDtoToComponentEntity().applyMapping(request, ComponentEntity.class); + componentEntity.setVspId(vspId); + componentEntity.setId(componentId); + + CompositionEntityValidationData validationData = + vendorSoftwareProductManager.updateComponent(componentEntity, user); + return validationData != null && CollectionUtils.isNotEmpty(validationData.getErrors()) + ? Response.status(Response.Status.EXPECTATION_FAILED).entity( + new MapCompositionEntityValidationDataToDto() + .applyMapping(validationData, CompositionEntityValidationDataDto.class)).build() : + Response.ok().build(); + } + + @Override + public Response getQuestionnaire(String vspId, String componentId, String version, String user) { + QuestionnaireResponse questionnaireResponse = vendorSoftwareProductManager + .getComponentQuestionnaire(vspId, Version.valueOf(version), componentId, user); + + QuestionnaireResponseDto result = new MapQuestionnaireResponseToQuestionnaireResponseDto() + .applyMapping(questionnaireResponse, QuestionnaireResponseDto.class); + return Response.ok(result).build(); + } + + @Override + public Response updateQuestionnaire(String questionnaireData, String vspId, String componentId, + String user) { + vendorSoftwareProductManager + .updateComponentQuestionnaire(vspId, componentId, questionnaireData, user); + return Response.ok().build(); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/services/NetworksImpl.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/services/NetworksImpl.java new file mode 100644 index 0000000000..afc25ab4b0 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/services/NetworksImpl.java @@ -0,0 +1,115 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vsp.rest.services; + +import org.apache.commons.collections4.CollectionUtils; +import org.openecomp.sdc.vendorsoftwareproduct.VendorSoftwareProductManager; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.NetworkEntity; +import org.openecomp.sdc.vendorsoftwareproduct.types.CompositionEntityResponse; +import org.openecomp.sdc.vendorsoftwareproduct.types.CompositionEntityValidationData; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.Network; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.CompositionEntityResponseDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.CompositionEntityValidationDataDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.NetworkDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.NetworkRequestDto; +import org.openecomp.sdcrests.vsp.rest.Networks; +import org.openecomp.sdcrests.vsp.rest.mapping.MapCompositionEntityResponseToDto; +import org.openecomp.sdcrests.vsp.rest.mapping.MapCompositionEntityValidationDataToDto; +import org.openecomp.sdcrests.vsp.rest.mapping.MapNetworkEntityToNetworkDto; +import org.openecomp.sdcrests.vsp.rest.mapping.MapNetworkRequestDtoToNetworkEntity; +import org.openecomp.sdcrests.vsp.rest.mapping.MapNetworkToNetworkDto; +import org.openecomp.sdcrests.wrappers.GenericCollectionWrapper; +import org.openecomp.sdcrests.wrappers.StringWrapperResponse; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.context.annotation.Scope; +import org.springframework.stereotype.Service; + +import java.util.Collection; +import javax.inject.Named; +import javax.ws.rs.core.Response; + + +@Named +@Service("networks") +@Scope(value = "prototype") +public class NetworksImpl implements Networks { + @Autowired + private VendorSoftwareProductManager vendorSoftwareProductManager; + + @Override + public Response list(String vspId, String version, String user) { + Collection networks = + vendorSoftwareProductManager.listNetworks(vspId, Version.valueOf(version), user); + + MapNetworkEntityToNetworkDto mapper = new MapNetworkEntityToNetworkDto(); + GenericCollectionWrapper results = new GenericCollectionWrapper<>(); + for (NetworkEntity network : networks) { + results.add(mapper.applyMapping(network, NetworkDto.class)); + } + + return Response.ok(results).build(); + } + + @Override + public Response create(NetworkRequestDto request, String vspId, String user) { + NetworkEntity network = + new MapNetworkRequestDtoToNetworkEntity().applyMapping(request, NetworkEntity.class); + network.setVspId(vspId); + NetworkEntity createdNetwork = vendorSoftwareProductManager.createNetwork(network, user); + return Response + .ok(createdNetwork != null ? new StringWrapperResponse(createdNetwork.getId()) : null) + .build(); + } + + @Override + public Response get(String vspId, String networkId, String version, String user) { + CompositionEntityResponse response = + vendorSoftwareProductManager.getNetwork(vspId, Version.valueOf(version), networkId, user); + + CompositionEntityResponseDto responseDto = new CompositionEntityResponseDto<>(); + new MapCompositionEntityResponseToDto<>(new MapNetworkToNetworkDto(), NetworkDto.class) + .doMapping(response, responseDto); + return Response.ok(responseDto).build(); + } + + @Override + public Response delete(String vspId, String networkId, String user) { + vendorSoftwareProductManager.deleteNetwork(vspId, networkId, user); + return Response.ok().build(); + } + + @Override + public Response update(NetworkRequestDto request, String vspId, String networkId, String user) { + NetworkEntity networkEntity = + new MapNetworkRequestDtoToNetworkEntity().applyMapping(request, NetworkEntity.class); + networkEntity.setVspId(vspId); + networkEntity.setId(networkId); + + CompositionEntityValidationData validationData = + vendorSoftwareProductManager.updateNetwork(networkEntity, user); + return validationData != null && CollectionUtils.isNotEmpty(validationData.getErrors()) + ? Response.status(Response.Status.EXPECTATION_FAILED).entity( + new MapCompositionEntityValidationDataToDto() + .applyMapping(validationData, CompositionEntityValidationDataDto.class)).build() : + Response.ok().build(); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/services/NicsImpl.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/services/NicsImpl.java new file mode 100644 index 0000000000..ce601ec999 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/services/NicsImpl.java @@ -0,0 +1,140 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vsp.rest.services; + +import org.apache.commons.collections4.CollectionUtils; +import org.openecomp.sdc.vendorsoftwareproduct.VendorSoftwareProductManager; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity; +import org.openecomp.sdc.vendorsoftwareproduct.types.CompositionEntityResponse; +import org.openecomp.sdc.vendorsoftwareproduct.types.CompositionEntityValidationData; +import org.openecomp.sdc.vendorsoftwareproduct.types.QuestionnaireResponse; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.Nic; +import org.openecomp.sdc.versioning.dao.types.Version; + +import org.openecomp.sdcrests.vendorsoftwareproducts.types.CompositionEntityResponseDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.CompositionEntityValidationDataDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.NicDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.NicRequestDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.QuestionnaireResponseDto; +import org.openecomp.sdcrests.vsp.rest.Nics; +import org.openecomp.sdcrests.vsp.rest.mapping.MapCompositionEntityResponseToDto; +import org.openecomp.sdcrests.vsp.rest.mapping.MapCompositionEntityValidationDataToDto; +import org.openecomp.sdcrests.vsp.rest.mapping.MapNicEntityToNicDto; +import org.openecomp.sdcrests.vsp.rest.mapping.MapNicRequestDtoToNicEntity; +import org.openecomp.sdcrests.vsp.rest.mapping.MapNicToNicDto; +import org.openecomp.sdcrests.vsp.rest.mapping.MapQuestionnaireResponseToQuestionnaireResponseDto; +import org.openecomp.sdcrests.wrappers.GenericCollectionWrapper; +import org.openecomp.sdcrests.wrappers.StringWrapperResponse; + +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.context.annotation.Scope; +import org.springframework.stereotype.Service; + +import java.util.Collection; +import javax.inject.Named; +import javax.ws.rs.core.Response; + + +@Named +@Service("nics") +@Scope(value = "prototype") +public class NicsImpl implements Nics { + @Autowired + private VendorSoftwareProductManager vendorSoftwareProductManager; + + @Override + public Response list(String vspId, String componentId, String version, String user) { + Collection nics = + vendorSoftwareProductManager.listNics(vspId, Version.valueOf(version), componentId, user); + + MapNicEntityToNicDto mapper = new MapNicEntityToNicDto(); + GenericCollectionWrapper results = new GenericCollectionWrapper<>(); + for (NicEntity nic : nics) { + results.add(mapper.applyMapping(nic, NicDto.class)); + } + + return Response.ok(results).build(); + } + + @Override + public Response create(NicRequestDto request, String vspId, String componentId, String user) { + NicEntity nic = new MapNicRequestDtoToNicEntity().applyMapping(request, NicEntity.class); + nic.setVspId(vspId); + nic.setComponentId(componentId); + + NicEntity createdNic = vendorSoftwareProductManager.createNic(nic, user); + return Response.ok(createdNic != null ? new StringWrapperResponse(createdNic.getId()) : null) + .build(); + } + + @Override + public Response get(String vspId, String componentId, String nicId, String version, String user) { + CompositionEntityResponse response = vendorSoftwareProductManager + .getNic(vspId, Version.valueOf(version), componentId, nicId, user); + + CompositionEntityResponseDto responseDto = new CompositionEntityResponseDto<>(); + new MapCompositionEntityResponseToDto<>(new MapNicToNicDto(), NicDto.class) + .doMapping(response, responseDto); + return Response.ok(responseDto).build(); + } + + @Override + public Response delete(String vspId, String componentId, String nicId, String user) { + vendorSoftwareProductManager.deleteNic(vspId, componentId, nicId, user); + return Response.ok().build(); + } + + @Override + public Response update(NicRequestDto request, String vspId, String componentId, String nicId, + String user) { + NicEntity nicEntity = new MapNicRequestDtoToNicEntity().applyMapping(request, NicEntity.class); + nicEntity.setVspId(vspId); + nicEntity.setComponentId(componentId); + nicEntity.setId(nicId); + + CompositionEntityValidationData validationData = + vendorSoftwareProductManager.updateNic(nicEntity, user); + return validationData != null && CollectionUtils.isNotEmpty(validationData.getErrors()) + ? Response.status(Response.Status.EXPECTATION_FAILED).entity( + new MapCompositionEntityValidationDataToDto() + .applyMapping(validationData, CompositionEntityValidationDataDto.class)).build() : + Response.ok().build(); + } + + @Override + public Response getQuestionnaire(String vspId, String componentId, String nicId, String version, + String user) { + QuestionnaireResponse questionnaireResponse = vendorSoftwareProductManager + .getNicQuestionnaire(vspId, Version.valueOf(version), componentId, nicId, user); + + QuestionnaireResponseDto result = new MapQuestionnaireResponseToQuestionnaireResponseDto() + .applyMapping(questionnaireResponse, QuestionnaireResponseDto.class); + return Response.ok(result).build(); + } + + @Override + public Response updateQuestionnaire(String questionnaireData, String vspId, String componentId, + String nicId, String user) { + vendorSoftwareProductManager + .updateNicQuestionnaire(vspId, componentId, nicId, questionnaireData, user); + return Response.ok().build(); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/services/ProcessesImpl.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/services/ProcessesImpl.java new file mode 100644 index 0000000000..004d84591a --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/services/ProcessesImpl.java @@ -0,0 +1,89 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vsp.rest.services; + +import static org.openecomp.sdc.vendorsoftwareproduct.VendorSoftwareProductConstants.GENERAL_COMPONENT_ID; + +import org.apache.cxf.jaxrs.ext.multipart.Attachment; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.ProcessRequestDto; +import org.openecomp.sdcrests.vsp.rest.ComponentProcesses; +import org.openecomp.sdcrests.vsp.rest.Processes; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.context.annotation.Scope; +import org.springframework.stereotype.Service; + +import javax.inject.Named; +import javax.ws.rs.core.Response; + +@Named +@Service("processes") +@Scope(value = "prototype") +public class ProcessesImpl implements Processes { + + @Autowired + private ComponentProcesses componentProcesses; + + @Override + public Response list(String vspId, String version, String user) { + return componentProcesses.list(vspId, GENERAL_COMPONENT_ID, version, user); + } + + @Override + public Response deleteList(String vspId, String user) { + return componentProcesses.deleteList(vspId, GENERAL_COMPONENT_ID, user); + } + + @Override + public Response create(ProcessRequestDto request, String vspId, String user) { + return componentProcesses.create(request, vspId, GENERAL_COMPONENT_ID, user); + } + + @Override + public Response get(String vspId, String processId, String version, String user) { + return componentProcesses.get(vspId, GENERAL_COMPONENT_ID, processId, version, user); + } + + @Override + public Response delete(String vspId, String processId, String user) { + return componentProcesses.delete(vspId, GENERAL_COMPONENT_ID, processId, user); + } + + @Override + public Response update(ProcessRequestDto request, String vspId, String processId, String user) { + return componentProcesses.update(request, vspId, GENERAL_COMPONENT_ID, processId, user); + } + + @Override + public Response getUploadedFile(String vspId, String processId, String version, String user) { + return componentProcesses + .getUploadedFile(vspId, GENERAL_COMPONENT_ID, processId, version, user); + } + + @Override + public Response deleteUploadedFile(String vspId, String processId, String user) { + return componentProcesses.deleteUploadedFile(vspId, GENERAL_COMPONENT_ID, processId, user); + } + + @Override + public Response uploadFile(Attachment attachment, String vspId, String processId, String user) { + return componentProcesses.uploadFile(attachment, vspId, GENERAL_COMPONENT_ID, processId, user); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/services/VendorSoftwareProductsImpl.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/services/VendorSoftwareProductsImpl.java new file mode 100644 index 0000000000..1c13f172f1 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/main/java/org/openecomp/sdcrests/vsp/rest/services/VendorSoftwareProductsImpl.java @@ -0,0 +1,228 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vsp.rest.services; + +import org.openecomp.sdc.vendorsoftwareproduct.VendorSoftwareProductManager; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.PackageInfo; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.VspDetails; +import org.openecomp.sdc.vendorsoftwareproduct.types.QuestionnaireResponse; +import org.openecomp.sdc.vendorsoftwareproduct.types.UploadFileResponse; +import org.openecomp.sdc.vendorsoftwareproduct.types.ValidationResponse; +import org.openecomp.sdc.vendorsoftwareproduct.types.VersionedVendorSoftwareProductInfo; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.PackageInfoDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.QuestionnaireResponseDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.UploadFileResponseDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.ValidationResponseDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.VersionSoftwareProductActionRequestDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.VspCreationDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.VspDescriptionDto; +import org.openecomp.sdcrests.vendorsoftwareproducts.types.VspDetailsDto; +import org.openecomp.sdcrests.vsp.rest.VendorSoftwareProducts; +import org.openecomp.sdcrests.vsp.rest.mapping.MapPackageInfoToPackageInfoDto; +import org.openecomp.sdcrests.vsp.rest.mapping.MapQuestionnaireResponseToQuestionnaireResponseDto; +import org.openecomp.sdcrests.vsp.rest.mapping.MapUploadFileResponseToUploadFileResponseDto; +import org.openecomp.sdcrests.vsp.rest.mapping.MapValidationResponseToDto; +import org.openecomp.sdcrests.vsp.rest.mapping.MapVersionedVendorSoftwareProductInfoToVspDetailsDto; +import org.openecomp.sdcrests.vsp.rest.mapping.MapVspDescriptionDtoToVspDetails; +import org.openecomp.sdcrests.vsp.rest.mapping.MspVspDetailsToVspCreationDto; +import org.openecomp.sdcrests.wrappers.GenericCollectionWrapper; + +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.context.annotation.Scope; +import org.springframework.stereotype.Service; + +import java.io.File; +import java.io.IOException; +import java.io.InputStream; +import java.util.List; +import javax.inject.Named; +import javax.ws.rs.core.Response; + +@Named +@Service("vendorSoftwareProducts") +@Scope(value = "prototype") +public class VendorSoftwareProductsImpl implements VendorSoftwareProducts { + + @Autowired + private VendorSoftwareProductManager vendorSoftwareProductManager; + + @Override + public Response createNewVsp(VspDescriptionDto vspDescriptionDto, String user) { + VspDetails vspDetails = + new MapVspDescriptionDtoToVspDetails().applyMapping(vspDescriptionDto, VspDetails.class); + + vspDetails = vendorSoftwareProductManager.createNewVsp(vspDetails, user); + + MspVspDetailsToVspCreationDto mapping = new MspVspDetailsToVspCreationDto(); + VspCreationDto vspCreationDto = mapping.applyMapping(vspDetails, VspCreationDto.class); + + return Response.ok(vspCreationDto).build(); + } + + @Override + public Response getVspList(String versionFilter, String user) { + List vspList = + vendorSoftwareProductManager.getVspList(versionFilter, user); + + GenericCollectionWrapper results = new GenericCollectionWrapper<>(); + if (!vspList.isEmpty()) { + MapVersionedVendorSoftwareProductInfoToVspDetailsDto mapper = + new MapVersionedVendorSoftwareProductInfoToVspDetailsDto(); + for (VersionedVendorSoftwareProductInfo versionedVsp : vspList) { + results.add(mapper.applyMapping(versionedVsp, VspDetailsDto.class)); + } + } + + return Response.ok(results).build(); + } + + @Override + public Response getVspDetails(String vspId, String version, String user) { + VersionedVendorSoftwareProductInfo vspDetails = + vendorSoftwareProductManager.getVspDetails(vspId, Version.valueOf(version), user); + + VspDetailsDto vspDetailsDto = vspDetails == null ? null + : new MapVersionedVendorSoftwareProductInfoToVspDetailsDto() + .applyMapping(vspDetails, VspDetailsDto.class); + + return Response.ok(vspDetailsDto).build(); + } + + @Override + public Response updateVsp(String vspId, VspDescriptionDto vspDescriptionDto, String user) { + VspDetails vspDetails = + new MapVspDescriptionDtoToVspDetails().applyMapping(vspDescriptionDto, VspDetails.class); + vspDetails.setId(vspId); + + vendorSoftwareProductManager.updateVsp(vspDetails, user); + + return Response.ok().build(); + } + + @Override + public Response deleteVsp(String vspId, String user) { + vendorSoftwareProductManager.deleteVsp(vspId, user); + + return Response.ok().build(); + } + + @Override + public Response actOnVendorSoftwareProduct(String vspId, + VersionSoftwareProductActionRequestDto request, + String user) throws IOException { + switch (request.getAction()) { + case Checkout: + vendorSoftwareProductManager.checkout(vspId, user); + break; + case Undo_Checkout: + vendorSoftwareProductManager.undoCheckout(vspId, user); + break; + case Checkin: + vendorSoftwareProductManager.checkin(vspId, user); + break; + case Submit: + ValidationResponse validationResponse = vendorSoftwareProductManager.submit(vspId, user); + if (!validationResponse.isValid()) { + return Response.status(Response.Status.EXPECTATION_FAILED).entity( + new MapValidationResponseToDto() + .applyMapping(validationResponse, ValidationResponseDto.class)).build(); + } + break; + case Create_Package: + PackageInfo packageInfo = vendorSoftwareProductManager.createPackage(vspId, user); + return Response.ok(packageInfo == null ? null + : new MapPackageInfoToPackageInfoDto().applyMapping(packageInfo, PackageInfoDto.class)) + .build(); + default: + } + + return Response.ok().build(); + } + + @Override + public Response uploadFile(String uploadVspId, InputStream heatFileToUpload, String user) { + UploadFileResponse uploadFileResponse = + vendorSoftwareProductManager.uploadFile(uploadVspId, heatFileToUpload, user); + + UploadFileResponseDto uploadFileResponseDto = new MapUploadFileResponseToUploadFileResponseDto() + .applyMapping(uploadFileResponse, UploadFileResponseDto.class); + + return Response.ok(uploadFileResponseDto).build(); + } + + @Override + public Response getLatestHeatPackage(String vspId, String user) { + File zipFile = vendorSoftwareProductManager.getLatestHeatPackage(vspId, user); + + if (zipFile == null) { + return Response.status(Response.Status.NOT_FOUND).build(); + } + Response.ResponseBuilder response = Response.ok(zipFile); + response.header("Content-Disposition", "attachment; filename=" + zipFile.getName()); + return response.build(); + } + + @Override + public Response listPackages(String category, String subCategory, String user) { + List packageInfoList = + vendorSoftwareProductManager.listPackages(category, subCategory); + + GenericCollectionWrapper results = new GenericCollectionWrapper<>(); + MapPackageInfoToPackageInfoDto mapper = new MapPackageInfoToPackageInfoDto(); + + if (packageInfoList != null) { + for (PackageInfo packageInfo : packageInfoList) { + results.add(mapper.applyMapping(packageInfo, PackageInfoDto.class)); + } + } + return Response.ok(results).build(); + } + + @Override + public Response getTranslatedFile(String vspId, String version, String user) { + File zipFile = + vendorSoftwareProductManager.getTranslatedFile(vspId, Version.valueOf(version), user); + + Response.ResponseBuilder response = Response.ok(zipFile); + if (zipFile == null) { + return Response.status(Response.Status.NOT_FOUND).build(); + } + response.header("Content-Disposition", "attachment; filename=" + zipFile.getName()); + return response.build(); + } + + @Override + public Response getQuestionnaire(String vspId, String version, String user) { + QuestionnaireResponse questionnaireResponse = + vendorSoftwareProductManager.getVspQuestionnaire(vspId, Version.valueOf(version), user); + + QuestionnaireResponseDto result = new MapQuestionnaireResponseToQuestionnaireResponseDto() + .applyMapping(questionnaireResponse, QuestionnaireResponseDto.class); + return Response.ok(result).build(); + } + + @Override + public Response updateQuestionnaire(String questionnaireData, String vspId, String user) { + vendorSoftwareProductManager.updateVspQuestionnaire(vspId, questionnaireData, user); + return Response.ok().build(); + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/pom.xml b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/pom.xml new file mode 100644 index 0000000000..d68c2b9034 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/pom.xml @@ -0,0 +1,32 @@ + + + 4.0.0 + + + org.openecomp.sdc.onboarding + vendor-software-products-rest + 1.0.0-SNAPSHOT + ../ + + + vendor-software-products-rest-types + vendor-software-products-rest-types + + + + + + org.openecomp.sdc + openecomp-sdc-common-rest + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-vendor-software-product-manager + ${project.version} + + + + \ No newline at end of file diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/ComponentDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/ComponentDto.java new file mode 100644 index 0000000000..63b7e6ea7d --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/ComponentDto.java @@ -0,0 +1,35 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorsoftwareproducts.types; + +public class ComponentDto extends ComponentRequestDto implements CompositionDataEntityDto { + + private String id; + + public String getId() { + return id; + } + + public void setId(String id) { + this.id = id; + } + +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/ComponentRequestDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/ComponentRequestDto.java new file mode 100644 index 0000000000..f626dab072 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/ComponentRequestDto.java @@ -0,0 +1,53 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorsoftwareproducts.types; + +public class ComponentRequestDto { + + private String name; + private String displayName; + private String description; + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getDisplayName() { + return displayName; + } + + public void setDisplayName(String displayName) { + this.displayName = displayName; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/CompositionDataEntityDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/CompositionDataEntityDto.java new file mode 100644 index 0000000000..8eb1c6557f --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/CompositionDataEntityDto.java @@ -0,0 +1,24 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorsoftwareproducts.types; + +public interface CompositionDataEntityDto { +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/CompositionEntityResponseDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/CompositionEntityResponseDto.java new file mode 100644 index 0000000000..6e25e35d9b --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/CompositionEntityResponseDto.java @@ -0,0 +1,51 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorsoftwareproducts.types; + +public class CompositionEntityResponseDto { + private String id; + private String schema; + private T data; + + public String getId() { + return id; + } + + public void setId(String id) { + this.id = id; + } + + public String getSchema() { + return schema; + } + + public void setSchema(String schema) { + this.schema = schema; + } + + public T getData() { + return data; + } + + public void setData(T data) { + this.data = data; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/CompositionEntityValidationDataDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/CompositionEntityValidationDataDto.java new file mode 100644 index 0000000000..20e07880c4 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/CompositionEntityValidationDataDto.java @@ -0,0 +1,65 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorsoftwareproducts.types; + +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionEntityType; + +import java.util.Collection; + +public class CompositionEntityValidationDataDto { + private CompositionEntityType entityType; + private String entityId; + private Collection errors; + private Collection subEntitiesValidationData; + + public CompositionEntityType getEntityType() { + return entityType; + } + + public void setEntityType(CompositionEntityType entityType) { + this.entityType = entityType; + } + + public String getEntityId() { + return entityId; + } + + public void setEntityId(String entityId) { + this.entityId = entityId; + } + + public Collection getErrors() { + return errors; + } + + public void setErrors(Collection errors) { + this.errors = errors; + } + + public Collection getSubEntitiesValidationData() { + return subEntitiesValidationData; + } + + public void setSubEntitiesValidationData( + Collection subEntitiesValidationData) { + this.subEntitiesValidationData = subEntitiesValidationData; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/MibUploadStatusDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/MibUploadStatusDto.java new file mode 100644 index 0000000000..7331115c3f --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/MibUploadStatusDto.java @@ -0,0 +1,46 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorsoftwareproducts.types; + +public class MibUploadStatusDto { + private String snmpTrap; + private String snmpPoll; + + + public MibUploadStatusDto() { + } + + public String getSnmpTrap() { + return snmpTrap; + } + + public void setSnmpTrap(String snmpTrap) { + this.snmpTrap = snmpTrap; + } + + public String getSnmpPoll() { + return snmpPoll; + } + + public void setSnmpPoll(String snmpPoll) { + this.snmpPoll = snmpPoll; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/NetworkDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/NetworkDto.java new file mode 100644 index 0000000000..09ff449a52 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/NetworkDto.java @@ -0,0 +1,34 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorsoftwareproducts.types; + +public class NetworkDto extends NetworkRequestDto implements CompositionDataEntityDto { + + private String id; + + public String getId() { + return id; + } + + public void setId(String id) { + this.id = id; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/NetworkRequestDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/NetworkRequestDto.java new file mode 100644 index 0000000000..896ea22207 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/NetworkRequestDto.java @@ -0,0 +1,47 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorsoftwareproducts.types; + +import javax.validation.constraints.NotNull; + +public class NetworkRequestDto { + + @NotNull + private String name; + @NotNull + private boolean dhcp; + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public boolean isDhcp() { + return dhcp; + } + + public void setDhcp(boolean dhcp) { + this.dhcp = dhcp; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/NicDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/NicDto.java new file mode 100644 index 0000000000..05cd9a3a2b --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/NicDto.java @@ -0,0 +1,43 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorsoftwareproducts.types; + +public class NicDto extends NicRequestDto implements CompositionDataEntityDto { + + private String id; + private String networkName; + + public String getId() { + return id; + } + + public void setId(String id) { + this.id = id; + } + + public String getNetworkName() { + return networkName; + } + + public void setNetworkName(String networkName) { + this.networkName = networkName; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/NicRequestDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/NicRequestDto.java new file mode 100644 index 0000000000..bd14012eee --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/NicRequestDto.java @@ -0,0 +1,52 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorsoftwareproducts.types; + +public class NicRequestDto { + + private String name; + private String description; + private String networkId; + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public String getNetworkId() { + return networkId; + } + + public void setNetworkId(String networkId) { + this.networkId = networkId; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/PackageInfoDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/PackageInfoDto.java new file mode 100644 index 0000000000..5e689f3a0c --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/PackageInfoDto.java @@ -0,0 +1,124 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorsoftwareproducts.types; + +public class PackageInfoDto { + + private String displayName; + private String description; + private String vspName; + private String version; + private String packageId; + private String category; + private String subCategory; + private String vendorName; + private String vendorRelease; + private String packageChecksum; + private String packageType; + + public String getDisplayName() { + return displayName; + } + + public void setDisplayName(String displayName) { + this.displayName = displayName; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public String getVersion() { + return version; + } + + public void setVersion(String version) { + this.version = version; + } + + public String getPackageId() { + return packageId; + } + + public void setPackageId(String packageId) { + this.packageId = packageId; + } + + public String getCategory() { + return category; + } + + public void setCategory(String category) { + this.category = category; + } + + public String getSubCategory() { + return subCategory; + } + + public void setSubCategory(String subCategory) { + this.subCategory = subCategory; + } + + public String getVendorName() { + return vendorName; + } + + public void setVendorName(String vendorName) { + this.vendorName = vendorName; + } + + public String getVendorRelease() { + return vendorRelease; + } + + public void setVendorRelease(String vendorRelease) { + this.vendorRelease = vendorRelease; + } + + public String getPackageChecksum() { + return packageChecksum; + } + + public void setPackageChecksum(String packageChecksum) { + this.packageChecksum = packageChecksum; + } + + public String getPackageType() { + return packageType; + } + + public void setPackageType(String packageType) { + this.packageType = packageType; + } + + public String getVspName() { + return vspName; + } + + public void setVspName(String vendorName) { + this.vspName = vendorName; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/ProcessEntityDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/ProcessEntityDto.java new file mode 100644 index 0000000000..50923ff2e8 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/ProcessEntityDto.java @@ -0,0 +1,42 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorsoftwareproducts.types; + +public class ProcessEntityDto extends ProcessRequestDto { + private String id; + private String artifactName; + + public String getId() { + return id; + } + + public void setId(String id) { + this.id = id; + } + + public String getArtifactName() { + return artifactName; + } + + public void setArtifactName(String artifactName) { + this.artifactName = artifactName; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/ProcessRequestDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/ProcessRequestDto.java new file mode 100644 index 0000000000..e9c99b9d65 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/ProcessRequestDto.java @@ -0,0 +1,47 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorsoftwareproducts.types; + +import javax.validation.constraints.NotNull; + +public class ProcessRequestDto { + + @NotNull + private String name; + + private String description; + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/QuestionnaireResponseDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/QuestionnaireResponseDto.java new file mode 100644 index 0000000000..81377764c2 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/QuestionnaireResponseDto.java @@ -0,0 +1,42 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorsoftwareproducts.types; + +public class QuestionnaireResponseDto { + private String schema; + private String data; + + public String getSchema() { + return schema; + } + + public void setSchema(String schema) { + this.schema = schema; + } + + public String getData() { + return data; + } + + public void setData(String data) { + this.data = data; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/QuestionnaireValidationResultDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/QuestionnaireValidationResultDto.java new file mode 100644 index 0000000000..bf4805a9e1 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/QuestionnaireValidationResultDto.java @@ -0,0 +1,42 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorsoftwareproducts.types; + +public class QuestionnaireValidationResultDto { + private boolean valid; + private CompositionEntityValidationDataDto validationData; + + public boolean isValid() { + return valid; + } + + public void setValid(boolean valid) { + this.valid = valid; + } + + public CompositionEntityValidationDataDto getValidationData() { + return validationData; + } + + public void setValidationData(CompositionEntityValidationDataDto validationData) { + this.validationData = validationData; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/TranslatedFileDataDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/TranslatedFileDataDto.java new file mode 100644 index 0000000000..975f78d473 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/TranslatedFileDataDto.java @@ -0,0 +1,97 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorsoftwareproducts.types; + +public class TranslatedFileDataDto { + + private String displayName; + private String version; + private String category; + private String subcategory; + private String vendorName; + private String vendorRelease; + private String packageChecksum; + private String packageType; + + public String getDisplayName() { + return displayName; + } + + public void setDisplayName(String displayName) { + this.displayName = displayName; + } + + public String getVersion() { + return version; + } + + public void setVersion(String version) { + this.version = version; + } + + public String getCategory() { + return category; + } + + public void setCategory(String category) { + this.category = category; + } + + public String getSubcategory() { + return subcategory; + } + + public void setSubcategory(String subcategory) { + this.subcategory = subcategory; + } + + public String getVandorName() { + return vendorName; + } + + public void setVandorName(String vandorName) { + this.vendorName = vandorName; + } + + public String getVendorRelease() { + return vendorRelease; + } + + public void setVendorRelease(String vendorRelease) { + this.vendorRelease = vendorRelease; + } + + public String getPackageChecksum() { + return packageChecksum; + } + + public void setPackageChecksum(String packageChecksum) { + this.packageChecksum = packageChecksum; + } + + public String getPackageType() { + return packageType; + } + + public void setPackageType(String packageType) { + this.packageType = packageType; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/UploadFileResponseDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/UploadFileResponseDto.java new file mode 100644 index 0000000000..4f57b8031f --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/UploadFileResponseDto.java @@ -0,0 +1,63 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorsoftwareproducts.types; + +import org.openecomp.sdc.datatypes.error.ErrorMessage; +import org.openecomp.sdc.vendorsoftwareproduct.types.UploadFileStatus; + + +import java.util.List; +import java.util.Map; + +public class UploadFileResponseDto { + private List fileNames; + private Map> errors; + private UploadFileStatus status; + + public Map> getErrors() { + return errors; + } + + public void setErrors(Map> errors) { + this.errors = errors; + } + + public UploadFileStatus getStatus() { + return status; + } + + public void setStatus(UploadFileStatus status) { + this.status = status; + } + + public List getFileNames() { + return fileNames; + } + + public void setFileNames(List fileNames) { + this.fileNames = fileNames; + } + + public void addNewFileToList(String filename) { + this.fileNames.add(filename); + } + +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/ValidationResponseDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/ValidationResponseDto.java new file mode 100644 index 0000000000..d76ae665ae --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/ValidationResponseDto.java @@ -0,0 +1,77 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorsoftwareproducts.types; + +import org.openecomp.sdcrests.common.types.ErrorCodeDto; +import org.openecomp.sdcrests.common.types.ErrorMessageDto; + +import java.util.Collection; +import java.util.List; +import java.util.Map; + +public class ValidationResponseDto { + private boolean valid; + private Collection vspErrors; + private Collection licensingDataErrors; + private Map> uploadDataErrors; + private QuestionnaireValidationResultDto questionnaireValidationResult; + + public boolean isValid() { + return valid; + } + + public void setValid(boolean valid) { + this.valid = valid; + } + + public Collection getVspErrors() { + return vspErrors; + } + + public void setVspErrors(Collection vspErrors) { + this.vspErrors = vspErrors; + } + + public Collection getLicensingDataErrors() { + return licensingDataErrors; + } + + public void setLicensingDataErrors(Collection licensingDataErrors) { + this.licensingDataErrors = licensingDataErrors; + } + + public Map> getUploadDataErrors() { + return uploadDataErrors; + } + + public void setUploadDataErrors(Map> uploadDataErrors) { + this.uploadDataErrors = uploadDataErrors; + } + + public QuestionnaireValidationResultDto getQuestionnaireValidationResult() { + return questionnaireValidationResult; + } + + public void setQuestionnaireValidationResult( + QuestionnaireValidationResultDto questionnaireValidationResult) { + this.questionnaireValidationResult = questionnaireValidationResult; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/VendorSoftwareProductAction.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/VendorSoftwareProductAction.java new file mode 100644 index 0000000000..c652c1cc4e --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/VendorSoftwareProductAction.java @@ -0,0 +1,29 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorsoftwareproducts.types; + +public enum VendorSoftwareProductAction { + Checkout, + Undo_Checkout, + Checkin, + Submit, + Create_Package; +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/VersionSoftwareProductActionRequestDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/VersionSoftwareProductActionRequestDto.java new file mode 100644 index 0000000000..4ce2bf92f4 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/VersionSoftwareProductActionRequestDto.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorsoftwareproducts.types; + +public class VersionSoftwareProductActionRequestDto { + private VendorSoftwareProductAction action; + + public VendorSoftwareProductAction getAction() { + return action; + } + + public void setAction(VendorSoftwareProductAction action) { + this.action = action; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/VspCreationDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/VspCreationDto.java new file mode 100644 index 0000000000..d786017be1 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/VspCreationDto.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorsoftwareproducts.types; + +public class VspCreationDto { + private String vspId; + + public String getVspId() { + return vspId; + } + + public void setVspId(String vspId) { + this.vspId = vspId; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/VspDescriptionDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/VspDescriptionDto.java new file mode 100644 index 0000000000..a2358a0b48 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/VspDescriptionDto.java @@ -0,0 +1,115 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorsoftwareproducts.types; + +import org.openecomp.sdc.vendorsoftwareproduct.types.LicensingData; + +import javax.validation.constraints.NotNull; + +public class VspDescriptionDto { + @NotNull + private String name; + @NotNull + private String description; + private String icon; + @NotNull + private String category; + @NotNull + private String subCategory; + @NotNull + private String vendorName; + @NotNull + private String vendorId; // this will be populated with vlm id + private String licensingVersion; // this will be populated with vlm version + private LicensingData licensingData; + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public String getIcon() { + return this.icon; + } + + public void setIcon(String icon) { + this.icon = icon; + } + + public String getCategory() { + return category; + } + + public void setCategory(String category) { + this.category = category; + } + + public String getSubCategory() { + return subCategory; + } + + public void setSubCategory(String subCategory) { + this.subCategory = subCategory; + } + + public String getVendorName() { + return vendorName; + } + + public void setVendorName(String vendorName) { + this.vendorName = vendorName; + } + + public String getVendorId() { + return vendorId; + } + + public void setVendorId(String vendorId) { + this.vendorId = vendorId; + } + + public String getLicensingVersion() { + return licensingVersion; + } + + public void setLicensingVersion(String licensingVersion) { + this.licensingVersion = licensingVersion; + } + + public LicensingData getLicensingData() { + return licensingData; + } + + public void setLicensingData(LicensingData licensingData) { + this.licensingData = licensingData; + } +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/VspDetailsDto.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/VspDetailsDto.java new file mode 100644 index 0000000000..85b3203099 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/VspDetailsDto.java @@ -0,0 +1,97 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorsoftwareproducts.types; + +import io.swagger.annotations.ApiModel; + +import org.openecomp.sdc.heat.datatypes.structure.ValidationStructureList; +import org.openecomp.sdc.versioning.dao.types.VersionStatus; + +import java.util.List; + +@ApiModel(value = "VspDetails") +public class VspDetailsDto extends VspDescriptionDto { + + private String id; + private String version; + private List viewableVersions; + private List finalVersions; + private VersionStatus status; + private String lockingUser; + private ValidationStructureList validationData; + + public String getId() { + return id; + } + + public void setId(String id) { + this.id = id; + } + + public String getVersion() { + return version; + } + + public void setVersion(String version) { + this.version = version; + } + + public List getViewableVersions() { + return viewableVersions; + } + + public void setViewableVersions(List viewableVersions) { + this.viewableVersions = viewableVersions; + } + + public List getFinalVersions() { + return finalVersions; + } + + public void setFinalVersions(List finalVersions) { + this.finalVersions = finalVersions; + } + + public VersionStatus getStatus() { + return status; + } + + public void setStatus(VersionStatus status) { + this.status = status; + } + + public String getLockingUser() { + return lockingUser; + } + + public void setLockingUser(String lockingUser) { + this.lockingUser = lockingUser; + } + + public ValidationStructureList getValidationData() { + return validationData; + } + + public void setValidationData(ValidationStructureList validationData) { + this.validationData = validationData; + } + +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/validation/CustomJsonValidator.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/validation/CustomJsonValidator.java new file mode 100644 index 0000000000..23d90c02a2 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/validation/CustomJsonValidator.java @@ -0,0 +1,40 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorsoftwareproducts.types.validation; + +import org.openecomp.core.utilities.json.JsonUtil; + +import javax.validation.ConstraintValidator; +import javax.validation.ConstraintValidatorContext; + +public class CustomJsonValidator implements ConstraintValidator { + + @Override + public void initialize(IsValidJson stringEnumeration) { + } + + + @Override + public boolean isValid(String json, ConstraintValidatorContext context) { + return JsonUtil.isValidJson(json); + } + +} diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/validation/IsValidJson.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/validation/IsValidJson.java new file mode 100644 index 0000000000..7a9ec50721 --- /dev/null +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-types/src/main/java/org/openecomp/sdcrests/vendorsoftwareproducts/types/validation/IsValidJson.java @@ -0,0 +1,77 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdcrests.vendorsoftwareproducts.types.validation; + + +import static java.lang.annotation.ElementType.ANNOTATION_TYPE; +import static java.lang.annotation.ElementType.CONSTRUCTOR; +import static java.lang.annotation.ElementType.FIELD; +import static java.lang.annotation.ElementType.METHOD; +import static java.lang.annotation.ElementType.PARAMETER; +import static java.lang.annotation.RetentionPolicy.RUNTIME; + +import org.openecomp.sdcrests.common.RestConstants; + + +import java.lang.annotation.Documented; +import java.lang.annotation.Retention; +import java.lang.annotation.Target; + +import javax.validation.Constraint; +import javax.validation.Payload; + + +/** + * The interface Is valid json. + */ +@Documented +@Constraint(validatedBy = CustomJsonValidator.class) +@Target({METHOD, FIELD, ANNOTATION_TYPE, PARAMETER, CONSTRUCTOR}) +@Retention(RUNTIME) +public @interface IsValidJson { + /** + * The constant message. + */ + String message = RestConstants.INVALID_JSON_ERROR_MESSAGE; + + /** + * Message string. + * + * @return the string + */ + String message() default RestConstants.INVALID_JSON_ERROR_MESSAGE; + + /** + * Groups class [ ]. + * + * @return the class [ ] + */ + Class[] groups() default {}; + + /** + * Payload class [ ]. + * + * @return the class [ ] + */ + Class[] payload() default {}; +} + + diff --git a/openecomp-be/api/pom.xml b/openecomp-be/api/pom.xml new file mode 100644 index 0000000000..f6654290c7 --- /dev/null +++ b/openecomp-be/api/pom.xml @@ -0,0 +1,22 @@ + + 4.0.0 + + + org.openecomp.sdc + openecomp-sdc + 1.0.0-SNAPSHOT + + + openecomp-sdc-api + openecomp-sdc-api + pom + http://maven.apache.org + + + + + /openecomp-sdc-rest-webapp + + + \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-action-manager/pom.xml b/openecomp-be/backend/openecomp-sdc-action-manager/pom.xml new file mode 100644 index 0000000000..af1652ad50 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-action-manager/pom.xml @@ -0,0 +1,87 @@ + + + 4.0.0 + + + org.openecomp.sdc + backend + 1.0.0-SNAPSHOT + + + openecomp-sdc-action-manager + + + + org.openecomp.core + openecomp-utilities-lib + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-validation-core + ${project.version} + + + org.openecomp.core + openecomp-nosqldb-core + ${project.version} + + + org.testng + testng + 6.9.10 + test + + + junit + junit + RELEASE + test + + + com.fasterxml.jackson.dataformat + jackson-dataformat-xml + 2.7.4 + + + org.codehaus.woodstox + woodstox-core-asl + 4.4.1 + + + org.openecomp.sdc + openecomp-sdc-action-core + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-versioning-core + ${project.version} + + + org.openecomp.sdc.sdc_common + openecomp-logging-api + ${project.version} + + + org.openecomp.sdc.sdc_common + openecomp-logging-core + ${project.version} + + + + + + org.apache.maven.plugins + maven-surefire-plugin + 2.19.1 + + true + + + + + + \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-action-manager/src/main/java/org/openecomp/sdc/action/ActionManager.java b/openecomp-be/backend/openecomp-sdc-action-manager/src/main/java/org/openecomp/sdc/action/ActionManager.java new file mode 100644 index 0000000000..52b0b2a851 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-action-manager/src/main/java/org/openecomp/sdc/action/ActionManager.java @@ -0,0 +1,66 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.action; + + +import org.openecomp.sdc.action.errors.ActionException; +import org.openecomp.sdc.action.types.Action; +import org.openecomp.sdc.action.types.ActionArtifact; +import org.openecomp.sdc.action.types.EcompComponent; + +import java.util.List; + +public interface ActionManager { + public Action createAction(Action action, String user) throws ActionException; + + public Action updateAction(Action action, String user) throws ActionException; + + public void deleteAction(String actionInvariantUuId, String user) throws ActionException; + + public List getFilteredActions(String filterType, String filterValue) + throws ActionException; + + public List getEcompComponents() throws ActionException; + + public List getActionsByActionInvariantUuId(String invariantId) throws ActionException; + + public Action getActionsByActionUuId(String actionUuId) throws ActionException; + + public Action checkout(String invariantUuId, String user) throws ActionException; + + public void undoCheckout(String invariantUuId, String user) throws ActionException; + + public Action checkin(String invariantUuId, String user) throws ActionException; + + public Action submit(String invariantUuId, String user) throws ActionException; + + public ActionArtifact uploadArtifact(ActionArtifact data, String actionInvariantUuId, + String user); + + public ActionArtifact downloadArtifact(String actionUuId, String artifactUuId) + throws ActionException; + + public void deleteArtifact(String actionInvariantUuId, String artifactUuId, String user) + throws ActionException; + + public void updateArtifact(ActionArtifact data, String actionInvariantUuId, String user); +} + diff --git a/openecomp-be/backend/openecomp-sdc-action-manager/src/main/java/org/openecomp/sdc/action/impl/ActionManagerImpl.java b/openecomp-be/backend/openecomp-sdc-action-manager/src/main/java/org/openecomp/sdc/action/impl/ActionManagerImpl.java new file mode 100644 index 0000000000..53ab943765 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-action-manager/src/main/java/org/openecomp/sdc/action/impl/ActionManagerImpl.java @@ -0,0 +1,1217 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.action.impl; + +import static org.openecomp.sdc.action.ActionConstants.SERVICE_INSTANCE_ID; +import static org.openecomp.sdc.action.ActionConstants.TARGET_ENTITY_API; +import static org.openecomp.sdc.action.ActionConstants.TARGET_ENTITY_DB; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ARTIFACT_ALREADY_EXISTS; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ARTIFACT_ALREADY_EXISTS_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ARTIFACT_DELETE_READ_ONLY; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ARTIFACT_DELETE_READ_ONLY_MSG; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ARTIFACT_UPDATE_NAME_INVALID; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ARTIFACT_UPDATE_READ_ONLY; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ARTIFACT_UPDATE_READ_ONLY_MSG; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_CHECKIN_ON_ENTITY_LOCKED_BY_OTHER_USER; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_CHECKIN_ON_UNLOCKED_ENTITY; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_CHECKOUT_ON_LOCKED_ENTITY; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_CHECKOUT_ON_LOCKED_ENTITY_OTHER_USER; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_DELETE_ON_LOCKED_ENTITY_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_EDIT_ON_ENTITY_LOCKED_BY_OTHER_USER; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ENTITY_NOT_EXIST; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ENTITY_NOT_EXIST_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ENTITY_UNIQUE_VALUE_ERROR; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ENTITY_UNIQUE_VALUE_MSG; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_INTERNAL_SERVER_ERR_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_REQUESTED_VERSION_INVALID; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_SUBMIT_FINALIZED_ENTITY_NOT_ALLOWED; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_SUBMIT_LOCKED_ENTITY_NOT_ALLOWED; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_UNDO_CHECKOUT_ON_ENTITY_LOCKED_BY_OTHER_USER; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_UNDO_CHECKOUT_ON_UNLOCKED_ENTITY; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_UPDATE_INVALID_VERSION; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_UPDATE_NOT_ALLOWED_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_UPDATE_NOT_ALLOWED_CODE_NAME; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_UPDATE_NOT_ALLOWED_FOR_NAME; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_UPDATE_ON_UNLOCKED_ENTITY; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_UPDATE_PARAM_INVALID; +import static org.openecomp.sdc.action.util.ActionUtil.actionLogPostProcessor; +import static org.openecomp.sdc.action.util.ActionUtil.actionLogPreProcessor; +import static org.openecomp.sdc.versioning.dao.types.Version.VERSION_STRING_VIOLATION_MSG; + +import org.apache.commons.lang.StringUtils; +import org.openecomp.core.logging.api.Logger; +import org.openecomp.core.logging.api.LoggerFactory; +import org.openecomp.core.util.UniqueValueUtil; +import org.openecomp.core.utilities.CommonMethods; +import org.openecomp.core.utilities.json.JsonUtil; +import org.openecomp.sdc.action.ActionConstants; +import org.openecomp.sdc.action.ActionManager; +import org.openecomp.sdc.action.dao.ActionArtifactDao; +import org.openecomp.sdc.action.dao.ActionArtifactDaoFactory; +import org.openecomp.sdc.action.dao.ActionDao; +import org.openecomp.sdc.action.dao.ActionDaoFactory; +import org.openecomp.sdc.action.dao.types.ActionArtifactEntity; +import org.openecomp.sdc.action.dao.types.ActionEntity; +import org.openecomp.sdc.action.errors.ActionErrorConstants; +import org.openecomp.sdc.action.errors.ActionException; +import org.openecomp.sdc.action.logging.StatusCode; +import org.openecomp.sdc.action.types.Action; +import org.openecomp.sdc.action.types.ActionArtifact; +import org.openecomp.sdc.action.types.ActionArtifactProtection; +import org.openecomp.sdc.action.types.ActionStatus; +import org.openecomp.sdc.action.types.ActionSubOperation; +import org.openecomp.sdc.action.types.EcompComponent; +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.versioning.VersioningManager; +import org.openecomp.sdc.versioning.VersioningManagerFactory; +import org.openecomp.sdc.versioning.dao.VersionInfoDao; +import org.openecomp.sdc.versioning.dao.VersionInfoDaoFactory; +import org.openecomp.sdc.versioning.dao.types.UserCandidateVersion; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.dao.types.VersionInfoEntity; +import org.openecomp.sdc.versioning.errors.EntityNotExistErrorBuilder; +import org.openecomp.sdc.versioning.errors.VersioningErrorCodes; +import org.openecomp.sdc.versioning.types.VersionInfo; +import org.openecomp.sdc.versioning.types.VersionableEntityAction; +import org.slf4j.MDC; + +import java.time.ZoneOffset; +import java.util.ArrayList; +import java.util.Collections; +import java.util.Date; +import java.util.Iterator; +import java.util.LinkedHashMap; +import java.util.LinkedList; +import java.util.List; +import java.util.Map; +import java.util.UUID; + + +/** + * Manager Implementation for {@link ActionManager Action Library Operations}.
Handles Business + * layer validations and acts as an interface between the REST and DAO layers. + */ +public class ActionManagerImpl implements ActionManager { + + private static final ActionDao actionDao = ActionDaoFactory.getInstance().createInterface(); + private static final VersioningManager versioningManager = + VersioningManagerFactory.getInstance().createInterface(); + private static final ActionArtifactDao actionArtifactDao = + ActionArtifactDaoFactory.getInstance().createInterface(); + private static VersionInfoDao versionInfoDao = + VersionInfoDaoFactory.getInstance().createInterface(); + + private final Logger log = (Logger) LoggerFactory.getLogger(this.getClass().getName()); + + public ActionManagerImpl() { + actionDao.registerVersioning(ActionConstants.ACTION_VERSIONABLE_TYPE); + } + + /** + * Get Current Timestamp in UTC format. + * + * @return Current Timestamp in UTC format. + */ + public static Date getCurrentTimeStampUtc() { + return Date.from(java.time.ZonedDateTime.now(ZoneOffset.UTC).toInstant()); + } + + /** + * List All Major, Last Minor and Candidate version (if any) for Given Action Invariant UUID. + * + * @param invariantId Invariant UUID of the action for which the information is required. + * @return List of All Major, Last Minor and Candidate version if any Of {@link Action} with given + actionInvariantUuId. + * @throws ActionException Exception with an action library specific code, short description and + * detailed message for the error occurred during the operation. + */ + @Override + public List getActionsByActionInvariantUuId(String invariantId) throws ActionException { + log.debug(" entering getActionsByActionInvariantUUID with invariantID = " + invariantId); + List actions = actionDao + .getActionsByActionInvariantUuId(invariantId != null ? invariantId.toUpperCase() : null); + if (actions != null && actions.isEmpty()) { + throw new ActionException(ACTION_ENTITY_NOT_EXIST_CODE, ACTION_ENTITY_NOT_EXIST); + } + log.debug(" exit getActionsByActionInvariantUUID with invariantID = " + invariantId); + return actions; + } + + /** + * Get list of actions based on a filter criteria. If no filter is sent all actions will be + * returned. + * + * @param filterType Filter by Vendor/Category/Model/Component/None. + * @param filterValue Filter Parameter Value (Vendor ID/Category ID/Model ID/Component ID). + * @return List of {@link Action} objects based on a filter criteria
Empty List if no records + match the provided filter criteria. + * @throws ActionException Exception with an action library specific code, short description and + * detailed message for the error occurred for the error occurred during + * the operation. + */ + @Override + public List getFilteredActions(String filterType, String filterValue) + throws ActionException { + log.debug(" entering getFilteredActions By filterType = " + filterType + " With value = " + + filterValue); + List actions; + switch (filterType) { + case ActionConstants.FILTER_TYPE_NONE: + //Business validation for ECOMP Component type fetch (if any) + break; + case ActionConstants.FILTER_TYPE_VENDOR: + //Business validation for vendor type fetch (if any) + break; + case ActionConstants.FILTER_TYPE_CATEGORY: + //Business validation for Category type fetch (if any) + break; + case ActionConstants.FILTER_TYPE_MODEL: + //Business validation for model type fetch (if any) + break; + case ActionConstants.FILTER_TYPE_ECOMP_COMPONENT: + //Business validation for ECOMP Component type fetch (if any) + break; + case ActionConstants.FILTER_TYPE_NAME: + actions = actionDao + .getFilteredActions(filterType, filterValue != null ? filterValue.toLowerCase() : null); + if (actions != null && actions.isEmpty()) { + throw new ActionException(ACTION_ENTITY_NOT_EXIST_CODE, ACTION_ENTITY_NOT_EXIST); + } + log.debug(" exit getFilteredActions By filterType = " + filterType + " With value = " + + filterValue); + return actions; + default: + break; + } + actions = actionDao + .getFilteredActions(filterType, filterValue != null ? filterValue.toLowerCase() : null); + List majorMinorVersionList = getMajorMinorVersionActions(actions); + Collections.sort(majorMinorVersionList); + log.debug( + " exit getFilteredActions By filterType = " + filterType + " With value = " + filterValue); + return majorMinorVersionList; + } + + /** + * Get the properties of an action version by its UUID. + * + * @param actionUuId UUID of the specific action version. + * @return {@link Action} object corresponding the version represented by the UUID. + * @throws ActionException Exception with an action library specific code, short description and + * detailed message for the error occurred for the error occurred during + * the operation. + */ + @Override + public Action getActionsByActionUuId(String actionUuId) throws ActionException { + log.debug(" entering getActionsByActionUUID with actionUUID = " + actionUuId); + Action action = + actionDao.getActionsByActionUuId(actionUuId != null ? actionUuId.toUpperCase() : null); + + if (action == null) { + throw new ActionException(ACTION_ENTITY_NOT_EXIST_CODE, ACTION_ENTITY_NOT_EXIST); + } + log.debug(" exit getActionsByActionUUID with actionUUID = " + actionUuId); + return action; + } + + /** + * List ECOMP Components supported by Action Library + * + * @return List of {@link EcompComponent} objects supported by Action Library
Empty List if + no components are found. + * @throws ActionException Exception with an action library specific code, short description and + * detailed message for the error occurred for the error occurred during + * the operation. + */ + @Override + public List getEcompComponents() throws ActionException { + return actionDao.getEcompComponents(); + } + + + /** + * Delete an action. + * + * @param actionInvariantUuId Invariant UUID of the action to be deleted. + * @param user User id of the user performing the operation. + */ + @Override + public void deleteAction(String actionInvariantUuId, String user) throws ActionException { + try { + log.debug("entering deleteAction with actionInvariantUUID = " + actionInvariantUuId + + " and user = " + user); + actionLogPreProcessor(ActionSubOperation.DELETE_ACTION, TARGET_ENTITY_API); + versioningManager.delete(ActionConstants.ACTION_VERSIONABLE_TYPE, actionInvariantUuId, user); + actionLogPostProcessor(StatusCode.COMPLETE); + log.metrics(""); + actionDao.deleteAction(actionInvariantUuId); + } catch (CoreException ce) { + formAndThrowException(ce); + } + } + + /** + * Create a new Action. + * + * @param action Action object model of the user request for creating an action. + * @param user AT&T id of the user sending the create request. + * @return {@link Action} model object for the created action. + * @throws ActionException Exception with an action library specific code, short description and + * detailed message for the error occurred for the error occurred during + * the operation. + */ + @Override + public Action createAction(Action action, String user) throws ActionException { + try { + actionLogPreProcessor(ActionSubOperation.VALIDATE_ACTION_UNIQUE_NAME, TARGET_ENTITY_API); + UniqueValueUtil + .validateUniqueValue(ActionConstants.UniqueValues.ACTION_NAME, action.getName()); + actionLogPostProcessor(StatusCode.COMPLETE); + } catch (CoreException ce) { + String errorDesc = String + .format(ACTION_ENTITY_UNIQUE_VALUE_MSG, ActionConstants.UniqueValues.ACTION_NAME, + action.getName()); + actionLogPostProcessor(StatusCode.ERROR, ACTION_ENTITY_UNIQUE_VALUE_ERROR, errorDesc, false); + throw new ActionException(ACTION_ENTITY_UNIQUE_VALUE_ERROR, errorDesc); + } finally { + log.metrics(""); + } + + action.setUser(user); + action.setTimestamp(getCurrentTimeStampUtc()); + action.setActionInvariantUuId(CommonMethods.nextUuId()); + action.setActionUuId(CommonMethods.nextUuId()); + + actionLogPreProcessor(ActionSubOperation.CREATE_ACTION_VERSION, TARGET_ENTITY_API); + Version version = versioningManager + .create(ActionConstants.ACTION_VERSIONABLE_TYPE, action.getActionInvariantUuId(), user); + actionLogPostProcessor(StatusCode.COMPLETE); + log.metrics(""); + action.setVersion(version.toString()); + action.setStatus(ActionStatus.Locked); + action = updateData(action); + action = actionDao.createAction(action); + actionLogPreProcessor(ActionSubOperation.CREATE_ACTION_UNIQUE_VALUE, TARGET_ENTITY_API); + UniqueValueUtil.createUniqueValue(ActionConstants.UniqueValues.ACTION_NAME, action.getName()); + actionLogPostProcessor(StatusCode.COMPLETE); + log.metrics(""); + return action; + } + + /** + * Update an existing action. + * + * @param action Action object model of the user request for creating an action. + * @param user AT&T id of the user sending the update request. + * @return {@link Action} model object for the update action. + * @throws ActionException Exception with an action library specific code, short description and + * detailed message for the error occurred for the error occurred during + * the operation. + */ + @Override + public Action updateAction(Action action, String user) throws ActionException { + try { + log.debug("entering updateAction to update action with invariantUUID = " + + action.getActionInvariantUuId() + " by user = " + user); + String invariantUuId = action.getActionInvariantUuId(); + actionLogPreProcessor(ActionSubOperation.GET_ACTION_VERSION, TARGET_ENTITY_API); + VersionInfo versionInfo = versioningManager + .getEntityVersionInfo(ActionConstants.ACTION_VERSIONABLE_TYPE, invariantUuId, user, + VersionableEntityAction.Write); + actionLogPostProcessor(StatusCode.COMPLETE); + log.metrics(""); + Version activeVersion = versionInfo.getActiveVersion(); + validateActions(action, activeVersion); + action.setStatus(ActionStatus.Locked); //Status will be Checkout for update + updateData(action); + action.setUser(user); + action.setTimestamp(getCurrentTimeStampUtc()); + actionDao.updateAction(action); + } catch (CoreException ce) { + formAndThrowException(ce); + } + log.debug("exit updateAction"); + return action; + } + + /** + * Checkout an existing action. + * + * @param invariantUuId actionInvariantUuId of the action to be checked out. + * @param user AT&T id of the user sending the checkout request. + * @return {@link Action} model object for the checkout action. + * @throws ActionException Exception with an action library specific code, short description and + * detailed message for the error occurred for the error occurred during + * the operation. + */ + @Override + public Action checkout(String invariantUuId, String user) throws ActionException { + Version version = null; + ActionEntity actionEntity = null; + try { + log.debug( + "entering checkout for Action with invariantUUID= " + invariantUuId + " by user = " + + user); + actionLogPreProcessor(ActionSubOperation.CHECKOUT_ACTION, TARGET_ENTITY_API); + version = + versioningManager.checkout(ActionConstants.ACTION_VERSIONABLE_TYPE, invariantUuId, user); + actionLogPostProcessor(StatusCode.COMPLETE); + log.metrics(""); + actionEntity = + updateUniqueIdForVersion(invariantUuId, version, ActionStatus.Locked.name(), user); + } catch (CoreException e0) { + if (e0.code() != null + && e0.code().id().equals(VersioningErrorCodes.CHECKOT_ON_LOCKED_ENTITY)) { + actionLogPreProcessor(ActionSubOperation.GET_ACTION_VERSION, TARGET_ENTITY_DB); + VersionInfoEntity versionInfoEntity = versionInfoDao + .get(new VersionInfoEntity(ActionConstants.ACTION_VERSIONABLE_TYPE, invariantUuId)); + actionLogPostProcessor(StatusCode.COMPLETE); + log.metrics(""); + String checkoutUser = versionInfoEntity.getCandidate().getUser(); + log.debug( + "Actual checkout user for Action with invariantUUID= " + invariantUuId + " is = " + + checkoutUser); + if (!checkoutUser.equals(user)) { + throw new ActionException(ACTION_CHECKOUT_ON_LOCKED_ENTITY_OTHER_USER, e0.getMessage()); + } + } + formAndThrowException(e0); + } + log.debug( + "exit checkout for Action with invariantUUID= " + invariantUuId + " by user = " + user); + return actionEntity != null ? actionEntity.toDto() : new Action(); + } + + /** + * Undo an already checked out action. + * + * @param invariantUuId actionInvariantUuId of the checked out action. + * @param user AT&T id of the user sending the request. + * @throws ActionException Exception with an action library specific code, short description and + * detailed message for the error occurred for the error occurred during + * the operation. + */ + @Override + public void undoCheckout(String invariantUuId, String user) throws ActionException { + Version version; + try { + log.debug( + "entering undoCheckout for Action with invariantUUID= " + invariantUuId + " by user = " + + user); + actionLogPreProcessor(ActionSubOperation.GET_ACTION_VERSION, TARGET_ENTITY_DB); + //Get list of uploaded artifacts in this checked out version + VersionInfoEntity versionInfoEntity = versionInfoDao + .get(new VersionInfoEntity(ActionConstants.ACTION_VERSIONABLE_TYPE, invariantUuId)); + actionLogPostProcessor(StatusCode.COMPLETE); + log.metrics(""); + if (versionInfoEntity == null) { + throw new CoreException( + new EntityNotExistErrorBuilder(ActionConstants.ACTION_VERSIONABLE_TYPE, invariantUuId) + .build()); + } + UserCandidateVersion candidate = versionInfoEntity.getCandidate(); + Version activeVersion; + if (candidate != null) { + activeVersion = candidate.getVersion(); + } else { + activeVersion = versionInfoEntity.getActiveVersion(); + } + actionLogPreProcessor(ActionSubOperation.GET_ACTIONENTITY_BY_VERSION, TARGET_ENTITY_DB); + Action action = actionDao.get(new ActionEntity(invariantUuId, activeVersion)).toDto(); + actionLogPostProcessor(StatusCode.COMPLETE); + log.metrics(""); + //Perform undo checkout on the action + actionLogPreProcessor(ActionSubOperation.UNDO_CHECKOUT_ACTION, TARGET_ENTITY_API); + version = versioningManager + .undoCheckout(ActionConstants.ACTION_VERSIONABLE_TYPE, invariantUuId, user); + actionLogPostProcessor(StatusCode.COMPLETE); + log.metrics(""); + if (version.equals(new Version(0, 0))) { + actionLogPreProcessor(ActionSubOperation.DELETE_UNIQUEVALUE, TARGET_ENTITY_API); + UniqueValueUtil + .deleteUniqueValue(ActionConstants.UniqueValues.ACTION_NAME, action.getName()); + actionLogPostProcessor(StatusCode.COMPLETE); + log.metrics(""); + actionLogPreProcessor(ActionSubOperation.DELETE_ACTIONVERSION, TARGET_ENTITY_DB ); + //Added for the case where Create->Undo_Checkout->Checkout should not get the action + versionInfoDao + .delete(new VersionInfoEntity(ActionConstants.ACTION_VERSIONABLE_TYPE, invariantUuId)); + actionLogPostProcessor(StatusCode.COMPLETE); + log.metrics(""); + } + List currentVersionArtifacts = action.getArtifacts(); + + //Delete the artifacts from action_artifact table (if any) + if (currentVersionArtifacts != null && currentVersionArtifacts.size() > 0) { + for (ActionArtifact artifact : currentVersionArtifacts) { + ActionArtifactEntity artifactDeleteEntity = + new ActionArtifactEntity(artifact.getArtifactUuId(), + getEffectiveVersion(activeVersion.toString())); + actionLogPreProcessor(ActionSubOperation.DELETE_ARTIFACT, TARGET_ENTITY_DB); + actionArtifactDao.delete(artifactDeleteEntity); + actionLogPostProcessor(StatusCode.COMPLETE); + log.metrics(""); + } + } + } catch (CoreException e0) { + formAndThrowException(e0); + } + log.debug( + "exit undoCheckout for Action with invariantUUID= " + invariantUuId + " by user = " + user); + } + + /** + * Checkin a checked out action. + * + * @param invariantUuId actionInvariantUuId of the checked out action. + * @param user AT&T id of the user sending the request. + * @return {@link Action} model object for the updated action. + * @throws ActionException Exception with an action library specific code, short description and + * detailed message for the error occurred for the error occurred during + * the operation. + */ + @Override + public Action checkin(String invariantUuId, String user) throws ActionException { + Version version = null; + ActionEntity actionEntity = null; + try { + log.debug("entering checkin for Action with invariantUUID= " + invariantUuId + " by user = " + + user); + actionLogPreProcessor(ActionSubOperation.CHECKIN_ACTION, TARGET_ENTITY_API); + version = versioningManager + .checkin(ActionConstants.ACTION_VERSIONABLE_TYPE, invariantUuId, user, null); + actionLogPostProcessor(StatusCode.COMPLETE); + log.metrics(""); + actionEntity = + updateStatusForVersion(invariantUuId, version, ActionStatus.Available.name(), user); + } catch (CoreException e0) { + formAndThrowException(e0); + } + log.debug( + "exit checkin for Action with invariantUUID= " + invariantUuId + " by user = " + user); + return actionEntity != null ? actionEntity.toDto() : new Action(); + } + + /** + * Submit a checked in action. + * + * @param invariantUuId actionInvariantUuId of the checked in action. + * @param user AT&T id of the user sending the request. + * @return {@link Action} model object for the updated action. + * @throws ActionException Exception with an action library specific code, short description and + * detailed message for the error occurred for the error occurred during + * the operation. + */ + @Override + public Action submit(String invariantUuId, String user) throws ActionException { + Version version = null; + ActionEntity actionEntity = null; + try { + log.debug("entering checkin for Action with invariantUUID= " + invariantUuId + " by user = " + + user); + actionLogPreProcessor(ActionSubOperation.CHECKIN_ACTION, TARGET_ENTITY_API); + version = versioningManager + .submit(ActionConstants.ACTION_VERSIONABLE_TYPE, invariantUuId, user, null); + actionLogPostProcessor(StatusCode.COMPLETE); + log.metrics(""); + actionEntity = + updateUniqueIdForVersion(invariantUuId, version, ActionStatus.Final.name(), user); + } catch (CoreException e0) { + formAndThrowException(e0); + } + log.debug( + "exit checkin for Action with invariantUUID= " + invariantUuId + " by user = " + user); + return actionEntity != null ? actionEntity.toDto() : new Action(); + } + + /** + * Download an artifact of an action. + * + * @param artifactUuId {@link ActionArtifact} object representing the artifact and its metadata. + * @param actionUuId UUID of the action for which the artifact has to be downloaded. + * @return downloaded action artifact object. + */ + @Override + public ActionArtifact downloadArtifact(String actionUuId, String artifactUuId) + throws ActionException { + log.debug(" entering downloadArtifact with actionUUID= " + actionUuId + " and artifactUUID= " + + artifactUuId); + Action action = actionDao.getActionsByActionUuId(actionUuId); + ActionArtifact actionArtifact; + if (action != null) { + MDC.put(SERVICE_INSTANCE_ID, action.getActionInvariantUuId()); + List artifacts = action.getArtifacts(); + String actionVersion = action.getVersion(); + int effectiveVersion = getEffectiveVersion(actionVersion); + ActionArtifact artifactMetadata = + getArtifactMetadataFromAction(artifacts, ActionConstants.ARTIFACT_METADATA_ATTR_UUID, + artifactUuId); + if (artifactMetadata != null) { + String artifactName = artifactMetadata.getArtifactName(); + actionArtifact = actionArtifactDao.downloadArtifact(effectiveVersion, artifactUuId); + actionArtifact.setArtifactName(artifactName); + + } else { + throw new ActionException(ActionErrorConstants.ACTION_ARTIFACT_ENTITY_NOT_EXIST_CODE, + ActionErrorConstants.ACTION_ARTIFACT_ENTITY_NOT_EXIST); + } + } else { + throw new ActionException(ACTION_ENTITY_NOT_EXIST_CODE, + ACTION_ENTITY_NOT_EXIST); + } + log.debug(" exit downloadArtifact with actionUUID= " + actionUuId + " and artifactUUID= " + + artifactUuId); + return actionArtifact; + } + + /** + * Upload an artifact to an action. + * + * @param artifact {@link ActionArtifact} object representing the artifact and its + * metadata. + * @param actionInvariantUuId Invariant UUID of the action to which the artifact has to be + * uploaded. + * @param user User ID of the user sending the request. + * @return Uploaded action artifact object. + */ + @Override + public ActionArtifact uploadArtifact(ActionArtifact artifact, String actionInvariantUuId, + String user) { + ActionArtifact uploadArtifactResponse = new ActionArtifact(); + try { + log.debug("entering uploadArtifact with actionInvariantUUID= " + actionInvariantUuId + + "artifactName= " + artifact.getArtifactName()); + actionLogPreProcessor(ActionSubOperation.GET_ACTION_VERSION, TARGET_ENTITY_DB); + VersionInfo versionInfo = versioningManager + .getEntityVersionInfo(ActionConstants.ACTION_VERSIONABLE_TYPE, actionInvariantUuId, user, + VersionableEntityAction.Write); + actionLogPostProcessor(StatusCode.COMPLETE); + log.metrics(""); + Version activeVersion = versionInfo.getActiveVersion(); + actionLogPreProcessor(ActionSubOperation.GET_ACTIONENTITY_BY_ACTIONINVID, TARGET_ENTITY_DB); + Action action = actionDao.get(new ActionEntity(actionInvariantUuId, activeVersion)).toDto(); + actionLogPostProcessor(StatusCode.COMPLETE); + log.metrics(""); + String artifactUuId = generateActionArtifactUuId(action, artifact.getArtifactName()); + //Check for Unique document name + List actionArtifacts = action.getArtifacts(); + ActionArtifact artifactMetadata = getArtifactMetadataFromAction(actionArtifacts, + ActionConstants.ARTIFACT_METADATA_ATTR_NAME, artifact.getArtifactName()); + if (artifactMetadata != null) { + throw new ActionException(ACTION_ARTIFACT_ALREADY_EXISTS_CODE, + String.format(ACTION_ARTIFACT_ALREADY_EXISTS, actionInvariantUuId)); + } + + //Create the artifact + artifact.setArtifactUuId(artifactUuId); + artifact.setTimestamp(getCurrentTimeStampUtc()); + artifact.setEffectiveVersion(getEffectiveVersion(activeVersion.toString())); + actionArtifactDao.uploadArtifact(artifact); + + //Update the action data field and timestamp + addArtifactMetadataInActionData(action, artifact); + + //Set the response object + uploadArtifactResponse.setArtifactUuId(artifact.getArtifactUuId()); + } catch (CoreException ce) { + formAndThrowException(ce); + } + log.debug( + "exit uploadArtifact with actionInvariantUUID= " + actionInvariantUuId + "artifactName= " + + artifact.getArtifactName()); + return uploadArtifactResponse; + } + + @Override + public void deleteArtifact(String actionInvariantUuId, String artifactUuId, String user) + throws ActionException { + log.debug( + "enter deleteArtifact with actionInvariantUUID= " + actionInvariantUuId + "artifactUUID= " + + artifactUuId + " and user = " + user); + Action action = actionDao.getLockedAction(actionInvariantUuId, user); + List actionArtifacts = action.getArtifacts(); + ActionArtifact artifactMetadata = + getArtifactMetadataFromAction(actionArtifacts, ActionConstants.ARTIFACT_METADATA_ATTR_UUID, + artifactUuId); + if (artifactMetadata == null) { + throw new ActionException(ActionErrorConstants.ACTION_ARTIFACT_ENTITY_NOT_EXIST_CODE, + ActionErrorConstants.ACTION_ARTIFACT_ENTITY_NOT_EXIST); + } + if (artifactMetadata.getArtifactProtection().equals(ActionArtifactProtection.readOnly.name())) { + throw new ActionException(ACTION_ARTIFACT_DELETE_READ_ONLY, + ACTION_ARTIFACT_DELETE_READ_ONLY_MSG); + } else { + + //Update action by removing artifact metadata + String jsonData = action.getData(); + List artifacts = action.getArtifacts();//action.getArtifacts(); + ActionArtifact artifact = null; + Iterator it = artifacts.iterator(); + while (it.hasNext()) { + artifact = it.next(); + String artifactId = artifact.getArtifactUuId(); + if (artifactId.equals(artifactUuId)) { + it.remove(); + } + } + + Map dataMap = JsonUtil.json2Object(jsonData, LinkedHashMap.class); + dataMap.put("artifacts", artifacts); + String data = JsonUtil.object2Json(dataMap); + ActionEntity actionEntity = action.toEntity(); + actionEntity.setData(data); + actionLogPreProcessor(ActionSubOperation.UPDATE_ACTION, TARGET_ENTITY_DB); + actionDao.update(actionEntity); + actionLogPostProcessor(StatusCode.COMPLETE, null, "", false); + log.metrics(""); + // delete Artifact if it's upload and delete action on same checkout version + String artifactName = artifactMetadata.getArtifactName(); + String generatedArtifactUuId = generateActionArtifactUuId(action, artifactName); + if (generatedArtifactUuId.equals(artifactUuId)) { + ActionArtifactEntity artifactDeleteEntity = + new ActionArtifactEntity(artifact.getArtifactUuId(), + getEffectiveVersion(action.getVersion())); + actionLogPreProcessor(ActionSubOperation.DELETE_ACTION_ARTIFACT, TARGET_ENTITY_DB); + actionArtifactDao.delete(artifactDeleteEntity); + actionLogPostProcessor(StatusCode.COMPLETE, null, "", false); + log.metrics(""); + } + + } + log.debug( + "exit deleteArtifact with actionInvariantUUID= " + actionInvariantUuId + "artifactUUID= " + + artifactUuId + " and user = " + user); + } + + /** + * Update an existing artifact. + * + * @param artifact {@link ActionArtifact} object representing the artifact and its + * metadata. + * @param actionInvariantUuId Invariant UUID of the action to which the artifact has to be + * uploaded. + * @param user User ID of the user sending the request. + */ + public void updateArtifact(ActionArtifact artifact, String actionInvariantUuId, String user) { + try { + log.debug("Enter updateArtifact with actionInvariantUUID= " + actionInvariantUuId + + "artifactUUID= " + artifact.getArtifactUuId() + " and user = " + user); + actionLogPreProcessor(ActionSubOperation.GET_ACTION_VERSION, TARGET_ENTITY_API); + VersionInfo versionInfo = versioningManager + .getEntityVersionInfo(ActionConstants.ACTION_VERSIONABLE_TYPE, actionInvariantUuId, user, + VersionableEntityAction.Write); + actionLogPostProcessor(StatusCode.COMPLETE, null, "", false); + log.metrics(""); + Version activeVersion = versionInfo.getActiveVersion(); + actionLogPreProcessor(ActionSubOperation.GET_ACTIONENTITY_BY_ACTIONINVID, TARGET_ENTITY_DB); + Action action = actionDao.get(new ActionEntity(actionInvariantUuId, activeVersion)).toDto(); + actionLogPostProcessor(StatusCode.COMPLETE, null, "", false); + log.metrics(""); + List actionArtifacts = action.getArtifacts(); + ActionArtifact artifactMetadataByUuId = getArtifactMetadataFromAction(actionArtifacts, + ActionConstants.ARTIFACT_METADATA_ATTR_UUID, artifact.getArtifactUuId()); + //Check if artifact is already in action or not + if (artifactMetadataByUuId == null) { + throw new ActionException(ActionErrorConstants.ACTION_ARTIFACT_ENTITY_NOT_EXIST_CODE, + ActionErrorConstants.ACTION_ARTIFACT_ENTITY_NOT_EXIST); + } + //If user tries to change artifact name + if (artifact.getArtifactName() != null + && !artifactMetadataByUuId.getArtifactName() + .equalsIgnoreCase(artifact.getArtifactName())) { + throw new ActionException(ACTION_UPDATE_NOT_ALLOWED_CODE, + ACTION_ARTIFACT_UPDATE_NAME_INVALID); + } + + byte[] payload = artifact.getArtifact(); + String artifactLabel = artifact.getArtifactLabel(); + String artifactCategory = artifact.getArtifactCategory(); + String artifactDescription = artifact.getArtifactDescription(); + String artifactProtection = artifact.getArtifactProtection(); + String artifactName = artifact.getArtifactName(); + //If artifact read only + if (artifactMetadataByUuId.getArtifactProtection() + .equals(ActionArtifactProtection.readOnly.name())) { + if (artifactName != null || artifactLabel != null || artifactCategory != null + || artifactDescription != null || payload != null) { + throw new ActionException(ACTION_ARTIFACT_UPDATE_READ_ONLY, + ACTION_ARTIFACT_UPDATE_READ_ONLY_MSG); + } + //Changing value from readOnly to readWrite + if (artifactProtection != null + && artifactProtection.equals(ActionArtifactProtection.readWrite.name())) { + artifactMetadataByUuId.setArtifactProtection(ActionArtifactProtection.readWrite.name()); + artifactMetadataByUuId.setTimestamp(getCurrentTimeStampUtc()); + updateArtifactMetadataInActionData(action, artifactMetadataByUuId); + } + } else { + int effectiveVersion = getEffectiveVersion(activeVersion.toString()); + if (artifactLabel != null) { + artifactMetadataByUuId.setArtifactLabel(artifactLabel); + } + if (artifactCategory != null) { + artifactMetadataByUuId.setArtifactCategory(artifactCategory); + } + if (artifactDescription != null) { + artifactMetadataByUuId.setArtifactDescription(artifactDescription); + } + if (artifactProtection != null) { + artifactMetadataByUuId.setArtifactProtection(artifactProtection); + } + if (payload != null) { + //get artifact data from action_artifact table for updating the content + ActionArtifact artifactContent = new ActionArtifact(); + artifactContent.setArtifactUuId(artifact.getArtifactUuId()); + artifactContent.setArtifact(payload); + artifactContent.setEffectiveVersion(effectiveVersion); + actionArtifactDao.updateArtifact(artifactContent); + } + //Update the action data field and timestamp + artifactMetadataByUuId.setTimestamp(getCurrentTimeStampUtc()); + updateArtifactMetadataInActionData(action, artifactMetadataByUuId); + } + log.debug("exit updateArtifact with actionInvariantUUID= " + actionInvariantUuId + + "artifactUUID= " + artifact.getArtifactUuId() + " and user = " + user); + } catch (CoreException coreException) { + formAndThrowException(coreException); + } + } + + /** + * Generate artifact UUID at runtime using action name and effective version. + * + * @param action {@link Action} for which the artifact is being uploaded/updated/downloaded. + * @param artifactName Artifact name. + * @return Generated UUID string. + */ + private String generateActionArtifactUuId(Action action, String artifactName) { + int effectiveVersion = getEffectiveVersion(action.getVersion()); + //Upper case for maintaining case-insensitive behavior for the artifact names + String artifactUuIdString + = action.getName().toUpperCase() + effectiveVersion + artifactName.toUpperCase(); + String generateArtifactUuId + = UUID.nameUUIDFromBytes((artifactUuIdString).getBytes()).toString(); + String artifactUuId = generateArtifactUuId.replace("-", ""); + return artifactUuId.toUpperCase(); + } + + /** + * Generate the effective action version for artifact operations. + * + * @param actionVersion Version of the action as a string. + * @return Effective version to be used for artifact operations. + */ + private int getEffectiveVersion(String actionVersion) { + Version version = Version.valueOf(actionVersion); + return version.getMajor() * 10000 + version.getMinor(); + } + + /** + * Update the data field of the Action object with the modified/generated fields after an + * operation. + * + * @param action Action object whose data field has to be updated. + * @return Updated {@link Action} object. + */ + private Action updateData(Action action) { + log.debug("entering updateData to update data json for action with actionuuid= " + + action.getActionUuId()); + Map dataMap = new LinkedHashMap<>(); + dataMap.put(ActionConstants.UNIQUE_ID, action.getActionUuId()); + dataMap.put(ActionConstants.VERSION, action.getVersion()); + dataMap.put(ActionConstants.INVARIANTUUID, action.getActionInvariantUuId()); + dataMap.put(ActionConstants.STATUS, action.getStatus().name()); + + String data = action.getData(); + Map currentDataMap = JsonUtil.json2Object(data, LinkedHashMap.class); + dataMap.putAll(currentDataMap); + data = JsonUtil.object2Json(dataMap); + action.setData(data); + log.debug("exit updateData"); + return action; + } + + /** + * Method to add the artifact metadata in the data attribute of action table. + * + * @param action Action to which artifact is uploaded. + * @param artifact Uploaded artifact object. + */ + private void addArtifactMetadataInActionData(Action action, ActionArtifact artifact) { + + ActionArtifact artifactMetadata = new ActionArtifact(); + artifactMetadata.setArtifactUuId(artifact.getArtifactUuId()); + artifactMetadata.setArtifactName(artifact.getArtifactName()); + artifactMetadata.setArtifactProtection(artifact.getArtifactProtection()); + artifactMetadata.setArtifactLabel(artifact.getArtifactLabel()); + artifactMetadata.setArtifactDescription(artifact.getArtifactDescription()); + artifactMetadata.setArtifactCategory(artifact.getArtifactCategory()); + artifactMetadata.setTimestamp(artifact.getTimestamp()); + List actionArtifacts = action.getArtifacts(); + if (actionArtifacts == null) { + actionArtifacts = new ArrayList<>(); + } + actionArtifacts.add(artifactMetadata); + action.setArtifacts(actionArtifacts); + String currentData = action.getData(); + Map currentDataMap = JsonUtil.json2Object(currentData, LinkedHashMap.class); + currentDataMap.put(ActionConstants.ARTIFACTS, actionArtifacts); + String updatedActionData = JsonUtil.object2Json(currentDataMap); + action.setData(updatedActionData); + action.setTimestamp(artifact.getTimestamp()); + actionDao.updateAction(action); + } + + /** + * Get a list of last major and last minor version (no candidate) of action from a list of + * actions. + * + * @param actions Exhaustive list of the action versions. + * @return List {@link Action} of last major and last minor version (no candidate) of action from + a list of actions. + */ + private List getMajorMinorVersionActions(List actions) { + log.debug(" entering getMajorMinorVersionActions for actions "); + List list = new LinkedList<>(); + actionLogPreProcessor(ActionSubOperation.GET_VERSIONINFO_FOR_ALL_ACTIONS, TARGET_ENTITY_API); + Map actionVersionMap = versioningManager + .listEntitiesVersionInfo(ActionConstants.ACTION_VERSIONABLE_TYPE, "", + VersionableEntityAction.Read); + actionLogPostProcessor(StatusCode.COMPLETE); + log.metrics(""); + for (Action action : actions) { + if (action.getStatus() == ActionStatus.Deleted) { + continue; + } + VersionInfo actionVersionInfo = actionVersionMap.get(action.getActionInvariantUuId()); + if (actionVersionInfo.getActiveVersion() != null + && actionVersionInfo.getActiveVersion().equals(Version.valueOf(action.getVersion()))) { + list.add(action); + } else if (actionVersionInfo.getLatestFinalVersion() != null + && actionVersionInfo.getLatestFinalVersion().equals(Version.valueOf(action.getVersion())) + && + !actionVersionInfo.getLatestFinalVersion().equals(actionVersionInfo.getActiveVersion())) { + list.add(action); + } + } + log.debug(" exit getMajorMinorVersionActions for actions "); + return list; + } + + /** + * CoreException object wrapper from Version library to Action Library Exception. + * + * @param exception CoreException object from version library. + */ + private void formAndThrowException(CoreException exception) { + log.debug( + "entering formAndThrowException with input CoreException =" + exception.code().id() + " " + + exception.getMessage()); + String errorDescription = exception.getMessage(); + String errorCode = exception.code().id(); + ActionException actionException = new ActionException(); + switch (errorCode) { + case VersioningErrorCodes.VERSIONABLE_ENTITY_NOT_EXIST: + actionException.setErrorCode(ACTION_ENTITY_NOT_EXIST_CODE); + actionException.setDescription(ACTION_ENTITY_NOT_EXIST); + break; + case VersioningErrorCodes.CHECKOT_ON_LOCKED_ENTITY: + actionException.setErrorCode(ACTION_CHECKOUT_ON_LOCKED_ENTITY); + actionException.setDescription(errorDescription); + break; + case VersioningErrorCodes.CHECKIN_ON_UNLOCKED_ENTITY: + actionException.setErrorCode(ACTION_CHECKIN_ON_UNLOCKED_ENTITY); + actionException.setDescription(errorDescription); + break; + case VersioningErrorCodes.SUBMIT_FINALIZED_ENTITY_NOT_ALLOWED: + actionException.setErrorCode(ACTION_SUBMIT_FINALIZED_ENTITY_NOT_ALLOWED); + actionException.setDescription(errorDescription); + break; + case VersioningErrorCodes.SUBMIT_LOCKED_ENTITY_NOT_ALLOWED: + actionException.setErrorCode(ACTION_SUBMIT_LOCKED_ENTITY_NOT_ALLOWED); + actionException.setDescription(errorDescription); + break; + case VersioningErrorCodes.UNDO_CHECKOUT_ON_UNLOCKED_ENTITY: + actionException.setErrorCode(ACTION_UNDO_CHECKOUT_ON_UNLOCKED_ENTITY); + actionException.setDescription(errorDescription); + break; + case VersioningErrorCodes.EDIT_ON_ENTITY_LOCKED_BY_OTHER_USER: + actionException.setErrorCode(ACTION_EDIT_ON_ENTITY_LOCKED_BY_OTHER_USER); + actionException.setDescription(errorDescription.replace("edit", "updat")); + break; + case VersioningErrorCodes.CHECKIN_ON_ENTITY_LOCKED_BY_OTHER_USER: + actionException.setErrorCode(ACTION_CHECKIN_ON_ENTITY_LOCKED_BY_OTHER_USER); + actionException.setDescription(errorDescription); + break; + case VersioningErrorCodes.UNDO_CHECKOUT_ON_ENTITY_LOCKED_BY_OTHER_USER: + actionException.setErrorCode(ACTION_UNDO_CHECKOUT_ON_ENTITY_LOCKED_BY_OTHER_USER); + actionException.setDescription(errorDescription); + break; + case VersioningErrorCodes.EDIT_ON_UNLOCKED_ENTITY: + actionException.setErrorCode(ACTION_UPDATE_ON_UNLOCKED_ENTITY); + actionException.setDescription(errorDescription.replace("edit", "update")); + break; + case VersioningErrorCodes.DELETE_ON_LOCKED_ENTITY: + actionException.setErrorCode(ACTION_DELETE_ON_LOCKED_ENTITY_CODE); + actionException.setDescription(errorDescription); + break; + default: + actionException.setErrorCode(ACTION_INTERNAL_SERVER_ERR_CODE); + actionException.setDescription(exception.getMessage()); + + } + log.debug( + "exit formAndThrowException with ActionException =" + actionException.getErrorCode() + " " + + actionException.getDescription()); + throw actionException; + } + + /** + * Validates an action object for business layer validations before an update operation. + * + * @param action Action object to be validated. + * @param activeVersion Active version of the actoin object. + */ + private void validateActions(Action action, Version activeVersion) { + try { + //Set version if not already available in input request + //If version set in input compare it with version from DB + if (StringUtils.isEmpty(action.getVersion())) { + action.setVersion(activeVersion.toString()); + } else { + if (!activeVersion.equals(Version.valueOf(action.getVersion()))) { + throw new ActionException(ACTION_UPDATE_INVALID_VERSION, + String.format(ACTION_REQUESTED_VERSION_INVALID, action.getVersion())); + } + } + String invariantUuId = action.getActionInvariantUuId(); + Version version = Version.valueOf(action.getVersion()); + Action existingAction = getActions(invariantUuId, version); + if (existingAction == null || existingAction.getActionInvariantUuId() == null) { + throw new ActionException(ACTION_ENTITY_NOT_EXIST_CODE, ACTION_ENTITY_NOT_EXIST); + } + List invalidParameters = new LinkedList<>(); + //Prevent update of name, version and id fields + if (!existingAction.getName().equals(action.getName())) { + throw new ActionException(ACTION_UPDATE_NOT_ALLOWED_CODE_NAME, + ACTION_UPDATE_NOT_ALLOWED_FOR_NAME); + } + if (!StringUtils.isEmpty(action.getActionUuId()) + && !existingAction.getActionUuId().equals(action.getActionUuId())) { + invalidParameters.add(ActionConstants.UNIQUE_ID); + } + if (action.getStatus() != null && (existingAction.getStatus() != action.getStatus())) { + invalidParameters.add(ActionConstants.STATUS); + } + + if (!invalidParameters.isEmpty()) { + throw new ActionException(ACTION_UPDATE_NOT_ALLOWED_CODE, + String.format(ACTION_UPDATE_PARAM_INVALID, StringUtils.join(invalidParameters, ", "))); + } + action.setActionUuId(existingAction.getActionUuId()); + } catch (IllegalArgumentException iae) { + String message = iae.getMessage(); + switch (message) { + case VERSION_STRING_VIOLATION_MSG: + throw new ActionException(ACTION_UPDATE_NOT_ALLOWED_CODE, message); + default: + throw iae; + } + } + } + + /** + * Get an action version entity object. + * + * @param invariantUuId Invariant UUID of the action. + * @param version Version of the action. + * @return {@link ActionEntity} object of the action version. + */ + private ActionEntity getActionsEntityByVersion(String invariantUuId, Version version) { + log.debug( + "entering getActionsEntityByVersion with invariantUUID= " + invariantUuId + " and version" + + version); + ActionEntity entity = null; + if (version != null) { + actionLogPreProcessor(ActionSubOperation.GET_ACTIONENTITY_BY_VERSION, TARGET_ENTITY_DB); + entity = actionDao.get( + new ActionEntity(invariantUuId != null ? invariantUuId.toUpperCase() : null, version)); + actionLogPostProcessor(StatusCode.COMPLETE); + log.metrics(""); + } + log.debug( + "exit getActionsEntityByVersion with invariantUUID= " + invariantUuId + " and version" + + version); + return entity; + } + + /** + * Get an action version object. + * + * @param invariantUuId Invariant UUID of the action. + * @param version Version of the action. + * @return {@link Action} object of the action version. + */ + private Action getActions(String invariantUuId, Version version) { + ActionEntity actionEntity = + getActionsEntityByVersion(invariantUuId != null ? invariantUuId.toUpperCase() : null, + version); + return actionEntity != null ? actionEntity.toDto() : new Action(); + } + + /** + * Create and set the Unique ID in for an action version row. + * + * @param invariantUuId Invariant UUID of the action. + * @param version Version of the action. + * @param status Status of the action. + * @param user AT&T id of the user sending the request. + * @return {@link ActionEntity} object of the action version. + */ + private ActionEntity updateUniqueIdForVersion(String invariantUuId, Version version, + String status, String user) { + log.debug( + "entering updateUniqueIdForVersion to update action with invariantUUID= " + invariantUuId + + " with version,status and user as ::" + version + " " + status + " " + user); + //generate UUID AND update for newly created entity row + ActionEntity actionEntity = getActionsEntityByVersion(invariantUuId, version); + if (actionEntity != null) { + log.debug("Found action to be updated"); + String data = actionEntity.getData(); + String uniqueId = CommonMethods.nextUuId(); + Map dataMap = JsonUtil.json2Object(data, LinkedHashMap.class); + dataMap.put(ActionConstants.UNIQUE_ID, uniqueId); + dataMap.put(ActionConstants.VERSION, version.toString()); + dataMap.put(ActionConstants.STATUS, status); + data = JsonUtil.object2Json(dataMap); + + actionEntity.setData(data); + actionEntity.setActionUuId(uniqueId); + actionEntity.setStatus(status); + actionEntity.setUser(user); + actionEntity.setTimestamp(getCurrentTimeStampUtc()); + actionLogPreProcessor(ActionSubOperation.UPDATE_ACTION, TARGET_ENTITY_DB); + actionDao.update(actionEntity); + actionLogPostProcessor(StatusCode.COMPLETE); + log.metrics(""); + } + log.debug( + "exit updateUniqueIdForVersion to update action with invariantUUID= " + invariantUuId); + return actionEntity; + } + + /** + * Set the status for an action version row. + * + * @param invariantUuId Invariant UUID of the action. + * @param version Version of the action. + * @param status Status of the action. + * @param user AT&T id of the user sending the request. + * @return {@link ActionEntity} object of the action version. + */ + private ActionEntity updateStatusForVersion(String invariantUuId, Version version, String status, + String user) { + log.debug( + "entering updateStatusForVersion with invariantUUID= " + invariantUuId + " and version" + + version + " for updating status " + status + " by user " + user); + ActionEntity actionEntity = getActionsEntityByVersion(invariantUuId, version); + if (actionEntity != null) { + String data = actionEntity.getData(); + Map dataMap = JsonUtil.json2Object(data, LinkedHashMap.class); + dataMap.put(ActionConstants.STATUS, status); + data = JsonUtil.object2Json(dataMap); + actionEntity.setData(data); + actionEntity.setStatus(status); + actionEntity.setUser(user); + actionEntity.setTimestamp(getCurrentTimeStampUtc()); + actionLogPreProcessor(ActionSubOperation.UPDATE_ACTION, TARGET_ENTITY_DB); + actionDao.update(actionEntity); + actionLogPostProcessor(StatusCode.COMPLETE); + log.metrics(""); + } + log.debug("exit updateStatusForVersion with invariantUUID= " + invariantUuId + " and version" + + version + " for updating status " + status + " by user " + user); + return actionEntity; + + } + + /** + * Gets an artifact from the action artifact metadata by artifact name. + * + * @param actionArtifactList Action's existing artifact list. + * @param artifactFilterType Search criteria for artifact in action artifact metadata. + * @param artifactFilterValue Value of Search parameter. + * @return Artifact metadata object if artifact is present in action and null otherwise. + */ + private ActionArtifact getArtifactMetadataFromAction(List actionArtifactList, + String artifactFilterType, + String artifactFilterValue) { + ActionArtifact artifact = null; + if (actionArtifactList != null && !actionArtifactList.isEmpty()) { + for (ActionArtifact entry : actionArtifactList) { + switch (artifactFilterType) { + case ActionConstants.ARTIFACT_METADATA_ATTR_UUID: + String artifactUuId = entry.getArtifactUuId(); + if (artifactUuId != null && artifactUuId.equals(artifactFilterValue)) { + artifact = entry; + break; + } + break; + case ActionConstants.ARTIFACT_METADATA_ATTR_NAME: + String existingArtifactName = entry.getArtifactName().toLowerCase(); + if (existingArtifactName.equals(artifactFilterValue.toLowerCase())) { + artifact = entry; + break; + } + break; + default: + } + } + } + return artifact; + } + + /** + * Method to update the artifact metadata in the data attribute of action table. + * + * @param action Action to which artifact is uploaded. + * @param updatedArtifact updated artifact object. + */ + private void updateArtifactMetadataInActionData(Action action, ActionArtifact updatedArtifact) { + for (ActionArtifact entry : action.getArtifacts()) { + if (entry.getArtifactUuId().equals(updatedArtifact.getArtifactUuId())) { + entry.setArtifactLabel(updatedArtifact.getArtifactLabel()); + entry.setArtifactCategory(updatedArtifact.getArtifactCategory()); + entry.setArtifactDescription(updatedArtifact.getArtifactDescription()); + entry.setArtifactProtection(updatedArtifact.getArtifactProtection()); + entry.setTimestamp(updatedArtifact.getTimestamp()); + break; + } + } + String data = action.getData(); + Map map = JsonUtil.json2Object(data, LinkedHashMap.class); + map.put(ActionConstants.ARTIFACTS, action.getArtifacts()); + String updatedActionData = JsonUtil.object2Json(map); + action.setData(updatedActionData); + action.setTimestamp(updatedArtifact.getTimestamp()); + actionDao.updateAction(action); + } +} diff --git a/openecomp-be/backend/openecomp-sdc-action-manager/src/test/java/org/openecomp/sdc/action/ActionTest.java b/openecomp-be/backend/openecomp-sdc-action-manager/src/test/java/org/openecomp/sdc/action/ActionTest.java new file mode 100644 index 0000000000..6d4b422154 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-action-manager/src/test/java/org/openecomp/sdc/action/ActionTest.java @@ -0,0 +1,1207 @@ +package org.openecomp.sdc.action; + +import org.openecomp.sdc.action.dao.ActionDao; +import org.openecomp.sdc.action.dao.ActionDaoFactory; +import org.openecomp.sdc.action.dao.types.ActionEntity; +import org.openecomp.sdc.action.errors.ActionErrorConstants; +import org.openecomp.sdc.action.errors.ActionException; +import org.openecomp.sdc.action.impl.ActionManagerImpl; + +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.core.nosqldb.api.NoSqlDb; +import org.openecomp.core.nosqldb.factory.NoSqlDbFactory; +import org.openecomp.core.utilities.json.JsonUtil; + +import org.openecomp.sdc.action.types.Action; +import org.openecomp.sdc.action.types.ActionArtifact; +import org.openecomp.sdc.action.types.ActionArtifactProtection; +import org.openecomp.sdc.action.types.ActionStatus; +import org.openecomp.sdc.action.types.EcompComponent; +import org.testng.Assert; +import org.testng.annotations.BeforeTest; +import org.testng.annotations.Test; + +import java.io.File; +import java.io.FileInputStream; +import java.io.IOException; +import java.util.*; + + +@SuppressWarnings("Duplicates") +public class ActionTest { + private static final Version VERSION01 = new Version(0, 1); + private static final String USER1 = "actionTestUser1"; + private static final String USER2 = "actionTestUser2"; + private static final String ACTION_1 = + "{\"name\":\"Test_Action1_name\", \"endpointUri\":\"/test/action/uri\"}"; + private static final String ACTION_2 = + "{\"name\":\"Test_Action2_list\", \"endpointUri\":\"/test/action/uri\", \"categoryList\":[\"Cat-test\", \"Cat-2\"], \"supportedModels\":[{\"versionId\" : \"Model-test\"}], \"supportedComponents\":[{\"Id\":\"APP-C\"}]}"; + private static final String ACTION_3 = + "{\"name\":\"Test_Action3_list\", \"endpointUri\":\"/test/action/uri\", \"vendorList\":[\"Vendor-test\", \"Vendor-2\"], \"supportedModels\":[{\"versionId\" : \"Model-2\"}], \"supportedComponents\":[{\"Id\":\"MSO\"}]}"; + private static final String ACTION_4 = + "{\"name\":\"Test_Action4_list\", \"endpointUri\":\"/test/action/uri\", \"categoryList\":[\"Cat-test\", \"Cat-2\"], \"supportedModels\":[{\"versionId\" : \"Model-test\"}], \"supportedComponents\":[{\"Id\":\"APP-C\"}]}"; + private static final String ACTION_5 = + "{\"name\":\"Test_Action5_list\", \"endpointUri\":\"/test/action/uri\", \"vendorList\":[\"Vendor-test\", \"Vendor-2\"], \"supportedModels\":[{\"versionId\" : \"Model-2\"}], \"supportedComponents\":[{\"Id\":\"MSO\"}]}"; + private static final String ACTION_6 = + "{\"name\":\"Test_Action6_name\", \"endpointUri\":\"/test/action/uri\"}"; + private static final String ARTIFACT_TEST_ACTION = + "{\"name\":\"Test_Artifact_Action\", \"endpointUri\":\"/test/artifact/action/uri\", \"vendorList\":[\"Vendor-test\", \"Vendor-2\"], \"supportedModels\":[{\"versionId\" : \"Model-2\"}], \"supportedComponents\":[{\"Id\":\"MSO\"}]}"; + private static final String ACTION_TEST_DELETE = + "{\"name\":\"Test_Delete_Action\", \"endpointUri\":\"/test/delete/action/uri\", \"categoryList\":[\"Cat-Delete-test\"], \"vendorList\":[\"Vendor-Delete\"], \"supportedModels\":[{\"versionId\" : \"Model-Delete\"}], \"supportedComponents\":[{\"Id\":\"MSO-Delete\"}]}"; + private static final String ACTION_TEST_ARTIFACT_FILE_NAME = "test_artifact_file.txt"; + private static final String ACTION_TEST_UPDATE_ARTIFACT_FILE_NAME = + "test_artifact_update_file.txt"; + private static ActionManager actionManager = new ActionManagerImpl(); + private static ActionDao actionDao = ActionDaoFactory.getInstance().createInterface(); + + private static NoSqlDb noSqlDb; + + private static String action1Id; + private static String action2Id; + + private static String actionUUId; + private static Action testArtifactAction; + private static String expectedArtifactUUID; + private static ActionArtifact actionArtifact; + private Action deleteAction; + + private static String testCreate() { + Action action1 = createAction(ACTION_1); + Action actionCreated = actionManager.createAction(action1, USER1); + action1Id = actionCreated.getActionInvariantUuId(); + actionUUId = actionCreated.getActionUuId(); + action1.setVersion(VERSION01.toString()); + ActionEntity loadedAction = actionDao.get(action1.toEntity()); + assertActionEquals(actionCreated, loadedAction.toDto()); + return action1Id; + } + + private static Action createAction(String requestJSON) { + Action action = JsonUtil.json2Object(requestJSON, Action.class); + action.setData(requestJSON); + return action; + } + + private static void assertActionEquals(Action actual, Action expected) { + Assert.assertEquals(actual.getActionUuId(), expected.getActionUuId()); + Assert.assertEquals(actual.getVersion(), expected.getVersion()); + Assert.assertEquals(actual.getName(), expected.getName()); + //Assert.assertEquals(actual.getDescription(), expected.getDescription()); + Assert.assertEquals(actual.getData(), expected.getData()); + Assert.assertEquals(actual.getActionInvariantUuId(), expected.getActionInvariantUuId()); + //Assert.assertEquals(actual.getEndpointUri(), expected.getEndpointUri()); + Assert.assertEquals(actual.getStatus(), expected.getStatus()); + Assert.assertEquals(actual.getSupportedComponents(), expected.getSupportedComponents()); + Assert.assertEquals(actual.getSupportedModels(), expected.getSupportedModels()); + } + + @BeforeTest + private void init() { + this.noSqlDb = NoSqlDbFactory.getInstance().createInterface(); + this.noSqlDb.execute("TRUNCATE dox.action;"); + this.noSqlDb.execute("TRUNCATE dox.ecompcomponent;"); + this.noSqlDb.execute("TRUNCATE dox.unique_value;"); + this.noSqlDb.execute("TRUNCATE dox.action_artifact;"); + this.noSqlDb.execute("insert into dox.ecompcomponent(id, name) values ('COMP-1','MSO');"); + this.noSqlDb.execute("insert into dox.ecompcomponent(id, name) values ('COMP-2','APP-C');"); + } + + @Test + public void createTest() { + action1Id = testCreate(); + } + + @Test + public void testGetByInvIdOnCreate() { + String input = + "{\"name\":\"Action_2.0\",\"endpointUri\":\"new/action/uri\",\"categoryList\":[\"Cat-1\", \"Cat-2\"],\"displayName\":\"Updated Action\",\"vendorList\":[\"Vendor-1\", \"Vendor-2\"]," + + "\"supportedModels\":[{\"versionId\":\"AA56B177-9383-4934-8543-0F91A7A04971\"," + + "\"invariantID\":\"CC87B177-9383-4934-8543-0F91A7A07193\", \"name\":\"vABC\"," + + "\"version\":\"2.1\",\"vendor\":\"cisco\"}]," + + "\"supportedComponents\":[{\"Id\":\"BB47B177-9383-4934-8543-0F91A7A06448\", \"name\":\"appc\"}]}"; + Action action1 = createAction(input); + Action action = actionManager.createAction(action1, USER1); + action2Id = action.getActionInvariantUuId(); + List actions = + actionManager.getActionsByActionInvariantUuId(action.getActionInvariantUuId()); + Assert.assertEquals(1, actions.size()); + Assert.assertEquals("0.1", actions.get(0).getVersion()); + } + + @Test(dependsOnMethods = {"testGetByInvIdOnCreate"}) + public void testGetByIgnoreCaseName() { + List actions = + actionManager.getFilteredActions(ActionConstants.FILTER_TYPE_NAME, "acTion_2.0"); + List actualVersionList = new ArrayList(); + List expectedVersionList = new ArrayList(); + expectedVersionList.add("0.1"); + for (Action action : actions) { + System.out.println("action by testGetByIgnoreCaseName is::::"); + System.out.println(action.getActionInvariantUuId() + " " + action.getVersion()); + actualVersionList.add(action.getVersion()); + } + Assert.assertEquals(1, actions.size()); + Assert.assertEquals(expectedVersionList, actualVersionList); + } + + @Test(dependsOnMethods = {"testGetByInvIdOnCreate"}) + public void testGetByInvIdManyVersionWithoutSubmit() { + for (int i = 0; i < 11; i++) { + actionManager.checkin(action2Id, USER1); + actionManager.checkout(action2Id, USER1); + } + + List actions = actionManager.getActionsByActionInvariantUuId(action2Id); + List actualVersionList = new ArrayList(); + List expectedVersionList = new ArrayList(); + expectedVersionList.add("0.11"); + expectedVersionList.add("0.12"); + System.out.println(actions.size()); + for (Action action : actions) { + System.out.println("testGetByInvIdManyVersionWithoutSubmit is::::"); + System.out.println(action.getActionInvariantUuId() + " " + action.getVersion()); + actualVersionList.add(action.getVersion()); + } + Assert.assertEquals(2, actions.size()); + Assert.assertEquals(expectedVersionList, actualVersionList); + } + + @Test(dependsOnMethods = {"testGetByInvIdManyVersionWithoutSubmit"}) + public void testGetByInvIdManyVersionWithFirstSubmit() { + actionManager.checkin(action2Id, USER1);//Checkin 0.12 + actionManager.submit(action2Id, USER1); //1.0 + for (int i = 0; i < 11; i++) { + actionManager.checkout(action2Id, USER1); + actionManager.checkin(action2Id, USER1); + } + + List actions = actionManager.getActionsByActionInvariantUuId(action2Id); + List actualVersionList = new ArrayList(); + List expectedVersionList = new ArrayList(); + expectedVersionList.add("1.0"); + expectedVersionList.add("1.11"); + System.out.println(actions.size()); + for (Action action : actions) { + System.out.println("testGetByInvIdManyVersionWithFirstSubmit is::::"); + System.out.println(action.getActionInvariantUuId() + " " + action.getVersion()); + actualVersionList.add(action.getVersion()); + } + Assert.assertEquals(2, actions.size()); + Assert.assertEquals(expectedVersionList, actualVersionList); + } + + @Test(dependsOnMethods = {"testGetByInvIdManyVersionWithFirstSubmit"}) + public void testGetByInvIdManyVersionWithMultSubmit() { + actionManager.submit(action2Id, USER1); //2.0 + for (int i = 0; i < 11; i++) { + actionManager.checkout(action2Id, USER1); + actionManager.checkin(action2Id, USER1); + } + actionManager.checkout(action2Id, USER1); //2.12 + + List actions = actionManager.getActionsByActionInvariantUuId(action2Id); + List actualVersionList = new ArrayList(); + List expectedVersionList = new ArrayList(); + expectedVersionList.add("1.0"); + expectedVersionList.add("2.0"); + expectedVersionList.add("2.11"); + expectedVersionList.add("2.12"); + System.out.println(actions.size()); + for (Action action : actions) { + System.out.println("testGetByInvIdManyVersionWithMultSubmit is::::"); + System.out.println(action.getActionInvariantUuId() + " " + action.getVersion()); + actualVersionList.add(action.getVersion()); + } + Assert.assertEquals(4, actions.size()); + Assert.assertEquals(expectedVersionList, actualVersionList); + } + + @Test(dependsOnMethods = {"testGetByInvIdManyVersionWithMultSubmit"}) + public void testGetByInvIdOnName() { + for (int i = 0; i < 9; i++) { + actionManager.checkin(action2Id, USER1); + actionManager.checkout(action2Id, USER1); //2.21 + } + + List actions = + actionManager.getFilteredActions(ActionConstants.FILTER_TYPE_NAME, "Action_2.0"); + List actualVersionList = new ArrayList(); + List expectedVersionList = new ArrayList(); + expectedVersionList.add("1.0"); + expectedVersionList.add("2.0"); + expectedVersionList.add("2.20"); + expectedVersionList.add("2.21"); + for (Action action : actions) { + System.out.println("action by testGetByInvIdOnName is::::"); + System.out.println(action.getActionInvariantUuId() + " " + action.getVersion()); + actualVersionList.add(action.getVersion()); + } + Assert.assertEquals(4, actions.size()); + Assert.assertEquals(expectedVersionList, actualVersionList); + } + + @Test(dependsOnMethods = {"createTest"}) + public void testCreateWithExistingActionName_negative() { + try { + actionManager.createAction(createAction(ACTION_1), USER1); + Assert.fail(); + } catch (ActionException e) { + Assert.assertEquals(e.getErrorCode(), ActionErrorConstants.ACTION_ENTITY_UNIQUE_VALUE_ERROR); + } + } + + @Test(groups = "updateTestGroup", + dependsOnMethods = {"testCreateWithExistingActionName_negative", "createTest"}) + public void updateTest() { + List newSupportedComponents = new LinkedList<>(); + newSupportedComponents.add("Updated MSO"); + newSupportedComponents.add("Updated APPC"); + + List newSupportedModels = new LinkedList<>(); + newSupportedModels.add("Updated Model-1"); + newSupportedModels.add("Updated Model-2"); + + Action action = new Action(); + action.setActionInvariantUuId(action1Id); + action.setVersion(VERSION01.toString()); + ActionEntity existingActionEntity = actionDao.get(action.toEntity()); + existingActionEntity + .setSupportedComponents(newSupportedComponents); //Updating Supported components + existingActionEntity.setSupportedModels(newSupportedModels); //Updating supported models + //Persisting the updated entity + Action updatedAction = actionManager.updateAction(existingActionEntity.toDto(), USER1); + + //Create expected response template + ActionEntity expectedActionEntity = new ActionEntity(action1Id, VERSION01); + expectedActionEntity.setName(existingActionEntity.getName()); + expectedActionEntity.setActionUuId(existingActionEntity.getActionUuId()); + expectedActionEntity.setActionInvariantUuId(existingActionEntity.getActionInvariantUuId()); + expectedActionEntity.setData(existingActionEntity.getData()); + expectedActionEntity.setStatus(ActionStatus.Locked.name()); + expectedActionEntity.setSupportedComponents(newSupportedComponents); + expectedActionEntity.setSupportedModels(newSupportedModels); + Action expectedAction = updateData(expectedActionEntity.toDto()); + + assertActionEquals(updatedAction, expectedAction); + } + + @Test(groups = "updateTestGroup", dependsOnMethods = {"updateTest"}) + public void testUpdateName_negative() { + try { + Action action = new Action(); + action.setActionInvariantUuId(action1Id); + action.setVersion(VERSION01.toString()); + ActionEntity existingActionEntity = actionDao.get(action.toEntity()); + action = existingActionEntity.toDto(); + action.setName("Update - New Action Name"); + //Persisting the updated entity + actionManager.updateAction(action, USER1); + Assert.fail(); + } catch (ActionException e) { + Assert + .assertEquals(e.getErrorCode(), ActionErrorConstants.ACTION_UPDATE_NOT_ALLOWED_CODE_NAME); + } + } + + @Test(groups = "updateTestGroup", dependsOnMethods = {"updateTest"}) + public void testUpdateVersion_negative() { + try { + Action action = new Action(); + action.setActionInvariantUuId(action1Id); + action.setVersion(VERSION01.toString()); + ActionEntity existingActionEntity = actionDao.get(action.toEntity()); + action = existingActionEntity.toDto(); + action.setVersion("0.3"); + //Persisting the updated entity + actionManager.updateAction(action, USER1); + Assert.fail(); + } catch (ActionException e) { + Assert.assertEquals(e.getErrorCode(), ActionErrorConstants.ACTION_UPDATE_INVALID_VERSION); + } + } + + @Test(groups = "updateTestGroup", dependsOnMethods = {"updateTest"}) + public void testUpdateInvalidVersion_negative() { + try { + Action action = new Action(); + action.setActionInvariantUuId(action1Id); + action.setVersion(VERSION01.toString()); + ActionEntity existingActionEntity = actionDao.get(action.toEntity()); + //existingActionEntity.setDisplayName("Display Name Updated"); + Action updatedAction = existingActionEntity.toDto(); + updatedAction.setVersion("invalid_version_format"); + //Persisting the updated entity + actionManager.updateAction(updatedAction, USER1); + Assert.fail(); + } catch (ActionException e) { + Assert.assertEquals(e.getErrorCode(), ActionErrorConstants.ACTION_UPDATE_NOT_ALLOWED_CODE); + } + } + + /*@Test(groups = "updateTestGroup", dependsOnMethods = {"updateTest"}) + public void testUpdateStatusInvalidEnum_negative() { + try { + Action action = new Action(); + action.setActionInvariantUuId(action1Id); + action.setVersion(VERSION01.toString()); + ActionEntity existingActionEntity = actionDao.get(action.toEntity()); + existingActionEntity.setStatus("invalid_status_string"); + //Persisting the updated entity + actionManager.updateAction(existingActionEntity.toDto(),USER1); + Assert.fail(); + } catch (ActionException e) { + Assert.assertEquals(e.getErrorCode(), ActionErrorConstants.ACTION_UPDATE_NOT_ALLOWED_CODE); + } catch (IllegalArgumentException ie){ + String message = ie.getMessage(); + boolean result = message.contains("No enum constant"); + Assert.assertEquals(true, result); + } + }*/ + + @Test(groups = "updateTestGroup", dependsOnMethods = {"updateTest"}) + public void testUpdateInvariantId_negative() { + try { + Action action = new Action(); + action.setActionInvariantUuId(action1Id); + action.setVersion(VERSION01.toString()); + ActionEntity existingActionEntity = actionDao.get(action.toEntity()); + action = existingActionEntity.toDto(); + action.setActionInvariantUuId(UUID.randomUUID().toString()); + //Persisting the updated entity + actionManager.updateAction(action, USER1); + Assert.fail(); + } catch (ActionException e) { + Assert.assertEquals(e.getErrorCode(), ActionErrorConstants.ACTION_ENTITY_NOT_EXIST_CODE); + } + } + + @Test(groups = "updateTestGroup", dependsOnMethods = {"updateTest"}) + public void testUpdateUniqueId_negative() { + try { + Action action = new Action(); + action.setActionInvariantUuId(action1Id); + action.setVersion(VERSION01.toString()); + ActionEntity existingActionEntity = actionDao.get(action.toEntity()); + //existingActionEntity.setActionUuId(UUID.randomUUID().toString()); + + action = existingActionEntity.toDto(); + action.setActionUuId(UUID.randomUUID().toString()); + //Persisting the updated entity + //actionManager.updateAction(existingActionEntity.toDto(),USER1); + actionManager.updateAction(action, USER1); + Assert.fail(); + } catch (ActionException e) { + Assert.assertEquals(e.getErrorCode(), ActionErrorConstants.ACTION_UPDATE_NOT_ALLOWED_CODE); + } + } + + @Test(groups = "updateTestGroup", dependsOnMethods = {"updateTest"}) + public void testUpdateStatus_negative() { + try { + Action action = new Action(); + action.setActionInvariantUuId(action1Id); + action.setVersion(VERSION01.toString()); + ActionEntity existingActionEntity = actionDao.get(action.toEntity()); + action = existingActionEntity.toDto(); + action.setStatus(ActionStatus.Final); + //Persisting the updated entity + actionManager.updateAction(action, USER1); + Assert.fail(); + } catch (ActionException e) { + Assert.assertEquals(e.getErrorCode(), ActionErrorConstants.ACTION_UPDATE_NOT_ALLOWED_CODE); + } catch (IllegalArgumentException ie) { + String message = ie.getMessage(); + boolean result = message.contains("No enum constant"); + Assert.assertEquals(true, result); + } + } + + @Test(groups = "updateTestGroup", dependsOnMethods = {"updateTest"}) + public void testUpdateOtherUser_negative() { + try { + Action action = new Action(); + action.setActionInvariantUuId(action1Id); + action.setVersion(VERSION01.toString()); + ActionEntity existingActionEntity = actionDao.get(action.toEntity()); + action = existingActionEntity.toDto(); + //existingActionEntity.setDescription("Testing Update using other user"); + //Persisting the updated entity + actionManager.updateAction(action, USER2); + Assert.fail(); + } catch (ActionException e) { + Assert.assertEquals(e.getErrorCode(), + ActionErrorConstants.ACTION_EDIT_ON_ENTITY_LOCKED_BY_OTHER_USER); + } + } + + @Test(dependsOnMethods = {"createTest"}) + public void testCheckOutOnCheckOut() { + try { + actionManager.checkout(action1Id, USER1); + } catch (ActionException wae) { + Assert + .assertEquals(wae.getErrorCode(), ActionErrorConstants.ACTION_CHECKOUT_ON_LOCKED_ENTITY); + Assert.assertEquals(wae.getDescription(), + "Can not check out versionable entity Action with id " + action1Id + + " since it is checked out by other user: " + USER1 + "."); + } + } + + @Test(dependsOnMethods = {"createTest"}) + public void testCheckOutOnCheckOutWithOtherUser() { + try { + actionManager.checkout(action1Id, "invlaiduser"); + } catch (ActionException wae) { + Assert.assertEquals(wae.getErrorCode(), + ActionErrorConstants.ACTION_CHECKOUT_ON_LOCKED_ENTITY_OTHER_USER); + Assert.assertEquals(wae.getDescription(), + "Can not check out versionable entity Action with id " + action1Id + + " since it is checked out by other user: " + USER1 + "."); + } + } + + @Test(dependsOnGroups = {"updateTestGroup"}) + public void testCheckIn() { + Action action = actionManager.checkin(action1Id, USER1); + Assert.assertEquals(action.getActionInvariantUuId(), action1Id); + Assert.assertEquals(action.getStatus(), ActionStatus.Available); + Assert.assertEquals(action.getVersion(), VERSION01.toString()); + Assert.assertNotNull(action.getActionUuId()); + } + + @Test(dependsOnMethods = {"testCheckIn"}) + public void testUpdateOnCheckedInAction_negative() { + try { + Action action = new Action(); + action.setActionInvariantUuId(action1Id); + action.setVersion(VERSION01.toString()); + ActionEntity existingActionEntity = actionDao.get(action.toEntity()); + //existingActionEntity.setDescription("Testing Update On Checked In Action"); + //Persisting the updated entity + actionManager.updateAction(existingActionEntity.toDto(), USER1); + Assert.fail(); + } catch (ActionException e) { + Assert.assertEquals(e.getErrorCode(), ActionErrorConstants.ACTION_UPDATE_ON_UNLOCKED_ENTITY); + } + } + + @Test(dependsOnMethods = {"testUpdateOnCheckedInAction_negative"}) + public void testSubmit() { + Action action = actionManager.submit(action1Id, USER1); + ActionEntity loadedAction = actionDao.get(action.toEntity()); + assertActionEquals(action, loadedAction.toDto()); + } + + @Test(dependsOnMethods = {"testSubmit"}) + public void testCheckInWithoutCheckout() { + try { + actionManager.checkin(action1Id, "invaliduser"); + } catch (ActionException wae) { + Assert + .assertEquals(wae.getErrorCode(), ActionErrorConstants.ACTION_CHECKIN_ON_UNLOCKED_ENTITY); + Assert.assertEquals(wae.getDescription(), + "Can not check in versionable entity Action with id " + action1Id + + " since it is not checked out."); + } + } + + @Test(dependsOnMethods = {"testSubmit"}) + public void testCheckOut() { + final Version VERSION02 = new Version(1, 1); + Action action = null; + action = actionManager.checkout(action1Id, USER1); + ActionEntity loadedAction = actionDao.get(action.toEntity()); + assertActionEquals(action, loadedAction.toDto()); + } + + @Test(dependsOnMethods = {"testCheckOut"}) + public void testCheckInWithOtherUser() { + try { + actionManager.checkin(action1Id, "invaliduser"); + } catch (ActionException wae) { + Assert.assertEquals(wae.getErrorCode(), + ActionErrorConstants.ACTION_CHECKIN_ON_ENTITY_LOCKED_BY_OTHER_USER); + Assert.assertEquals(wae.getDescription(), + "Can not check in versionable entity Action with id " + action1Id + + " since it is checked out by other user: " + USER1 + "."); + } + } + + @Test(dependsOnMethods = {"testCheckOut"}) + public void testSubmitOnCheckout() { + try { + actionManager.submit(action1Id, USER1); + } catch (ActionException wae) { + Assert.assertEquals(wae.getErrorCode(), + ActionErrorConstants.ACTION_SUBMIT_LOCKED_ENTITY_NOT_ALLOWED); + Assert.assertEquals(wae.getDescription(), "Versionable entity Action with id " + action1Id + + " can not be submitted since it is currently locked by user " + USER1 + "."); + } + } + + @Test(dependsOnMethods = {"testCheckOut"}) + public void testUndoCheckout() { + final Version VERSION11 = new Version(1, 1); + actionManager.undoCheckout(action1Id, USER1); + Action action = new Action(); + action.setActionInvariantUuId(action1Id); + action.setVersion(VERSION11.toString()); + ActionEntity existingActionEntity = actionDao.get(action.toEntity()); + Assert.assertNull(existingActionEntity); + } + + @Test + public void testUndoCheckoutOnCreate() { + Action action = actionManager.createAction(createAction(ACTION_6), USER1); + actionManager.undoCheckout(action.getActionInvariantUuId(), USER1); + ActionEntity existingActionEntity = actionDao.get(action.toEntity()); + Assert.assertNull(existingActionEntity); + } + + @Test + public void testGetECOMPComponents() { + List componentList = actionManager.getEcompComponents(); + List expectedComponentList = new ArrayList<>(); + expectedComponentList.add(new EcompComponent("MSO", "COMP-1")); + expectedComponentList.add(new EcompComponent("APP-C", "COMP-2")); + for (EcompComponent e : componentList) { + boolean res = expectedComponentList.contains(e); + Assert.assertEquals(res, true); + } + } + + @Test + public void testgetActionsByActionUUID_Negative() { + try { + Action action = actionManager.getActionsByActionUuId(""); + Assert.fail(); + } catch (ActionException e) { + Assert.assertEquals(e.getErrorCode(), ActionErrorConstants.ACTION_ENTITY_NOT_EXIST_CODE); + } + } + + @Test(dependsOnMethods = {"createTest"}) + public void testgetActionsByActionUUID() { + Action action = actionManager.getActionsByActionUuId(actionUUId); + Assert.assertNotNull(action.getData()); + } + + @Test + public void testGetByCategory() { + createActionVersions(ACTION_2); + createActionVersions(ACTION_3); + createActionVersions(ACTION_4); + createActionVersions(ACTION_5); + List actions = + actionManager.getFilteredActions(ActionConstants.FILTER_TYPE_CATEGORY, "CAT-teSt"); + + List actualNameVersionList = new ArrayList(); + List expectedNameVersionList = new ArrayList(); + expectedNameVersionList.add("Test_Action4_list:2.2"); + expectedNameVersionList.add("Test_Action4_list:2.0"); + expectedNameVersionList.add("Test_Action2_list:2.2"); + expectedNameVersionList.add("Test_Action2_list:2.0"); + for (Action action : actions) { + System.out.println("action by category is::::"); + System.out.println(action.getName() + " " + action.getVersion()); + actualNameVersionList.add(action.getName() + ":" + action.getVersion()); + } + Assert.assertEquals(4, actions.size()); + Assert.assertEquals(expectedNameVersionList, actualNameVersionList); + } + + @Test(dependsOnMethods = {"testGetByCategory"}) + public void testGetByVendor() { + List actions = + actionManager.getFilteredActions(ActionConstants.FILTER_TYPE_VENDOR, "VendOr-tESt"); + + List actualNameVersionList = new ArrayList(); + List expectedNameVersionList = new ArrayList(); + expectedNameVersionList.add("Test_Action5_list:2.2"); + expectedNameVersionList.add("Test_Action5_list:2.0"); + expectedNameVersionList.add("Test_Action3_list:2.2"); + expectedNameVersionList.add("Test_Action3_list:2.0"); + for (Action action : actions) { + System.out.println("action by category is::::"); + System.out.println(action.getName() + " " + action.getVersion()); + actualNameVersionList.add(action.getName() + ":" + action.getVersion()); + } + Assert.assertEquals(4, actions.size()); + Assert.assertEquals(expectedNameVersionList, actualNameVersionList); + } + + @Test(dependsOnMethods = {"testGetByCategory"}) + public void testGetBySupportedModel() { + List actions = + actionManager.getFilteredActions(ActionConstants.FILTER_TYPE_MODEL, "MODEL-tEst"); + + List actualNameVersionList = new ArrayList<>(); + List expectedNameVersionList = new ArrayList<>(); + expectedNameVersionList.add("Test_Action4_list:2.2"); + expectedNameVersionList.add("Test_Action4_list:2.0"); + expectedNameVersionList.add("Test_Action2_list:2.2"); + expectedNameVersionList.add("Test_Action2_list:2.0"); + for (Action action : actions) { + actualNameVersionList.add(action.getName() + ":" + action.getVersion()); + } + Assert.assertEquals(4, actions.size()); + Assert.assertEquals(expectedNameVersionList, actualNameVersionList); + } + + @Test(dependsOnMethods = {"testGetByCategory"}) + public void testGetBySupportedComponent() { + List actions = + actionManager.getFilteredActions(ActionConstants.FILTER_TYPE_ECOMP_COMPONENT, "mso"); + + List actualNameVersionList = new ArrayList<>(); + List expectedNameVersionList = new ArrayList<>(); + expectedNameVersionList.add("Test_Action5_list:2.2"); + expectedNameVersionList.add("Test_Action5_list:2.0"); + expectedNameVersionList.add("Test_Action3_list:2.2"); + expectedNameVersionList.add("Test_Action3_list:2.0"); + for (Action action : actions) { + actualNameVersionList.add(action.getName() + ":" + action.getVersion()); + } + Assert.assertEquals(4, actions.size()); + Assert.assertEquals(expectedNameVersionList, actualNameVersionList); + } + + @Test(dependsOnMethods = {"testGetByCategory"}) + public void testGetAllActions() { + List actions = + actionManager.getFilteredActions(ActionConstants.FILTER_TYPE_NONE, "MSO"); + + List actualNameVersionList = new ArrayList<>(); + List expectedNameVersionList = new ArrayList<>(); + + expectedNameVersionList.add("Test_Action5_list:2.2"); + expectedNameVersionList.add("Test_Action5_list:2.0"); + expectedNameVersionList.add("Test_Action3_list:2.2"); + expectedNameVersionList.add("Test_Action3_list:2.0"); + expectedNameVersionList.add("Test_Action4_list:2.2"); + expectedNameVersionList.add("Test_Action4_list:2.0"); + expectedNameVersionList.add("Test_Action2_list:2.2"); + expectedNameVersionList.add("Test_Action2_list:2.0"); + for (Action action : actions) { + actualNameVersionList.add(action.getName() + ":" + action.getVersion()); + } + Assert.assertEquals(8, actions.size()); + + for (String s : actualNameVersionList) { + boolean res = expectedNameVersionList.contains(s); + Assert.assertEquals(res, true); + } + } + + @Test(dependsOnMethods = {"testGetAllActions"}) + public void testDeleteCheckedOutAction_Negative() { + try { + initDeleteActionTest(); + String deleteActionInvariantId = deleteAction.getActionInvariantUuId(); + actionManager.deleteAction(deleteActionInvariantId, USER1); + Assert.fail(); + } catch (ActionException e) { + Assert.assertEquals(e.getErrorCode(), ActionErrorConstants.ACTION_DELETE_ON_LOCKED_ENTITY_CODE); + Assert.assertEquals(e.getDescription(), String.format( + "Can not delete versionable entity Action with id %s since it is checked out by other user: %s", + deleteAction.getActionInvariantUuId(), USER1 + ".")); + } + } + + @Test(dependsOnMethods = {"testDeleteCheckedOutAction_Negative"}) + public void testDeleteAction() { + try { + String deleteActionInvariantId = deleteAction.getActionInvariantUuId(); + actionManager.checkin(deleteActionInvariantId, USER1); + actionManager.deleteAction(deleteActionInvariantId, USER1); + } catch (ActionException e) { + Assert.fail("Delete action test failed with exception : " + e.getDescription()); + } + } + + @Test(dependsOnMethods = {"testDeleteAction"}) + public void testDeletedActionVersioningOperations_Negative() { + String deleteActionInvariantId = deleteAction.getActionInvariantUuId(); + try { + actionManager.checkout(deleteActionInvariantId, USER1); + Assert.fail(); + } catch (ActionException e) { + Assert.assertEquals(e.getErrorCode(), ActionErrorConstants.ACTION_ENTITY_NOT_EXIST_CODE); + Assert.assertEquals(e.getDescription(), ActionErrorConstants.ACTION_ENTITY_NOT_EXIST); + } + try { + actionManager.checkin(deleteActionInvariantId, USER1); + Assert.fail(); + } catch (ActionException e) { + Assert.assertEquals(e.getErrorCode(), ActionErrorConstants.ACTION_ENTITY_NOT_EXIST_CODE); + Assert.assertEquals(e.getDescription(), ActionErrorConstants.ACTION_ENTITY_NOT_EXIST); + } + try { + actionManager.submit(deleteActionInvariantId, USER1); + Assert.fail(); + } catch (ActionException e) { + Assert.assertEquals(e.getErrorCode(), ActionErrorConstants.ACTION_ENTITY_NOT_EXIST_CODE); + Assert.assertEquals(e.getDescription(), ActionErrorConstants.ACTION_ENTITY_NOT_EXIST); + } + try { + actionManager.undoCheckout(deleteActionInvariantId, USER1); + Assert.fail(); + } catch (ActionException e) { + Assert.assertEquals(e.getErrorCode(), ActionErrorConstants.ACTION_ENTITY_NOT_EXIST_CODE); + Assert.assertEquals(e.getDescription(), ActionErrorConstants.ACTION_ENTITY_NOT_EXIST); + } + try { + actionManager.deleteAction(deleteActionInvariantId, USER1); + Assert.fail(); + } catch (ActionException e) { + Assert.assertEquals(e.getErrorCode(), ActionErrorConstants.ACTION_ENTITY_NOT_EXIST_CODE); + Assert.assertEquals(e.getDescription(), ActionErrorConstants.ACTION_ENTITY_NOT_EXIST); + } + } + + @Test(dependsOnMethods = {"testDeleteAction"}) + public void testCreateActionWithDeletedActionName_Negative() { + try { + actionManager.createAction(createAction(ACTION_TEST_DELETE), USER1); + Assert.fail(); + } catch (ActionException e) { + Assert.assertEquals(e.getErrorCode(), ActionErrorConstants.ACTION_ENTITY_UNIQUE_VALUE_ERROR); + Assert.assertEquals(e.getDescription(), String + .format(ActionErrorConstants.ACTION_ENTITY_UNIQUE_VALUE_MSG, ActionConstants.UniqueValues.ACTION_NAME, + deleteAction.getName())); + } + } + + @Test(dependsOnMethods = {"testDeleteAction"}) + public void testDeletedActionGetQueries() { + String deleteActionInvariantId = deleteAction.getActionInvariantUuId(); + List invariantFetchResults = + actionManager.getActionsByActionInvariantUuId(deleteActionInvariantId); + Assert.assertEquals(invariantFetchResults.size(), 3); + for (Action a : invariantFetchResults) { + Assert.assertEquals(a.getStatus(), ActionStatus.Deleted); + } + + Action actionUUIDFetchResult = + actionManager.getActionsByActionUuId(deleteAction.getActionUuId()); + Assert.assertEquals(actionUUIDFetchResult.getStatus(), ActionStatus.Deleted); + + List nameFetchResults = + actionManager.getFilteredActions(ActionConstants.FILTER_TYPE_NAME, "Test_Delete_Action"); + Assert.assertEquals(nameFetchResults.size(), 3); + for (Action a : nameFetchResults) { + Assert.assertEquals(a.getStatus(), ActionStatus.Deleted); + } + + List filteredActions = + actionManager.getFilteredActions(ActionConstants.FILTER_TYPE_VENDOR, "Vendor-Delete"); + Assert.assertEquals(filteredActions.size(), 0); + filteredActions = + actionManager.getFilteredActions(ActionConstants.FILTER_TYPE_CATEGORY, "Cat-Delete-test"); + Assert.assertEquals(filteredActions.size(), 0); + filteredActions = + actionManager.getFilteredActions(ActionConstants.FILTER_TYPE_ECOMP_COMPONENT, "MSO-delete"); + Assert.assertEquals(filteredActions.size(), 0); + filteredActions = + actionManager.getFilteredActions(ActionConstants.FILTER_TYPE_MODEL, "Model-Delete"); + Assert.assertEquals(filteredActions.size(), 0); + } + + /*** + * ACTION ARTIFACT OPERATION TEST CASES + ***/ + + @Test + public void testUploadArtifact() { + actionArtifact = new ActionArtifact(); + File resourceFile = new File( + this.getClass().getClassLoader().getResource(ACTION_TEST_ARTIFACT_FILE_NAME).getPath()); + FileInputStream fileInputStream; + //Create payload from the test resource file + byte[] payload = new byte[(int) resourceFile.length()]; + try { + fileInputStream = new FileInputStream(resourceFile); + fileInputStream.read(payload); + fileInputStream.close(); + actionArtifact.setArtifact(payload); + actionArtifact.setArtifactName(ACTION_TEST_ARTIFACT_FILE_NAME); + actionArtifact.setArtifactLabel("Test Artifact Label"); + actionArtifact.setArtifactDescription("Test Artifact Description"); + actionArtifact.setArtifactProtection(ActionArtifactProtection.readWrite.name()); + } catch (IOException e) { + e.printStackTrace(); + } + + //Create action for artifact upload test + testArtifactAction = actionManager.createAction(createAction(ARTIFACT_TEST_ACTION), USER1); + //Generate Expected artifact UUID + expectedArtifactUUID = + generateActionArtifactUUID(testArtifactAction, ACTION_TEST_ARTIFACT_FILE_NAME); + //Upload the artifact + ActionArtifact response = actionManager + .uploadArtifact(actionArtifact, testArtifactAction.getActionInvariantUuId(), USER1); + //Validate if generated and the expected artifact UUID is same + Assert.assertEquals(expectedArtifactUUID, response.getArtifactUuId()); + //Fetch the data field of the updated action version + Action updatedAction = actionManager.getActionsByActionUuId(testArtifactAction.getActionUuId()); + List updatedArtifactList = updatedAction.getArtifacts(); + for (ActionArtifact artifact : updatedArtifactList) { + //Validate the artifact metadata + Assert.assertEquals(artifact.getArtifactName(), actionArtifact.getArtifactName()); + Assert.assertEquals(artifact.getArtifactLabel(), actionArtifact.getArtifactLabel()); + Assert + .assertEquals(artifact.getArtifactDescription(), actionArtifact.getArtifactDescription()); + Assert.assertEquals(artifact.getArtifactProtection(), actionArtifact.getArtifactProtection()); + } + } + + @Test(dependsOnMethods = {"testUploadArtifact"}) + public void testUploadArtifactInvalidActionInvId_negative() { + ActionArtifact testArtifact = new ActionArtifact(); + testArtifact.setArtifact("testData".getBytes()); + testArtifact.setArtifactName(ACTION_TEST_ARTIFACT_FILE_NAME); + try { + actionManager.uploadArtifact(testArtifact, "INVALID_UUID", USER1); + } catch (ActionException ae) { + Assert.assertEquals(ae.getErrorCode(), ActionErrorConstants.ACTION_ENTITY_NOT_EXIST_CODE); + Assert.assertEquals(ae.getDescription(), ActionErrorConstants.ACTION_ENTITY_NOT_EXIST); + } + } + + @Test(dependsOnMethods = {"testUploadArtifact"}) + public void testUploadArtifactSameName_negative() { + try { + actionManager + .uploadArtifact(actionArtifact, testArtifactAction.getActionInvariantUuId(), USER1); + } catch (ActionException ae) { + Assert.assertEquals(ae.getErrorCode(), ActionErrorConstants.ACTION_ARTIFACT_ALREADY_EXISTS_CODE); + Assert.assertEquals(ae.getDescription(), String + .format(ActionErrorConstants.ACTION_ARTIFACT_ALREADY_EXISTS, testArtifactAction.getActionInvariantUuId())); + } + } + + @Test(dependsOnMethods = {"testUploadArtifact"}) + public void testUploadArtifactCheckedOutOtherUser_negative() { + try { + actionManager + .uploadArtifact(actionArtifact, testArtifactAction.getActionInvariantUuId(), USER2); + } catch (ActionException ae) { + Assert.assertEquals(ae.getErrorCode(), ActionErrorConstants.ACTION_EDIT_ON_ENTITY_LOCKED_BY_OTHER_USER); + Assert.assertEquals(ae.getDescription(), + "Versionable entity Action with id " + testArtifactAction.getActionInvariantUuId() + + " can not be updated since it is locked by other user " + USER1 + "."); + } + } + + @Test(dependsOnMethods = {"testUploadArtifact"}) + public void testUploadArtifactUnlockedAction_negative() { + try { + testArtifactAction = + actionManager.checkin(testArtifactAction.getActionInvariantUuId(), USER1); + actionManager + .uploadArtifact(actionArtifact, testArtifactAction.getActionInvariantUuId(), USER1); + } catch (ActionException ae) { + Assert.assertEquals(ae.getErrorCode(), ActionErrorConstants.ACTION_UPDATE_ON_UNLOCKED_ENTITY); + Assert.assertEquals(ae.getDescription(), "Can not update versionable entity Action with id " + + testArtifactAction.getActionInvariantUuId() + " since it is not checked out."); + } + } + + @Test(dependsOnMethods = {"testUploadArtifact"}) + public void testDownloadArtifact() { + String actionUUID = testArtifactAction.getActionUuId(); + ActionArtifact response = actionManager.downloadArtifact(actionUUID, expectedArtifactUUID); + Assert.assertEquals(actionArtifact.getArtifactName(), response.getArtifactName()); + Assert.assertEquals(actionArtifact.getArtifact(), response.getArtifact()); + } + + @Test(dependsOnMethods = {"testUploadArtifact"}) + public void testDownloadArtifactNegativeInvalidArtifact() { + String actionUUID = testArtifactAction.getActionUuId(); + String artifactUUID = "negativeArtifact"; + try { + ActionArtifact response = actionManager.downloadArtifact(actionUUID, artifactUUID); + } catch (ActionException ae) { + Assert.assertEquals(ae.getErrorCode(), ActionErrorConstants.ACTION_ARTIFACT_ENTITY_NOT_EXIST_CODE); + } + + } + + @Test + public void testDownloadArtifactNegativeInvalidAction() { + String actionUUID = "NegativeAction"; + try { + ActionArtifact response = actionManager.downloadArtifact(actionUUID, expectedArtifactUUID); + } catch (ActionException ae) { + Assert.assertEquals(ae.getErrorCode(), ActionErrorConstants.ACTION_ENTITY_NOT_EXIST_CODE); + } + + } + + @Test + public void testDeleteArtifactInvalidActInvId() { + try { + actionManager.deleteArtifact("action2Id", "1234", USER1); + } catch (ActionException e) { + Assert.assertEquals(e.getErrorCode(), ActionErrorConstants.ACTION_ENTITY_NOT_EXIST_CODE); + Assert.assertEquals(e.getDescription(), ActionErrorConstants.ACTION_ENTITY_NOT_EXIST); + } + } + + @Test(dependsOnMethods = {"testGetByInvIdOnCreate"}) + public void testDeleteArtifactInvalidArtifactUUID() { + try { + actionManager.deleteArtifact(action2Id, "1234", USER1); + } catch (ActionException e) { + Assert.assertEquals(e.getErrorCode(), + ActionErrorConstants.ACTION_ARTIFACT_ENTITY_NOT_EXIST_CODE); + Assert + .assertEquals(e.getDescription(), ActionErrorConstants.ACTION_ARTIFACT_ENTITY_NOT_EXIST); + } + } + + @Test(dependsOnMethods = {"testUploadArtifact"}) + public void testDeleteReadOnlyArtifact() { + ActionArtifact testArtifact = null; + String artifactUUID = null; + try { + testArtifact = new ActionArtifact(); + testArtifact.setArtifact("testData".getBytes()); + testArtifact.setArtifactProtection(ActionArtifactProtection.readOnly.name()); + testArtifact.setArtifactName("TestRO.txt"); + actionManager + .uploadArtifact(testArtifact, testArtifactAction.getActionInvariantUuId(), USER1); + artifactUUID = testArtifact.getArtifactUuId(); + actionManager.deleteArtifact(testArtifactAction.getActionInvariantUuId(), + testArtifact.getArtifactUuId(), USER1); + + } catch (ActionException e) { + Assert.assertEquals(e.getErrorCode(), ActionErrorConstants.ACTION_ARTIFACT_DELETE_READ_ONLY); + Assert.assertEquals(e.getDescription(), + ActionErrorConstants.ACTION_ARTIFACT_DELETE_READ_ONLY_MSG); + } + + //cleanup uploaded document after test + testArtifact = new ActionArtifact(); + testArtifact.setArtifactUuId(artifactUUID); + testArtifact.setArtifactProtection(ActionArtifactProtection.readWrite.name()); + actionManager.updateArtifact(testArtifact, testArtifactAction.getActionInvariantUuId(), USER1); + actionManager + .deleteArtifact(testArtifactAction.getActionInvariantUuId(), testArtifact.getArtifactUuId(), + USER1); + } + + @Test(dependsOnMethods = {"testUploadArtifact"}) + public void testDeleteArtifactLockedByOtherUser() { + try { + actionManager.deleteArtifact(testArtifactAction.getActionInvariantUuId(), + actionArtifact.getArtifactUuId(), USER2); + } catch (ActionException ae) { + Assert.assertEquals(ae.getErrorCode(), ActionErrorConstants.ACTION_ARTIFACT_DEL_LOCKED_OTHER_USER_CODE); + Assert.assertEquals(ae.getDescription(), + String.format(ActionErrorConstants.ACTION_ARTIFACT_DEL_LOCKED_OTHER_USER, USER1)); + } + } + + @Test(dependsOnMethods = {"testUploadArtifactUnlockedAction_negative"}) + public void testDeleteArtifactOnUnlockedAction() { + try { + actionManager.deleteArtifact(testArtifactAction.getActionInvariantUuId(), + actionArtifact.getArtifactUuId(), USER1); + } catch (ActionException ae) { + Assert.assertEquals(ae.getErrorCode(), ActionErrorConstants.ACTION_NOT_LOCKED_CODE); + Assert.assertEquals(ae.getDescription(), ActionErrorConstants.ACTION_NOT_LOCKED_MSG); + } + } + + @Test(dependsOnMethods = {"testUploadArtifact"}) + public void testDeleteArtifact() { + try { + ActionArtifact testArtifact = new ActionArtifact(); + testArtifact.setArtifact("testData".getBytes()); + testArtifact.setArtifactName("Test_ToBeDel.txt"); + testArtifact.setArtifactProtection(ActionArtifactProtection.readWrite.name()); + actionManager + .uploadArtifact(testArtifact, testArtifactAction.getActionInvariantUuId(), USER1); + actionManager.deleteArtifact(testArtifactAction.getActionInvariantUuId(), + testArtifact.getArtifactUuId(), USER1); + ActionArtifact response = actionManager + .downloadArtifact(testArtifactAction.getActionUuId(), testArtifact.getArtifactUuId()); + } catch (ActionException e) { + Assert.assertEquals(e.getErrorCode(), + ActionErrorConstants.ACTION_ARTIFACT_ENTITY_NOT_EXIST_CODE); + Assert + .assertEquals(e.getDescription(), ActionErrorConstants.ACTION_ARTIFACT_ENTITY_NOT_EXIST); + } + } + + @Test(dependsOnMethods = {"testUploadArtifact"}) + public void testUpdateArtifact() { + ActionArtifact updatedArtifact = new ActionArtifact(); + File resourceFile = new File( + this.getClass().getClassLoader().getResource(ACTION_TEST_UPDATE_ARTIFACT_FILE_NAME) + .getPath()); + FileInputStream fileInputStream; + //Create payload from the test resource file + byte[] payload = new byte[(int) resourceFile.length()]; + try { + fileInputStream = new FileInputStream(resourceFile); + fileInputStream.read(payload); + fileInputStream.close(); + updatedArtifact.setArtifactUuId( + generateActionArtifactUUID(testArtifactAction, ACTION_TEST_ARTIFACT_FILE_NAME)); + updatedArtifact.setArtifact(payload); + updatedArtifact.setArtifactName(ACTION_TEST_ARTIFACT_FILE_NAME); + updatedArtifact.setArtifactLabel("Test Artifact Update Label"); + updatedArtifact.setArtifactDescription("Test Artifact Update Description"); + updatedArtifact.setArtifactProtection(ActionArtifactProtection.readWrite.name()); + } catch (IOException e) { + e.printStackTrace(); + } + + String actionInvarientUUID = testArtifactAction.getActionInvariantUuId(); + actionManager.updateArtifact(updatedArtifact, actionInvarientUUID, USER1); + + String actionUUID = testArtifactAction.getActionUuId(); + Action action = actionManager.getActionsByActionUuId(actionUUID); + List artifacts = action.getArtifacts(); + for (ActionArtifact actionArtifact : artifacts) { + Assert.assertEquals(actionArtifact.getArtifactName(), updatedArtifact.getArtifactName()); + Assert.assertEquals(actionArtifact.getArtifactLabel(), updatedArtifact.getArtifactLabel()); + Assert.assertEquals(actionArtifact.getArtifactDescription(), + updatedArtifact.getArtifactDescription()); + Assert.assertEquals(actionArtifact.getArtifactProtection(), + updatedArtifact.getArtifactProtection()); + } + } + + @Test(dependsOnMethods = {"testUploadArtifact"}) + public void testUpdateArtifact_ArtifactNotPresent_Negative() { + ActionArtifact invalidActionArtifact = new ActionArtifact(); + String artifactUUID = generateActionArtifactUUID(testArtifactAction, "ArtifactNotPresent"); + invalidActionArtifact.setArtifactUuId(artifactUUID); + try { + actionManager + .updateArtifact(invalidActionArtifact, testArtifactAction.getActionInvariantUuId(), + USER1); + } catch (ActionException actionException) { + Assert.assertEquals(actionException.getDescription(), ActionErrorConstants.ACTION_ARTIFACT_ENTITY_NOT_EXIST); + } + } + + @Test(dependsOnMethods = {"testUploadArtifact"}) + public void testUpdateArtifact_ArtifactNameUpdate_Negative() { + String invariantUUID = testArtifactAction.getActionInvariantUuId(); + ActionArtifact artifactToUpdate = new ActionArtifact(); + artifactToUpdate.setArtifactUuId(actionArtifact.getArtifactUuId()); + artifactToUpdate.setArtifactName("UpdatingName"); + + try { + actionManager.updateArtifact(artifactToUpdate, invariantUUID, USER1); + } catch (ActionException actionException) { + Assert.assertEquals(actionException.getDescription(), ActionErrorConstants.ACTION_ARTIFACT_UPDATE_NAME_INVALID); + } + } + + @Test(dependsOnMethods = {"testUploadArtifact"}) + void testUpdateArtifact_CheckoutByOtherUser_Negative() { + String invariantUUID = testArtifactAction.getActionInvariantUuId(); + ActionArtifact artifactToUpdate = new ActionArtifact(); + artifactToUpdate.setArtifactUuId(actionArtifact.getArtifactUuId()); + artifactToUpdate.setArtifactLabel("CheckoutbyOtherUser label"); + + try { + actionManager.updateArtifact(artifactToUpdate, invariantUUID, USER2); + } catch (ActionException actionException) { + Assert + .assertEquals(actionException.getErrorCode(), ActionErrorConstants.ACTION_EDIT_ON_ENTITY_LOCKED_BY_OTHER_USER); + Assert.assertEquals(actionException.getDescription(), + "Versionable entity Action with id " + invariantUUID + + " can not be updated since it is locked by other user " + USER1 + "."); + } + System.out.println("asdf"); + } + + @Test(dependsOnMethods = {"testUploadArtifact"}) + void testUpdateArtifact_ArtifactProtectionReadOnly_CanNotUpdate_Negative() { + String invariantUUID = testArtifactAction.getActionInvariantUuId(); + ActionArtifact artifactToUpdate = new ActionArtifact(); + artifactToUpdate.setArtifactUuId(actionArtifact.getArtifactUuId()); + artifactToUpdate.setArtifactProtection(ActionArtifactProtection.readOnly.name()); + actionManager.updateArtifact(artifactToUpdate, invariantUUID, USER1); + + artifactToUpdate.setArtifactLabel("test label"); + artifactToUpdate.setArtifactDescription("test description"); + artifactToUpdate.setArtifactProtection(ActionArtifactProtection.readWrite.name()); + try { + actionManager.updateArtifact(artifactToUpdate, invariantUUID, USER1); + } catch (ActionException actionExecption) { + Assert.assertEquals(actionExecption.getDescription(), ActionErrorConstants.ACTION_ARTIFACT_UPDATE_READ_ONLY_MSG); + } + } + + // Function which will take action as input string and create action + // After create multiple versions of same action + // Final versions :1.0, 2.0 + // Last minor version :2.2 + // Candidate version :2.3 + private void createActionVersions(String input) { + Action action1 = createAction(input); + Action action = actionManager.createAction(action1, USER1); + String Id = action.getActionInvariantUuId(); + + actionManager.checkin(Id, USER1); + actionManager.submit(Id, USER1); // 1.0 + actionManager.checkout(Id, USER1); + actionManager.checkin(Id, USER1); + actionManager.submit(Id, USER1);//2.0 + actionManager.checkout(Id, USER1); + actionManager.checkin(Id, USER1); + actionManager.checkout(Id, USER1); + actionManager.checkin(Id, USER1); //2.2 + actionManager.checkout(Id, USER1); //2.3 candidate + } + + private Action updateData(Action action) { + Map dataMap = new LinkedHashMap<>(); + dataMap.put(ActionConstants.UNIQUE_ID, action.getActionUuId()); + dataMap.put(ActionConstants.VERSION, action.getVersion()); + dataMap.put(ActionConstants.INVARIANTUUID, action.getActionInvariantUuId()); + dataMap.put(ActionConstants.STATUS, ActionStatus.Locked.name()); + + String data = action.getData(); + Map currentDataMap = JsonUtil.json2Object(data, LinkedHashMap.class); + dataMap.putAll(currentDataMap); + data = JsonUtil.object2Json(dataMap); + action.setData(data); + return action; + } + + private void initDeleteActionTest() { + deleteAction = actionManager.createAction(createAction(ACTION_TEST_DELETE), USER1); + String deleteActionInvariantId = deleteAction.getActionInvariantUuId(); + actionManager.checkin(deleteActionInvariantId, USER1); + actionManager.submit(deleteActionInvariantId, USER1); // 1.0 + actionManager.checkout(deleteActionInvariantId, USER1); + actionManager.checkin(deleteActionInvariantId, USER1); + actionManager.submit(deleteActionInvariantId, USER1);//2.0 + actionManager.checkout(deleteActionInvariantId, USER1); + } + + private int getEffectiveVersion(String actionVersion) { + Version version = Version.valueOf(actionVersion); + return version.getMajor() * 10000 + version.getMinor(); + } + + private String generateActionArtifactUUID(Action action, String artifactName) { + int effectiveVersion = getEffectiveVersion(action.getVersion()); + //Upper case for maintaining case-insensitive behavior for the artifact names + String artifactUUIDString = + action.getName().toUpperCase() + effectiveVersion + artifactName.toUpperCase(); + String generateArtifactUUID = + UUID.nameUUIDFromBytes((artifactUUIDString).getBytes()).toString(); + String artifactUUID = generateArtifactUUID.replace("-", ""); + return artifactUUID.toUpperCase(); + } + +} diff --git a/openecomp-be/backend/openecomp-sdc-action-manager/src/test/resources/test_artifact_file.txt b/openecomp-be/backend/openecomp-sdc-action-manager/src/test/resources/test_artifact_file.txt new file mode 100644 index 0000000000..15752ea310 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-action-manager/src/test/resources/test_artifact_file.txt @@ -0,0 +1,2 @@ +Upload_Artifacts. +The test verifies uploading an artifact when action status is locked. \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-action-manager/src/test/resources/test_artifact_update_file.txt b/openecomp-be/backend/openecomp-sdc-action-manager/src/test/resources/test_artifact_update_file.txt new file mode 100644 index 0000000000..940aedfc85 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-action-manager/src/test/resources/test_artifact_update_file.txt @@ -0,0 +1,2 @@ +Update_Artifacts. +The test verifies updating an artifact when action status is locked. \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-action-manager/test-output/Default suite/Default test.html b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/Default suite/Default test.html new file mode 100644 index 0000000000..d0d707db79 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/Default suite/Default test.html @@ -0,0 +1,324 @@ + + +TestNG: Default test + + + + + + + + +

Default test

+ + + + + + + + + + + +
Tests passed/Failed/Skipped:49/0/0
Started on:Thu Sep 08 12:49:36 IST 2016
Total time:6 seconds (6008 ms)
Included groups:
Excluded groups:

+(Hover the method name to see the test class name)

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
PASSED TESTS
Test methodExceptionTime (seconds)Instance
createTest
Test class: ActionTest
0ActionTest@5b367418
testCheckIn
Test class: ActionTest
0ActionTest@5b367418
testCheckInWithOtherUser
Test class: ActionTest
0ActionTest@5b367418
testCheckInWithoutCheckout
Test class: ActionTest
0ActionTest@5b367418
testCheckOut
Test class: ActionTest
0ActionTest@5b367418
testCheckOutOnCheckOut
Test class: ActionTest
0ActionTest@5b367418
testCheckOutOnCheckOutWithOtherUser
Test class: ActionTest
0ActionTest@5b367418
testCreateWithExistingActionName_negative
Test class: ActionTest
0ActionTest@5b367418
testDeleteArtifact
Test class: ActionTest
0ActionTest@5b367418
testDeleteArtifactInvalidActInvId
Test class: ActionTest
0ActionTest@5b367418
testDeleteArtifactInvalidArtifactUUID
Test class: ActionTest
0ActionTest@5b367418
testDeleteArtifactLockedByOtherUser
Test class: ActionTest
0ActionTest@5b367418
testDeleteArtifactOnUnlockedAction
Test class: ActionTest
0ActionTest@5b367418
testDeleteReadOnlyArtifact
Test class: ActionTest
0ActionTest@5b367418
testDownloadArtifact
Test class: ActionTest
0ActionTest@5b367418
testDownloadArtifactNegativeInvalidAction
Test class: ActionTest
0ActionTest@5b367418
testDownloadArtifactNegativeInvalidArtifact
Test class: ActionTest
0ActionTest@5b367418
testGetAllActions
Test class: ActionTest
0ActionTest@5b367418
testGetByCategory
Test class: ActionTest
0ActionTest@5b367418
testGetByIgnoreCaseName
Test class: ActionTest
0ActionTest@5b367418
testGetByInvIdManyVersionWithFirstSubmit
Test class: ActionTest
0ActionTest@5b367418
testGetByInvIdManyVersionWithMultSubmit
Test class: ActionTest
0ActionTest@5b367418
testGetByInvIdManyVersionWithoutSubmit
Test class: ActionTest
0ActionTest@5b367418
testGetByInvIdOnCreate
Test class: ActionTest
0ActionTest@5b367418
testGetByInvIdOnName
Test class: ActionTest
0ActionTest@5b367418
testGetBySupportedComponent
Test class: ActionTest
0ActionTest@5b367418
testGetBySupportedModel
Test class: ActionTest
0ActionTest@5b367418
testGetByVendor
Test class: ActionTest
0ActionTest@5b367418
testGetECOMPComponents
Test class: ActionTest
0ActionTest@5b367418
testSubmit
Test class: ActionTest
0ActionTest@5b367418
testSubmitOnCheckout
Test class: ActionTest
0ActionTest@5b367418
testUndoCheckout
Test class: ActionTest
0ActionTest@5b367418
testUpdateArtifact
Test class: ActionTest
0ActionTest@5b367418
testUpdateInvalidVersion_negative
Test class: ActionTest
0ActionTest@5b367418
testUpdateInvariantId_negative
Test class: ActionTest
0ActionTest@5b367418
testUpdateName_negative
Test class: ActionTest
0ActionTest@5b367418
testUpdateOnCheckedInAction_negative
Test class: ActionTest
0ActionTest@5b367418
testUpdateOtherUser_negative
Test class: ActionTest
0ActionTest@5b367418
testUpdateStatus_negative
Test class: ActionTest
0ActionTest@5b367418
testUpdateUniqueId_negative
Test class: ActionTest
0ActionTest@5b367418
testUpdateVersion_negative
Test class: ActionTest
0ActionTest@5b367418
testUploadArtifact
Test class: ActionTest
0ActionTest@5b367418
testUploadArtifactCheckedOutOtherUser_negative
Test class: ActionTest
0ActionTest@5b367418
testUploadArtifactInvalidActionInvId_negative
Test class: ActionTest
0ActionTest@5b367418
testUploadArtifactSameName_negative
Test class: ActionTest
0ActionTest@5b367418
testUploadArtifactUnlockedAction_negative
Test class: ActionTest
0ActionTest@5b367418
testgetActionsByActionUUID
Test class: ActionTest
0ActionTest@5b367418
testgetActionsByActionUUID_Negative
Test class: ActionTest
0ActionTest@5b367418
updateTest
Test class: ActionTest
0ActionTest@5b367418

+ + \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-action-manager/test-output/Default suite/Default test.xml b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/Default suite/Default test.xml new file mode 100644 index 0000000000..9eb74cff2d --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/Default suite/Default test.xml @@ -0,0 +1,53 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/openecomp-be/backend/openecomp-sdc-action-manager/test-output/Default suite/testng-failed.xml b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/Default suite/testng-failed.xml new file mode 100644 index 0000000000..5f2650e66e --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/Default suite/testng-failed.xml @@ -0,0 +1,16 @@ + + + + + + + + + + + + + + + + diff --git a/openecomp-be/backend/openecomp-sdc-action-manager/test-output/bullet_point.png b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/bullet_point.png new file mode 100644 index 0000000000000000000000000000000000000000..176e6d5b3d64d032e76c493e5811a1cf839220b5 GIT binary patch literal 356 zcmeAS@N?(olHy`uVBq!ia0vp^93afW1|*O0@9PFqoCO|{#S9GG!XV7ZFl&wkP>?0v z(btiIVPjv-@4(4GzCyA`kS_y6l_~>6Lo)-z&;LOBB?CjL0RzLU1O^7H84L{K`IF+0 zx&hVR@^o z&n}1RKn7{UjfWZCs($|cfA#bKkH7!F`St(Z@BiQa{{Qv=|DXRL zz<>l4f3h$#FmN;IfW$y%FtB(Pob+71*X+evXI>YLE;&}Fj8#mRE%&W?B30shyu13% zpT6C#3k-fJGjKF52@24V6I?%GvcZa|)%y<^9(-F=IB9W`k6g3(YLhfsMh0sDZC^x! literal 0 HcmV?d00001 diff --git a/openecomp-be/backend/openecomp-sdc-action-manager/test-output/emailable-report.html b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/emailable-report.html new file mode 100644 index 0000000000..299de973b7 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/emailable-report.html @@ -0,0 +1,2 @@ + +TestNG Report
Test# Passed# Skipped# FailedTime (ms)Included GroupsExcluded Groups
Default suite
Default test49006,008
ClassMethodStartTime (ms)
Default suite
Default test — passed
ActionTestcreateTest147331917940879
testCheckIn147331918270110
testCheckInWithOtherUser14733191827665
testCheckInWithoutCheckout14733191827404
testCheckOut147331918274521
testCheckOutOnCheckOut147331918058013
testCheckOutOnCheckOutWithOtherUser14733191805949
testCreateWithExistingActionName_negative14733191806035
testDeleteArtifact147331918127239
testDeleteArtifactInvalidActInvId14733191794883
testDeleteArtifactInvalidArtifactUUID14733191806669
testDeleteArtifactLockedByOtherUser14733191813125
testDeleteArtifactOnUnlockedAction14733191819825
testDeleteReadOnlyArtifact147331918131759
testDownloadArtifact14733191813778
testDownloadArtifactNegativeInvalidAction14733191794924
testDownloadArtifactNegativeInvalidArtifact14733191813865
testGetAllActions147331918060956
testGetByCategory1473319179497961
testGetByIgnoreCaseName147331918067611
testGetByInvIdManyVersionWithFirstSubmit1473319181466515
testGetByInvIdManyVersionWithMultSubmit1473319182005366
testGetByInvIdManyVersionWithoutSubmit1473319180688451
testGetByInvIdOnCreate147331918045930
testGetByInvIdOnName1473319182430271
testGetBySupportedComponent147331918114044
testGetBySupportedModel147331918118544
testGetByVendor147331918123041
testGetECOMPComponents14733191804905
testSubmit147331918271920
testSubmitOnCheckout14733191827724
testUndoCheckout147331918277718
testUpdateArtifact147331918139222
testUpdateInvalidVersion_negative14733191823717
testUpdateInvariantId_negative14733191823786
testUpdateName_negative14733191823858
testUpdateOnCheckedInAction_negative14733191827127
testUpdateOtherUser_negative14733191823947
testUpdateStatus_negative147331918240210
testUpdateUniqueId_negative14733191824139
testUpdateVersion_negative14733191824227
testUploadArtifact147331918049678
testUploadArtifactCheckedOutOtherUser_negative14733191814156
testUploadArtifactInvalidActionInvId_negative14733191814226
testUploadArtifactSameName_negative14733191814289
testUploadArtifactUnlockedAction_negative147331918143821
testgetActionsByActionUUID14733191814605
testgetActionsByActionUUID_Negative14733191805744
updateTest147331918198717

Default test

ActionTest#createTest

back to summary

ActionTest#testCheckIn

back to summary

ActionTest#testCheckInWithOtherUser

back to summary

ActionTest#testCheckInWithoutCheckout

back to summary

ActionTest#testCheckOut

back to summary

ActionTest#testCheckOutOnCheckOut

back to summary

ActionTest#testCheckOutOnCheckOutWithOtherUser

back to summary

ActionTest#testCreateWithExistingActionName_negative

back to summary

ActionTest#testDeleteArtifact

back to summary

ActionTest#testDeleteArtifactInvalidActInvId

back to summary

ActionTest#testDeleteArtifactInvalidArtifactUUID

back to summary

ActionTest#testDeleteArtifactLockedByOtherUser

back to summary

ActionTest#testDeleteArtifactOnUnlockedAction

back to summary

ActionTest#testDeleteReadOnlyArtifact

back to summary

ActionTest#testDownloadArtifact

back to summary

ActionTest#testDownloadArtifactNegativeInvalidAction

back to summary

ActionTest#testDownloadArtifactNegativeInvalidArtifact

back to summary

ActionTest#testGetAllActions

back to summary

ActionTest#testGetByCategory

back to summary

ActionTest#testGetByIgnoreCaseName

back to summary

ActionTest#testGetByInvIdManyVersionWithFirstSubmit

back to summary

ActionTest#testGetByInvIdManyVersionWithMultSubmit

back to summary

ActionTest#testGetByInvIdManyVersionWithoutSubmit

back to summary

ActionTest#testGetByInvIdOnCreate

back to summary

ActionTest#testGetByInvIdOnName

back to summary

ActionTest#testGetBySupportedComponent

back to summary

ActionTest#testGetBySupportedModel

back to summary

ActionTest#testGetByVendor

back to summary

ActionTest#testGetECOMPComponents

back to summary

ActionTest#testSubmit

back to summary

ActionTest#testSubmitOnCheckout

back to summary

ActionTest#testUndoCheckout

back to summary

ActionTest#testUpdateArtifact

back to summary

ActionTest#testUpdateInvalidVersion_negative

back to summary

ActionTest#testUpdateInvariantId_negative

back to summary

ActionTest#testUpdateName_negative

back to summary

ActionTest#testUpdateOnCheckedInAction_negative

back to summary

ActionTest#testUpdateOtherUser_negative

back to summary

ActionTest#testUpdateStatus_negative

back to summary

ActionTest#testUpdateUniqueId_negative

back to summary

ActionTest#testUpdateVersion_negative

back to summary

ActionTest#testUploadArtifact

back to summary

ActionTest#testUploadArtifactCheckedOutOtherUser_negative

back to summary

ActionTest#testUploadArtifactInvalidActionInvId_negative

back to summary

ActionTest#testUploadArtifactSameName_negative

back to summary

ActionTest#testUploadArtifactUnlockedAction_negative

back to summary

ActionTest#testgetActionsByActionUUID

back to summary

ActionTest#testgetActionsByActionUUID_Negative

back to summary

ActionTest#updateTest

back to summary

\ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-action-manager/test-output/failed.png b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/failed.png new file mode 100644 index 0000000000000000000000000000000000000000..c117be59a9ecd1da15ebf48f6b7f53496302a7cd GIT binary patch literal 977 zcmV;?11|iDP)4Tx0C)j~RNrgUP!#^!Wu36$i#lf!2|j3%Ze&w*L!7p2SGvtw>Nd9_NSmf@ zT$;ut?S8Na*^6&F#dq-sKKTa>*@JI;k`2ZbVfd_wB24xov!0tYO(#d#()tZ$I5%3%!zLYh@BH>w}XODA7?mkV}ap}jU$$3 zG&Mk)3Bm`(LOM&hKscCb;PVaG&Vdx+MpZJHTQ(R_;DA31$+jOGBoLXk_De?ey1m!ik&_4G zH9n^))_*|$z4!HUisgBd@awc5jn(v9k~&t~+vLrrBg4dZQ9lDnLV}JQWGLW~LJVP= zW5lZXOcog;N~F?hbX0k=IMzETla}oqM|jC!4!B+x^;@#I_Tc-T-6hwKycLDTx1-om z?X`jFy0R0R8-I0SrK4`)H@W4T8*Qr#2vPou<*`U!Wy(*2QP*`g=8#jD{B;Y@GL-Hm zb`n?&x~%YC_$q7)PlXr4m%r4=&fcvN%Ybn#KC7Nn&Bp8{(oE9pWVpYI^+LuN`H(R~ zTAjWmO`M83^4d@fCkA(d>*nHIFV_d2yUbnT`nd?LE^;G|!WZ>Ld?E0@Grm4ww{M7H zr`x{MWb30bTI;*hk-DO>dX$gbC-yy#suLNqvA(f>RtPJ!qGM`Gvvf}Y10`)vm-7Xa z?-7Ixe2A_siI1ydSCCID3U8SVUY86>uSnT0use_K1GZDvUFKY)t}F* z)!pahe+zh{{06Bb3f97*Uorpy0B%V{K~yLeW4y>F|DS;bz(j&tuu`}Ny`K+o>P41= zYq-R&z$-w|z14sZ}6S`uM8b)lMhS`K{GDtB9px6Kr!cSsofH?!*c`##8 zG{6+YB(Z6NYd}|wOA}U4!xUqq;Wl8C#3lv+hIuOk>aOmJ00000NkvXXu0mjfn+D0# literal 0 HcmV?d00001 diff --git a/openecomp-be/backend/openecomp-sdc-action-manager/test-output/index.html b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/index.html new file mode 100644 index 0000000000..a9227f662e --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/index.html @@ -0,0 +1,1231 @@ + + + + + TestNG reports + + + + + + + + + + +
+ Test results +
+ 1 suite +
+ +
+
+
+
+
+ + ActionTest +
+
+
+
+ + + createTest +
+
+
+
+ + + testCheckIn +
+
+
+
+ + + testCheckInWithOtherUser +
+
+
+
+ + + testCheckInWithoutCheckout +
+
+
+
+ + + testCheckOut +
+
+
+
+ + + testCheckOutOnCheckOut +
+
+
+
+ + + testCheckOutOnCheckOutWithOtherUser +
+
+
+
+ + + testCreateWithExistingActionName_negative +
+
+
+
+ + + testDeleteArtifact +
+
+
+
+ + + testDeleteArtifactInvalidActInvId +
+
+
+
+ + + testDeleteArtifactInvalidArtifactUUID +
+
+
+
+ + + testDeleteArtifactLockedByOtherUser +
+
+
+
+ + + testDeleteArtifactOnUnlockedAction +
+
+
+
+ + + testDeleteReadOnlyArtifact +
+
+
+
+ + + testDownloadArtifact +
+
+
+
+ + + testDownloadArtifactNegativeInvalidAction +
+
+
+
+ + + testDownloadArtifactNegativeInvalidArtifact +
+
+
+
+ + + testGetAllActions +
+
+
+
+ + + testGetByCategory +
+
+
+
+ + + testGetByIgnoreCaseName +
+
+
+
+ + + testGetByInvIdManyVersionWithFirstSubmit +
+
+
+
+ + + testGetByInvIdManyVersionWithMultSubmit +
+
+
+
+ + + testGetByInvIdManyVersionWithoutSubmit +
+
+
+
+ + + testGetByInvIdOnCreate +
+
+
+
+ + + testGetByInvIdOnName +
+
+
+
+ + + testGetBySupportedComponent +
+
+
+
+ + + testGetBySupportedModel +
+
+
+
+ + + testGetByVendor +
+
+
+
+ + + testGetECOMPComponents +
+
+
+
+ + + testSubmit +
+
+
+
+ + + testSubmitOnCheckout +
+
+
+
+ + + testUndoCheckout +
+
+
+
+ + + testUpdateArtifact +
+
+
+
+ + + testUpdateInvalidVersion_negative +
+
+
+
+ + + testUpdateInvariantId_negative +
+
+
+
+ + + testUpdateName_negative +
+
+
+
+ + + testUpdateOnCheckedInAction_negative +
+
+
+
+ + + testUpdateOtherUser_negative +
+
+
+
+ + + testUpdateStatus_negative +
+
+
+
+ + + testUpdateUniqueId_negative +
+
+
+
+ + + testUpdateVersion_negative +
+
+
+
+ + + testUploadArtifact +
+
+
+
+ + + testUploadArtifactCheckedOutOtherUser_negative +
+
+
+
+ + + testUploadArtifactInvalidActionInvId_negative +
+
+
+
+ + + testUploadArtifactSameName_negative +
+
+
+
+ + + testUploadArtifactUnlockedAction_negative +
+
+
+
+ + + testgetActionsByActionUUID +
+
+
+
+ + + testgetActionsByActionUUID_Negative +
+
+
+
+ + + updateTest +
+
+
+
+
+
+
+ C:\Users\sheetalm\AppData\Local\Temp\testng-eclipse--1963739526\testng-customsuite.xml +
+
+
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE suite SYSTEM "http://testng.org/testng-1.0.dtd">
+<suite name="Default suite">
+  <test verbose="2" name="Default test">
+    <classes>
+      <class name="ActionTest"/>
+    </classes>
+  </test> <!-- Default test -->
+</suite> <!-- Default suite -->
+            
+
+
+
+
+ Tests for Default suite +
+
+
    +
  • + Default test (1 class) +
  • +
+
+
+
+
+ Groups for Default suite +
+
+
+ updateTestGroup +
+
+ testUpdateInvalidVersion_negative +
+
+
+ testUpdateInvariantId_negative +
+
+
+ testUpdateName_negative +
+
+
+ testUpdateOtherUser_negative +
+
+
+ testUpdateStatus_negative +
+
+
+ testUpdateUniqueId_negative +
+
+
+ testUpdateVersion_negative +
+
+
+ updateTest +
+
+
+
+
+
+
+ Times for Default suite +
+
+
+ + Total running time: 3 seconds +
+
+
+
+
+
+
+ Reporter output for Default suite +
+
+
+
+
+
+ 0 ignored methods +
+
+
+
+
+
+ Methods in chronological order +
+
+
+
ActionTest
+
+ init + 0 ms +
+
+ createTest + 2619 ms +
+
+ testDeleteArtifactInvalidActInvId + 2699 ms +
+
+ testDownloadArtifactNegativeInvalidAction + 2703 ms +
+
+ testGetByCategory + 2708 ms +
+
+ testGetByInvIdOnCreate + 3670 ms +
+
+ testGetECOMPComponents + 3701 ms +
+
+ testUploadArtifact + 3707 ms +
+
+ testgetActionsByActionUUID_Negative + 3785 ms +
+
+ testCheckOutOnCheckOut + 3791 ms +
+
+ testCheckOutOnCheckOutWithOtherUser + 3805 ms +
+
+ testCreateWithExistingActionName_negative + 3814 ms +
+
+ testGetAllActions + 3820 ms +
+
+ testDeleteArtifactInvalidArtifactUUID + 3877 ms +
+
+ testGetByIgnoreCaseName + 3887 ms +
+
+ testGetByInvIdManyVersionWithoutSubmit + 3899 ms +
+
+ testGetBySupportedComponent + 4351 ms +
+
+ testGetBySupportedModel + 4396 ms +
+
+ testGetByVendor + 4441 ms +
+
+ testDeleteArtifact + 4483 ms +
+
+ testDeleteArtifactLockedByOtherUser + 4523 ms +
+
+ testDeleteReadOnlyArtifact + 4528 ms +
+
+ testDownloadArtifact + 4588 ms +
+
+ testDownloadArtifactNegativeInvalidArtifact + 4597 ms +
+
+ testUpdateArtifact + 4603 ms +
+
+ testUploadArtifactCheckedOutOtherUser_negative + 4626 ms +
+
+ testUploadArtifactInvalidActionInvId_negative + 4633 ms +
+
+ testUploadArtifactSameName_negative + 4639 ms +
+
+ testUploadArtifactUnlockedAction_negative + 4649 ms +
+
+ testgetActionsByActionUUID + 4671 ms +
+
+ testGetByInvIdManyVersionWithFirstSubmit + 4677 ms +
+
+ testDeleteArtifactOnUnlockedAction + 5193 ms +
+
+ updateTest + 5198 ms +
+
+ testGetByInvIdManyVersionWithMultSubmit + 5216 ms +
+
+ testUpdateInvalidVersion_negative + 5582 ms +
+
+ testUpdateInvariantId_negative + 5589 ms +
+
+ testUpdateName_negative + 5596 ms +
+
+ testUpdateOtherUser_negative + 5605 ms +
+
+ testUpdateStatus_negative + 5613 ms +
+
+ testUpdateUniqueId_negative + 5624 ms +
+
+ testUpdateVersion_negative + 5633 ms +
+
+ testGetByInvIdOnName + 5641 ms +
+
+ testCheckIn + 5912 ms +
+
+ testUpdateOnCheckedInAction_negative + 5923 ms +
+
+ testSubmit + 5930 ms +
+
+ testCheckInWithoutCheckout + 5951 ms +
+
+ testCheckOut + 5956 ms +
+
+ testCheckInWithOtherUser + 5977 ms +
+
+ testSubmitOnCheckout + 5983 ms +
+
+ testUndoCheckout + 5988 ms +
+
+
+
+
+ + diff --git a/openecomp-be/backend/openecomp-sdc-action-manager/test-output/jquery-1.7.1.min.js b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/jquery-1.7.1.min.js new file mode 100644 index 0000000000..198b3ff07d --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/jquery-1.7.1.min.js @@ -0,0 +1,4 @@ +/*! jQuery v1.7.1 jquery.com | jquery.org/license */ +(function(a,b){function cy(a){return f.isWindow(a)?a:a.nodeType===9?a.defaultView||a.parentWindow:!1}function cv(a){if(!ck[a]){var b=c.body,d=f("<"+a+">").appendTo(b),e=d.css("display");d.remove();if(e==="none"||e===""){cl||(cl=c.createElement("iframe"),cl.frameBorder=cl.width=cl.height=0),b.appendChild(cl);if(!cm||!cl.createElement)cm=(cl.contentWindow||cl.contentDocument).document,cm.write((c.compatMode==="CSS1Compat"?"":"")+""),cm.close();d=cm.createElement(a),cm.body.appendChild(d),e=f.css(d,"display"),b.removeChild(cl)}ck[a]=e}return ck[a]}function cu(a,b){var c={};f.each(cq.concat.apply([],cq.slice(0,b)),function(){c[this]=a});return c}function ct(){cr=b}function cs(){setTimeout(ct,0);return cr=f.now()}function cj(){try{return new a.ActiveXObject("Microsoft.XMLHTTP")}catch(b){}}function ci(){try{return new a.XMLHttpRequest}catch(b){}}function cc(a,c){a.dataFilter&&(c=a.dataFilter(c,a.dataType));var d=a.dataTypes,e={},g,h,i=d.length,j,k=d[0],l,m,n,o,p;for(g=1;g0){if(c!=="border")for(;g=0===c})}function S(a){return!a||!a.parentNode||a.parentNode.nodeType===11}function K(){return!0}function J(){return!1}function n(a,b,c){var d=b+"defer",e=b+"queue",g=b+"mark",h=f._data(a,d);h&&(c==="queue"||!f._data(a,e))&&(c==="mark"||!f._data(a,g))&&setTimeout(function(){!f._data(a,e)&&!f._data(a,g)&&(f.removeData(a,d,!0),h.fire())},0)}function m(a){for(var b in a){if(b==="data"&&f.isEmptyObject(a[b]))continue;if(b!=="toJSON")return!1}return!0}function l(a,c,d){if(d===b&&a.nodeType===1){var e="data-"+c.replace(k,"-$1").toLowerCase();d=a.getAttribute(e);if(typeof d=="string"){try{d=d==="true"?!0:d==="false"?!1:d==="null"?null:f.isNumeric(d)?parseFloat(d):j.test(d)?f.parseJSON(d):d}catch(g){}f.data(a,c,d)}else d=b}return d}function h(a){var b=g[a]={},c,d;a=a.split(/\s+/);for(c=0,d=a.length;c)[^>]*$|#([\w\-]*)$)/,j=/\S/,k=/^\s+/,l=/\s+$/,m=/^<(\w+)\s*\/?>(?:<\/\1>)?$/,n=/^[\],:{}\s]*$/,o=/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g,p=/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,q=/(?:^|:|,)(?:\s*\[)+/g,r=/(webkit)[ \/]([\w.]+)/,s=/(opera)(?:.*version)?[ \/]([\w.]+)/,t=/(msie) ([\w.]+)/,u=/(mozilla)(?:.*? rv:([\w.]+))?/,v=/-([a-z]|[0-9])/ig,w=/^-ms-/,x=function(a,b){return(b+"").toUpperCase()},y=d.userAgent,z,A,B,C=Object.prototype.toString,D=Object.prototype.hasOwnProperty,E=Array.prototype.push,F=Array.prototype.slice,G=String.prototype.trim,H=Array.prototype.indexOf,I={};e.fn=e.prototype={constructor:e,init:function(a,d,f){var g,h,j,k;if(!a)return this;if(a.nodeType){this.context=this[0]=a,this.length=1;return this}if(a==="body"&&!d&&c.body){this.context=c,this[0]=c.body,this.selector=a,this.length=1;return this}if(typeof a=="string"){a.charAt(0)!=="<"||a.charAt(a.length-1)!==">"||a.length<3?g=i.exec(a):g=[null,a,null];if(g&&(g[1]||!d)){if(g[1]){d=d instanceof e?d[0]:d,k=d?d.ownerDocument||d:c,j=m.exec(a),j?e.isPlainObject(d)?(a=[c.createElement(j[1])],e.fn.attr.call(a,d,!0)):a=[k.createElement(j[1])]:(j=e.buildFragment([g[1]],[k]),a=(j.cacheable?e.clone(j.fragment):j.fragment).childNodes);return e.merge(this,a)}h=c.getElementById(g[2]);if(h&&h.parentNode){if(h.id!==g[2])return f.find(a);this.length=1,this[0]=h}this.context=c,this.selector=a;return this}return!d||d.jquery?(d||f).find(a):this.constructor(d).find(a)}if(e.isFunction(a))return f.ready(a);a.selector!==b&&(this.selector=a.selector,this.context=a.context);return e.makeArray(a,this)},selector:"",jquery:"1.7.1",length:0,size:function(){return this.length},toArray:function(){return F.call(this,0)},get:function(a){return a==null?this.toArray():a<0?this[this.length+a]:this[a]},pushStack:function(a,b,c){var d=this.constructor();e.isArray(a)?E.apply(d,a):e.merge(d,a),d.prevObject=this,d.context=this.context,b==="find"?d.selector=this.selector+(this.selector?" ":"")+c:b&&(d.selector=this.selector+"."+b+"("+c+")");return d},each:function(a,b){return e.each(this,a,b)},ready:function(a){e.bindReady(),A.add(a);return this},eq:function(a){a=+a;return a===-1?this.slice(a):this.slice(a,a+1)},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},slice:function(){return this.pushStack(F.apply(this,arguments),"slice",F.call(arguments).join(","))},map:function(a){return this.pushStack(e.map(this,function(b,c){return a.call(b,c,b)}))},end:function(){return this.prevObject||this.constructor(null)},push:E,sort:[].sort,splice:[].splice},e.fn.init.prototype=e.fn,e.extend=e.fn.extend=function(){var a,c,d,f,g,h,i=arguments[0]||{},j=1,k=arguments.length,l=!1;typeof i=="boolean"&&(l=i,i=arguments[1]||{},j=2),typeof i!="object"&&!e.isFunction(i)&&(i={}),k===j&&(i=this,--j);for(;j0)return;A.fireWith(c,[e]),e.fn.trigger&&e(c).trigger("ready").off("ready")}},bindReady:function(){if(!A){A=e.Callbacks("once memory");if(c.readyState==="complete")return setTimeout(e.ready,1);if(c.addEventListener)c.addEventListener("DOMContentLoaded",B,!1),a.addEventListener("load",e.ready,!1);else if(c.attachEvent){c.attachEvent("onreadystatechange",B),a.attachEvent("onload",e.ready);var b=!1;try{b=a.frameElement==null}catch(d){}c.documentElement.doScroll&&b&&J()}}},isFunction:function(a){return e.type(a)==="function"},isArray:Array.isArray||function(a){return e.type(a)==="array"},isWindow:function(a){return a&&typeof a=="object"&&"setInterval"in a},isNumeric:function(a){return!isNaN(parseFloat(a))&&isFinite(a)},type:function(a){return a==null?String(a):I[C.call(a)]||"object"},isPlainObject:function(a){if(!a||e.type(a)!=="object"||a.nodeType||e.isWindow(a))return!1;try{if(a.constructor&&!D.call(a,"constructor")&&!D.call(a.constructor.prototype,"isPrototypeOf"))return!1}catch(c){return!1}var d;for(d in a);return d===b||D.call(a,d)},isEmptyObject:function(a){for(var b in a)return!1;return!0},error:function(a){throw new Error(a)},parseJSON:function(b){if(typeof b!="string"||!b)return null;b=e.trim(b);if(a.JSON&&a.JSON.parse)return a.JSON.parse(b);if(n.test(b.replace(o,"@").replace(p,"]").replace(q,"")))return(new Function("return "+b))();e.error("Invalid JSON: "+b)},parseXML:function(c){var d,f;try{a.DOMParser?(f=new DOMParser,d=f.parseFromString(c,"text/xml")):(d=new ActiveXObject("Microsoft.XMLDOM"),d.async="false",d.loadXML(c))}catch(g){d=b}(!d||!d.documentElement||d.getElementsByTagName("parsererror").length)&&e.error("Invalid XML: "+c);return d},noop:function(){},globalEval:function(b){b&&j.test(b)&&(a.execScript||function(b){a.eval.call(a,b)})(b)},camelCase:function(a){return a.replace(w,"ms-").replace(v,x)},nodeName:function(a,b){return a.nodeName&&a.nodeName.toUpperCase()===b.toUpperCase()},each:function(a,c,d){var f,g=0,h=a.length,i=h===b||e.isFunction(a);if(d){if(i){for(f in a)if(c.apply(a[f],d)===!1)break}else for(;g0&&a[0]&&a[j-1]||j===0||e.isArray(a));if(k)for(;i1?i.call(arguments,0):b,j.notifyWith(k,e)}}function l(a){return function(c){b[a]=arguments.length>1?i.call(arguments,0):c,--g||j.resolveWith(j,b)}}var b=i.call(arguments,0),c=0,d=b.length,e=Array(d),g=d,h=d,j=d<=1&&a&&f.isFunction(a.promise)?a:f.Deferred(),k=j.promise();if(d>1){for(;c
a",d=q.getElementsByTagName("*"),e=q.getElementsByTagName("a")[0];if(!d||!d.length||!e)return{};g=c.createElement("select"),h=g.appendChild(c.createElement("option")),i=q.getElementsByTagName("input")[0],b={leadingWhitespace:q.firstChild.nodeType===3,tbody:!q.getElementsByTagName("tbody").length,htmlSerialize:!!q.getElementsByTagName("link").length,style:/top/.test(e.getAttribute("style")),hrefNormalized:e.getAttribute("href")==="/a",opacity:/^0.55/.test(e.style.opacity),cssFloat:!!e.style.cssFloat,checkOn:i.value==="on",optSelected:h.selected,getSetAttribute:q.className!=="t",enctype:!!c.createElement("form").enctype,html5Clone:c.createElement("nav").cloneNode(!0).outerHTML!=="<:nav>",submitBubbles:!0,changeBubbles:!0,focusinBubbles:!1,deleteExpando:!0,noCloneEvent:!0,inlineBlockNeedsLayout:!1,shrinkWrapBlocks:!1,reliableMarginRight:!0},i.checked=!0,b.noCloneChecked=i.cloneNode(!0).checked,g.disabled=!0,b.optDisabled=!h.disabled;try{delete q.test}catch(s){b.deleteExpando=!1}!q.addEventListener&&q.attachEvent&&q.fireEvent&&(q.attachEvent("onclick",function(){b.noCloneEvent=!1}),q.cloneNode(!0).fireEvent("onclick")),i=c.createElement("input"),i.value="t",i.setAttribute("type","radio"),b.radioValue=i.value==="t",i.setAttribute("checked","checked"),q.appendChild(i),k=c.createDocumentFragment(),k.appendChild(q.lastChild),b.checkClone=k.cloneNode(!0).cloneNode(!0).lastChild.checked,b.appendChecked=i.checked,k.removeChild(i),k.appendChild(q),q.innerHTML="",a.getComputedStyle&&(j=c.createElement("div"),j.style.width="0",j.style.marginRight="0",q.style.width="2px",q.appendChild(j),b.reliableMarginRight=(parseInt((a.getComputedStyle(j,null)||{marginRight:0}).marginRight,10)||0)===0);if(q.attachEvent)for(o in{submit:1,change:1,focusin:1})n="on"+o,p=n in q,p||(q.setAttribute(n,"return;"),p=typeof q[n]=="function"),b[o+"Bubbles"]=p;k.removeChild(q),k=g=h=j=q=i=null,f(function(){var a,d,e,g,h,i,j,k,m,n,o,r=c.getElementsByTagName("body")[0];!r||(j=1,k="position:absolute;top:0;left:0;width:1px;height:1px;margin:0;",m="visibility:hidden;border:0;",n="style='"+k+"border:5px solid #000;padding:0;'",o="
"+""+"
",a=c.createElement("div"),a.style.cssText=m+"width:0;height:0;position:static;top:0;margin-top:"+j+"px",r.insertBefore(a,r.firstChild),q=c.createElement("div"),a.appendChild(q),q.innerHTML="
t
",l=q.getElementsByTagName("td"),p=l[0].offsetHeight===0,l[0].style.display="",l[1].style.display="none",b.reliableHiddenOffsets=p&&l[0].offsetHeight===0,q.innerHTML="",q.style.width=q.style.paddingLeft="1px",f.boxModel=b.boxModel=q.offsetWidth===2,typeof q.style.zoom!="undefined"&&(q.style.display="inline",q.style.zoom=1,b.inlineBlockNeedsLayout=q.offsetWidth===2,q.style.display="",q.innerHTML="
",b.shrinkWrapBlocks=q.offsetWidth!==2),q.style.cssText=k+m,q.innerHTML=o,d=q.firstChild,e=d.firstChild,h=d.nextSibling.firstChild.firstChild,i={doesNotAddBorder:e.offsetTop!==5,doesAddBorderForTableAndCells:h.offsetTop===5},e.style.position="fixed",e.style.top="20px",i.fixedPosition=e.offsetTop===20||e.offsetTop===15,e.style.position=e.style.top="",d.style.overflow="hidden",d.style.position="relative",i.subtractsBorderForOverflowNotVisible=e.offsetTop===-5,i.doesNotIncludeMarginInBodyOffset=r.offsetTop!==j,r.removeChild(a),q=a=null,f.extend(b,i))});return b}();var j=/^(?:\{.*\}|\[.*\])$/,k=/([A-Z])/g;f.extend({cache:{},uuid:0,expando:"jQuery"+(f.fn.jquery+Math.random()).replace(/\D/g,""),noData:{embed:!0,object:"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000",applet:!0},hasData:function(a){a=a.nodeType?f.cache[a[f.expando]]:a[f.expando];return!!a&&!m(a)},data:function(a,c,d,e){if(!!f.acceptData(a)){var g,h,i,j=f.expando,k=typeof c=="string",l=a.nodeType,m=l?f.cache:a,n=l?a[j]:a[j]&&j,o=c==="events";if((!n||!m[n]||!o&&!e&&!m[n].data)&&k&&d===b)return;n||(l?a[j]=n=++f.uuid:n=j),m[n]||(m[n]={},l||(m[n].toJSON=f.noop));if(typeof c=="object"||typeof c=="function")e?m[n]=f.extend(m[n],c):m[n].data=f.extend(m[n].data,c);g=h=m[n],e||(h.data||(h.data={}),h=h.data),d!==b&&(h[f.camelCase(c)]=d);if(o&&!h[c])return g.events;k?(i=h[c],i==null&&(i=h[f.camelCase(c)])):i=h;return i}},removeData:function(a,b,c){if(!!f.acceptData(a)){var d,e,g,h=f.expando,i=a.nodeType,j=i?f.cache:a,k=i?a[h]:h;if(!j[k])return;if(b){d=c?j[k]:j[k].data;if(d){f.isArray(b)||(b in d?b=[b]:(b=f.camelCase(b),b in d?b=[b]:b=b.split(" ")));for(e=0,g=b.length;e-1)return!0;return!1},val:function(a){var c,d,e,g=this[0];{if(!!arguments.length){e=f.isFunction(a);return this.each(function(d){var g=f(this),h;if(this.nodeType===1){e?h=a.call(this,d,g.val()):h=a,h==null?h="":typeof h=="number"?h+="":f.isArray(h)&&(h=f.map(h,function(a){return a==null?"":a+""})),c=f.valHooks[this.nodeName.toLowerCase()]||f.valHooks[this.type];if(!c||!("set"in c)||c.set(this,h,"value")===b)this.value=h}})}if(g){c=f.valHooks[g.nodeName.toLowerCase()]||f.valHooks[g.type];if(c&&"get"in c&&(d=c.get(g,"value"))!==b)return d;d=g.value;return typeof d=="string"?d.replace(q,""):d==null?"":d}}}}),f.extend({valHooks:{option:{get:function(a){var b=a.attributes.value;return!b||b.specified?a.value:a.text}},select:{get:function(a){var b,c,d,e,g=a.selectedIndex,h=[],i=a.options,j=a.type==="select-one";if(g<0)return null;c=j?g:0,d=j?g+1:i.length;for(;c=0}),c.length||(a.selectedIndex=-1);return c}}},attrFn:{val:!0,css:!0,html:!0,text:!0,data:!0,width:!0,height:!0,offset:!0},attr:function(a,c,d,e){var g,h,i,j=a.nodeType;if(!!a&&j!==3&&j!==8&&j!==2){if(e&&c in f.attrFn)return f(a)[c](d);if(typeof a.getAttribute=="undefined")return f.prop(a,c,d);i=j!==1||!f.isXMLDoc(a),i&&(c=c.toLowerCase(),h=f.attrHooks[c]||(u.test(c)?x:w));if(d!==b){if(d===null){f.removeAttr(a,c);return}if(h&&"set"in h&&i&&(g=h.set(a,d,c))!==b)return g;a.setAttribute(c,""+d);return d}if(h&&"get"in h&&i&&(g=h.get(a,c))!==null)return g;g=a.getAttribute(c);return g===null?b:g}},removeAttr:function(a,b){var c,d,e,g,h=0;if(b&&a.nodeType===1){d=b.toLowerCase().split(p),g=d.length;for(;h=0}})});var z=/^(?:textarea|input|select)$/i,A=/^([^\.]*)?(?:\.(.+))?$/,B=/\bhover(\.\S+)?\b/,C=/^key/,D=/^(?:mouse|contextmenu)|click/,E=/^(?:focusinfocus|focusoutblur)$/,F=/^(\w*)(?:#([\w\-]+))?(?:\.([\w\-]+))?$/,G=function(a){var b=F.exec(a);b&&(b[1]=(b[1]||"").toLowerCase(),b[3]=b[3]&&new RegExp("(?:^|\\s)"+b[3]+"(?:\\s|$)"));return b},H=function(a,b){var c=a.attributes||{};return(!b[1]||a.nodeName.toLowerCase()===b[1])&&(!b[2]||(c.id||{}).value===b[2])&&(!b[3]||b[3].test((c["class"]||{}).value))},I=function(a){return f.event.special.hover?a:a.replace(B,"mouseenter$1 mouseleave$1")}; +f.event={add:function(a,c,d,e,g){var h,i,j,k,l,m,n,o,p,q,r,s;if(!(a.nodeType===3||a.nodeType===8||!c||!d||!(h=f._data(a)))){d.handler&&(p=d,d=p.handler),d.guid||(d.guid=f.guid++),j=h.events,j||(h.events=j={}),i=h.handle,i||(h.handle=i=function(a){return typeof f!="undefined"&&(!a||f.event.triggered!==a.type)?f.event.dispatch.apply(i.elem,arguments):b},i.elem=a),c=f.trim(I(c)).split(" ");for(k=0;k=0&&(h=h.slice(0,-1),k=!0),h.indexOf(".")>=0&&(i=h.split("."),h=i.shift(),i.sort());if((!e||f.event.customEvent[h])&&!f.event.global[h])return;c=typeof c=="object"?c[f.expando]?c:new f.Event(h,c):new f.Event(h),c.type=h,c.isTrigger=!0,c.exclusive=k,c.namespace=i.join("."),c.namespace_re=c.namespace?new RegExp("(^|\\.)"+i.join("\\.(?:.*\\.)?")+"(\\.|$)"):null,o=h.indexOf(":")<0?"on"+h:"";if(!e){j=f.cache;for(l in j)j[l].events&&j[l].events[h]&&f.event.trigger(c,d,j[l].handle.elem,!0);return}c.result=b,c.target||(c.target=e),d=d!=null?f.makeArray(d):[],d.unshift(c),p=f.event.special[h]||{};if(p.trigger&&p.trigger.apply(e,d)===!1)return;r=[[e,p.bindType||h]];if(!g&&!p.noBubble&&!f.isWindow(e)){s=p.delegateType||h,m=E.test(s+h)?e:e.parentNode,n=null;for(;m;m=m.parentNode)r.push([m,s]),n=m;n&&n===e.ownerDocument&&r.push([n.defaultView||n.parentWindow||a,s])}for(l=0;le&&i.push({elem:this,matches:d.slice(e)});for(j=0;j0?this.on(b,null,a,c):this.trigger(b)},f.attrFn&&(f.attrFn[b]=!0),C.test(b)&&(f.event.fixHooks[b]=f.event.keyHooks),D.test(b)&&(f.event.fixHooks[b]=f.event.mouseHooks)}),function(){function x(a,b,c,e,f,g){for(var h=0,i=e.length;h0){k=j;break}}j=j[a]}e[h]=k}}}function w(a,b,c,e,f,g){for(var h=0,i=e.length;h+~,(\[\\]+)+|[>+~])(\s*,\s*)?((?:.|\r|\n)*)/g,d="sizcache"+(Math.random()+"").replace(".",""),e=0,g=Object.prototype.toString,h=!1,i=!0,j=/\\/g,k=/\r\n/g,l=/\W/;[0,0].sort(function(){i=!1;return 0});var m=function(b,d,e,f){e=e||[],d=d||c;var h=d;if(d.nodeType!==1&&d.nodeType!==9)return[];if(!b||typeof b!="string")return e;var i,j,k,l,n,q,r,t,u=!0,v=m.isXML(d),w=[],x=b;do{a.exec(""),i=a.exec(x);if(i){x=i[3],w.push(i[1]);if(i[2]){l=i[3];break}}}while(i);if(w.length>1&&p.exec(b))if(w.length===2&&o.relative[w[0]])j=y(w[0]+w[1],d,f);else{j=o.relative[w[0]]?[d]:m(w.shift(),d);while(w.length)b=w.shift(),o.relative[b]&&(b+=w.shift()),j=y(b,j,f)}else{!f&&w.length>1&&d.nodeType===9&&!v&&o.match.ID.test(w[0])&&!o.match.ID.test(w[w.length-1])&&(n=m.find(w.shift(),d,v),d=n.expr?m.filter(n.expr,n.set)[0]:n.set[0]);if(d){n=f?{expr:w.pop(),set:s(f)}:m.find(w.pop(),w.length===1&&(w[0]==="~"||w[0]==="+")&&d.parentNode?d.parentNode:d,v),j=n.expr?m.filter(n.expr,n.set):n.set,w.length>0?k=s(j):u=!1;while(w.length)q=w.pop(),r=q,o.relative[q]?r=w.pop():q="",r==null&&(r=d),o.relative[q](k,r,v)}else k=w=[]}k||(k=j),k||m.error(q||b);if(g.call(k)==="[object Array]")if(!u)e.push.apply(e,k);else if(d&&d.nodeType===1)for(t=0;k[t]!=null;t++)k[t]&&(k[t]===!0||k[t].nodeType===1&&m.contains(d,k[t]))&&e.push(j[t]);else for(t=0;k[t]!=null;t++)k[t]&&k[t].nodeType===1&&e.push(j[t]);else s(k,e);l&&(m(l,h,e,f),m.uniqueSort(e));return e};m.uniqueSort=function(a){if(u){h=i,a.sort(u);if(h)for(var b=1;b0},m.find=function(a,b,c){var d,e,f,g,h,i;if(!a)return[];for(e=0,f=o.order.length;e":function(a,b){var c,d=typeof b=="string",e=0,f=a.length;if(d&&!l.test(b)){b=b.toLowerCase();for(;e=0)?c||d.push(h):c&&(b[g]=!1));return!1},ID:function(a){return a[1].replace(j,"")},TAG:function(a,b){return a[1].replace(j,"").toLowerCase()},CHILD:function(a){if(a[1]==="nth"){a[2]||m.error(a[0]),a[2]=a[2].replace(/^\+|\s*/g,"");var b=/(-?)(\d*)(?:n([+\-]?\d*))?/.exec(a[2]==="even"&&"2n"||a[2]==="odd"&&"2n+1"||!/\D/.test(a[2])&&"0n+"+a[2]||a[2]);a[2]=b[1]+(b[2]||1)-0,a[3]=b[3]-0}else a[2]&&m.error(a[0]);a[0]=e++;return a},ATTR:function(a,b,c,d,e,f){var g=a[1]=a[1].replace(j,"");!f&&o.attrMap[g]&&(a[1]=o.attrMap[g]),a[4]=(a[4]||a[5]||"").replace(j,""),a[2]==="~="&&(a[4]=" "+a[4]+" ");return a},PSEUDO:function(b,c,d,e,f){if(b[1]==="not")if((a.exec(b[3])||"").length>1||/^\w/.test(b[3]))b[3]=m(b[3],null,null,c);else{var g=m.filter(b[3],c,d,!0^f);d||e.push.apply(e,g);return!1}else if(o.match.POS.test(b[0])||o.match.CHILD.test(b[0]))return!0;return b},POS:function(a){a.unshift(!0);return a}},filters:{enabled:function(a){return a.disabled===!1&&a.type!=="hidden"},disabled:function(a){return a.disabled===!0},checked:function(a){return a.checked===!0},selected:function(a){a.parentNode&&a.parentNode.selectedIndex;return a.selected===!0},parent:function(a){return!!a.firstChild},empty:function(a){return!a.firstChild},has:function(a,b,c){return!!m(c[3],a).length},header:function(a){return/h\d/i.test(a.nodeName)},text:function(a){var b=a.getAttribute("type"),c=a.type;return a.nodeName.toLowerCase()==="input"&&"text"===c&&(b===c||b===null)},radio:function(a){return a.nodeName.toLowerCase()==="input"&&"radio"===a.type},checkbox:function(a){return a.nodeName.toLowerCase()==="input"&&"checkbox"===a.type},file:function(a){return a.nodeName.toLowerCase()==="input"&&"file"===a.type},password:function(a){return a.nodeName.toLowerCase()==="input"&&"password"===a.type},submit:function(a){var b=a.nodeName.toLowerCase();return(b==="input"||b==="button")&&"submit"===a.type},image:function(a){return a.nodeName.toLowerCase()==="input"&&"image"===a.type},reset:function(a){var b=a.nodeName.toLowerCase();return(b==="input"||b==="button")&&"reset"===a.type},button:function(a){var b=a.nodeName.toLowerCase();return b==="input"&&"button"===a.type||b==="button"},input:function(a){return/input|select|textarea|button/i.test(a.nodeName)},focus:function(a){return a===a.ownerDocument.activeElement}},setFilters:{first:function(a,b){return b===0},last:function(a,b,c,d){return b===d.length-1},even:function(a,b){return b%2===0},odd:function(a,b){return b%2===1},lt:function(a,b,c){return bc[3]-0},nth:function(a,b,c){return c[3]-0===b},eq:function(a,b,c){return c[3]-0===b}},filter:{PSEUDO:function(a,b,c,d){var e=b[1],f=o.filters[e];if(f)return f(a,c,b,d);if(e==="contains")return(a.textContent||a.innerText||n([a])||"").indexOf(b[3])>=0;if(e==="not"){var g=b[3];for(var h=0,i=g.length;h=0}},ID:function(a,b){return a.nodeType===1&&a.getAttribute("id")===b},TAG:function(a,b){return b==="*"&&a.nodeType===1||!!a.nodeName&&a.nodeName.toLowerCase()===b},CLASS:function(a,b){return(" "+(a.className||a.getAttribute("class"))+" ").indexOf(b)>-1},ATTR:function(a,b){var c=b[1],d=m.attr?m.attr(a,c):o.attrHandle[c]?o.attrHandle[c](a):a[c]!=null?a[c]:a.getAttribute(c),e=d+"",f=b[2],g=b[4];return d==null?f==="!=":!f&&m.attr?d!=null:f==="="?e===g:f==="*="?e.indexOf(g)>=0:f==="~="?(" "+e+" ").indexOf(g)>=0:g?f==="!="?e!==g:f==="^="?e.indexOf(g)===0:f==="$="?e.substr(e.length-g.length)===g:f==="|="?e===g||e.substr(0,g.length+1)===g+"-":!1:e&&d!==!1},POS:function(a,b,c,d){var e=b[2],f=o.setFilters[e];if(f)return f(a,c,b,d)}}},p=o.match.POS,q=function(a,b){return"\\"+(b-0+1)};for(var r in o.match)o.match[r]=new RegExp(o.match[r].source+/(?![^\[]*\])(?![^\(]*\))/.source),o.leftMatch[r]=new RegExp(/(^(?:.|\r|\n)*?)/.source+o.match[r].source.replace(/\\(\d+)/g,q));var s=function(a,b){a=Array.prototype.slice.call(a,0);if(b){b.push.apply(b,a);return b}return a};try{Array.prototype.slice.call(c.documentElement.childNodes,0)[0].nodeType}catch(t){s=function(a,b){var c=0,d=b||[];if(g.call(a)==="[object Array]")Array.prototype.push.apply(d,a);else if(typeof a.length=="number")for(var e=a.length;c",e.insertBefore(a,e.firstChild),c.getElementById(d)&&(o.find.ID=function(a,c,d){if(typeof c.getElementById!="undefined"&&!d){var e=c.getElementById(a[1]);return e?e.id===a[1]||typeof e.getAttributeNode!="undefined"&&e.getAttributeNode("id").nodeValue===a[1]?[e]:b:[]}},o.filter.ID=function(a,b){var c=typeof a.getAttributeNode!="undefined"&&a.getAttributeNode("id");return a.nodeType===1&&c&&c.nodeValue===b}),e.removeChild(a),e=a=null}(),function(){var a=c.createElement("div");a.appendChild(c.createComment("")),a.getElementsByTagName("*").length>0&&(o.find.TAG=function(a,b){var c=b.getElementsByTagName(a[1]);if(a[1]==="*"){var d=[];for(var e=0;c[e];e++)c[e].nodeType===1&&d.push(c[e]);c=d}return c}),a.innerHTML="",a.firstChild&&typeof a.firstChild.getAttribute!="undefined"&&a.firstChild.getAttribute("href")!=="#"&&(o.attrHandle.href=function(a){return a.getAttribute("href",2)}),a=null}(),c.querySelectorAll&&function(){var a=m,b=c.createElement("div"),d="__sizzle__";b.innerHTML="

";if(!b.querySelectorAll||b.querySelectorAll(".TEST").length!==0){m=function(b,e,f,g){e=e||c;if(!g&&!m.isXML(e)){var h=/^(\w+$)|^\.([\w\-]+$)|^#([\w\-]+$)/.exec(b);if(h&&(e.nodeType===1||e.nodeType===9)){if(h[1])return s(e.getElementsByTagName(b),f);if(h[2]&&o.find.CLASS&&e.getElementsByClassName)return s(e.getElementsByClassName(h[2]),f)}if(e.nodeType===9){if(b==="body"&&e.body)return s([e.body],f);if(h&&h[3]){var i=e.getElementById(h[3]);if(!i||!i.parentNode)return s([],f);if(i.id===h[3])return s([i],f)}try{return s(e.querySelectorAll(b),f)}catch(j){}}else if(e.nodeType===1&&e.nodeName.toLowerCase()!=="object"){var k=e,l=e.getAttribute("id"),n=l||d,p=e.parentNode,q=/^\s*[+~]/.test(b);l?n=n.replace(/'/g,"\\$&"):e.setAttribute("id",n),q&&p&&(e=e.parentNode);try{if(!q||p)return s(e.querySelectorAll("[id='"+n+"'] "+b),f)}catch(r){}finally{l||k.removeAttribute("id")}}}return a(b,e,f,g)};for(var e in a)m[e]=a[e];b=null}}(),function(){var a=c.documentElement,b=a.matchesSelector||a.mozMatchesSelector||a.webkitMatchesSelector||a.msMatchesSelector;if(b){var d=!b.call(c.createElement("div"),"div"),e=!1;try{b.call(c.documentElement,"[test!='']:sizzle")}catch(f){e=!0}m.matchesSelector=function(a,c){c=c.replace(/\=\s*([^'"\]]*)\s*\]/g,"='$1']");if(!m.isXML(a))try{if(e||!o.match.PSEUDO.test(c)&&!/!=/.test(c)){var f=b.call(a,c);if(f||!d||a.document&&a.document.nodeType!==11)return f}}catch(g){}return m(c,null,null,[a]).length>0}}}(),function(){var a=c.createElement("div");a.innerHTML="
";if(!!a.getElementsByClassName&&a.getElementsByClassName("e").length!==0){a.lastChild.className="e";if(a.getElementsByClassName("e").length===1)return;o.order.splice(1,0,"CLASS"),o.find.CLASS=function(a,b,c){if(typeof b.getElementsByClassName!="undefined"&&!c)return b.getElementsByClassName(a[1])},a=null}}(),c.documentElement.contains?m.contains=function(a,b){return a!==b&&(a.contains?a.contains(b):!0)}:c.documentElement.compareDocumentPosition?m.contains=function(a,b){return!!(a.compareDocumentPosition(b)&16)}:m.contains=function(){return!1},m.isXML=function(a){var b=(a?a.ownerDocument||a:0).documentElement;return b?b.nodeName!=="HTML":!1};var y=function(a,b,c){var d,e=[],f="",g=b.nodeType?[b]:b;while(d=o.match.PSEUDO.exec(a))f+=d[0],a=a.replace(o.match.PSEUDO,"");a=o.relative[a]?a+"*":a;for(var h=0,i=g.length;h0)for(h=g;h=0:f.filter(a,this).length>0:this.filter(a).length>0)},closest:function(a,b){var c=[],d,e,g=this[0];if(f.isArray(a)){var h=1;while(g&&g.ownerDocument&&g!==b){for(d=0;d-1:f.find.matchesSelector(g,a)){c.push(g);break}g=g.parentNode;if(!g||!g.ownerDocument||g===b||g.nodeType===11)break}}c=c.length>1?f.unique(c):c;return this.pushStack(c,"closest",a)},index:function(a){if(!a)return this[0]&&this[0].parentNode?this.prevAll().length:-1;if(typeof a=="string")return f.inArray(this[0],f(a));return f.inArray(a.jquery?a[0]:a,this)},add:function(a,b){var c=typeof a=="string"?f(a,b):f.makeArray(a&&a.nodeType?[a]:a),d=f.merge(this.get(),c);return this.pushStack(S(c[0])||S(d[0])?d:f.unique(d))},andSelf:function(){return this.add(this.prevObject)}}),f.each({parent:function(a){var b=a.parentNode;return b&&b.nodeType!==11?b:null},parents:function(a){return f.dir(a,"parentNode")},parentsUntil:function(a,b,c){return f.dir(a,"parentNode",c)},next:function(a){return f.nth(a,2,"nextSibling")},prev:function(a){return f.nth(a,2,"previousSibling")},nextAll:function(a){return f.dir(a,"nextSibling")},prevAll:function(a){return f.dir(a,"previousSibling")},nextUntil:function(a,b,c){return f.dir(a,"nextSibling",c)},prevUntil:function(a,b,c){return f.dir(a,"previousSibling",c)},siblings:function(a){return f.sibling(a.parentNode.firstChild,a)},children:function(a){return f.sibling(a.firstChild)},contents:function(a){return f.nodeName(a,"iframe")?a.contentDocument||a.contentWindow.document:f.makeArray(a.childNodes)}},function(a,b){f.fn[a]=function(c,d){var e=f.map(this,b,c);L.test(a)||(d=c),d&&typeof d=="string"&&(e=f.filter(d,e)),e=this.length>1&&!R[a]?f.unique(e):e,(this.length>1||N.test(d))&&M.test(a)&&(e=e.reverse());return this.pushStack(e,a,P.call(arguments).join(","))}}),f.extend({filter:function(a,b,c){c&&(a=":not("+a+")");return b.length===1?f.find.matchesSelector(b[0],a)?[b[0]]:[]:f.find.matches(a,b)},dir:function(a,c,d){var e=[],g=a[c];while(g&&g.nodeType!==9&&(d===b||g.nodeType!==1||!f(g).is(d)))g.nodeType===1&&e.push(g),g=g[c];return e},nth:function(a,b,c,d){b=b||1;var e=0;for(;a;a=a[c])if(a.nodeType===1&&++e===b)break;return a},sibling:function(a,b){var c=[];for(;a;a=a.nextSibling)a.nodeType===1&&a!==b&&c.push(a);return c}});var V="abbr|article|aside|audio|canvas|datalist|details|figcaption|figure|footer|header|hgroup|mark|meter|nav|output|progress|section|summary|time|video",W=/ jQuery\d+="(?:\d+|null)"/g,X=/^\s+/,Y=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/ig,Z=/<([\w:]+)/,$=/",""],legend:[1,"
","
"],thead:[1,"","
"],tr:[2,"","
"],td:[3,"","
"],col:[2,"","
"],area:[1,"",""],_default:[0,"",""]},bh=U(c);bg.optgroup=bg.option,bg.tbody=bg.tfoot=bg.colgroup=bg.caption=bg.thead,bg.th=bg.td,f.support.htmlSerialize||(bg._default=[1,"div
","
"]),f.fn.extend({text:function(a){if(f.isFunction(a))return this.each(function(b){var c=f(this);c.text(a.call(this,b,c.text()))});if(typeof a!="object"&&a!==b)return this.empty().append((this[0]&&this[0].ownerDocument||c).createTextNode(a));return f.text(this)},wrapAll:function(a){if(f.isFunction(a))return this.each(function(b){f(this).wrapAll(a.call(this,b))});if(this[0]){var b=f(a,this[0].ownerDocument).eq(0).clone(!0);this[0].parentNode&&b.insertBefore(this[0]),b.map(function(){var a=this;while(a.firstChild&&a.firstChild.nodeType===1)a=a.firstChild;return a}).append(this)}return this},wrapInner:function(a){if(f.isFunction(a))return this.each(function(b){f(this).wrapInner(a.call(this,b))});return this.each(function(){var b=f(this),c=b.contents();c.length?c.wrapAll(a):b.append(a)})},wrap:function(a){var b=f.isFunction(a);return this.each(function(c){f(this).wrapAll(b?a.call(this,c):a)})},unwrap:function(){return this.parent().each(function(){f.nodeName(this,"body")||f(this).replaceWith(this.childNodes)}).end()},append:function(){return this.domManip(arguments,!0,function(a){this.nodeType===1&&this.appendChild(a)})},prepend:function(){return this.domManip(arguments,!0,function(a){this.nodeType===1&&this.insertBefore(a,this.firstChild)})},before:function(){if(this[0]&&this[0].parentNode)return this.domManip(arguments,!1,function(a){this.parentNode.insertBefore(a,this)});if(arguments.length){var a=f.clean(arguments);a.push.apply(a,this.toArray());return this.pushStack(a,"before",arguments)}},after:function(){if(this[0]&&this[0].parentNode)return this.domManip(arguments,!1,function(a){this.parentNode.insertBefore(a,this.nextSibling)});if(arguments.length){var a=this.pushStack(this,"after",arguments);a.push.apply(a,f.clean(arguments));return a}},remove:function(a,b){for(var c=0,d;(d=this[c])!=null;c++)if(!a||f.filter(a,[d]).length)!b&&d.nodeType===1&&(f.cleanData(d.getElementsByTagName("*")),f.cleanData([d])),d.parentNode&&d.parentNode.removeChild(d);return this},empty:function() +{for(var a=0,b;(b=this[a])!=null;a++){b.nodeType===1&&f.cleanData(b.getElementsByTagName("*"));while(b.firstChild)b.removeChild(b.firstChild)}return this},clone:function(a,b){a=a==null?!1:a,b=b==null?a:b;return this.map(function(){return f.clone(this,a,b)})},html:function(a){if(a===b)return this[0]&&this[0].nodeType===1?this[0].innerHTML.replace(W,""):null;if(typeof a=="string"&&!ba.test(a)&&(f.support.leadingWhitespace||!X.test(a))&&!bg[(Z.exec(a)||["",""])[1].toLowerCase()]){a=a.replace(Y,"<$1>");try{for(var c=0,d=this.length;c1&&l0?this.clone(!0):this).get();f(e[h])[b](j),d=d.concat(j)}return this.pushStack(d,a,e.selector)}}),f.extend({clone:function(a,b,c){var d,e,g,h=f.support.html5Clone||!bc.test("<"+a.nodeName)?a.cloneNode(!0):bo(a);if((!f.support.noCloneEvent||!f.support.noCloneChecked)&&(a.nodeType===1||a.nodeType===11)&&!f.isXMLDoc(a)){bk(a,h),d=bl(a),e=bl(h);for(g=0;d[g];++g)e[g]&&bk(d[g],e[g])}if(b){bj(a,h);if(c){d=bl(a),e=bl(h);for(g=0;d[g];++g)bj(d[g],e[g])}}d=e=null;return h},clean:function(a,b,d,e){var g;b=b||c,typeof b.createElement=="undefined"&&(b=b.ownerDocument||b[0]&&b[0].ownerDocument||c);var h=[],i;for(var j=0,k;(k=a[j])!=null;j++){typeof k=="number"&&(k+="");if(!k)continue;if(typeof k=="string")if(!_.test(k))k=b.createTextNode(k);else{k=k.replace(Y,"<$1>");var l=(Z.exec(k)||["",""])[1].toLowerCase(),m=bg[l]||bg._default,n=m[0],o=b.createElement("div");b===c?bh.appendChild(o):U(b).appendChild(o),o.innerHTML=m[1]+k+m[2];while(n--)o=o.lastChild;if(!f.support.tbody){var p=$.test(k),q=l==="table"&&!p?o.firstChild&&o.firstChild.childNodes:m[1]===""&&!p?o.childNodes:[];for(i=q.length-1;i>=0;--i)f.nodeName(q[i],"tbody")&&!q[i].childNodes.length&&q[i].parentNode.removeChild(q[i])}!f.support.leadingWhitespace&&X.test(k)&&o.insertBefore(b.createTextNode(X.exec(k)[0]),o.firstChild),k=o.childNodes}var r;if(!f.support.appendChecked)if(k[0]&&typeof (r=k.length)=="number")for(i=0;i=0)return b+"px"}}}),f.support.opacity||(f.cssHooks.opacity={get:function(a,b){return br.test((b&&a.currentStyle?a.currentStyle.filter:a.style.filter)||"")?parseFloat(RegExp.$1)/100+"":b?"1":""},set:function(a,b){var c=a.style,d=a.currentStyle,e=f.isNumeric(b)?"alpha(opacity="+b*100+")":"",g=d&&d.filter||c.filter||"";c.zoom=1;if(b>=1&&f.trim(g.replace(bq,""))===""){c.removeAttribute("filter");if(d&&!d.filter)return}c.filter=bq.test(g)?g.replace(bq,e):g+" "+e}}),f(function(){f.support.reliableMarginRight||(f.cssHooks.marginRight={get:function(a,b){var c;f.swap(a,{display:"inline-block"},function(){b?c=bz(a,"margin-right","marginRight"):c=a.style.marginRight});return c}})}),c.defaultView&&c.defaultView.getComputedStyle&&(bA=function(a,b){var c,d,e;b=b.replace(bs,"-$1").toLowerCase(),(d=a.ownerDocument.defaultView)&&(e=d.getComputedStyle(a,null))&&(c=e.getPropertyValue(b),c===""&&!f.contains(a.ownerDocument.documentElement,a)&&(c=f.style(a,b)));return c}),c.documentElement.currentStyle&&(bB=function(a,b){var c,d,e,f=a.currentStyle&&a.currentStyle[b],g=a.style;f===null&&g&&(e=g[b])&&(f=e),!bt.test(f)&&bu.test(f)&&(c=g.left,d=a.runtimeStyle&&a.runtimeStyle.left,d&&(a.runtimeStyle.left=a.currentStyle.left),g.left=b==="fontSize"?"1em":f||0,f=g.pixelLeft+"px",g.left=c,d&&(a.runtimeStyle.left=d));return f===""?"auto":f}),bz=bA||bB,f.expr&&f.expr.filters&&(f.expr.filters.hidden=function(a){var b=a.offsetWidth,c=a.offsetHeight;return b===0&&c===0||!f.support.reliableHiddenOffsets&&(a.style&&a.style.display||f.css(a,"display"))==="none"},f.expr.filters.visible=function(a){return!f.expr.filters.hidden(a)});var bD=/%20/g,bE=/\[\]$/,bF=/\r?\n/g,bG=/#.*$/,bH=/^(.*?):[ \t]*([^\r\n]*)\r?$/mg,bI=/^(?:color|date|datetime|datetime-local|email|hidden|month|number|password|range|search|tel|text|time|url|week)$/i,bJ=/^(?:about|app|app\-storage|.+\-extension|file|res|widget):$/,bK=/^(?:GET|HEAD)$/,bL=/^\/\//,bM=/\?/,bN=/)<[^<]*)*<\/script>/gi,bO=/^(?:select|textarea)/i,bP=/\s+/,bQ=/([?&])_=[^&]*/,bR=/^([\w\+\.\-]+:)(?:\/\/([^\/?#:]*)(?::(\d+))?)?/,bS=f.fn.load,bT={},bU={},bV,bW,bX=["*/"]+["*"];try{bV=e.href}catch(bY){bV=c.createElement("a"),bV.href="",bV=bV.href}bW=bR.exec(bV.toLowerCase())||[],f.fn.extend({load:function(a,c,d){if(typeof a!="string"&&bS)return bS.apply(this,arguments);if(!this.length)return this;var e=a.indexOf(" ");if(e>=0){var g=a.slice(e,a.length);a=a.slice(0,e)}var h="GET";c&&(f.isFunction(c)?(d=c,c=b):typeof c=="object"&&(c=f.param(c,f.ajaxSettings.traditional),h="POST"));var i=this;f.ajax({url:a,type:h,dataType:"html",data:c,complete:function(a,b,c){c=a.responseText,a.isResolved()&&(a.done(function(a){c=a}),i.html(g?f("
").append(c.replace(bN,"")).find(g):c)),d&&i.each(d,[c,b,a])}});return this},serialize:function(){return f.param(this.serializeArray())},serializeArray:function(){return this.map(function(){return this.elements?f.makeArray(this.elements):this}).filter(function(){return this.name&&!this.disabled&&(this.checked||bO.test(this.nodeName)||bI.test(this.type))}).map(function(a,b){var c=f(this).val();return c==null?null:f.isArray(c)?f.map(c,function(a,c){return{name:b.name,value:a.replace(bF,"\r\n")}}):{name:b.name,value:c.replace(bF,"\r\n")}}).get()}}),f.each("ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".split(" "),function(a,b){f.fn[b]=function(a){return this.on(b,a)}}),f.each(["get","post"],function(a,c){f[c]=function(a,d,e,g){f.isFunction(d)&&(g=g||e,e=d,d=b);return f.ajax({type:c,url:a,data:d,success:e,dataType:g})}}),f.extend({getScript:function(a,c){return f.get(a,b,c,"script")},getJSON:function(a,b,c){return f.get(a,b,c,"json")},ajaxSetup:function(a,b){b?b_(a,f.ajaxSettings):(b=a,a=f.ajaxSettings),b_(a,b);return a},ajaxSettings:{url:bV,isLocal:bJ.test(bW[1]),global:!0,type:"GET",contentType:"application/x-www-form-urlencoded",processData:!0,async:!0,accepts:{xml:"application/xml, text/xml",html:"text/html",text:"text/plain",json:"application/json, text/javascript","*":bX},contents:{xml:/xml/,html:/html/,json:/json/},responseFields:{xml:"responseXML",text:"responseText"},converters:{"* text":a.String,"text html":!0,"text json":f.parseJSON,"text xml":f.parseXML},flatOptions:{context:!0,url:!0}},ajaxPrefilter:bZ(bT),ajaxTransport:bZ(bU),ajax:function(a,c){function w(a,c,l,m){if(s!==2){s=2,q&&clearTimeout(q),p=b,n=m||"",v.readyState=a>0?4:0;var o,r,u,w=c,x=l?cb(d,v,l):b,y,z;if(a>=200&&a<300||a===304){if(d.ifModified){if(y=v.getResponseHeader("Last-Modified"))f.lastModified[k]=y;if(z=v.getResponseHeader("Etag"))f.etag[k]=z}if(a===304)w="notmodified",o=!0;else try{r=cc(d,x),w="success",o=!0}catch(A){w="parsererror",u=A}}else{u=w;if(!w||a)w="error",a<0&&(a=0)}v.status=a,v.statusText=""+(c||w),o?h.resolveWith(e,[r,w,v]):h.rejectWith(e,[v,w,u]),v.statusCode(j),j=b,t&&g.trigger("ajax"+(o?"Success":"Error"),[v,d,o?r:u]),i.fireWith(e,[v,w]),t&&(g.trigger("ajaxComplete",[v,d]),--f.active||f.event.trigger("ajaxStop"))}}typeof a=="object"&&(c=a,a=b),c=c||{};var d=f.ajaxSetup({},c),e=d.context||d,g=e!==d&&(e.nodeType||e instanceof f)?f(e):f.event,h=f.Deferred(),i=f.Callbacks("once memory"),j=d.statusCode||{},k,l={},m={},n,o,p,q,r,s=0,t,u,v={readyState:0,setRequestHeader:function(a,b){if(!s){var c=a.toLowerCase();a=m[c]=m[c]||a,l[a]=b}return this},getAllResponseHeaders:function(){return s===2?n:null},getResponseHeader:function(a){var c;if(s===2){if(!o){o={};while(c=bH.exec(n))o[c[1].toLowerCase()]=c[2]}c=o[a.toLowerCase()]}return c===b?null:c},overrideMimeType:function(a){s||(d.mimeType=a);return this},abort:function(a){a=a||"abort",p&&p.abort(a),w(0,a);return this}};h.promise(v),v.success=v.done,v.error=v.fail,v.complete=i.add,v.statusCode=function(a){if(a){var b;if(s<2)for(b in a)j[b]=[j[b],a[b]];else b=a[v.status],v.then(b,b)}return this},d.url=((a||d.url)+"").replace(bG,"").replace(bL,bW[1]+"//"),d.dataTypes=f.trim(d.dataType||"*").toLowerCase().split(bP),d.crossDomain==null&&(r=bR.exec(d.url.toLowerCase()),d.crossDomain=!(!r||r[1]==bW[1]&&r[2]==bW[2]&&(r[3]||(r[1]==="http:"?80:443))==(bW[3]||(bW[1]==="http:"?80:443)))),d.data&&d.processData&&typeof d.data!="string"&&(d.data=f.param(d.data,d.traditional)),b$(bT,d,c,v);if(s===2)return!1;t=d.global,d.type=d.type.toUpperCase(),d.hasContent=!bK.test(d.type),t&&f.active++===0&&f.event.trigger("ajaxStart");if(!d.hasContent){d.data&&(d.url+=(bM.test(d.url)?"&":"?")+d.data,delete d.data),k=d.url;if(d.cache===!1){var x=f.now(),y=d.url.replace(bQ,"$1_="+x);d.url=y+(y===d.url?(bM.test(d.url)?"&":"?")+"_="+x:"")}}(d.data&&d.hasContent&&d.contentType!==!1||c.contentType)&&v.setRequestHeader("Content-Type",d.contentType),d.ifModified&&(k=k||d.url,f.lastModified[k]&&v.setRequestHeader("If-Modified-Since",f.lastModified[k]),f.etag[k]&&v.setRequestHeader("If-None-Match",f.etag[k])),v.setRequestHeader("Accept",d.dataTypes[0]&&d.accepts[d.dataTypes[0]]?d.accepts[d.dataTypes[0]]+(d.dataTypes[0]!=="*"?", "+bX+"; q=0.01":""):d.accepts["*"]);for(u in d.headers)v.setRequestHeader(u,d.headers[u]);if(d.beforeSend&&(d.beforeSend.call(e,v,d)===!1||s===2)){v.abort();return!1}for(u in{success:1,error:1,complete:1})v[u](d[u]);p=b$(bU,d,c,v);if(!p)w(-1,"No Transport");else{v.readyState=1,t&&g.trigger("ajaxSend",[v,d]),d.async&&d.timeout>0&&(q=setTimeout(function(){v.abort("timeout")},d.timeout));try{s=1,p.send(l,w)}catch(z){if(s<2)w(-1,z);else throw z}}return v},param:function(a,c){var d=[],e=function(a,b){b=f.isFunction(b)?b():b,d[d.length]=encodeURIComponent(a)+"="+encodeURIComponent(b)};c===b&&(c=f.ajaxSettings.traditional);if(f.isArray(a)||a.jquery&&!f.isPlainObject(a))f.each(a,function(){e(this.name,this.value)});else for(var g in a)ca(g,a[g],c,e);return d.join("&").replace(bD,"+")}}),f.extend({active:0,lastModified:{},etag:{}});var cd=f.now(),ce=/(\=)\?(&|$)|\?\?/i;f.ajaxSetup({jsonp:"callback",jsonpCallback:function(){return f.expando+"_"+cd++}}),f.ajaxPrefilter("json jsonp",function(b,c,d){var e=b.contentType==="application/x-www-form-urlencoded"&&typeof b.data=="string";if(b.dataTypes[0]==="jsonp"||b.jsonp!==!1&&(ce.test(b.url)||e&&ce.test(b.data))){var g,h=b.jsonpCallback=f.isFunction(b.jsonpCallback)?b.jsonpCallback():b.jsonpCallback,i=a[h],j=b.url,k=b.data,l="$1"+h+"$2";b.jsonp!==!1&&(j=j.replace(ce,l),b.url===j&&(e&&(k=k.replace(ce,l)),b.data===k&&(j+=(/\?/.test(j)?"&":"?")+b.jsonp+"="+h))),b.url=j,b.data=k,a[h]=function(a){g=[a]},d.always(function(){a[h]=i,g&&f.isFunction(i)&&a[h](g[0])}),b.converters["script json"]=function(){g||f.error(h+" was not called");return g[0]},b.dataTypes[0]="json";return"script"}}),f.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/javascript|ecmascript/},converters:{"text script":function(a){f.globalEval(a);return a}}}),f.ajaxPrefilter("script",function(a){a.cache===b&&(a.cache=!1),a.crossDomain&&(a.type="GET",a.global=!1)}),f.ajaxTransport("script",function(a){if(a.crossDomain){var d,e=c.head||c.getElementsByTagName("head")[0]||c.documentElement;return{send:function(f,g){d=c.createElement("script"),d.async="async",a.scriptCharset&&(d.charset=a.scriptCharset),d.src=a.url,d.onload=d.onreadystatechange=function(a,c){if(c||!d.readyState||/loaded|complete/.test(d.readyState))d.onload=d.onreadystatechange=null,e&&d.parentNode&&e.removeChild(d),d=b,c||g(200,"success")},e.insertBefore(d,e.firstChild)},abort:function(){d&&d.onload(0,1)}}}});var cf=a.ActiveXObject?function(){for(var a in ch)ch[a](0,1)}:!1,cg=0,ch;f.ajaxSettings.xhr=a.ActiveXObject?function(){return!this.isLocal&&ci()||cj()}:ci,function(a){f.extend(f.support,{ajax:!!a,cors:!!a&&"withCredentials"in a})}(f.ajaxSettings.xhr()),f.support.ajax&&f.ajaxTransport(function(c){if(!c.crossDomain||f.support.cors){var d;return{send:function(e,g){var h=c.xhr(),i,j;c.username?h.open(c.type,c.url,c.async,c.username,c.password):h.open(c.type,c.url,c.async);if(c.xhrFields)for(j in c.xhrFields)h[j]=c.xhrFields[j];c.mimeType&&h.overrideMimeType&&h.overrideMimeType(c.mimeType),!c.crossDomain&&!e["X-Requested-With"]&&(e["X-Requested-With"]="XMLHttpRequest");try{for(j in e)h.setRequestHeader(j,e[j])}catch(k){}h.send(c.hasContent&&c.data||null),d=function(a,e){var j,k,l,m,n;try{if(d&&(e||h.readyState===4)){d=b,i&&(h.onreadystatechange=f.noop,cf&&delete ch[i]);if(e)h.readyState!==4&&h.abort();else{j=h.status,l=h.getAllResponseHeaders(),m={},n=h.responseXML,n&&n.documentElement&&(m.xml=n),m.text=h.responseText;try{k=h.statusText}catch(o){k=""}!j&&c.isLocal&&!c.crossDomain?j=m.text?200:404:j===1223&&(j=204)}}}catch(p){e||g(-1,p)}m&&g(j,k,m,l)},!c.async||h.readyState===4?d():(i=++cg,cf&&(ch||(ch={},f(a).unload(cf)),ch[i]=d),h.onreadystatechange=d)},abort:function(){d&&d(0,1)}}}});var ck={},cl,cm,cn=/^(?:toggle|show|hide)$/,co=/^([+\-]=)?([\d+.\-]+)([a-z%]*)$/i,cp,cq=[["height","marginTop","marginBottom","paddingTop","paddingBottom"],["width","marginLeft","marginRight","paddingLeft","paddingRight"],["opacity"]],cr;f.fn.extend({show:function(a,b,c){var d,e;if(a||a===0)return this.animate(cu("show",3),a,b,c);for(var g=0,h=this.length;g=i.duration+this.startTime){this.now=this.end,this.pos=this.state=1,this.update(),i.animatedProperties[this.prop]=!0;for(b in i.animatedProperties)i.animatedProperties[b]!==!0&&(g=!1);if(g){i.overflow!=null&&!f.support.shrinkWrapBlocks&&f.each(["","X","Y"],function(a,b){h.style["overflow"+b]=i.overflow[a]}),i.hide&&f(h).hide();if(i.hide||i.show)for(b in i.animatedProperties)f.style(h,b,i.orig[b]),f.removeData(h,"fxshow"+b,!0),f.removeData(h,"toggle"+b,!0);d=i.complete,d&&(i.complete=!1,d.call(h))}return!1}i.duration==Infinity?this.now=e:(c=e-this.startTime,this.state=c/i.duration,this.pos=f.easing[i.animatedProperties[this.prop]](this.state,c,0,1,i.duration),this.now=this.start+(this.end-this.start)*this.pos),this.update();return!0}},f.extend(f.fx,{tick:function(){var a,b=f.timers,c=0;for(;c-1,k={},l={},m,n;j?(l=e.position(),m=l.top,n=l.left):(m=parseFloat(h)||0,n=parseFloat(i)||0),f.isFunction(b)&&(b=b.call(a,c,g)),b.top!=null&&(k.top=b.top-g.top+m),b.left!=null&&(k.left=b.left-g.left+n),"using"in b?b.using.call(a,k):e.css(k)}},f.fn.extend({position:function(){if(!this[0])return null;var a=this[0],b=this.offsetParent(),c=this.offset(),d=cx.test(b[0].nodeName)?{top:0,left:0}:b.offset();c.top-=parseFloat(f.css(a,"marginTop"))||0,c.left-=parseFloat(f.css(a,"marginLeft"))||0,d.top+=parseFloat(f.css(b[0],"borderTopWidth"))||0,d.left+=parseFloat(f.css(b[0],"borderLeftWidth"))||0;return{top:c.top-d.top,left:c.left-d.left}},offsetParent:function(){return this.map(function(){var a=this.offsetParent||c.body;while(a&&!cx.test(a.nodeName)&&f.css(a,"position")==="static")a=a.offsetParent;return a})}}),f.each(["Left","Top"],function(a,c){var d="scroll"+c;f.fn[d]=function(c){var e,g;if(c===b){e=this[0];if(!e)return null;g=cy(e);return g?"pageXOffset"in g?g[a?"pageYOffset":"pageXOffset"]:f.support.boxModel&&g.document.documentElement[d]||g.document.body[d]:e[d]}return this.each(function(){g=cy(this),g?g.scrollTo(a?f(g).scrollLeft():c,a?c:f(g).scrollTop()):this[d]=c})}}),f.each(["Height","Width"],function(a,c){var d=c.toLowerCase();f.fn["inner"+c]=function(){var a=this[0];return a?a.style?parseFloat(f.css(a,d,"padding")):this[d]():null},f.fn["outer"+c]=function(a){var b=this[0];return b?b.style?parseFloat(f.css(b,d,a?"margin":"border")):this[d]():null},f.fn[d]=function(a){var e=this[0];if(!e)return a==null?null:this;if(f.isFunction(a))return this.each(function(b){var c=f(this);c[d](a.call(this,b,c[d]()))});if(f.isWindow(e)){var g=e.document.documentElement["client"+c],h=e.document.body;return e.document.compatMode==="CSS1Compat"&&g||h&&h["client"+c]||g}if(e.nodeType===9)return Math.max(e.documentElement["client"+c],e.body["scroll"+c],e.documentElement["scroll"+c],e.body["offset"+c],e.documentElement["offset"+c]);if(a===b){var i=f.css(e,d),j=parseFloat(i);return f.isNumeric(j)?j:i}return this.css(d,typeof a=="string"?a:a+"px")}}),a.jQuery=a.$=f,typeof define=="function"&&define.amd&&define.amd.jQuery&&define("jquery",[],function(){return f})})(window); \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-action-manager/test-output/junitreports/TEST-com.amdocs.asdc.action.ActionTest.xml b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/junitreports/TEST-com.amdocs.asdc.action.ActionTest.xml new file mode 100644 index 0000000000..538301cde7 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/junitreports/TEST-com.amdocs.asdc.action.ActionTest.xml @@ -0,0 +1,53 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/openecomp-be/backend/openecomp-sdc-action-manager/test-output/navigator-bullet.png b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/navigator-bullet.png new file mode 100644 index 0000000000000000000000000000000000000000..36d90d395c51912e718b89dd88b4a3fb53aa1d85 GIT binary patch literal 352 zcmV-m0iXVfP)G5@hw44>$jtc^drBsEhr7 z^X9?-KzfCWMC0vWtek#CBxB+XG+nX0$0e)!py)g%*!C9F3xb^$q9zV zJJ-RS;)J3Q3>X<0IJnsvq?E-OUUR%-Sh{}$*!>`a1>MbzjEoGd?5qriD%uRz5+)#_ z=~xvqF)}e2@@p|@3aYFDDdOf=+lQf0fP;_0P2842gi~-LkXsB?^cOvN)>U@o{(tlO y5-4a&(SrsYdr*b0AjKdWn<5ZqBsQ)A0t^5xc9&6bK}yU30000 +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Class nameMethod nameGroups
ActionTest  
@Test
 testUploadArtifactSameName_negative 
 testCheckIn 
 testGetBySupportedComponent 
 testDeleteArtifactOnUnlockedAction 
 testDeleteArtifactInvalidActInvId 
 testUpdateStatus_negativeupdateTestGroup
 testUpdateArtifact 
 testGetByVendor 
 testCheckInWithOtherUser 
 testGetByInvIdManyVersionWithMultSubmit 
 testUpdateOtherUser_negativeupdateTestGroup
 testUploadArtifactCheckedOutOtherUser_negative 
 testCheckInWithoutCheckout 
 updateTestupdateTestGroup
 testUpdateVersion_negativeupdateTestGroup
 testGetByIgnoreCaseName 
 testgetActionsByActionUUID 
 testGetECOMPComponents 
 testGetByCategory 
 testDownloadArtifact 
 createTest 
 testUpdateName_negativeupdateTestGroup
 testGetAllActions 
 testUndoCheckout 
 testCheckOutOnCheckOutWithOtherUser 
 testUploadArtifactInvalidActionInvId_negative 
 testSubmit 
 testgetActionsByActionUUID_Negative 
 testUpdateOnCheckedInAction_negative 
 testGetByInvIdManyVersionWithoutSubmit 
 testGetByInvIdManyVersionWithFirstSubmit 
 testUpdateUniqueId_negativeupdateTestGroup
 testGetByInvIdOnCreate 
 testGetBySupportedModel 
 testUploadArtifact 
 testDownloadArtifactNegativeInvalidArtifact 
 testDeleteReadOnlyArtifact 
 testUpdateInvariantId_negativeupdateTestGroup
 testDownloadArtifactNegativeInvalidAction 
 testGetByInvIdOnName 
 testUpdateInvalidVersion_negativeupdateTestGroup
 testDeleteArtifact 
 testDeleteArtifactLockedByOtherUser 
 testCheckOut 
 testCheckOutOnCheckOut 
 testUploadArtifactUnlockedAction_negative 
 testSubmitOnCheckout 
 testDeleteArtifactInvalidArtifactUUID 
 testCreateWithExistingActionName_negative 
@BeforeClass
@BeforeMethod
@AfterMethod
@AfterClass
diff --git a/openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/groups.html b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/groups.html new file mode 100644 index 0000000000..211c8ec14d --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/groups.html @@ -0,0 +1,3 @@ +

Groups used for this test run

+ +
Group nameMethods
updateTestGroupActionTest.testUpdateOtherUser_negative()[pri:0, instance:ActionTest@5b367418]
ActionTest.testUpdateInvariantId_negative()[pri:0, instance:ActionTest@5b367418]
ActionTest.testUpdateStatus_negative()[pri:0, instance:ActionTest@5b367418]
ActionTest.testUpdateUniqueId_negative()[pri:0, instance:ActionTest@5b367418]
ActionTest.testUpdateVersion_negative()[pri:0, instance:ActionTest@5b367418]
ActionTest.updateTest()[pri:0, instance:ActionTest@5b367418]
ActionTest.testUpdateInvalidVersion_negative()[pri:0, instance:ActionTest@5b367418]
ActionTest.testUpdateName_negative()[pri:0, instance:ActionTest@5b367418]
diff --git a/openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/index.html b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/index.html new file mode 100644 index 0000000000..8ed202c3be --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/index.html @@ -0,0 +1,6 @@ +Results for Default suite + + + + + diff --git a/openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/main.html b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/main.html new file mode 100644 index 0000000000..5888ae0744 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/main.html @@ -0,0 +1,2 @@ +Results for Default suite +Select a result on the left-hand pane. diff --git a/openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/methods-alphabetical.html b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/methods-alphabetical.html new file mode 100644 index 0000000000..c7600fc861 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/methods-alphabetical.html @@ -0,0 +1,104 @@ +

Methods run, sorted chronologically

>> means before, << means after


Default suite

(Hover the method name to see the test class name)

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TimeDelta (ms)Suite
configuration
Test
configuration
Class
configuration
Groups
configuration
Method
configuration
Test
method
ThreadInstances
16/09/08 12:49:39 0      createTestmain@222427158
16/09/08 12:49:36 -2616  >>init     main@222427158
16/09/08 12:49:42 3293      testCheckInmain@222427158
16/09/08 12:49:42 3358      testCheckInWithOtherUsermain@222427158
16/09/08 12:49:42 3332      testCheckInWithoutCheckoutmain@222427158
16/09/08 12:49:42 3337      testCheckOutmain@222427158
16/09/08 12:49:40 1172      testCheckOutOnCheckOutmain@222427158
16/09/08 12:49:40 1186      testCheckOutOnCheckOutWithOtherUsermain@222427158
16/09/08 12:49:40 1195      testCreateWithExistingActionName_negativemain@222427158
16/09/08 12:49:41 1864      testDeleteArtifactmain@222427158
16/09/08 12:49:39 80      testDeleteArtifactInvalidActInvIdmain@222427158
16/09/08 12:49:40 1258      testDeleteArtifactInvalidArtifactUUIDmain@222427158
16/09/08 12:49:41 1904      testDeleteArtifactLockedByOtherUsermain@222427158
16/09/08 12:49:41 2574      testDeleteArtifactOnUnlockedActionmain@222427158
16/09/08 12:49:41 1909      testDeleteReadOnlyArtifactmain@222427158
16/09/08 12:49:41 1969      testDownloadArtifactmain@222427158
16/09/08 12:49:39 84      testDownloadArtifactNegativeInvalidActionmain@222427158
16/09/08 12:49:41 1978      testDownloadArtifactNegativeInvalidArtifactmain@222427158
16/09/08 12:49:40 1201      testGetAllActionsmain@222427158
16/09/08 12:49:39 89      testGetByCategorymain@222427158
16/09/08 12:49:40 1268      testGetByIgnoreCaseNamemain@222427158
16/09/08 12:49:41 2058      testGetByInvIdManyVersionWithFirstSubmitmain@222427158
16/09/08 12:49:42 2597      testGetByInvIdManyVersionWithMultSubmitmain@222427158
16/09/08 12:49:40 1280      testGetByInvIdManyVersionWithoutSubmitmain@222427158
16/09/08 12:49:40 1051      testGetByInvIdOnCreatemain@222427158
16/09/08 12:49:42 3022      testGetByInvIdOnNamemain@222427158
16/09/08 12:49:41 1732      testGetBySupportedComponentmain@222427158
16/09/08 12:49:41 1777      testGetBySupportedModelmain@222427158
16/09/08 12:49:41 1822      testGetByVendormain@222427158
16/09/08 12:49:40 1082      testGetECOMPComponentsmain@222427158
16/09/08 12:49:42 3311      testSubmitmain@222427158
16/09/08 12:49:42 3364      testSubmitOnCheckoutmain@222427158
16/09/08 12:49:42 3369      testUndoCheckoutmain@222427158
16/09/08 12:49:41 1984      testUpdateArtifactmain@222427158
16/09/08 12:49:42 2963      testUpdateInvalidVersion_negativemain@222427158
16/09/08 12:49:42 2970      testUpdateInvariantId_negativemain@222427158
16/09/08 12:49:42 2977      testUpdateName_negativemain@222427158
16/09/08 12:49:42 3304      testUpdateOnCheckedInAction_negativemain@222427158
16/09/08 12:49:42 2986      testUpdateOtherUser_negativemain@222427158
16/09/08 12:49:42 2994      testUpdateStatus_negativemain@222427158
16/09/08 12:49:42 3005      testUpdateUniqueId_negativemain@222427158
16/09/08 12:49:42 3014      testUpdateVersion_negativemain@222427158
16/09/08 12:49:40 1088      testUploadArtifactmain@222427158
16/09/08 12:49:41 2007      testUploadArtifactCheckedOutOtherUser_negativemain@222427158
16/09/08 12:49:41 2014      testUploadArtifactInvalidActionInvId_negativemain@222427158
16/09/08 12:49:41 2020      testUploadArtifactSameName_negativemain@222427158
16/09/08 12:49:41 2030      testUploadArtifactUnlockedAction_negativemain@222427158
16/09/08 12:49:41 2052      testgetActionsByActionUUIDmain@222427158
16/09/08 12:49:40 1166      testgetActionsByActionUUID_Negativemain@222427158
16/09/08 12:49:41 2579      updateTestmain@222427158
diff --git a/openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/methods-not-run.html b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/methods-not-run.html new file mode 100644 index 0000000000..54b14cb854 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/methods-not-run.html @@ -0,0 +1,2 @@ +

Methods that were not run

+
\ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/methods.html b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/methods.html new file mode 100644 index 0000000000..ebf981d265 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/methods.html @@ -0,0 +1,104 @@ +

Methods run, sorted chronologically

>> means before, << means after


Default suite

(Hover the method name to see the test class name)

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TimeDelta (ms)Suite
configuration
Test
configuration
Class
configuration
Groups
configuration
Method
configuration
Test
method
ThreadInstances
16/09/08 12:49:36 0  >>init     main@222427158
16/09/08 12:49:39 2616      createTestmain@222427158
16/09/08 12:49:39 2696      testDeleteArtifactInvalidActInvIdmain@222427158
16/09/08 12:49:39 2700      testDownloadArtifactNegativeInvalidActionmain@222427158
16/09/08 12:49:39 2705      testGetByCategorymain@222427158
16/09/08 12:49:40 3667      testGetByInvIdOnCreatemain@222427158
16/09/08 12:49:40 3698      testGetECOMPComponentsmain@222427158
16/09/08 12:49:40 3704      testUploadArtifactmain@222427158
16/09/08 12:49:40 3782      testgetActionsByActionUUID_Negativemain@222427158
16/09/08 12:49:40 3788      testCheckOutOnCheckOutmain@222427158
16/09/08 12:49:40 3802      testCheckOutOnCheckOutWithOtherUsermain@222427158
16/09/08 12:49:40 3811      testCreateWithExistingActionName_negativemain@222427158
16/09/08 12:49:40 3817      testGetAllActionsmain@222427158
16/09/08 12:49:40 3874      testDeleteArtifactInvalidArtifactUUIDmain@222427158
16/09/08 12:49:40 3884      testGetByIgnoreCaseNamemain@222427158
16/09/08 12:49:40 3896      testGetByInvIdManyVersionWithoutSubmitmain@222427158
16/09/08 12:49:41 4348      testGetBySupportedComponentmain@222427158
16/09/08 12:49:41 4393      testGetBySupportedModelmain@222427158
16/09/08 12:49:41 4438      testGetByVendormain@222427158
16/09/08 12:49:41 4480      testDeleteArtifactmain@222427158
16/09/08 12:49:41 4520      testDeleteArtifactLockedByOtherUsermain@222427158
16/09/08 12:49:41 4525      testDeleteReadOnlyArtifactmain@222427158
16/09/08 12:49:41 4585      testDownloadArtifactmain@222427158
16/09/08 12:49:41 4594      testDownloadArtifactNegativeInvalidArtifactmain@222427158
16/09/08 12:49:41 4600      testUpdateArtifactmain@222427158
16/09/08 12:49:41 4623      testUploadArtifactCheckedOutOtherUser_negativemain@222427158
16/09/08 12:49:41 4630      testUploadArtifactInvalidActionInvId_negativemain@222427158
16/09/08 12:49:41 4636      testUploadArtifactSameName_negativemain@222427158
16/09/08 12:49:41 4646      testUploadArtifactUnlockedAction_negativemain@222427158
16/09/08 12:49:41 4668      testgetActionsByActionUUIDmain@222427158
16/09/08 12:49:41 4674      testGetByInvIdManyVersionWithFirstSubmitmain@222427158
16/09/08 12:49:41 5190      testDeleteArtifactOnUnlockedActionmain@222427158
16/09/08 12:49:41 5195      updateTestmain@222427158
16/09/08 12:49:42 5213      testGetByInvIdManyVersionWithMultSubmitmain@222427158
16/09/08 12:49:42 5579      testUpdateInvalidVersion_negativemain@222427158
16/09/08 12:49:42 5586      testUpdateInvariantId_negativemain@222427158
16/09/08 12:49:42 5593      testUpdateName_negativemain@222427158
16/09/08 12:49:42 5602      testUpdateOtherUser_negativemain@222427158
16/09/08 12:49:42 5610      testUpdateStatus_negativemain@222427158
16/09/08 12:49:42 5621      testUpdateUniqueId_negativemain@222427158
16/09/08 12:49:42 5630      testUpdateVersion_negativemain@222427158
16/09/08 12:49:42 5638      testGetByInvIdOnNamemain@222427158
16/09/08 12:49:42 5909      testCheckInmain@222427158
16/09/08 12:49:42 5920      testUpdateOnCheckedInAction_negativemain@222427158
16/09/08 12:49:42 5927      testSubmitmain@222427158
16/09/08 12:49:42 5948      testCheckInWithoutCheckoutmain@222427158
16/09/08 12:49:42 5953      testCheckOutmain@222427158
16/09/08 12:49:42 5974      testCheckInWithOtherUsermain@222427158
16/09/08 12:49:42 5980      testSubmitOnCheckoutmain@222427158
16/09/08 12:49:42 5985      testUndoCheckoutmain@222427158
diff --git a/openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/reporter-output.html b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/reporter-output.html new file mode 100644 index 0000000000..063bc2e96f --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/reporter-output.html @@ -0,0 +1 @@ +

Reporter output

\ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/testng.xml.html b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/testng.xml.html new file mode 100644 index 0000000000..ce68151560 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/testng.xml.html @@ -0,0 +1 @@ +testng.xml for Default suite<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE suite SYSTEM "http://testng.org/testng-1.0.dtd">
<suite name="Default suite">
  <test verbose="2" name="Default test">
    <classes>
      <class name="ActionTest"/>
    </classes>
  </test> <!-- Default test -->
</suite> <!-- Default suite -->
\ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/toc.html b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/toc.html new file mode 100644 index 0000000000..a27f5af7c9 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/Default suite/toc.html @@ -0,0 +1,30 @@ + + +Results for Default suite + + + + +

Results for
Default suite

+ + + + + + + + + + +
1 test1 class49 methods:
+  chronological
+  alphabetical
+  not run (0)
1 groupreporter outputtestng.xml
+ +

+

+
Default test (49/0/0) + Results +
+
+ \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/index.html b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/index.html new file mode 100644 index 0000000000..0ac18dca36 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/old/index.html @@ -0,0 +1,9 @@ + +Test results + + +

Test results

+ + + +
SuitePassedFailedSkippedtestng.xml
Total4900 
Default suite4900Link
diff --git a/openecomp-be/backend/openecomp-sdc-action-manager/test-output/passed.png b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/passed.png new file mode 100644 index 0000000000000000000000000000000000000000..45e85bbfd0f5e85def14b896cfd4331675be2759 GIT binary patch literal 1019 zcmV4Tx0C)j~RNrgUP!#^!Wu36$i#lf!2|j3%Ze&w*L!7p2SGvtw>Nd9_NSmf@ zT$;ut?S8Na*^6&F#dq-sKKTa>*@JI;k`2ZbVfd_wB24xov!0tYO(#d#()tZ$I5%3%!zLYh@BH>w}XODA7?mkV}ap}jU$$3 zG&Mk)3Bm`(LOM&hKscCb;PVaG&Vdx+MpZJHTQ(R_;DA31$+jOGBoLXk_De?ey1m!ik&_4G zH9n^))_*|$z4!HUisgBd@awc5jn(v9k~&t~+vLrrBg4dZQ9lDnLV}JQWGLW~LJVP= zW5lZXOcog;N~F?hbX0k=IMzETla}oqM|jC!4!B+x^;@#I_Tc-T-6hwKycLDTx1-om z?X`jFy0R0R8-I0SrK4`)H@W4T8*Qr#2vPou<*`U!Wy(*2QP*`g=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*nHIFV_d2yUbnT`nd?LE^;G|!WZ>Ld?E0@Grm4ww{M7H zr`x{MWb30bTI;*hk-DO>dX$gbC-yy#suLNqvA(f>RtPJ!qGM`Gvvf}Y10`)vm-7Xa z?-7Ixe2A_siI1ydSCCID3U8SVUY86>uSnT0use_K1GZDvUFKY)t}F* z)!pahe+zh{{06Bb3f97*Uorpy0Axu-K~yLeV|;sz;XeZjfQbaPV5M*kLYBBKLY9MT zcz2wU0a*fOGe`_12Lo^oAOUnu=!!vVSU?0aK-Pq8GE5DM4KP7`G=>J4GmvdUHULEf pOfgIWHcfC1=!$V^Vx)OY0{~v*D#slo71{s*002ovPDHLkV1jLYy!8M8 literal 0 HcmV?d00001 diff --git a/openecomp-be/backend/openecomp-sdc-action-manager/test-output/testng-failed.xml b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/testng-failed.xml new file mode 100644 index 0000000000..5f2650e66e --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/testng-failed.xml @@ -0,0 +1,16 @@ + + + + + + + + + + + + + + + + diff --git a/openecomp-be/backend/openecomp-sdc-action-manager/test-output/testng-reports.css b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/testng-reports.css new file mode 100644 index 0000000000..29588e5572 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/testng-reports.css @@ -0,0 +1,309 @@ +body { + margin: 0px 0px 5px 5px; +} + +ul { + margin: 0px; +} + +li { + list-style-type: none; +} + +a { + text-decoration: none; +} + +a:hover { + text-decoration: underline; +} + +.navigator-selected { + background: #ffa500; +} + +.wrapper { + position: absolute; + top: 60px; + bottom: 0; + left: 400px; + right: 0; + overflow: auto; +} + +.navigator-root { + position: absolute; + top: 60px; + bottom: 0; + left: 0; + width: 400px; + overflow-y: auto; +} + +.suite { + margin: 0px 10px 10px 0px; + background-color: #fff8dc; +} + +.suite-name { + padding-left: 10px; + font-size: 25px; + font-family: Times; +} + +.main-panel-header { + padding: 5px; + background-color: #9FB4D9; //afeeee; + font-family: monospace; + font-size: 18px; +} + +.main-panel-content { + padding: 5px; + margin-bottom: 10px; + background-color: #DEE8FC; //d0ffff; +} + +.rounded-window { + border-radius: 10px; + border-style: solid; + border-width: 1px; +} + +.rounded-window-top { + border-top-right-radius: 10px 10px; + border-top-left-radius: 10px 10px; + border-style: solid; + border-width: 1px; + overflow: auto; +} + +.light-rounded-window-top { + border-top-right-radius: 10px 10px; + border-top-left-radius: 10px 10px; +} + +.rounded-window-bottom { + border-style: solid; + border-width: 0px 1px 1px 1px; + border-bottom-right-radius: 10px 10px; + border-bottom-left-radius: 10px 10px; + overflow: auto; +} + +.method-name { + font-size: 12px; + font-family: monospace; +} + +.method-content { + border-style: solid; + border-width: 0px 0px 1px 0px; + margin-bottom: 10; + padding-bottom: 5px; + width: 80%; +} + +.parameters { + font-size: 14px; + font-family: monospace; +} + +.stack-trace { + white-space: pre; + font-family: monospace; + font-size: 12px; + font-weight: bold; + margin-top: 0px; + margin-left: 20px; +} + +.testng-xml { + font-family: monospace; +} + +.method-list-content { + margin-left: 10px; +} + +.navigator-suite-content { + margin-left: 10px; + font: 12px 'Lucida Grande'; +} + +.suite-section-title { + margin-top: 10px; + width: 80%; + border-style: solid; + border-width: 1px 0px 0px 0px; + font-family: Times; + font-size: 18px; + font-weight: bold; +} + +.suite-section-content { + list-style-image: url(bullet_point.png); +} + +.top-banner-root { + position: absolute; + top: 0; + height: 45px; + left: 0; + right: 0; + padding: 5px; + margin: 0px 0px 5px 0px; + background-color: #0066ff; + font-family: Times; + color: #fff; + text-align: center; +} + +.top-banner-title-font { + font-size: 25px; +} + +.test-name { + font-family: 'Lucida Grande'; + font-size: 16px; +} + +.suite-icon { + padding: 5px; + float: right; + height: 20; +} + +.test-group { + font: 20px 'Lucida Grande'; + margin: 5px 5px 10px 5px; + border-width: 0px 0px 1px 0px; + border-style: solid; + padding: 5px; +} + +.test-group-name { + font-weight: bold; +} + +.method-in-group { + font-size: 16px; + margin-left: 80px; +} + +table.google-visualization-table-table { + width: 100%; +} + +.reporter-method-name { + font-size: 14px; + font-family: monospace; +} + +.reporter-method-output-div { + padding: 5px; + margin: 0px 0px 5px 20px; + font-size: 12px; + font-family: monospace; + border-width: 0px 0px 0px 1px; + border-style: solid; +} + +.ignored-class-div { + font-size: 14px; + font-family: monospace; +} + +.ignored-methods-div { + padding: 5px; + margin: 0px 0px 5px 20px; + font-size: 12px; + font-family: monospace; + border-width: 0px 0px 0px 1px; + border-style: solid; +} + +.border-failed { + border-top-left-radius: 10px 10px; + border-bottom-left-radius: 10px 10px; + border-style: solid; + border-width: 0px 0px 0px 10px; + border-color: #f00; +} + +.border-skipped { + border-top-left-radius: 10px 10px; + border-bottom-left-radius: 10px 10px; + border-style: solid; + border-width: 0px 0px 0px 10px; + border-color: #edc600; +} + +.border-passed { + border-top-left-radius: 10px 10px; + border-bottom-left-radius: 10px 10px; + border-style: solid; + border-width: 0px 0px 0px 10px; + border-color: #19f52d; +} + +.times-div { + text-align: center; + padding: 5px; +} + +.suite-total-time { + font: 16px 'Lucida Grande'; +} + +.configuration-suite { + margin-left: 20px; +} + +.configuration-test { + margin-left: 40px; +} + +.configuration-class { + margin-left: 60px; +} + +.configuration-method { + margin-left: 80px; +} + +.test-method { + margin-left: 100px; +} + +.chronological-class { + background-color: #0ccff; + border-style: solid; + border-width: 0px 0px 1px 1px; +} + +.method-start { + float: right; +} + +.chronological-class-name { + padding: 0px 0px 0px 5px; + color: #008; +} + +.after, .before, .test-method { + font-family: monospace; + font-size: 14px; +} + +.navigator-suite-header { + font-size: 22px; + margin: 0px 10px 5px 0px; + background-color: #deb887; + text-align: center; +} + +.collapse-all-icon { + padding: 5px; + float: right; +} diff --git a/openecomp-be/backend/openecomp-sdc-action-manager/test-output/testng-reports.js b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/testng-reports.js new file mode 100644 index 0000000000..5159f81927 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/testng-reports.js @@ -0,0 +1,122 @@ +$(document).ready(function() { + $('a.navigator-link').click(function() { + // Extract the panel for this link + var panel = getPanelName($(this)); + + // Mark this link as currently selected + $('.navigator-link').parent().removeClass('navigator-selected'); + $(this).parent().addClass('navigator-selected'); + + showPanel(panel); + }); + + installMethodHandlers('failed'); + installMethodHandlers('skipped'); + installMethodHandlers('passed', true); // hide passed methods by default + + $('a.method').click(function() { + showMethod($(this)); + return false; + }); + + // Hide all the panels and display the first one (do this last + // to make sure the click() will invoke the listeners) + $('.panel').hide(); + $('.navigator-link').first().click(); + + // Collapse/expand the suites + $('a.collapse-all-link').click(function() { + var contents = $('.navigator-suite-content'); + if (contents.css('display') == 'none') { + contents.show(); + } else { + contents.hide(); + } + }); +}); + +// The handlers that take care of showing/hiding the methods +function installMethodHandlers(name, hide) { + function getContent(t) { + return $('.method-list-content.' + name + "." + t.attr('panel-name')); + } + + function getHideLink(t, name) { + var s = 'a.hide-methods.' + name + "." + t.attr('panel-name'); + return $(s); + } + + function getShowLink(t, name) { + return $('a.show-methods.' + name + "." + t.attr('panel-name')); + } + + function getMethodPanelClassSel(element, name) { + var panelName = getPanelName(element); + var sel = '.' + panelName + "-class-" + name; + return $(sel); + } + + $('a.hide-methods.' + name).click(function() { + var w = getContent($(this)); + w.hide(); + getHideLink($(this), name).hide(); + getShowLink($(this), name).show(); + getMethodPanelClassSel($(this), name).hide(); + }); + + $('a.show-methods.' + name).click(function() { + var w = getContent($(this)); + w.show(); + getHideLink($(this), name).show(); + getShowLink($(this), name).hide(); + showPanel(getPanelName($(this))); + getMethodPanelClassSel($(this), name).show(); + }); + + if (hide) { + $('a.hide-methods.' + name).click(); + } else { + $('a.show-methods.' + name).click(); + } +} + +function getHashForMethod(element) { + return element.attr('hash-for-method'); +} + +function getPanelName(element) { + return element.attr('panel-name'); +} + +function showPanel(panelName) { + $('.panel').hide(); + var panel = $('.panel[panel-name="' + panelName + '"]'); + panel.show(); +} + +function showMethod(element) { + var hashTag = getHashForMethod(element); + var panelName = getPanelName(element); + showPanel(panelName); + var current = document.location.href; + var base = current.substring(0, current.indexOf('#')) + document.location.href = base + '#' + hashTag; + var newPosition = $(document).scrollTop() - 65; + $(document).scrollTop(newPosition); +} + +function drawTable() { + for (var i = 0; i < suiteTableInitFunctions.length; i++) { + window[suiteTableInitFunctions[i]](); + } + + for (var k in window.suiteTableData) { + var v = window.suiteTableData[k]; + var div = v.tableDiv; + var data = v.tableData + var table = new google.visualization.Table(document.getElementById(div)); + table.draw(data, { + showRowNumber : false + }); + } +} diff --git a/openecomp-be/backend/openecomp-sdc-action-manager/test-output/testng-results.xml b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/testng-results.xml new file mode 100644 index 0000000000..02c71b6bac --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/testng-results.xml @@ -0,0 +1,223 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/openecomp-be/backend/openecomp-sdc-action-manager/test-output/testng.css b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/testng.css new file mode 100644 index 0000000000..5124ba863b --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-action-manager/test-output/testng.css @@ -0,0 +1,9 @@ +.invocation-failed, .test-failed { background-color: #DD0000; } +.invocation-percent, .test-percent { background-color: #006600; } +.invocation-passed, .test-passed { background-color: #00AA00; } +.invocation-skipped, .test-skipped { background-color: #CCCC00; } + +.main-page { + font-size: x-large; +} + diff --git a/openecomp-be/backend/openecomp-sdc-application-config-manager/pom.xml b/openecomp-be/backend/openecomp-sdc-application-config-manager/pom.xml new file mode 100644 index 0000000000..437114404f --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-application-config-manager/pom.xml @@ -0,0 +1,55 @@ + + + 4.0.0 + + + org.openecomp.sdc + backend + 1.0.0-SNAPSHOT + + + org.openecomp.sdc + openecomp-sdc-application-config-manager + + + + + com.google.code.gson + gson + 2.3.1 + test + + + org.yaml + snakeyaml + 1.14 + test + + + org.openecomp.core + openecomp-config-lib + ${project.version} + + + org.testng + testng + 6.9.10 + test + + + + + + org.apache.maven.plugins + maven-surefire-plugin + 2.19.1 + + true + + + + + + \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-application-config-manager/src/main/java/org/openecomp/sdc/applicationconfig/ApplicationConfigManager.java b/openecomp-be/backend/openecomp-sdc-application-config-manager/src/main/java/org/openecomp/sdc/applicationconfig/ApplicationConfigManager.java new file mode 100644 index 0000000000..924401b9c1 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-application-config-manager/src/main/java/org/openecomp/sdc/applicationconfig/ApplicationConfigManager.java @@ -0,0 +1,35 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.applicationconfig; + +import org.openecomp.core.utilities.applicationconfig.dao.type.ApplicationConfigEntity; +import org.openecomp.core.utilities.applicationconfig.type.ConfigurationData; + +import java.util.Collection; + +public interface ApplicationConfigManager { + + void insertIntoTable(String namespace, String key, String value); + + ConfigurationData getFromTable(String namespace, String key); + + Collection getListOfConfigurationByNamespace(String namespace); +} diff --git a/openecomp-be/backend/openecomp-sdc-application-config-manager/src/main/java/org/openecomp/sdc/applicationconfig/impl/ApplicationConfigManagerImpl.java b/openecomp-be/backend/openecomp-sdc-application-config-manager/src/main/java/org/openecomp/sdc/applicationconfig/impl/ApplicationConfigManagerImpl.java new file mode 100644 index 0000000000..b44c541261 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-application-config-manager/src/main/java/org/openecomp/sdc/applicationconfig/impl/ApplicationConfigManagerImpl.java @@ -0,0 +1,63 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.applicationconfig.impl; + +import org.openecomp.core.utilities.applicationconfig.ApplicationConfig; +import org.openecomp.core.utilities.applicationconfig.dao.type.ApplicationConfigEntity; +import org.openecomp.core.utilities.applicationconfig.impl.ApplicationConfigImpl; +import org.openecomp.core.utilities.applicationconfig.type.ConfigurationData; +import org.openecomp.sdc.applicationconfig.ApplicationConfigManager; +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; + +import java.util.Collection; + +public class ApplicationConfigManagerImpl implements ApplicationConfigManager { + private static final String SCHEMA_GENERATOR_INITIALIZATION_ERROR = + "SCHEMA_GENERATOR_INITIALIZATION_ERROR"; + private static final String SCHEMA_GENERATOR_INITIALIZATION_ERROR_MSG = + "Error occurred while loading questionnaire schema templates"; + private ApplicationConfig applicationConfig = new ApplicationConfigImpl(); + + @Override + public void insertIntoTable(String namespace, String key, String value) { + try { + applicationConfig.insertValue(namespace, key, value); + } catch (Exception exception) { + throw new CoreException(new ErrorCode.ErrorCodeBuilder() + .withCategory(ErrorCategory.APPLICATION) + .withId(SCHEMA_GENERATOR_INITIALIZATION_ERROR) + .withMessage(SCHEMA_GENERATOR_INITIALIZATION_ERROR_MSG) + .build()); + } + } + + @Override + public ConfigurationData getFromTable(String namespace, String key) { + return applicationConfig.getConfigurationData(namespace, key); + } + + @Override + public Collection getListOfConfigurationByNamespace(String namespace) { + return applicationConfig.getListOfConfigurationByNamespace(namespace); + } +} diff --git a/openecomp-be/backend/openecomp-sdc-application-config-manager/src/test/java/org/openecomp/sdc/applicationconfig/ApplicationConfigManagerTest.java b/openecomp-be/backend/openecomp-sdc-application-config-manager/src/test/java/org/openecomp/sdc/applicationconfig/ApplicationConfigManagerTest.java new file mode 100644 index 0000000000..291ef18e19 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-application-config-manager/src/test/java/org/openecomp/sdc/applicationconfig/ApplicationConfigManagerTest.java @@ -0,0 +1,64 @@ +package org.openecomp.sdc.applicationconfig; + +import org.openecomp.sdc.applicationconfig.impl.ApplicationConfigManagerImpl; +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.core.utilities.applicationconfig.dao.type.ApplicationConfigEntity; +import org.openecomp.core.utilities.applicationconfig.type.ConfigurationData; + +import org.testng.Assert; +import org.testng.annotations.Test; + +import java.util.Collection; + +public class ApplicationConfigManagerTest { + + public static final String TEST_NAMESPACE_1 = "test-app-namespace"; + public static final String TEST_NAMESPACE_2 = "test-namespace"; + public static final String TEST_KEY = "test-app-key"; + public static final String TEST_VALUE = "test-app-value"; + ApplicationConfigManager applicationConfigManager = new ApplicationConfigManagerImpl(); + + @Test + public void testInsertIntoTable() { + try { + applicationConfigManager.insertIntoTable(TEST_NAMESPACE_1, TEST_KEY, TEST_VALUE); + } catch (CoreException e) { + Assert.assertEquals(e.getMessage(), + "Error occurred while loading questionnaire schema templates"); + } + } + + + @Test(dependsOnMethods = "testInsertIntoTable") + public void testGetValueFromTable() { + ConfigurationData value = applicationConfigManager.getFromTable(TEST_NAMESPACE_1, TEST_KEY); + + Assert.assertEquals(value.getValue(), TEST_VALUE); + } + + + @Test(dependsOnMethods = "testInsertIntoTable") + public void testGetValueFromTableNegative() { + try { + ConfigurationData value = + applicationConfigManager.getFromTable("not-existing-namespace", "not-existing-key"); + } catch (CoreException ce) { + Assert.assertEquals(ce.getMessage(), + "Configuration for namespace not-existing-namespace and key not-existing-key was not found"); + } + + } + + @Test + public void testGetList() { + applicationConfigManager.insertIntoTable(TEST_NAMESPACE_2, "key1", "val1"); + applicationConfigManager.insertIntoTable(TEST_NAMESPACE_2, "key2", "val2"); + applicationConfigManager.insertIntoTable(TEST_NAMESPACE_2, "key3", "val3"); + + Collection ACElist = + applicationConfigManager.getListOfConfigurationByNamespace(TEST_NAMESPACE_2); + + Assert.assertNotNull(ACElist); + Assert.assertEquals(ACElist.size(), 3); + } +} diff --git a/openecomp-be/backend/openecomp-sdc-validation-manager/pom.xml b/openecomp-be/backend/openecomp-sdc-validation-manager/pom.xml new file mode 100644 index 0000000000..4a7b39aae1 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-validation-manager/pom.xml @@ -0,0 +1,78 @@ + + + 4.0.0 + + + org.openecomp.sdc + backend + 1.0.0-SNAPSHOT + + + openecomp-sdc-validation-manager + + + + org.openecomp.core + openecomp-utilities-lib + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-validation-core + ${project.version} + + + org.openecomp.core + openecomp-heat-lib + ${project.version} + + + + + org.testng + testng + 6.9.10 + test + + + junit + junit + RELEASE + test + + + + + org.openecomp.sdc + openecomp-sdc-translator-core + ${project.version} + + + com.fasterxml.jackson.dataformat + jackson-dataformat-xml + 2.7.4 + + + org.codehaus.woodstox + woodstox-core-asl + 4.4.1 + + + org.openecomp.sdc + openecomp-sdc-vendor-license-core + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-validation-api + ${project.version} + + + + + + + + \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-validation-manager/src/main/java/org/openecomp/sdc/validation/UploadValidationManager.java b/openecomp-be/backend/openecomp-sdc-validation-manager/src/main/java/org/openecomp/sdc/validation/UploadValidationManager.java new file mode 100644 index 0000000000..734771f909 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-validation-manager/src/main/java/org/openecomp/sdc/validation/UploadValidationManager.java @@ -0,0 +1,34 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.validation; + +import org.openecomp.sdc.validation.types.ValidationFileResponse; + +import java.io.IOException; +import java.io.InputStream; + +public interface UploadValidationManager { + + + ValidationFileResponse validateFile(String type, InputStream heatFileToUpload) throws IOException; + + +} diff --git a/openecomp-be/backend/openecomp-sdc-validation-manager/src/main/java/org/openecomp/sdc/validation/errors/ValidationErrorCodes.java b/openecomp-be/backend/openecomp-sdc-validation-manager/src/main/java/org/openecomp/sdc/validation/errors/ValidationErrorCodes.java new file mode 100644 index 0000000000..815517cdb8 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-validation-manager/src/main/java/org/openecomp/sdc/validation/errors/ValidationErrorCodes.java @@ -0,0 +1,26 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.validation.errors; + +public class ValidationErrorCodes { + public static final String VALIDATION_INVALID = "VALIDATION_INVALID"; + +} diff --git a/openecomp-be/backend/openecomp-sdc-validation-manager/src/main/java/org/openecomp/sdc/validation/errors/ValidationInvalidErrorBuilder.java b/openecomp-be/backend/openecomp-sdc-validation-manager/src/main/java/org/openecomp/sdc/validation/errors/ValidationInvalidErrorBuilder.java new file mode 100644 index 0000000000..5e4cb59ef3 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-validation-manager/src/main/java/org/openecomp/sdc/validation/errors/ValidationInvalidErrorBuilder.java @@ -0,0 +1,75 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.validation.errors; + +import static org.openecomp.sdc.validation.errors.ValidationErrorCodes.VALIDATION_INVALID; + +import org.openecomp.sdc.common.errors.BaseErrorBuilder; +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.datatypes.error.ErrorMessage; + +import java.util.List; +import java.util.Map; + +/** + * The type Validation invalid error builder. + */ +public class ValidationInvalidErrorBuilder extends BaseErrorBuilder { + private static final String VALIDATION_INVALID_DETAILED_MSG = "File is invalid: %s"; + private static final String VALIDATION_INVALID_MSG = "Validated file is invalid"; + + /** + * Instantiates a new Validation invalid error builder. + * + * @param errors the errors + */ + public ValidationInvalidErrorBuilder(Map> errors) { + getErrorCodeBuilder().withId(VALIDATION_INVALID); + getErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION); + getErrorCodeBuilder() + .withMessage(String.format(VALIDATION_INVALID_DETAILED_MSG, toString(errors))); + } + + /** + * Instantiates a new Validation invalid error builder. + */ + public ValidationInvalidErrorBuilder() { + getErrorCodeBuilder().withId(VALIDATION_INVALID); + getErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION); + getErrorCodeBuilder().withMessage(VALIDATION_INVALID_MSG); + } + + private String toString(Map> errors) { + StringBuffer sb = new StringBuffer(); + errors.entrySet().stream() + .forEach(entry -> singleErrorToString(sb, entry.getKey(), entry.getValue())); + return sb.toString(); + } + + private void singleErrorToString(StringBuffer sb, String fileName, List errors) { + sb.append(System.lineSeparator()); + sb.append(fileName); + sb.append(sb.append(": ")); + errors.stream().forEach( + error -> sb.append(error.getMessage()).append("[").append(error.getLevel()).append("], ")); + } + +} diff --git a/openecomp-be/backend/openecomp-sdc-validation-manager/src/main/java/org/openecomp/sdc/validation/impl/UploadValidationManagerImpl.java b/openecomp-be/backend/openecomp-sdc-validation-manager/src/main/java/org/openecomp/sdc/validation/impl/UploadValidationManagerImpl.java new file mode 100644 index 0000000000..ce0d911082 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-validation-manager/src/main/java/org/openecomp/sdc/validation/impl/UploadValidationManagerImpl.java @@ -0,0 +1,161 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.validation.impl; + +import org.apache.commons.collections4.CollectionUtils; +import org.apache.commons.collections4.MapUtils; +import org.openecomp.core.utilities.file.FileContentHandler; +import org.openecomp.core.utilities.file.FileUtils; +import org.openecomp.core.validation.api.ValidationManager; +import org.openecomp.core.validation.errors.Messages; +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; +import org.openecomp.sdc.common.utils.AsdcCommon; +import org.openecomp.sdc.heat.datatypes.structure.ValidationStructureList; +import org.openecomp.sdc.heat.services.tree.HeatTreeManager; +import org.openecomp.sdc.heat.services.tree.HeatTreeManagerUtil; +import org.openecomp.sdc.validation.UploadValidationManager; +import org.openecomp.sdc.validation.types.ValidationFileResponse; +import org.openecomp.sdc.validation.utils.ValidationManagerUtil; + +import java.io.ByteArrayInputStream; +import java.io.File; +import java.io.IOException; +import java.io.InputStream; +import java.util.ArrayList; +import java.util.List; +import java.util.Map; +import java.util.zip.ZipEntry; +import java.util.zip.ZipInputStream; + +public class UploadValidationManagerImpl implements UploadValidationManager { + + private static FileContentHandler getFileContentMapFromZip(byte[] uploadFileData) + throws IOException, CoreException { + ZipEntry zipEntry; + List folderList = new ArrayList<>(); + FileContentHandler mapFileContent = new FileContentHandler(); + try { + ZipInputStream inputZipStream; + + byte[] fileByteContent; + String currentEntryName; + inputZipStream = new ZipInputStream(new ByteArrayInputStream(uploadFileData)); + + while ((zipEntry = inputZipStream.getNextEntry()) != null) { + currentEntryName = zipEntry.getName(); + // else, get the file content (as byte array) and save it in a map. + fileByteContent = FileUtils.toByteArray(inputZipStream); + + int index = lastIndexFileSeparatorIndex(currentEntryName); + String currSubstringWithoutSeparator = + currentEntryName.substring(index + 1, currentEntryName.length()); + if (index != -1) { + if (currSubstringWithoutSeparator.length() > 0) { + mapFileContent.addFile(currentEntryName.substring(index + 1, currentEntryName.length()), + fileByteContent); + } else { + folderList.add(currentEntryName); + } + } else { + mapFileContent.addFile(currentEntryName, fileByteContent); + } + } + } catch (RuntimeException exception) { + throw new IOException(exception); + } + + if (CollectionUtils.isNotEmpty(folderList)) { + throw new CoreException((new ErrorCode.ErrorCodeBuilder()) + .withMessage(Messages.ZIP_SHOULD_NOT_CONTAIN_FOLDERS.getErrorMessage()) + .withId(Messages.ZIP_SHOULD_NOT_CONTAIN_FOLDERS.getErrorMessage()) + .withCategory(ErrorCategory.APPLICATION).build()); + + } + + return mapFileContent; + } + + private static int lastIndexFileSeparatorIndex(String filePath) { + int length = filePath.length() - 1; + + for (int i = length; i >= 0; i--) { + char currChar = filePath.charAt(i); + if (currChar == '/' || currChar == File.separatorChar || currChar == File.pathSeparatorChar) { + return i; + } + } + // if we've reached to the start of the string and didn't find file separator - return -1 + return -1; + } + + @Override + public ValidationFileResponse validateFile(String type, InputStream fileToValidate) + throws IOException { + + ValidationFileResponse validationFileResponse = new ValidationFileResponse(); + + HeatTreeManager tree; + ValidationStructureList validationStructureList = new ValidationStructureList(); + if (type.toLowerCase().equals("heat")) { + FileContentHandler content = getFileContent(fileToValidate); + if (!content.containsFile(AsdcCommon.MANIFEST_NAME)) { + throw new CoreException((new ErrorCode.ErrorCodeBuilder()) + .withMessage(Messages.MANIFEST_NOT_EXIST.getErrorMessage()) + .withId(Messages.ZIP_SHOULD_NOT_CONTAIN_FOLDERS.getErrorMessage()) + .withCategory(ErrorCategory.APPLICATION).build()); + } + Map> errors = + validateHeatUploadData(content); + tree = HeatTreeManagerUtil.initHeatTreeManager(content); + tree.createTree(); + if (MapUtils.isNotEmpty(errors)) { + + + tree.addErrors(errors); + validationStructureList.setImportStructure(tree.getTree()); + //validationFileResponse.setStatus(ValidationFileStatus.Failure); + } else { + //validationFileResponse.setStatus(ValidationFileStatus.Success); + } + } else { + throw new RuntimeException("invalid type:" + type); + } + validationFileResponse.setValidationData(validationStructureList); + return validationFileResponse; + } + + private Map> validateHeatUploadData( + FileContentHandler fileContentMap) + throws IOException { + ValidationManager validationManager = + ValidationManagerUtil.initValidationManager(fileContentMap); + return validationManager.validate(); + } + + private FileContentHandler getFileContent(InputStream is) throws IOException { + return getFileContentMapFromZip(FileUtils.toByteArray(is)); + + + } + +} diff --git a/openecomp-be/backend/openecomp-sdc-validation-manager/src/main/java/org/openecomp/sdc/validation/types/ValidationFileResponse.java b/openecomp-be/backend/openecomp-sdc-validation-manager/src/main/java/org/openecomp/sdc/validation/types/ValidationFileResponse.java new file mode 100644 index 0000000000..ff7f845252 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-validation-manager/src/main/java/org/openecomp/sdc/validation/types/ValidationFileResponse.java @@ -0,0 +1,36 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.validation.types; + + +import org.openecomp.sdc.heat.datatypes.structure.ValidationStructureList; + +public class ValidationFileResponse { + private ValidationStructureList validationData; + + public ValidationStructureList getValidationData() { + return validationData; + } + + public void setValidationData(ValidationStructureList validationData) { + this.validationData = validationData; + } +} diff --git a/openecomp-be/backend/openecomp-sdc-validation-manager/src/main/java/org/openecomp/sdc/validation/types/ValidationFileStatus.java b/openecomp-be/backend/openecomp-sdc-validation-manager/src/main/java/org/openecomp/sdc/validation/types/ValidationFileStatus.java new file mode 100644 index 0000000000..117eb3b3b7 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-validation-manager/src/main/java/org/openecomp/sdc/validation/types/ValidationFileStatus.java @@ -0,0 +1,26 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.validation.types; + +public enum ValidationFileStatus { + Success, + Failure; +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-license-manager/pom.xml b/openecomp-be/backend/openecomp-sdc-vendor-license-manager/pom.xml new file mode 100644 index 0000000000..a8c8e9a9f1 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-license-manager/pom.xml @@ -0,0 +1,103 @@ + + 4.0.0 + + + + backend + org.openecomp.sdc + 1.0.0-SNAPSHOT + + + openecomp-sdc-vendor-license-manager + openecomp-sdc-vendor-license-manager + + + + com.google.code.gson + gson + 2.3.1 + test + + + org.yaml + snakeyaml + 1.14 + test + + + org.openecomp.sdc + openecomp-sdc-vendor-license-core + ${project.version} + + + org.mockito + mockito-all + test + 1.10.19 + + + org.testng + testng + test + 6.8.5 + + + snakeyaml + org.yaml + + + + + junit + junit + test + RELEASE + + + javax.el + javax.el-api + ${javax.el-api.version} + + + org.glassfish.web + javax.el + 2.2.4 + + + org.codehaus.woodstox + woodstox-core-asl + 4.4.1 + + + org.openecomp.sdc + openecomp-sdc-vendor-software-product-manager + ${project.version} + + + com.fasterxml.jackson.dataformat + jackson-dataformat-xml + 2.7.4 + + + + commons-io + commons-io + ${commons.io.version} + + + + + + + + org.apache.maven.plugins + maven-surefire-plugin + 2.19.1 + + true + + + + + \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/main/java/org/openecomp/sdc/vendorlicense/VendorLicenseManager.java b/openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/main/java/org/openecomp/sdc/vendorlicense/VendorLicenseManager.java new file mode 100644 index 0000000000..dbe786a44b --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/main/java/org/openecomp/sdc/vendorlicense/VendorLicenseManager.java @@ -0,0 +1,115 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense; + +import org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity; +import org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupModel; +import org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementEntity; +import org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementModel; +import org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyGroupEntity; +import org.openecomp.sdc.vendorlicense.dao.types.VendorLicenseModelEntity; +import org.openecomp.sdc.vendorlicense.types.VersionedVendorLicenseModel; +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.util.Collection; +import java.util.Set; + +public interface VendorLicenseManager { + + void checkout(String vendorLicenseModelId, String user); + + void undoCheckout(String vendorLicenseModelId, String user); + + void checkin(String vendorLicenseModelId, String user); + + void submit(String vendorLicenseModelId, String user); + + Collection listVendorLicenseModels(String versionFilter, + String user); + + VendorLicenseModelEntity createVendorLicenseModel(VendorLicenseModelEntity licenseModel, + String user); + + void updateVendorLicenseModel(VendorLicenseModelEntity licenseModel, String user); + + VersionedVendorLicenseModel getVendorLicenseModel(String vlmId, Version version, String user); + + void deleteVendorLicenseModel(String vlmId, String user); + + + Collection listLicenseAgreements(String vlmId, Version version, + String user); + + LicenseAgreementEntity createLicenseAgreement(LicenseAgreementEntity licenseAgreement, + String user); + + void updateLicenseAgreement(LicenseAgreementEntity licenseAgreement, + Set addedFeatureGroupIds, Set removedFeatureGroupIds, + String user); + + LicenseAgreementModel getLicenseAgreementModel(String vlmId, Version version, + String licenseAgreementId, String user); + + void deleteLicenseAgreement(String vlmId, String licenseAgreementId, String user); + + + Collection listFeatureGroups( + String vlmId, Version version, String user); + + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity createFeatureGroup( + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity fg, String user); + + void updateFeatureGroup(org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity featureGroup, + Set addedLicenseKeyGroups, Set removedLicenseKeyGroups, + Set addedEntitlementPools, Set removedEntitlementPools, + String user); + + FeatureGroupModel getFeatureGroupModel( + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity featureGroup, String user); + + void deleteFeatureGroup(org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity featureGroup, + String user); + + + Collection listEntitlementPools(String vlmId, Version version, + String user); + + EntitlementPoolEntity createEntitlementPool(EntitlementPoolEntity entitlementPool, String user); + + void updateEntitlementPool(EntitlementPoolEntity entitlementPool, String user); + + EntitlementPoolEntity getEntitlementPool(EntitlementPoolEntity entitlementPool, String user); + + void deleteEntitlementPool(EntitlementPoolEntity entitlementPool, String user); + + + Collection listLicenseKeyGroups(String vlmId, Version version, + String user); + + LicenseKeyGroupEntity createLicenseKeyGroup(LicenseKeyGroupEntity licenseKeyGroup, String user); + + void updateLicenseKeyGroup(LicenseKeyGroupEntity licenseKeyGroup, String user); + + LicenseKeyGroupEntity getLicenseKeyGroup(LicenseKeyGroupEntity licenseKeyGroup, String user); + + void deleteLicenseKeyGroup(LicenseKeyGroupEntity licenseKeyGroup, String user); + +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/main/java/org/openecomp/sdc/vendorlicense/impl/VendorLicenseManagerImpl.java b/openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/main/java/org/openecomp/sdc/vendorlicense/impl/VendorLicenseManagerImpl.java new file mode 100644 index 0000000000..b0b088c774 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/main/java/org/openecomp/sdc/vendorlicense/impl/VendorLicenseManagerImpl.java @@ -0,0 +1,558 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.impl; + +import static org.openecomp.sdc.vendorlicense.VendorLicenseConstants + .VENDOR_LICENSE_MODEL_VERSIONABLE_TYPE; + +import org.openecomp.core.util.UniqueValueUtil; +import org.openecomp.sdc.vendorlicense.VendorLicenseConstants; +import org.openecomp.sdc.vendorlicense.VendorLicenseManager; +import org.openecomp.sdc.vendorlicense.dao.EntitlementPoolDao; +import org.openecomp.sdc.vendorlicense.dao.EntitlementPoolDaoFactory; +import org.openecomp.sdc.vendorlicense.dao.FeatureGroupDao; +import org.openecomp.sdc.vendorlicense.dao.FeatureGroupDaoFactory; +import org.openecomp.sdc.vendorlicense.dao.LicenseAgreementDaoFactory; +import org.openecomp.sdc.vendorlicense.dao.LicenseKeyGroupDao; +import org.openecomp.sdc.vendorlicense.dao.LicenseKeyGroupDaoFactory; +import org.openecomp.sdc.vendorlicense.dao.VendorLicenseModelDao; +import org.openecomp.sdc.vendorlicense.dao.VendorLicenseModelDaoFactory; +import org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity; +import org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupModel; +import org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementEntity; +import org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementModel; +import org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyGroupEntity; +import org.openecomp.sdc.vendorlicense.dao.types.VendorLicenseModelEntity; +import org.openecomp.sdc.vendorlicense.facade.VendorLicenseFacade; +import org.openecomp.sdc.vendorlicense.facade.VendorLicenseFacadeFactory; +import org.openecomp.sdc.vendorlicense.types.VersionedVendorLicenseModel; +import org.openecomp.sdc.versioning.VersioningManager; +import org.openecomp.sdc.versioning.VersioningUtil; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.dao.types.VersionStatus; +import org.openecomp.sdc.versioning.types.VersionInfo; +import org.openecomp.sdc.versioning.types.VersionableEntityAction; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.Collections; +import java.util.Comparator; +import java.util.List; +import java.util.Map; +import java.util.Set; + +public class VendorLicenseManagerImpl implements VendorLicenseManager { + + private static final VersioningManager versioningManager = + org.openecomp.sdc.versioning.VersioningManagerFactory.getInstance().createInterface(); + private static final VendorLicenseFacade vendorLicenseFacade = + VendorLicenseFacadeFactory.getInstance().createInterface(); + + private static final VendorLicenseModelDao + vendorLicenseModelDao = VendorLicenseModelDaoFactory.getInstance().createInterface(); + private static final org.openecomp.sdc.vendorlicense.dao.LicenseAgreementDao + licenseAgreementDao = LicenseAgreementDaoFactory.getInstance().createInterface(); + private static final FeatureGroupDao featureGroupDao = + FeatureGroupDaoFactory.getInstance().createInterface(); + private static final EntitlementPoolDao + entitlementPoolDao = EntitlementPoolDaoFactory.getInstance().createInterface(); + private static final LicenseKeyGroupDao + licenseKeyGroupDao = LicenseKeyGroupDaoFactory.getInstance().createInterface(); + + private static void sortVlmListByModificationTimeDescOrder( + List vendorLicenseModels) { + Collections.sort(vendorLicenseModels, new Comparator() { + @Override + public int compare(VersionedVendorLicenseModel o1, VersionedVendorLicenseModel o2) { + return o2.getVendorLicenseModel().getWritetimeMicroSeconds() + .compareTo(o1.getVendorLicenseModel().getWritetimeMicroSeconds()); + } + }); + } + + @Override + public void checkout(String vendorLicenseModelId, String user) { + Version newVersion = versioningManager + .checkout(VENDOR_LICENSE_MODEL_VERSIONABLE_TYPE, vendorLicenseModelId, user); + vendorLicenseFacade.updateVlmLastModificationTime(vendorLicenseModelId, newVersion); + } + + @Override + public void undoCheckout(String vendorLicenseModelId, String user) { + Version newVersion = versioningManager + .undoCheckout(VENDOR_LICENSE_MODEL_VERSIONABLE_TYPE, vendorLicenseModelId, user); + vendorLicenseFacade.updateVlmLastModificationTime(vendorLicenseModelId, newVersion); + } + + @Override + public void checkin(String vendorLicenseModelId, String user) { + vendorLicenseFacade.checkin(vendorLicenseModelId, user); + } + + @Override + public void submit(String vendorLicenseModelId, String user) { + vendorLicenseFacade.submit(vendorLicenseModelId, user); + } + + @Override + public Collection listVendorLicenseModels(String versionFilter, + String user) { + Map idToVersionsInfo = versioningManager + .listEntitiesVersionInfo(VENDOR_LICENSE_MODEL_VERSIONABLE_TYPE, user, + VersionableEntityAction.Read); + + List vendorLicenseModels = new ArrayList<>(); + for (Map.Entry entry : idToVersionsInfo.entrySet()) { + VersionInfo versionInfo = entry.getValue(); + if (versionFilter != null && versionFilter.equals(VersionStatus.Final.name())) { + if (versionInfo.getLatestFinalVersion() == null) { + continue; + } + versionInfo.setActiveVersion(versionInfo.getLatestFinalVersion()); + versionInfo.setStatus(VersionStatus.Final); + versionInfo.setLockingUser(null); + } + + VendorLicenseModelEntity + vlm = vendorLicenseModelDao + .get(new VendorLicenseModelEntity(entry.getKey(), versionInfo.getActiveVersion())); + if (vlm != null) { + VersionedVendorLicenseModel versionedVlm = new VersionedVendorLicenseModel(); + versionedVlm.setVendorLicenseModel(vlm); + versionedVlm.setVersionInfo(versionInfo); + vendorLicenseModels.add(versionedVlm); + } + } + + sortVlmListByModificationTimeDescOrder(vendorLicenseModels); + + return vendorLicenseModels; + } + + @Override + public VendorLicenseModelEntity createVendorLicenseModel( + VendorLicenseModelEntity vendorLicenseModelEntity, String user) { + return vendorLicenseFacade.createVendorLicenseModel(vendorLicenseModelEntity, user); + } + + @Override + public void updateVendorLicenseModel(VendorLicenseModelEntity vendorLicenseModelEntity, + String user) { + Version activeVersion = + getVersionInfo(vendorLicenseModelEntity.getId(), VersionableEntityAction.Write, user) + .getActiveVersion(); + vendorLicenseModelEntity.setVersion(activeVersion); + + String existingVendorName = vendorLicenseModelDao.get(vendorLicenseModelEntity).getVendorName(); + UniqueValueUtil + .updateUniqueValue(VendorLicenseConstants.UniqueValues.VENDOR_NAME, existingVendorName, + vendorLicenseModelEntity.getVendorName()); + vendorLicenseModelDao.update(vendorLicenseModelEntity); + + vendorLicenseFacade + .updateVlmLastModificationTime(vendorLicenseModelEntity.getId(), activeVersion); + } + + @Override + public VersionedVendorLicenseModel getVendorLicenseModel(String vlmId, Version version, + String user) { + return vendorLicenseFacade.getVendorLicenseModel(vlmId, version, user); + } + + @Override + public void deleteVendorLicenseModel(String vlmId, String user) { + throw new UnsupportedOperationException("Unsupported operation for 1607 release."); + + /* Version activeVersion = getVersionInfo(vlmId, VersionableEntityAction.Write, user) + .getActiveVersion(); + + vendorLicenseModelDao.delete(new VendorLicenseModelEntity(vlmId, activeVersion)); + licenseAgreementDao.deleteAll(new LicenseAgreementEntity(vlmId, activeVersion, null)); + featureGroupDao.deleteAll(new FeatureGroupEntity(vlmId, activeVersion, null)); + licenseKeyGroupDao.deleteAll(new LicenseKeyGroupEntity(vlmId, activeVersion, null)); + entitlementPoolDao.deleteAll(new EntitlementPoolEntity(vlmId, activeVersion, null));*/ + } + + @Override + public Collection listLicenseAgreements(String vlmId, Version version, + String user) { + return licenseAgreementDao.list(new LicenseAgreementEntity(vlmId, VersioningUtil + .resolveVersion(version, getVersionInfo(vlmId, VersionableEntityAction.Read, user)), null)); + } + + @Override + public LicenseAgreementEntity createLicenseAgreement(LicenseAgreementEntity licenseAgreement, + String user) { + return vendorLicenseFacade.createLicenseAgreement(licenseAgreement, user); + } + + @Override + public void updateLicenseAgreement(LicenseAgreementEntity licenseAgreement, + Set addedFeatureGroupIds, + Set removedFeatureGroupIds, String user) { + Version activeVersion = + getVersionInfo(licenseAgreement.getVendorLicenseModelId(), VersionableEntityAction.Write, + user).getActiveVersion(); + licenseAgreement.setVersion(activeVersion); + LicenseAgreementEntity retrieved = licenseAgreementDao.get(licenseAgreement); + VersioningUtil + .validateEntityExistence(retrieved, licenseAgreement, VendorLicenseModelEntity.ENTITY_TYPE); + VersioningUtil.validateContainedEntitiesExistence( + new org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity().getEntityType(), + removedFeatureGroupIds, retrieved, retrieved.getFeatureGroupIds()); + VersioningUtil.validateEntitiesExistence(addedFeatureGroupIds, + new org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity( + licenseAgreement.getVendorLicenseModelId(), activeVersion, null), + featureGroupDao, VendorLicenseModelEntity.ENTITY_TYPE); + + UniqueValueUtil.updateUniqueValue(VendorLicenseConstants.UniqueValues.LICENSE_AGREEMENT_NAME, + retrieved.getName(), licenseAgreement.getName(), licenseAgreement.getVendorLicenseModelId(), + licenseAgreement.getVersion().toString()); + licenseAgreementDao.updateColumnsAndDeltaFeatureGroupIds(licenseAgreement, addedFeatureGroupIds, + removedFeatureGroupIds); + + addFeatureGroupsToLicenseAgreementRef(addedFeatureGroupIds, licenseAgreement); + removeFeatureGroupsToLicenseAgreementRef(removedFeatureGroupIds, licenseAgreement); + + vendorLicenseFacade + .updateVlmLastModificationTime(licenseAgreement.getVendorLicenseModelId(), activeVersion); + } + + @Override + public LicenseAgreementModel getLicenseAgreementModel(String vlmId, Version version, + String licenseAgreementId, String user) { + return vendorLicenseFacade.getLicenseAgreementModel(vlmId, version, licenseAgreementId, user); + } + + @Override + public void deleteLicenseAgreement(String vlmId, String licenseAgreementId, String user) { + Version activeVersion = + getVersionInfo(vlmId, VersionableEntityAction.Write, user).getActiveVersion(); + LicenseAgreementEntity input = + new LicenseAgreementEntity(vlmId, activeVersion, licenseAgreementId); + LicenseAgreementEntity retrieved = licenseAgreementDao.get(input); + VersioningUtil.validateEntityExistence(retrieved, input, VendorLicenseModelEntity.ENTITY_TYPE); + + removeFeatureGroupsToLicenseAgreementRef(retrieved.getFeatureGroupIds(), retrieved); + + licenseAgreementDao.delete(input); + UniqueValueUtil.deleteUniqueValue(VendorLicenseConstants.UniqueValues.LICENSE_AGREEMENT_NAME, + retrieved.getVendorLicenseModelId(), retrieved.getVersion().toString(), + retrieved.getName()); + + vendorLicenseFacade + .updateVlmLastModificationTime(input.getVendorLicenseModelId(), input.getVersion()); + } + + @Override + public Collection listFeatureGroups( + String vlmId, Version version, + String user) { + return featureGroupDao + .list(new org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity(vlmId, VersioningUtil + .resolveVersion(version, getVersionInfo(vlmId, VersionableEntityAction.Read, user)), + null)); + } + + @Override + public org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity createFeatureGroup( + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity featureGroup, String user) { + return vendorLicenseFacade.createFeatureGroup(featureGroup, user); + } + + @Override + public void updateFeatureGroup( + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity featureGroup, + Set addedLicenseKeyGroups, + Set removedLicenseKeyGroups, + Set addedEntitlementPools, + Set removedEntitlementPools, + String user) { + Version activeVersion = + getVersionInfo(featureGroup.getVendorLicenseModelId(), VersionableEntityAction.Write, user) + .getActiveVersion(); + featureGroup.setVersion(activeVersion); + + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity retrieved = + featureGroupDao.get(featureGroup); + VersioningUtil + .validateEntityExistence(retrieved, featureGroup, VendorLicenseModelEntity.ENTITY_TYPE); + + VersioningUtil.validateContainedEntitiesExistence(new LicenseKeyGroupEntity().getEntityType(), + removedLicenseKeyGroups, retrieved, retrieved.getLicenseKeyGroupIds()); + VersioningUtil.validateContainedEntitiesExistence(new EntitlementPoolEntity().getEntityType(), + removedEntitlementPools, retrieved, retrieved.getEntitlementPoolIds()); + + VersioningUtil.validateEntitiesExistence(addedLicenseKeyGroups, + new LicenseKeyGroupEntity(featureGroup.getVendorLicenseModelId(), activeVersion, null), + licenseKeyGroupDao, VendorLicenseModelEntity.ENTITY_TYPE); + VersioningUtil.validateEntitiesExistence(addedEntitlementPools, + new EntitlementPoolEntity(featureGroup.getVendorLicenseModelId(), activeVersion, null), + entitlementPoolDao, VendorLicenseModelEntity.ENTITY_TYPE); + UniqueValueUtil.updateUniqueValue(VendorLicenseConstants.UniqueValues.FEATURE_GROUP_NAME, + retrieved.getName(), featureGroup.getName(), featureGroup.getVendorLicenseModelId(), + featureGroup.getVersion().toString()); + + addLicenseKeyGroupsToFeatureGroupsRef(addedLicenseKeyGroups, featureGroup); + removeLicenseKeyGroupsToFeatureGroupsRef(removedLicenseKeyGroups, featureGroup); + addEntitlementPoolsToFeatureGroupsRef(addedEntitlementPools, featureGroup); + removeEntitlementPoolsToFeatureGroupsRef(removedEntitlementPools, featureGroup); + + featureGroupDao.updateFeatureGroup(featureGroup, addedEntitlementPools, removedEntitlementPools, + addedLicenseKeyGroups, removedLicenseKeyGroups); + + vendorLicenseFacade + .updateVlmLastModificationTime(featureGroup.getVendorLicenseModelId(), activeVersion); + } + + @Override + public FeatureGroupModel getFeatureGroupModel( + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity featureGroup, String user) { + return vendorLicenseFacade.getFeatureGroupModel(featureGroup, user); + } + + @Override + public void deleteFeatureGroup( + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity featureGroup, String user) { + Version activeVersion = + getVersionInfo(featureGroup.getVendorLicenseModelId(), VersionableEntityAction.Write, user) + .getActiveVersion(); + featureGroup.setVersion(activeVersion); + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity retrieved = + featureGroupDao.get(featureGroup); + VersioningUtil + .validateEntityExistence(retrieved, featureGroup, VendorLicenseModelEntity.ENTITY_TYPE); + + removeLicenseKeyGroupsToFeatureGroupsRef(retrieved.getLicenseKeyGroupIds(), featureGroup); + removeEntitlementPoolsToFeatureGroupsRef(retrieved.getEntitlementPoolIds(), featureGroup); + + for (String licenceAgreementId : retrieved.getReferencingLicenseAgreements()) { + licenseAgreementDao.removeFeatureGroup( + new LicenseAgreementEntity(featureGroup.getVendorLicenseModelId(), activeVersion, + licenceAgreementId), featureGroup.getId()); + } + + featureGroupDao.delete(featureGroup); + UniqueValueUtil.deleteUniqueValue(VendorLicenseConstants.UniqueValues.FEATURE_GROUP_NAME, + retrieved.getVendorLicenseModelId(), retrieved.getVersion().toString(), + retrieved.getName()); + + vendorLicenseFacade.updateVlmLastModificationTime(featureGroup.getVendorLicenseModelId(), + featureGroup.getVersion()); + } + + @Override + public Collection listEntitlementPools(String vlmId, Version version, + String user) { + return vendorLicenseFacade.listEntitlementPools(vlmId, version, user); + } + + @Override + public EntitlementPoolEntity createEntitlementPool(EntitlementPoolEntity entitlementPool, + String user) { + return vendorLicenseFacade.createEntitlementPool(entitlementPool, user); + } + + @Override + public void updateEntitlementPool(EntitlementPoolEntity entitlementPool, String user) { + Version activeVersion = + getVersionInfo(entitlementPool.getVendorLicenseModelId(), VersionableEntityAction.Write, + user).getActiveVersion(); + vendorLicenseFacade + .updateVlmLastModificationTime(entitlementPool.getVendorLicenseModelId(), activeVersion); + vendorLicenseFacade.updateEntitlementPool(entitlementPool, user); + } + + @Override + public EntitlementPoolEntity getEntitlementPool(EntitlementPoolEntity entitlementPool, + String user) { + entitlementPool.setVersion(VersioningUtil.resolveVersion(entitlementPool.getVersion(), + getVersionInfo(entitlementPool.getVendorLicenseModelId(), VersionableEntityAction.Read, + user))); + + EntitlementPoolEntity retrieved = entitlementPoolDao.get(entitlementPool); + VersioningUtil + .validateEntityExistence(retrieved, entitlementPool, VendorLicenseModelEntity.ENTITY_TYPE); + return retrieved; + } + + @Override + public void deleteEntitlementPool(EntitlementPoolEntity entitlementPool, String user) { + Version activeVersion = + getVersionInfo(entitlementPool.getVendorLicenseModelId(), VersionableEntityAction.Write, + user).getActiveVersion(); + entitlementPool.setVersion(activeVersion); + + EntitlementPoolEntity retrieved = entitlementPoolDao.get(entitlementPool); + VersioningUtil + .validateEntityExistence(retrieved, entitlementPool, VendorLicenseModelEntity.ENTITY_TYPE); + + for (String referencingFeatureGroupId : retrieved.getReferencingFeatureGroups()) { + featureGroupDao.removeEntitlementPool( + new org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity( + entitlementPool.getVendorLicenseModelId(), activeVersion, + referencingFeatureGroupId), entitlementPool.getId()); + } + + entitlementPoolDao.delete(entitlementPool); + UniqueValueUtil.deleteUniqueValue(VendorLicenseConstants.UniqueValues.ENTITLEMENT_POOL_NAME, + retrieved.getVendorLicenseModelId(), retrieved.getVersion().toString(), + retrieved.getName()); + + vendorLicenseFacade.updateVlmLastModificationTime(entitlementPool.getVendorLicenseModelId(), + entitlementPool.getVersion()); + } + + @Override + public Collection listLicenseKeyGroups(String vlmId, Version version, + String user) { + return vendorLicenseFacade.listLicenseKeyGroups(vlmId, version, user); + } + + @Override + public LicenseKeyGroupEntity createLicenseKeyGroup(LicenseKeyGroupEntity licenseKeyGroup, + String user) { + return vendorLicenseFacade.createLicenseKeyGroup(licenseKeyGroup, user); + } + + @Override + public void updateLicenseKeyGroup(LicenseKeyGroupEntity licenseKeyGroup, String user) { + Version activeVersion = + getVersionInfo(licenseKeyGroup.getVendorLicenseModelId(), VersionableEntityAction.Write, + user).getActiveVersion(); + vendorLicenseFacade + .updateVlmLastModificationTime(licenseKeyGroup.getVendorLicenseModelId(), activeVersion); + + vendorLicenseFacade.updateLicenseKeyGroup(licenseKeyGroup, user); + } + + @Override + public LicenseKeyGroupEntity getLicenseKeyGroup(LicenseKeyGroupEntity licenseKeyGroup, + String user) { + licenseKeyGroup.setVersion(VersioningUtil.resolveVersion(licenseKeyGroup.getVersion(), + getVersionInfo(licenseKeyGroup.getVendorLicenseModelId(), VersionableEntityAction.Read, + user))); + + LicenseKeyGroupEntity retrieved = licenseKeyGroupDao.get(licenseKeyGroup); + VersioningUtil + .validateEntityExistence(retrieved, licenseKeyGroup, VendorLicenseModelEntity.ENTITY_TYPE); + return retrieved; + } + + @Override + public void deleteLicenseKeyGroup(LicenseKeyGroupEntity licenseKeyGroup, String user) { + Version activeVersion = + getVersionInfo(licenseKeyGroup.getVendorLicenseModelId(), VersionableEntityAction.Write, + user).getActiveVersion(); + licenseKeyGroup.setVersion(activeVersion); + + LicenseKeyGroupEntity retrieved = licenseKeyGroupDao.get(licenseKeyGroup); + VersioningUtil + .validateEntityExistence(retrieved, licenseKeyGroup, VendorLicenseModelEntity.ENTITY_TYPE); + + licenseKeyGroupDao.delete(licenseKeyGroup); + for (String referencingFeatureGroupId : retrieved.getReferencingFeatureGroups()) { + featureGroupDao.removeLicenseKeyGroup( + new org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity( + licenseKeyGroup.getVendorLicenseModelId(), activeVersion, + referencingFeatureGroupId), licenseKeyGroup.getId()); + } + UniqueValueUtil.deleteUniqueValue(VendorLicenseConstants.UniqueValues.LICENSE_KEY_GROUP_NAME, + retrieved.getVendorLicenseModelId(), retrieved.getVersion().toString(), + retrieved.getName()); + + vendorLicenseFacade.updateVlmLastModificationTime(licenseKeyGroup.getVendorLicenseModelId(), + licenseKeyGroup.getVersion()); + } + + private void addFeatureGroupsToLicenseAgreementRef(Set featureGroupIds, + LicenseAgreementEntity licenseAgreement) { + if (featureGroupIds != null) { + for (String featureGroupId : featureGroupIds) { + featureGroupDao.addReferencingLicenseAgreement( + new org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity( + licenseAgreement.getVendorLicenseModelId(), + licenseAgreement.getVersion(), featureGroupId), licenseAgreement.getId()); + } + } + } + + private void removeFeatureGroupsToLicenseAgreementRef(Set featureGroupIds, + LicenseAgreementEntity licenseAgreement) { + if (featureGroupIds != null) { + for (String featureGroupId : featureGroupIds) { + featureGroupDao.removeReferencingLicenseAgreement( + new org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity( + licenseAgreement.getVendorLicenseModelId(), + licenseAgreement.getVersion(), featureGroupId), licenseAgreement.getId()); + } + } + } + + private void addLicenseKeyGroupsToFeatureGroupsRef(Set licenseKeyGroupIds, + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity featureGroup) { + if (licenseKeyGroupIds != null) { + for (String licenseKeyGroupId : licenseKeyGroupIds) { + licenseKeyGroupDao.addReferencingFeatureGroup( + new LicenseKeyGroupEntity(featureGroup.getVendorLicenseModelId(), + featureGroup.getVersion(), licenseKeyGroupId), featureGroup.getId()); + } + } + } + + private void removeLicenseKeyGroupsToFeatureGroupsRef(Set licenseKeyGroupIds, + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity featureGroup) { + if (licenseKeyGroupIds != null) { + for (String licenseKeyGroupId : licenseKeyGroupIds) { + licenseKeyGroupDao.removeReferencingFeatureGroup( + new LicenseKeyGroupEntity(featureGroup.getVendorLicenseModelId(), + featureGroup.getVersion(), licenseKeyGroupId), featureGroup.getId()); + } + } + } + + private void addEntitlementPoolsToFeatureGroupsRef(Set entitlementPoolIds, + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity featureGroup) { + if (entitlementPoolIds != null) { + for (String entitlementPoolId : entitlementPoolIds) { + entitlementPoolDao.addReferencingFeatureGroup( + new EntitlementPoolEntity(featureGroup.getVendorLicenseModelId(), + featureGroup.getVersion(), entitlementPoolId), featureGroup.getId()); + } + } + } + + private void removeEntitlementPoolsToFeatureGroupsRef(Set entitlementPoolIds, + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity featureGroup) { + if (entitlementPoolIds != null) { + for (String entitlementPoolId : entitlementPoolIds) { + entitlementPoolDao.removeReferencingFeatureGroup( + new EntitlementPoolEntity(featureGroup.getVendorLicenseModelId(), + featureGroup.getVersion(), entitlementPoolId), featureGroup.getId()); + } + } + } + + private VersionInfo getVersionInfo(String vendorLicenseModelId, VersionableEntityAction action, + String user) { + return vendorLicenseFacade.getVersionInfo(vendorLicenseModelId, action, user); + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/test/java/org/openecomp/sdc/vendorlicense/ArtifactTestUtils.java b/openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/test/java/org/openecomp/sdc/vendorlicense/ArtifactTestUtils.java new file mode 100644 index 0000000000..60fe06a23e --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/test/java/org/openecomp/sdc/vendorlicense/ArtifactTestUtils.java @@ -0,0 +1,252 @@ +package org.openecomp.sdc.vendorlicense; + +import org.openecomp.sdc.vendorlicense.facade.VendorLicenseFacade; +import org.openecomp.sdc.vendorlicense.facade.VendorLicenseFacadeFactory; +import org.openecomp.sdc.vendorlicense.impl.VendorLicenseManagerImpl; +import org.openecomp.sdc.vendorlicense.licenseartifacts.VendorLicenseArtifactsService; +import org.openecomp.sdc.vendorsoftwareproduct.VendorSoftwareProductManager; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.VspDetails; +import org.openecomp.sdc.vendorsoftwareproduct.impl.VendorSoftwareProductManagerImpl; +import org.openecomp.sdc.versioning.VersioningManager; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.types.VersionInfo; +import org.openecomp.sdc.versioning.types.VersionableEntityAction; +import org.openecomp.core.utilities.CommonMethods; +import org.testng.annotations.BeforeMethod; + +import java.util.ArrayList; +import java.util.HashSet; +import java.util.List; +import java.util.Set; + +import static org.openecomp.sdc.vendorlicense.VendorLicenseConstants.VENDOR_LICENSE_MODEL_VERSIONABLE_TYPE; + +public class ArtifactTestUtils { + + protected static final Version VERSION01 = new Version(0, 1); + protected static final String USER1 = "baseTest_TestUser1"; + protected static VendorLicenseManager vendorLicenseManager = new VendorLicenseManagerImpl(); + protected static VendorSoftwareProductManager vendorSoftwareProductManager = new VendorSoftwareProductManagerImpl(); + protected static VendorLicenseFacade vendorLicenseFacade = VendorLicenseFacadeFactory.getInstance().createInterface(); + private static final VersioningManager versioningManager = org.openecomp.sdc.versioning.VersioningManagerFactory + .getInstance().createInterface(); + protected static VendorLicenseArtifactsService vendorLicenseArtifactsService = VendorLicenseArtifactServiceFactory + .getInstance().createInterface(); + + protected static Version currVersion; + + protected String vlm1Id; + protected String vlm2Id; + + protected String ep11Id; + protected String ep12Id; + protected String lkg11Id; + protected String lkg12Id; + protected String lkg13Id; + protected String fg11Id; + protected String fg12Id; + protected String la11Id; + + protected String ep21Id; + protected String ep22Id; + protected String lkg21Id; + protected String lkg22Id; + protected String fg21Id; + protected String fg22Id; + protected String la21Id; + protected String la22Id; + + protected org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity fg11; + protected org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity fg12; + protected org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity ep11; + protected org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity ep12; + protected org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyGroupEntity lkg11; + protected org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyGroupEntity lkg12; + protected org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyGroupEntity lkg13; + + protected org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity fg21; + protected org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity fg22; + protected org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity ep21; + protected org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity ep22; + protected org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyGroupEntity lkg21; + protected org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyGroupEntity lkg22; + + protected VspDetails vspDetails; + protected VspDetails vsp2; + + + @BeforeMethod + public void setUp() { + vlm1Id = vendorLicenseFacade.createVendorLicenseModel(VendorLicenseModelTest.createVendorLicenseModel("vlm1 name" + CommonMethods.nextUuId(), "vlm1Id desc", "icon1"), USER1).getId(); + vlm2Id = vendorLicenseFacade.createVendorLicenseModel(VendorLicenseModelTest.createVendorLicenseModel("vlm2 name" + CommonMethods.nextUuId(), "vlm2Id desc", "icon2"), USER1).getId(); + + + Set opScopeChoices = new HashSet<>(); + opScopeChoices.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.Other); + opScopeChoices.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.Data_Center); + opScopeChoices.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.Network_Wide); + + ep11 = EntitlementPoolTest.createEntitlementPool(vlm1Id, VERSION01, "EP1_" + CommonMethods.nextUuId(), "EP1 dec", 80, org.openecomp.sdc.vendorlicense.dao.types.ThresholdUnit.Absolute, org.openecomp.sdc.vendorlicense.dao.types.EntitlementMetric.Core, null, "inc1", org.openecomp.sdc.vendorlicense.dao.types.AggregationFunction.Other, "agg func1", opScopeChoices, null, org.openecomp.sdc.vendorlicense.dao.types.EntitlementTime.Hour, null, "sku1"); + ep11Id = vendorLicenseManager.createEntitlementPool(ep11, USER1).getId(); + ep12 = EntitlementPoolTest.createEntitlementPool(vlm1Id, VERSION01, "EP2_" + CommonMethods.nextUuId(), "EP2 dec", 70, org.openecomp.sdc.vendorlicense.dao.types.ThresholdUnit.Absolute, org.openecomp.sdc.vendorlicense.dao.types.EntitlementMetric.Other, "e metric2", "inc2", org.openecomp.sdc.vendorlicense.dao.types.AggregationFunction.Average, null, opScopeChoices, "op scope2", org.openecomp.sdc.vendorlicense.dao.types.EntitlementTime.Other, "time2", "sku2"); + ep12Id = vendorLicenseManager.createEntitlementPool(ep12, USER1).getId(); + + Set opScopeChoicesLKG = new HashSet<>(); + opScopeChoicesLKG.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.CPU); + opScopeChoicesLKG.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.VM); + opScopeChoicesLKG.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.Availability_Zone); + opScopeChoicesLKG.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.Data_Center); + + lkg11 = LicenseKeyGroupTest.createLicenseKeyGroup(vlm1Id, VERSION01, "LKG1", "LKG1 dec", org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyType.One_Time, new org.openecomp.sdc.vendorlicense.dao.types.MultiChoiceOrOther<>(opScopeChoicesLKG, null)); + lkg11Id = vendorLicenseManager.createLicenseKeyGroup(lkg11, USER1).getId(); + lkg11.setId(lkg11Id); + + lkg12 = LicenseKeyGroupTest.createLicenseKeyGroup(vlm1Id, VERSION01, "LKG2", "LKG2 dec", org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyType.Unique, new org.openecomp.sdc.vendorlicense.dao.types.MultiChoiceOrOther<>(opScopeChoicesLKG, null)); + lkg12Id = vendorLicenseManager.createLicenseKeyGroup(lkg12, USER1).getId(); + lkg12.setId(lkg11Id); + + lkg13 = LicenseKeyGroupTest.createLicenseKeyGroup(vlm1Id, VERSION01, "LKG3", "LKG3 dec", org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyType.Universal, new org.openecomp.sdc.vendorlicense.dao.types.MultiChoiceOrOther<>(opScopeChoicesLKG, null)); + lkg13Id = vendorLicenseManager.createLicenseKeyGroup(lkg13, USER1).getId(); + lkg13.setId(lkg13Id); + + fg11 = LicenseAgreementTest.createFeatureGroup(vlm1Id, VERSION01, "fg11", "FG1", "FG1 desc", CommonMethods.toSingleElementSet(ep11Id), CommonMethods.toSingleElementSet(lkg11Id)); + fg11Id = vendorLicenseManager.createFeatureGroup(fg11, USER1).getId(); + + fg12 = LicenseAgreementTest.createFeatureGroup(vlm1Id, VERSION01, "fg2", "FG2", "FG2 desc", CommonMethods.toSingleElementSet(ep12Id), CommonMethods.toSingleElementSet(lkg12Id)); + fg12Id = vendorLicenseManager.createFeatureGroup(fg12, USER1).getId(); + + + String requirementsAndConstrains1 = "Requirements And Constraints1"; + org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementEntity + la1 = LicenseAgreementTest.createLicenseAgreement(vlm1Id, VERSION01, null, "LA1", "LA1 desc", requirementsAndConstrains1, new org.openecomp.sdc.vendorlicense.dao.types.ChoiceOrOther<>( + org.openecomp.sdc.vendorlicense.dao.types.LicenseTerm.Unlimited, null), fg11Id); + la11Id = vendorLicenseManager.createLicenseAgreement(la1, USER1).getId(); + + List fgs = new ArrayList<>(); + fgs.add(fg11Id); + createTwoFinalVersionsForVLM(vlm1Id); + VersionInfo versionInfo = vendorLicenseFacade.getVersionInfo(vlm1Id, VersionableEntityAction.Read, ""); + vspDetails = createVspDetails(null, null, "VSP1_" + CommonMethods.nextUuId(), "Test-vsp", "vendorName", vlm1Id, "icon", "category", "subCategory", la11Id, fgs); + + List finalVersions = versionInfo.getFinalVersions(); + Version finalVersion = finalVersions.get(1); + + vspDetails.setVlmVersion(finalVersion); + + vspDetails = vendorSoftwareProductManager.createNewVsp(vspDetails, USER1); + + } + + private void createTwoFinalVersionsForVLM(String vlm1Id) { + versioningManager.checkin(VENDOR_LICENSE_MODEL_VERSIONABLE_TYPE, vlm1Id, USER1, "desc1"); + versioningManager.checkout(VENDOR_LICENSE_MODEL_VERSIONABLE_TYPE, vlm1Id, USER1); + versioningManager.checkin(VENDOR_LICENSE_MODEL_VERSIONABLE_TYPE, vlm1Id, USER1, "desc1"); + vendorLicenseFacade.submit(vlm1Id, USER1); + versioningManager.checkout(VENDOR_LICENSE_MODEL_VERSIONABLE_TYPE, vlm1Id, USER1); + versioningManager.checkin(VENDOR_LICENSE_MODEL_VERSIONABLE_TYPE, vlm1Id, USER1, "desc2"); + vendorLicenseFacade.submit(vlm1Id, USER1); + + } + + protected void createThirdFinalVersionForVLMChangeEpLKGInSome(String vlm1Id, org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity ep, org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyGroupEntity lkg) { + versioningManager.checkout(VENDOR_LICENSE_MODEL_VERSIONABLE_TYPE, vlm1Id, USER1); + vendorLicenseManager.updateEntitlementPool(ep, USER1); + vendorLicenseManager.updateLicenseKeyGroup(lkg, USER1); + versioningManager.checkin(VENDOR_LICENSE_MODEL_VERSIONABLE_TYPE, vlm1Id, USER1, "desc1"); + vendorLicenseFacade.submit(vlm1Id, USER1); + + } + + + protected void setVlm2FirstVersion() { + Set opScopeChoices = new HashSet<>(); + opScopeChoices.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.Other); + opScopeChoices.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.Data_Center); + opScopeChoices.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.Network_Wide); + + Set opScopeChoicesLKG = new HashSet<>(); + opScopeChoicesLKG.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.CPU); + opScopeChoicesLKG.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.VM); + opScopeChoicesLKG.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.Availability_Zone); + opScopeChoicesLKG.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.Data_Center); + + ep21 = EntitlementPoolTest.createEntitlementPool(vlm2Id, VERSION01, "EP21", "EP21 dec", 80, org.openecomp.sdc.vendorlicense.dao.types.ThresholdUnit.Absolute, org.openecomp.sdc.vendorlicense.dao.types.EntitlementMetric.Core, null, "inc21", org.openecomp.sdc.vendorlicense.dao.types.AggregationFunction.Other, "agg func21", opScopeChoices, null, org.openecomp.sdc.vendorlicense.dao.types.EntitlementTime.Hour, null, "sku21"); + ep21Id = vendorLicenseManager.createEntitlementPool(ep21, USER1).getId(); + + lkg21 = LicenseKeyGroupTest.createLicenseKeyGroup(vlm2Id, VERSION01, "LKG21", "LKG21 dec", org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyType.One_Time, new org.openecomp.sdc.vendorlicense.dao.types.MultiChoiceOrOther<>(opScopeChoicesLKG, null)); + lkg21Id = vendorLicenseManager.createLicenseKeyGroup(lkg21, USER1).getId(); + lkg21.setId(lkg21Id); + + fg21 = LicenseAgreementTest.createFeatureGroup(vlm2Id, VERSION01, "fg21", "FG21", "FG21 desc", CommonMethods.toSingleElementSet(ep21Id), CommonMethods.toSingleElementSet(lkg21Id)); + fg21Id = vendorLicenseManager.createFeatureGroup(fg21, USER1).getId(); + + String requirementsAndConstrains1 = "Requirements And Constraints21"; + org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementEntity + la2 = LicenseAgreementTest.createLicenseAgreement(vlm2Id, VERSION01, null, "LA21", "LA21 desc", requirementsAndConstrains1, new org.openecomp.sdc.vendorlicense.dao.types.ChoiceOrOther<>( + org.openecomp.sdc.vendorlicense.dao.types.LicenseTerm.Unlimited, null), fg21Id); + la21Id = vendorLicenseManager.createLicenseAgreement(la2, USER1).getId(); + +// setValuesForVlm(VERSION01, ep21, ep21Id, lkg21, lkg21Id, fg21, fg21Id, la21Id, 1); + + vendorLicenseManager.checkin(vlm2Id, USER1); + currVersion = versioningManager.submit(VENDOR_LICENSE_MODEL_VERSIONABLE_TYPE, vlm2Id, USER1, null); + + List fgs = new ArrayList<>(); + fgs.add(fg21Id); + vsp2 = createVspDetails(null, null, "VSP2_" + CommonMethods.nextUuId(), "Test-vsp", "vendorName", vlm2Id, "icon", "category", "subCategory", la21Id, fgs); + vsp2 = vendorSoftwareProductManager.createNewVsp(vsp2, USER1); + } + + protected void setVlm2SecondVersion() { + vendorLicenseManager.checkout(vlm2Id, USER1); + + Set opScopeChoices = new HashSet<>(); + opScopeChoices.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.Other); + opScopeChoices.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.Data_Center); + opScopeChoices.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.Network_Wide); + + Set opScopeChoicesLKG = new HashSet<>(); + opScopeChoicesLKG.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.CPU); + opScopeChoicesLKG.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.VM); + opScopeChoicesLKG.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.Availability_Zone); + opScopeChoicesLKG.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.Data_Center); + + ep22 = EntitlementPoolTest.createEntitlementPool(vlm2Id, currVersion, "EP22", "EP22 dec", 80, org.openecomp.sdc.vendorlicense.dao.types.ThresholdUnit.Absolute, org.openecomp.sdc.vendorlicense.dao.types.EntitlementMetric.Core, null, "inc22", org.openecomp.sdc.vendorlicense.dao.types.AggregationFunction.Other, "agg func22", opScopeChoices, null, org.openecomp.sdc.vendorlicense.dao.types.EntitlementTime.Hour, null, "sku22"); + ep22Id = vendorLicenseManager.createEntitlementPool(ep22, USER1).getId(); + + lkg22 = LicenseKeyGroupTest.createLicenseKeyGroup(vlm2Id, currVersion, "LKG22", "LKG22 dec", org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyType.One_Time, new org.openecomp.sdc.vendorlicense.dao.types.MultiChoiceOrOther<>(opScopeChoicesLKG, null)); + lkg22Id = vendorLicenseManager.createLicenseKeyGroup(lkg22, USER1).getId(); + lkg22.setId(lkg22Id); + + fg22 = LicenseAgreementTest.createFeatureGroup(vlm2Id, currVersion, "fg22", "FG22", "FG22 desc", CommonMethods.toSingleElementSet(ep22Id), CommonMethods.toSingleElementSet(lkg22Id)); + fg22Id = vendorLicenseManager.createFeatureGroup(fg22, USER1).getId(); + + String requirementsAndConstrains1 = "Requirements And Constraints22"; + org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementEntity + la2 = LicenseAgreementTest.createLicenseAgreement(vlm2Id, currVersion, null, "LA22", "LA22 desc", requirementsAndConstrains1, new org.openecomp.sdc.vendorlicense.dao.types.ChoiceOrOther<>( + org.openecomp.sdc.vendorlicense.dao.types.LicenseTerm.Unlimited, null), fg22Id); + la22Id = vendorLicenseManager.createLicenseAgreement(la2, USER1).getId(); + +// setValuesForVlm(currVersion, ep22, ep22Id, lkg22, lkg22Id, fg22, fg22Id, la22Id, 2); + + vendorLicenseManager.checkin(vlm2Id, USER1); + currVersion = versioningManager.submit(VENDOR_LICENSE_MODEL_VERSIONABLE_TYPE, vlm2Id, USER1, null); + } + + protected static VspDetails createVspDetails(String id, Version version, String name, String desc, String vendorName, String vlm, String icon, String category, String subCategory, String licenseAgreement, List featureGroups) { + VspDetails vspDetails = new VspDetails(id, version); + vspDetails.setName(name); + vspDetails.setDescription(desc); + vspDetails.setIcon(icon); + vspDetails.setCategory(category); + vspDetails.setSubCategory(subCategory); + vspDetails.setVendorName(vendorName); + vspDetails.setVendorId(vlm); + vspDetails.setLicenseAgreement(licenseAgreement); + vspDetails.setFeatureGroups(featureGroups); + return vspDetails; + } + + +} + diff --git a/openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/test/java/org/openecomp/sdc/vendorlicense/EntitlementPoolTest.java b/openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/test/java/org/openecomp/sdc/vendorlicense/EntitlementPoolTest.java new file mode 100644 index 0000000000..0c05fee10d --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/test/java/org/openecomp/sdc/vendorlicense/EntitlementPoolTest.java @@ -0,0 +1,275 @@ +package org.openecomp.sdc.vendorlicense; + +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.vendorlicense.dao.EntitlementPoolDao; +import org.openecomp.sdc.vendorlicense.dao.EntitlementPoolDaoFactory; +import org.openecomp.sdc.vendorlicense.impl.VendorLicenseManagerImpl; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.errors.VersioningErrorCodes; +import org.openecomp.core.util.UniqueValueUtil; +import org.openecomp.core.utilities.CommonMethods; + +import org.openecomp.sdc.vendorlicense.dao.types.AggregationFunction; +import org.openecomp.sdc.vendorlicense.dao.types.EntitlementMetric; +import org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity; +import org.openecomp.sdc.vendorlicense.dao.types.EntitlementTime; +import org.openecomp.sdc.vendorlicense.dao.types.OperationalScope; +import org.testng.Assert; +import org.testng.annotations.BeforeClass; +import org.testng.annotations.Test; + +import java.util.Collection; +import java.util.Collections; +import java.util.HashSet; +import java.util.Set; + +public class EntitlementPoolTest { + + private static final String USER1 = "epTestUser1"; + private static final String USER2 = "epTestUser2"; + private static final String EP1_V01_DESC = "EP1 desc"; + private static final Version VERSION01 = new Version(0, 1); + private static final Version VERSION03 = new Version(0, 3); + private static final String EP1_NAME = "EP1 name"; + private static final String EP2_NAME = "EP2 name"; + + private static VendorLicenseManager vendorLicenseManager = new VendorLicenseManagerImpl(); + private static EntitlementPoolDao entitlementPoolDao; + + private static String vlm1Id; + private static String vlm2Id; + private static String ep1Id; + private static String ep2Id; + + public static EntitlementPoolEntity createEntitlementPool(String vlmId, Version version, + String name, String desc, int threshold, + org.openecomp.sdc.vendorlicense.dao.types.ThresholdUnit thresholdUnit, + EntitlementMetric entitlementMetricChoice, + String entitlementMetricOther, + String increments, + AggregationFunction aggregationFunctionChoice, + String aggregationFunctionOther, + Set operationalScopeChoices, + String operationalScopeOther, + EntitlementTime timeChoice, + String timeOther, String sku) { + EntitlementPoolEntity entitlementPool = new EntitlementPoolEntity(); + entitlementPool.setVendorLicenseModelId(vlmId); + entitlementPool.setVersion(version); + entitlementPool.setName(name); + entitlementPool.setDescription(desc); + entitlementPool.setThresholdValue(threshold); + entitlementPool.setThresholdUnit(thresholdUnit); + entitlementPool + .setEntitlementMetric(new org.openecomp.sdc.vendorlicense.dao.types.ChoiceOrOther<>(entitlementMetricChoice, entitlementMetricOther)); + entitlementPool.setIncrements(increments); + entitlementPool.setAggregationFunction( + new org.openecomp.sdc.vendorlicense.dao.types.ChoiceOrOther<>(aggregationFunctionChoice, aggregationFunctionOther)); + entitlementPool.setOperationalScope( + new org.openecomp.sdc.vendorlicense.dao.types.MultiChoiceOrOther<>(operationalScopeChoices, operationalScopeOther)); + entitlementPool.setTime(new org.openecomp.sdc.vendorlicense.dao.types.ChoiceOrOther<>(timeChoice, timeOther)); + entitlementPool.setManufacturerReferenceNumber(sku); + return entitlementPool; + } + + private static void assertEntitlementPoolsEquals(EntitlementPoolEntity actual, + EntitlementPoolEntity expected) { + Assert.assertEquals(actual.getVendorLicenseModelId(), expected.getVendorLicenseModelId()); + Assert.assertEquals(actual.getVersion(), expected.getVersion()); + Assert.assertEquals(actual.getId(), expected.getId()); + Assert.assertEquals(actual.getName(), expected.getName()); + Assert.assertEquals(actual.getDescription(), expected.getDescription()); + Assert.assertEquals(actual.getThresholdValue(), expected.getThresholdValue()); + Assert.assertEquals(actual.getThresholdUnit(), expected.getThresholdUnit()); + Assert.assertEquals(actual.getEntitlementMetric(), expected.getEntitlementMetric()); + Assert.assertEquals(actual.getIncrements(), expected.getIncrements()); + Assert.assertEquals(actual.getAggregationFunction(), expected.getAggregationFunction()); + Assert.assertEquals(actual.getOperationalScope(), expected.getOperationalScope()); + Assert.assertEquals(actual.getTime(), expected.getTime()); + Assert.assertEquals(actual.getManufacturerReferenceNumber(), + expected.getManufacturerReferenceNumber()); + } + + @BeforeClass + private void init() { + entitlementPoolDao = EntitlementPoolDaoFactory.getInstance().createInterface(); + vlm1Id = vendorLicenseManager.createVendorLicenseModel(VendorLicenseModelTest + .createVendorLicenseModel("vendor1 name " + CommonMethods.nextUuId(), "vlm1 dec", "icon1"), + USER1).getId(); + vlm2Id = vendorLicenseManager.createVendorLicenseModel(VendorLicenseModelTest + .createVendorLicenseModel("vendor2 name " + CommonMethods.nextUuId(), "vlm2 dec", "icon2"), + USER1).getId(); + } + + @Test + public void emptyListTest() { + Collection entitlementPools = + vendorLicenseManager.listEntitlementPools(vlm1Id, null, USER1); + Assert.assertEquals(entitlementPools.size(), 0); + } + + @Test(dependsOnMethods = "emptyListTest") + public void createTest() { + ep1Id = testCreate(vlm1Id, EP1_NAME); + + Set opScopeChoices; + opScopeChoices = new HashSet<>(); + opScopeChoices.add(OperationalScope.Core); + opScopeChoices.add(OperationalScope.CPU); + opScopeChoices.add(OperationalScope.Network_Wide); + EntitlementPoolEntity ep2 = + createEntitlementPool(vlm1Id, null, EP2_NAME, "EP2 dec", 70, org.openecomp.sdc.vendorlicense.dao.types.ThresholdUnit.Absolute, + EntitlementMetric.Other, "e metric2", "inc2", AggregationFunction.Average, null, + opScopeChoices, null, EntitlementTime.Other, "time2", "sku2"); + ep2Id = vendorLicenseManager.createEntitlementPool(ep2, USER1).getId(); + ep2.setId(ep2Id); + } + + private String testCreate(String vlmId, String name) { + Set opScopeChoices = new HashSet<>(); + opScopeChoices.add(OperationalScope.Other); + EntitlementPoolEntity ep1 = + createEntitlementPool(vlmId, null, name, EP1_V01_DESC, 80, org.openecomp.sdc.vendorlicense.dao.types.ThresholdUnit.Percentage, + EntitlementMetric.Core, null, "inc1", AggregationFunction.Other, "agg func1", + opScopeChoices, "op scope1", EntitlementTime.Other, "time1", "sku1"); + String ep1Id = vendorLicenseManager.createEntitlementPool(ep1, USER1).getId(); + ep1.setId(ep1Id); + + EntitlementPoolEntity loadedEp1 = entitlementPoolDao.get(ep1); + Assert.assertTrue(loadedEp1.equals(ep1)); + return ep1Id; + } + + @Test(dependsOnMethods = {"createTest"}) + public void testCreateWithExistingName_negative() { + testCreateWithExistingName_negative(vlm1Id, EP1_NAME); + } + + @Test(dependsOnMethods = {"createTest"}) + public void testCreateWithExistingNameUnderOtherVlm() { + testCreate(vlm2Id, EP1_NAME); + } + + @Test(dependsOnMethods = {"testCreateWithExistingName_negative"}) + public void updateAndGetTest() { + EntitlementPoolEntity emptyEp1 = new EntitlementPoolEntity(vlm1Id, VERSION01, ep1Id); + + EntitlementPoolEntity ep1 = entitlementPoolDao.get(emptyEp1); + ep1.setEntitlementMetric(new org.openecomp.sdc.vendorlicense.dao.types.ChoiceOrOther<>(EntitlementMetric.Other, "e metric1 updated")); + ep1.setAggregationFunction(new org.openecomp.sdc.vendorlicense.dao.types.ChoiceOrOther<>(AggregationFunction.Other, "agg func1 updated")); + + vendorLicenseManager.updateEntitlementPool(ep1, USER1); + + EntitlementPoolEntity loadedEp1 = vendorLicenseManager.getEntitlementPool(emptyEp1, USER1); + assertEntitlementPoolsEquals(loadedEp1, ep1); + } + + @Test(dependsOnMethods = {"updateAndGetTest"}) + public void testGetNonExistingVersion_negative() { + try { + vendorLicenseManager + .getEntitlementPool(new EntitlementPoolEntity(vlm1Id, new Version(48, 83), ep1Id), USER1); + Assert.assertTrue(false); + } catch (CoreException e) { + Assert.assertEquals(e.code().id(), VersioningErrorCodes.REQUESTED_VERSION_INVALID); + } + } + + @Test(dependsOnMethods = {"updateAndGetTest"}) + public void testGetOtherUserCandidateVersion_negative() { + vendorLicenseManager.checkin(vlm1Id, USER1); + vendorLicenseManager.checkout(vlm1Id, USER2); + try { + vendorLicenseManager + .getEntitlementPool(new EntitlementPoolEntity(vlm1Id, new Version(0, 2), ep1Id), USER1); + Assert.assertTrue(false); + } catch (CoreException e) { + Assert.assertEquals(e.code().id(), VersioningErrorCodes.REQUESTED_VERSION_INVALID); + } + } + + @Test(dependsOnMethods = {"testGetOtherUserCandidateVersion_negative"}) + public void testGetCandidateVersion() { + EntitlementPoolEntity ep = new EntitlementPoolEntity(vlm1Id, new Version(0, 2), ep1Id); + ep.setDescription("updated!"); + vendorLicenseManager.updateEntitlementPool(ep, USER2); + + EntitlementPoolEntity actualEp = vendorLicenseManager.getEntitlementPool(ep, USER2); + EntitlementPoolEntity expectedEp = entitlementPoolDao.get(ep); + + Assert.assertEquals(actualEp.getDescription(), ep.getDescription()); + assertEntitlementPoolsEquals(actualEp, expectedEp); + } + + @Test(dependsOnMethods = {"testGetCandidateVersion"}) + public void testGetOldVersion() { + vendorLicenseManager.checkin(vlm1Id, USER2); + EntitlementPoolEntity actualEp = vendorLicenseManager + .getEntitlementPool(new EntitlementPoolEntity(vlm1Id, new Version(0, 1), ep1Id), USER2); + Assert.assertEquals(actualEp.getDescription(), EP1_V01_DESC); + } + + @Test(dependsOnMethods = {"testGetOldVersion"}) + public void listTest() { + Collection loadedEps = + vendorLicenseManager.listEntitlementPools(vlm1Id, null, USER1); + Assert.assertEquals(loadedEps.size(), 2); + + int existingCounter = 0; + for (EntitlementPoolEntity loadedEp : loadedEps) { + if (ep2Id.equals(loadedEp.getId()) || ep1Id.equals(loadedEp.getId())) { + existingCounter++; + } + } + + Assert.assertEquals(existingCounter, 2); + } + + @Test(dependsOnMethods = {"listTest"}) + public void deleteTest() { + vendorLicenseManager.checkout(vlm1Id, USER1); + EntitlementPoolEntity emptyEp1 = new EntitlementPoolEntity(vlm1Id, null, ep1Id); + vendorLicenseManager.deleteEntitlementPool(emptyEp1, USER1); + + emptyEp1.setVersion(VERSION03); + EntitlementPoolEntity loadedEp1 = entitlementPoolDao.get(emptyEp1); + Assert.assertEquals(loadedEp1, null); + + Collection loadedEps = + entitlementPoolDao.list(new EntitlementPoolEntity(vlm1Id, VERSION03, null)); + Assert.assertEquals(loadedEps.size(), 1); + Assert.assertEquals(loadedEps.iterator().next().getId(), ep2Id); + } + + @Test(dependsOnMethods = "deleteTest") + public void listOldVersionTest() { + Collection loadedEps = + vendorLicenseManager.listEntitlementPools(vlm1Id, VERSION01, USER1); + Assert.assertEquals(loadedEps.size(), 2); + } + + @Test(dependsOnMethods = "deleteTest") + public void testCreateWithRemovedName() { + testCreate(vlm1Id, EP1_NAME); + } + + @Test(dependsOnMethods = "deleteTest") + public void testCreateWithExistingNameAfterCheckout_negative() { + testCreateWithExistingName_negative(vlm1Id, EP2_NAME); + } + + private void testCreateWithExistingName_negative(String vlmId, String epName) { + try { + EntitlementPoolEntity ep1 = + createEntitlementPool(vlmId, null, epName, EP1_V01_DESC, 80, org.openecomp.sdc.vendorlicense.dao.types.ThresholdUnit.Percentage, + EntitlementMetric.Core, null, "inc1", AggregationFunction.Other, "agg func1", + Collections.singleton(OperationalScope.Other), "op scope1", EntitlementTime.Other, + "time1", "sku1"); + vendorLicenseManager.createEntitlementPool(ep1, USER1).getId(); + Assert.fail(); + } catch (CoreException e) { + Assert.assertEquals(e.code().id(), UniqueValueUtil.UNIQUE_VALUE_VIOLATION); + } + } + +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/test/java/org/openecomp/sdc/vendorlicense/FeatureGroupTest.java b/openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/test/java/org/openecomp/sdc/vendorlicense/FeatureGroupTest.java new file mode 100644 index 0000000000..c2381dd2f3 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/test/java/org/openecomp/sdc/vendorlicense/FeatureGroupTest.java @@ -0,0 +1,202 @@ +package org.openecomp.sdc.vendorlicense; + +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.vendorlicense.facade.VendorLicenseFacade; +import org.openecomp.sdc.vendorlicense.impl.VendorLicenseManagerImpl; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.core.util.UniqueValueUtil; +import org.openecomp.core.utilities.CommonMethods; +import org.testng.Assert; +import org.testng.annotations.Test; + +import java.util.*; + +public class FeatureGroupTest { + protected static final Version VERSION01 = new Version(0, 1); + protected static final String USER1 = "FeatureGroupTest_User1"; + protected static VendorLicenseManager vendorLicenseManager = new VendorLicenseManagerImpl(); + protected static VendorLicenseFacade vendorLicenseFacade = org.openecomp.sdc.vendorlicense.facade.VendorLicenseFacadeFactory + .getInstance().createInterface(); + + + @Test + public void testListFeatureGroups() throws Exception { + String vlmId = vendorLicenseFacade.createVendorLicenseModel(VendorLicenseModelTest.createVendorLicenseModel("vlmId_" + CommonMethods.nextUuId(), "vlm2Id desc", "icon2"), USER1).getId(); + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity + fg22 = LicenseAgreementTest.createFeatureGroup(vlmId, VERSION01, "fg2", "FG2", "FG2 desc", null, null); + String fg22Id = vendorLicenseManager.createFeatureGroup(fg22, USER1).getId(); + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity + fg33 = LicenseAgreementTest.createFeatureGroup(vlmId, VERSION01, "fg3", "FG3", "FG3 desc", null, null); + String fg33Id = vendorLicenseManager.createFeatureGroup(fg33, USER1).getId(); + + Collection featureGroupEntities = vendorLicenseManager.listFeatureGroups(vlmId, null, USER1); + + Assert.assertEquals(featureGroupEntities.size(), 2); + Set actualIds = new HashSet<>(); + for (org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity featureGroupEntity : featureGroupEntities) { + actualIds.add(featureGroupEntity.getId()); + } + + Set expectedIds = new HashSet<>(); + expectedIds.add(fg22Id); + expectedIds.add(fg33Id); + for (String id : actualIds) { + Assert.assertTrue(expectedIds.contains(id)); + } + + } + + @Test + public void testCreateFeatureGroup() throws Exception { + String testName = "testCreateFeatureGroup"; + String vlmId = vendorLicenseFacade.createVendorLicenseModel(VendorLicenseModelTest.createVendorLicenseModel(testName + CommonMethods.nextUuId(), testName, "icon1"), USER1).getId(); + Set opScopeChoices = new HashSet<>(); + opScopeChoices.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.Other); + opScopeChoices.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.Data_Center); + opScopeChoices.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.Network_Wide); + org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity + ep = EntitlementPoolTest.createEntitlementPool(vlmId, VERSION01, "EP1" + CommonMethods.nextUuId(), "EP1 dec", 80, org.openecomp.sdc.vendorlicense.dao.types.ThresholdUnit.Absolute, org.openecomp.sdc.vendorlicense.dao.types.EntitlementMetric.Core, null, "inc1", org.openecomp.sdc.vendorlicense.dao.types.AggregationFunction.Other, "agg func1", opScopeChoices, null, org.openecomp.sdc.vendorlicense.dao.types.EntitlementTime.Hour, null, "sku1"); + String epId = vendorLicenseManager.createEntitlementPool(ep, USER1).getId(); + Set opScopeChoicesLKG = new HashSet<>(); + opScopeChoicesLKG.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.CPU); + opScopeChoicesLKG.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.VM); + opScopeChoicesLKG.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.Availability_Zone); + opScopeChoicesLKG.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.Data_Center); + + org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyGroupEntity + lkg = LicenseKeyGroupTest.createLicenseKeyGroup(vlmId, VERSION01, "LKG1", "LKG1 dec", org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyType.One_Time, new org.openecomp.sdc.vendorlicense.dao.types.MultiChoiceOrOther<>(opScopeChoicesLKG, null)); + String lkgId = vendorLicenseManager.createLicenseKeyGroup(lkg, USER1).getId(); + lkg.setId(lkgId); + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity + fg1 = createFGForTest(vlmId, "created" + CommonMethods.nextUuId(), Collections.singleton(epId), Collections.singleton(lkgId)); + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity + fg1FromDB = vendorLicenseManager.getFeatureGroupModel(fg1, USER1).getFeatureGroup(); + Assert.assertTrue(fg1FromDB.equals(fg1)); + } + + + @Test + public void testCreateWithExistingName_negative() { + String testName = "createExistingName"; + String vlmId = vendorLicenseFacade.createVendorLicenseModel(VendorLicenseModelTest.createVendorLicenseModel(testName + CommonMethods.nextUuId(), testName, "icon1"), USER1).getId(); + createFGForTest(vlmId, "created", Collections.emptySet(), Collections.emptySet()); + try { + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity + created = LicenseAgreementTest.createFeatureGroup(vlmId, null, "created", "created", "created desc", Collections.emptySet(), Collections.emptySet()); + vendorLicenseManager.createFeatureGroup(created, USER1); + Assert.fail(); + } catch (CoreException e) { + Assert.assertEquals(e.code().id(), UniqueValueUtil.UNIQUE_VALUE_VIOLATION); + } + } + + private org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity createFGForTest(String vlmId, String fgName, Set epIds, Set lkgIds) { + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity + created = LicenseAgreementTest.createFeatureGroup(vlmId, null, null, fgName, "created desc", epIds, lkgIds); + return vendorLicenseManager.createFeatureGroup(created, USER1); + } + + @Test + public void testUpdateFeatureGroup_addEP_andGET() throws Exception { + String testName = "testUpdateFeatureGroup_addEP_andGET"; + String vlmId = vendorLicenseFacade.createVendorLicenseModel(VendorLicenseModelTest.createVendorLicenseModel(testName + CommonMethods.nextUuId(), testName, "icon1"), USER1).getId(); + + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity + fg5 = LicenseAgreementTest.createFeatureGroup(vlmId, VERSION01, "id" + CommonMethods.nextUuId(), "created" + CommonMethods.nextUuId(), "created desc", null, null); + vendorLicenseManager.createFeatureGroup(fg5, USER1).getId(); + + + Set opScopeChoices = new HashSet<>(); + opScopeChoices.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.Other); + opScopeChoices.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.Data_Center); + + org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity + epToAdd = EntitlementPoolTest.createEntitlementPool(vlmId, VERSION01, "epToAdd", "epToAdd dec", 80, org.openecomp.sdc.vendorlicense.dao.types.ThresholdUnit.Absolute, org.openecomp.sdc.vendorlicense.dao.types.EntitlementMetric.Core, null, "inc1", org.openecomp.sdc.vendorlicense.dao.types.AggregationFunction.Other, "agg func1", opScopeChoices, null, org.openecomp.sdc.vendorlicense.dao.types.EntitlementTime.Hour, null, "sku1"); + String epToAddId = vendorLicenseManager.createEntitlementPool(epToAdd, USER1).getId(); + + vendorLicenseManager.updateFeatureGroup(fg5, null, null, CommonMethods.toSingleElementSet(epToAddId), null, USER1); + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupModel + updatedFG = vendorLicenseManager.getFeatureGroupModel(fg5, USER1); + Set updatedEPs = updatedFG.getEntitlementPools(); + + epToAdd.setReferencingFeatureGroups(CommonMethods.toSingleElementSet(fg5.getId())); + + Assert.assertEquals(updatedEPs.size(), 1); + for (org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity updatedEP : updatedEPs) { + Assert.assertTrue(updatedEP.getReferencingFeatureGroups().contains(fg5.getId())); + Assert.assertEquals(updatedEP.getId(), epToAddId); + } + } + + @Test + public void testUpdateFeatureGroup_removeLKG_andGET() throws Exception { + String testName = "testUpdateFeatureGroup_removeLKG_andGET"; + String vlmId = vendorLicenseFacade.createVendorLicenseModel(VendorLicenseModelTest.createVendorLicenseModel(testName + CommonMethods.nextUuId(), testName, "icon1"), USER1).getId(); + + Set opScopeChoicesLKG = new HashSet<>(); + opScopeChoicesLKG.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.CPU); + opScopeChoicesLKG.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.VM); + opScopeChoicesLKG.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.Availability_Zone); + opScopeChoicesLKG.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.Data_Center); + org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyGroupEntity + lkg = LicenseKeyGroupTest.createLicenseKeyGroup(vlmId, VERSION01, "lkg" + CommonMethods.nextUuId(), "lkg desc", org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyType.Unique, new org.openecomp.sdc.vendorlicense.dao.types.MultiChoiceOrOther<>(opScopeChoicesLKG, null)); + String lkgId = vendorLicenseManager.createLicenseKeyGroup(lkg, USER1).getId(); + lkg.setId(lkgId); + + org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyGroupEntity + lkg_1 = LicenseKeyGroupTest.createLicenseKeyGroup(vlmId, VERSION01, "lkg" + CommonMethods.nextUuId(), "lkg_1 desc", org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyType.Unique, new org.openecomp.sdc.vendorlicense.dao.types.MultiChoiceOrOther<>(opScopeChoicesLKG, null)); + String lkgId_1 = vendorLicenseManager.createLicenseKeyGroup(lkg_1, USER1).getId(); + lkg.setId(lkgId); + + Set opScopeChoices = new HashSet<>(); + opScopeChoices.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.Other); + opScopeChoices.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.Data_Center); + opScopeChoices.add(org.openecomp.sdc.vendorlicense.dao.types.OperationalScope.Network_Wide); + org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity + ep = EntitlementPoolTest.createEntitlementPool(vlmId, VERSION01, "EP1" + CommonMethods.nextUuId(), "EP1 dec", 80, org.openecomp.sdc.vendorlicense.dao.types.ThresholdUnit.Absolute, org.openecomp.sdc.vendorlicense.dao.types.EntitlementMetric.Core, null, "inc1", org.openecomp.sdc.vendorlicense.dao.types.AggregationFunction.Other, "agg func1", opScopeChoices, null, org.openecomp.sdc.vendorlicense.dao.types.EntitlementTime.Hour, null, "sku1"); + String epId = vendorLicenseManager.createEntitlementPool(ep, USER1).getId(); + + Set lkgs = new HashSet<>(); + lkgs.add(lkgId); + lkgs.add(lkgId_1); + + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity + fg = LicenseAgreementTest.createFeatureGroup(vlmId, VERSION01, "fg11" + CommonMethods.nextUuId(), "FG1", "FG1 desc", CommonMethods.toSingleElementSet(epId), lkgs); + String fgId = vendorLicenseManager.createFeatureGroup(fg, USER1).getId(); + vendorLicenseManager.updateFeatureGroup(fg, null, CommonMethods.toSingleElementSet(lkgId), null, null, USER1); + + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupModel + featureGroup = vendorLicenseManager.getFeatureGroupModel(fg, USER1); + Set licenseKeyGroups = featureGroup.getLicenseKeyGroups(); + Assert.assertEquals(licenseKeyGroups.size(), 1); + List lkgIds = new ArrayList<>(); + for (org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyGroupEntity licenseKeyGroup : licenseKeyGroups) { + lkgIds.add(licenseKeyGroup.getId()); + } + + Assert.assertTrue(lkgIds.contains(lkgId_1)); + Assert.assertFalse(lkgIds.contains(lkgId)); + + } + + + @Test + public void testDeleteFeatureGroup() throws Exception { + String testName = "testDeleteFeatureGroup"; + String vlmId = vendorLicenseFacade.createVendorLicenseModel(VendorLicenseModelTest.createVendorLicenseModel(testName + CommonMethods.nextUuId(), testName, "icon1"), USER1).getId(); + + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity + fg1 = createFGForTest(vlmId, "new", Collections.emptySet(), Collections.emptySet()); + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity + fg2 = createFGForTest(vlmId, "newer", Collections.emptySet(), Collections.emptySet()); + Collection featureGroupEntities = vendorLicenseManager.listFeatureGroups(vlmId, null, USER1); + Assert.assertEquals(featureGroupEntities.size(), 2); //precondition + + vendorLicenseManager.deleteFeatureGroup(fg1, USER1); + Assert.assertEquals(vendorLicenseManager.listFeatureGroups(vlmId, null, USER1).size(), 1); + + + } + + +} \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/test/java/org/openecomp/sdc/vendorlicense/LicenseAgreementTest.java b/openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/test/java/org/openecomp/sdc/vendorlicense/LicenseAgreementTest.java new file mode 100644 index 0000000000..f68f84ec0a --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/test/java/org/openecomp/sdc/vendorlicense/LicenseAgreementTest.java @@ -0,0 +1,218 @@ +package org.openecomp.sdc.vendorlicense; + +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.vendorlicense.dao.FeatureGroupDaoFactory; +import org.openecomp.sdc.vendorlicense.dao.types.LicenseTerm; +import org.openecomp.sdc.vendorlicense.impl.VendorLicenseManagerImpl; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.core.util.UniqueValueUtil; +import org.openecomp.core.utilities.CommonMethods; +import org.testng.Assert; +import org.testng.annotations.BeforeClass; +import org.testng.annotations.Test; + +import java.util.Collection; +import java.util.HashSet; +import java.util.Set; + +public class LicenseAgreementTest { + private static final Version VERSION01 = new Version(0, 1); + private static final String USER1 = "user1"; + private static final String LA1_NAME = "LA1 Name"; + + private static VendorLicenseManager vendorLicenseManager = new VendorLicenseManagerImpl(); + private static org.openecomp.sdc.vendorlicense.dao.FeatureGroupDao featureGroupDao; + private static org.openecomp.sdc.vendorlicense.dao.LicenseAgreementDao licenseAgreementDao; + + private static String vlm1Id; + private static String vlm2Id; + private static String la1Id; + private static String la2Id; + + public static org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementEntity createLicenseAgreement(String vlmId, Version version, + String id, String name, String desc, + String requirementsAndConstrains, + org.openecomp.sdc.vendorlicense.dao.types.ChoiceOrOther term, + String... fgIds) { + org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementEntity + la = new org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementEntity(); + la.setVendorLicenseModelId(vlmId); + la.setVersion(version); + la.setId(id); + la.setName(name); + la.setDescription(desc); + la.setLicenseTerm(term); + la.setRequirementsAndConstrains(requirementsAndConstrains); + for (String fgId : fgIds) { + la.getFeatureGroupIds().add(fgId); + } + return la; + } + + public static org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity createFeatureGroup(String vendorId, Version version, String id, + String name, String description, + Set entitlementPoolIds, + Set licenseKeyGroupIds) { + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity + featureGroup = new org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity(); + featureGroup.setVendorLicenseModelId(vendorId); + featureGroup.setVersion(version); + featureGroup.setId(id); + featureGroup.setName(name); + featureGroup.setDescription(description); + featureGroup.setEntitlementPoolIds(entitlementPoolIds); + featureGroup.setLicenseKeyGroupIds(licenseKeyGroupIds); + return featureGroup; + } + + @BeforeClass + private void init() { + licenseAgreementDao = org.openecomp.sdc.vendorlicense.dao.LicenseAgreementDaoFactory.getInstance().createInterface(); + featureGroupDao = FeatureGroupDaoFactory.getInstance().createInterface(); + vlm1Id = vendorLicenseManager.createVendorLicenseModel(VendorLicenseModelTest + .createVendorLicenseModel("vendor1 name " + CommonMethods.nextUuId(), "vlm1 dec", "icon1"), + USER1).getId(); + vlm2Id = vendorLicenseManager.createVendorLicenseModel(VendorLicenseModelTest + .createVendorLicenseModel("vendor2 name " + CommonMethods.nextUuId(), "vlm2 dec", "icon2"), + USER1).getId(); + } + + @Test + public void createLicenseAgreementTest() { + la1Id = testCreate(vlm1Id, LA1_NAME); + } + + private String testCreate(String vlmId, String name) { + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity fg1 = + createFeatureGroup(vlmId, VERSION01, "fg11", "FG1", "FG1 desc", null, null); + featureGroupDao.create(fg1); + + org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementEntity + la1 = createLicenseAgreement(vlmId, VERSION01, null, name, "LA1 desc", + "RequirementsAndConstrains1", new org.openecomp.sdc.vendorlicense.dao.types.ChoiceOrOther<>( + org.openecomp.sdc.vendorlicense.dao.types.LicenseTerm.Unlimited, null), "fg11"); + la1 = vendorLicenseManager.createLicenseAgreement(la1, USER1); + String la1Id = la1.getId(); + + org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementEntity loadedLa1 = licenseAgreementDao.get(la1); + Assert.assertTrue(loadedLa1.equals(la1)); + return la1Id; + } + + @Test(dependsOnMethods = {"createLicenseAgreementTest"}) + public void testCreateWithExistingName_negative() { + try { + org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementEntity la1 = + createLicenseAgreement(vlm1Id, VERSION01, null, LA1_NAME, "LA1 desc", + "RequirementsAndConstrains1", new org.openecomp.sdc.vendorlicense.dao.types.ChoiceOrOther<>( + org.openecomp.sdc.vendorlicense.dao.types.LicenseTerm.Unlimited, null), + "fg11"); + vendorLicenseManager.createLicenseAgreement(la1, USER1); + Assert.fail(); + } catch (CoreException e) { + Assert.assertEquals(e.code().id(), UniqueValueUtil.UNIQUE_VALUE_VIOLATION); + } + } + + @Test(dependsOnMethods = {"createLicenseAgreementTest"}) + public void testCreateWithExistingNameUnderOtherVlm() { + testCreate(vlm2Id, LA1_NAME); + } + + @Test(dependsOnMethods = {"testCreateWithExistingName_negative"}) + public void updateLicenseAgreementTest() { + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity fg2 = + createFeatureGroup(vlm1Id, VERSION01, "fg2", "FG2", "FG2 desc", null, null); + featureGroupDao.create(fg2); + + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity fg3 = + createFeatureGroup(vlm1Id, VERSION01, "fg3", "FG3", "FG3 desc", null, null); + featureGroupDao.create(fg3); + + org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementEntity la1 = + licenseAgreementDao.get(new org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementEntity(vlm1Id, VERSION01, la1Id)); + la1.setDescription("LA1 desc updated"); + la1.setLicenseTerm(new org.openecomp.sdc.vendorlicense.dao.types.ChoiceOrOther<>( + org.openecomp.sdc.vendorlicense.dao.types.LicenseTerm.Other, "bla bla term")); + la1.getFeatureGroupIds().add("fg2"); + la1.getFeatureGroupIds().add("fg3"); + la1.getFeatureGroupIds().remove("fg11"); + + Set addedFeatureGroupIds = new HashSet<>(); + addedFeatureGroupIds.add("fg2"); + addedFeatureGroupIds.add("fg3"); + + Set removedFeatureGroupIds = new HashSet<>(); + removedFeatureGroupIds.add("fg11"); + + vendorLicenseManager + .updateLicenseAgreement(la1, addedFeatureGroupIds, removedFeatureGroupIds, USER1); + + org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementEntity loadedLa1 = + licenseAgreementDao.get(new org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementEntity(vlm1Id, VERSION01, la1Id)); + Assert.assertTrue(loadedLa1.equals(la1)); + + } + + @Test(dependsOnMethods = {"updateLicenseAgreementTest"}) + public void listLicenseAgreementsTest() { + org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementEntity + la2 = createLicenseAgreement(vlm1Id, VERSION01, null, "LA2", "LA2 desc", + "RequirementsAndConstrains2", new org.openecomp.sdc.vendorlicense.dao.types.ChoiceOrOther<>( + org.openecomp.sdc.vendorlicense.dao.types.LicenseTerm.Unlimited, null), "fg2"); + la2 = vendorLicenseManager.createLicenseAgreement(la2, USER1); + la2Id = la2.getId(); + + Collection loadedLas = + vendorLicenseManager.listLicenseAgreements(vlm1Id, null, USER1); + Assert.assertEquals(loadedLas.size(), 2); + boolean la2Exists = false; + for (org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementEntity loadedLa : loadedLas) { + if (la2Id.equals(loadedLa.getId())) { + Assert.assertTrue(loadedLa.equals(la2)); + la2Exists = true; + } + } + + Assert.assertTrue(la2Exists); + } + + @Test(dependsOnMethods = {"listLicenseAgreementsTest"}) + public void featureGroupDeletedLicenseAgreementUpdated() { + org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementEntity licenseAgreement = + createLicenseAgreement(vlm1Id, VERSION01, "laId", "LA2", "LA2 desc", + "RequirementsAndConstrains2", new org.openecomp.sdc.vendorlicense.dao.types.ChoiceOrOther<>( + org.openecomp.sdc.vendorlicense.dao.types.LicenseTerm.Unlimited, null), "fg2"); + licenseAgreementDao.create(licenseAgreement); + String featureGroupId = "FeatureGroupId"; + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity created = + createFeatureGroup(vlm1Id, VERSION01, "fg11", "FG1", "FG1 desc", null, null); + featureGroupDao.create(created); + featureGroupDao.addReferencingLicenseAgreement(created, licenseAgreement.getId()); + + vendorLicenseManager.deleteFeatureGroup(created, USER1); + org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementEntity afterDeletingFG = licenseAgreementDao.get(licenseAgreement); + Assert.assertEquals(afterDeletingFG.getFeatureGroupIds().size(), 1); + Assert.assertTrue(afterDeletingFG.getFeatureGroupIds().contains("fg2")); + } + + @Test(dependsOnMethods = {"listLicenseAgreementsTest"}) + public void deleteLicenseAgreementsTest() { + vendorLicenseManager.deleteLicenseAgreement(vlm1Id, la1Id, USER1); + + org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementEntity loadedLa1 = + licenseAgreementDao.get(new org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementEntity(vlm1Id, VERSION01, la1Id)); + Assert.assertEquals(loadedLa1, null); + + Collection loadedLas = + licenseAgreementDao.list(new org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementEntity(vlm1Id, VERSION01, null)); + Assert.assertEquals(loadedLas.size(), 1); + Assert.assertEquals(loadedLas.iterator().next().getId(), la2Id); + } + + @Test(dependsOnMethods = "deleteLicenseAgreementsTest") + public void testCreateWithRemovedName() { + testCreate(vlm1Id, LA1_NAME); + } +} + diff --git a/openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/test/java/org/openecomp/sdc/vendorlicense/LicenseKeyGroupTest.java b/openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/test/java/org/openecomp/sdc/vendorlicense/LicenseKeyGroupTest.java new file mode 100644 index 0000000000..15b179b9c6 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/test/java/org/openecomp/sdc/vendorlicense/LicenseKeyGroupTest.java @@ -0,0 +1,162 @@ +package org.openecomp.sdc.vendorlicense; + +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.vendorlicense.dao.LicenseKeyGroupDao; +import org.openecomp.sdc.vendorlicense.dao.LicenseKeyGroupDaoFactory; +import org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyGroupEntity; +import org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyType; +import org.openecomp.sdc.vendorlicense.dao.types.MultiChoiceOrOther; +import org.openecomp.sdc.vendorlicense.dao.types.OperationalScope; +import org.openecomp.sdc.vendorlicense.impl.VendorLicenseManagerImpl; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.core.nosqldb.api.NoSqlDb; +import org.openecomp.core.nosqldb.factory.NoSqlDbFactory; +import org.openecomp.core.util.UniqueValueUtil; +import org.openecomp.core.utilities.CommonMethods; +import org.testng.Assert; +import org.testng.annotations.BeforeClass; +import org.testng.annotations.Test; + +import java.util.Collection; +import java.util.Collections; +import java.util.HashSet; +import java.util.Set; + +public class LicenseKeyGroupTest { + + public static final String LKG1_NAME = "LKG1 name"; + private static final Version VERSION01 = new Version(0, 1); + private static final String USER1 = "user1"; + public static String vlm1Id; + public static String vlm2Id; + private static VendorLicenseManager vendorLicenseManager = new VendorLicenseManagerImpl(); + private static LicenseKeyGroupDao licenseKeyGroupDao; + private static NoSqlDb noSqlDb; + private static String lkg1Id; + private static String lkg2Id; + + public static LicenseKeyGroupEntity createLicenseKeyGroup(String vlmId, Version version, + String name, String desc, + LicenseKeyType type, + MultiChoiceOrOther operationalScope) { + LicenseKeyGroupEntity licenseKeyGroup = new LicenseKeyGroupEntity(); + licenseKeyGroup.setVendorLicenseModelId(vlmId); + licenseKeyGroup.setVersion(version); + licenseKeyGroup.setName(name); + licenseKeyGroup.setDescription(desc); + licenseKeyGroup.setType(type); + licenseKeyGroup.setOperationalScope(operationalScope); + return licenseKeyGroup; + } + + @BeforeClass + private void init() { + licenseKeyGroupDao = LicenseKeyGroupDaoFactory.getInstance().createInterface(); + noSqlDb = NoSqlDbFactory.getInstance().createInterface(); + + vlm1Id = vendorLicenseManager.createVendorLicenseModel(VendorLicenseModelTest + .createVendorLicenseModel("vendor1 name " + CommonMethods.nextUuId(), "vlm1Id dec", + "icon1"), USER1).getId(); + vlm2Id = vendorLicenseManager.createVendorLicenseModel(VendorLicenseModelTest + .createVendorLicenseModel("vendor2 name " + CommonMethods.nextUuId(), "vlm2 dec", "icon2"), + USER1).getId(); + } + + @Test + public void createTest() { + lkg1Id = testCreate(vlm1Id, LKG1_NAME); + } + + private String testCreate(String vlmId, String name) { + Set opScopeChoices = new HashSet<>(); + opScopeChoices.add(OperationalScope.CPU); + opScopeChoices.add(OperationalScope.VM); + opScopeChoices.add(OperationalScope.Tenant); + opScopeChoices.add(OperationalScope.Data_Center); + LicenseKeyGroupEntity lkg1 = + createLicenseKeyGroup(vlmId, VERSION01, name, "LKG1 dec", LicenseKeyType.One_Time, + new MultiChoiceOrOther<>(opScopeChoices, null)); + String lkg1Id = vendorLicenseManager.createLicenseKeyGroup(lkg1, USER1).getId(); + lkg1.setId(lkg1Id); + + LicenseKeyGroupEntity loadedLkg1 = licenseKeyGroupDao.get(lkg1); + Assert.assertTrue(loadedLkg1.equals(lkg1)); + return lkg1Id; + } + + @Test(dependsOnMethods = {"createTest"}) + public void testCreateWithExistingName_negative() { + try { + LicenseKeyGroupEntity lkg1 = + createLicenseKeyGroup(vlm1Id, VERSION01, LKG1_NAME, "LKG1 dec", LicenseKeyType.One_Time, + new MultiChoiceOrOther<>(Collections.singleton(OperationalScope.Other), + "other op scope")); + vendorLicenseManager.createLicenseKeyGroup(lkg1, USER1).getId(); + Assert.fail(); + } catch (CoreException e) { + Assert.assertEquals(e.code().id(), UniqueValueUtil.UNIQUE_VALUE_VIOLATION); + } + } + + @Test(dependsOnMethods = {"createTest"}) + public void testCreateWithExistingNameUnderOtherVlm() { + testCreate(vlm2Id, LKG1_NAME); + } + + @Test(dependsOnMethods = {"testCreateWithExistingName_negative"}) + public void updateAndGetTest() { + LicenseKeyGroupEntity lkg1 = + licenseKeyGroupDao.get(new LicenseKeyGroupEntity(vlm1Id, VERSION01, lkg1Id)); + Set opScopeChoices = new HashSet<>(); + opScopeChoices.add(OperationalScope.Other); + lkg1.setOperationalScope(new MultiChoiceOrOther<>(opScopeChoices, "op scope1 updated")); + lkg1.setDescription("LKG1 dec updated"); + + vendorLicenseManager.updateLicenseKeyGroup(lkg1, USER1); + + LicenseKeyGroupEntity loadedLkg1 = vendorLicenseManager.getLicenseKeyGroup(lkg1, USER1); + Assert.assertTrue(loadedLkg1.equals(lkg1)); + + } + + @Test(dependsOnMethods = {"updateAndGetTest"}) + public void listTest() { + Set opScopeChoices = new HashSet<>(); + opScopeChoices.add(OperationalScope.Network_Wide); + LicenseKeyGroupEntity lkg2 = + createLicenseKeyGroup(vlm1Id, VERSION01, "LKG2", "LKG2 dec", LicenseKeyType.Universal, + new MultiChoiceOrOther<>(opScopeChoices, null)); + lkg2Id = vendorLicenseManager.createLicenseKeyGroup(lkg2, USER1).getId(); + lkg2.setId(lkg2Id); + + Collection loadedLkgs = + vendorLicenseManager.listLicenseKeyGroups(vlm1Id, null, USER1); + Assert.assertEquals(loadedLkgs.size(), 2); + for (LicenseKeyGroupEntity loadedLkg : loadedLkgs) { + if (lkg2Id.equals(loadedLkg.getId())) { + Assert.assertTrue(loadedLkg.equals(lkg2)); + } + } + } + + @Test(dependsOnMethods = {"listTest"}) + public void deleteTest() { + vendorLicenseManager + .deleteLicenseKeyGroup(new LicenseKeyGroupEntity(vlm1Id, VERSION01, lkg1Id), USER1); + + LicenseKeyGroupEntity loadedLkg1 = + licenseKeyGroupDao.get(new LicenseKeyGroupEntity(vlm1Id, VERSION01, lkg1Id)); + Assert.assertEquals(loadedLkg1, null); + + Collection loadedLkgs = + licenseKeyGroupDao.list(new LicenseKeyGroupEntity(vlm1Id, VERSION01, null)); + Assert.assertEquals(loadedLkgs.size(), 1); + Assert.assertEquals(loadedLkgs.iterator().next().getId(), lkg2Id); + } + + @Test(dependsOnMethods = "deleteTest") + public void testCreateWithRemovedName() { + testCreate(vlm1Id, LKG1_NAME); + } +} + diff --git a/openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/test/java/org/openecomp/sdc/vendorlicense/VendorLicenseModelTest.java b/openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/test/java/org/openecomp/sdc/vendorlicense/VendorLicenseModelTest.java new file mode 100644 index 0000000000..c2a8d14c01 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/test/java/org/openecomp/sdc/vendorlicense/VendorLicenseModelTest.java @@ -0,0 +1,402 @@ +package org.openecomp.sdc.vendorlicense; + +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.vendorlicense.impl.VendorLicenseManagerImpl; +import org.openecomp.core.util.UniqueValueUtil; + +import org.testng.Assert; +import org.testng.annotations.BeforeTest; +import org.testng.annotations.Test; + +import java.util.Collection; +import java.util.HashSet; +import java.util.List; +import java.util.Set; + +public class VendorLicenseModelTest { + private static final org.openecomp.sdc.versioning.dao.types.Version + VERSION01 = new org.openecomp.sdc.versioning.dao.types.Version(0, 1); + private static final org.openecomp.sdc.versioning.dao.types.Version + VERSION02 = new org.openecomp.sdc.versioning.dao.types.Version(0, 2); + private static final String USER1 = "vlmTestUser1"; + private static final String USER2 = "vlmTestUser2"; + private static final String USER3 = "vlmTestUser3"; + private static final String VLM1_NAME = "Vlm1 name"; + private static VendorLicenseManager vendorLicenseManager = new VendorLicenseManagerImpl(); + private static org.openecomp.sdc.vendorlicense.dao.VendorLicenseModelDao vendorLicenseModelDao = + org.openecomp.sdc.vendorlicense.dao.VendorLicenseModelDaoFactory.getInstance().createInterface(); + + private static String vlm1Id; + private static String vlm2Id; + private static String vlm3Id; + private static String vlm4Id; + private static String laId; + private static String fg1Id; + private static String fg2Id; + + private static String testCreate() { + org.openecomp.sdc.vendorlicense.dao.types.VendorLicenseModelEntity vlm1 = createVendorLicenseModel(VLM1_NAME, "VLM1 dec", "icon1"); + String vlmId = vendorLicenseManager.createVendorLicenseModel(vlm1, USER1).getId(); + + vlm1.setVersion(VERSION01); + org.openecomp.sdc.vendorlicense.dao.types.VendorLicenseModelEntity loadedVlm1 = vendorLicenseModelDao.get(vlm1); + Assert.assertTrue(loadedVlm1.equals(vlm1)); + return vlmId; + } + + public static org.openecomp.sdc.vendorlicense.dao.types.VendorLicenseModelEntity createVendorLicenseModel(String name, String desc, + String icon) { + org.openecomp.sdc.vendorlicense.dao.types.VendorLicenseModelEntity + vendorLicenseModel = new org.openecomp.sdc.vendorlicense.dao.types.VendorLicenseModelEntity(); + vendorLicenseModel.setVendorName(name); + vendorLicenseModel.setDescription(desc); + vendorLicenseModel.setIconRef(icon); + return vendorLicenseModel; + } + + @BeforeTest + private void init() { + UniqueValueUtil.deleteUniqueValue(VendorLicenseConstants.UniqueValues.VENDOR_NAME, VLM1_NAME); + UniqueValueUtil + .deleteUniqueValue(VendorLicenseConstants.UniqueValues.VENDOR_NAME, "VLM1 updated"); + UniqueValueUtil.deleteUniqueValue(VendorLicenseConstants.UniqueValues.VENDOR_NAME, "VLM2"); + UniqueValueUtil.deleteUniqueValue(VendorLicenseConstants.UniqueValues.VENDOR_NAME, "test_vlm1"); + UniqueValueUtil.deleteUniqueValue(VendorLicenseConstants.UniqueValues.VENDOR_NAME, "test_vlm2"); + UniqueValueUtil.deleteUniqueValue(VendorLicenseConstants.UniqueValues.VENDOR_NAME, "test_vlm3"); + } + + @Test + public void createTest() { + vlm1Id = testCreate(); + } + + @Test(dependsOnMethods = {"createTest"}) + public void testCreateWithExistingVendorName_negative() { + try { + vendorLicenseManager + .createVendorLicenseModel(createVendorLicenseModel(VLM1_NAME, "VLM1 dec", "icon1"), + USER1); + Assert.fail(); + } catch (CoreException e) { + Assert.assertEquals(e.code().id(), UniqueValueUtil.UNIQUE_VALUE_VIOLATION); + } + } + + @Test(dependsOnMethods = {"testCreateWithExistingVendorName_negative"}) + public void updateTest() { + org.openecomp.sdc.vendorlicense.dao.types.VendorLicenseModelEntity + expectedVlm1 = new org.openecomp.sdc.vendorlicense.dao.types.VendorLicenseModelEntity(vlm1Id, VERSION01); + expectedVlm1.setVendorName("VLM1 updated"); + expectedVlm1.setDescription("VLM1 dec updated"); + expectedVlm1.setIconRef("icon1 updated"); + vendorLicenseManager.updateVendorLicenseModel(expectedVlm1, USER1); + + org.openecomp.sdc.vendorlicense.dao.types.VendorLicenseModelEntity actualVlm1 = + vendorLicenseModelDao.get(new org.openecomp.sdc.vendorlicense.dao.types.VendorLicenseModelEntity(vlm1Id, VERSION01)); + Assert.assertTrue(actualVlm1.equals(expectedVlm1)); + } + + @Test(dependsOnMethods = {"updateTest"}) + public void testUpdateWithSimilarVendorName() { + org.openecomp.sdc.vendorlicense.dao.types.VendorLicenseModelEntity + expectedVlm1 = new org.openecomp.sdc.vendorlicense.dao.types.VendorLicenseModelEntity(vlm1Id, VERSION01); + expectedVlm1.setVendorName("vlm1 UPDATED"); + vendorLicenseManager.updateVendorLicenseModel(expectedVlm1, USER1); + + org.openecomp.sdc.vendorlicense.dao.types.VendorLicenseModelEntity actualVlm1 = + vendorLicenseModelDao.get(new org.openecomp.sdc.vendorlicense.dao.types.VendorLicenseModelEntity(vlm1Id, VERSION01)); + Assert.assertTrue(actualVlm1.equals(expectedVlm1)); + } + + @Test(dependsOnMethods = {"updateTest"}) + public void testCreateWithRemovedVendorName() { + testCreate(); + } + + @Test(dependsOnMethods = {"updateTest"}) + public void getTest() { + org.openecomp.sdc.vendorlicense.dao.types.VendorLicenseModelEntity expectedVlm1 = + vendorLicenseModelDao.get(new org.openecomp.sdc.vendorlicense.dao.types.VendorLicenseModelEntity(vlm1Id, VERSION01)); + org.openecomp.sdc.vendorlicense.types.VersionedVendorLicenseModel actualVlm1 = + vendorLicenseManager.getVendorLicenseModel(vlm1Id, null, USER1); + + Assert.assertTrue(actualVlm1.getVendorLicenseModel().equals(expectedVlm1)); + Assert.assertEquals(actualVlm1.getVersionInfo().getActiveVersion(), VERSION01); + Assert.assertEquals(actualVlm1.getVersionInfo().getStatus(), org.openecomp.sdc.versioning.dao.types.VersionStatus.Locked); + Assert.assertEquals(actualVlm1.getVersionInfo().getLockingUser(), USER1); + } + + @Test(dependsOnMethods = {"getTest"}) + public void listTest() { + org.openecomp.sdc.vendorlicense.dao.types.VendorLicenseModelEntity vlm2 = createVendorLicenseModel("VLM2", "VLM2 dec", "icon2"); + vlm2Id = vendorLicenseManager.createVendorLicenseModel(vlm2, USER1).getId(); + vlm2.setId(vlm2Id); + + Collection loadedVlms = + vendorLicenseManager.listVendorLicenseModels(null, USER1); + boolean vlm1Exists = false; + boolean vlm2Exists = false; + for (org.openecomp.sdc.vendorlicense.types.VersionedVendorLicenseModel loadedVlm : loadedVlms) { + if (vlm1Id.equals(loadedVlm.getVendorLicenseModel().getId())) { + vlm1Exists = true; + continue; + } + if (vlm2Id.equals(loadedVlm.getVendorLicenseModel().getId())) { + Assert.assertTrue(loadedVlm.getVendorLicenseModel().equals(vlm2)); + + vlm2Exists = true; + } + } + + Assert.assertTrue(vlm1Exists); + Assert.assertTrue(vlm2Exists); + } + + @Test(dependsOnMethods = {"listTest"}) + public void listFinalVersionWhenNoneTest() { + Collection loadedVlms = + vendorLicenseManager.listVendorLicenseModels( + org.openecomp.sdc.versioning.dao.types.VersionStatus.Final.name(), USER1); + boolean vlm1Exists = false; + boolean vlm2Exists = false; + for (org.openecomp.sdc.vendorlicense.types.VersionedVendorLicenseModel loadedVlm : loadedVlms) { + if (vlm1Id.equals(loadedVlm.getVendorLicenseModel().getId())) { + vlm1Exists = true; + continue; + } + if (vlm2Id.equals(loadedVlm.getVendorLicenseModel().getId())) { + vlm2Exists = true; + } + } + + Assert.assertFalse(vlm1Exists); + Assert.assertFalse(vlm2Exists); + } + + @Test(dependsOnMethods = {"listFinalVersionWhenNoneTest"}) + + // Unsupported operation for 1607 release. +/* public void deleteTest() { + vendorLicenseManager.deleteVendorLicenseModel(vlm1Id, USER1); + + VendorLicenseModelEntity loadedVlm1 = vendorLicenseModelDao.get(new VendorLicenseModelEntity(vlm1Id, VERSION01)); + Assert.assertEquals(loadedVlm1, null); + + Collection loadedVlms = vendorLicenseModelDao.list(null); + Assert.assertTrue(loadedVlms.size() > 1); + boolean vlm1Exists = false; + boolean vlm2Exists = false; + for (VendorLicenseModelEntity loadedVlm : loadedVlms) { + if (vlm1Id.equals(loadedVlm.getId())) { + vlm1Exists = true; + } + if (vlm2Id.equals(loadedVlm.getId())) { + vlm2Exists = true; + } + } + Assert.assertFalse(vlm1Exists); + Assert.assertTrue(vlm2Exists); + } + + @Test(dependsOnMethods = {"deleteTest"})*/ + public void checkinTest() { + vendorLicenseManager.checkin(vlm2Id, USER1); + + org.openecomp.sdc.vendorlicense.types.VersionedVendorLicenseModel versionedVlm2 = + vendorLicenseManager.getVendorLicenseModel(vlm2Id, null, USER1); + Assert.assertEquals(versionedVlm2.getVersionInfo().getActiveVersion(), VERSION01); + Assert.assertEquals(versionedVlm2.getVersionInfo().getStatus(), org.openecomp.sdc.versioning.dao.types.VersionStatus.Available); + Assert.assertNull(versionedVlm2.getVersionInfo().getLockingUser()); + } + + @Test(dependsOnMethods = {"checkinTest"}) + public void checkoutTest() { + vendorLicenseManager.checkout(vlm2Id, USER2); + + org.openecomp.sdc.vendorlicense.types.VersionedVendorLicenseModel versionedVlm2 = + vendorLicenseManager.getVendorLicenseModel(vlm2Id, null, USER2); + Assert.assertEquals(versionedVlm2.getVersionInfo().getActiveVersion(), VERSION02); + Assert.assertEquals(versionedVlm2.getVersionInfo().getStatus(), org.openecomp.sdc.versioning.dao.types.VersionStatus.Locked); + Assert.assertEquals(versionedVlm2.getVersionInfo().getLockingUser(), USER2); + + versionedVlm2 = vendorLicenseManager.getVendorLicenseModel(vlm2Id, null, USER1); + Assert.assertEquals(versionedVlm2.getVersionInfo().getActiveVersion(), VERSION01); + Assert.assertEquals(versionedVlm2.getVersionInfo().getStatus(), org.openecomp.sdc.versioning.dao.types.VersionStatus.Locked); + Assert.assertEquals(versionedVlm2.getVersionInfo().getLockingUser(), USER2); + } + + @Test(dependsOnMethods = {"checkoutTest"}) + public void undoCheckoutTest() { + vendorLicenseManager.undoCheckout(vlm2Id, USER2); + + org.openecomp.sdc.vendorlicense.types.VersionedVendorLicenseModel versionedVlm2 = + vendorLicenseManager.getVendorLicenseModel(vlm2Id, null, USER2); + Assert.assertEquals(versionedVlm2.getVersionInfo().getActiveVersion(), VERSION01); + Assert.assertEquals(versionedVlm2.getVersionInfo().getStatus(), org.openecomp.sdc.versioning.dao.types.VersionStatus.Available); + Assert.assertNull(versionedVlm2.getVersionInfo().getLockingUser()); + } + + @Test(dependsOnMethods = {"undoCheckoutTest"}, expectedExceptions = CoreException.class) + public void submitUncompletedVlmNegativeTest() { + vendorLicenseManager.submit(vlm2Id, USER2); + } + + @Test(dependsOnMethods = {"submitUncompletedVlmNegativeTest"}, + expectedExceptions = CoreException.class) + public void submitUncompletedVlmMissingFGNegativeTest() { + vendorLicenseManager.checkout(vlm2Id, USER2); + org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementEntity + licenseAgreement = new org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementEntity(vlm2Id, null, null); + org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementEntity licenseAgreementEntity = + vendorLicenseManager.createLicenseAgreement(licenseAgreement, USER2); + laId = licenseAgreementEntity.getId(); + vendorLicenseManager.checkin(vlm2Id, USER2); + vendorLicenseManager.submit(vlm2Id, USER2); + } + + @Test(dependsOnMethods = {"submitUncompletedVlmMissingFGNegativeTest"}, + expectedExceptions = CoreException.class) + public void submitUncompletedVlmMissingEPNegativeTest() { + vendorLicenseManager.checkout(vlm2Id, USER2); + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity + featureGroup = new org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity(vlm2Id, null, null); + featureGroup = vendorLicenseManager.createFeatureGroup(featureGroup, USER2); + fg1Id = featureGroup.getId(); + + org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementModel licenseAgreementModel = + vendorLicenseManager.getLicenseAgreementModel(vlm2Id, null, laId, USER2); + Set fgIdSet = new HashSet<>(); + fgIdSet.add(fg1Id); + vendorLicenseManager + .updateLicenseAgreement(licenseAgreementModel.getLicenseAgreement(), fgIdSet, null, USER2); + vendorLicenseManager.checkin(vlm2Id, USER2); + vendorLicenseManager.submit(vlm2Id, USER2); + } + + @Test(dependsOnMethods = {"submitUncompletedVlmMissingEPNegativeTest"}, + expectedExceptions = CoreException.class) + public void submitUncompletedVlmMissingEPInOneFGNegativeTest() { + vendorLicenseManager.checkout(vlm2Id, USER2); + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity + featureGroup = new org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity(vlm2Id, null, null); + org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity entitlementPool = vendorLicenseManager + .createEntitlementPool(new org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity(vlm2Id, null, null), USER2); + featureGroup.getEntitlementPoolIds().add(entitlementPool.getId()); + featureGroup = vendorLicenseManager.createFeatureGroup(featureGroup, USER2); + fg2Id = featureGroup.getId(); + org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementModel licenseAgreementModel = + vendorLicenseManager.getLicenseAgreementModel(vlm2Id, null, laId, USER2); + Set fgIdSet = new HashSet<>(); + fgIdSet.add(fg2Id); + vendorLicenseManager + .updateLicenseAgreement(licenseAgreementModel.getLicenseAgreement(), fgIdSet, null, USER2); + + vendorLicenseManager.checkin(vlm2Id, USER2); + vendorLicenseManager.submit(vlm2Id, USER2); + } + + @Test(dependsOnMethods = {"submitUncompletedVlmMissingEPInOneFGNegativeTest"}) + public void submitTest() { + vendorLicenseManager.checkout(vlm2Id, USER2); + + org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity entitlementPool = vendorLicenseManager + .createEntitlementPool(new org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity(vlm2Id, null, null), USER2); + Set epSetId = new HashSet<>(); + epSetId.add(entitlementPool.getId()); + + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity + featureGroup = new org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity(vlm2Id, null, fg1Id); + featureGroup.getEntitlementPoolIds().add(entitlementPool.getId()); + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupModel featureGroupModel = + vendorLicenseManager.getFeatureGroupModel(featureGroup, USER2); + + vendorLicenseManager + .updateFeatureGroup(featureGroupModel.getFeatureGroup(), null, null, epSetId, null, USER2); + vendorLicenseManager.checkin(vlm2Id, USER2); + vendorLicenseManager.submit(vlm2Id, USER2); + + org.openecomp.sdc.vendorlicense.types.VersionedVendorLicenseModel versionedVlm2 = + vendorLicenseManager.getVendorLicenseModel(vlm2Id, null, USER1); + Assert.assertEquals(versionedVlm2.getVersionInfo().getActiveVersion(), new org.openecomp.sdc.versioning.dao.types.Version(1, 0)); + Assert.assertEquals(versionedVlm2.getVersionInfo().getStatus(), org.openecomp.sdc.versioning.dao.types.VersionStatus.Final); + Assert.assertNull(versionedVlm2.getVersionInfo().getLockingUser()); + } + + @Test(dependsOnMethods = {"submitTest"}) + public void listFinalVersionWhenOneTest() { + Collection loadedVlms = + vendorLicenseManager.listVendorLicenseModels( + org.openecomp.sdc.versioning.dao.types.VersionStatus.Final.name(), USER1); + boolean vlm2Exists = false; + for (org.openecomp.sdc.vendorlicense.types.VersionedVendorLicenseModel loadedVlm : loadedVlms) { + if (vlm2Id.equals(loadedVlm.getVendorLicenseModel().getId())) { + vlm2Exists = true; + Assert.assertEquals(loadedVlm.getVersionInfo().getActiveVersion(), new org.openecomp.sdc.versioning.dao.types.Version(1, 0)); + Assert.assertEquals(loadedVlm.getVersionInfo().getStatus(), org.openecomp.sdc.versioning.dao.types.VersionStatus.Final); + Assert.assertNull(loadedVlm.getVersionInfo().getLockingUser()); + break; + } + } + + Assert.assertTrue(vlm2Exists); + } + + @Test(dependsOnMethods = {"listFinalVersionWhenOneTest"}) + public void testVLMListWithModificationTimeDescOrder() { + org.openecomp.sdc.vendorlicense.dao.types.VendorLicenseModelEntity vlm1 = createVendorLicenseModel("test_vlm1", "desc", "icon"); + vlm3Id = vendorLicenseManager.createVendorLicenseModel(vlm1, USER3).getId(); + + org.openecomp.sdc.vendorlicense.dao.types.VendorLicenseModelEntity vlm2 = createVendorLicenseModel("test_vlm2", "desc", "icon"); + vlm4Id = vendorLicenseManager.createVendorLicenseModel(vlm2, USER3).getId(); + + assertVLMInWantedLocationInVSPList(vlm4Id, 0, USER3); + assertVLMInWantedLocationInVSPList(vlm3Id, 1, USER3); + } + + @Test(dependsOnMethods = {"testVLMListWithModificationTimeDescOrder"}) + public void testOldVLMAfterChangeShouldBeInBeginningOfList() { + org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity ep = vendorLicenseManager + .createEntitlementPool(new org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity(vlm3Id, null, null), USER3); + + assertVLMInWantedLocationInVSPList(vlm3Id, 0, USER3); + } + + @Test(dependsOnMethods = {"testOldVLMAfterChangeShouldBeInBeginningOfList"}) + public void testAddNewVLMShouldBeInBeginningOfList() { + org.openecomp.sdc.vendorlicense.dao.types.VendorLicenseModelEntity vlm = createVendorLicenseModel("test_vlm3", "desc", "icon"); + String vlm5Id = vendorLicenseManager.createVendorLicenseModel(vlm, USER3).getId(); + + assertVLMInWantedLocationInVSPList(vlm5Id, 0, USER3); + } + + @Test(dependsOnMethods = {"testAddNewVLMShouldBeInBeginningOfList"}) + public void testVLMInBeginningOfListAfterCheckin() { + vendorLicenseManager.checkin(vlm4Id, USER3); + assertVLMInWantedLocationInVSPList(vlm4Id, 0, USER3); + } + + @Test(dependsOnMethods = {"testVLMInBeginningOfListAfterCheckin"}) + public void testVLMInBeginningOfListAfterCheckout() { + vendorLicenseManager.checkin(vlm3Id, USER3); + assertVLMInWantedLocationInVSPList(vlm3Id, 0, USER3); + + vendorLicenseManager.checkout(vlm4Id, USER3); + assertVLMInWantedLocationInVSPList(vlm4Id, 0, USER3); + } + + @Test(dependsOnMethods = {"testVLMInBeginningOfListAfterCheckout"}) + public void testVLMInBeginningOfListAfterUndoCheckout() { + vendorLicenseManager.checkout(vlm3Id, USER3); + vendorLicenseManager.undoCheckout(vlm3Id, USER3); + assertVLMInWantedLocationInVSPList(vlm3Id, 0, USER3); + } + + private void assertVLMInWantedLocationInVSPList(String vlmId, int location, String user) { + List vlmList = + (List) vendorLicenseManager + .listVendorLicenseModels(null, user); + Assert.assertEquals(vlmList.get(location).getVendorLicenseModel().getId(), vlmId); + } + + +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/test/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/VendorLicenseArtifactsServiceTest.java b/openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/test/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/VendorLicenseArtifactsServiceTest.java new file mode 100644 index 0000000000..778caf3756 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-license-manager/src/test/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/VendorLicenseArtifactsServiceTest.java @@ -0,0 +1,141 @@ +package org.openecomp.sdc.vendorlicense.licenseartifacts.impl; + +import org.apache.commons.io.IOUtils; +import org.apache.commons.lang3.StringUtils; +import org.openecomp.sdc.vendorlicense.ArtifactTestUtils; +import org.openecomp.sdc.vendorlicense.dao.types.EntitlementMetric; +import org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity; +import org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyGroupEntity; +import org.openecomp.sdc.vendorlicense.dao.types.OperationalScope; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.core.utilities.file.FileContentHandler; +import org.testng.Assert; +import org.testng.annotations.BeforeClass; +import org.testng.annotations.Test; + +import java.io.IOException; +import java.nio.charset.StandardCharsets; + +public class VendorLicenseArtifactsServiceTest extends ArtifactTestUtils { + private FileContentHandler licenseArtifacts; + + + @Test + public void createVNFArtifact() throws Exception { + Version vlmVersion = vspDetails.getVlmVersion(); + licenseArtifacts = vendorLicenseArtifactsService.createLicenseArtifacts(vspDetails.getId(), vspDetails.getVendorId(), vlmVersion, vspDetails.getFeatureGroups(), USER1); + String actual = IOUtils.toString(licenseArtifacts.getFileContent( + org.openecomp.sdc.vendorlicense.VendorLicenseConstants.VNF_ARTIFACT_NAME_WITH_PATH), StandardCharsets.UTF_8); +// System.out.println("createVnfArtifact = " + actual); + + Assert.assertTrue(actual.contains("type")); + Assert.assertFalse(actual.contains(lkg13Id)); + Assert.assertTrue(actual.contains(OperationalScope.Availability_Zone.toString())); + Assert.assertTrue(actual.contains("vf-id")); + Assert.assertFalse(actual.contains(org.openecomp.sdc.vendorlicense.VendorLicenseConstants.VENDOR_LICENSE_MODEL_ARTIFACT_REGEX_REMOVE)); + Assert.assertFalse(actual.contains("80.0")); + Assert.assertTrue(actual.contains("80")); + + } + + @Test + public void createVendorLicenseArtifact() throws Exception { + Version vlmVersion = vspDetails.getVlmVersion(); + + licenseArtifacts = vendorLicenseArtifactsService.createLicenseArtifacts(vspDetails.getId(), vspDetails.getVendorId(), vlmVersion, vspDetails.getFeatureGroups(), USER1); + String actual = IOUtils.toString(licenseArtifacts.getFileContent( + org.openecomp.sdc.vendorlicense.VendorLicenseConstants.VENDOR_LICENSE_MODEL_ARTIFACT_NAME_WITH_PATH), StandardCharsets.UTF_8); + +// System.out.println("createVendorLicenseArtifact = " + actual); + Assert.assertFalse(actual.contains(lkg11Id)); + Assert.assertFalse(actual.contains(ep11Id)); + Assert.assertTrue(actual.contains("type")); + Assert.assertTrue(actual.contains(EntitlementMetric.Core.toString())); + Assert.assertTrue(actual.contains("entitlement-pool-list")); + Assert.assertFalse(actual.contains(org.openecomp.sdc.vendorlicense.VendorLicenseConstants.VENDOR_LICENSE_MODEL_ARTIFACT_REGEX_REMOVE)); + + Assert.assertTrue(actual.contains("vendor-license-model")); + Assert.assertFalse(actual.contains("80.0")); + Assert.assertTrue(actual.contains("80")); + } + + @Test + public void vNFArtifactContainsCurrentVLMVersion() throws IOException { + super.setVlm2FirstVersion(); + licenseArtifacts = vendorLicenseArtifactsService.createLicenseArtifacts(vsp2.getId(), vsp2.getVendorId(), vsp2.getVlmVersion(), vsp2.getFeatureGroups(), USER1); + String actual = IOUtils.toString(licenseArtifacts.getFileContent( + org.openecomp.sdc.vendorlicense.VendorLicenseConstants.VNF_ARTIFACT_NAME_WITH_PATH), StandardCharsets.UTF_8); + + Assert.assertTrue(actual.contains(ep21.getVersionUuId())); + } + + @Test + public void vnfArtifactContainsSameIdAsVLMArtifact() throws IOException { + Version vlmVersion = vspDetails.getVlmVersion(); + licenseArtifacts = vendorLicenseArtifactsService.createLicenseArtifacts(vspDetails.getId(), vspDetails.getVendorId(), vlmVersion, vspDetails.getFeatureGroups(), USER1); + String actualVnfArtifact = IOUtils.toString(licenseArtifacts.getFileContent( + org.openecomp.sdc.vendorlicense.VendorLicenseConstants.VNF_ARTIFACT_NAME_WITH_PATH), StandardCharsets.UTF_8); + String actualVendorLicenseArtifact = IOUtils.toString(licenseArtifacts.getFileContent( + org.openecomp.sdc.vendorlicense.VendorLicenseConstants.VENDOR_LICENSE_MODEL_ARTIFACT_NAME_WITH_PATH), StandardCharsets.UTF_8); + + String firstLKGUUID = actualVnfArtifact.substring(actualVnfArtifact.indexOf("") + 24, actualVnfArtifact.indexOf("") + 60); + Assert.assertTrue(actualVendorLicenseArtifact.contains(firstLKGUUID)); + + String firstEPUUID = actualVnfArtifact.substring(actualVnfArtifact.indexOf("<>") + 23, actualVnfArtifact.indexOf("<>") + 60); + Assert.assertTrue(actualVendorLicenseArtifact.contains(firstEPUUID)); + } + + + @Test + public void vNFArtifactContainsPreviousVLMVersionAndNotLatest() throws IOException { + super.setVlm2SecondVersion(); + licenseArtifacts = vendorLicenseArtifactsService.createLicenseArtifacts(vsp2.getId(), vsp2.getVendorId(), vsp2.getVlmVersion(), vsp2.getFeatureGroups(), USER1); + String actual = IOUtils.toString(licenseArtifacts.getFileContent( + org.openecomp.sdc.vendorlicense.VendorLicenseConstants.VNF_ARTIFACT_NAME_WITH_PATH), StandardCharsets.UTF_8); + + Assert.assertTrue(actual.contains(lkg21.getVersionUuId())); + Assert.assertTrue(actual.contains(ep21.getVersionUuId())); + Assert.assertFalse(actual.contains(lkg22Id)); + Assert.assertFalse(actual.contains(ep22Id)); + + + Assert.assertTrue(actual.contains("80")); + } + + + @Test + public void onlyAddChangedEntitiesToVendorArtifact() throws IOException { + Version vlmVersion = vspDetails.getVlmVersion(); + + EntitlementPoolEntity updatedEP = ep11; + String updatedNameEP = "updatedNameEP"; + updatedEP.setName(updatedNameEP); + LicenseKeyGroupEntity updatedLKG = new LicenseKeyGroupEntity(); + updatedLKG.setId(lkg11Id); + updatedLKG.setVendorLicenseModelId(lkg11.getVendorLicenseModelId()); + String updateDescLKG = "UpdateDescLKG"; + updatedLKG.setName(lkg11.getName()); + updatedLKG.setDescription(updateDescLKG); + + createThirdFinalVersionForVLMChangeEpLKGInSome(ep11.getVendorLicenseModelId(), updatedEP, updatedLKG); + licenseArtifacts = vendorLicenseArtifactsService.createLicenseArtifacts(vspDetails.getId(), vspDetails.getVendorId(), vlmVersion, vspDetails.getFeatureGroups(), USER1); + String actual = IOUtils.toString(licenseArtifacts.getFileContent( + org.openecomp.sdc.vendorlicense.VendorLicenseConstants.VENDOR_LICENSE_MODEL_ARTIFACT_NAME_WITH_PATH), StandardCharsets.UTF_8); +// System.out.println("onlyAddChangedEntitiesToVendorArtifact = " + actual); + + int countUpdatedLKG = StringUtils.countMatches(actual, updateDescLKG); + Assert.assertEquals(countUpdatedLKG, 1); + + int countUpdatedEp = StringUtils.countMatches(actual, updatedNameEP); + Assert.assertEquals(countUpdatedEp, 1); + + int epOccurrences = StringUtils.countMatches(actual, ""); + Assert.assertEquals(epOccurrences, 3); + } + + @BeforeClass + public void setUp() { + super.setUp(); + } +} + diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/pom.xml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/pom.xml new file mode 100644 index 0000000000..6b98e15c75 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/pom.xml @@ -0,0 +1,147 @@ + + + 4.0.0 + + + org.openecomp.sdc + backend + 1.0.0-SNAPSHOT + + + openecomp-sdc-vendor-software-product-manager + + + + com.google.code.gson + gson + 2.3.1 + test + + + org.yaml + snakeyaml + 1.14 + test + + + org.openecomp.core + openecomp-utilities-lib + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-validation-core + ${project.version} + + + org.openecomp.core + openecomp-nosqldb-core + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-vendor-software-product-core + ${project.version} + + + org.openecomp.core + openecomp-heat-lib + ${project.version} + + + org.openecomp.core + openecomp-tosca-lib + ${project.version} + + + + + org.testng + testng + 6.9.10 + test + + + junit + junit + RELEASE + test + + + org.mockito + mockito-all + 1.10.19 + test + + + + + org.openecomp.sdc + openecomp-sdc-translator-core + ${project.version} + + + com.fasterxml.jackson.dataformat + jackson-dataformat-xml + 2.7.4 + + + org.codehaus.woodstox + woodstox-core-asl + 4.4.1 + + + org.openecomp.sdc + openecomp-sdc-vendor-license-core + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-enrichment-core + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-validation-api + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-enrichment-impl + ${project.version} + + + commons-io + commons-io + ${commons.io.version} + + + org.openecomp.sdc + openecomp-sdc-model-impl + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-validation-manager + ${project.version} + test + + + + + + + org.apache.maven.plugins + maven-surefire-plugin + 2.19.1 + + true + + + + + + + \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/VendorSoftwareProductManager.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/VendorSoftwareProductManager.java new file mode 100644 index 0000000000..0d38d165c2 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/VendorSoftwareProductManager.java @@ -0,0 +1,173 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct; + +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.NetworkEntity; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.PackageInfo; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.VspDetails; +import org.openecomp.sdc.vendorsoftwareproduct.types.CompositionEntityResponse; +import org.openecomp.sdc.vendorsoftwareproduct.types.CompositionEntityValidationData; +import org.openecomp.sdc.vendorsoftwareproduct.types.QuestionnaireResponse; +import org.openecomp.sdc.vendorsoftwareproduct.types.UploadFileResponse; +import org.openecomp.sdc.vendorsoftwareproduct.types.ValidationResponse; +import org.openecomp.sdc.vendorsoftwareproduct.types.VersionedVendorSoftwareProductInfo; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.ComponentData; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.Network; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.Nic; +import org.openecomp.sdc.vendorsoftwareproduct.types.schemagenerator.MibUploadStatus; +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.io.File; +import java.io.IOException; +import java.io.InputStream; +import java.util.Collection; +import java.util.List; + +public interface VendorSoftwareProductManager { + + Version checkout(String vendorSoftwareProductId, String user); + + Version undoCheckout(String vendorSoftwareProductId, String user); + + Version checkin(String vendorSoftwareProductId, String user); + + ValidationResponse submit(String vendorSoftwareProductId, String user) throws IOException; + + + VspDetails createNewVsp(VspDetails vspDetails, String user); + + List getVspList(String versionFilter, String user); + + void updateVsp(VspDetails vspDetails, String user); + + VersionedVendorSoftwareProductInfo getVspDetails(String vspId, Version version, String user); + + void deleteVsp(String vspIdToDelete, String user); + + + UploadFileResponse uploadFile(String vspId, InputStream heatFileToUpload, String user); + + PackageInfo createPackage(String vspId, String user) throws IOException; + + List listPackages(String category, String subCategory); + + File getTranslatedFile(String vspId, Version version, String user); + + File getLatestHeatPackage(String vspId, String user); + + QuestionnaireResponse getVspQuestionnaire(String vspId, Version version, String user); + + void updateVspQuestionnaire(String vspId, String questionnaireData, String user); + + + Collection listNetworks(String vspId, Version version, String user); + + NetworkEntity createNetwork(NetworkEntity network, String user); + + CompositionEntityValidationData updateNetwork(NetworkEntity networkEntity, String user); + + CompositionEntityResponse getNetwork(String vspId, Version version, String networkId, + String user); + + void deleteNetwork(String vspId, String networkId, String user); + + + QuestionnaireResponse getComponentQuestionnaire(String vspId, Version version, String componentId, + String user); + + void updateComponentQuestionnaire(String vspId, String componentId, String questionnaireData, + String user); + + + Collection listComponents(String vspId, Version version, String user); + + void deleteComponents(String vspId, String user); + + ComponentEntity createComponent(ComponentEntity componentEntity, String user); + + CompositionEntityValidationData updateComponent(ComponentEntity componentEntity, String user); + + CompositionEntityResponse getComponent(String vspId, Version version, + String componentId, String user); + + void deleteComponent(String vspId, String componentId, String user); + + + Collection listProcesses( + String vspId, Version version, String componentId, + String user); + + void deleteProcesses(String vspId, String componentId, String user); + + org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity createProcess( + org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity processEntity, String user); + + org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity getProcess(String vspId, + Version version, + String componentId, + String processId, + String user); + + void updateProcess(org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity processEntity, + String user); + + void deleteProcess(String vspId, String componentId, String processId, String user); + + + File getProcessArtifact(String vspId, Version version, String componentId, String processId, + String user); + + void deleteProcessArtifact(String vspId, String componentId, String processId, String user); + + void uploadProcessArtifact(InputStream uploadFile, String fileName, String vspId, + String componentId, String processId, String user); + + + Collection listNics(String vspId, + Version version, + String componentId, + String user); + + org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity createNic( + org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity nic, String user); + + CompositionEntityValidationData updateNic( + org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity nicEntity, String user); + + CompositionEntityResponse getNic(String vspId, Version version, String componentId, + String nicId, String user); + + void deleteNic(String vspId, String componentId, String nicId, String user); + + QuestionnaireResponse getNicQuestionnaire(String vspId, Version version, String componentId, + String nicId, String user); + + void updateNicQuestionnaire(String vspId, String componentId, String nicId, + String questionnaireData, String user); + + void deleteComponentMib(String vspId, String componentId, boolean isTrap, String user); + + void uploadComponentMib(InputStream object, String filename, String vspId, String componentId, + boolean isTrap, String user); + + MibUploadStatus listMibFilenames(String vspId, String componentId, String user); +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/CreatePackageForNonFinalVendorSoftwareProductErrorBuilder.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/CreatePackageForNonFinalVendorSoftwareProductErrorBuilder.java new file mode 100644 index 0000000000..527530d4de --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/CreatePackageForNonFinalVendorSoftwareProductErrorBuilder.java @@ -0,0 +1,59 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.errors; + +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; +import org.openecomp.sdc.versioning.dao.types.Version; + +/** + * The type Create package for non final vendor software product error builder. + */ +public class CreatePackageForNonFinalVendorSoftwareProductErrorBuilder { + + private static final String CREATE_PACKAGE_FOR_NON_FINAL_VSP_MSG = + "Package creation for vendor software product with id %s and version %s is not allowed " + + "since it is not final (submitted)."; + private final ErrorCode.ErrorCodeBuilder builder = new ErrorCode.ErrorCodeBuilder(); + + /** + * Instantiates a new Create package for non final vendor software product error builder. + * + * @param vendorSoftwareProductId the vendor software product id + * @param version the version + */ + public CreatePackageForNonFinalVendorSoftwareProductErrorBuilder(String vendorSoftwareProductId, + Version version) { + builder.withId(VendorSoftwareProductErrorCodes.CREATE_PACKAGE_FOR_NON_FINAL_VSP); + builder.withCategory(ErrorCategory.APPLICATION); + builder.withMessage(String + .format(CREATE_PACKAGE_FOR_NON_FINAL_VSP_MSG, vendorSoftwareProductId, version.toString())); + } + + /** + * Build error code. + * + * @return the error code + */ + public ErrorCode build() { + return builder.build(); + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/FileCreationErrorBuilder.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/FileCreationErrorBuilder.java new file mode 100644 index 0000000000..5a40609270 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/FileCreationErrorBuilder.java @@ -0,0 +1,56 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.errors; + +import static org.openecomp.sdc.vendorsoftwareproduct.errors.VendorSoftwareProductErrorCodes.HEAT_PACKAGE_FILE_CREATION; + +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; + +/** + * The type File creation error builder. + */ +public class FileCreationErrorBuilder { + private static final String HEAT_PKG_FILE_CREATION_ERROR_MSG = + "Error while trying to create heat file from the package of vendor software product " + + "with Id %s."; + private final ErrorCode.ErrorCodeBuilder builder = new ErrorCode.ErrorCodeBuilder(); + + /** + * Instantiates a new File creation error builder. + * + * @param vendorSoftwareProductId the vendor software product id + */ + public FileCreationErrorBuilder(String vendorSoftwareProductId) { + builder.withId(HEAT_PACKAGE_FILE_CREATION); + builder.withCategory(ErrorCategory.SYSTEM); + builder.withMessage(String.format(HEAT_PKG_FILE_CREATION_ERROR_MSG, vendorSoftwareProductId)); + } + + /** + * Build error code. + * + * @return the error code + */ + public ErrorCode build() { + return builder.build(); + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/MibUploadErrorBuilder.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/MibUploadErrorBuilder.java new file mode 100644 index 0000000000..75a4aa3ff7 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/MibUploadErrorBuilder.java @@ -0,0 +1,59 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.errors; + +import org.openecomp.sdc.common.errors.BaseErrorBuilder; +import org.openecomp.sdc.common.errors.ErrorCategory; + +/** + * The type Mib upload error builder. + */ +public class MibUploadErrorBuilder extends BaseErrorBuilder { + private static final String UPLOAD_INVALID_DETAILED_MSG = + "MIB uploaded for vendor software product with Id %s and version %s is invalid: %s"; + + + /** + * Instantiates a new Mib upload error builder. + * + * @param vendorSoftwareProductId the vendor software product id + * @param version the version + * @param error the error + */ + public MibUploadErrorBuilder(String vendorSoftwareProductId, org.openecomp.sdc.versioning.dao + .types.Version version, String error) { + getErrorCodeBuilder().withId(VendorSoftwareProductErrorCodes.MIB_UPLOAD_INVALID); + getErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION); + getErrorCodeBuilder().withMessage(String + .format(UPLOAD_INVALID_DETAILED_MSG, vendorSoftwareProductId, version.toString(), error)); + } + + /** + * Instantiates a new Mib upload error builder. + * + * @param errorMessage the error message + */ + public MibUploadErrorBuilder(String errorMessage) { + getErrorCodeBuilder().withId(VendorSoftwareProductErrorCodes.MIB_UPLOAD_INVALID); + getErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION); + getErrorCodeBuilder().withMessage(errorMessage); + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/PackageInvalidErrorBuilder.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/PackageInvalidErrorBuilder.java new file mode 100644 index 0000000000..279dbfe4ea --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/PackageInvalidErrorBuilder.java @@ -0,0 +1,60 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.errors; + +import static org.openecomp.sdc.vendorsoftwareproduct.errors.VendorSoftwareProductErrorCodes + .PACKAGE_INVALID; + +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; +import org.openecomp.sdc.versioning.dao.types.Version; + +/** + * The type Package invalid error builder. + */ +public class PackageInvalidErrorBuilder { + private static final String PACKAGE_INVALID_MSG = + "Package for vendor software product with Id %s and version %s is invalid " + + "(does not contain translated data)."; + private final ErrorCode.ErrorCodeBuilder builder = new ErrorCode.ErrorCodeBuilder(); + + /** + * Instantiates a new Package invalid error builder. + * + * @param vendorSoftwareProductId the vendor software product id + * @param version the version + */ + public PackageInvalidErrorBuilder(String vendorSoftwareProductId, Version version) { + builder.withId(PACKAGE_INVALID); + builder.withCategory(ErrorCategory.APPLICATION); + builder.withMessage( + String.format(PACKAGE_INVALID_MSG, vendorSoftwareProductId, version.toString())); + } + + /** + * Build error code. + * + * @return the error code + */ + public ErrorCode build() { + return builder.build(); + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/PackageNotFoundErrorBuilder.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/PackageNotFoundErrorBuilder.java new file mode 100644 index 0000000000..3a32fa30b1 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/PackageNotFoundErrorBuilder.java @@ -0,0 +1,71 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.errors; + +import static org.openecomp.sdc.vendorsoftwareproduct.errors.VendorSoftwareProductErrorCodes.PACKAGE_NOT_FOUND; + +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; +import org.openecomp.sdc.versioning.dao.types.Version; + +/** + * The type Package not found error builder. + */ +public class PackageNotFoundErrorBuilder { + private static final String PACKAGE_VERSION_NOT_FOUND_MSG = + "Package for vendor software product with Id %s and version %s does not exist."; + private static final String PACKAGE_NOT_FOUND_MSG = + "Package for vendor software product with Id %s does not exist."; + private final ErrorCode.ErrorCodeBuilder builder = new ErrorCode.ErrorCodeBuilder(); + + /** + * Instantiates a new Package not found error builder. + * + * @param vendorSoftwareProductId the vendor software product id + * @param version the version + */ + public PackageNotFoundErrorBuilder(String vendorSoftwareProductId, Version version) { + builder.withId(PACKAGE_NOT_FOUND); + builder.withCategory(ErrorCategory.APPLICATION); + builder.withMessage( + String.format(PACKAGE_VERSION_NOT_FOUND_MSG, vendorSoftwareProductId, version.toString())); + } + + /** + * Instantiates a new Package not found error builder. + * + * @param vendorSoftwareProductId the vendor software product id + */ + public PackageNotFoundErrorBuilder(String vendorSoftwareProductId) { + builder.withId(PACKAGE_NOT_FOUND); + builder.withCategory(ErrorCategory.APPLICATION); + builder.withMessage(String.format(PACKAGE_NOT_FOUND_MSG, vendorSoftwareProductId)); + } + + /** + * Build error code. + * + * @return the error code + */ + public ErrorCode build() { + return builder.build(); + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/TranslationFileCreationErrorBuilder.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/TranslationFileCreationErrorBuilder.java new file mode 100644 index 0000000000..2267e1d80a --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/TranslationFileCreationErrorBuilder.java @@ -0,0 +1,60 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.errors; + +import static org.openecomp.sdc.vendorsoftwareproduct.errors.VendorSoftwareProductErrorCodes + .TRANSLATION_FILE_CREATION; + +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; +import org.openecomp.sdc.versioning.dao.types.Version; + +/** + * The type Translation file creation error builder. + */ +public class TranslationFileCreationErrorBuilder { + private static final String TRANSLATION_FILE_CREATION_ERROR_MSG = + "Error while trying to create translation file from the package of vendor software " + + "product with Id %s and version %s."; + private final ErrorCode.ErrorCodeBuilder builder = new ErrorCode.ErrorCodeBuilder(); + + /** + * Instantiates a new Translation file creation error builder. + * + * @param vendorSoftwareProductId the vendor software product id + * @param version the version + */ + public TranslationFileCreationErrorBuilder(String vendorSoftwareProductId, Version version) { + builder.withId(TRANSLATION_FILE_CREATION); + builder.withCategory(ErrorCategory.SYSTEM); + builder.withMessage(String + .format(TRANSLATION_FILE_CREATION_ERROR_MSG, vendorSoftwareProductId, version.toString())); + } + + /** + * Build error code. + * + * @return the error code + */ + public ErrorCode build() { + return builder.build(); + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/UploadInvalidErrorBuilder.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/UploadInvalidErrorBuilder.java new file mode 100644 index 0000000000..0974af1c6a --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/UploadInvalidErrorBuilder.java @@ -0,0 +1,82 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.errors; + +import static org.openecomp.sdc.vendorsoftwareproduct.errors.VendorSoftwareProductErrorCodes + .UPLOAD_INVALID; + +import org.openecomp.sdc.common.errors.BaseErrorBuilder; +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.datatypes.error.ErrorMessage; +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.util.List; +import java.util.Map; + +/** + * The type Upload invalid error builder. + */ +public class UploadInvalidErrorBuilder extends BaseErrorBuilder { + private static final String UPLOAD_INVALID_DETAILED_MSG = + "File uploaded for vendor software product with Id %s and version %s is invalid: %s"; + private static final String UPLOAD_INVALID_MSG = "Uploaded file is invalid"; + + /** + * Instantiates a new Upload invalid error builder. + * + * @param vendorSoftwareProductId the vendor software product id + * @param version the version + * @param errors the errors + */ + public UploadInvalidErrorBuilder(String vendorSoftwareProductId, Version version, + Map> errors) { + getErrorCodeBuilder().withId(UPLOAD_INVALID); + getErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION); + getErrorCodeBuilder().withMessage(String + .format(UPLOAD_INVALID_DETAILED_MSG, vendorSoftwareProductId, version.toString(), + toString(errors))); + } + + /** + * Instantiates a new Upload invalid error builder. + */ + public UploadInvalidErrorBuilder() { + getErrorCodeBuilder().withId(UPLOAD_INVALID); + getErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION); + getErrorCodeBuilder().withMessage(UPLOAD_INVALID_MSG); + } + + private String toString(Map> errors) { + StringBuffer sb = new StringBuffer(); + errors.entrySet().stream() + .forEach(entry -> singleErrorToString(sb, entry.getKey(), entry.getValue())); + return sb.toString(); + } + + private void singleErrorToString(StringBuffer sb, String fileName, List errors) { + sb.append(System.lineSeparator()); + sb.append(fileName); + sb.append(sb.append(": ")); + errors.stream().forEach( + error -> sb.append(error.getMessage()).append("[").append(error.getLevel()).append("], ")); + } + +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/VendorSoftwareProductErrorCodes.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/VendorSoftwareProductErrorCodes.java new file mode 100644 index 0000000000..369e99d75f --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/VendorSoftwareProductErrorCodes.java @@ -0,0 +1,48 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.errors; + +public class VendorSoftwareProductErrorCodes { + + public static final String VSP_NOT_FOUND = "VSP_NOT_FOUND"; + public static final String VSP_INVALID = "VSP_INVALID"; + + public static final String UPLOAD_INVALID = "UPLOAD_INVALID"; + + public static final String PACKAGE_NOT_FOUND = "PACKAGE_NOT_FOUND"; + + public static final String PACKAGE_INVALID = "PACKAGE_INVALID"; + public static final String VSP_COMPOSITION_EDIT_NOT_ALLOWED = "VSP_COMPOSITION_EDIT_NOT_ALLOWED"; + + public static final String CREATE_PACKAGE_FOR_NON_FINAL_VSP = "CREATE_PACKAGE_FOR_NON_FINAL_VSP"; + + public static final String TRANSLATION_FILE_CREATION = "TRANSLATION_FILE_CREATION"; + + public static final String HEAT_PACKAGE_FILE_CREATION = "HEAT_PACKAGE_FILE_CREATION"; + + public static final String TOSCA_ENTRY_NOT_FOUND = "TOSCA_ENTRY_NOT_FOUND"; + public static final String TOSCA_INVALID_SUBSTITUTE_NODE_TEMPLATE = + "TOSCA_INVALID_SUBSTITUTE_NODE_TEMPLATE"; + + public static final String MIB_UPLOAD_INVALID = "MIB_UPLOAD_INVALID"; + + +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/VendorSoftwareProductInvalidErrorBuilder.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/VendorSoftwareProductInvalidErrorBuilder.java new file mode 100644 index 0000000000..1439563b17 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/VendorSoftwareProductInvalidErrorBuilder.java @@ -0,0 +1,60 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.errors; + +import static org.openecomp.sdc.vendorsoftwareproduct.errors.VendorSoftwareProductErrorCodes.VSP_INVALID; + +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; +import org.openecomp.sdc.versioning.dao.types.Version; + + +/** + * The type Vendor software product invalid error builder. + */ +public class VendorSoftwareProductInvalidErrorBuilder { + private static final String VSP_INVALID_MSG = + "Vendor software product with Id %s and version %s is invalid - does not contain " + + "service model."; + private final ErrorCode.ErrorCodeBuilder builder = new ErrorCode.ErrorCodeBuilder(); + + /** + * Instantiates a new Vendor software product invalid error builder. + * + * @param vendorSoftwareProductId the vendor software product id + * @param version the version + */ + public VendorSoftwareProductInvalidErrorBuilder(String vendorSoftwareProductId, Version version) { + builder.withId(VSP_INVALID); + builder.withCategory(ErrorCategory.APPLICATION); + builder + .withMessage(String.format(VSP_INVALID_MSG, vendorSoftwareProductId, version.toString())); + } + + /** + * Build error code. + * + * @return the error code + */ + public ErrorCode build() { + return builder.build(); + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/VendorSoftwareProductNotFoundErrorBuilder.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/VendorSoftwareProductNotFoundErrorBuilder.java new file mode 100644 index 0000000000..89fc08cdb0 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/errors/VendorSoftwareProductNotFoundErrorBuilder.java @@ -0,0 +1,54 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.errors; + +import static org.openecomp.sdc.vendorsoftwareproduct.errors.VendorSoftwareProductErrorCodes.VSP_NOT_FOUND; + +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; + +/** + * The type Vendor software product not found error builder. + */ +public class VendorSoftwareProductNotFoundErrorBuilder { + private static final String VSP_FOUND_MSG = "Vendor software product with Id %s not found."; + private final ErrorCode.ErrorCodeBuilder builder = new ErrorCode.ErrorCodeBuilder(); + + /** + * Instantiates a new Vendor software product not found error builder. + * + * @param vendorSoftwareProductId the vendor software product id + */ + public VendorSoftwareProductNotFoundErrorBuilder(String vendorSoftwareProductId) { + builder.withId(VSP_NOT_FOUND); + builder.withCategory(ErrorCategory.APPLICATION); + builder.withMessage(String.format(VSP_FOUND_MSG, vendorSoftwareProductId)); + } + + /** + * Build error code. + * + * @return the error code + */ + public ErrorCode build() { + return builder.build(); + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/impl/VendorSoftwareProductManagerImpl.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/impl/VendorSoftwareProductManagerImpl.java new file mode 100644 index 0000000000..191c8d728c --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/impl/VendorSoftwareProductManagerImpl.java @@ -0,0 +1,1567 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.impl; + +import static org.openecomp.sdc.vendorsoftwareproduct.VendorSoftwareProductConstants.CSAR; +import static org.openecomp.sdc.vendorsoftwareproduct.VendorSoftwareProductConstants.GENERAL_COMPONENT_ID; +import static org.openecomp.sdc.vendorsoftwareproduct.VendorSoftwareProductConstants.UPLOAD_RAW_DATA; +import static org.openecomp.sdc.vendorsoftwareproduct.VendorSoftwareProductConstants.VENDOR_SOFTWARE_PRODUCT_VERSIONABLE_TYPE; +import static org.openecomp.sdc.vendorsoftwareproduct.VendorSoftwareProductConstants.VSP_PACKAGE_ZIP; + +import org.apache.commons.collections4.CollectionUtils; +import org.apache.commons.collections4.MapUtils; +import org.openecomp.core.enrichment.EnrichmentArtifactsServiceFactory; +import org.openecomp.core.enrichment.api.EnrichmentManager; +import org.openecomp.core.enrichment.enrichmentartifacts.EnrichmentArtifactsService; +import org.openecomp.core.enrichment.factory.EnrichmentManagerFactory; +import org.openecomp.core.enrichment.types.ComponentArtifactType; +import org.openecomp.core.model.dao.EnrichedServiceModelDao; +import org.openecomp.core.model.dao.EnrichedServiceModelDaoFactory; +import org.openecomp.core.model.dao.ServiceModelDao; +import org.openecomp.core.model.dao.ServiceModelDaoFactory; +import org.openecomp.core.model.types.ServiceElement; +import org.openecomp.core.util.UniqueValueUtil; +import org.openecomp.core.utilities.CommonMethods; +import org.openecomp.core.utilities.file.FileContentHandler; +import org.openecomp.core.utilities.file.FileUtils; +import org.openecomp.core.utilities.json.JsonSchemaDataGenerator; +import org.openecomp.core.utilities.json.JsonUtil; +import org.openecomp.core.validation.api.ValidationManager; +import org.openecomp.core.validation.errors.Messages; +import org.openecomp.core.validation.types.MessageContainerUtil; +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; +import org.openecomp.sdc.common.errors.ValidationErrorBuilder; +import org.openecomp.sdc.common.utils.AsdcCommon; +import org.openecomp.sdc.datatypes.error.ErrorLevel; +import org.openecomp.sdc.datatypes.error.ErrorMessage; +import org.openecomp.sdc.enrichment.impl.tosca.ComponentInfo; +import org.openecomp.sdc.heat.datatypes.structure.HeatStructureTree; +import org.openecomp.sdc.heat.datatypes.structure.ValidationStructureList; +import org.openecomp.sdc.heat.services.tree.HeatTreeManager; +import org.openecomp.sdc.heat.services.tree.HeatTreeManagerUtil; +import org.openecomp.sdc.tosca.datatypes.ToscaServiceModel; +import org.openecomp.sdc.tosca.services.impl.ToscaFileOutputServiceCsarImpl; +import org.openecomp.sdc.validation.utils.ValidationManagerUtil; +import org.openecomp.sdc.vendorlicense.VendorLicenseArtifactServiceFactory; +import org.openecomp.sdc.vendorlicense.facade.VendorLicenseFacade; +import org.openecomp.sdc.vendorlicense.facade.VendorLicenseFacadeFactory; +import org.openecomp.sdc.vendorlicense.licenseartifacts.VendorLicenseArtifactsService; +import org.openecomp.sdc.vendorsoftwareproduct.VendorSoftwareProductConstants; +import org.openecomp.sdc.vendorsoftwareproduct.VendorSoftwareProductManager; +import org.openecomp.sdc.vendorsoftwareproduct.dao.ComponentArtifactDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.ComponentArtifactDaoFactory; +import org.openecomp.sdc.vendorsoftwareproduct.dao.VendorSoftwareProductDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.VendorSoftwareProductDaoFactory; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentArtifactEntity; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.NetworkEntity; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.PackageInfo; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessArtifactEntity; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.UploadDataEntity; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.VspDetails; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.VspQuestionnaireEntity; +import org.openecomp.sdc.vendorsoftwareproduct.errors.CreatePackageForNonFinalVendorSoftwareProductErrorBuilder; +import org.openecomp.sdc.vendorsoftwareproduct.errors.FileCreationErrorBuilder; +import org.openecomp.sdc.vendorsoftwareproduct.errors.MibUploadErrorBuilder; +import org.openecomp.sdc.vendorsoftwareproduct.errors.PackageInvalidErrorBuilder; +import org.openecomp.sdc.vendorsoftwareproduct.errors.PackageNotFoundErrorBuilder; +import org.openecomp.sdc.vendorsoftwareproduct.errors.TranslationFileCreationErrorBuilder; +import org.openecomp.sdc.vendorsoftwareproduct.errors.UploadInvalidErrorBuilder; +import org.openecomp.sdc.vendorsoftwareproduct.errors.VendorSoftwareProductErrorCodes; +import org.openecomp.sdc.vendorsoftwareproduct.errors.VendorSoftwareProductInvalidErrorBuilder; +import org.openecomp.sdc.vendorsoftwareproduct.errors.VendorSoftwareProductNotFoundErrorBuilder; +import org.openecomp.sdc.vendorsoftwareproduct.services.CompositionDataExtractor; +import org.openecomp.sdc.vendorsoftwareproduct.services.CompositionEntityDataManager; +import org.openecomp.sdc.vendorsoftwareproduct.services.SchemaGenerator; +import org.openecomp.sdc.vendorsoftwareproduct.types.CompositionEntityResponse; +import org.openecomp.sdc.vendorsoftwareproduct.types.CompositionEntityValidationData; +import org.openecomp.sdc.vendorsoftwareproduct.types.QuestionnaireResponse; +import org.openecomp.sdc.vendorsoftwareproduct.types.QuestionnaireValidationResult; +import org.openecomp.sdc.vendorsoftwareproduct.types.UploadFileResponse; +import org.openecomp.sdc.vendorsoftwareproduct.types.ValidationResponse; +import org.openecomp.sdc.vendorsoftwareproduct.types.VersionedVendorSoftwareProductInfo; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.Component; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.ComponentData; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionData; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionEntityId; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionEntityType; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.Network; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.Nic; +import org.openecomp.sdc.vendorsoftwareproduct.types.schemagenerator.ComponentCompositionSchemaInput; +import org.openecomp.sdc.vendorsoftwareproduct.types.schemagenerator.ComponentQuestionnaireSchemaInput; +import org.openecomp.sdc.vendorsoftwareproduct.types.schemagenerator.MibUploadStatus; +import org.openecomp.sdc.vendorsoftwareproduct.types.schemagenerator.NetworkCompositionSchemaInput; +import org.openecomp.sdc.vendorsoftwareproduct.types.schemagenerator.NicCompositionSchemaInput; +import org.openecomp.sdc.vendorsoftwareproduct.types.schemagenerator.SchemaTemplateContext; +import org.openecomp.sdc.vendorsoftwareproduct.types.schemagenerator.SchemaTemplateInput; +import org.openecomp.sdc.vendorsoftwareproduct.util.CompilationUtil; +import org.openecomp.sdc.vendorsoftwareproduct.util.VendorSoftwareProductUtils; +import org.openecomp.sdc.versioning.VersioningManager; +import org.openecomp.sdc.versioning.VersioningManagerFactory; +import org.openecomp.sdc.versioning.VersioningUtil; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.dao.types.VersionStatus; +import org.openecomp.sdc.versioning.errors.RequestedVersionInvalidErrorBuilder; +import org.openecomp.sdc.versioning.types.VersionInfo; +import org.openecomp.sdc.versioning.types.VersionableEntityAction; + +import java.io.File; +import java.io.FileOutputStream; +import java.io.IOException; +import java.io.InputStream; +import java.nio.ByteBuffer; +import java.util.ArrayList; +import java.util.Collection; +import java.util.Collections; +import java.util.Comparator; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.stream.Collectors; + +/** + * The type Vendor software product manager. + */ +public class VendorSoftwareProductManagerImpl implements VendorSoftwareProductManager { + + private static final String VSP_COMPOSITION_EDIT_NOT_ALLOWED_MSG = + "Composition entities may not be created / deleted for Vendor Software Product whose " + + "entities were uploaded"; + + private static final VersioningManager versioningManager = + VersioningManagerFactory.getInstance().createInterface(); + private static final VendorSoftwareProductDao vendorSoftwareProductDao = + VendorSoftwareProductDaoFactory.getInstance().createInterface(); + private static final VendorLicenseFacade vendorLicenseFacade = + VendorLicenseFacadeFactory.getInstance().createInterface(); + private static final ComponentArtifactDao componentArtifactDao = + ComponentArtifactDaoFactory.getInstance().createInterface(); + private static final ServiceModelDao serviceModelDao = + ServiceModelDaoFactory.getInstance().createInterface(); + private static final EnrichedServiceModelDao + enrichedServiceModelDao = EnrichedServiceModelDaoFactory.getInstance().createInterface(); + private static VendorLicenseArtifactsService licenseArtifactsService = + VendorLicenseArtifactServiceFactory.getInstance().createInterface(); + private static EnrichmentArtifactsService enrichmentArtifactsService = + EnrichmentArtifactsServiceFactory.getInstance().createInterface(); + + + /** + * Instantiates a new Vendor software product manager. + */ + public VendorSoftwareProductManagerImpl() { + vendorSoftwareProductDao.registerVersioning(VENDOR_SOFTWARE_PRODUCT_VERSIONABLE_TYPE); + serviceModelDao.registerVersioning(VENDOR_SOFTWARE_PRODUCT_VERSIONABLE_TYPE); + enrichedServiceModelDao.registerVersioning(VENDOR_SOFTWARE_PRODUCT_VERSIONABLE_TYPE); + componentArtifactDao.registerVersioning(VENDOR_SOFTWARE_PRODUCT_VERSIONABLE_TYPE); + } + + private static List validateCompletedVendorSoftwareProduct(VspDetails vspDetails, + UploadDataEntity uploadData, + Object serviceModel) { + List errros = new ArrayList<>(); + + if (vspDetails.getName() == null) { + errros.add(createMissingMandatoryFieldError("name")); + } + if (vspDetails.getDescription() == null) { + errros.add(createMissingMandatoryFieldError("description")); + } + if (vspDetails.getVendorId() == null) { + errros.add(createMissingMandatoryFieldError("vendor Id")); + } + if (vspDetails.getVlmVersion() == null) { + errros.add(createMissingMandatoryFieldError( + "licensing version (in the format of: {integer}.{integer})")); + } + if (vspDetails.getCategory() == null) { + errros.add(createMissingMandatoryFieldError("category")); + } + if (vspDetails.getSubCategory() == null) { + errros.add(createMissingMandatoryFieldError("sub category")); + } + if (vspDetails.getLicenseAgreement() == null) { + errros.add(createMissingMandatoryFieldError("license agreement")); + } + if (CollectionUtils.isEmpty(vspDetails.getFeatureGroups())) { + errros.add(createMissingMandatoryFieldError("feature groups")); + } + if (uploadData == null || uploadData.getContentData() == null || serviceModel == null) { + errros.add( + new VendorSoftwareProductInvalidErrorBuilder(vspDetails.getId(), vspDetails.getVersion()) + .build()); + } + + return errros.isEmpty() ? null : errros; + } + + private static ErrorCode createMissingMandatoryFieldError(String fieldName) { + return new ValidationErrorBuilder("must be supplied", fieldName).build(); + } + + private static String getVspQuestionnaireSchema(SchemaTemplateInput schemaInput) { + return SchemaGenerator + .generate(SchemaTemplateContext.questionnaire, CompositionEntityType.vsp, schemaInput); + } + + private static String getComponentQuestionnaireSchema(SchemaTemplateInput schemaInput) { + return SchemaGenerator + .generate(SchemaTemplateContext.questionnaire, CompositionEntityType.component, + schemaInput); + } + + private static String getNicQuestionnaireSchema(SchemaTemplateInput schemaInput) { + return SchemaGenerator + .generate(SchemaTemplateContext.questionnaire, CompositionEntityType.nic, schemaInput); + } + + private static void sortVspListByModificationTimeDescOrder( + List vendorLicenseModels) { + Collections.sort(vendorLicenseModels, new Comparator() { + @Override + public int compare(VersionedVendorSoftwareProductInfo o1, + VersionedVendorSoftwareProductInfo o2) { + return o2.getVspDetails().getWritetimeMicroSeconds() + .compareTo(o1.getVspDetails().getWritetimeMicroSeconds()); + } + }); + } + + private boolean isManual(String vspId, Version version) { + return false; + } + + @Override + public Version checkout(String vendorSoftwareProductId, String user) { + Version newVersion = versioningManager + .checkout(VENDOR_SOFTWARE_PRODUCT_VERSIONABLE_TYPE, vendorSoftwareProductId, user); + vendorSoftwareProductDao.updateVspLatestModificationTime(vendorSoftwareProductId, newVersion); + return newVersion; + } + + @Override + public Version undoCheckout(String vendorSoftwareProductId, String user) { + Version newVersion = versioningManager + .undoCheckout(VENDOR_SOFTWARE_PRODUCT_VERSIONABLE_TYPE, vendorSoftwareProductId, user); + vendorSoftwareProductDao.updateVspLatestModificationTime(vendorSoftwareProductId, newVersion); + return newVersion; + } + + @Override + public Version checkin(String vendorSoftwareProductId, String user) { + Version newVersion = versioningManager + .checkin(VENDOR_SOFTWARE_PRODUCT_VERSIONABLE_TYPE, vendorSoftwareProductId, user, null); + vendorSoftwareProductDao.updateVspLatestModificationTime(vendorSoftwareProductId, newVersion); + return newVersion; + } + + @Override + public ValidationResponse submit(String vendorSoftwareProductId, String user) throws IOException { + VspDetails vspDetails = getVspDetails(vendorSoftwareProductId, null, user).getVspDetails(); + UploadDataEntity uploadData = vendorSoftwareProductDao + .getUploadData(new UploadDataEntity(vendorSoftwareProductId, vspDetails.getVersion())); + ToscaServiceModel serviceModel = + serviceModelDao.getServiceModel(vendorSoftwareProductId, vspDetails.getVersion()); + Version newVersion = null; + + ValidationResponse validationResponse = new ValidationResponse(); + validationResponse + .setVspErrors(validateCompletedVendorSoftwareProduct(vspDetails, uploadData, serviceModel)); + validationResponse.setLicensingDataErrors(validateLicensingData(vspDetails)); + validationResponse.setUploadDataErrors(validateUploadData(uploadData)); + validationResponse.setQuestionnaireValidationResult( + validateQuestionnaire(vspDetails.getId(), vspDetails.getVersion())); + validationResponse.setCompilationErrors( + compile(vendorSoftwareProductId, vspDetails.getVersion(), serviceModel)); + + if (validationResponse.isValid()) { + newVersion = versioningManager + .submit(VENDOR_SOFTWARE_PRODUCT_VERSIONABLE_TYPE, vendorSoftwareProductId, user, null); + } + //vendorSoftwareProductDao.updateVspLatestModificationTime(vendorSoftwareProductId, newVersion); + return validationResponse; + } + + private Map> compile(String vendorSoftwareProductId, Version version, + ToscaServiceModel serviceModel) { + Collection components = listComponents(vendorSoftwareProductId, version); + if (serviceModel == null) { + return null; + } + if (CollectionUtils.isEmpty(components)) { + enrichedServiceModelDao.storeServiceModel(vendorSoftwareProductId, version, serviceModel); + return null; + } + EnrichmentManager enrichmentManager = + EnrichmentManagerFactory.getInstance().createInterface(); + enrichmentManager.initInput(vendorSoftwareProductId, version); + enrichmentManager.addModel(serviceModel); + + ComponentInfo componentInfo = new ComponentInfo(); + Map> compileErrors = new HashMap<>(); + CompilationUtil.addMonitoringInfo(componentInfo, compileErrors); + for (ComponentEntity componentEntity : components) { + ComponentInfo currentEntityComponentInfo = new ComponentInfo(); + currentEntityComponentInfo.setCeilometerInfo(componentInfo.getCeilometerInfo()); + CompilationUtil + .addMibInfo(vendorSoftwareProductId, version, componentEntity, currentEntityComponentInfo, + compileErrors); + enrichmentManager.addEntityInput(componentEntity.getComponentCompositionData().getName(), + currentEntityComponentInfo); + + } + Map> enrichErrors; + enrichErrors = enrichmentManager.enrich(); + enrichedServiceModelDao + .storeServiceModel(vendorSoftwareProductId, version, enrichmentManager.getModel()); + if (enrichErrors != null) { + compileErrors.putAll(enrichErrors); + } + + vendorSoftwareProductDao.updateVspLatestModificationTime(vendorSoftwareProductId, version); + + return compileErrors; + } + + private Collection validateLicensingData(VspDetails vspDetails) { + if (vspDetails.getVendorId() == null || vspDetails.getVlmVersion() == null + || vspDetails.getLicenseAgreement() == null + || CollectionUtils.isEmpty(vspDetails.getFeatureGroups())) { + return null; + } + return vendorLicenseFacade + .validateLicensingData(vspDetails.getVendorId(), vspDetails.getVlmVersion(), + vspDetails.getLicenseAgreement(), vspDetails.getFeatureGroups()); + } + + @Override + public VspDetails createNewVsp(VspDetails vspDetails, String user) { + UniqueValueUtil.validateUniqueValue( + VendorSoftwareProductConstants.UniqueValues.VENDOR_SOFTWARE_PRODUCT_NAME, + vspDetails.getName()); + vspDetails.setId(CommonMethods.nextUuId()); + + // vspDetails.setLastModificationTime(new Date()); + + Version version = versioningManager + .create(VENDOR_SOFTWARE_PRODUCT_VERSIONABLE_TYPE, vspDetails.getId(), user); + vspDetails.setVersion(version); + + // vspDetails.setLastModificationTime(new Date()); + + vendorSoftwareProductDao.createVendorSoftwareProductInfo(vspDetails); + vendorSoftwareProductDao.updateQuestionnaire(vspDetails.getId(), version, + new JsonSchemaDataGenerator(getVspQuestionnaireSchema(null)).generateData()); + UniqueValueUtil + .createUniqueValue(VendorSoftwareProductConstants.UniqueValues.VENDOR_SOFTWARE_PRODUCT_NAME, + vspDetails.getName()); + + return vspDetails; + } + + @Override + public List getVspList(String versionFilter, String user) { + Map idToVersionsInfo = versioningManager + .listEntitiesVersionInfo(VENDOR_SOFTWARE_PRODUCT_VERSIONABLE_TYPE, user, + VersionableEntityAction.Read); + + List vsps = new ArrayList<>(); + for (Map.Entry entry : idToVersionsInfo.entrySet()) { + VersionInfo versionInfo = entry.getValue(); + if (versionFilter != null && versionFilter.equals(VersionStatus.Final.name())) { + if (versionInfo.getLatestFinalVersion() == null) { + continue; + } + versionInfo.setActiveVersion(versionInfo.getLatestFinalVersion()); + versionInfo.setStatus(VersionStatus.Final); + versionInfo.setLockingUser(null); + } + + VspDetails vsp = vendorSoftwareProductDao.getVendorSoftwareProductInfo( + new VspDetails(entry.getKey(), entry.getValue().getActiveVersion())); + if (vsp != null) { + vsp.setValidationDataStructure(null); + vsps.add(new VersionedVendorSoftwareProductInfo(vsp, entry.getValue())); + } + } + + sortVspListByModificationTimeDescOrder(vsps); + return vsps; + } + + @Override + public void updateVsp(VspDetails vspDetails, String user) { + Version activeVersion = + getVersionInfo(vspDetails.getId(), VersionableEntityAction.Write, user).getActiveVersion(); + vspDetails.setVersion(activeVersion); + // vspDetails.setLastModificationTime(new Date()); + + VspDetails retrieved = vendorSoftwareProductDao.getVendorSoftwareProductInfo(vspDetails); + vspDetails.setValidationData(retrieved.getValidationData()); + UniqueValueUtil + .updateUniqueValue(VendorSoftwareProductConstants.UniqueValues.VENDOR_SOFTWARE_PRODUCT_NAME, + retrieved.getName(), vspDetails.getName()); + vendorSoftwareProductDao.updateVendorSoftwareProductInfo(vspDetails); + + vendorSoftwareProductDao.updateVspLatestModificationTime(vspDetails.getId(), activeVersion); + } + + @Override + public VersionedVendorSoftwareProductInfo getVspDetails(String vspId, Version version, + String user) { + VersionInfo versionInfo = getVersionInfo(vspId, VersionableEntityAction.Read, user); + if (version == null) { + version = versionInfo.getActiveVersion(); + } else { + if (!versionInfo.getViewableVersions().contains(version)) { + throw new CoreException(new RequestedVersionInvalidErrorBuilder().build()); + } + } + + VspDetails vendorSoftwareProductInfo = + vendorSoftwareProductDao.getVendorSoftwareProductInfo(new VspDetails(vspId, version)); + if (vendorSoftwareProductInfo == null) { + throw new CoreException(new VendorSoftwareProductNotFoundErrorBuilder(vspId).build()); + } + return new VersionedVendorSoftwareProductInfo(vendorSoftwareProductInfo, versionInfo); + } + + @Override + public void deleteVsp(String vspId, String user) { + throw new UnsupportedOperationException("Unsupported operation for 1607 release."); + } + + @Override + public UploadFileResponse uploadFile(String vspId, InputStream heatFileToUpload, String user) { + Version activeVersion = + getVersionInfo(vspId, VersionableEntityAction.Write, user).getActiveVersion(); + UploadFileResponse uploadFileResponse = new UploadFileResponse(); + + if (heatFileToUpload == null) { + uploadFileResponse.addStructureError(AsdcCommon.UPLOAD_FILE, + new ErrorMessage(ErrorLevel.ERROR, + Messages.NO_ZIP_FILE_WAS_UPLOADED_OR_ZIP_NOT_EXIST.getErrorMessage())); + return uploadFileResponse; + } + + InputStream uploadedFileData; + FileContentHandler fileContentMap; + Map> errors = new HashMap<>(); + try { + fileContentMap = getContent(heatFileToUpload, errors); + if (!errors.isEmpty()) { + return addStructureErrorsToResponse(uploadFileResponse, errors); + } + + uploadedFileData = fileContentMap.getFileContent(UPLOAD_RAW_DATA); + fileContentMap.remove(UPLOAD_RAW_DATA); + + ValidationManagerUtil.handleMissingManifest(fileContentMap, errors); + if (!errors.isEmpty()) { + return addStructureErrorsToResponse(uploadFileResponse, errors); + } + + } catch (CoreException ce) { + ErrorMessage.ErrorMessageUtil.addMessage(AsdcCommon.UPLOAD_FILE, errors) + .add(new ErrorMessage(ErrorLevel.ERROR, ce.getMessage())); + return addStructureErrorsToResponse(uploadFileResponse, errors); + } + + HeatStructureTree tree = createAndValidateHeatTree(uploadFileResponse, fileContentMap); + + deleteUploadDataAndContent(vspId, activeVersion); + saveHotData(vspId, activeVersion, uploadedFileData, fileContentMap, tree); + + vendorSoftwareProductDao.updateVspLatestModificationTime(vspId, activeVersion); + + ToscaServiceModel toscaServiceModel = + VendorSoftwareProductUtils.loadAndTranslateTemplateData(fileContentMap) + .getToscaServiceModel(); + if (toscaServiceModel != null) { + serviceModelDao.storeServiceModel(vspId, activeVersion, toscaServiceModel); + saveCompositionData(vspId, activeVersion, + CompositionDataExtractor.extractServiceCompositionData(toscaServiceModel)); + } + + return uploadFileResponse; + } + + private UploadFileResponse addStructureErrorsToResponse(UploadFileResponse uploadFileResponse, + Map> errors) { + uploadFileResponse.addStructureErrors(errors); + return uploadFileResponse; + } + + private HeatStructureTree createAndValidateHeatTree(UploadFileResponse uploadFileResponse, + FileContentHandler fileContentMap) { + VendorSoftwareProductUtils.addFileNamesToUploadFileResponse(fileContentMap, uploadFileResponse); + Map> validationErrors = + ValidationManagerUtil.initValidationManager(fileContentMap).validate(); + uploadFileResponse.getErrors().putAll(validationErrors); + + HeatTreeManager heatTreeManager = HeatTreeManagerUtil.initHeatTreeManager(fileContentMap); + heatTreeManager.createTree(); + heatTreeManager.addErrors(validationErrors); + return heatTreeManager.getTree(); + } + + private void saveHotData(String vspId, Version activeVersion, InputStream uploadedFileData, + FileContentHandler fileContentMap, HeatStructureTree tree) { + Map manifestAsMap = (Map) JsonUtil + .json2Object(fileContentMap.getFileContent(AsdcCommon.MANIFEST_NAME), Map.class); + + UploadDataEntity uploadData = new UploadDataEntity(vspId, activeVersion); + uploadData.setPackageName((String) manifestAsMap.get("name")); + uploadData.setPackageVersion((String) manifestAsMap.get("version")); + uploadData.setContentData(ByteBuffer.wrap(FileUtils.toByteArray(uploadedFileData))); + uploadData.setValidationDataStructure(new ValidationStructureList(tree)); + vendorSoftwareProductDao.updateUploadData(uploadData); + } + + private FileContentHandler getContent(InputStream heatFileToUpload, + Map> errors) { + FileContentHandler contentMap = null; + byte[] uploadedFileData; + try { + uploadedFileData = FileUtils.toByteArray(heatFileToUpload); + VendorSoftwareProductUtils.validateRawZipData(uploadedFileData, errors); + contentMap = VendorSoftwareProductUtils.loadUploadFileContent(uploadedFileData); + VendorSoftwareProductUtils.validateContentZipData(contentMap, errors); + contentMap.addFile(UPLOAD_RAW_DATA, uploadedFileData); + } catch (IOException e0) { + ErrorMessage.ErrorMessageUtil.addMessage(AsdcCommon.UPLOAD_FILE, errors) + .add(new ErrorMessage(ErrorLevel.ERROR, Messages.INVALID_ZIP_FILE.getErrorMessage())); + } + return contentMap; + } + + private void validateMibZipContent(String vspId, Version version, byte[] uploadedFileData, + Map> errors) { + FileContentHandler contentMap; + try { + contentMap = VendorSoftwareProductUtils.loadUploadFileContent(uploadedFileData); + VendorSoftwareProductUtils.validateContentZipData(contentMap, errors); + } catch (IOException e0) { + throw new CoreException( + new MibUploadErrorBuilder(vspId, version, Messages.INVALID_ZIP_FILE.getErrorMessage()) + .build()); + } + } + + @Override + public List listPackages(String category, String subCategory) { + return vendorSoftwareProductDao.listPackages(category, subCategory); + } + + @Override + public File getTranslatedFile(String vspId, Version version, String user) { + VersionInfo versionInfo = getVersionInfo(vspId, VersionableEntityAction.Read, user); + if (version == null) { + if (versionInfo.getLatestFinalVersion() == null) { + throw new CoreException(new PackageNotFoundErrorBuilder(vspId).build()); + } + version = versionInfo.getLatestFinalVersion(); + } else { + if (!version.isFinal() || !versionInfo.getViewableVersions().contains(version)) { + throw new CoreException(new RequestedVersionInvalidErrorBuilder().build()); + } + } + + PackageInfo packageInfo = + vendorSoftwareProductDao.getPackageInfo(new PackageInfo(vspId, version)); + if (packageInfo == null) { + throw new CoreException(new PackageNotFoundErrorBuilder(vspId, version).build()); + } + + ByteBuffer translatedFileBuffer = packageInfo.getTranslatedFile(); + if (translatedFileBuffer == null) { + throw new CoreException(new PackageInvalidErrorBuilder(vspId, version).build()); + } + + File translatedFile = new File(VSP_PACKAGE_ZIP); + + try { + FileOutputStream fos = new FileOutputStream(translatedFile); + fos.write(translatedFileBuffer.array()); + fos.close(); + } catch (IOException e0) { + throw new CoreException(new TranslationFileCreationErrorBuilder(vspId, version).build(), e0); + } + + return translatedFile; + } + + @Override + public File getLatestHeatPackage(String vspId, + String user) { //todo remove the writing to file system.. + VersionInfo versionInfo = getVersionInfo(vspId, VersionableEntityAction.Read, user); + Version version = versionInfo.getActiveVersion(); + + UploadDataEntity uploadData = + vendorSoftwareProductDao.getUploadData(new UploadDataEntity(vspId, version)); + + ByteBuffer contentData = uploadData.getContentData(); + if (contentData == null) { + return null; + } + + File heatPkgFile = new File(String.format("heats-for-%s.zip", vspId)); + + try { + FileOutputStream fos = new FileOutputStream(heatPkgFile); + fos.write(contentData.array()); + fos.close(); + } catch (IOException e0) { + throw new CoreException(new FileCreationErrorBuilder(vspId).build(), e0); + } + return heatPkgFile; + } + + @Override + public PackageInfo createPackage(String vspId, String user) throws IOException { + VersionInfo versionInfo = getVersionInfo(vspId, VersionableEntityAction.Read, user); + Version activeVersion = versionInfo.getActiveVersion(); + if (!activeVersion.isFinal()) { + throw new CoreException( + new CreatePackageForNonFinalVendorSoftwareProductErrorBuilder(vspId, activeVersion) + .build()); + } + + ToscaServiceModel toscaServiceModel = + enrichedServiceModelDao.getServiceModel(vspId, activeVersion); + VspDetails vspDetails = + vendorSoftwareProductDao.getVendorSoftwareProductInfo(new VspDetails(vspId, activeVersion)); + Version vlmVersion = vspDetails.getVlmVersion(); + + PackageInfo packageInfo = createPackageInfo(vspId, vspDetails); + + ToscaFileOutputServiceCsarImpl toscaServiceTemplateServiceCsar = + new ToscaFileOutputServiceCsarImpl(); + FileContentHandler licenseArtifacts = licenseArtifactsService + .createLicenseArtifacts(vspDetails.getId(), vspDetails.getVendorId(), vlmVersion, + vspDetails.getFeatureGroups(), user); + //todo add tosca validation here + packageInfo.setTranslatedFile(ByteBuffer.wrap( + toscaServiceTemplateServiceCsar.createOutputFile(toscaServiceModel, licenseArtifacts))); + + vendorSoftwareProductDao.insertPackageDetails(packageInfo); + + vendorSoftwareProductDao.updateVspLatestModificationTime(vspId, vspDetails.getVersion()); + + return packageInfo; + } + + private PackageInfo createPackageInfo(String vspId, VspDetails vspDetails) { + PackageInfo packageInfo = new PackageInfo(); + packageInfo.setVspId(vspId); + packageInfo.setVersion(vspDetails.getVersion()); + packageInfo.setDisplayName(vspDetails.getPackageName()); + packageInfo.setVspName(vspDetails.getName()); + packageInfo.setVspDescription(vspDetails.getDescription()); + packageInfo.setCategory(vspDetails.getCategory()); + packageInfo.setSubCategory(vspDetails.getSubCategory()); + packageInfo.setVendorName(vspDetails.getVendorName()); + packageInfo.setPackageType(CSAR); + packageInfo.setVendorRelease("1.0"); //todo TBD + return packageInfo; + } + + @Override + public QuestionnaireResponse getVspQuestionnaire(String vspId, Version version, String user) { + version = VersioningUtil + .resolveVersion(version, getVersionInfo(vspId, VersionableEntityAction.Read, user)); + + QuestionnaireResponse questionnaireResponse = new QuestionnaireResponse(); + questionnaireResponse.setData(getVspQuestionnaire(vspId, version).getQuestionnaireData()); + questionnaireResponse.setSchema(getVspQuestionnaireSchema(null)); + + return questionnaireResponse; + } + + private VspQuestionnaireEntity getVspQuestionnaire(String vspId, Version version) { + VspQuestionnaireEntity retrieved = vendorSoftwareProductDao.getQuestionnaire(vspId, version); + VersioningUtil.validateEntityExistence(retrieved, new VspQuestionnaireEntity(vspId, version), + VspDetails.ENTITY_TYPE); + return retrieved; + } + + @Override + public void updateVspQuestionnaire(String vspId, String questionnaireData, String user) { + Version activeVersion = + getVersionInfo(vspId, VersionableEntityAction.Write, user).getActiveVersion(); + + vendorSoftwareProductDao.updateVspLatestModificationTime(vspId, activeVersion); + + vendorSoftwareProductDao.updateQuestionnaire(vspId, activeVersion, questionnaireData); + } + + @Override + public Collection listNetworks(String vspId, Version version, String user) { + version = VersioningUtil + .resolveVersion(version, getVersionInfo(vspId, VersionableEntityAction.Read, user)); + return listNetworks(vspId, version); + } + + private Collection listNetworks(String vspId, Version version) { + return vendorSoftwareProductDao.listNetworks(vspId, version); + } + + @Override + public NetworkEntity createNetwork(NetworkEntity network, String user) { + Version activeVersion = + getVersionInfo(network.getVspId(), VersionableEntityAction.Write, user).getActiveVersion(); + network.setVersion(activeVersion); + if (!isManual(network.getVspId(), activeVersion)) { + throw new CoreException( + new ErrorCode.ErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION) + .withId(VendorSoftwareProductErrorCodes.VSP_COMPOSITION_EDIT_NOT_ALLOWED) + .withMessage(VSP_COMPOSITION_EDIT_NOT_ALLOWED_MSG).build()); + } + + vendorSoftwareProductDao.updateVspLatestModificationTime(network.getVspId(), activeVersion); + return null; + } + + private NetworkEntity createNetwork(NetworkEntity network) { + network.setId(CommonMethods.nextUuId()); + vendorSoftwareProductDao.createNetwork(network); + + return network; + } + + @Override + public CompositionEntityValidationData updateNetwork(NetworkEntity network, String user) { + Version activeVersion = + getVersionInfo(network.getVspId(), VersionableEntityAction.Write, user).getActiveVersion(); + network.setVersion(activeVersion); + NetworkEntity retrieved = getNetwork(network.getVspId(), activeVersion, network.getId()); + + NetworkCompositionSchemaInput schemaInput = new NetworkCompositionSchemaInput(); + schemaInput.setManual(isManual(network.getVspId(), activeVersion)); + schemaInput.setNetwork(retrieved.getNetworkCompositionData()); + + CompositionEntityValidationData validationData = CompositionEntityDataManager + .validateEntity(network, SchemaTemplateContext.composition, schemaInput); + if (CollectionUtils.isEmpty(validationData.getErrors())) { + vendorSoftwareProductDao.updateNetwork(network); + } + + vendorSoftwareProductDao.updateVspLatestModificationTime(network.getVspId(), activeVersion); + + return validationData; + } + + @Override + public CompositionEntityResponse getNetwork(String vspId, Version version, + String networkId, String user) { + version = VersioningUtil + .resolveVersion(version, getVersionInfo(vspId, VersionableEntityAction.Read, user)); + NetworkEntity networkEntity = getNetwork(vspId, version, networkId); + Network network = networkEntity.getNetworkCompositionData(); + + NetworkCompositionSchemaInput schemaInput = new NetworkCompositionSchemaInput(); + schemaInput.setManual(isManual(vspId, version)); + schemaInput.setNetwork(network); + + CompositionEntityResponse response = new CompositionEntityResponse<>(); + response.setId(networkId); + response.setData(network); + response.setSchema(SchemaGenerator + .generate(SchemaTemplateContext.composition, CompositionEntityType.network, schemaInput)); + + return response; + } + + private NetworkEntity getNetwork(String vspId, Version version, String networkId) { + NetworkEntity retrieved = vendorSoftwareProductDao.getNetwork(vspId, version, networkId); + VersioningUtil.validateEntityExistence(retrieved, new NetworkEntity(vspId, version, networkId), + VspDetails.ENTITY_TYPE); + return retrieved; + } + + @Override + public void deleteNetwork(String vspId, String networkId, String user) { + Version activeVersion = + getVersionInfo(vspId, VersionableEntityAction.Write, user).getActiveVersion(); + if (!isManual(vspId, activeVersion)) { + throw new CoreException( + new ErrorCode.ErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION) + .withId(VendorSoftwareProductErrorCodes.VSP_COMPOSITION_EDIT_NOT_ALLOWED) + .withMessage(VSP_COMPOSITION_EDIT_NOT_ALLOWED_MSG).build()); + } + + vendorSoftwareProductDao.updateVspLatestModificationTime(vspId, activeVersion); + } + + @Override + public QuestionnaireResponse getComponentQuestionnaire(String vspId, Version version, + String componentId, String user) { + version = VersioningUtil + .resolveVersion(version, getVersionInfo(vspId, VersionableEntityAction.Read, user)); + + QuestionnaireResponse questionnaireResponse = new QuestionnaireResponse(); + questionnaireResponse.setData(getComponent(vspId, version, componentId).getQuestionnaireData()); + List nicNames = listNics(vspId, version, componentId).stream() + .map(nic -> nic.getNicCompositionData().getName()).collect(Collectors.toList()); + questionnaireResponse.setSchema(getComponentQuestionnaireSchema( + new ComponentQuestionnaireSchemaInput(nicNames, + JsonUtil.json2Object(questionnaireResponse.getData(), Map.class)))); + + return questionnaireResponse; + } + + @Override + public void updateComponentQuestionnaire(String vspId, String componentId, + String questionnaireData, String user) { + Version activeVersion = + getVersionInfo(vspId, VersionableEntityAction.Write, user).getActiveVersion(); + getComponent(vspId, activeVersion, componentId); + + vendorSoftwareProductDao + .updateComponentQuestionnaire(vspId, activeVersion, componentId, questionnaireData); + + vendorSoftwareProductDao.updateVspLatestModificationTime(vspId, activeVersion); + } + + @Override + public Collection listComponents(String vspId, Version version, String user) { + version = VersioningUtil + .resolveVersion(version, getVersionInfo(vspId, VersionableEntityAction.Read, user)); + return listComponents(vspId, version); + } + + private Collection listComponents(String vspId, Version version) { + return vendorSoftwareProductDao.listComponents(vspId, version); + } + + @Override + public void deleteComponents(String vspId, String user) { + Version activeVersion = + getVersionInfo(vspId, VersionableEntityAction.Write, user).getActiveVersion(); + if (!isManual(vspId, activeVersion)) { + throw new CoreException( + new ErrorCode.ErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION) + .withId(VendorSoftwareProductErrorCodes.VSP_COMPOSITION_EDIT_NOT_ALLOWED) + .withMessage(VSP_COMPOSITION_EDIT_NOT_ALLOWED_MSG).build()); + } + + vendorSoftwareProductDao.updateVspLatestModificationTime(vspId, activeVersion); + } + + @Override + public ComponentEntity createComponent(ComponentEntity component, String user) { + Version activeVersion = + getVersionInfo(component.getVspId(), VersionableEntityAction.Write, user) + .getActiveVersion(); + component.setVersion(activeVersion); + + if (!isManual(component.getVspId(), activeVersion)) { + throw new CoreException( + new ErrorCode.ErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION) + .withId(VendorSoftwareProductErrorCodes.VSP_COMPOSITION_EDIT_NOT_ALLOWED) + .withMessage(VSP_COMPOSITION_EDIT_NOT_ALLOWED_MSG).build()); + + } + + /* ComponentCompositionSchemaInput schemaInput = new ComponentCompositionSchemaInput(); + schemaInput.setManual(true); + CompositionEntityValidationData validationData = CompositionEntityDataManager + .validateEntity(component, SchemaTemplateContext.composition, schemaInput); + if (CollectionUtils.isEmpty(validationData.getErrors())) { + return createComponent(component); + } + return validationData;*/ + + vendorSoftwareProductDao.updateVspLatestModificationTime(component.getVspId(), activeVersion); + + return null; + } + + private ComponentEntity createComponent(ComponentEntity component) { + component.setId(CommonMethods.nextUuId()); + component.setQuestionnaireData( + new JsonSchemaDataGenerator(getComponentQuestionnaireSchema(null)).generateData()); + + vendorSoftwareProductDao.createComponent(component); + + return component; + } + + @Override + public CompositionEntityResponse getComponent(String vspId, Version version, + String componentId, String user) { + version = VersioningUtil + .resolveVersion(version, getVersionInfo(vspId, VersionableEntityAction.Read, user)); + ComponentEntity componentEntity = getComponent(vspId, version, componentId); + ComponentData component = componentEntity.getComponentCompositionData(); + + ComponentCompositionSchemaInput schemaInput = new ComponentCompositionSchemaInput(); + schemaInput.setManual(isManual(vspId, version)); + schemaInput.setComponent(component); + + CompositionEntityResponse response = new CompositionEntityResponse<>(); + response.setId(componentId); + response.setData(component); + response.setSchema(SchemaGenerator + .generate(SchemaTemplateContext.composition, CompositionEntityType.component, schemaInput)); + + return response; + } + + private ComponentEntity getComponent(String vspId, Version version, String componentId) { + ComponentEntity retrieved = vendorSoftwareProductDao.getComponent(vspId, version, componentId); + VersioningUtil + .validateEntityExistence(retrieved, new ComponentEntity(vspId, version, componentId), + VspDetails.ENTITY_TYPE); + return retrieved; + } + + @Override + public CompositionEntityValidationData updateComponent(ComponentEntity component, String user) { + Version activeVersion = + getVersionInfo(component.getVspId(), VersionableEntityAction.Write, user) + .getActiveVersion(); + component.setVersion(activeVersion); + ComponentEntity retrieved = + getComponent(component.getVspId(), activeVersion, component.getId()); + + ComponentCompositionSchemaInput schemaInput = new ComponentCompositionSchemaInput(); + schemaInput.setManual(isManual(component.getVspId(), activeVersion)); + schemaInput.setComponent(retrieved.getComponentCompositionData()); + + CompositionEntityValidationData validationData = CompositionEntityDataManager + .validateEntity(component, SchemaTemplateContext.composition, schemaInput); + if (CollectionUtils.isEmpty(validationData.getErrors())) { + vendorSoftwareProductDao.updateComponent(component); + } + + vendorSoftwareProductDao.updateVspLatestModificationTime(component.getVspId(), activeVersion); + + return validationData; + } + + @Override + public void deleteComponent(String vspId, String componentId, String user) { + Version activeVersion = + getVersionInfo(vspId, VersionableEntityAction.Write, user).getActiveVersion(); + if (!isManual(vspId, activeVersion)) { + throw new CoreException( + new ErrorCode.ErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION) + .withId(VendorSoftwareProductErrorCodes.VSP_COMPOSITION_EDIT_NOT_ALLOWED) + .withMessage(VSP_COMPOSITION_EDIT_NOT_ALLOWED_MSG).build()); + } + + vendorSoftwareProductDao.updateVspLatestModificationTime(vspId, activeVersion); + } + + @Override + public Collection listProcesses( + String vspId, Version version, String componentId, + String user) { + version = VersioningUtil + .resolveVersion(version, getVersionInfo(vspId, VersionableEntityAction.Read, user)); + if (!GENERAL_COMPONENT_ID.equals(componentId)) { + getComponent(vspId, version, componentId); + } + return vendorSoftwareProductDao.listProcesses(vspId, version, componentId); + } + + @Override + public void deleteProcesses(String vspId, String componentId, String user) { + Version activeVersion = + getVersionInfo(vspId, VersionableEntityAction.Write, user).getActiveVersion(); + if (!GENERAL_COMPONENT_ID.equals(componentId)) { + getComponent(vspId, activeVersion, componentId); + } + + Collection processes = + vendorSoftwareProductDao.listProcesses(vspId, activeVersion, componentId); + for (org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity process : processes) { + UniqueValueUtil.deleteUniqueValue(VendorSoftwareProductConstants.UniqueValues.PROCESS_NAME, + process.getVspId(), process.getVersion().toString(), process.getComponentId(), + process.getName()); + } + + vendorSoftwareProductDao.deleteProcesses(vspId, activeVersion, componentId); + + vendorSoftwareProductDao.updateVspLatestModificationTime(vspId, activeVersion); + } + + @Override + public org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity createProcess( + org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity process, String user) { + Version activeVersion = + getVersionInfo(process.getVspId(), VersionableEntityAction.Write, user).getActiveVersion(); + process.setVersion(activeVersion); + UniqueValueUtil.validateUniqueValue(VendorSoftwareProductConstants.UniqueValues.PROCESS_NAME, + process.getVspId(), process.getVersion().toString(), process.getComponentId(), + process.getName()); + process.setId(CommonMethods.nextUuId()); + if (!GENERAL_COMPONENT_ID.equals(process.getComponentId())) { + getComponent(process.getVspId(), activeVersion, process.getComponentId()); + } + + vendorSoftwareProductDao.createProcess(process); + UniqueValueUtil.createUniqueValue(VendorSoftwareProductConstants.UniqueValues.PROCESS_NAME, + process.getVspId(), process.getVersion().toString(), process.getComponentId(), + process.getName()); + + vendorSoftwareProductDao.updateVspLatestModificationTime(process.getVspId(), activeVersion); + return process; + } + + @Override + public org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity getProcess(String vspId, + Version version, + String componentId, + String processId, + String user) { + version = VersioningUtil + .resolveVersion(version, getVersionInfo(vspId, VersionableEntityAction.Read, user)); + org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity retrieved = + vendorSoftwareProductDao.getProcess(vspId, version, componentId, processId); + validateProcessExistence(vspId, version, componentId, processId, retrieved); + return retrieved; + } + + @Override + public void updateProcess(org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity process, + String user) { + Version activeVersion = + getVersionInfo(process.getVspId(), VersionableEntityAction.Write, user).getActiveVersion(); + process.setVersion(activeVersion); + + org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity retrieved = + vendorSoftwareProductDao + .getProcess(process.getVspId(), activeVersion, process.getComponentId(), + process.getId()); + validateProcessExistence(process.getVspId(), activeVersion, process.getComponentId(), + process.getId(), retrieved); + + UniqueValueUtil.updateUniqueValue(VendorSoftwareProductConstants.UniqueValues.PROCESS_NAME, + retrieved.getName(), process.getName(), process.getVspId(), process.getVersion().toString(), + process.getComponentId()); + vendorSoftwareProductDao.updateProcess(process); + + vendorSoftwareProductDao.updateVspLatestModificationTime(process.getVspId(), activeVersion); + } + + @Override + public void deleteProcess(String vspId, String componentId, String processId, String user) { + Version activeVersion = + getVersionInfo(vspId, VersionableEntityAction.Write, user).getActiveVersion(); + org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity retrieved = + vendorSoftwareProductDao.getProcess(vspId, activeVersion, componentId, processId); + validateProcessExistence(vspId, activeVersion, componentId, processId, retrieved); + + vendorSoftwareProductDao.deleteProcess(vspId, activeVersion, componentId, processId); + UniqueValueUtil.deleteUniqueValue(VendorSoftwareProductConstants.UniqueValues.PROCESS_NAME, + retrieved.getVspId(), retrieved.getVersion().toString(), retrieved.getComponentId(), + retrieved.getName()); + + vendorSoftwareProductDao.updateVspLatestModificationTime(vspId, activeVersion); + } + + @Override + public File getProcessArtifact(String vspId, Version version, String componentId, + String processId, String user) { + version = VersioningUtil + .resolveVersion(version, getVersionInfo(vspId, VersionableEntityAction.Read, user)); + ProcessArtifactEntity retrieved = + vendorSoftwareProductDao.getProcessArtifact(vspId, version, componentId, processId); + validateProcessArtifactExistence(vspId, version, componentId, processId, retrieved); + + File file = new File(String + .format("%s_%s_%s_%s", vspId, version.toString().replace('.', '_'), componentId, + processId)); + try { + FileOutputStream fos = new FileOutputStream(file); + fos.write(retrieved.getArtifact().array()); + fos.close(); + } catch (IOException e0) { + throw new CoreException(new UploadInvalidErrorBuilder().build()); + } + + return file; + } + + @Override + public void deleteProcessArtifact(String vspId, String componentId, String processId, + String user) { + Version activeVersion = + getVersionInfo(vspId, VersionableEntityAction.Write, user).getActiveVersion(); + ProcessArtifactEntity retrieved = + vendorSoftwareProductDao.getProcessArtifact(vspId, activeVersion, componentId, processId); + validateProcessArtifactExistence(vspId, activeVersion, componentId, processId, retrieved); + + vendorSoftwareProductDao.deleteProcessArtifact(vspId, activeVersion, componentId, processId); + + vendorSoftwareProductDao.updateVspLatestModificationTime(vspId, activeVersion); + } + + @Override + public void uploadProcessArtifact(InputStream artifactFile, String artifactFileName, String vspId, + String componentId, String processId, String user) { + Version activeVersion = + getVersionInfo(vspId, VersionableEntityAction.Write, user).getActiveVersion(); + org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity retrieved = + vendorSoftwareProductDao.getProcess(vspId, activeVersion, componentId, processId); + validateProcessExistence(vspId, activeVersion, componentId, processId, retrieved); + + if (artifactFile == null) { + throw new CoreException(new UploadInvalidErrorBuilder().build()); + } + + byte[] artifact; + try { + artifact = FileUtils.toByteArray(artifactFile); + } catch (RuntimeException e0) { + throw new CoreException(new UploadInvalidErrorBuilder().build()); + } + + vendorSoftwareProductDao + .uploadProcessArtifact(vspId, activeVersion, componentId, processId, artifact, + artifactFileName); + + vendorSoftwareProductDao.updateVspLatestModificationTime(vspId, activeVersion); + } + + @Override + public Collection listNics( + String vspId, Version version, String componentId, + String user) { + version = VersioningUtil + .resolveVersion(version, getVersionInfo(vspId, VersionableEntityAction.Read, user)); + Collection nics = + listNics(vspId, version, componentId); + + Map networksNameById = listNetworksNameById(vspId, version); + nics.stream().forEach(nicEntity -> { + Nic nic = nicEntity.getNicCompositionData(); + nic.setNetworkName(networksNameById.get(nic.getNetworkId())); + nicEntity.setNicCompositionData(nic); + }); + return nics; + } + + private Collection listNics( + String vspId, Version version, String componentId) { + getComponent(vspId, version, componentId); + + return vendorSoftwareProductDao.listNics(vspId, version, componentId); + } + + private Map listNetworksNameById(String vspId, Version version) { + Collection networks = listNetworks(vspId, version); + return networks.stream().collect(Collectors.toMap(NetworkEntity::getId, + networkEntity -> networkEntity.getNetworkCompositionData().getName())); + } + + @Override + public org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity createNic( + org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity nic, String user) { + Version activeVersion = + getVersionInfo(nic.getVspId(), VersionableEntityAction.Write, user).getActiveVersion(); + nic.setVersion(activeVersion); + if (!isManual(nic.getVspId(), activeVersion)) { + throw new CoreException( + new ErrorCode.ErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION) + .withId(VendorSoftwareProductErrorCodes.VSP_COMPOSITION_EDIT_NOT_ALLOWED) + .withMessage(VSP_COMPOSITION_EDIT_NOT_ALLOWED_MSG).build()); + } + + vendorSoftwareProductDao.updateVspLatestModificationTime(nic.getVspId(), activeVersion); + + return null; + } + + private org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity createNic( + org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity nic) { + nic.setId(CommonMethods.nextUuId()); + nic.setQuestionnaireData( + new JsonSchemaDataGenerator(getNicQuestionnaireSchema(null)).generateData()); + + vendorSoftwareProductDao.createNic(nic); + + return nic; + } + + @Override + public CompositionEntityResponse getNic(String vspId, Version version, String componentId, + String nicId, String user) { + version = VersioningUtil + .resolveVersion(version, getVersionInfo(vspId, VersionableEntityAction.Read, user)); + org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity + nicEntity = getNic(vspId, version, componentId, nicId); + Nic nic = nicEntity.getNicCompositionData(); + + NicCompositionSchemaInput schemaInput = new NicCompositionSchemaInput(); + schemaInput.setManual(isManual(vspId, version)); + schemaInput.setNic(nic); + Map networksNameById = listNetworksNameById(vspId, version); + nic.setNetworkName(networksNameById.get(nic.getNetworkId())); + schemaInput.setNetworkIds(networksNameById.keySet()); + + CompositionEntityResponse response = new CompositionEntityResponse<>(); + response.setId(nicId); + response.setData(nic); + response.setSchema(SchemaGenerator + .generate(SchemaTemplateContext.composition, CompositionEntityType.nic, schemaInput)); + + return response; + } + + private org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity getNic(String vspId, + Version version, + String componentId, + String nicId) { + getComponent(vspId, version, componentId); + org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity + retrieved = vendorSoftwareProductDao.getNic(vspId, version, componentId, nicId); + VersioningUtil + .validateEntityExistence(retrieved, + new org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity(vspId, version, + componentId, nicId), + VspDetails.ENTITY_TYPE); + return retrieved; + } + + @Override + public void deleteNic(String vspId, String componentId, String nicId, String user) { + Version activeVersion = + getVersionInfo(vspId, VersionableEntityAction.Write, user).getActiveVersion(); + if (!isManual(vspId, activeVersion)) { + throw new CoreException( + new ErrorCode.ErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION) + .withId(VendorSoftwareProductErrorCodes.VSP_COMPOSITION_EDIT_NOT_ALLOWED) + .withMessage(VSP_COMPOSITION_EDIT_NOT_ALLOWED_MSG).build()); + } + + vendorSoftwareProductDao.updateVspLatestModificationTime(vspId, activeVersion); + } + + @Override + public CompositionEntityValidationData updateNic( + org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity nic, String user) { + Version activeVersion = + getVersionInfo(nic.getVspId(), VersionableEntityAction.Write, user).getActiveVersion(); + nic.setVersion(activeVersion); + org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity + retrieved = getNic(nic.getVspId(), activeVersion, nic.getComponentId(), nic.getId()); + + NicCompositionSchemaInput schemaInput = new NicCompositionSchemaInput(); + schemaInput.setManual(isManual(nic.getVspId(), activeVersion)); + schemaInput.setNic(retrieved.getNicCompositionData()); + + CompositionEntityValidationData validationData = CompositionEntityDataManager + .validateEntity(nic, SchemaTemplateContext.composition, schemaInput); + if (CollectionUtils.isEmpty(validationData.getErrors())) { + vendorSoftwareProductDao.updateNic(nic); + } + + vendorSoftwareProductDao.updateVspLatestModificationTime(nic.getVspId(), activeVersion); + return validationData; + } + + @Override + public QuestionnaireResponse getNicQuestionnaire(String vspId, Version version, + String componentId, String nicId, String user) { + version = VersioningUtil + .resolveVersion(version, getVersionInfo(vspId, VersionableEntityAction.Read, user)); + + QuestionnaireResponse questionnaireResponse = new QuestionnaireResponse(); + questionnaireResponse + .setData(getNic(vspId, version, componentId, nicId).getQuestionnaireData()); + questionnaireResponse.setSchema(getNicQuestionnaireSchema(null)); + + return questionnaireResponse; + } + + @Override + public void updateNicQuestionnaire(String vspId, String componentId, String nicId, + String questionnaireData, String user) { + Version activeVersion = + getVersionInfo(vspId, VersionableEntityAction.Write, user).getActiveVersion(); + getNic(vspId, activeVersion, componentId, nicId); + + vendorSoftwareProductDao + .updateNicQuestionnaire(vspId, activeVersion, componentId, nicId, questionnaireData); + + vendorSoftwareProductDao.updateVspLatestModificationTime(vspId, activeVersion); + } + + @Override + public void deleteComponentMib(String vspId, String componentId, boolean isTrap, String user) { + Version activeVersion = + getVersionInfo(vspId, VersionableEntityAction.Write, user).getActiveVersion(); + ComponentArtifactEntity componentArtifactEntity = + setValuesForComponentArtifactEntityUpload(vspId, activeVersion, null, componentId, null, + isTrap, null); + ComponentArtifactEntity retrieved = + componentArtifactDao.getArtifactByType(componentArtifactEntity); + + componentArtifactDao.delete(retrieved); + + vendorSoftwareProductDao.updateVspLatestModificationTime(vspId, activeVersion); + } + + @Override + public void uploadComponentMib(InputStream object, String filename, String vspId, + String componentId, boolean isTrap, String user) { + Version activeVersion = + getVersionInfo(vspId, VersionableEntityAction.Write, user).getActiveVersion(); + ComponentArtifactEntity componentArtifactEntity; + + + if (object == null) { + throw new CoreException(new MibUploadErrorBuilder( + Messages.NO_ZIP_FILE_WAS_UPLOADED_OR_ZIP_NOT_EXIST.getErrorMessage()).build()); + } else { + byte[] uploadedFileData; + Map> errors = new HashMap<>(); + try { + uploadedFileData = FileUtils.toByteArray(object); + validateMibZipContent(vspId, activeVersion, uploadedFileData, errors); + if (MapUtils.isNotEmpty(errors)) { + throw new CoreException( + new MibUploadErrorBuilder(errors.values().iterator().next().get(0).getMessage()) + .build()); + } + + createArtifactInDatabase(vspId, activeVersion, filename, componentId, isTrap, + uploadedFileData); + + } catch (Exception e0) { + throw new CoreException(new MibUploadErrorBuilder(e0.getMessage()).build()); + } + } + + vendorSoftwareProductDao.updateVspLatestModificationTime(vspId, activeVersion); + } + + private void createArtifactInDatabase(String vspId, Version activeVersion, String filename, + String componentId, boolean isTrap, + byte[] uploadedFileData) { + ComponentArtifactEntity componentArtifactEntity; + + String artifactId = CommonMethods.nextUuId(); + componentArtifactEntity = + setValuesForComponentArtifactEntityUpload(vspId, activeVersion, filename, componentId, + artifactId, isTrap, uploadedFileData); + componentArtifactDao.update(componentArtifactEntity); + } + + @Override + public MibUploadStatus listMibFilenames(String vspId, String componentId, String user) { + Version activeVersion = + getVersionInfo(vspId, VersionableEntityAction.Read, user).getActiveVersion(); + ComponentArtifactEntity current = + new ComponentArtifactEntity(vspId, activeVersion, componentId, null); + + return setMibUploadStatusValues(current); + + } + + private MibUploadStatus setMibUploadStatusValues( + ComponentArtifactEntity componentArtifactEntity) { + MibUploadStatus mibUploadStatus = new MibUploadStatus(); + + Collection artifactNames = + componentArtifactDao.getArtifactNamesAndTypesForComponent(componentArtifactEntity); + Map artifactTypeToFilename = + VendorSoftwareProductUtils.filterNonTrapOrPollArtifacts(artifactNames); + + if (MapUtils.isNotEmpty(artifactTypeToFilename)) { + if (artifactTypeToFilename.containsKey(ComponentArtifactType.SNMP_TRAP)) { + mibUploadStatus.setSnmpTrap(artifactTypeToFilename.get(ComponentArtifactType.SNMP_TRAP)); + } + if (artifactTypeToFilename.containsKey(ComponentArtifactType.SNMP_POLL)) { + mibUploadStatus.setSnmpPoll(artifactTypeToFilename.get(ComponentArtifactType.SNMP_POLL)); + } + } + + return mibUploadStatus; + } + + private ComponentArtifactEntity setValuesForComponentArtifactEntityUpload(String vspId, + Version version, + String filename, + String componentId, + String artifactId, + boolean isTrap, + byte[] + uploadedFileData) { + ComponentArtifactEntity componentArtifactEntity = new ComponentArtifactEntity(); + + componentArtifactEntity.setVspId(vspId); + componentArtifactEntity.setVersion(version); + componentArtifactEntity.setComponentId(componentId); + componentArtifactEntity.setId(artifactId); + componentArtifactEntity.setType(ComponentArtifactType.getComponentArtifactType(isTrap)); + componentArtifactEntity.setArtifactName(filename); + + if (Objects.nonNull(uploadedFileData)) { + componentArtifactEntity.setArtifact(ByteBuffer.wrap(uploadedFileData)); + } + + return componentArtifactEntity; + } + + private void validateProcessExistence(String vspId, Version version, String componentId, + String processId, + org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity retrieved) { + if (retrieved != null) { + return; + } + if (!GENERAL_COMPONENT_ID.equals(componentId)) { + getComponent(vspId, version, componentId); + } + VersioningUtil.validateEntityExistence(retrieved, + new org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity(vspId, version, + componentId, processId), + VspDetails.ENTITY_TYPE);//todo retrieved is always null ?? + } + + private void validateProcessArtifactExistence(String vspId, Version version, String componentId, + String processId, ProcessArtifactEntity retrieved) { + if (retrieved != null) { + VersioningUtil.validateEntityExistence(retrieved.getArtifact(), + new ProcessArtifactEntity(vspId, version, componentId, processId), + VspDetails.ENTITY_TYPE); + } else { + if (!GENERAL_COMPONENT_ID.equals(componentId)) { + getComponent(vspId, version, componentId); + } + VersioningUtil.validateEntityExistence(retrieved, + new org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity(vspId, version, + componentId, processId), + VspDetails.ENTITY_TYPE); //todo retrieved is always null ?? + } + } + + private Map> validateUploadData(UploadDataEntity uploadData) + throws IOException { + if (uploadData == null || uploadData.getContentData() == null) { + return null; + } + + FileContentHandler fileContentMap = + VendorSoftwareProductUtils.loadUploadFileContent(uploadData.getContentData().array()); + ValidationManager validationManager = + ValidationManagerUtil.initValidationManager(fileContentMap); + Map> validationErrors = validationManager.validate(); + + return + MapUtils.isEmpty(MessageContainerUtil.getMessageByLevel(ErrorLevel.ERROR, validationErrors)) + ? null : validationErrors; + } + + private VersionInfo getVersionInfo(String vendorSoftwareProductId, VersionableEntityAction action, + String user) { + return versioningManager + .getEntityVersionInfo(VENDOR_SOFTWARE_PRODUCT_VERSIONABLE_TYPE, vendorSoftwareProductId, + user, action); + } + + private void saveCompositionData(String vspId, Version version, CompositionData compositionData) { + Map networkIdByName = new HashMap<>(); + for (Network network : compositionData.getNetworks()) { + + NetworkEntity networkEntity = new NetworkEntity(vspId, version, null); + networkEntity.setNetworkCompositionData(network); + + if (network.getName() != null) { + networkIdByName.put(network.getName(), createNetwork(networkEntity).getId()); + } + } + + for (Component component : compositionData.getComponents()) { + ComponentEntity componentEntity = new ComponentEntity(vspId, version, null); + componentEntity.setComponentCompositionData(component.getData()); + + String componentId = createComponent(componentEntity).getId(); + + if (CollectionUtils.isNotEmpty(component.getNics())) { + for (Nic nic : component.getNics()) { + if (nic.getNetworkName() != null) { + nic.setNetworkId(networkIdByName.get(nic.getNetworkName())); + nic.setNetworkName(null); + } + + org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity + nicEntity = + new org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity(vspId, version, + componentId, null); + nicEntity.setNicCompositionData(nic); + createNic(nicEntity); + } + } + } + } + + private void deleteUploadDataAndContent(String vspId, Version version) { + vendorSoftwareProductDao.deleteUploadData(vspId, version); + } + + private QuestionnaireValidationResult validateQuestionnaire(String vspId, Version version) { + CompositionEntityDataManager compositionEntityDataManager = new CompositionEntityDataManager(); + compositionEntityDataManager + .addEntity(vendorSoftwareProductDao.getQuestionnaire(vspId, version), null); + + Collection nics = + vendorSoftwareProductDao.listNicsByVsp(vspId, version); + + Map> nicNamesByComponent = new HashMap<>(); + for (org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity nicEntity : nics) { + compositionEntityDataManager.addEntity(nicEntity, null); + + Nic nic = nicEntity.getNicCompositionData(); + if (nic != null && nic.getName() != null) { + List nicNames = nicNamesByComponent.get(nicEntity.getComponentId()); + if (nicNames == null) { + nicNames = new ArrayList<>(); + nicNamesByComponent.put(nicEntity.getComponentId(), nicNames); + } + nicNames.add(nic.getName()); + } + } + + Collection components = + vendorSoftwareProductDao.listComponentsQuestionnaire(vspId, version); + components.stream().forEach(component -> compositionEntityDataManager.addEntity(component, + new ComponentQuestionnaireSchemaInput(nicNamesByComponent.get(component.getId()), + JsonUtil.json2Object(component.getQuestionnaireData(), Map.class)))); + + Map> errorsByEntityId = + compositionEntityDataManager.validateEntitiesQuestionnaire(); + if (MapUtils.isNotEmpty(errorsByEntityId)) { + compositionEntityDataManager.buildTrees(); + compositionEntityDataManager.addErrorsToTrees(errorsByEntityId); + Collection roots = compositionEntityDataManager.getTrees(); + return new QuestionnaireValidationResult(roots.iterator().next()); + } + + return null; + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/services/CompositionDataExtractor.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/services/CompositionDataExtractor.java new file mode 100644 index 0000000000..f92b83532e --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/services/CompositionDataExtractor.java @@ -0,0 +1,386 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.services; + +import org.apache.commons.collections4.CollectionUtils; +import org.apache.commons.collections4.MapUtils; +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.tosca.datatypes.ToscaCapabilityType; +import org.openecomp.sdc.tosca.datatypes.ToscaFunctions; +import org.openecomp.sdc.tosca.datatypes.ToscaNodeType; +import org.openecomp.sdc.tosca.datatypes.ToscaRelationshipType; +import org.openecomp.sdc.tosca.datatypes.ToscaServiceModel; +import org.openecomp.sdc.tosca.datatypes.model.NodeTemplate; +import org.openecomp.sdc.tosca.datatypes.model.ParameterDefinition; +import org.openecomp.sdc.tosca.datatypes.model.RequirementAssignment; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.errors.ToscaInvalidEntryNotFoundErrorBuilder; +import org.openecomp.sdc.tosca.errors.ToscaInvalidSubstituteNodeTemplateErrorBuilder; +import org.openecomp.sdc.tosca.errors.ToscaMissingSubstitutionMappingForReqCapErrorBuilder; +import org.openecomp.sdc.tosca.services.ToscaAnalyzerService; +import org.openecomp.sdc.tosca.services.ToscaConstants; +import org.openecomp.sdc.tosca.services.impl.ToscaAnalyzerServiceImpl; +import org.openecomp.sdc.tosca.services.yamlutil.ToscaExtensionYamlUtil; +import org.openecomp.sdc.vendorsoftwareproduct.types.ExtractCompositionDataContext; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.Component; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.ComponentData; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionData; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.Network; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.Nic; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.Optional; + +/** + * The type Composition data extractor. + */ +public class CompositionDataExtractor { + + /** + * The constant logger. + */ + protected static Logger logger; + private static ToscaAnalyzerService toscaAnalyzerService; + + static { + logger = LoggerFactory.getLogger(CompositionDataExtractor.class); + toscaAnalyzerService = new ToscaAnalyzerServiceImpl(); + } + + /** + * Extract service composition data composition data. + * + * @param toscaServiceModel the tosca service model + * @return the composition data + */ + public static CompositionData extractServiceCompositionData(ToscaServiceModel toscaServiceModel) { + ExtractCompositionDataContext context = new ExtractCompositionDataContext(); + String entryDefinitionServiceTemplateFileName = + toscaServiceModel.getEntryDefinitionServiceTemplate(); + ServiceTemplate entryDefinitionServiceTemplate = + toscaServiceModel.getServiceTemplates().get(entryDefinitionServiceTemplateFileName); + extractServiceCompositionData(entryDefinitionServiceTemplateFileName, + entryDefinitionServiceTemplate, toscaServiceModel, context); + + CompositionData compositionData = new CompositionData(); + compositionData.setNetworks(context.getNetworks()); + compositionData.setComponents(context.getComponents()); + return compositionData; + } + + private static void extractServiceCompositionData(String serviceTemplateFileName, + ServiceTemplate serviceTemplate, + ToscaServiceModel toscaServiceModel, + ExtractCompositionDataContext context) { + if (context.getHandledServiceTemplates().contains(serviceTemplateFileName)) { + return; + } + context.addNetworks(extractNetworks(serviceTemplate, toscaServiceModel)); + extractComponents(serviceTemplate, toscaServiceModel, context); + handleSubstitution(serviceTemplate, toscaServiceModel, context); + context.addHandledServiceTemplates(serviceTemplateFileName); + } + + private static void handleSubstitution(ServiceTemplate serviceTemplate, + ToscaServiceModel toscaServiceModel, + ExtractCompositionDataContext context) { + Map substitutableNodeTemplates = + toscaAnalyzerService.getSubstitutableNodeTemplates(serviceTemplate); + + if (substitutableNodeTemplates != null) { + for (String substitutableNodeTemplateId : substitutableNodeTemplates.keySet()) { + handleSubstitutableNodeTemplate(serviceTemplate, toscaServiceModel, + substitutableNodeTemplateId, + substitutableNodeTemplates.get(substitutableNodeTemplateId), context); + } + } + } + + private static void handleSubstitutableNodeTemplate(ServiceTemplate serviceTemplate, + ToscaServiceModel toscaServiceModel, + String substitutableNodeTemplateId, + NodeTemplate substitutableNodeTemplate, + ExtractCompositionDataContext context) { + ToscaExtensionYamlUtil toscaExtensionYamlUtil = new ToscaExtensionYamlUtil(); + Optional substituteServiceTemplateFileName = toscaAnalyzerService + .getSubstituteServiceTemplateName(substitutableNodeTemplateId, substitutableNodeTemplate); + if (!substituteServiceTemplateFileName.isPresent()) { + throw new CoreException( + new ToscaInvalidSubstituteNodeTemplateErrorBuilder(substitutableNodeTemplateId).build()); + } + if (context.getHandledServiceTemplates().contains(substituteServiceTemplateFileName.get())) { + return; + } + + ServiceTemplate substituteServiceTemplate = + toscaServiceModel.getServiceTemplates().get(substituteServiceTemplateFileName.get()); + extractServiceCompositionData(substituteServiceTemplateFileName.get(), + substituteServiceTemplate, toscaServiceModel, context); + + List> substitutableRequirements = + substitutableNodeTemplate.getRequirements(); + + if (CollectionUtils.isEmpty(substitutableRequirements)) { + return; + } + + for (Map substitutableReq : substitutableRequirements) { + substitutableReq.keySet().stream().filter(reqId -> { + RequirementAssignment reqAssignment = toscaExtensionYamlUtil + .yamlToObject(toscaExtensionYamlUtil.objectToYaml(substitutableReq.get(reqId)), + RequirementAssignment.class); + return isLinkToNetworkRequirementAssignment(reqAssignment); + }).forEach(reqId -> { + RequirementAssignment linkToNetworkRequirement = toscaExtensionYamlUtil + .yamlToObject(toscaExtensionYamlUtil.objectToYaml(substitutableReq.get(reqId)), + RequirementAssignment.class); + String connectedNodeId = linkToNetworkRequirement.getNode(); + Optional connectedNodeTemplate = + toscaAnalyzerService.getNodeTemplateById(serviceTemplate, connectedNodeId); + + if (connectedNodeTemplate.isPresent() && toscaAnalyzerService + .isTypeOf(connectedNodeTemplate.get(), ToscaNodeType.NETWORK.getDisplayName(), + serviceTemplate, toscaServiceModel)) { + Optional> mappedNodeTemplate = toscaAnalyzerService + .getSubstitutionMappedNodeTemplateByExposedReq( + substituteServiceTemplateFileName.get(), substituteServiceTemplate, reqId); + if (!mappedNodeTemplate.isPresent()) { + throw new CoreException(new ToscaMissingSubstitutionMappingForReqCapErrorBuilder( + ToscaMissingSubstitutionMappingForReqCapErrorBuilder.MappingExposedEntry + .REQUIREMENT, connectedNodeId).build()); + } + + if (toscaAnalyzerService.isTypeOf(mappedNodeTemplate.get().getValue(), + ToscaNodeType.NETWORK_PORT.getDisplayName(), serviceTemplate, toscaServiceModel)) { + Nic port = context.getNics().get(mappedNodeTemplate.get().getKey()); + if (port != null) { + port.setNetworkName(connectedNodeId); + } else { + logger.warn( + "Different ports define for the same component which is used in different " + + "substitution service templates."); + } + } + } else if (!connectedNodeTemplate.isPresent()) { + throw new CoreException( + new ToscaInvalidEntryNotFoundErrorBuilder("Node Template", connectedNodeId).build()); + } + }); + } + } + + private static boolean isLinkToNetworkRequirementAssignment(RequirementAssignment requirement) { + return toscaAnalyzerService.isDesiredRequirementAssignment(requirement, + ToscaCapabilityType.NETWORK_LINKABLE.getDisplayName(), null, + ToscaRelationshipType.NETWORK_LINK_TO.getDisplayName()); + } + + + private static void connectPortToNetwork(Nic port, NodeTemplate portNodeTemplate) { + List linkRequirementsToNetwork = + toscaAnalyzerService.getRequirements(portNodeTemplate, ToscaConstants.LINK_REQUIREMENT_ID); + + //port is connected to one network + for (RequirementAssignment linkRequirementToNetwork : linkRequirementsToNetwork) { + port.setNetworkName(linkRequirementToNetwork.getNode()); + } + + } + + /* + return Map with key - compute node template id, value - list of connected port node template id + */ + private static Map> getComputeToPortsConnection( + Map portNodeTemplates) { + Map> computeToPortConnection = new HashMap<>(); + if (MapUtils.isEmpty(portNodeTemplates)) { + return computeToPortConnection; + } + for (String portId : portNodeTemplates.keySet()) { + List bindingRequirementsToCompute = toscaAnalyzerService + .getRequirements(portNodeTemplates.get(portId), ToscaConstants.BINDING_REQUIREMENT_ID); + for (RequirementAssignment bindingRequirementToCompute : bindingRequirementsToCompute) { + computeToPortConnection + .putIfAbsent(bindingRequirementToCompute.getNode(), new ArrayList<>()); + computeToPortConnection.get(bindingRequirementToCompute.getNode()).add(portId); + } + + } + + return computeToPortConnection; + } + + private static void extractComponents(ServiceTemplate serviceTemplate, + ToscaServiceModel toscaServiceModel, + ExtractCompositionDataContext context) { + Map computeNodeTemplates = toscaAnalyzerService + .getNodeTemplatesByType(serviceTemplate, ToscaNodeType.COMPUTE.getDisplayName(), + toscaServiceModel); + if (MapUtils.isEmpty(computeNodeTemplates)) { + return; + } + Map portNodeTemplates = toscaAnalyzerService + .getNodeTemplatesByType(serviceTemplate, ToscaNodeType.NETWORK_PORT.getDisplayName(), + toscaServiceModel); + Map> computeToPortsConnection = + getComputeToPortsConnection(portNodeTemplates); + Map> computesGroupedByType = + getNodeTemplatesGroupedByType(computeNodeTemplates); + + computesGroupedByType.keySet() + .stream() + .filter(nodeType -> + !context.getCreatedComponents().contains(nodeType)) + .forEach(nodeType -> extractComponent(serviceTemplate, computeToPortsConnection, + computesGroupedByType, nodeType, context)); + } + + private static void extractComponent(ServiceTemplate serviceTemplate, + Map> computeToPortsConnection, + Map> computesGroupedByType, + String computeNodeType, + ExtractCompositionDataContext context) { + ComponentData component = new ComponentData(); + component.setName(computeNodeType); + component.setDisplayName(getComponentDisplayName(component.getName())); + Component componentModel = new Component(); + componentModel.setData(component); + + String computeId = computesGroupedByType.get(computeNodeType).get(0); + List connectedPortIds = computeToPortsConnection.get(computeId); + + if (connectedPortIds != null) { + componentModel.setNics(new ArrayList<>()); + for (String portId : connectedPortIds) { + Nic port = extractPort(serviceTemplate, portId); + componentModel.getNics().add(port); + context.addNic(portId, port); + } + } + context.addComponent(componentModel); + context.getCreatedComponents().add(computeNodeType); + } + + private static Nic extractPort(ServiceTemplate serviceTemplate, String portNodeTemplateId) { + Optional portNodeTemplate = + toscaAnalyzerService.getNodeTemplateById(serviceTemplate, portNodeTemplateId); + if (portNodeTemplate.isPresent()) { + Nic port = new Nic(); + port.setName(portNodeTemplateId); + connectPortToNetwork(port, portNodeTemplate.get()); + return port; + } else { + throw new CoreException( + new ToscaInvalidEntryNotFoundErrorBuilder("Node Template", portNodeTemplateId).build()); + } + } + + + private static Map> getNodeTemplatesGroupedByType( + Map nodeTemplates) { + Map> nodeTemplatesGrouped = + new HashMap<>(); //key - node type, value - list of node ids with this type + for (String nodeId : nodeTemplates.keySet()) { + String nodeType = nodeTemplates.get(nodeId).getType(); + nodeTemplatesGrouped.putIfAbsent(nodeType, new ArrayList<>()); + nodeTemplatesGrouped.get(nodeType).add(nodeId); + } + return nodeTemplatesGrouped; + } + + private static List extractNetworks(ServiceTemplate serviceTemplate, + ToscaServiceModel toscaServiceModel) { + List networks = new ArrayList<>(); + Map networkNodeTemplates = toscaAnalyzerService + .getNodeTemplatesByType(serviceTemplate, ToscaNodeType.NETWORK.getDisplayName(), + toscaServiceModel); + if (MapUtils.isEmpty(networkNodeTemplates)) { + return networks; + } + for (String networkId : networkNodeTemplates.keySet()) { + Network network = new Network(); + network.setName(networkId); + Optional networkDhcpValue = + getNetworkDhcpValue(serviceTemplate, networkNodeTemplates.get(networkId)); + network.setDhcp(networkDhcpValue.isPresent() ? networkDhcpValue.get() : true); + networks.add(network); + } + + return networks; + } + + //dhcp default value is true + private static Optional getNetworkDhcpValue(ServiceTemplate serviceTemplate, + NodeTemplate networkNodeTemplate) { + if (networkNodeTemplate == null) { + return Optional.empty(); + } + if (networkNodeTemplate.getProperties() == null + || networkNodeTemplate.getProperties().get(ToscaConstants.DHCP_ENABLED_PROPERTY_NAME) + == null) { + return Optional.of(true); + } + + Object dhcp = + networkNodeTemplate.getProperties().get(ToscaConstants.DHCP_ENABLED_PROPERTY_NAME); + if (dhcp instanceof String) { + return Optional.of(Boolean.valueOf((String) dhcp)); + } else if (dhcp instanceof Boolean) { + return Optional.of((Boolean) dhcp); + } else if (dhcp instanceof Map) { + String inputParameterName = + (String) ((Map) dhcp).get(ToscaFunctions.GET_INPUT.getDisplayName()); + if (inputParameterName != null) { + ParameterDefinition inputParameterDefinition = + serviceTemplate.getTopology_template().getInputs().get(inputParameterName); + if (inputParameterDefinition != null) { + if (inputParameterDefinition.get_default() != null) { + return Optional.of(Boolean.valueOf(inputParameterDefinition.get_default().toString())); + } + } else { + throw new CoreException( + new ToscaInvalidEntryNotFoundErrorBuilder("Input Parameter", inputParameterName) + .build()); + } + } + } + + return Optional.of(true); + } + + private static String getComponentDisplayName(String componentName) { + if (componentName == null) { + return null; + } + String delimiterChar = "."; + if (componentName.contains(delimiterChar)) { + return componentName.substring(componentName.lastIndexOf(delimiterChar) + 1); + } + return componentName; + + } + +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/services/CompositionEntityDataManager.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/services/CompositionEntityDataManager.java new file mode 100644 index 0000000000..e3f56a6578 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/services/CompositionEntityDataManager.java @@ -0,0 +1,257 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.services; + +import org.openecomp.core.utilities.json.JsonUtil; +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; +import org.openecomp.sdc.vendorsoftwareproduct.types.CompositionEntityValidationData; +import org.openecomp.sdc.vendorsoftwareproduct.types.schemagenerator.SchemaTemplateContext; +import org.openecomp.sdc.vendorsoftwareproduct.types.schemagenerator.SchemaTemplateInput; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +/** + * The type Composition entity data manager. + */ +public class CompositionEntityDataManager { + + private static final String COMPOSITION_ENTITY_DATA_MANAGER_ERR = + "COMPOSITION_ENTITY_DATA_MANAGER_ERR"; + private static final String COMPOSITION_ENTITY_DATA_MANAGER_ERR_MSG = + "Invalid input: %s may not be null"; + + private Map entities = new HashMap<>(); + private Map nonDynamicSchemas = new HashMap<>(); + private List roots = new ArrayList<>(); + + /** + * Validate entity composition entity validation data. + * + * @param entity the entity + * @param schemaTemplateContext the schema template context + * @param schemaTemplateInput the schema template input + * @return the composition entity validation data + */ + public static CompositionEntityValidationData validateEntity( + org.openecomp.sdc.vendorsoftwareproduct.dao.type.CompositionEntity entity, + SchemaTemplateContext schemaTemplateContext, + SchemaTemplateInput schemaTemplateInput) { + if (entity == null) { + throw new CoreException( + new ErrorCode.ErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION) + .withId(COMPOSITION_ENTITY_DATA_MANAGER_ERR).withMessage( + String.format(COMPOSITION_ENTITY_DATA_MANAGER_ERR_MSG, "composition entity")) + .build()); + } + if (schemaTemplateContext == null) { + throw new CoreException( + new ErrorCode.ErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION) + .withId(COMPOSITION_ENTITY_DATA_MANAGER_ERR).withMessage( + String.format(COMPOSITION_ENTITY_DATA_MANAGER_ERR_MSG, "schema template context")) + .build()); + } + + CompositionEntityValidationData validationData = + new CompositionEntityValidationData(entity.getType(), entity.getId()); + String json = + schemaTemplateContext == SchemaTemplateContext.composition ? entity.getCompositionData() + : entity.getQuestionnaireData(); + validationData.setErrors(JsonUtil.validate( + json == null ? JsonUtil.object2Json(new Object()) : json, + SchemaGenerator.generate(schemaTemplateContext, entity.getType(), schemaTemplateInput))); + + return validationData; + } + + /** + * Add entity. + * + * @param entity the entity + * @param schemaTemplateInput the schema template input + */ + public void addEntity(org.openecomp.sdc.vendorsoftwareproduct.dao.type.CompositionEntity entity, + SchemaTemplateInput schemaTemplateInput) { + if (entity == null) { + throw new CoreException( + new ErrorCode.ErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION) + .withId(COMPOSITION_ENTITY_DATA_MANAGER_ERR).withMessage( + String.format(COMPOSITION_ENTITY_DATA_MANAGER_ERR_MSG, "composition entity")) + .build()); + } + entities.put(entity.getCompositionEntityId(), + new CompositionEntityData(entity, schemaTemplateInput)); + } + + /** + * Validate entities questionnaire map. + * + * @return the map + */ + public Map> validateEntitiesQuestionnaire() { + Map> + errorsByEntityId = new HashMap<>(); + + entities.entrySet().stream().forEach(entry -> { + Collection errors = validateQuestionnaire(entry.getValue()); + if (errors != null) { + errorsByEntityId.put(entry.getKey(), errors); + } + }); + + return errorsByEntityId; + } + + /** + * Build trees. + */ + public void buildTrees() { + Map + entitiesValidationData = + new HashMap<>(); + entities.entrySet().stream().forEach( + entry -> addValidationDataEntity(entitiesValidationData, entry.getKey(), + entry.getValue().entity)); + } + + /** + * Gets trees. + * + * @return the trees + */ + public Collection getTrees() { + return roots; + } + + /** + * Add errors to trees. + * + * @param errors the errors + */ + public void addErrorsToTrees( + Map> errors) { + roots.stream().forEach(root -> addErrorsToTree(root, null, errors)); + } + + private void addValidationDataEntity( + Map entitiesValidationData, + org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionEntityId entityId, + org.openecomp.sdc.vendorsoftwareproduct.dao.type.CompositionEntity entity) { + if (entitiesValidationData.containsKey(entityId)) { + return; + } + + CompositionEntityValidationData validationData = + new CompositionEntityValidationData(entity.getType(), entity.getId()); + entitiesValidationData.put(entityId, validationData); + + org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionEntityId parentEntityId = + entityId.getParentId(); + if (parentEntityId == null) { + roots.add(validationData); + } else { + CompositionEntityData parentEntity = entities.get(parentEntityId); + if (parentEntity == null) { + roots.add(validationData); + } else { + addValidationDataEntity(entitiesValidationData, parentEntityId, parentEntity.entity); + entitiesValidationData.get(parentEntityId).addSubEntityValidationData(validationData); + } + } + } + + private void addErrorsToTree(CompositionEntityValidationData node, + org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionEntityId parentNodeId, + Map> errors) { + if (node == null) { + return; + } + org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionEntityId + nodeId = new org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionEntityId( + node.getEntityId(), parentNodeId); + node.setErrors(errors.get(nodeId)); + + if (node.getSubEntitiesValidationData() != null) { + node.getSubEntitiesValidationData().stream() + .forEach(subNode -> addErrorsToTree(subNode, nodeId, errors)); + } + } + + private Collection validateQuestionnaire(CompositionEntityData compositionEntityData) { + return JsonUtil.validate( + compositionEntityData.entity.getQuestionnaireData() == null ? JsonUtil + .object2Json(new Object()) : compositionEntityData.entity.getQuestionnaireData(), + getSchema(compositionEntityData.entity.getType(), SchemaTemplateContext.questionnaire, + compositionEntityData.schemaTemplateInput)); + } + + private String getSchema( + org.openecomp.sdc.vendorsoftwareproduct.types + .composition.CompositionEntityType compositionEntityType, + SchemaTemplateContext schemaTemplateContext, + SchemaTemplateInput schemaTemplateInput) { + return schemaTemplateInput == null ? getNonDynamicSchema(schemaTemplateContext, + compositionEntityType) : SchemaGenerator + .generate(schemaTemplateContext, compositionEntityType, schemaTemplateInput); + } + + private String getNonDynamicSchema(SchemaTemplateContext schemaTemplateContext, + org.openecomp.sdc.vendorsoftwareproduct.types.composition + .CompositionEntityType compositionEntityType) { + String schema = nonDynamicSchemas.get(compositionEntityType); + if (schema == null) { + schema = SchemaGenerator.generate(schemaTemplateContext, compositionEntityType, null); + nonDynamicSchemas.put(compositionEntityType, schema); + } + return schema; + } + + private static class CompositionEntityData { + private org.openecomp.sdc.vendorsoftwareproduct.dao.type.CompositionEntity entity; + private SchemaTemplateInput schemaTemplateInput; + + /** + * Instantiates a new Composition entity data. + * + * @param entity the entity + * @param schemaTemplateInput the schema template input + */ + public CompositionEntityData( + org.openecomp.sdc.vendorsoftwareproduct.dao.type.CompositionEntity entity, + SchemaTemplateInput schemaTemplateInput) { + this.entity = entity; + this.schemaTemplateInput = schemaTemplateInput; + } + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/services/SchemaGenerator.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/services/SchemaGenerator.java new file mode 100644 index 0000000000..53fe5455fb --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/services/SchemaGenerator.java @@ -0,0 +1,70 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.services; + +import freemarker.template.Template; +import freemarker.template.TemplateException; +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; +import org.openecomp.sdc.vendorsoftwareproduct.types.schemagenerator.SchemaTemplateContext; +import org.openecomp.sdc.vendorsoftwareproduct.types.schemagenerator.SchemaTemplateInput; + +import java.io.IOException; +import java.io.StringWriter; +import java.io.Writer; + +/** + * The type Schema generator. + */ +public class SchemaGenerator { + /** + * The constant SCHEMA_GENERATION_ERROR. + */ + public static final String SCHEMA_GENERATION_ERROR = "SCHEMA_GENERATION_ERROR"; + + /** + * Generate string. + * + * @param schemaTemplateContext the schema template context + * @param entityType the entity type + * @param input the input + * @return the string + */ + public static String generate(SchemaTemplateContext schemaTemplateContext, + org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionEntityType entityType, + SchemaTemplateInput input) { + Template schemaTemplate = + SchemaGeneratorConfig.getSchemaTemplate(schemaTemplateContext, entityType); + return processTemplate(input, schemaTemplate); + } + + private static String processTemplate(SchemaTemplateInput input, Template schemaTemplate) { + try (Writer writer = new StringWriter(1024)) { + schemaTemplate.process(input, writer); + return writer.toString(); + } catch (IOException | TemplateException exception) { + throw new CoreException( + new ErrorCode.ErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION) + .withId(SCHEMA_GENERATION_ERROR).withMessage(exception.getMessage()).build()); + } + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/services/SchemaGeneratorConfig.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/services/SchemaGeneratorConfig.java new file mode 100644 index 0000000000..034d8520fb --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/services/SchemaGeneratorConfig.java @@ -0,0 +1,184 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.services; + +import freemarker.cache.StringTemplateLoader; +import freemarker.template.Configuration; +import freemarker.template.Template; +import freemarker.template.TemplateExceptionHandler; +import org.openecomp.core.utilities.applicationconfig.ApplicationConfig; +import org.openecomp.core.utilities.applicationconfig.ApplicationConfigFactory; +import org.openecomp.core.utilities.applicationconfig.type.ConfigurationData; +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; +import org.openecomp.sdc.vendorsoftwareproduct.types.schemagenerator.SchemaTemplateContext; + +import java.io.File; +import java.io.IOException; +import java.util.HashMap; +import java.util.Map; + +/** + * The type Schema generator config. + */ +public class SchemaGeneratorConfig { + /** + * The constant SCHEMA_GENERATOR_INITIALIZATION_ERROR. + */ + public static final String SCHEMA_GENERATOR_INITIALIZATION_ERROR = + "SCHEMA_GENERATOR_INITIALIZATION_ERROR"; + /** + * The constant SCHEMA_GENERATOR_INITIALIZATION_ERROR_MSG. + */ + public static final String SCHEMA_GENERATOR_INITIALIZATION_ERROR_MSG = + "Error occurred while loading questionnaire schema schemaTemplates"; + private static final String CONFIGURATION_NAMESPACE = "vsp.schemaTemplates"; + private static Map schemaTemplates = new HashMap<>(); + private static ApplicationConfig applicationConfig = + ApplicationConfigFactory.getInstance().createInterface(); + + private static Configuration configuration = new Configuration(Configuration.VERSION_2_3_23); + private static StringTemplateLoader stringLoader = new StringTemplateLoader(); + + static { + configuration.setClassLoaderForTemplateLoading(SchemaGenerator.class.getClassLoader(), + File.pathSeparator); + configuration.setDefaultEncoding("UTF-8"); + configuration.setTemplateExceptionHandler(TemplateExceptionHandler.RETHROW_HANDLER); + configuration.setLogTemplateExceptions(true); + configuration.setTemplateLoader(stringLoader); + } + + /** + * Insert schema template. + * + * @param schemaTemplateContext the schema template context + * @param entityType the entity type + * @param schemaTemplateString the schema template string + */ + public static void insertSchemaTemplate(SchemaTemplateContext schemaTemplateContext, + org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionEntityType entityType, + String schemaTemplateString) { + applicationConfig.insertValue(CONFIGURATION_NAMESPACE, + new SchemaTemplateId(schemaTemplateContext, entityType).toString(), schemaTemplateString); + } + + /** + * Gets schema template. + * + * @param schemaTemplateContext the schema template context + * @param entityType the entity type + * @return the schema template + */ + public static Template getSchemaTemplate(SchemaTemplateContext schemaTemplateContext, + org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionEntityType entityType) { + SchemaTemplateId id = new SchemaTemplateId(schemaTemplateContext, entityType); + ConfigurationData configurationData = + applicationConfig.getConfigurationData(CONFIGURATION_NAMESPACE, id.toString()); + + SchemaTemplate schemaTemplate = schemaTemplates.get(id); + if (schemaTemplate == null || schemaTemplate.timestamp != configurationData.getTimeStamp()) { + stringLoader.putTemplate(id.toString(), configurationData.getValue()); + Template template; + try { + template = configuration.getTemplate(id.toString()); + } catch (IOException exception) { + throw new CoreException( + new ErrorCode.ErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION) + .withId(SCHEMA_GENERATOR_INITIALIZATION_ERROR) + .withMessage(SCHEMA_GENERATOR_INITIALIZATION_ERROR_MSG).build(), exception); + } + schemaTemplate = new SchemaTemplate(template, configurationData.getTimeStamp()); + schemaTemplates.put(id, schemaTemplate); + } + return schemaTemplate.template; + } + + private static class SchemaTemplateId { + private SchemaTemplateContext context; + private org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionEntityType + entityType; + + /** + * Instantiates a new Schema template id. + * + * @param context the context + * @param entityType the entity type + */ + public SchemaTemplateId(SchemaTemplateContext context, + org.openecomp.sdc.vendorsoftwareproduct.types.composition + .CompositionEntityType entityType) { + this.context = context; + this.entityType = entityType; + } + + @Override + public String toString() { + return context + "." + entityType; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (obj == null || getClass() != obj.getClass()) { + return false; + } + + SchemaTemplateId that = (SchemaTemplateId) obj; + + if (entityType != that.entityType) { + return false; + } + if (context != that.context) { + return false; + } + + return true; + } + + @Override + public int hashCode() { + int result = entityType != null ? entityType.hashCode() : 0; + result = 31 * result + (context != null ? context.hashCode() : 0); + return result; + } + } + + private static class SchemaTemplate { + private Template template; + private long timestamp; + + /** + * Instantiates a new Schema template. + * + * @param template the template + * @param timestamp the timestamp + */ + public SchemaTemplate(Template template, long timestamp) { + this.template = template; + this.timestamp = timestamp; + } + } + +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/CompositionEntityResponse.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/CompositionEntityResponse.java new file mode 100644 index 0000000000..6a71db041b --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/CompositionEntityResponse.java @@ -0,0 +1,53 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.types; + +public class CompositionEntityResponse { + + private String id; + private String schema; + private T data; + + public String getId() { + return id; + } + + public void setId(String id) { + this.id = id; + } + + public String getSchema() { + return schema; + } + + public void setSchema(String schema) { + this.schema = schema; + } + + public T getData() { + return data; + } + + public void setData(T data) { + this.data = data; + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/CompositionEntityValidationData.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/CompositionEntityValidationData.java new file mode 100644 index 0000000000..d334e18637 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/CompositionEntityValidationData.java @@ -0,0 +1,122 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.types; + +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionEntityType; + +import java.util.ArrayList; +import java.util.Collection; + +/** + * The type Composition entity validation data. + */ +public class CompositionEntityValidationData { + private CompositionEntityType entityType; + private String entityId; + private Collection errors; + private Collection subEntitiesValidationData; + + /** + * Instantiates a new Composition entity validation data. + * + * @param entityType the entity type + * @param entityId the entity id + */ + public CompositionEntityValidationData(CompositionEntityType entityType, String entityId) { + this.entityType = entityType; + this.entityId = entityId; + } + + /** + * Gets entity type. + * + * @return the entity type + */ + public CompositionEntityType getEntityType() { + return entityType; + } + + /** + * Sets entity type. + * + * @param entityType the entity type + */ + public void setEntityType(CompositionEntityType entityType) { + this.entityType = entityType; + } + + /** + * Gets entity id. + * + * @return the entity id + */ + public String getEntityId() { + return entityId; + } + + /** + * Sets entity id. + * + * @param entityId the entity id + */ + public void setEntityId(String entityId) { + this.entityId = entityId; + } + + /** + * Gets errors. + * + * @return the errors + */ + public Collection getErrors() { + return errors; + } + + /** + * Sets errors. + * + * @param errors the errors + */ + public void setErrors(Collection errors) { + this.errors = errors; + } + + /** + * Gets sub entities validation data. + * + * @return the sub entities validation data + */ + public Collection getSubEntitiesValidationData() { + return subEntitiesValidationData; + } + + /** + * Add sub entity validation data. + * + * @param subEntityValidationData the sub entity validation data + */ + public void addSubEntityValidationData(CompositionEntityValidationData subEntityValidationData) { + if (subEntitiesValidationData == null) { + subEntitiesValidationData = new ArrayList<>(); + } + subEntitiesValidationData.add(subEntityValidationData); + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/ExtractCompositionDataContext.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/ExtractCompositionDataContext.java new file mode 100644 index 0000000000..0e34fc4e56 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/ExtractCompositionDataContext.java @@ -0,0 +1,204 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.types; + +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.Nic; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Set; + +/** + * The type Extract composition data context. + */ +public class ExtractCompositionDataContext { + private List networks = + new ArrayList<>(); + private List components = + new ArrayList<>(); + private Map nics = new HashMap<>(); + private Set handledServiceTemplates = new HashSet<>(); + private Set createdComponents = new HashSet<>(); + + /** + * Gets created components. + * + * @return the created components + */ + public Set getCreatedComponents() { + return createdComponents; + } + + /** + * Sets created components. + * + * @param createdComponents the created components + */ + public void setCreatedComponents(Set createdComponents) { + this.createdComponents = createdComponents; + } + + /** + * Gets handled service templates. + * + * @return the handled service templates + */ + public Set getHandledServiceTemplates() { + return handledServiceTemplates; + } + + /** + * Sets handled service templates. + * + * @param handledServiceTemplates the handled service templates + */ + public void setHandledServiceTemplates(Set handledServiceTemplates) { + this.handledServiceTemplates = handledServiceTemplates; + } + + /** + * Add handled service templates. + * + * @param handledServiceTemplate the handled service template + */ + public void addHandledServiceTemplates(String handledServiceTemplate) { + this.handledServiceTemplates.add(handledServiceTemplate); + } + + /** + * Gets networks. + * + * @return the networks + */ + public List getNetworks() { + return networks; + } + + /** + * Sets networks. + * + * @param networks the networks + */ + public void setNetworks( + List networks) { + this.networks = networks; + } + + /** + * Add network. + * + * @param network the network + */ + public void addNetwork( + org.openecomp.sdc.vendorsoftwareproduct.types.composition.Network network) { + if (network != null) { + networks.add(network); + } + } + + /** + * Add networks. + * + * @param network the network + */ + public void addNetworks( + List network) { + if (networks != null) { + networks.addAll(network); + } + } + + /** + * Gets components. + * + * @return the components + */ + public List getComponents() { + return components; + } + + /** + * Sets components. + * + * @param components the components + */ + public void setComponents( + List components) { + this.components = components; + } + + /** + * Add component. + * + * @param component the component + */ + public void addComponent( + org.openecomp.sdc.vendorsoftwareproduct.types.composition.Component component) { + if (component != null) { + components.add(component); + } + } + + /** + * Add components. + * + * @param components the components + */ + public void addComponents( + List components) { + if (components != null) { + this.components.addAll(components); + } + } + + /** + * Gets nics. + * + * @return the nics + */ + public Map getNics() { + return nics; + } + + /** + * Sets nics. + * + * @param nics the nics + */ + public void setNics(Map nics) { + this.nics = nics; + } + + /** + * Add nic. + * + * @param nicId the nic id + * @param nic the nic + */ + public void addNic(String nicId, Nic nic) { + this.nics.put(nicId, nic); + } + + +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/LicensingData.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/LicensingData.java new file mode 100644 index 0000000000..f0f6c095dd --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/LicensingData.java @@ -0,0 +1,45 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.types; + +import java.util.List; + +public class LicensingData { + + private String licenseAgreement; + private List featureGroups; + + public String getLicenseAgreement() { + return licenseAgreement; + } + + public void setLicenseAgreement(String licenseAgreement) { + this.licenseAgreement = licenseAgreement; + } + + public List getFeatureGroups() { + return featureGroups; + } + + public void setFeatureGroups(List featureGroups) { + this.featureGroups = featureGroups; + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/QuestionnaireResponse.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/QuestionnaireResponse.java new file mode 100644 index 0000000000..84a2ed58f8 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/QuestionnaireResponse.java @@ -0,0 +1,42 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.types; + +public class QuestionnaireResponse { + private String schema; + private String data; + + public String getSchema() { + return schema; + } + + public void setSchema(String schema) { + this.schema = schema; + } + + public String getData() { + return data; + } + + public void setData(String data) { + this.data = data; + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/QuestionnaireValidationResult.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/QuestionnaireValidationResult.java new file mode 100644 index 0000000000..d970e73a06 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/QuestionnaireValidationResult.java @@ -0,0 +1,39 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.types; + +public class QuestionnaireValidationResult { + private boolean valid; + private CompositionEntityValidationData validationData; + + public QuestionnaireValidationResult(CompositionEntityValidationData validationData) { + this.validationData = validationData; + valid = validationData == null; + } + + public boolean isValid() { + return valid; + } + + public CompositionEntityValidationData getValidationData() { + return validationData; + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/UploadFileResponse.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/UploadFileResponse.java new file mode 100644 index 0000000000..68389b6ed9 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/UploadFileResponse.java @@ -0,0 +1,143 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.types; + + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +public class UploadFileResponse { + private List fileNames; + private Map> errors = + new HashMap<>(); + private UploadFileStatus status = UploadFileStatus.Success; + + /** + * Gets status. + * + * @return the status + */ + public UploadFileStatus getStatus() { + return status; + } + + /** + * Sets status. + * + * @param status the status + */ + public void setStatus(UploadFileStatus status) { + this.status = status; + } + + /** + * Gets file names. + * + * @return the file names + */ + public List getFileNames() { + return fileNames; + } + + /** + * Sets file names. + * + * @param fileNames the file names + */ + public void setFileNames(List fileNames) { + this.fileNames = fileNames; + } + + /** + * Add new file to list. + * + * @param filename the filename + */ + public void addNewFileToList(String filename) { + this.fileNames.add(filename); + } + + /** + * Remove file from list. + * + * @param toRemove the to remove + */ + public void removeFileFromList(String toRemove) { + this.fileNames.remove(toRemove); + } + + /** + * Add structure error. + * + * @param fileName the file name + * @param errorMessage the error message + */ + public void addStructureError(String fileName, + org.openecomp.sdc.datatypes.error.ErrorMessage errorMessage) { + List errorList = errors.get(fileName); + if (errorList == null) { + errorList = new ArrayList<>(); + errors.put(fileName, errorList); + } + errorList.add(errorMessage); + if (org.openecomp.sdc.datatypes.error.ErrorLevel.ERROR.equals(errorMessage.getLevel())) { + status = UploadFileStatus.Failure; + } + } + + /** + * Add structure errors. + * + * @param errorsByFileName the errors by file name + */ + public void addStructureErrors( + Map> errorsByFileName) { + if (errorsByFileName == null) { + return; + } + + errors.putAll(errorsByFileName); + + if (status == UploadFileStatus.Failure) { + return; + } + for (Map.Entry> entry + : errorsByFileName.entrySet()) { + for (org.openecomp.sdc.datatypes.error.ErrorMessage errorMessage : entry.getValue()) { + if (errorMessage.getLevel() == org.openecomp.sdc.datatypes.error.ErrorLevel.ERROR) { + status = UploadFileStatus.Failure; + return; + } + } + } + } + + /** + * Gets errors. + * + * @return the errors + */ + public Map> getErrors() { + return errors; + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/UploadFileStatus.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/UploadFileStatus.java new file mode 100644 index 0000000000..2bd8d76a66 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/UploadFileStatus.java @@ -0,0 +1,26 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.types; + +public enum UploadFileStatus { + Success, + Failure +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/UploadFileStructure.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/UploadFileStructure.java new file mode 100644 index 0000000000..1e21c60577 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/UploadFileStructure.java @@ -0,0 +1,40 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.types; + +import java.util.List; + +public class UploadFileStructure { + + private List fileNames; + + public List getFileNames() { + return fileNames; + } + + public void setFileNames(List fileNames) { + this.fileNames = fileNames; + } + + public void addNewFileToList(String filename) { + this.fileNames.add(filename); + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/ValidationResponse.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/ValidationResponse.java new file mode 100644 index 0000000000..29e5f73bce --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/ValidationResponse.java @@ -0,0 +1,157 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.types; + +import org.apache.commons.collections4.CollectionUtils; +import org.apache.commons.collections4.MapUtils; +import org.openecomp.sdc.common.errors.ErrorCode; +import org.openecomp.sdc.datatypes.error.ErrorMessage; + +import java.util.Collection; +import java.util.List; +import java.util.Map; + +/** + * The type Validation response. + */ +public class ValidationResponse { + private boolean valid = true; + private Collection vspErrors; + private Collection licensingDataErrors; + private Map> uploadDataErrors; + private Map> compilationErrors; + private QuestionnaireValidationResult questionnaireValidationResult; + + /** + * Is valid boolean. + * + * @return the boolean + */ + public boolean isValid() { + return valid; + } + + /** + * Gets vsp errors. + * + * @return the vsp errors + */ + public Collection getVspErrors() { + return vspErrors; + } + + /** + * Sets vsp errors. + * + * @param vspErrors the vsp errors + */ + public void setVspErrors(Collection vspErrors) { + this.vspErrors = vspErrors; + if (CollectionUtils.isNotEmpty(vspErrors)) { + valid = false; + } + } + + /** + * Gets licensing data errors. + * + * @return the licensing data errors + */ + public Collection getLicensingDataErrors() { + return licensingDataErrors; + } + + /** + * Sets licensing data errors. + * + * @param licensingDataErrors the licensing data errors + */ + public void setLicensingDataErrors(Collection licensingDataErrors) { + this.licensingDataErrors = licensingDataErrors; + if (CollectionUtils.isNotEmpty(licensingDataErrors)) { + valid = false; + } + } + + /** + * Gets upload data errors. + * + * @return the upload data errors + */ + public Map> getUploadDataErrors() { + return uploadDataErrors; + } + + /** + * Sets upload data errors. + * + * @param uploadDataErrors the upload data errors + */ + public void setUploadDataErrors(Map> uploadDataErrors) { + this.uploadDataErrors = uploadDataErrors; + if (MapUtils.isNotEmpty(uploadDataErrors)) { + valid = false; + } + } + + /** + * Gets compilation errors. + * + * @return the compilation errors + */ + public Map> getCompilationErrors() { + return compilationErrors; + } + + /** + * Sets compilation errors. + * + * @param compilationErrors the compilation errors + */ + public void setCompilationErrors(Map> compilationErrors) { + this.compilationErrors = compilationErrors; + if (MapUtils.isNotEmpty(compilationErrors)) { + valid = false; + } + } + + /** + * Gets questionnaire validation result. + * + * @return the questionnaire validation result + */ + public QuestionnaireValidationResult getQuestionnaireValidationResult() { + return questionnaireValidationResult; + } + + /** + * Sets questionnaire validation result. + * + * @param questionnaireValidationResult the questionnaire validation result + */ + public void setQuestionnaireValidationResult( + QuestionnaireValidationResult questionnaireValidationResult) { + this.questionnaireValidationResult = questionnaireValidationResult; + if (questionnaireValidationResult != null && !questionnaireValidationResult.isValid()) { + valid = false; + } + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/VersionedVendorSoftwareProductInfo.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/VersionedVendorSoftwareProductInfo.java new file mode 100644 index 0000000000..cbc81da1ee --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/VersionedVendorSoftwareProductInfo.java @@ -0,0 +1,53 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.types; + +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.VspDetails; + +public class VersionedVendorSoftwareProductInfo { + private VspDetails vspDetails; + private org.openecomp.sdc.versioning.types.VersionInfo versionInfo; + + public VersionedVendorSoftwareProductInfo() { + } + + public VersionedVendorSoftwareProductInfo(VspDetails vspDetails, + org.openecomp.sdc.versioning.types.VersionInfo versionInfo) { + this.vspDetails = vspDetails; + this.versionInfo = versionInfo; + } + + public VspDetails getVspDetails() { + return vspDetails; + } + + public void setVspDetails(VspDetails vspDetails) { + this.vspDetails = vspDetails; + } + + public org.openecomp.sdc.versioning.types.VersionInfo getVersionInfo() { + return versionInfo; + } + + public void setVersionInfo(org.openecomp.sdc.versioning.types.VersionInfo versionInfo) { + this.versionInfo = versionInfo; + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/schemagenerator/ComponentCompositionSchemaInput.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/schemagenerator/ComponentCompositionSchemaInput.java new file mode 100644 index 0000000000..7fb5ec890b --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/schemagenerator/ComponentCompositionSchemaInput.java @@ -0,0 +1,43 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.types.schemagenerator; + +public class ComponentCompositionSchemaInput implements SchemaTemplateInput { + private boolean manual; + private org.openecomp.sdc.vendorsoftwareproduct.types.composition.ComponentData component; + + public boolean isManual() { + return manual; + } + + public void setManual(boolean manual) { + this.manual = manual; + } + + public org.openecomp.sdc.vendorsoftwareproduct.types.composition.ComponentData getComponent() { + return component; + } + + public void setComponent( + org.openecomp.sdc.vendorsoftwareproduct.types.composition.ComponentData component) { + this.component = component; + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/schemagenerator/ComponentQuestionnaireSchemaInput.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/schemagenerator/ComponentQuestionnaireSchemaInput.java new file mode 100644 index 0000000000..1f92e6d957 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/schemagenerator/ComponentQuestionnaireSchemaInput.java @@ -0,0 +1,42 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.types.schemagenerator; + +import java.util.List; +import java.util.Map; + +public class ComponentQuestionnaireSchemaInput implements SchemaTemplateInput { + private List nicNames; + private Map componentQuestionnaireData; + + public ComponentQuestionnaireSchemaInput(List nicNames, Map componentQuestionnaireData) { + this.nicNames = nicNames; + this.componentQuestionnaireData = componentQuestionnaireData; + } + + public List getNicNames() { + return nicNames; + } + + public Map getComponentQuestionnaireData() { + return componentQuestionnaireData; + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/schemagenerator/MibUploadStatus.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/schemagenerator/MibUploadStatus.java new file mode 100644 index 0000000000..046d53054e --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/schemagenerator/MibUploadStatus.java @@ -0,0 +1,51 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.types.schemagenerator; + +public class MibUploadStatus { + private String snmpTrap; + private String snmpPoll; + + + public MibUploadStatus(String snmpTrap, String snmpPoll) { + this.snmpTrap = snmpTrap; + this.snmpPoll = snmpPoll; + } + + public MibUploadStatus() { + } + + public String getSnmpTrap() { + return snmpTrap; + } + + public void setSnmpTrap(String snmpTrap) { + this.snmpTrap = snmpTrap; + } + + public String getSnmpPoll() { + return snmpPoll; + } + + public void setSnmpPoll(String snmpPoll) { + this.snmpPoll = snmpPoll; + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/schemagenerator/NetworkCompositionSchemaInput.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/schemagenerator/NetworkCompositionSchemaInput.java new file mode 100644 index 0000000000..456b4409fd --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/schemagenerator/NetworkCompositionSchemaInput.java @@ -0,0 +1,43 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.types.schemagenerator; + +public class NetworkCompositionSchemaInput implements SchemaTemplateInput { + private boolean manual; + private org.openecomp.sdc.vendorsoftwareproduct.types.composition.Network network; + + public boolean isManual() { + return manual; + } + + public void setManual(boolean manual) { + this.manual = manual; + } + + public org.openecomp.sdc.vendorsoftwareproduct.types.composition.Network getNetwork() { + return network; + } + + public void setNetwork(org.openecomp.sdc.vendorsoftwareproduct.types.composition + .Network network) { + this.network = network; + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/schemagenerator/NicCompositionSchemaInput.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/schemagenerator/NicCompositionSchemaInput.java new file mode 100644 index 0000000000..87693a492c --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/schemagenerator/NicCompositionSchemaInput.java @@ -0,0 +1,55 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.types.schemagenerator; + +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.Nic; + +import java.util.Collection; + +public class NicCompositionSchemaInput implements SchemaTemplateInput { + private boolean manual; + private Nic nic; + private Collection networkIds; + + public boolean isManual() { + return manual; + } + + public void setManual(boolean manual) { + this.manual = manual; + } + + public Nic getNic() { + return nic; + } + + public void setNic(Nic nic) { + this.nic = nic; + } + + public Collection getNetworkIds() { + return networkIds; + } + + public void setNetworkIds(Collection networkIds) { + this.networkIds = networkIds; + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/schemagenerator/SchemaTemplateContext.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/schemagenerator/SchemaTemplateContext.java new file mode 100644 index 0000000000..3ee3e4a5e6 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/schemagenerator/SchemaTemplateContext.java @@ -0,0 +1,26 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.types.schemagenerator; + +public enum SchemaTemplateContext { + composition, + questionnaire +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/schemagenerator/SchemaTemplateInput.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/schemagenerator/SchemaTemplateInput.java new file mode 100644 index 0000000000..93e614f98b --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/schemagenerator/SchemaTemplateInput.java @@ -0,0 +1,25 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.types.schemagenerator; + +public interface SchemaTemplateInput { + +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/util/CompilationUtil.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/util/CompilationUtil.java new file mode 100644 index 0000000000..54038bcd73 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/util/CompilationUtil.java @@ -0,0 +1,126 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.util; + +import org.openecomp.core.enrichment.types.ComponentArtifactType; +import org.openecomp.core.enrichment.types.ComponentCeilometerInfo; +import org.openecomp.core.enrichment.types.ComponentMibInfo; +import org.openecomp.core.enrichment.types.MibInfo; +import org.openecomp.core.utilities.applicationconfig.ApplicationConfig; +import org.openecomp.core.utilities.applicationconfig.ApplicationConfigFactory; +import org.openecomp.core.utilities.json.JsonUtil; +import org.openecomp.sdc.datatypes.error.ErrorMessage; +import org.openecomp.sdc.enrichment.impl.tosca.ComponentInfo; +import org.openecomp.sdc.vendorsoftwareproduct.dao.ComponentArtifactDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.ComponentArtifactDaoFactory; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentArtifactEntity; +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.io.File; +import java.util.List; +import java.util.Map; + +/** + * The type Compilation util. + */ +public class CompilationUtil { + + private static final ApplicationConfig applicationConfig = + ApplicationConfigFactory.getInstance().createInterface(); + private static final ComponentArtifactDao componentArtifactDao = + ComponentArtifactDaoFactory.getInstance().createInterface(); + + /** + * Add monitoring info. + * + * @param componentInfo the component info + * @param compileErrors the compile errors + */ + public static void addMonitoringInfo(ComponentInfo componentInfo, + Map> compileErrors) { + + String ceilometerJson = + applicationConfig.getConfigurationData("vsp.monitoring", "component.ceilometer").getValue(); + ComponentCeilometerInfo ceilometerInfo = + JsonUtil.json2Object(ceilometerJson, ComponentCeilometerInfo.class); + componentInfo.setCeilometerInfo(ceilometerInfo); + } + + /** + * Add mib info. + * + * @param vspId the vsp id + * @param version the version + * @param componentEntity the component entity + * @param componentInfo the component info + * @param compileErrors the compile errors + */ + public static void addMibInfo(String vspId, Version version, org.openecomp.sdc + .vendorsoftwareproduct.dao.type.ComponentEntity componentEntity, + ComponentInfo componentInfo, + Map> compileErrors) { + + String componentId = componentEntity.getId(); + + ComponentArtifactEntity entity = new ComponentArtifactEntity(); + entity.setVspId(vspId); + entity.setVersion(version); + entity.setComponentId(componentId); + + ComponentMibInfo componentMibInfo = new ComponentMibInfo(); + + extractAndInsertMibContentToComponentInfo(componentId, ComponentArtifactType.SNMP_POLL, entity, + componentMibInfo, compileErrors); + extractAndInsertMibContentToComponentInfo(componentId, ComponentArtifactType.SNMP_TRAP, entity, + componentMibInfo, compileErrors); + componentInfo.setMibInfo(componentMibInfo); + } + + private static void extractAndInsertMibContentToComponentInfo(String componentId, + ComponentArtifactType type, + ComponentArtifactEntity componentArtifactEntity, + ComponentMibInfo componentMibInfo, + Map> compileErrors) { + String path; + componentArtifactEntity.setType(type); + ComponentArtifactEntity artifact = + componentArtifactDao.getArtifactByType(componentArtifactEntity); + + if (artifact == null) { + return; + } + path = componentId + File.separator + type.name(); + MibInfo mibInfo = new MibInfo(); + mibInfo.setName(path); + mibInfo.setContent(artifact.getArtifact().array()); + switch (type) { + case SNMP_POLL: + componentMibInfo.setSnmpPoll(mibInfo); + break; + case SNMP_TRAP: + componentMibInfo.setSnmpTrap(mibInfo); + break; + default: + } + + + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/util/VendorSoftwareProductUtils.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/util/VendorSoftwareProductUtils.java new file mode 100644 index 0000000000..62e8dd8b87 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/util/VendorSoftwareProductUtils.java @@ -0,0 +1,254 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.util; + +import org.apache.commons.collections4.CollectionUtils; +import org.apache.commons.collections4.MapUtils; +import org.openecomp.core.enrichment.types.ComponentArtifactType; +import org.openecomp.core.translator.api.HeatToToscaTranslator; +import org.openecomp.core.translator.datatypes.TranslatorOutput; +import org.openecomp.core.translator.factory.HeatToToscaTranslatorFactory; +import org.openecomp.core.utilities.file.FileContentHandler; +import org.openecomp.core.utilities.file.FileUtils; +import org.openecomp.core.validation.errors.Messages; +import org.openecomp.core.validation.types.MessageContainerUtil; +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; +import org.openecomp.sdc.common.utils.AsdcCommon; +import org.openecomp.sdc.datatypes.error.ErrorMessage; +import org.openecomp.sdc.heat.datatypes.structure.HeatStructureTree; +import org.openecomp.sdc.heat.datatypes.structure.ValidationStructureList; +import org.openecomp.sdc.heat.services.tree.HeatTreeManager; +import org.openecomp.sdc.heat.services.tree.HeatTreeManagerUtil; +import org.openecomp.sdc.vendorsoftwareproduct.dao.VendorSoftwareProductDaoFactory; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentArtifactEntity; +import org.openecomp.sdc.vendorsoftwareproduct.types.UploadFileResponse; + +import java.io.ByteArrayInputStream; +import java.io.File; +import java.io.IOException; +import java.io.InputStream; +import java.util.ArrayList; +import java.util.Collection; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.zip.ZipEntry; +import java.util.zip.ZipInputStream; + +/** + * The type Vendor software product utils. + */ +public class VendorSoftwareProductUtils { + + private static org.openecomp.sdc.vendorsoftwareproduct.dao.VendorSoftwareProductDao + vendorSoftwareProductDao = + VendorSoftwareProductDaoFactory.getInstance().createInterface(); + + /** + * Load upload file content file content handler. + * + * @param uploadedFileData the uploaded file data + * @return the file content handler + * @throws IOException the io exception + */ + public static FileContentHandler loadUploadFileContent(byte[] uploadedFileData) + throws IOException { + return getFileContentMapFromZip(uploadedFileData); + } + + private static FileContentHandler getFileContentMapFromZip(byte[] uploadFileData) + throws IOException, CoreException { + ZipEntry zipEntry; + List folderList = new ArrayList<>(); + FileContentHandler mapFileContent = new FileContentHandler(); + try { + ZipInputStream inputZipStream; + + byte[] fileByteContent; + String currentEntryName; + inputZipStream = new ZipInputStream(new ByteArrayInputStream(uploadFileData)); + + while ((zipEntry = inputZipStream.getNextEntry()) != null) { + currentEntryName = zipEntry.getName(); + // else, get the file content (as byte array) and save it in a map. + fileByteContent = FileUtils.toByteArray(inputZipStream); + + int index = lastIndexFileSeparatorIndex(currentEntryName); + String currSubstringWithoutSeparator = + currentEntryName.substring(index + 1, currentEntryName.length()); + if (index != -1) { //todo ? + folderList.add(currentEntryName); + } else { + mapFileContent.addFile(currentEntryName, fileByteContent); + } + + } + + } catch (RuntimeException e0) { + throw new IOException(e0); + } + + if (CollectionUtils.isNotEmpty(folderList)) { + throw new CoreException((new ErrorCode.ErrorCodeBuilder()) + .withMessage(Messages.ZIP_SHOULD_NOT_CONTAIN_FOLDERS.getErrorMessage()) + .withId(Messages.ZIP_SHOULD_NOT_CONTAIN_FOLDERS.getErrorMessage()) + .withCategory(ErrorCategory.APPLICATION).build()); + } + + return mapFileContent; + } + + /** + * Load and translate template data translator output. + * + * @param fileNameContentMap the file name content map + * @return the translator output + */ + public static TranslatorOutput loadAndTranslateTemplateData( + FileContentHandler fileNameContentMap) { + HeatToToscaTranslator heatToToscaTranslator = + HeatToToscaTranslatorFactory.getInstance().createInterface(); + InputStream fileContent = fileNameContentMap.getFileContent(AsdcCommon.MANIFEST_NAME); + + heatToToscaTranslator.addManifest(AsdcCommon.MANIFEST_NAME, FileUtils.toByteArray(fileContent)); + + fileNameContentMap.getFileList().stream() + .filter(fileName -> !(fileName.equals(AsdcCommon.MANIFEST_NAME))).forEach( + fileName -> heatToToscaTranslator + .addFile(fileName, FileUtils.toByteArray(fileNameContentMap.getFileContent(fileName)))); + + Map> errors = heatToToscaTranslator.validate(); + if (MapUtils.isNotEmpty(MessageContainerUtil.getMessageByLevel( + org.openecomp.sdc.datatypes.error.ErrorLevel.ERROR, errors))) { + TranslatorOutput translatorOutput = new TranslatorOutput(); + translatorOutput.setErrorMessages(errors); + return translatorOutput; + } + + InputStream structureFile = getHeatStructureTreeFile(fileNameContentMap); + heatToToscaTranslator.addExternalArtifacts(AsdcCommon.HEAT_META, structureFile); + return heatToToscaTranslator.translate(); + } + + private static InputStream getHeatStructureTreeFile(FileContentHandler fileNameContentMap) { + HeatTreeManager heatTreeManager = HeatTreeManagerUtil.initHeatTreeManager(fileNameContentMap); + heatTreeManager.createTree(); + HeatStructureTree tree = heatTreeManager.getTree(); + ValidationStructureList validationStructureList = new ValidationStructureList(tree); + return FileUtils.convertToInputStream(validationStructureList, FileUtils.FileExtension.JSON); + } + + + private static int lastIndexFileSeparatorIndex(String filePath) { + int length = filePath.length() - 1; + + for (int i = length; i >= 0; i--) { + char currChar = filePath.charAt(i); + if (currChar == '/' || currChar == File.separatorChar || currChar == File.pathSeparatorChar) { + return i; + } + } + // if we've reached to the start of the string and didn't find file separator - return -1 + return -1; + } + + /** + * Add file names to upload file response. + * + * @param fileContentMap the file content map + * @param uploadFileResponse the upload file response + */ + public static void addFileNamesToUploadFileResponse(FileContentHandler fileContentMap, + UploadFileResponse uploadFileResponse) { + uploadFileResponse.setFileNames(new ArrayList<>()); + for (String filename : fileContentMap.getFileList()) { + if (!new File(filename).isDirectory()) { + uploadFileResponse.addNewFileToList(filename); + } + } + uploadFileResponse.removeFileFromList(AsdcCommon.MANIFEST_NAME); + } + + /** + * Validate raw zip data. + * + * @param uploadedFileData the uploaded file data + * @param errors the errors + */ + public static void validateRawZipData(byte[] uploadedFileData, + Map> errors) { + if (uploadedFileData.length == 0) { + ErrorMessage.ErrorMessageUtil.addMessage(AsdcCommon.UPLOAD_FILE, errors).add( + new ErrorMessage(org.openecomp.sdc.datatypes.error.ErrorLevel.ERROR, + Messages.NO_ZIP_FILE_WAS_UPLOADED_OR_ZIP_NOT_EXIST.getErrorMessage())); + } + } + + /** + * Validate content zip data. + * + * @param contentMap the content map + * @param errors the errors + */ + public static void validateContentZipData(FileContentHandler contentMap, + Map> errors) { + if (contentMap == null) { + ErrorMessage.ErrorMessageUtil.addMessage(AsdcCommon.UPLOAD_FILE, errors).add( + new ErrorMessage(org.openecomp.sdc.datatypes.error.ErrorLevel.ERROR, + Messages.ZIP_SHOULD_NOT_CONTAIN_FOLDERS.getErrorMessage())); + + } else if (contentMap.getFileList().size() == 0) { + ErrorMessage.ErrorMessageUtil.addMessage(AsdcCommon.UPLOAD_FILE, errors) + .add(new ErrorMessage(org.openecomp.sdc.datatypes.error.ErrorLevel.ERROR, + Messages.INVALID_ZIP_FILE.getErrorMessage())); + } + } + + + /** + * Filter non trap or poll artifacts map. + * + * @param artifacts the artifacts + * @return the map + */ + public static Map filterNonTrapOrPollArtifacts( + Collection artifacts) { + Map artifactTypeToFilename = new HashMap<>(); + + for (ComponentArtifactEntity entity : artifacts) { + if (isTrapOrPoll(entity.getType())) { + artifactTypeToFilename.put(entity.getType(), entity.getArtifactName()); + } + } + + return artifactTypeToFilename; + } + + + private static boolean isTrapOrPoll(ComponentArtifactType type) { + return type.equals(ComponentArtifactType.SNMP_POLL) + || type.equals(ComponentArtifactType.SNMP_TRAP); + } + + +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/ComponentProcessesTest.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/ComponentProcessesTest.java new file mode 100644 index 0000000000..cfc2e111ac --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/ComponentProcessesTest.java @@ -0,0 +1,46 @@ +package org.openecomp.sdc.vendorsoftwareproduct; + +import org.testng.annotations.BeforeClass; + +public class ComponentProcessesTest extends ProcessesTest { + + @BeforeClass + @Override + protected void init() { +// super.init(); +// +// org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity +// comp11 = new org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity(vsp1Id, null, null); +// org.openecomp.sdc.vendorsoftwareproduct.types.composition.ComponentData +// compData11 = new org.openecomp.sdc.vendorsoftwareproduct.types.composition.ComponentData(); +// compData11.setName("c11 name"); +// compData11.setDescription("c11 desc"); +// comp11.setComponentCompositionData(compData11); +// +//// component11Id = vendorSoftwareProductManager.createComponent(comp11, USER1).getId(); +// +// org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity +// comp21 = new org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity(vsp2Id, null, null); +// org.openecomp.sdc.vendorsoftwareproduct.types.composition.ComponentData +// compData21 = new org.openecomp.sdc.vendorsoftwareproduct.types.composition.ComponentData(); +// compData21.setName("c21 name"); +// compData21.setDescription("c21 desc"); +// comp21.setComponentCompositionData(compData21); + +// component21Id = vendorSoftwareProductManager.createComponent(comp21, USER1).getId(); + } + + @Override + public void testCreateWithExistingNameUnderOtherComponent() { +// org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity +// comp12 = new org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity(vsp1Id, null, null); +// org.openecomp.sdc.vendorsoftwareproduct.types.composition.ComponentData +// compData12 = new org.openecomp.sdc.vendorsoftwareproduct.types.composition.ComponentData(); +// compData12.setName("c12 name"); +// compData12.setDescription("c12 desc"); +// comp12.setComponentCompositionData(compData12); +// +// String component12Id = vendorSoftwareProductManager.createComponent(comp12, USER1).getId(); +// testCreate(vsp1Id, component12Id); + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/ComponentsTest.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/ComponentsTest.java new file mode 100644 index 0000000000..ff33bcb9ee --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/ComponentsTest.java @@ -0,0 +1,329 @@ +package org.openecomp.sdc.vendorsoftwareproduct; + +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.vendorsoftwareproduct.dao.VendorSoftwareProductDaoFactory; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.VspDetails; +import org.openecomp.sdc.vendorsoftwareproduct.errors.VendorSoftwareProductErrorCodes; +import org.openecomp.sdc.vendorsoftwareproduct.impl.VendorSoftwareProductManagerImpl; +import org.openecomp.sdc.vendorsoftwareproduct.types.CompositionEntityResponse; +import org.openecomp.sdc.vendorsoftwareproduct.types.CompositionEntityValidationData; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.ComponentData; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.errors.VersioningErrorCodes; +import org.openecomp.core.utilities.CommonMethods; + +import org.testng.Assert; +import org.testng.annotations.BeforeClass; +import org.testng.annotations.Test; + +import java.util.Collection; + +public class ComponentsTest { + + private static final String USER1 = "componentsTestUser1"; + private static final String USER2 = "componentsTestUser2"; + private static final Version VERSION01 = new Version(0, 1); + private static final VendorSoftwareProductManager vendorSoftwareProductManager = + new VendorSoftwareProductManagerImpl(); + private static final org.openecomp.sdc.vendorsoftwareproduct.dao.VendorSoftwareProductDao + vendorSoftwareProductDao = + VendorSoftwareProductDaoFactory.getInstance().createInterface(); + + private static String vsp1Id; + private static String vsp2Id; + private static String comp1Id = "1"; + private static String comp2Id = "2"; + + static org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity createComponent(String vspId, Version version, String compId) { + org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity + componentEntity = new org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity(vspId, version, compId); + ComponentData compData = new ComponentData(); + compData.setName(compId + " name"); + compData.setDisplayName(compId + " display name"); + compData.setDescription(compId + " desc"); + componentEntity.setComponentCompositionData(compData); + vendorSoftwareProductDao.createComponent(componentEntity); + return componentEntity; + } + + @BeforeClass + private void init() { + VspDetails vsp1 = vendorSoftwareProductManager.createNewVsp(VSPCommon + .createVspDetails(null, null, "VSP_" + CommonMethods.nextUuId(), "Test-vsp1", "vendorName", + "vlm1Id", "icon", "category", "subCategory", "123", null), USER1); + vsp1Id = vsp1.getId(); + + VspDetails vsp2 = vendorSoftwareProductManager.createNewVsp(VSPCommon + .createVspDetails(null, null, "VSP_" + CommonMethods.nextUuId(), "Test-vsp2", "vendorName", + "vlm1Id", "icon", "category", "subCategory", "123", null), USER1); + vsp2Id = vsp2.getId(); + } + + @Test + public void testListWhenNone() { + Collection components = + vendorSoftwareProductManager.listComponents(vsp1Id, null, USER1); + Assert.assertEquals(components.size(), 0); + } + + @Test + public void testCreateNonExistingVspId_negative() { + testCreate_negative(new org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity("non existing vsp id", null, null), USER1, + VersioningErrorCodes.VERSIONABLE_ENTITY_NOT_EXIST); + } + + @Test + public void testCreateOnLockedVsp_negative() { + testCreate_negative(new org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity(vsp1Id, null, null), USER2, + VersioningErrorCodes.EDIT_ON_ENTITY_LOCKED_BY_OTHER_USER); + } + +/* @Test(dependsOnMethods = "testListWhenNone") + public void testCreate() { + comp1Id = testCreate(vsp1Id); + } + + private String testCreate(String vspId) { + ComponentEntity expected = new ComponentEntity(vspId, null, null); + ComponentData compData = new ComponentData(); + compData.setName("comp1 name"); + compData.setDescription("comp1 desc"); + expected.setComponentCompositionData(compData); + + ComponentEntity created = vendorSoftwareProductManager.createComponent(expected, USER1); + Assert.assertNotNull(created); + expected.setId(created.getId()); + expected.setVersion(VERSION01); + + ComponentEntity actual = vendorSoftwareProductDao.getComponent(vspId, VERSION01, created.getId()); + + Assert.assertEquals(actual, expected); + return created.getId(); + }*/ + +/* @Test(dependsOnMethods = {"testCreate"}) + public void testCreateWithExistingName_negative() { + ComponentEntity component = new ComponentEntity(vsp1Id, null, null); + ComponentData compData = new ComponentData(); + compData.setName("comp1 name"); + compData.setDescription("comp1 desc"); + component.setComponentCompositionData(compData); + testCreate_negative(component, USER1, UniqueValueUtil.UNIQUE_VALUE_VIOLATION); + }*/ + +/* @Test(dependsOnMethods = {"testCreate"}) + public void testCreateWithExistingNameUnderOtherVsp() { + testCreate(vsp2Id); + }*/ + + @Test + public void testCreateOnUploadVsp_negative() { + testCreate_negative(new org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity(vsp1Id, null, null), USER1, + VendorSoftwareProductErrorCodes.VSP_COMPOSITION_EDIT_NOT_ALLOWED); + } + + @Test + public void testGetNonExistingComponentId_negative() { + testGet_negative(vsp1Id, null, "non existing component id", USER1, + VersioningErrorCodes.VERSIONABLE_SUB_ENTITY_NOT_FOUND); + } + + @Test + public void testGetNonExistingVspId_negative() { + testGet_negative("non existing vsp id", null, comp1Id, USER1, + VersioningErrorCodes.VERSIONABLE_ENTITY_NOT_EXIST); + } + + @Test(dependsOnMethods = "testListWhenNone")//"testCreate") + public void testGet() { + org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity + expected = createComponent(vsp1Id, VERSION01, comp1Id); + testGet(vsp1Id, VERSION01, comp1Id, USER1, expected); + } + + @Test + public void testUpdateNonExistingComponentId_negative() { + testUpdate_negative(vsp1Id, "non existing component id", USER1, + VersioningErrorCodes.VERSIONABLE_SUB_ENTITY_NOT_FOUND); + } + + @Test + public void testUpdateNonExistingVspId_negative() { + testUpdate_negative("non existing vsp id", comp1Id, USER1, + VersioningErrorCodes.VERSIONABLE_ENTITY_NOT_EXIST); + } + + @Test(dependsOnMethods = {"testGet"}) + public void testUpdateOnUploadVsp() { + org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity + expected = new org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity(vsp1Id, null, comp1Id); + ComponentData compData = new ComponentData(); + compData.setName(comp1Id + " name"); // no change + compData.setDisplayName(comp1Id + " display name"); // no change + compData.setDescription(comp1Id + " desc updated"); // allowed change + expected.setComponentCompositionData(compData); + + CompositionEntityValidationData validationData = + vendorSoftwareProductManager.updateComponent(expected, USER1); + Assert.assertTrue(validationData == null || validationData.getErrors() == null); + expected.setVersion(VERSION01); + + org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity actual = vendorSoftwareProductDao.getComponent(vsp1Id, VERSION01, comp1Id); + Assert.assertEquals(actual, expected); + } + + @Test(dependsOnMethods = {"testUpdateOnUploadVsp"}) + public void testIllegalUpdateOnUploadVsp() { + org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity + expected = new org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity(vsp1Id, null, comp1Id); + ComponentData compData = new ComponentData(); + compData + .setName("comp1 name updated"); // not allowed: changed name + omitted display name + expected.setComponentCompositionData(compData); + + CompositionEntityValidationData validationData = + vendorSoftwareProductManager.updateComponent(expected, USER1); + Assert.assertNotNull(validationData); + Assert.assertEquals(validationData.getErrors().size(), 2); + } + + @Test + public void testListNonExistingVspId_negative() { + testList_negative("non existing vsp id", null, USER1, + VersioningErrorCodes.VERSIONABLE_ENTITY_NOT_EXIST); + } +/* + @Test(dependsOnMethods = {"testUpdateOnUploadVsp", "testList"}) + public void testCreateWithERemovedName() { + testCreate(vsp1Id); + } + + @Test(dependsOnMethods = "testList") + public void testDeleteNonExistingComponentId_negative() { + testDelete_negative(vsp1Id, "non existing component id", USER1, VersioningErrorCodes.VERSIONABLE_SUB_ENTITY_NOT_FOUND); + }*/ + + @Test(dependsOnMethods = {"testGet"}) + public void testList() { + org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity + createdP2 = createComponent(vsp1Id, VERSION01, comp2Id); + + Collection actual = + vendorSoftwareProductManager.listComponents(vsp1Id, null, USER1); + Assert.assertEquals(actual.size(), 2); + } + + @Test + public void testDeleteNonExistingVspId_negative() { + testDelete_negative("non existing vsp id", comp1Id, USER1, + VersioningErrorCodes.VERSIONABLE_ENTITY_NOT_EXIST); + } +/* + @Test(dependsOnMethods = "testList") + public void testDelete() { + vendorSoftwareProductManager.deleteComponent(vsp1Id, comp1Id, USER1); + ComponentEntity actual = vendorSoftwareProductDao.getComponent(vsp1Id, VERSION01, comp1Id); + Assert.assertNull(actual); + }*/ + + @Test + public void testDeleteOnUploadVsp_negative() { + testDelete_negative(vsp1Id, comp1Id, USER1, + VendorSoftwareProductErrorCodes.VSP_COMPOSITION_EDIT_NOT_ALLOWED); + } + + @Test + public void testDeleteListNonExistingVspId_negative() { + testDeleteList_negative("non existing vsp id", USER1, + VersioningErrorCodes.VERSIONABLE_ENTITY_NOT_EXIST); + } +/* + @Test(dependsOnMethods = "testDelete") + public void testDeleteList() { + ComponentEntity comp3 = new ComponentEntity(vsp1Id, null, null); + comp3.setName("comp3 name"); + comp3.setDescription("comp3 desc"); + vendorSoftwareProductManager.createComponent(comp3, USER1); + + vendorSoftwareProductManager.deleteComponents(vsp1Id, USER1); + + Collection actual = vendorSoftwareProductManager.listComponents(vsp1Id, null, USER1); + Assert.assertEquals(actual.size(), 0); + }*/ + + @Test + public void testDeleteListOnUploadVsp_negative() { + testDeleteList_negative(vsp1Id, USER1, + VendorSoftwareProductErrorCodes.VSP_COMPOSITION_EDIT_NOT_ALLOWED); + } + + private void testGet(String vspId, Version version, String componentId, String user, + org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity expected) { + CompositionEntityResponse response = + vendorSoftwareProductManager.getComponent(vspId, null, componentId, user); + Assert.assertEquals(response.getId(), expected.getId()); + Assert.assertEquals(response.getData(), expected.getComponentCompositionData()); + Assert.assertNotNull(response.getSchema()); + } + + private void testCreate_negative( + org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity component, String user, + String expectedErrorCode) { + try { + vendorSoftwareProductManager.createComponent(component, user); + Assert.fail(); + } catch (CoreException e) { + Assert.assertEquals(e.code().id(), expectedErrorCode); + } + } + + private void testGet_negative(String vspId, Version version, String componentId, String user, + String expectedErrorCode) { + try { + vendorSoftwareProductManager.getComponent(vspId, version, componentId, user); + Assert.fail(); + } catch (CoreException e) { + Assert.assertEquals(e.code().id(), expectedErrorCode); + } + } + + private void testUpdate_negative(String vspId, String componentId, String user, + String expectedErrorCode) { + try { + vendorSoftwareProductManager + .updateComponent(new org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity(vspId, null, componentId), user); + Assert.fail(); + } catch (CoreException e) { + Assert.assertEquals(e.code().id(), expectedErrorCode); + } + } + + private void testList_negative(String vspId, Version version, String user, + String expectedErrorCode) { + try { + vendorSoftwareProductManager.listComponents(vspId, version, user); + Assert.fail(); + } catch (CoreException e) { + Assert.assertEquals(e.code().id(), expectedErrorCode); + } + } + + private void testDeleteList_negative(String vspId, String user, String expectedErrorCode) { + try { + vendorSoftwareProductManager.deleteComponents(vspId, user); + Assert.fail(); + } catch (CoreException e) { + Assert.assertEquals(e.code().id(), expectedErrorCode); + } + } + + private void testDelete_negative(String vspId, String componentId, String user, + String expectedErrorCode) { + try { + vendorSoftwareProductManager.deleteComponent(vspId, componentId, user); + Assert.fail(); + } catch (CoreException e) { + Assert.assertEquals(e.code().id(), expectedErrorCode); + } + } +} \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/ComponentsUploadTest.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/ComponentsUploadTest.java new file mode 100644 index 0000000000..0819d89851 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/ComponentsUploadTest.java @@ -0,0 +1,159 @@ +package org.openecomp.sdc.vendorsoftwareproduct; + +import org.openecomp.sdc.vendorlicense.facade.VendorLicenseFacade; +import org.openecomp.sdc.vendorlicense.facade.VendorLicenseFacadeFactory; +import org.openecomp.sdc.vendorsoftwareproduct.dao.VendorSoftwareProductDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.VendorSoftwareProductDaoFactory; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.VspDetails; +import org.openecomp.sdc.vendorsoftwareproduct.impl.VendorSoftwareProductManagerImpl; +import org.openecomp.sdc.vendorsoftwareproduct.types.schemagenerator.MibUploadStatus; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.core.util.UniqueValueUtil; +import org.openecomp.core.utilities.CommonMethods; + +import org.testng.Assert; +import org.testng.annotations.BeforeTest; +import org.testng.annotations.Test; + +import java.io.IOException; +import java.io.InputStream; +import java.net.URL; + +public class ComponentsUploadTest { + + private static final String USER1 = "vspTestUser1"; + + private static VendorSoftwareProductManager vendorSoftwareProductManager = + new VendorSoftwareProductManagerImpl(); + private static VendorSoftwareProductDao vendorSoftwareProductDao = + VendorSoftwareProductDaoFactory.getInstance().createInterface(); + private static VendorLicenseFacade vendorLicenseFacade = + VendorLicenseFacadeFactory.getInstance().createInterface(); + + private static String vspId = null; + private static Version activeVersion = null; + private static String trapFileName = "MMSC.zip"; + private static String pollFileName = "MNS OAM FW.zip"; + private static String notZipFileName = "notZipFile"; + private static String zipWithFoldersFileName = "zipFileWithFolder.zip"; + private static String emptyZipFileName = "emptyZip.zip"; + private String vlm1Id; + private String componentId; + + @BeforeTest + private void init() { + UniqueValueUtil + .deleteUniqueValue(VendorSoftwareProductConstants.UniqueValues.VENDOR_SOFTWARE_PRODUCT_NAME, + "VSPTestMib"); + vlm1Id = vendorLicenseFacade.createVendorLicenseModel(VSPCommon + .createVendorLicenseModel("vlmName " + CommonMethods.nextUuId(), "vlm1Id desc", "icon1"), + USER1).getId(); + VspDetails vspDetails = vendorSoftwareProductManager.createNewVsp(VSPCommon + .createVspDetails(null, null, "VSPTestMib", "Test-vsp-mib", "vendorName", vlm1Id, "icon", + "category", "subCategory", "123", null), USER1); + + vspId = vspDetails.getId(); + activeVersion = vspDetails.getVersion(); + componentId = createComponent(new ComponentEntity(vspId, activeVersion, null)).getId(); + } + + + @Test + public void testUploadAndFilenamesList() { + InputStream zis1 = getFileInputStream("/validation/zips/various/MMSC.zip"); + InputStream zis2 = getFileInputStream("/validation/zips/various/MNS OAM FW.zip"); + + vendorSoftwareProductManager + .uploadComponentMib(zis1, "MMSC.zip", vspId, componentId, true, USER1); + vendorSoftwareProductManager + .uploadComponentMib(zis2, "MNS OAM FW.zip", vspId, componentId, false, USER1); + + MibUploadStatus mibUploadStatus = + vendorSoftwareProductManager.listMibFilenames(vspId, componentId, USER1); + Assert.assertEquals(mibUploadStatus.getSnmpTrap(), trapFileName); + Assert.assertEquals(mibUploadStatus.getSnmpPoll(), pollFileName); + } + + @Test(dependsOnMethods = "testUploadAndFilenamesList") + public void testMibsExistentAfterCheckout() throws IOException { + activeVersion = vendorSoftwareProductManager.checkin(vspId, USER1); +// UniqueValueUtil.deleteUniqueValue(VendorSoftwareProductConstants.UniqueValues.COMPONENT_ARTIFACT_NAME, "MMSC.zip"); +// UniqueValueUtil.deleteUniqueValue(VendorSoftwareProductConstants.UniqueValues.COMPONENT_ARTIFACT_NAME, "MNS OAM FW.zip"); + activeVersion = vendorSoftwareProductManager.checkout(vspId, USER1); + + MibUploadStatus mibUploadStatus = + vendorSoftwareProductManager.listMibFilenames(vspId, componentId, USER1); + Assert.assertNotNull(mibUploadStatus.getSnmpTrap()); + Assert.assertNotNull(mibUploadStatus.getSnmpPoll()); + } + + @Test(dependsOnMethods = "testMibsExistentAfterCheckout") + public void testDeleteFile() { + vendorSoftwareProductManager.deleteComponentMib(vspId, componentId, true, USER1); + vendorSoftwareProductManager.deleteComponentMib(vspId, componentId, false, USER1); + + MibUploadStatus mibUploadStatus = + vendorSoftwareProductManager.listMibFilenames(vspId, componentId, USER1); + Assert.assertNull(mibUploadStatus.getSnmpTrap()); + Assert.assertNull(mibUploadStatus.getSnmpPoll()); + } + + @Test(dependsOnMethods = "testDeleteFile") + public void testUploadInvalidZip() { + URL url = this.getClass().getResource("/notZipFile"); + + try { + vendorSoftwareProductManager + .uploadComponentMib(url.openStream(), notZipFileName, vspId, componentId, true, USER1); + Assert.fail(); + } catch (Exception e) { +// Assert.assertEquals(e.getMessage(), "MIB uploaded for vendor software product with Id " + vspId + " and version " + activeVersion + " is invalid: Invalid zip file"); + Assert.assertEquals(e.getMessage(), "Invalid zip file"); + } + } + + @Test(dependsOnMethods = "testUploadInvalidZip") + public void testUploadZipWithFolders() { + InputStream zis = getFileInputStream("/vspmanager/zips/zipFileWithFolder.zip"); + + try { + vendorSoftwareProductManager + .uploadComponentMib(zis, zipWithFoldersFileName, vspId, componentId, true, USER1); + Assert.fail(); + } catch (Exception e) { + Assert.assertEquals(e.getMessage(), "Zip file should not contain folders"); + } + } + + @Test(dependsOnMethods = "testUploadZipWithFolders") + public void testUploadEmptyZip() { + InputStream zis = getFileInputStream("/vspmanager/zips/emptyZip.zip"); + + try { + vendorSoftwareProductManager + .uploadComponentMib(zis, emptyZipFileName, vspId, componentId, true, USER1); + Assert.fail(); + } catch (Exception e) { + Assert.assertEquals(e.getMessage(), "Invalid zip file"); + } + } + + + private InputStream getFileInputStream(String fileName) { + URL url = this.getClass().getResource(fileName); + try { + return url.openStream(); + } catch (IOException e) { + e.printStackTrace(); + return null; + } + } + + + private ComponentEntity createComponent(ComponentEntity component) { + component.setId(CommonMethods.nextUuId()); + vendorSoftwareProductDao.createComponent(component); + return component; + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/NetworksTest.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/NetworksTest.java new file mode 100644 index 0000000000..2921f19c1b --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/NetworksTest.java @@ -0,0 +1,292 @@ +package org.openecomp.sdc.vendorsoftwareproduct; + +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.vendorsoftwareproduct.dao.VendorSoftwareProductDaoFactory; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.VspDetails; +import org.openecomp.sdc.vendorsoftwareproduct.errors.VendorSoftwareProductErrorCodes; +import org.openecomp.sdc.vendorsoftwareproduct.impl.VendorSoftwareProductManagerImpl; +import org.openecomp.sdc.vendorsoftwareproduct.types.CompositionEntityResponse; +import org.openecomp.sdc.vendorsoftwareproduct.types.CompositionEntityValidationData; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.errors.VersioningErrorCodes; +import org.openecomp.core.utilities.CommonMethods; + +import org.testng.Assert; +import org.testng.annotations.BeforeClass; +import org.testng.annotations.Test; + +import java.util.Collection; + +public class NetworksTest { + + private static final String USER1 = "networksTestUser1"; + private static final String USER2 = "networksTestUser2"; + private static final Version VERSION01 = new Version(0, 1); + private static final VendorSoftwareProductManager vendorSoftwareProductManager = + new VendorSoftwareProductManagerImpl(); + private static final org.openecomp.sdc.vendorsoftwareproduct.dao.VendorSoftwareProductDao + vendorSoftwareProductDao = + VendorSoftwareProductDaoFactory.getInstance().createInterface(); + + private static String vsp1Id; + private static String vsp2Id; + private static String networkId = "1"; + + static org.openecomp.sdc.vendorsoftwareproduct.dao.type.NetworkEntity createNetwork(String vspId, Version version, String networkId) { + org.openecomp.sdc.vendorsoftwareproduct.dao.type.NetworkEntity + networkEntity = new org.openecomp.sdc.vendorsoftwareproduct.dao.type.NetworkEntity(vspId, version, networkId); + org.openecomp.sdc.vendorsoftwareproduct.types.composition.Network + networkData = new org.openecomp.sdc.vendorsoftwareproduct.types.composition.Network(); + networkData.setName(networkId + " name"); + networkData.setDhcp(true); + networkEntity.setNetworkCompositionData(networkData); + vendorSoftwareProductDao.createNetwork(networkEntity); + return networkEntity; + } + + @BeforeClass + private void init() { + VspDetails vsp1 = vendorSoftwareProductManager.createNewVsp(VSPCommon + .createVspDetails(null, null, "VSP_" + CommonMethods.nextUuId(), "Test-vsp1", "vendorName", + "vlm1Id", "icon", "category", "subCategory", "123", null), USER1); + vsp1Id = vsp1.getId(); + + VspDetails vsp2 = vendorSoftwareProductManager.createNewVsp(VSPCommon + .createVspDetails(null, null, "VSP_" + CommonMethods.nextUuId(), "Test-vsp2", "vendorName", + "vlm1Id", "icon", "category", "subCategory", "123", null), USER1); + vsp2Id = vsp2.getId(); + } + + @Test + public void testListWhenNone() { + Collection networks = + vendorSoftwareProductManager.listNetworks(vsp1Id, null, USER1); + Assert.assertEquals(networks.size(), 0); + } + + @Test + public void testCreateNonExistingVspId_negative() { + testCreate_negative(new org.openecomp.sdc.vendorsoftwareproduct.dao.type.NetworkEntity("non existing vsp id", null, null), USER1, + VersioningErrorCodes.VERSIONABLE_ENTITY_NOT_EXIST); + } + + @Test + public void testCreateOnLockedVsp_negative() { + testCreate_negative(new org.openecomp.sdc.vendorsoftwareproduct.dao.type.NetworkEntity(vsp1Id, null, null), USER2, + VersioningErrorCodes.EDIT_ON_ENTITY_LOCKED_BY_OTHER_USER); + } + +/* @Test(dependsOnMethods = "testListWhenNone") + public void testCreate() { + networkId = testCreate(vsp1Id); + } + + private String testCreate(String vspId) { + NetworkEntity expected = new NetworkEntity(vspId, null, null); + Network networkData = new Network(); + networkData.setName("network1 name"); + networkData.setDhcp(true); + expected.setNetworkCompositionData(networkData); + + + NetworkEntity created = vendorSoftwareProductManager.createNetwork(expected, USER1); + Assert.assertNotNull(created); + expected.setId(created.getId()); + expected.setVersion(VERSION01); + + NetworkEntity actual = vendorSoftwareProductDao.getNetwork(vspId, VERSION01, created.getId()); + + Assert.assertEquals(actual, expected); + return created.getId(); + } + + @Test(dependsOnMethods = {"testCreate"}) + public void testCreateWithExistingName_negative() { + NetworkEntity network = new NetworkEntity(vsp1Id, null, null); + Network networkData = new Network(); + networkData.setName("network1 name"); + networkData.setDhcp(true); + network.setNetworkCompositionData(networkData); + testCreate_negative(network, USER1, UniqueValueUtil.UNIQUE_VALUE_VIOLATION); + }*/ + + @Test + public void testCreateOnUploadVsp_negative() { + testCreate_negative(new org.openecomp.sdc.vendorsoftwareproduct.dao.type.NetworkEntity(vsp1Id, null, null), USER1, + VendorSoftwareProductErrorCodes.VSP_COMPOSITION_EDIT_NOT_ALLOWED); + } + + /* @Test(dependsOnMethods = {"testCreate"}) + public void testCreateWithExistingNameUnderOtherVsp() { + testCreate(vsp2Id); + } + */ + @Test(dependsOnMethods = "testListWhenNone")//"testCreate") + public void testGetNonExistingNetworkId_negative() { + testGet_negative(vsp1Id, null, "non existing network id", USER1, + VersioningErrorCodes.VERSIONABLE_SUB_ENTITY_NOT_FOUND); + } + + @Test(dependsOnMethods = "testListWhenNone")//"testCreate") + public void testGetNonExistingVspId_negative() { + testGet_negative("non existing vsp id", null, networkId, USER1, + VersioningErrorCodes.VERSIONABLE_ENTITY_NOT_EXIST); + } + + @Test(dependsOnMethods = "testListWhenNone")//"testCreate") + public void testGet() { + org.openecomp.sdc.vendorsoftwareproduct.dao.type.NetworkEntity + expected = createNetwork(vsp1Id, VERSION01, networkId); + testGet(vsp1Id, VERSION01, networkId, USER1, expected); + } + + @Test(dependsOnMethods = "testListWhenNone")//"testCreate") + public void testUpdateNonExistingNetworkId_negative() { + testUpdate_negative(vsp1Id, "non existing network id", USER1, + VersioningErrorCodes.VERSIONABLE_SUB_ENTITY_NOT_FOUND); + } + + @Test(dependsOnMethods = "testListWhenNone")//"testCreate") + public void testUpdateNonExistingVspId_negative() { + testUpdate_negative("non existing vsp id", networkId, USER1, + VersioningErrorCodes.VERSIONABLE_ENTITY_NOT_EXIST); + } + + @Test(dependsOnMethods = {"testGet"}) + public void testIllegalUpdateOnUploadVsp() { + org.openecomp.sdc.vendorsoftwareproduct.dao.type.NetworkEntity + expected = new org.openecomp.sdc.vendorsoftwareproduct.dao.type.NetworkEntity(vsp1Id, null, networkId); + org.openecomp.sdc.vendorsoftwareproduct.types.composition.Network + networkData = new org.openecomp.sdc.vendorsoftwareproduct.types.composition.Network(); + networkData.setName(networkId + " name updated"); + networkData.setDhcp(false); + expected.setNetworkCompositionData(networkData); + + CompositionEntityValidationData validationData = + vendorSoftwareProductManager.updateNetwork(expected, USER1); + Assert.assertNotNull(validationData); + Assert.assertTrue(validationData.getErrors().size() > 0); + } + + @Test(dependsOnMethods = {"testGet"}) + public void testListNonExistingVspId_negative() { + testList_negative("non existing vsp id", null, USER1, + VersioningErrorCodes.VERSIONABLE_ENTITY_NOT_EXIST); + } + + /* + @Test(dependsOnMethods = {"testUpdateOnUploadVsp", "testList"}) + public void testCreateWithERemovedName() { + testCreate(vsp1Id); + } + + @Test(dependsOnMethods = "testList") + public void testDeleteNonExistingNetworkId_negative() { + testDelete_negative(vsp1Id, "non existing network id", USER1, VersioningErrorCodes.VERSIONABLE_SUB_ENTITY_NOT_FOUND); + }*/ + + @Test(dependsOnMethods = {"testGet"}) + public void testList() { + createNetwork(vsp1Id, VERSION01, "2"); + + Collection actual = + vendorSoftwareProductManager.listNetworks(vsp1Id, null, USER1); + Assert.assertEquals(actual.size(), 2); + } + + @Test(dependsOnMethods = "testList") + public void testDeleteNonExistingVspId_negative() { + testDelete_negative("non existing vsp id", networkId, USER1, + VersioningErrorCodes.VERSIONABLE_ENTITY_NOT_EXIST); + } +/* + @Test(dependsOnMethods = "testList") + public void testDelete() { + vendorSoftwareProductManager.deleteNetwork(vsp1Id, networkId, USER1); + NetworkEntity actual = vendorSoftwareProductDao.getNetwork(vsp1Id, VERSION01, networkId); + Assert.assertNull(actual); + } + + @Test + public void testDeleteListNonExistingVspId_negative() { + testDeleteList_negative("non existing vsp id", USER1, VersioningErrorCodes.VERSIONABLE_ENTITY_NOT_EXIST); + } + + @Test(dependsOnMethods = "testDelete") + public void testDeleteList() { + NetworkEntity network3 = new NetworkEntity(vsp1Id, null, null); + network3.setName("network3 name"); + network3.setDescription("network3 desc"); + vendorSoftwareProductManager.createNetwork(network3, USER1); + + vendorSoftwareProductManager.deleteNetworks(vsp1Id, USER1); + + Collection actual = vendorSoftwareProductManager.listNetworks(vsp1Id, null, USER1); + Assert.assertEquals(actual.size(), 0); + }*/ + + @Test(dependsOnMethods = "testList") + public void testDeleteOnUploadVsp_negative() { + testDelete_negative(vsp1Id, networkId, USER1, + VendorSoftwareProductErrorCodes.VSP_COMPOSITION_EDIT_NOT_ALLOWED); + } + + private void testGet(String vspId, Version version, String networkId, String user, + org.openecomp.sdc.vendorsoftwareproduct.dao.type.NetworkEntity expected) { + CompositionEntityResponse response = + vendorSoftwareProductManager.getNetwork(vspId, null, networkId, user); + Assert.assertEquals(response.getId(), expected.getId()); + Assert.assertEquals(response.getData(), expected.getNetworkCompositionData()); + Assert.assertNotNull(response.getSchema()); + } + + private void testCreate_negative( + org.openecomp.sdc.vendorsoftwareproduct.dao.type.NetworkEntity network, String user, String expectedErrorCode) { + try { + vendorSoftwareProductManager.createNetwork(network, user); + Assert.fail(); + } catch (CoreException e) { + Assert.assertEquals(e.code().id(), expectedErrorCode); + } + } + + private void testGet_negative(String vspId, Version version, String networkId, String user, + String expectedErrorCode) { + try { + vendorSoftwareProductManager.getNetwork(vspId, version, networkId, user); + Assert.fail(); + } catch (CoreException e) { + Assert.assertEquals(e.code().id(), expectedErrorCode); + } + } + + private void testUpdate_negative(String vspId, String networkId, String user, + String expectedErrorCode) { + try { + vendorSoftwareProductManager.updateNetwork(new org.openecomp.sdc.vendorsoftwareproduct.dao.type.NetworkEntity(vspId, null, networkId), user); + Assert.fail(); + } catch (CoreException e) { + Assert.assertEquals(e.code().id(), expectedErrorCode); + } + } + + private void testList_negative(String vspId, Version version, String user, + String expectedErrorCode) { + try { + vendorSoftwareProductManager.listNetworks(vspId, version, user); + Assert.fail(); + } catch (CoreException e) { + Assert.assertEquals(e.code().id(), expectedErrorCode); + } + } + + private void testDelete_negative(String vspId, String networkId, String user, + String expectedErrorCode) { + try { + vendorSoftwareProductManager.deleteNetwork(vspId, networkId, user); + Assert.fail(); + } catch (CoreException e) { + Assert.assertEquals(e.code().id(), expectedErrorCode); + } + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/NicsTest.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/NicsTest.java new file mode 100644 index 0000000000..10ea7f7eaf --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/NicsTest.java @@ -0,0 +1,346 @@ +package org.openecomp.sdc.vendorsoftwareproduct; + +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.vendorsoftwareproduct.errors.VendorSoftwareProductErrorCodes; +import org.openecomp.sdc.vendorsoftwareproduct.impl.VendorSoftwareProductManagerImpl; +import org.openecomp.sdc.vendorsoftwareproduct.types.CompositionEntityResponse; +import org.openecomp.sdc.vendorsoftwareproduct.types.CompositionEntityValidationData; +import org.openecomp.core.utilities.CommonMethods; + +import org.testng.Assert; +import org.testng.annotations.BeforeClass; +import org.testng.annotations.Test; + +import java.util.Collection; + +public class NicsTest { + + private static final String USER1 = "nicsTestUser1"; + private static final String USER2 = "nicsTestUser2"; + private static final org.openecomp.sdc.versioning.dao.types.Version + VERSION01 = new org.openecomp.sdc.versioning.dao.types.Version(0, 1); + private static final VendorSoftwareProductManager vendorSoftwareProductManager = + new VendorSoftwareProductManagerImpl(); + private static final org.openecomp.sdc.vendorsoftwareproduct.dao.VendorSoftwareProductDao + vendorSoftwareProductDao = + org.openecomp.sdc.vendorsoftwareproduct.dao.VendorSoftwareProductDaoFactory.getInstance().createInterface(); + + private static String vsp1Id; + private static String vsp2Id; + private static org.openecomp.sdc.vendorsoftwareproduct.dao.type.NetworkEntity network1; + private static org.openecomp.sdc.vendorsoftwareproduct.dao.type.NetworkEntity network2; + private static String component11Id; + private static String component21Id; + private static String nic1Id = "nic1"; + + static org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity createNic(String vspId, org.openecomp.sdc.versioning.dao.types.Version version, String compId, String nicId, + String networkId) { + org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity + nicEntity = new org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity(vspId, version, compId, nicId); + org.openecomp.sdc.vendorsoftwareproduct.types.composition.Nic + nicData = new org.openecomp.sdc.vendorsoftwareproduct.types.composition.Nic(); + nicData.setName(nicId + " name"); + nicData.setDescription(nicId + " desc"); + nicData.setNetworkId(networkId); + nicEntity.setNicCompositionData(nicData); + vendorSoftwareProductDao.createNic(nicEntity); + return nicEntity; + } + + @BeforeClass + private void init() { + vsp1Id = vendorSoftwareProductManager.createNewVsp(VSPCommon + .createVspDetails(null, null, "VSP_" + CommonMethods.nextUuId(), "Test-vsp1", "vendorName1", + "vlm1Id", "icon", "category", "subCategory", "123", null), USER1).getId(); + network1 = NetworksTest.createNetwork(vsp1Id, VERSION01, "network1"); + component11Id = ComponentsTest.createComponent(vsp1Id, VERSION01, "component11").getId(); + + vsp2Id = vendorSoftwareProductManager.createNewVsp(VSPCommon + .createVspDetails(null, null, "VSP_" + CommonMethods.nextUuId(), "Test-vsp2", "vendorName1", + "vlm1Id", "icon", "category", "subCategory", "123", null), USER1).getId(); + network2 = NetworksTest.createNetwork(vsp2Id, VERSION01, "network2"); + component21Id = ComponentsTest.createComponent(vsp2Id, VERSION01, "component21").getId(); + } + +/* @Test + public void testCreateNonExistingComponentId_negative() { + testCreate_negative(new NicEntity(vsp1Id, null, "non existing component id", null), USER1, VersioningErrorCodes.VERSIONABLE_SUB_ENTITY_NOT_FOUND); + }*/ + + @Test + public void testListWhenNone() { + Collection nics = + vendorSoftwareProductManager.listNics(vsp1Id, null, component11Id, USER1); + Assert.assertEquals(nics.size(), 0); + } + + @Test + public void testCreateNonExistingVspId_negative() { + testCreate_negative(new org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity("non existing vsp id", null, component11Id, null), USER1, + org.openecomp.sdc.versioning.errors.VersioningErrorCodes.VERSIONABLE_ENTITY_NOT_EXIST); + } + + @Test + public void testCreateOnLockedVsp_negative() { + testCreate_negative(new org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity(vsp1Id, null, component11Id, null), USER2, + org.openecomp.sdc.versioning.errors.VersioningErrorCodes.EDIT_ON_ENTITY_LOCKED_BY_OTHER_USER); + } + +// @Test(dependsOnMethods = "testListWhenNone") +// public void testCreate() { +// nic1Id = testCreate(vsp1Id, component11Id, network1.getId(), network1.getNetworkCompositionData().getName()); +// } + +/* @Test(dependsOnMethods = {"testCreate"}) + public void testCreateWithExistingName_negative() { + NicEntity nic = new NicEntity(vsp1Id, null, component11Id, null); + Nic nicData = new Nic(); + nicData.setName("nic1 name"); + nic.setNicCompositionData(nicData); + testCreate_negative(nic, USER1, UniqueValueUtil.UNIQUE_VALUE_VIOLATION); + }*/ + +// @Test(dependsOnMethods = {"testCreate"}) +// public void testCreateWithExistingNameUnderOtherComponent() { +// ComponentEntity component12 = new ComponentEntity(vsp1Id, null, null); +// ComponentData compData12 = new ComponentData(); +// compData12.setName("comp12 name"); +// compData12.setDescription("comp12 desc"); +// component12.setComponentCompositionData(compData12); +// +// String component12Id = vendorSoftwareProductManager.createComponent(component12, USER1).getId(); +// testCreate(vsp1Id, component12Id, network1.getId(), network1.getNetworkCompositionData().getName()); +// } + +// @Test(dependsOnMethods = {"testCreate"}) +// public void testCreateWithExistingNameUnderOtherVsp() { +// testCreate(vsp2Id, component21Id, network2.getId(), network2.getNetworkCompositionData().getName()); +// } + + @Test + public void testCreateOnUploadVsp_negative() { + testCreate_negative(new org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity(vsp1Id, null, component11Id, null), USER1, + VendorSoftwareProductErrorCodes.VSP_COMPOSITION_EDIT_NOT_ALLOWED); + } + + @Test + public void testGetNonExistingNicId_negative() { + testGet_negative(vsp1Id, null, component11Id, "non existing nic id", USER1, + org.openecomp.sdc.versioning.errors.VersioningErrorCodes.VERSIONABLE_SUB_ENTITY_NOT_FOUND); + } + + @Test(dependsOnMethods = "testListWhenNone")//"testCreate") + public void testGetNonExistingComponentId_negative() { + testGet_negative(vsp1Id, null, "non existing component id", nic1Id, USER1, + org.openecomp.sdc.versioning.errors.VersioningErrorCodes.VERSIONABLE_SUB_ENTITY_NOT_FOUND); + } + + @Test(dependsOnMethods = "testListWhenNone")//"testCreate") + public void testGetNonExistingVspId_negative() { + testGet_negative("non existing vsp id", null, component11Id, nic1Id, USER1, + org.openecomp.sdc.versioning.errors.VersioningErrorCodes.VERSIONABLE_ENTITY_NOT_EXIST); + } + + @Test(dependsOnMethods = "testListWhenNone")//"testCreate") + public void testGet() { + createNic(vsp1Id, VERSION01, component11Id, nic1Id, network1.getId()); + testGet(vsp1Id, VERSION01, component11Id, nic1Id, USER1); + } + + @Test + public void testUpdateNonExistingNicId_negative() { + testUpdate_negative(vsp1Id, component11Id, "non existing nic id", USER1, + org.openecomp.sdc.versioning.errors.VersioningErrorCodes.VERSIONABLE_SUB_ENTITY_NOT_FOUND); + } + + @Test(dependsOnMethods = "testListWhenNone")//"testCreate") + public void testUpdateNonExistingComponentId_negative() { + testUpdate_negative(vsp1Id, "non existing component id", nic1Id, USER1, + org.openecomp.sdc.versioning.errors.VersioningErrorCodes.VERSIONABLE_SUB_ENTITY_NOT_FOUND); + } + + @Test(dependsOnMethods = "testListWhenNone")//"testCreate") + public void testUpdateNonExistingVspId_negative() { + testUpdate_negative("non existing vsp id", component11Id, nic1Id, USER1, + org.openecomp.sdc.versioning.errors.VersioningErrorCodes.VERSIONABLE_ENTITY_NOT_EXIST); + } + + @Test(dependsOnMethods = {"testGet"}) + public void testUpdateOnUploadVsp() { + org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity + expected = new org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity(vsp1Id, null, component11Id, nic1Id); + org.openecomp.sdc.vendorsoftwareproduct.types.composition.Nic + nicData = new org.openecomp.sdc.vendorsoftwareproduct.types.composition.Nic(); + nicData.setName(nic1Id + " name"); + nicData.setDescription(nic1Id + " desc updated"); + nicData.setNetworkId(network1.getId()); + expected.setNicCompositionData(nicData); + + CompositionEntityValidationData validationData = + vendorSoftwareProductManager.updateNic(expected, USER1); + Assert.assertTrue(validationData == null || validationData.getErrors() == null); + expected.setVersion(VERSION01); + + org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity + actual = vendorSoftwareProductDao.getNic(vsp1Id, VERSION01, component11Id, nic1Id); + Assert.assertEquals(actual, expected); + } + + @Test(dependsOnMethods = {"testGet"}) + public void testIllegalUpdateOnUploadVsp() { + org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity + expected = new org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity(vsp1Id, null, component11Id, nic1Id); + org.openecomp.sdc.vendorsoftwareproduct.types.composition.Nic + nicData = new org.openecomp.sdc.vendorsoftwareproduct.types.composition.Nic(); + nicData.setName(nic1Id + " name updated"); + nicData.setDescription(nic1Id + " desc updated"); + nicData.setNetworkId(network1.getId()); + expected.setNicCompositionData(nicData); + + CompositionEntityValidationData validationData = + vendorSoftwareProductManager.updateNic(expected, USER1); + Assert.assertNotNull(validationData); + Assert.assertTrue(validationData.getErrors().size() > 0); + } + + @Test + public void testListNonExistingComponentId_negative() { + testList_negative(vsp1Id, null, "non existing component id", USER1, + org.openecomp.sdc.versioning.errors.VersioningErrorCodes.VERSIONABLE_SUB_ENTITY_NOT_FOUND); + } + + @Test + public void testListNonExistingVspId_negative() { + testList_negative("non existing vsp id", null, component11Id, USER1, + org.openecomp.sdc.versioning.errors.VersioningErrorCodes.VERSIONABLE_ENTITY_NOT_EXIST); + } +/* + @Test(dependsOnMethods = {"testUpdateOnUploadVsp", "testList"}) + public void testCreateWithRemovedName() { + testCreate(vsp1Id, component11Id); + } + + @Test + public void testDeleteNonExistingNicId_negative() { + testDelete_negative(vsp1Id, component11Id, "non existing nic id", USER1, VersioningErrorCodes.VERSIONABLE_SUB_ENTITY_NOT_FOUND); + } + + @Test(dependsOnMethods = "testList") + public void testDeleteNonExistingComponentId_negative() { + testDelete_negative(vsp1Id, "non existing component id", nic1Id, USER1, VersioningErrorCodes.VERSIONABLE_SUB_ENTITY_NOT_FOUND); + }*/ + + @Test(dependsOnMethods = {"testGet"}) + public void testList() { + createNic(vsp1Id, VERSION01, component11Id, "nic2", network1.getId()); + + Collection actual = + vendorSoftwareProductManager.listNics(vsp1Id, null, component11Id, USER1); + Assert.assertEquals(actual.size(), 2); + } + + @Test(dependsOnMethods = "testList") + public void testDeleteNonExistingVspId_negative() { + testDelete_negative("non existing vsp id", component11Id, nic1Id, USER1, + org.openecomp.sdc.versioning.errors.VersioningErrorCodes.VERSIONABLE_ENTITY_NOT_EXIST); + } +/* + @Test(dependsOnMethods = "testList") + public void testDelete() { + vendorSoftwareProductManager.deleteNic(vsp1Id, component11Id, nic1Id, USER1); + NicEntity actual = vendorSoftwareProductDao.getNic(vsp1Id, VERSION01, component11Id, nic1Id); + Assert.assertNull(actual); + }*/ + + @Test(dependsOnMethods = "testList") + public void testDeleteOnUploadVsp_negative() { + testDelete_negative(vsp1Id, component11Id, nic1Id, USER1, + VendorSoftwareProductErrorCodes.VSP_COMPOSITION_EDIT_NOT_ALLOWED); + } + + private String testCreate(String vspId, String componentId, String networkId, + String networkName) { + org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity + expected = new org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity(vspId, null, componentId, null); + + org.openecomp.sdc.vendorsoftwareproduct.types.composition.Nic + nicData = new org.openecomp.sdc.vendorsoftwareproduct.types.composition.Nic(); + nicData.setName("nic1 name"); + nicData.setNetworkId(networkId); + //nicData.setNetworkName(networkName); + nicData.setNetworkType(org.openecomp.sdc.vendorsoftwareproduct.types.composition.NetworkType.External); + expected.setNicCompositionData(nicData); + + org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity created = vendorSoftwareProductManager.createNic(expected, USER1); + Assert.assertNotNull(created); + expected.setId(created.getId()); + expected.setVersion(VERSION01); + + org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity actual = + vendorSoftwareProductDao.getNic(vspId, VERSION01, componentId, created.getId()); + + Assert.assertEquals(actual, expected); + + return created.getId(); + } + + private void testGet(String vspId, org.openecomp.sdc.versioning.dao.types.Version version, String componentId, String nicId, + String user) { + CompositionEntityResponse response = + vendorSoftwareProductManager.getNic(vspId, null, componentId, nicId, user); + org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity + expected = vendorSoftwareProductDao.getNic(vspId, version, componentId, nicId); + Assert.assertEquals(response.getId(), expected.getId()); + Assert.assertEquals(response.getData(), expected.getNicCompositionData()); + Assert.assertNotNull(response.getSchema()); + } + + private void testCreate_negative(org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity nic, String user, String expectedErrorCode) { + try { + vendorSoftwareProductManager.createNic(nic, user); + Assert.fail(); + } catch (CoreException e) { + Assert.assertEquals(e.code().id(), expectedErrorCode); + } + } + + private void testGet_negative(String vspId, org.openecomp.sdc.versioning.dao.types.Version version, String componentId, String nicId, + String user, String expectedErrorCode) { + try { + vendorSoftwareProductManager.getNic(vspId, version, componentId, nicId, user); + Assert.fail(); + } catch (CoreException e) { + Assert.assertEquals(e.code().id(), expectedErrorCode); + } + } + + private void testUpdate_negative(String vspId, String componentId, String nicId, String user, + String expectedErrorCode) { + try { + vendorSoftwareProductManager.updateNic(new org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity(vspId, null, componentId, nicId), user); + Assert.fail(); + } catch (CoreException e) { + Assert.assertEquals(e.code().id(), expectedErrorCode); + } + } + + private void testList_negative(String vspId, org.openecomp.sdc.versioning.dao.types.Version version, String componentId, String user, + String expectedErrorCode) { + try { + vendorSoftwareProductManager.listNics(vspId, version, componentId, user); + Assert.fail(); + } catch (CoreException e) { + Assert.assertEquals(e.code().id(), expectedErrorCode); + } + } + + private void testDelete_negative(String vspId, String componentId, String nicId, String user, + String expectedErrorCode) { + try { + vendorSoftwareProductManager.deleteNic(vspId, componentId, nicId, user); + Assert.fail(); + } catch (CoreException e) { + Assert.assertEquals(e.code().id(), expectedErrorCode); + } + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/ProcessesTest.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/ProcessesTest.java new file mode 100644 index 0000000000..8571088be1 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/ProcessesTest.java @@ -0,0 +1,473 @@ +package org.openecomp.sdc.vendorsoftwareproduct; + +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.vendorsoftwareproduct.dao.VendorSoftwareProductDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.VendorSoftwareProductDaoFactory; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessArtifactEntity; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.VspDetails; +import org.openecomp.sdc.vendorsoftwareproduct.impl.VendorSoftwareProductManagerImpl; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.errors.VersioningErrorCodes; +import org.openecomp.core.util.UniqueValueUtil; +import org.openecomp.core.utilities.CommonMethods; + +import org.testng.Assert; +import org.testng.annotations.BeforeClass; +import org.testng.annotations.Test; + +import java.io.ByteArrayInputStream; +import java.io.File; +import java.util.Collection; + +public class ProcessesTest { + + protected static final String USER1 = "processesTestUser1"; + protected static final VendorSoftwareProductManager vendorSoftwareProductManager = + new VendorSoftwareProductManagerImpl(); + private static final String USER2 = "processesTestUser2"; + private static final String ARTIFACT_NAME = "artifact.sh"; + private static final Version VERSION01 = new Version(0, 1); + private static final VendorSoftwareProductDao vendorSoftwareProductDao = + VendorSoftwareProductDaoFactory.getInstance().createInterface(); + + protected String vsp1Id; + protected String vsp2Id; + protected String component11Id = VendorSoftwareProductConstants.GENERAL_COMPONENT_ID; + protected String component21Id = VendorSoftwareProductConstants.GENERAL_COMPONENT_ID; + private String p1Id; + private String p2Id; + + @BeforeClass + protected void init() { + VspDetails vsp1 = vendorSoftwareProductManager.createNewVsp(VSPCommon + .createVspDetails(null, null, "VSP_" + CommonMethods.nextUuId(), "Test-vsp1", "vendorName1", + "vlm1Id", "icon", "category", "subCategory", "123", null), USER1); + vsp1Id = vsp1.getId(); + + VspDetails vsp2 = vendorSoftwareProductManager.createNewVsp(VSPCommon + .createVspDetails(null, null, "VSP_" + CommonMethods.nextUuId(), "Test-vsp2", "vendorName1", + "vlm1Id", "icon", "category", "subCategory", "123", null), USER1); + vsp2Id = vsp2.getId(); + } + + @Test + public void testListWhenNone() { + Collection processes = + vendorSoftwareProductManager.listProcesses(vsp1Id, null, component11Id, USER1); + Assert.assertEquals(processes.size(), 0); + } + + @Test + public void testCreateNonExistingComponentId_negative() { + testCreate_negative(new org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity(vsp1Id, null, "non existing component id", null), USER1, + VersioningErrorCodes.VERSIONABLE_SUB_ENTITY_NOT_FOUND); + } + + @Test + public void testCreateNonExistingVspId_negative() { + testCreate_negative(new org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity("non existing vsp id", null, component11Id, null), USER1, + VersioningErrorCodes.VERSIONABLE_ENTITY_NOT_EXIST); + } + + @Test + public void testCreateOnLockedVsp_negative() { + testCreate_negative(new org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity(vsp1Id, null, component11Id, null), USER2, + VersioningErrorCodes.EDIT_ON_ENTITY_LOCKED_BY_OTHER_USER); + } + + @Test(dependsOnMethods = "testListWhenNone") + public void testCreate() { + p1Id = testCreate(vsp1Id, component11Id); + } + + @Test(dependsOnMethods = {"testCreate"}) + public void testCreateWithExistingName_negative() { + org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity + process = new org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity(vsp1Id, null, component11Id, null); + process.setName("p1 name"); + testCreate_negative(process, USER1, UniqueValueUtil.UNIQUE_VALUE_VIOLATION); + } + + @Test(dependsOnMethods = {"testCreate"}) + public void testCreateWithExistingNameUnderOtherComponent() { + // This method is implemented in the sub class ComponentProcessesTest, it is here in order to keep the tests sequence down there (using @Test). + } + + @Test(dependsOnMethods = {"testCreate"}) + public void testCreateWithExistingNameUnderOtherVsp() { + testCreate(vsp2Id, component21Id); + } + + @Test + public void testGetNonExistingProcessId_negative() { + testGet_negative(vsp1Id, null, component11Id, "non existing process id", USER1, + VersioningErrorCodes.VERSIONABLE_SUB_ENTITY_NOT_FOUND); + } + + @Test(dependsOnMethods = "testCreate") + public void testGetNonExistingComponentId_negative() { + testGet_negative(vsp1Id, null, "non existing component id", p1Id, USER1, + VersioningErrorCodes.VERSIONABLE_SUB_ENTITY_NOT_FOUND); + } + + @Test(dependsOnMethods = "testCreate") + public void testGetNonExistingVspId_negative() { + testGet_negative("non existing vsp id", null, component11Id, p1Id, USER1, + VersioningErrorCodes.VERSIONABLE_ENTITY_NOT_EXIST); + } + + @Test(dependsOnMethods = "testCreate") + public void testGet() { + org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity + actual = testGet(vsp1Id, VERSION01, component11Id, p1Id, USER1); + Assert.assertNull(actual.getArtifactName()); + } + + @Test + public void testUpdateNonExistingProcessId_negative() { + testUpdate_negative(vsp1Id, component11Id, "non existing process id", USER1, + VersioningErrorCodes.VERSIONABLE_SUB_ENTITY_NOT_FOUND); + } + + @Test(dependsOnMethods = "testCreate") + public void testUpdateNonExistingComponentId_negative() { + testUpdate_negative(vsp1Id, "non existing component id", p1Id, USER1, + VersioningErrorCodes.VERSIONABLE_SUB_ENTITY_NOT_FOUND); + } + + @Test(dependsOnMethods = "testCreate") + public void testUpdateNonExistingVspId_negative() { + testUpdate_negative("non existing vsp id", component11Id, p1Id, USER1, + VersioningErrorCodes.VERSIONABLE_ENTITY_NOT_EXIST); + } + + @Test(dependsOnMethods = {"testGet"}) + public void testUpdate() { + org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity + expected = new org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity(vsp1Id, null, component11Id, p1Id); + expected.setName("p1 name updated"); + expected.setDescription("p1 desc updated"); + + vendorSoftwareProductManager.updateProcess(expected, USER1); + expected.setVersion(VERSION01); + + org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity actual = + vendorSoftwareProductDao.getProcess(vsp1Id, VERSION01, component11Id, p1Id); + Assert.assertEquals(actual, expected); + } + + @Test + public void testListNonExistingComponentId_negative() { + testList_negative(vsp1Id, null, "non existing component id", USER1, + VersioningErrorCodes.VERSIONABLE_SUB_ENTITY_NOT_FOUND); + } + + @Test + public void testListNonExistingVspId_negative() { + testList_negative("non existing vsp id", null, component11Id, USER1, + VersioningErrorCodes.VERSIONABLE_ENTITY_NOT_EXIST); + } + + @Test(dependsOnMethods = {"testGet"}) + public void testList() { + org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity + p2 = new org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity(vsp1Id, null, component11Id, null); + p2.setName("p2 name"); + p2.setDescription("p2 desc"); + + org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity createdP2 = vendorSoftwareProductManager.createProcess(p2, USER1); + p2Id = createdP2.getId(); + + Collection actual = + vendorSoftwareProductManager.listProcesses(vsp1Id, null, component11Id, USER1); + Collection expected = + vendorSoftwareProductDao.listProcesses(vsp1Id, VERSION01, component11Id); + Assert.assertEquals(actual.size(), 2); + Assert.assertEquals(actual, expected); + } + + @Test(dependsOnMethods = {"testUpdate", "testList"}) + public void testCreateWithRemovedName() { + testCreate(vsp1Id, component11Id); + } + + @Test + public void testDeleteNonExistingProcessId_negative() { + testDelete_negative(vsp1Id, component11Id, "non existing process id", USER1, + VersioningErrorCodes.VERSIONABLE_SUB_ENTITY_NOT_FOUND); + } + + @Test(dependsOnMethods = "testList") + public void testDeleteNonExistingComponentId_negative() { + testDelete_negative(vsp1Id, "non existing component id", p1Id, USER1, + VersioningErrorCodes.VERSIONABLE_SUB_ENTITY_NOT_FOUND); + } + + @Test(dependsOnMethods = "testList") + public void testDeleteNonExistingVspId_negative() { + testDelete_negative("non existing vsp id", component11Id, p1Id, USER1, + VersioningErrorCodes.VERSIONABLE_ENTITY_NOT_EXIST); + } + + @Test(dependsOnMethods = "testList") + public void testDelete() { + vendorSoftwareProductManager.deleteProcess(vsp1Id, component11Id, p1Id, USER1); + org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity actual = + vendorSoftwareProductDao.getProcess(vsp1Id, VERSION01, component11Id, p1Id); + Assert.assertNull(actual); + } + + @Test + public void testUploadFileNonExistingProcessId_negative() { + testUploadFile_negative(vsp1Id, component11Id, "non existing process id", USER1, + VersioningErrorCodes.VERSIONABLE_SUB_ENTITY_NOT_FOUND); + } + + @Test(dependsOnMethods = "testList") + public void testUploadFileNonExistingComponentId_negative() { + testUploadFile_negative(vsp1Id, "non existing component id", p2Id, USER1, + VersioningErrorCodes.VERSIONABLE_SUB_ENTITY_NOT_FOUND); + } + + @Test(dependsOnMethods = "testList") + public void testUploadFileNonExistingVspId_negative() { + testUploadFile_negative("non existing vsp id", component11Id, p2Id, USER1, + VersioningErrorCodes.VERSIONABLE_ENTITY_NOT_EXIST); + } + + @Test(dependsOnMethods = "testList") + public void testGetFileWhenNone_negative() { + testGetFile_negative(vsp1Id, null, component11Id, p2Id, USER1, + VersioningErrorCodes.VERSIONABLE_SUB_ENTITY_NOT_FOUND); + } + + @Test(dependsOnMethods = "testList") + public void testDeleteFileWhenNone_negative() { + testDeleteFile_negative(vsp1Id, component11Id, p2Id, USER1, + VersioningErrorCodes.VERSIONABLE_SUB_ENTITY_NOT_FOUND); + } + + @Test(dependsOnMethods = {"testGetFileWhenNone_negative", "testDeleteFileWhenNone_negative"}) + public void testUploadFile() { + vendorSoftwareProductManager + .uploadProcessArtifact(new ByteArrayInputStream("bla bla".getBytes()), ARTIFACT_NAME, + vsp1Id, component11Id, p2Id, USER1); + ProcessArtifactEntity actual = + vendorSoftwareProductDao.getProcessArtifact(vsp1Id, VERSION01, component11Id, p2Id); + Assert.assertNotNull(actual); + Assert.assertNotNull(actual.getArtifact()); + Assert.assertEquals(actual.getArtifactName(), ARTIFACT_NAME); + } + + @Test(dependsOnMethods = "testUploadFile") + public void testGetAfterUploadFile() { + org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity + actual = testGet(vsp1Id, VERSION01, component11Id, p2Id, USER1); + Assert.assertEquals(actual.getArtifactName(), ARTIFACT_NAME); + } + + @Test + public void testGetFileNonExistingProcessId_negative() { + testGetFile_negative(vsp1Id, null, component11Id, "non existing process id", USER1, + VersioningErrorCodes.VERSIONABLE_SUB_ENTITY_NOT_FOUND); + } + + @Test(dependsOnMethods = "testList") + public void testGetFileNonExistingComponentId_negative() { + testGetFile_negative(vsp1Id, null, "non existing component id", p2Id, USER1, + VersioningErrorCodes.VERSIONABLE_SUB_ENTITY_NOT_FOUND); + } + + @Test(dependsOnMethods = "testList") + public void testGetFileNonExistingVspId_negative() { + testGetFile_negative("non existing vsp id", null, component11Id, p2Id, USER1, + VersioningErrorCodes.VERSIONABLE_ENTITY_NOT_EXIST); + } + + @Test(dependsOnMethods = "testUploadFile") + public void testGetFile() { + File actual = + vendorSoftwareProductManager.getProcessArtifact(vsp1Id, null, component11Id, p2Id, USER1); + Assert.assertNotNull(actual); + ProcessArtifactEntity expected = + vendorSoftwareProductDao.getProcessArtifact(vsp1Id, VERSION01, component11Id, p2Id); + Assert.assertNotNull(expected); + Assert.assertNotNull(expected.getArtifact()); + } + + @Test + public void testDeleteFileNonExistingProcessId_negative() { + testDeleteFile_negative(vsp1Id, component11Id, "non existing process id", USER1, + VersioningErrorCodes.VERSIONABLE_SUB_ENTITY_NOT_FOUND); + } + + @Test(dependsOnMethods = "testList") + public void testDeleteFileNonExistingComponentId_negative() { + testDeleteFile_negative(vsp1Id, "non existing component id", p2Id, USER1, + VersioningErrorCodes.VERSIONABLE_SUB_ENTITY_NOT_FOUND); + } + + @Test(dependsOnMethods = "testList") + public void testDeleteFileNonExistingVspId_negative() { + testDeleteFile_negative("non existing vsp id", component11Id, p2Id, USER1, + VersioningErrorCodes.VERSIONABLE_ENTITY_NOT_EXIST); + } + + @Test(dependsOnMethods = "testGetFile") + public void testDeleteFile() { + vendorSoftwareProductManager.deleteProcessArtifact(vsp1Id, component11Id, p2Id, USER1); + ProcessArtifactEntity expected = + vendorSoftwareProductDao.getProcessArtifact(vsp1Id, VERSION01, component11Id, p2Id); + Assert.assertNull(expected.getArtifact()); + } + + @Test + public void testDeleteListNonExistingComponentId_negative() { + testDeleteList_negative(vsp1Id, "non existing component id", USER1, + VersioningErrorCodes.VERSIONABLE_SUB_ENTITY_NOT_FOUND); + } + + @Test + public void testDeleteListNonExistingVspId_negative() { + testDeleteList_negative("non existing vsp id", component11Id, USER1, + VersioningErrorCodes.VERSIONABLE_ENTITY_NOT_EXIST); + } + + @Test(dependsOnMethods = {"testDeleteFile"}) + public void testDeleteList() { + org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity + p3 = new org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity(vsp1Id, null, component11Id, null); + p3.setName("p3 name"); + p3.setDescription("p3 desc"); + vendorSoftwareProductManager.createProcess(p3, USER1); + + vendorSoftwareProductManager.deleteProcesses(vsp1Id, component11Id, USER1); + + Collection actual = + vendorSoftwareProductManager.listProcesses(vsp1Id, null, component11Id, USER1); + Assert.assertEquals(actual.size(), 0); + } + + protected String testCreate(String vspId, String componentId) { + org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity + expected = new org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity(vspId, null, componentId, null); + expected.setName("p1 name"); + expected.setDescription("p1 desc"); + + org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity created = vendorSoftwareProductManager.createProcess(expected, USER1); + Assert.assertNotNull(created); + expected.setId(created.getId()); + expected.setVersion(VERSION01); + + org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity actual = + vendorSoftwareProductDao.getProcess(vspId, VERSION01, componentId, created.getId()); + + Assert.assertEquals(actual, expected); + + return created.getId(); + } + + private org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity testGet(String vspId, Version version, String componentId, String processId, + String user) { + org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity actual = + vendorSoftwareProductManager.getProcess(vspId, null, componentId, processId, user); + org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity expected = + vendorSoftwareProductDao.getProcess(vspId, version, componentId, processId); + Assert.assertEquals(actual, expected); + return actual; + } + + private void testCreate_negative( + org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity process, String user, String expectedErrorCode) { + try { + vendorSoftwareProductManager.createProcess(process, user); + Assert.fail(); + } catch (CoreException e) { + Assert.assertEquals(e.code().id(), expectedErrorCode); + } + } + + private void testGet_negative(String vspId, Version version, String componentId, String processId, + String user, String expectedErrorCode) { + try { + vendorSoftwareProductManager.getProcess(vspId, version, componentId, processId, user); + Assert.fail(); + } catch (CoreException e) { + Assert.assertEquals(e.code().id(), expectedErrorCode); + } + } + + private void testUpdate_negative(String vspId, String componentId, String processId, String user, + String expectedErrorCode) { + try { + vendorSoftwareProductManager + .updateProcess(new org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity(vspId, null, componentId, processId), user); + Assert.fail(); + } catch (CoreException e) { + Assert.assertEquals(e.code().id(), expectedErrorCode); + } + } + + private void testList_negative(String vspId, Version version, String componentId, String user, + String expectedErrorCode) { + try { + vendorSoftwareProductManager.listProcesses(vspId, version, componentId, user); + Assert.fail(); + } catch (CoreException e) { + Assert.assertEquals(e.code().id(), expectedErrorCode); + } + } + + private void testDeleteList_negative(String vspId, String componentId, String user, + String expectedErrorCode) { + try { + vendorSoftwareProductManager.deleteProcesses(vspId, componentId, user); + Assert.fail(); + } catch (CoreException e) { + Assert.assertEquals(e.code().id(), expectedErrorCode); + } + } + + private void testDelete_negative(String vspId, String componentId, String processId, String user, + String expectedErrorCode) { + try { + vendorSoftwareProductManager.deleteProcess(vspId, componentId, processId, user); + Assert.fail(); + } catch (CoreException e) { + Assert.assertEquals(e.code().id(), expectedErrorCode); + } + } + + private void testGetFile_negative(String vspId, Version version, String componentId, + String processId, String user, String expectedErrorCode) { + try { + vendorSoftwareProductManager.getProcessArtifact(vspId, version, componentId, processId, user); + Assert.fail(); + } catch (CoreException e) { + Assert.assertEquals(e.code().id(), expectedErrorCode); + } + } + + private void testUploadFile_negative(String vspId, String componentId, String processId, + String user, String expectedErrorCode) { + try { + vendorSoftwareProductManager + .uploadProcessArtifact(new ByteArrayInputStream("bla bla".getBytes()), "artifact.sh", + vspId, componentId, processId, user); + Assert.fail(); + } catch (CoreException e) { + Assert.assertEquals(e.code().id(), expectedErrorCode); + } + } + + private void testDeleteFile_negative(String vspId, String componentId, String processId, + String user, String expectedErrorCode) { + try { + vendorSoftwareProductManager.deleteProcessArtifact(vspId, componentId, processId, user); + Assert.fail(); + } catch (CoreException e) { + Assert.assertEquals(e.code().id(), expectedErrorCode); + } + } + +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/VSPCommon.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/VSPCommon.java new file mode 100644 index 0000000000..4eaba77f2b --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/VSPCommon.java @@ -0,0 +1,78 @@ +package org.openecomp.sdc.vendorsoftwareproduct; + +import org.openecomp.sdc.vendorlicense.dao.types.VendorLicenseModelEntity; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.VspDetails; + +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.core.utilities.file.FileUtils; + +import java.io.*; +import java.util.List; +import java.util.zip.ZipEntry; +import java.util.zip.ZipOutputStream; + +public class VSPCommon { + + public static VspDetails createVspDetails(String id, Version version, String name, String desc, + String vendorName, String vlm, String icon, + String category, String subCategory, + String licenseAgreement, List featureGroups) { + VspDetails vspDetails = new VspDetails(id, version); + vspDetails.setName(name); + vspDetails.setDescription(desc); + vspDetails.setIcon(icon); + vspDetails.setCategory(category); + vspDetails.setSubCategory(subCategory); + vspDetails.setVendorName(vendorName); + vspDetails.setVendorId(vlm); + vspDetails.setVlmVersion(new Version(1, 0)); + vspDetails.setLicenseAgreement(licenseAgreement); + vspDetails.setFeatureGroups(featureGroups); + return vspDetails; + } + + + public static VendorLicenseModelEntity createVendorLicenseModel(String name, String desc, + String icon) { + VendorLicenseModelEntity vendorLicenseModel = new VendorLicenseModelEntity(); + vendorLicenseModel.setVendorName(name); + vendorLicenseModel.setDescription(desc); + vendorLicenseModel.setIconRef(icon); + return vendorLicenseModel; + } + + public static void zipDir(File file, String path, ZipOutputStream zos) { + zipDir(file, path, zos, false); + } + + public static void zipDir(File file, String path, ZipOutputStream zos, boolean isRootDir) { + if (file.isDirectory()) { + path += File.separator + file.getName(); + File[] files = file.listFiles(); + if (files != null) { + for (File innerFile : files) { + if (isRootDir) { + zipDir(innerFile, "", zos, false); + } else { + zipDir(innerFile, path, zos, false); + } + } + } + } else { + + try { + if (!path.isEmpty()) { + path += File.separator; + } + zos.putNextEntry(new ZipEntry(path + file.getName())); + InputStream is = new FileInputStream(file); + byte[] data = FileUtils.toByteArray(is); + zos.write(data); + zos.closeEntry(); + } catch (IOException e) { + e.printStackTrace(); + } + } + } + +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/VSPFullTest.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/VSPFullTest.java new file mode 100644 index 0000000000..ebc4c3af64 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/VSPFullTest.java @@ -0,0 +1,194 @@ +package org.openecomp.sdc.vendorsoftwareproduct; + +import org.openecomp.sdc.tosca.datatypes.ToscaServiceModel; +import org.openecomp.sdc.tosca.datatypes.model.CapabilityDefinition; +import org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity; +import org.openecomp.sdc.vendorlicense.facade.VendorLicenseFacade; +import org.openecomp.sdc.vendorsoftwareproduct.dao.VendorSoftwareProductDaoFactory; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.VspDetails; +import org.openecomp.sdc.vendorsoftwareproduct.impl.VendorSoftwareProductManagerImpl; +import org.openecomp.sdc.vendorsoftwareproduct.types.ValidationResponse; +import org.openecomp.sdc.vendorsoftwareproduct.types.VersionedVendorSoftwareProductInfo; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.core.model.dao.EnrichedServiceModelDaoFactory; +import org.openecomp.core.util.UniqueValueUtil; +import org.openecomp.core.utilities.CommonMethods; +import org.apache.commons.collections4.MapUtils; +import org.apache.commons.io.IOUtils; +import org.testng.Assert; +import org.testng.annotations.Test; + +import java.io.*; +import java.net.URL; +import java.util.Collection; +import java.util.HashMap; +import java.util.Map; +import java.util.Set; +import java.util.stream.Collectors; + +public class VSPFullTest { + + + public static final Version VERSION01 = new Version(0, 1); + private static final org.openecomp.sdc.vendorsoftwareproduct.dao.VendorSoftwareProductDao + vendorSoftwareProductDao = + VendorSoftwareProductDaoFactory.getInstance().createInterface(); + private static final String USER1 = "vspTestUser1"; + private static VendorSoftwareProductManager vendorSoftwareProductManager = + new VendorSoftwareProductManagerImpl(); + private static VendorLicenseFacade vendorLicenseFacade = + org.openecomp.sdc.vendorlicense.facade.VendorLicenseFacadeFactory.getInstance().createInterface(); + + @Test + public void testEnrichModelInSubmit() { + UniqueValueUtil + .deleteUniqueValue(VendorSoftwareProductConstants.UniqueValues.VENDOR_SOFTWARE_PRODUCT_NAME, + "VSP_FullTest"); + + String vlm1Id = vendorLicenseFacade.createVendorLicenseModel(VSPCommon + .createVendorLicenseModel("vlmName " + CommonMethods.nextUuId(), "vlm1Id desc", "icon1"), + USER1).getId(); + String entitlementPoolId = vendorLicenseFacade + .createEntitlementPool(new EntitlementPoolEntity(vlm1Id, null, null), USER1).getId(); + + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity + featureGroup = new org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity(vlm1Id, null, null); + featureGroup.getEntitlementPoolIds().add(entitlementPoolId); + String featureGroupId = vendorLicenseFacade.createFeatureGroup(featureGroup, USER1).getId(); + + org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementEntity + licenseAgreement = new org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementEntity(vlm1Id, null, null); + licenseAgreement.getFeatureGroupIds().add(featureGroupId); + String licenseAgreementId = + vendorLicenseFacade.createLicenseAgreement(licenseAgreement, USER1).getId(); + + vendorLicenseFacade.checkin(vlm1Id, USER1); + vendorLicenseFacade.submit(vlm1Id, USER1); + + String vspId = createVsp(vlm1Id, licenseAgreementId, licenseAgreement.getFeatureGroupIds()); + + Collection components = uploadFullCompositionFile(vspId); + + + //check in + vendorSoftwareProductManager.checkin(vspId, USER1); + //submit + try { + ValidationResponse result = vendorSoftwareProductManager.submit(vspId, USER1); + //Assert.assertTrue(result.isValid()); + //PackageInfo createPackageResult = vendorSoftwareProductManager.createPackage(vspId, USER1); + + } catch (IOException e) { + Assert.fail(); + } + VersionedVendorSoftwareProductInfo details = + vendorSoftwareProductManager.getVspDetails(vspId, null, USER1); + + + //File csar = vendorSoftwareProductManager.getTranslatedFile(vspId,details.getVersionInfo().getActiveVersion(),USER1); + // writeFile(csar); + + + ToscaServiceModel model = + (ToscaServiceModel) EnrichedServiceModelDaoFactory.getInstance().createInterface() + .getServiceModel(vspId, details.getVersionInfo().getActiveVersion()); + + Map capabilities = new HashMap<>(); + for (org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity component : components) { + model.getServiceTemplates(). + entrySet(). + stream(). + filter(entryValue -> entryValue.getValue() != null && + entryValue.getValue().getNode_types() != null && + entryValue.getValue(). + getNode_types(). + containsKey(component.getComponentCompositionData().getName())). + forEach(entryValue -> entryValue.getValue().getNode_types(). + values(). + stream(). + filter(type -> MapUtils.isNotEmpty(type.getCapabilities())). + forEach(type -> type.getCapabilities(). + entrySet(). + forEach(entry -> addCapability(entryValue.getKey(), capabilities, entry.getKey(), + entry.getValue())))); + + } + + Assert.assertNotNull(capabilities); + } + + private Collection uploadFullCompositionFile(String vspId) { + vendorSoftwareProductManager + .uploadFile(vspId, getFileInputStream("/vspmanager/zips/fullComposition.zip"), USER1); + + Collection components = + vendorSoftwareProductManager.listComponents(vspId, null, USER1); + Assert.assertFalse(components.isEmpty()); + + for (org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity component : components) { + Assert.assertNotNull(vendorSoftwareProductManager + .getComponentQuestionnaire(vspId, null, component.getId(), USER1).getData()); + + Collection nics = + vendorSoftwareProductManager.listNics(vspId, null, component.getId(), USER1); + Assert.assertFalse(nics.isEmpty()); + for (org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity nic : nics) { + Assert.assertNotNull(vendorSoftwareProductManager + .getNicQuestionnaire(vspId, null, component.getId(), nic.getId(), USER1).getData()); + } + } + + return components; + } + + private String createVsp(String vlm1Id, String licenseAgreementId, Set featureGroupIds) { + VspDetails expectedVsp = VSPCommon + .createVspDetails(null, null, "VSP_FullTest", "Test-vsp_fullTest", "vendorName", vlm1Id, + "icon", "category", "subCategory", licenseAgreementId, + featureGroupIds.stream().collect(Collectors.toList())); + String vspId = vendorSoftwareProductManager.createNewVsp(expectedVsp, USER1).getId(); + + VspDetails actualVsp = + vendorSoftwareProductDao.getVendorSoftwareProductInfo(new VspDetails(vspId, VERSION01)); + expectedVsp.setId(vspId); + expectedVsp.setVersion(VERSION01); + + VendorSoftwareProductManagerTest.assertVspsEquals(actualVsp, expectedVsp); + Assert.assertNotNull( + vendorSoftwareProductManager.getVspQuestionnaire(vspId, null, USER1).getData()); + return vspId; + } + + private void writeFile(File csar) { + try { + FileInputStream in = new FileInputStream(csar); + File output = new File("CSAR_vDNS.zip"); + + FileOutputStream out = new FileOutputStream(output); + + IOUtils.copy(in, out); + in.close(); + out.close(); + } catch (IOException e) { + throw new RuntimeException(e); + } + } + + private void addCapability(String entryValueKey, Map capabilities, + String key, CapabilityDefinition value) { + + capabilities.put(entryValueKey + "_" + key, value); + } + + private InputStream getFileInputStream(String fileName) { + URL url = this.getClass().getResource(fileName); + try { + return url.openStream(); + } catch (IOException e) { + e.printStackTrace(); + return null; + } + } + + +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/VendorSoftwareProductManagerTest.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/VendorSoftwareProductManagerTest.java new file mode 100644 index 0000000000..d94c868f25 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/VendorSoftwareProductManagerTest.java @@ -0,0 +1,672 @@ +package org.openecomp.sdc.vendorsoftwareproduct; + +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.common.errors.ErrorCode; +import org.openecomp.sdc.common.errors.ValidationErrorBuilder; +import org.openecomp.sdc.common.utils.AsdcCommon; +import org.openecomp.sdc.heat.datatypes.structure.HeatStructureTree; +import org.openecomp.sdc.tosca.datatypes.ToscaServiceModel; +import org.openecomp.sdc.tosca.datatypes.model.CapabilityDefinition; +import org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity; +import org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementEntity; +import org.openecomp.sdc.vendorlicense.facade.VendorLicenseFacade; + +import org.openecomp.sdc.vendorsoftwareproduct.dao.VendorSoftwareProductDaoFactory; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.PackageInfo; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.UploadDataEntity; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.VspDetails; +import org.openecomp.sdc.vendorsoftwareproduct.errors.VendorSoftwareProductErrorCodes; +import org.openecomp.sdc.vendorsoftwareproduct.impl.VendorSoftwareProductManagerImpl; +import org.openecomp.sdc.vendorsoftwareproduct.tree.UploadFileTest; +import org.openecomp.sdc.vendorsoftwareproduct.types.UploadFileResponse; +import org.openecomp.sdc.vendorsoftwareproduct.types.ValidationResponse; +import org.openecomp.sdc.vendorsoftwareproduct.types.VersionedVendorSoftwareProductInfo; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.errors.VersioningErrorCodes; +import org.openecomp.core.model.dao.EnrichedServiceModelDaoFactory; +import org.openecomp.core.util.UniqueValueUtil; +import org.openecomp.core.utilities.CommonMethods; +import org.openecomp.core.validation.errors.Messages; +import org.apache.commons.collections4.MapUtils; +import org.apache.commons.io.IOUtils; +import org.testng.Assert; +import org.testng.annotations.BeforeTest; +import org.testng.annotations.Test; + +import java.io.*; +import java.net.URL; +import java.util.*; +import java.util.stream.Collectors; + +public class VendorSoftwareProductManagerTest { + public static final Version VERSION01 = new Version(0, 1); + public static final Version VERSION10 = new Version(1, 0); + private static final String USER1 = "vspTestUser1"; + private static final String USER2 = "vspTestUser2"; + private static final String USER3 = "vspTestUser3"; + public static String id001 = null; + public static String id002 = null; + public static String id003 = null; + public static String id004 = null; + public static String id005 = null; + public static String id006 = null; + public static String id007 = null; + public static Version activeVersion002 = null; + private static VendorSoftwareProductManager vendorSoftwareProductManager = + new VendorSoftwareProductManagerImpl(); + private static org.openecomp.sdc.vendorsoftwareproduct.dao.VendorSoftwareProductDao + vendorSoftwareProductDao = + VendorSoftwareProductDaoFactory.getInstance().createInterface(); + private static VendorLicenseFacade vendorLicenseFacade = + org.openecomp.sdc.vendorlicense.facade.VendorLicenseFacadeFactory.getInstance().createInterface(); + private static String vlm1Id; + private static String licenseAgreementId; + private static String featureGroupId; + private static VspDetails vsp1; + private static VspDetails vsp2; + UploadFileTest ut = new UploadFileTest(); + + static void assertVspsEquals(VspDetails actual, VspDetails expected) { + Assert.assertEquals(actual.getId(), expected.getId()); + Assert.assertEquals(actual.getVersion(), expected.getVersion()); + Assert.assertEquals(actual.getName(), expected.getName()); + Assert.assertEquals(actual.getDescription(), expected.getDescription()); + Assert.assertEquals(actual.getIcon(), expected.getIcon()); + Assert.assertEquals(actual.getCategory(), expected.getCategory()); + Assert.assertEquals(actual.getSubCategory(), expected.getSubCategory()); + Assert.assertEquals(actual.getVendorName(), expected.getVendorName()); + Assert.assertEquals(actual.getVendorId(), expected.getVendorId()); + Assert.assertEquals(actual.getLicenseAgreement(), expected.getLicenseAgreement()); + Assert.assertEquals(actual.getFeatureGroups(), expected.getFeatureGroups()); + } + + @BeforeTest + private void init() { + UniqueValueUtil + .deleteUniqueValue(VendorSoftwareProductConstants.UniqueValues.VENDOR_SOFTWARE_PRODUCT_NAME, + "VSP1"); + UniqueValueUtil + .deleteUniqueValue(VendorSoftwareProductConstants.UniqueValues.VENDOR_SOFTWARE_PRODUCT_NAME, + "VSP3"); + UniqueValueUtil + .deleteUniqueValue(VendorSoftwareProductConstants.UniqueValues.VENDOR_SOFTWARE_PRODUCT_NAME, + "VSP4"); + UniqueValueUtil + .deleteUniqueValue(VendorSoftwareProductConstants.UniqueValues.VENDOR_SOFTWARE_PRODUCT_NAME, + "VSP5"); + UniqueValueUtil + .deleteUniqueValue(VendorSoftwareProductConstants.UniqueValues.VENDOR_SOFTWARE_PRODUCT_NAME, + "vsp1_test"); + UniqueValueUtil + .deleteUniqueValue(VendorSoftwareProductConstants.UniqueValues.VENDOR_SOFTWARE_PRODUCT_NAME, + "vsp2_test"); + createVlm(); + } + + private void createVlm() { + vlm1Id = vendorLicenseFacade.createVendorLicenseModel(VSPCommon + .createVendorLicenseModel("vlmName " + CommonMethods.nextUuId(), "vlm1Id desc", "icon1"), + USER1).getId(); + + String entitlementPoolId = vendorLicenseFacade + .createEntitlementPool(new EntitlementPoolEntity(vlm1Id, null, null), USER1).getId(); + + org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity + featureGroup = new org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity(vlm1Id, null, null); + featureGroup.getEntitlementPoolIds().add(entitlementPoolId); + featureGroupId = vendorLicenseFacade.createFeatureGroup(featureGroup, USER1).getId(); + + LicenseAgreementEntity licenseAgreement = new LicenseAgreementEntity(vlm1Id, null, null); + licenseAgreement.getFeatureGroupIds().add(featureGroupId); + licenseAgreementId = + vendorLicenseFacade.createLicenseAgreement(licenseAgreement, USER1).getId(); + + vendorLicenseFacade.checkin(vlm1Id, USER1); + vendorLicenseFacade.submit(vlm1Id, USER1); + } + + @Test + public void testHeatSet() { + Set set = new HashSet<>(); + HeatStructureTree heatStructureTree1 = new HeatStructureTree(); + HeatStructureTree heatStructureTree2 = new HeatStructureTree(); + + heatStructureTree1.setFileName("file"); + + HeatStructureTree env = new HeatStructureTree(); + env.setFileName("env"); + heatStructureTree1.setEnv(env); + + heatStructureTree2.setFileName("file"); + heatStructureTree2.setEnv(env); + + set.add(heatStructureTree1); + set.add(heatStructureTree2); + + Assert.assertEquals(set.size(), 1); + } + + @Test(dependsOnMethods = {"testHeatSet"}) + public void testCreateVSP() { + VspDetails expectedVsp = VSPCommon + .createVspDetails(null, null, "VSP1", "Test-vsp", "vendorName", vlm1Id, "icon", "category", + "subCategory", "123", null); + + VspDetails createdVsp = vendorSoftwareProductManager.createNewVsp(expectedVsp, USER1); + id001 = createdVsp.getId(); + Assert.assertNotNull(id001); + Assert.assertNotNull(createdVsp.getVersion()); + + VspDetails actualVsp = + vendorSoftwareProductDao.getVendorSoftwareProductInfo(new VspDetails(id001, VERSION01)); + expectedVsp.setId(id001); + expectedVsp.setVersion(VERSION01); + + assertVspsEquals(actualVsp, expectedVsp); + Assert.assertNotNull( + vendorSoftwareProductManager.getVspQuestionnaire(id001, null, USER1).getData()); + } + + @Test(dependsOnMethods = {"testCreateVSP"}) + public void testCreateWithExistingName_negative() { + try { + VspDetails expectedVsp = VSPCommon + .createVspDetails(null, null, "Vsp1", "Test-vsp", "vendorName", vlm1Id, "icon", + "category", "subCategory", "123", null); + vendorSoftwareProductManager.createNewVsp(expectedVsp, USER1); + Assert.fail(); + } catch (CoreException e) { + Assert.assertEquals(e.code().id(), UniqueValueUtil.UNIQUE_VALUE_VIOLATION); + } + } + + @Test(dependsOnMethods = {"testCreateWithExistingName_negative"}) + public void testGetVSPDetails() { + VersionedVendorSoftwareProductInfo actualVsp = + vendorSoftwareProductManager.getVspDetails(id001, null, USER1); + + VspDetails expectedVsp = + vendorSoftwareProductDao.getVendorSoftwareProductInfo(new VspDetails(id001, VERSION01)); + assertVspsEquals(actualVsp.getVspDetails(), expectedVsp); + Assert.assertEquals(actualVsp.getVersionInfo().getActiveVersion(), VERSION01); + Assert.assertEquals(actualVsp.getVersionInfo().getStatus(), org.openecomp.sdc.versioning.dao.types.VersionStatus.Locked); + Assert.assertEquals(actualVsp.getVersionInfo().getLockingUser(), USER1); + } + + @Test(dependsOnMethods = {"testGetVSPDetails"}) + public void testUpdateVSP() { + VspDetails expectedVsp = VSPCommon + .createVspDetails(id001, VERSION01, "VSP1", null, "vendorName", vlm1Id, "icon", "category", + "subCategory", "456", null); + vendorSoftwareProductManager.updateVsp(expectedVsp, USER1); + + VspDetails actualVsp = + vendorSoftwareProductDao.getVendorSoftwareProductInfo(new VspDetails(id001, VERSION01)); + + assertVspsEquals(actualVsp, expectedVsp); + } + + @Test(dependsOnMethods = {"testUpdateVSP"}) + public void testGetVSPDetailsAfterUpdate() { + VersionedVendorSoftwareProductInfo vspDetails = + vendorSoftwareProductManager.getVspDetails(id001, null, USER1); + Assert.assertEquals(vspDetails.getVspDetails().getName(), "VSP1"); + Assert.assertEquals(vspDetails.getVspDetails().getCategory(), "category"); + Assert.assertEquals(vspDetails.getVspDetails().getSubCategory(), "subCategory"); + Assert.assertEquals(vspDetails.getVspDetails().getVendorId(), vlm1Id); + Assert.assertEquals(vspDetails.getVersionInfo().getActiveVersion(), VERSION01); + Assert.assertEquals(vspDetails.getVersionInfo().getStatus(), org.openecomp.sdc.versioning.dao.types.VersionStatus.Locked); + Assert.assertEquals(vspDetails.getVersionInfo().getLockingUser(), USER1); + } + + @Test(dependsOnMethods = {"testGetVSPDetailsAfterUpdate"}) + public void testGetVSPList() { + String licenseAgreementId = "bla bla"; + VspDetails vspDetails = vendorSoftwareProductManager.createNewVsp(VSPCommon + .createVspDetails(null, null, "VSP3", "Test-vsp", "vendorName", vlm1Id, "icon", "category", + "subCategory", licenseAgreementId, null), USER1); + id002 = vspDetails.getId(); + vspDetails = vendorSoftwareProductManager.createNewVsp(VSPCommon + .createVspDetails(null, null, "VSP4", "Test-vsp", "vendorName", vlm1Id, "icon", "category", + "subCategory", licenseAgreementId, null), USER1); + id003 = vspDetails.getId(); + + List vspDetailsList = + vendorSoftwareProductManager.getVspList(null, USER1); + int foundCount = 0; + for (VersionedVendorSoftwareProductInfo vsp : vspDetailsList) { + if (vsp.getVspDetails().getId().equals(id001) || vsp.getVspDetails().getId().equals(id002) || + vsp.getVspDetails().getId().equals(id003)) { + foundCount++; + } + } + + Assert.assertEquals(foundCount, 3); + } + + @Test(dependsOnMethods = {"testGetVSPList"}) + // Unsupported operation for 1607 release. +/* public void testDeleteVSP() { + vendorSoftwareProductManager.deleteVsp(id001, USER1); + + VspDetails vspDetails = vendorSoftwareProductDao.getVendorSoftwareProductInfo(new VspDetails(id001, VERSION01)); + Assert.assertNull(vspDetails); + + List vspDetailsList = vendorSoftwareProductManager.getVspList(null, USER1); + boolean found001 = false; + for (VersionedVendorSoftwareProductInfo vsp : vspDetailsList) { + if (vsp.getVspDetails().getId().equals(id001)) { + found001 = true; + } + } + + Assert.assertFalse(found001); + } + + + @Test(dependsOnMethods = {"testDeleteVSP"})*/ + public void testCheckin() { + vendorSoftwareProductManager.checkin(id002, USER1); + + VersionedVendorSoftwareProductInfo vsp2 = + vendorSoftwareProductManager.getVspDetails(id002, null, USER1); + Assert.assertEquals(vsp2.getVersionInfo().getActiveVersion(), VERSION01); + Assert.assertEquals(vsp2.getVersionInfo().getStatus(), org.openecomp.sdc.versioning.dao.types.VersionStatus.Available); + Assert.assertNull(vsp2.getVersionInfo().getLockingUser()); + } + + @Test(dependsOnMethods = {"testCheckin"}) + public void testCheckout() { + vendorSoftwareProductManager.checkout(id002, USER2); + + VersionedVendorSoftwareProductInfo vsp2 = + vendorSoftwareProductManager.getVspDetails(id002, null, USER2); + Assert.assertEquals(vsp2.getVersionInfo().getActiveVersion(), new Version(0, 2)); + Assert.assertEquals(vsp2.getVersionInfo().getStatus(), org.openecomp.sdc.versioning.dao.types.VersionStatus.Locked); + Assert.assertEquals(vsp2.getVersionInfo().getLockingUser(), USER2); + + vsp2 = vendorSoftwareProductManager.getVspDetails(id002, null, USER1); + Assert.assertEquals(vsp2.getVersionInfo().getActiveVersion(), VERSION01); + Assert.assertEquals(vsp2.getVersionInfo().getStatus(), org.openecomp.sdc.versioning.dao.types.VersionStatus.Locked); + Assert.assertEquals(vsp2.getVersionInfo().getLockingUser(), USER2); + } + + @Test(dependsOnMethods = {"testCheckout"}) + public void testUndoCheckout() { + vendorSoftwareProductManager.undoCheckout(id002, USER2); + + VersionedVendorSoftwareProductInfo vsp2 = + vendorSoftwareProductManager.getVspDetails(id002, null, USER2); + Assert.assertEquals(vsp2.getVersionInfo().getActiveVersion(), VERSION01); + Assert.assertEquals(vsp2.getVersionInfo().getStatus(), org.openecomp.sdc.versioning.dao.types.VersionStatus.Available); + Assert.assertNull(vsp2.getVersionInfo().getLockingUser()); + } + + @Test(dependsOnMethods = {"testUndoCheckout"}) + public void testListFinalVspsWhenNone() { + List vspDetailsList = + vendorSoftwareProductManager.getVspList( + org.openecomp.sdc.versioning.dao.types.VersionStatus.Final.name(), USER1); + int nonFinalFoundCount = 0; + for (VersionedVendorSoftwareProductInfo vsp : vspDetailsList) { + if (vsp.getVspDetails().getId().equals(id001) || vsp.getVspDetails().getId().equals(id002) || + vsp.getVspDetails().getId().equals(id003)) { + nonFinalFoundCount++; + } + } + + Assert.assertEquals(nonFinalFoundCount, 0); + } + + @Test(dependsOnMethods = "testListFinalVspsWhenNone") + public void testSubmitWithoutLicencingData() throws IOException { + ValidationResponse validationResponse = vendorSoftwareProductManager.submit(id002, USER2); + Assert.assertNotNull(validationResponse); + Assert.assertFalse(validationResponse.isValid()); + List errorIds = validationResponse.getVspErrors().stream().map(ErrorCode::id).distinct() + .collect(Collectors.toList()); + Assert.assertTrue(errorIds.contains(ValidationErrorBuilder.FIELD_VALIDATION_ERROR_ERR_ID)); + Assert.assertTrue(errorIds.contains(VendorSoftwareProductErrorCodes.VSP_INVALID)); + } + + @Test(dependsOnMethods = {"testSubmitWithoutLicencingData"}) + public void testSubmitWithoutUploadData() throws IOException { + vendorSoftwareProductManager.checkout(id002, USER2); + + VspDetails updatedVsp2 = + vendorSoftwareProductManager.getVspDetails(id002, null, USER2).getVspDetails(); + updatedVsp2.setFeatureGroups(new ArrayList<>()); + updatedVsp2.getFeatureGroups().add(featureGroupId); + updatedVsp2.setLicenseAgreement(licenseAgreementId); + + vendorSoftwareProductManager.updateVsp(updatedVsp2, USER2); + activeVersion002 = vendorSoftwareProductManager.checkin(id002, USER2); + + ValidationResponse validationResponse = vendorSoftwareProductManager.submit(id002, USER2); + Assert.assertNotNull(validationResponse); + Assert.assertFalse(validationResponse.isValid()); + Assert.assertTrue(validationResponse.getVspErrors().size() > 0); + } + + @Test(dependsOnMethods = {"testSubmitWithoutUploadData"}) + public void testUploadFile() throws IOException { + activeVersion002 = vendorSoftwareProductManager.checkout(id002, USER1); + testLegalUpload(id002, activeVersion002, + getFileInputStream("/vspmanager/zips/emptyComposition.zip"), USER1); + } + +/* @Test(dependsOnMethods = {"testUploadFile"}) + public void testUploadFile2() throws IOException { + testLegalUpload(id002, activeVersion002, ut.getZipInputStream("/legalUpload2"), USER1); + }*/ + + @Test + public void testDownloadFile() throws IOException { + VspDetails expectedVsp = VSPCommon + .createVspDetails(null, null, String.format("VSP-test-%s", vlm1Id), "Test-vsp", + "vendorName", vlm1Id, "icon", "category", "subCategory", "123", null); + VspDetails createdVsp = vendorSoftwareProductManager.createNewVsp(expectedVsp, USER1); + + id005 = createdVsp.getId(); + Assert.assertNotNull(id005); + Assert.assertNotNull(createdVsp.getVersion()); + + //InputStream zipInputStream = getFileInputStream("/legalUpload/zip/legalUpload.zip") + try (InputStream zipInputStream = ut.getZipInputStream("/legalUpload")) { + + UploadFileResponse resp = + vendorSoftwareProductManager.uploadFile(id005, zipInputStream, USER1); + File latestHeatPackage = vendorSoftwareProductManager.getLatestHeatPackage(id005, USER1); + + zipInputStream.reset(); + byte[] uploaded = IOUtils.toByteArray(zipInputStream); + + byte[] downloaded; + try (BufferedInputStream fileStream = new BufferedInputStream( + new FileInputStream(latestHeatPackage))) { + downloaded = IOUtils.toByteArray(fileStream); + } + + Assert.assertTrue(Arrays.equals(uploaded, downloaded)); + } + } + + @Test(dependsOnMethods = {"testUploadFile"}) + public void testUploadNotExistingFile() throws IOException { + URL url = this.getClass().getResource("notExist.zip"); + testLegalUpload(id002, activeVersion002, url == null ? null : url.openStream(), USER1); + } + + @Test(dependsOnMethods = {"testUploadFile"}, expectedExceptions = CoreException.class) + public void negativeTestCreatePackageBeforeSubmit() throws IOException { + vendorSoftwareProductManager.createPackage(id002, USER1); + } + + @Test(dependsOnMethods = {"negativeTestCreatePackageBeforeSubmit"}) + public void negativeTestGetVSPDetailsNonExistingVersion() { + try { + vendorSoftwareProductManager.getVspDetails(id002, new Version(43, 8), USER1); + Assert.assertTrue(false); + } catch (CoreException e) { + Assert.assertEquals(e.code().id(), VersioningErrorCodes.REQUESTED_VERSION_INVALID); + } + } + + @Test(dependsOnMethods = {"negativeTestCreatePackageBeforeSubmit"}) + public void negativeTestGetVSPDetailsCheckoutByOtherVersion() { + try { + vendorSoftwareProductManager.getVspDetails(id002, activeVersion002, USER2); + Assert.assertTrue(false); + } catch (CoreException e) { + Assert.assertEquals(e.code().id(), VersioningErrorCodes.REQUESTED_VERSION_INVALID); + } + } + + @Test(dependsOnMethods = {"negativeTestCreatePackageBeforeSubmit"}) + public void testGetVSPDetailsCandidateVersion() { + VersionedVendorSoftwareProductInfo actualVsp = + vendorSoftwareProductManager.getVspDetails(id002, new Version(0, 3), USER1); + + VspDetails expectedVsp = vendorSoftwareProductDao + .getVendorSoftwareProductInfo(new VspDetails(id002, new Version(0, 3))); + assertVspsEquals(actualVsp.getVspDetails(), expectedVsp); + Assert.assertEquals(actualVsp.getVersionInfo().getActiveVersion(), new Version(0, 3)); + Assert.assertEquals(actualVsp.getVersionInfo().getStatus(), org.openecomp.sdc.versioning.dao.types.VersionStatus.Locked); + Assert.assertEquals(actualVsp.getVersionInfo().getLockingUser(), USER1); + } + + @Test(dependsOnMethods = {"negativeTestCreatePackageBeforeSubmit"}) + public void testGetVSPDetailsOldVersion() { + VersionedVendorSoftwareProductInfo actualVsp = + vendorSoftwareProductManager.getVspDetails(id002, new Version(0, 1), USER2); + + VspDetails expectedVsp = vendorSoftwareProductDao + .getVendorSoftwareProductInfo(new VspDetails(id002, new Version(0, 1))); + assertVspsEquals(actualVsp.getVspDetails(), expectedVsp); + Assert.assertEquals(actualVsp.getVersionInfo().getActiveVersion(), new Version(0, 2)); + Assert.assertEquals(actualVsp.getVersionInfo().getStatus(), org.openecomp.sdc.versioning.dao.types.VersionStatus.Locked); + Assert.assertEquals(actualVsp.getVersionInfo().getLockingUser(), USER1); + } + + @Test(dependsOnMethods = {"negativeTestGetVSPDetailsNonExistingVersion", + "negativeTestGetVSPDetailsCheckoutByOtherVersion", "testGetVSPDetailsCandidateVersion", + "testGetVSPDetailsOldVersion"}) + public void testSubmit() throws IOException { + activeVersion002 = vendorSoftwareProductManager.checkin(id002, USER1); + ValidationResponse validationResponse = vendorSoftwareProductManager.submit(id002, USER1); + Assert.assertTrue(validationResponse.isValid()); + + VersionedVendorSoftwareProductInfo vsp2 = + vendorSoftwareProductManager.getVspDetails(id002, null, USER1); + Assert.assertEquals(vsp2.getVersionInfo().getActiveVersion(), VERSION10); + Assert.assertEquals(vsp2.getVersionInfo().getStatus(), org.openecomp.sdc.versioning.dao.types.VersionStatus.Final); + Assert.assertNull(vsp2.getVersionInfo().getLockingUser()); + } + + @Test(dependsOnMethods = {"testSubmit"}) + public void testListFinalVspsWhenExist() { + List vspDetailsList = + vendorSoftwareProductManager.getVspList( + org.openecomp.sdc.versioning.dao.types.VersionStatus.Final.name(), USER1); + int nonFinalFoundCount = 0; + boolean found002 = false; + for (VersionedVendorSoftwareProductInfo vsp : vspDetailsList) { + if (vsp.getVspDetails().getId().equals(id002)) { + found002 = true; + } + if (vsp.getVspDetails().getId().equals(id001) || vsp.getVspDetails().getId().equals(id003)) { + nonFinalFoundCount++; + } + } + + Assert.assertEquals(nonFinalFoundCount, 0); + Assert.assertTrue(found002); + } + + @Test(dependsOnMethods = {"testSubmit"}) + public void testCreatePackage() throws IOException { + PackageInfo packageInfo = vendorSoftwareProductManager.createPackage(id002, USER1); + Assert.assertNotNull(packageInfo.getVspId()); + } + + @Test + public void testUploadFileWithoutManifest() { + InputStream zis = getFileInputStream("/vspmanager/zips/withoutManifest.zip"); + VspDetails vspDetails = vendorSoftwareProductManager.createNewVsp(VSPCommon + .createVspDetails(null, null, "VSP5", "Test-vsp", "vendorName", vlm1Id, "icon", "category", + "subCategory", "456", null), USER1); + id004 = vspDetails.getId(); + + UploadFileResponse uploadFileResponse = + vendorSoftwareProductManager.uploadFile(id004, zis, USER1); + + Assert.assertNotNull(uploadFileResponse.getErrors()); + Assert.assertEquals(uploadFileResponse.getErrors().size(), 1); + } + + @Test(dependsOnMethods = {"testUploadFileWithoutManifest"}) + public void testUploadFileMissingFile() { + InputStream zis = getFileInputStream("/vspmanager/zips/missingYml.zip"); + + UploadFileResponse uploadFileResponse = + vendorSoftwareProductManager.uploadFile(id004, zis, USER1); + + Assert.assertEquals(uploadFileResponse.getErrors().size(), 3); + } + + @Test(dependsOnMethods = {"testUploadFileMissingFile"}) + public void testUploadNotZipFile() throws IOException { + URL url = this.getClass().getResource("/notZipFile"); + UploadFileResponse uploadFileResponse = + vendorSoftwareProductManager.uploadFile(id004, url.openStream(), USER1); + + Assert.assertNotNull(uploadFileResponse.getErrors()); + Assert.assertEquals( + uploadFileResponse.getErrors().get(AsdcCommon.UPLOAD_FILE).get(0).getMessage(), + Messages.INVALID_ZIP_FILE.getErrorMessage()); + } + + @Test + public void testEnrichModelInSubmit() { + UniqueValueUtil + .deleteUniqueValue(VendorSoftwareProductConstants.UniqueValues.VENDOR_SOFTWARE_PRODUCT_NAME, + "VSP_syb"); + VspDetails vspDetails = vendorSoftwareProductManager.createNewVsp(VSPCommon + .createVspDetails(null, null, "VSP_syb", "Test-vsp_syb", "vendorName", vlm1Id, "icon", + "category", "subCategory", "456", null), USER1); + String id = vspDetails.getId(); + + //upload file + InputStream zis = getFileInputStream("/vspmanager/zips/fullComposition.zip"); + UploadFileResponse uploadFileResponse = vendorSoftwareProductManager.uploadFile(id, zis, USER1); + + //check in + vendorSoftwareProductManager.checkin(id, USER1); + //submit + try { + ValidationResponse result = vendorSoftwareProductManager.submit(id, USER1); + } catch (IOException e) { + Assert.fail(); + } + VersionedVendorSoftwareProductInfo details = + vendorSoftwareProductManager.getVspDetails(id, null, USER1); + Collection components = vendorSoftwareProductManager + .listComponents(id, details.getVersionInfo().getActiveVersion(), USER1); + + ToscaServiceModel model = + (ToscaServiceModel) EnrichedServiceModelDaoFactory.getInstance().createInterface() + .getServiceModel(id, details.getVersionInfo().getActiveVersion()); + + Map capabilities = new HashMap<>(); + for (org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity component : components) { + model.getServiceTemplates(). + entrySet(). + stream(). + filter(entryValue -> entryValue.getValue() != null && + entryValue.getValue().getNode_types() != null && + entryValue.getValue(). + getNode_types(). + containsKey(component.getComponentCompositionData().getName())). + forEach(entryValue -> entryValue.getValue().getNode_types(). + values(). + stream(). + filter(type -> MapUtils.isNotEmpty(type.getCapabilities())). + forEach(type -> type.getCapabilities(). + entrySet(). + forEach(entry -> addCapability(entryValue.getKey(), capabilities, entry.getKey(), + entry.getValue())))); + + } + + Assert.assertNotNull(capabilities); + } + + @Test(dependsOnMethods = {"testEnrichModelInSubmit"}) + public void testVSPListSortedByModificationTimeDescOreder() { + vsp1 = VSPCommon + .createVspDetails(null, null, "vsp1_test", "Test-vsp", "vendorName", vlm1Id, "icon", + "category", "subCategory", "123", null); + id006 = vendorSoftwareProductManager.createNewVsp(vsp1, USER3).getId(); + + vsp2 = VSPCommon + .createVspDetails(null, null, "vsp2_test", "Test-vsp", "vendorName", vlm1Id, "icon", + "category", "subCategory", "123", null); + id007 = vendorSoftwareProductManager.createNewVsp(vsp2, USER3).getId(); + + assertVSPInWantedLocationInVSPList(id007, 0, USER3); + assertVSPInWantedLocationInVSPList(id006, 1, USER3); + } + + @Test(dependsOnMethods = {"testVSPListSortedByModificationTimeDescOreder"}) + public void testUpdatedVSPShouldBeInBeginningOfList() { + vendorSoftwareProductManager.updateVsp(vsp1, USER3); + assertVSPInWantedLocationInVSPList(id006, 0, USER3); + + vendorSoftwareProductManager + .uploadFile(id007, getFileInputStream("/vspmanager/zips/emptyComposition.zip"), USER3); + assertVSPInWantedLocationInVSPList(id007, 0, USER3); + } + + @Test(dependsOnMethods = {"testUpdatedVSPShouldBeInBeginningOfList"}) + public void testVSPInBeginningOfListAfterCheckin() { + vendorSoftwareProductManager.checkin(id006, USER3); + assertVSPInWantedLocationInVSPList(id006, 0, USER3); + + vendorSoftwareProductManager.checkin(id007, USER3); + assertVSPInWantedLocationInVSPList(id007, 0, USER3); + } + + @Test(dependsOnMethods = {"testVSPInBeginningOfListAfterCheckin"}) + public void testVSPInBeginningOfListAfterCheckout() { + vendorSoftwareProductManager.checkout(id006, USER3); + assertVSPInWantedLocationInVSPList(id006, 0, USER3); + } + + @Test(dependsOnMethods = {"testVSPInBeginningOfListAfterCheckout"}) + public void testVSPInBeginningOfListAfterUndoCheckout() { + vendorSoftwareProductManager.checkout(id007, USER3); + assertVSPInWantedLocationInVSPList(id007, 0, USER3); + + vendorSoftwareProductManager.undoCheckout(id006, USER3); + assertVSPInWantedLocationInVSPList(id006, 0, USER3); + } + + @Test(dependsOnMethods = {"testVSPInBeginningOfListAfterUndoCheckout"}) + public void testVSPInBeginningOfListAfterSubmit() throws IOException { + vendorSoftwareProductManager.checkin(id007, USER3); + vendorSoftwareProductManager.submit(id007, USER3); + + assertVSPInWantedLocationInVSPList(id007, 0, USER3); + } + + private void testLegalUpload(String vspId, Version version, InputStream upload, String user) { + vendorSoftwareProductManager.uploadFile(vspId, upload, user); + + UploadDataEntity uploadData = + vendorSoftwareProductDao.getUploadData(new UploadDataEntity(vspId, version)); + Assert.assertNotNull(uploadData); + Assert.assertNotNull(uploadData.getContentData()); + } + + private void addCapability(String entryValueKey, Map capabilities, + String key, CapabilityDefinition value) { + + capabilities.put(entryValueKey + "_" + key, value); + } + + private InputStream getFileInputStream(String fileName) { + URL url = this.getClass().getResource(fileName); + try { + return url.openStream(); + } catch (IOException e) { + e.printStackTrace(); + return null; + } + } + + private void assertVSPInWantedLocationInVSPList(String vspId, int location, String user) { + List vspList = + vendorSoftwareProductManager.getVspList(null, user); + Assert.assertEquals(vspList.get(location).getVspDetails().getId(), vspId); + } +} \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/services/CompositionDataExtractorTest.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/services/CompositionDataExtractorTest.java new file mode 100644 index 0000000000..55f30db609 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/services/CompositionDataExtractorTest.java @@ -0,0 +1,280 @@ +package org.openecomp.sdc.vendorsoftwareproduct.services; + +import org.openecomp.sdc.tosca.datatypes.ToscaServiceModel; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.services.yamlutil.ToscaExtensionYamlUtil; + +import org.testng.Assert; +import org.testng.annotations.Test; + +import java.io.*; +import java.net.URL; +import java.nio.file.NotDirectoryException; +import java.util.HashMap; +import java.util.Map; + +public class CompositionDataExtractorTest { + + + private static ToscaServiceModel loadToscaServiceModel(String serviceTemplatesPath, + String globalServiceTemplatesPath, + String entryDefinitionServiceTemplate) + throws IOException { + ToscaExtensionYamlUtil toscaExtensionYamlUtil = new ToscaExtensionYamlUtil(); + Map serviceTemplates = new HashMap<>(); + if (entryDefinitionServiceTemplate == null) { + entryDefinitionServiceTemplate = "MainServiceTemplate.yaml"; + } + + loadServiceTemplates(serviceTemplatesPath, toscaExtensionYamlUtil, serviceTemplates); + if (globalServiceTemplatesPath != null) { + loadServiceTemplates(globalServiceTemplatesPath, toscaExtensionYamlUtil, serviceTemplates); + } + + return new ToscaServiceModel(null, serviceTemplates, entryDefinitionServiceTemplate); + } + + private static void loadServiceTemplates(String serviceTemplatesPath, + ToscaExtensionYamlUtil toscaExtensionYamlUtil, + Map serviceTemplates) + throws IOException { + URL urlFile = CompositionDataExtractorTest.class.getResource(serviceTemplatesPath); + if (urlFile != null) { + File pathFile = new File(urlFile.getFile()); + File[] files = pathFile.listFiles(); + if (files != null) { + addServiceTemplateFiles(serviceTemplates, files, toscaExtensionYamlUtil); + } else { + throw new NotDirectoryException(serviceTemplatesPath); + } + } else { + throw new NotDirectoryException(serviceTemplatesPath); + } + } + + private static void addServiceTemplateFiles(Map serviceTemplates, + File[] files, + ToscaExtensionYamlUtil toscaExtensionYamlUtil) + throws IOException { + for (File file : files) { + try (InputStream yamlFile = new FileInputStream(file)) { + ServiceTemplate serviceTemplateFromYaml = + toscaExtensionYamlUtil.yamlToObject(yamlFile, ServiceTemplate.class); + serviceTemplates.put(file.getName(), serviceTemplateFromYaml); + try { + yamlFile.close(); + } catch (IOException ignore) { + } + } catch (FileNotFoundException e) { + throw e; + } catch (IOException e) { + throw e; + } + } + } + + @Test + public void testExtractNetworks() throws Exception { + ToscaServiceModel toscaServiceModel = + loadToscaServiceModel("/extractServiceComposition/networks/", + "/extractServiceComposition/toscaGlobalServiceTemplates/", null); + org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionData compositionData = + CompositionDataExtractor.extractServiceCompositionData(toscaServiceModel); + Assert.assertEquals(compositionData.getComponents().size(), 0); + Assert.assertEquals(compositionData.getNetworks().size(), 7); + + for (org.openecomp.sdc.vendorsoftwareproduct.types.composition.Network network : compositionData.getNetworks()) { + boolean dhcp = network.isDhcp(); + switch (network.getName()) { + case "contail-net-default-true-dhcp": + Assert.assertEquals(dhcp, true); + break; + case "contail-net-dhcp-false-param": + Assert.assertEquals(dhcp, false); + break; + case "contail-net-dhcp-false": + Assert.assertEquals(dhcp, false); + break; + case "contail-net-dhcp-true-param": + Assert.assertEquals(dhcp, true); + break; + case "contail-net-dhcp-true": + Assert.assertEquals(dhcp, true); + break; + case "contail-net-dhcp-default-true-param": + Assert.assertEquals(dhcp, true); + break; + case "neutron-net-default-dhcp": + Assert.assertEquals(dhcp, true); + break; + default: + throw new Exception("Unexpected Network Name " + network.getName()); + } + + } + } + + @Test + public void testExtractOnlyComponents() throws Exception { + ToscaServiceModel toscaServiceModel = + loadToscaServiceModel("/extractServiceComposition/onlyComponents/", + "/extractServiceComposition/toscaGlobalServiceTemplates/", "OnlyComponentsST.yaml"); + org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionData compositionData = + CompositionDataExtractor.extractServiceCompositionData(toscaServiceModel); + Assert.assertEquals(compositionData.getComponents().size(), 3); + Assert.assertEquals(compositionData.getNetworks().size(), 0); + + for (org.openecomp.sdc.vendorsoftwareproduct.types.composition.Component component : compositionData.getComponents()) { + switch (component.getData().getName()) { + case "org.openecomp.resource.vfc.nodes.heat.pcrf_psm": + Assert.assertNull(component.getNics()); + Assert.assertEquals(component.getData().getDisplayName(), "pcrf_psm"); + break; + case "org.openecomp.resource.vfc.nodes.heat.nova.Server": + Assert.assertNull(component.getNics()); + Assert.assertEquals(component.getData().getDisplayName(), "Server"); + break; + case "org.openecomp.resource.vfc.nodes.heat.pcm": + Assert.assertNull(component.getNics()); + Assert.assertEquals(component.getData().getDisplayName(), "pcm"); + break; + default: + throw new Exception("Unexpected ComponentData Name " + component.getData().getName()); + } + } + } + + @Test + public void testExtractComponentsWithPorts() throws Exception { + + ToscaServiceModel toscaServiceModel = + loadToscaServiceModel("/extractServiceComposition/componentsWithPort/", + "/extractServiceComposition/toscaGlobalServiceTemplates/", "ComponentsWithPortST.yaml"); + org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionData compositionData = + CompositionDataExtractor.extractServiceCompositionData(toscaServiceModel); + + Assert.assertEquals(compositionData.getComponents().size(), 3); + Assert.assertEquals(compositionData.getNetworks().size(), 0); + + for (org.openecomp.sdc.vendorsoftwareproduct.types.composition.Component component : compositionData.getComponents()) { + switch (component.getData().getName()) { + case "org.openecomp.resource.vfc.nodes.heat.pcrf_psm": + Assert.assertEquals(component.getNics().size(), 1); + Assert.assertEquals(component.getNics().get(0).getName(), "psm01_port_0"); + Assert.assertNull(component.getNics().get(0).getNetworkName()); + Assert.assertEquals(component.getData().getDisplayName(), "pcrf_psm"); + break; + case "org.openecomp.resource.vfc.nodes.heat.nova.Server": + Assert.assertEquals(component.getNics().size(), 1); + Assert.assertEquals(component.getNics().get(0).getName(), "FSB1_Internal2"); + Assert.assertNull(component.getNics().get(0).getNetworkName()); + Assert.assertEquals(component.getData().getDisplayName(), "Server"); + break; + case "org.openecomp.resource.vfc.nodes.heat.pcm": + Assert.assertEquals(component.getNics().size(), 2); + Assert.assertEquals(component.getData().getDisplayName(), "pcm"); + break; + default: + throw new Exception("Unexpected ComponentData Name " + component.getData().getName()); + } + } + } + + @Test + public void testExtractFullComposition() throws Exception { + + ToscaServiceModel toscaServiceModel = + loadToscaServiceModel("/extractServiceComposition/fullComposition/", + "/extractServiceComposition/toscaGlobalServiceTemplates/", null); + org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionData compositionData = + CompositionDataExtractor.extractServiceCompositionData(toscaServiceModel); + Assert.assertEquals(compositionData.getComponents().size(), 3); + Assert.assertEquals(compositionData.getNetworks().size(), 3); + + for (org.openecomp.sdc.vendorsoftwareproduct.types.composition.Component component : compositionData.getComponents()) { + switch (component.getData().getName()) { + case "org.openecomp.resource.vfc.nodes.heat.pcrf_psm": + Assert.assertEquals(component.getNics().size(), 1); + Assert.assertEquals(component.getNics().get(0).getName(), "psm01_port_0"); + Assert.assertNull(component.getNics().get(0).getNetworkName()); + Assert.assertEquals(component.getData().getDisplayName(), "pcrf_psm"); + break; + case "org.openecomp.resource.vfc.nodes.heat.nova.Server": + Assert.assertEquals(component.getNics().size(), 3); + Assert.assertEquals(component.getData().getDisplayName(), "Server"); + for (org.openecomp.sdc.vendorsoftwareproduct.types.composition.Nic port : component.getNics()) { + switch (port.getName()) { + case "FSB1_Internal2_port": + Assert.assertEquals(port.getNetworkName(), "Internal2-net"); + break; + case "FSB1_OAM_Port": + Assert.assertNull(port.getNetworkName()); + break; + case "FSB1_Internal1_port": + Assert.assertEquals(port.getNetworkName(), "Internal1-net"); + break; + default: + throw new Exception("Unexpected Nic " + port.getName()); + } + } + break; + case "org.openecomp.resource.vfc.nodes.heat.pcm": + Assert.assertEquals(component.getNics().size(), 2); + Assert.assertEquals(component.getData().getDisplayName(), "pcm"); + break; + default: + throw new Exception("Unexpected ComponentData Name " + component.getData().getName()); + } + } + } + + @Test + public void testExtractSubstitutionComposition() throws Exception { + + ToscaServiceModel toscaServiceModel = + loadToscaServiceModel("/extractServiceComposition/substitution/", + "/extractServiceComposition/toscaGlobalServiceTemplates/", null); + org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionData compositionData = + CompositionDataExtractor.extractServiceCompositionData(toscaServiceModel); + Assert.assertEquals(compositionData.getComponents().size(), 2); + Assert.assertEquals(compositionData.getNetworks().size(), 4); + + for (org.openecomp.sdc.vendorsoftwareproduct.types.composition.Component component : compositionData.getComponents()) { + switch (component.getData().getName()) { + case "org.openecomp.resource.vfc.nodes.heat.cmaui_image": + Assert.assertEquals(component.getNics().size(), 1); + Assert.assertEquals(component.getNics().get(0).getName(), "cmaui_port_1"); + Assert.assertEquals(component.getNics().get(0).getNetworkName(), "test_net1"); + Assert.assertEquals(component.getData().getDisplayName(), "cmaui_image"); + break; + case "org.openecomp.resource.vfc.nodes.heat.abc_image": + Assert.assertEquals(component.getNics().size(), 1); + Assert.assertEquals(component.getNics().get(0).getName(), "abc_port_1"); + Assert.assertEquals(component.getNics().get(0).getNetworkName(), "test_net2"); + Assert.assertEquals(component.getData().getDisplayName(), "abc_image"); + break; + default: + throw new Exception("Unexpected ComponentData Name " + component.getData().getName()); + } + } + for (org.openecomp.sdc.vendorsoftwareproduct.types.composition.Network network : compositionData.getNetworks()) { + boolean dhcp = network.isDhcp(); + switch (network.getName()) { + case "test_net2": + Assert.assertEquals(dhcp, true); + break; + case "test_net1": + Assert.assertEquals(dhcp, true); + break; + case "Internal1-net": // same network display twice since define in 2 nested files with the same key + Assert.assertEquals(dhcp, true); + break; + default: + throw new Exception("Unexpected Network Name " + network.getName()); + } + + } + } + + +} \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/services/CompositionEntityDataManagerTest.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/services/CompositionEntityDataManagerTest.java new file mode 100644 index 0000000000..e1ddcdc975 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/services/CompositionEntityDataManagerTest.java @@ -0,0 +1,141 @@ +package org.openecomp.sdc.vendorsoftwareproduct.services; + +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.NetworkEntity; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.VspQuestionnaireEntity; +import org.openecomp.sdc.vendorsoftwareproduct.types.CompositionEntityValidationData; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionEntityId; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionEntityType; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.Network; +import org.openecomp.sdc.vendorsoftwareproduct.types.schemagenerator.NetworkCompositionSchemaInput; +import org.openecomp.sdc.vendorsoftwareproduct.types.schemagenerator.SchemaTemplateContext; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.apache.commons.collections.CollectionUtils; +import org.testng.Assert; +import org.testng.annotations.Test; + +import java.util.Collection; +import java.util.Map; + +public class CompositionEntityDataManagerTest { + + public static final String VSP1 = "vsp1"; + public static final String COMPONENT1 = "component1"; + public static final String NIC1 = "nic1"; + private static CompositionEntityDataManager compositionEntityDataManager = + new CompositionEntityDataManager(); + private static Map> errorsById; + + private static void assertValidationData(CompositionEntityValidationData validationData, + String id, CompositionEntityType type, + boolean hasErrors) { + Assert.assertNotNull(validationData); + Assert.assertEquals(validationData.getEntityId(), id); + Assert.assertEquals(validationData.getEntityType(), type); + Assert.assertTrue(CollectionUtils.isNotEmpty(validationData.getErrors()) == hasErrors); + } + + @Test(expectedExceptions = CoreException.class) + public void testAddNullEntity_negative() { + compositionEntityDataManager.addEntity(null, null); + } + + @Test + public void testAddEntity() { + compositionEntityDataManager + .addEntity(new VspQuestionnaireEntity(VSP1, new Version(0, 1)), null); + + String invalidQuestionnaireData = "{\"a\": \"b\"}"; + + ComponentEntity component = new ComponentEntity(VSP1, new Version(0, 1), COMPONENT1); + component.setQuestionnaireData(invalidQuestionnaireData); + compositionEntityDataManager.addEntity(component, null); + + org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity + nic = new org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity(VSP1, new Version(0, 1), COMPONENT1, NIC1); + nic.setQuestionnaireData(invalidQuestionnaireData); + compositionEntityDataManager.addEntity(nic, null); + } + + @Test(dependsOnMethods = "testAddEntity") + public void testValidateEntitiesQuestionnaire() { + errorsById = compositionEntityDataManager.validateEntitiesQuestionnaire(); + Assert.assertNotNull(errorsById); + Assert.assertEquals(errorsById.size(), 2); // both component and nic data don't mach schemas + CompositionEntityId nicId = + new org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity(VSP1, new Version(0, 1), COMPONENT1, NIC1).getCompositionEntityId(); + Assert.assertTrue(errorsById.containsKey(nicId)); + Assert.assertTrue(errorsById.containsKey(nicId.getParentId())); + } + + @Test(dependsOnMethods = "testAddEntity") + public void testBuildTrees() { + compositionEntityDataManager.buildTrees(); + } + + @Test(dependsOnMethods = "testBuildTrees") + public void testAddErrorsToTrees() { + compositionEntityDataManager.addErrorsToTrees(errorsById); + } + + @Test(dependsOnMethods = "testAddErrorsToTrees") + public void testGetTrees() { + Collection trees = compositionEntityDataManager.getTrees(); + Assert.assertNotNull(trees); + Assert.assertEquals(trees.size(), 1); + + CompositionEntityValidationData vspValidationData = trees.iterator().next(); + assertValidationData(vspValidationData, VSP1, CompositionEntityType.vsp, false); + Assert.assertEquals(vspValidationData.getSubEntitiesValidationData().size(), 1); + + CompositionEntityValidationData componentValidationData = + vspValidationData.getSubEntitiesValidationData().iterator().next(); + assertValidationData(componentValidationData, COMPONENT1, CompositionEntityType.component, + true); + Assert.assertEquals(componentValidationData.getSubEntitiesValidationData().size(), 1); + + CompositionEntityValidationData nicValidationData = + componentValidationData.getSubEntitiesValidationData().iterator().next(); + assertValidationData(nicValidationData, NIC1, CompositionEntityType.nic, true); + Assert.assertNull(nicValidationData.getSubEntitiesValidationData()); + } + + @Test + public void testValidateValidEntity() { + NetworkEntity networkEntity = new NetworkEntity(VSP1, new Version(0, 1), "network1"); + Network network = new Network(); + network.setName("network1 name"); + network.setDhcp(true); + networkEntity.setNetworkCompositionData(network); + + NetworkCompositionSchemaInput schemaTemplateInput = new NetworkCompositionSchemaInput(); + schemaTemplateInput.setManual(false); + schemaTemplateInput.setNetwork(network); + + CompositionEntityValidationData validationData = CompositionEntityDataManager + .validateEntity(networkEntity, SchemaTemplateContext.composition, schemaTemplateInput); + assertValidationData(validationData, "network1", CompositionEntityType.network, false); + } + + @Test + public void testValidateInvalidEntity() { + NetworkEntity networkEntity = new NetworkEntity(VSP1, new Version(0, 1), "network1"); + Network network = new Network(); + network.setName("network1 name changed"); + network.setDhcp(false); + networkEntity.setNetworkCompositionData(network); + + NetworkCompositionSchemaInput schemaTemplateInput = new NetworkCompositionSchemaInput(); + schemaTemplateInput.setManual(false); + Network origNetwork = new Network(); + origNetwork.setName("network1 name"); + origNetwork.setDhcp(true); + schemaTemplateInput.setNetwork(origNetwork); + + CompositionEntityValidationData validationData = CompositionEntityDataManager + .validateEntity(networkEntity, SchemaTemplateContext.composition, schemaTemplateInput); + assertValidationData(validationData, "network1", CompositionEntityType.network, true); + Assert.assertEquals(validationData.getErrors().size(), 2); + } +} \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/services/QuestionnaireSchemaTest.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/services/QuestionnaireSchemaTest.java new file mode 100644 index 0000000000..4d03b5980f --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/services/QuestionnaireSchemaTest.java @@ -0,0 +1,64 @@ +package org.openecomp.sdc.vendorsoftwareproduct.services; + +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.VspQuestionnaireEntity; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionEntityId; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.core.utilities.file.FileUtils; + +import org.testng.Assert; +import org.testng.annotations.Test; + +import java.util.Collection; +import java.util.List; +import java.util.Map; + +public class QuestionnaireSchemaTest { + + public static final String VSP1 = "vsp1"; + public static final String COMPONENT1 = "component1"; + public static final String NIC1 = "nic1"; + private static CompositionEntityDataManager compositionEntityDataManager = + new CompositionEntityDataManager(); + private static Map> errorsById; + private static org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity componentEntity; + private static org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity nicEntity; + + private static String loadFileToString(String path) { + return new String(FileUtils.toByteArray(FileUtils.loadFileToInputStream(path))); + } + + @Test + public void testAddEntity() { + compositionEntityDataManager + .addEntity(new VspQuestionnaireEntity(VSP1, new Version(0, 1)), null); + + componentEntity = new org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity(VSP1, new Version(0, 1), COMPONENT1); + nicEntity = new org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity(VSP1, new Version(0, 1), COMPONENT1, NIC1); + compositionEntityDataManager.addEntity(componentEntity, null); + + componentEntity.setQuestionnaireData(loadFileToString("quesionnaire/validComponent.json")); + nicEntity.setQuestionnaireData(loadFileToString("quesionnaire/validNic.json")); + compositionEntityDataManager.addEntity(nicEntity, null); + } + + @Test(dependsOnMethods = "testAddEntity") + public void testNicAndComponentValidQuestionnaire() { + errorsById = compositionEntityDataManager.validateEntitiesQuestionnaire(); + Assert.assertEquals(errorsById.size(), 0); + } + + @Test(dependsOnMethods = "testNicAndComponentValidQuestionnaire") + public void testComponentInvalidQuestionnaire() { + componentEntity.setQuestionnaireData(loadFileToString("quesionnaire/invalidComponent.json")); + compositionEntityDataManager.addEntity(componentEntity, null); + + errorsById = compositionEntityDataManager.validateEntitiesQuestionnaire(); + Assert.assertEquals(errorsById.size(), 1); + + CompositionEntityId component = errorsById.keySet().iterator().next(); + List errors = (List) errorsById.get(component); + Assert.assertEquals(errors.size(), 1); + Assert.assertEquals(errors.get(0), + "#/general/recovery/pointObjective: 20.0 is not lower or equal to 15"); + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/services/QuestionnaireValidatorTest.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/services/QuestionnaireValidatorTest.java new file mode 100644 index 0000000000..0dedacb34a --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/services/QuestionnaireValidatorTest.java @@ -0,0 +1,74 @@ +package org.openecomp.sdc.vendorsoftwareproduct.services; + +public class QuestionnaireValidatorTest { +/* + public static QuestionnaireValidator validator = new QuestionnaireValidator(); + + @Test(expectedExceptions = CoreException.class) + public void testAddSubEntityBeforeRoot_negative() { + validator.addSubEntity(createComponent("componentId2"), CompositionEntityType.vsp); + } + + @Test(dependsOnMethods = "testAddSubEntityBeforeRoot_negative") + public void testAddRootEntity() { + validator.addRootEntity(createVspQuestionnaireEntity()); + } + + @Test(dependsOnMethods = "testAddRootEntity", expectedExceptions = CoreException.class) + public void testAddRootEntityWhenAlreadyExist_negative() { + validator.addRootEntity(createVspQuestionnaireEntity()); + } + + @Test(dependsOnMethods = "testAddRootEntity") + public void testAddSubEntity() { + validator.addSubEntity(createComponent("componentId1"), CompositionEntityType.vsp); + } + + @Test(dependsOnMethods = "testAddRootEntity", expectedExceptions = CoreException.class) + public void testAddSubEntityWithNonExistingParentType() { + validator.addSubEntity(new ComponentEntity("vspId1", new Version(0, 1), "componentId2"), CompositionEntityType.nic); + } + + @Test(dependsOnMethods = "testAddSubEntity") + public void testAddSubEntities() throws Exception { + Collection nics = new ArrayList<>(); + nics.add(createNic("nicId1", "componentId1")); + nics.add(createNic("nicId2", "componentId1")); + nics.add(createNic("nicId3", "componentId1")); + + validator.addSubEntities(nics, CompositionEntityType.component); + } + + + @Test(dependsOnMethods = "testAddSubEntities") + public void testValidate() throws Exception { + QuestionnaireValidationResult validationResult = validator.validate(); + Assert.assertTrue(validationResult.isValid()); + } + + private static VspQuestionnaireEntity createVspQuestionnaireEntity() { + VspQuestionnaireEntity vspQuestionnaireEntity = new VspQuestionnaireEntity(); + vspQuestionnaireEntity.setId("vspId1"); + vspQuestionnaireEntity.setVersion(new Version(0, 1)); + vspQuestionnaireEntity.setQuestionnaireData("{\n" + + " \"name\": \"bla bla\"\n" + + "}"); + return vspQuestionnaireEntity; + } + + private static ComponentEntity createComponent(String componentId) { + ComponentEntity component = new ComponentEntity("vspId1", new Version(0, 1), componentId); + component.setQuestionnaireData("{\n" + + " \"name\": \"bla bla\"\n" + + "}"); + return component; + } + + private static CompositionEntity createNic(String nicId, String componentId) { + NicEntity nic = new NicEntity("vspId1", new Version(0, 1), componentId, nicId); + nic.setQuestionnaireData("{\n" + + " \"name\": \"bla bla\"\n" + + "}"); + return nic; + }*/ +} \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/services/SchemaGeneratorTest.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/services/SchemaGeneratorTest.java new file mode 100644 index 0000000000..fd293c66dd --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/services/SchemaGeneratorTest.java @@ -0,0 +1,244 @@ +package org.openecomp.sdc.vendorsoftwareproduct.services; + +import org.openecomp.core.utilities.json.JsonUtil; +import org.everit.json.schema.EmptySchema; +import org.everit.json.schema.loader.SchemaLoader; +import org.json.JSONObject; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.ComponentData; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionEntityType; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.Network; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.NetworkType; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.Nic; +import org.openecomp.sdc.vendorsoftwareproduct.types.schemagenerator.ComponentCompositionSchemaInput; +import org.openecomp.sdc.vendorsoftwareproduct.types.schemagenerator.ComponentQuestionnaireSchemaInput; +import org.openecomp.sdc.vendorsoftwareproduct.types.schemagenerator.NetworkCompositionSchemaInput; +import org.openecomp.sdc.vendorsoftwareproduct.types.schemagenerator.NicCompositionSchemaInput; +import org.openecomp.sdc.vendorsoftwareproduct.types.schemagenerator.SchemaTemplateContext; +import org.testng.Assert; +import org.testng.annotations.Test; + +import java.util.Arrays; +import java.util.Map; + +public class SchemaGeneratorTest { + + private static int getMinOfVmMax(JSONObject schemaJson) { + return schemaJson.getJSONObject("properties").getJSONObject("compute") + .getJSONObject("properties").getJSONObject("numOfVMs").getJSONObject("properties") + .getJSONObject("maximum").getInt("minimum"); + } + + private static JSONObject validateSchema(String schema) { + System.out.println(schema); + Assert.assertNotNull(schema); + Assert.assertTrue(JsonUtil.isValidJson(schema)); + JSONObject schemaJson = new JSONObject(schema); + Assert.assertFalse(SchemaLoader.load(schemaJson) instanceof EmptySchema); + return schemaJson; + } + + @Test + public void testGenerateVspQuestionnaire() { + String schema = SchemaGenerator + .generate(SchemaTemplateContext.questionnaire, CompositionEntityType.vsp, null); + validateSchema(schema); + } + + @Test + public void testGenerateNetworkCompositionUpload() { + Network network = new Network(); + network.setName("upload network1 name"); + network.setDhcp(true); + + NetworkCompositionSchemaInput input = new NetworkCompositionSchemaInput(); + input.setManual(false); + input.setNetwork(network); + + String schema = SchemaGenerator + .generate(SchemaTemplateContext.composition, CompositionEntityType.network, input); + validateSchema(schema); + } + + @Test + public void testGenerateNetworkCompositionManual() { + NetworkCompositionSchemaInput input = new NetworkCompositionSchemaInput(); + input.setManual(true); + + String schema = SchemaGenerator + .generate(SchemaTemplateContext.composition, CompositionEntityType.network, input); + + validateSchema(schema); + } + + @Test + public void testGenerateComponentQuestionnaireWithoutInput() { + String schema = SchemaGenerator + .generate(SchemaTemplateContext.questionnaire, CompositionEntityType.component, null); + validateSchema(schema); + } + + @Test + public void testGenerateComponentQuestionnaireWithMissingInput() { + ComponentQuestionnaireSchemaInput input = + new ComponentQuestionnaireSchemaInput(Arrays.asList("nic1", "nic2"), + JsonUtil.json2Object("{\n" + + " \"compute\": {\n" + + " \"numOfVMs\": {\n" + + " \"blabla\": 70\n" + // no minimum + " }\n" + + " }\n" + + "}", Map.class)); + String schema = SchemaGenerator + .generate(SchemaTemplateContext.questionnaire, CompositionEntityType.component, input); + JSONObject schemaJson = validateSchema(schema); + //Assert.assertEquals(getMinOfVmMax(schemaJson), 0); + } + + @Test + public void testGenerateComponentQuestionnaireWithInvalidTypeInput() { + ComponentQuestionnaireSchemaInput input = + new ComponentQuestionnaireSchemaInput(Arrays.asList("nic1", "nic2"), + JsonUtil.json2Object("{\n" + + " \"compute\": {\n" + + " \"numOfVMs\": {\n" + + " \"minimum\": \"some string instead of integer\"\n" + + // invalid minimum - string + " }\n" + + " }\n" + + "}", Map.class)); + String schema = SchemaGenerator + .generate(SchemaTemplateContext.questionnaire, CompositionEntityType.component, input); + JSONObject schemaJson = validateSchema(schema); + Assert.assertEquals(getMinOfVmMax(schemaJson), 0); + } + + @Test + public void testGenerateComponentQuestionnaireWithInvalidRangeInput() { + ComponentQuestionnaireSchemaInput input = + new ComponentQuestionnaireSchemaInput(Arrays.asList("nic1", "nic2"), + JsonUtil.json2Object("{\n" + + " \"compute\": {\n" + + " \"numOfVMs\": {\n" + + " \"minimum\": 150\n" + // invalid minimum - integer out of range (0-100) + " }\n" + + " }\n" + + "}", Map.class)); + String schema = SchemaGenerator + .generate(SchemaTemplateContext.questionnaire, CompositionEntityType.component, input); + JSONObject schemaJson = validateSchema(schema); + Assert.assertEquals(getMinOfVmMax(schemaJson), 0); + } + + @Test + public void testGenerateComponentQuestionnaireWithValidInput() { + ComponentQuestionnaireSchemaInput input = + new ComponentQuestionnaireSchemaInput(Arrays.asList("nic1", "nic2"), + JsonUtil.json2Object("{\n" + + " \"compute\": {\n" + + " \"numOfVMs\": {\n" + + " \"minimum\": 30\n" + // valid minimum - integer at the correct range (0-100) + " }\n" + + " }\n" + + "}", Map.class)); + String schema = SchemaGenerator + .generate(SchemaTemplateContext.questionnaire, CompositionEntityType.component, input); + JSONObject schemaJson = validateSchema(schema); + Assert.assertEquals(getMinOfVmMax(schemaJson), 30); + } + + @Test + public void testGenerateNicQuestionnaire() { + String schema = SchemaGenerator + .generate(SchemaTemplateContext.questionnaire, CompositionEntityType.nic, null); + validateSchema(schema); + } + + @Test + public void testGenerateComponentCompositionUpload() { + ComponentData component = new ComponentData(); + component.setName("upload comp1 name"); + component.setDescription("upload comp1 desc"); + + ComponentCompositionSchemaInput input = new ComponentCompositionSchemaInput(); + input.setManual(false); + input.setComponent(component); + + String schema = SchemaGenerator + .generate(SchemaTemplateContext.composition, CompositionEntityType.component, input); + validateSchema(schema); + } + + @Test + public void testGenerateComponentCompositionManual() { + ComponentCompositionSchemaInput input = new ComponentCompositionSchemaInput(); + input.setManual(true); + + String schema = SchemaGenerator + .generate(SchemaTemplateContext.composition, CompositionEntityType.component, input); + validateSchema(schema); + } + + @Test + public void testGenerateNicCompositionUpload() { + Nic nic = new Nic(); + nic.setName("upload nic1 name"); + nic.setDescription("upload nic1 desc"); + nic.setNetworkId("upload nic1 networkId"); + //nic.setNetworkName("upload nic1 networkName"); + nic.setNetworkType(NetworkType.External); + + NicCompositionSchemaInput input = new NicCompositionSchemaInput(); + input.setManual(false); + input.setNic(nic); + + String schema = SchemaGenerator + .generate(SchemaTemplateContext.composition, CompositionEntityType.nic, input); + validateSchema(schema); + } + + +// @Test +// public void testGenerateNicCompositionManualWithoutNetworkId() { +// Nic nic = new Nic(); +// nic.setName("upload nic1 name"); +// nic.setDescription("upload nic1 desc"); +// //nic.setNetworkName("upload nic1 networkName"); +// nic.setNetworkType(NetworkType.External); +// +// NicCompositionSchemaInput input = new NicCompositionSchemaInput(); +// input.setManual(true); +// input.setNic(nic); +// +// String schema = SchemaGenerator.generate(SchemaTemplateContext.composition, CompositionEntityType.nic, input); +// validateSchema(schema); +// } + + @Test + public void testGenerateNicCompositionUploadWithoutNetworkId() { + Nic nic = new Nic(); + nic.setName("upload nic1 name"); + nic.setDescription("upload nic1 desc"); + //nic.setNetworkName("upload nic1 networkName"); + nic.setNetworkType(NetworkType.External); + + NicCompositionSchemaInput input = new NicCompositionSchemaInput(); + input.setManual(false); + input.setNic(nic); + + String schema = SchemaGenerator + .generate(SchemaTemplateContext.composition, CompositionEntityType.nic, input); + validateSchema(schema); + } + + @Test + public void testGenerateNicCompositionManual() { + NicCompositionSchemaInput input = new NicCompositionSchemaInput(); + input.setManual(true); + input.setNetworkIds( + Arrays.asList("manual networkId1", "manual networkId2", "manual networkId3")); + + String schema = SchemaGenerator + .generate(SchemaTemplateContext.composition, CompositionEntityType.nic, input); + validateSchema(schema); + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/tree/HeatTreeManagerTest.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/tree/HeatTreeManagerTest.java new file mode 100644 index 0000000000..c926977c7b --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/tree/HeatTreeManagerTest.java @@ -0,0 +1,102 @@ +package org.openecomp.sdc.vendorsoftwareproduct.tree; + +import org.openecomp.sdc.datatypes.error.ErrorMessage; +import org.openecomp.sdc.heat.datatypes.structure.HeatStructureTree; +import org.openecomp.sdc.heat.services.tree.HeatTreeManager; +import org.junit.Assert; +import org.junit.Test; + +import java.io.IOException; +import java.util.*; + + +public class HeatTreeManagerTest extends TreeBaseTest { + + @Test + public void testHeatTreeManager() { + + INPUT_DIR = "/tree/valid_tree/input/"; + HeatTreeManager heatTreeManager = initHeatTreeManager(); + heatTreeManager.createTree(); + Map> errorMap = new HashMap<>(); + + List errorList = new ArrayList<>(); + errorList.add(new ErrorMessage(org.openecomp.sdc.datatypes.error.ErrorLevel.ERROR, "Missing Artifact")); + errorMap.put("missing-artifact", errorList); + errorList = new ArrayList<>(); + errorList.add(new ErrorMessage(org.openecomp.sdc.datatypes.error.ErrorLevel.WARNING, "Missing Nested File")); + errorMap.put("missingNested.yaml", errorList); + heatTreeManager.addErrors(errorMap); + HeatStructureTree tree = heatTreeManager.getTree(); + Assert.assertNotNull(tree); + } + + @Test + public void testHeatTreeManagerMissingManifest() { + + INPUT_DIR = "/tree/missing_manifest/input/"; + HeatTreeManager heatTreeManager = initHeatTreeManager(); + heatTreeManager.createTree(); + Map> errorMap = new HashMap<>(); + + List errorList = new ArrayList<>(); + errorList.add(new ErrorMessage(org.openecomp.sdc.datatypes.error.ErrorLevel.ERROR, "Missing Artifact")); + errorMap.put("missing-artifact", errorList); + errorList = new ArrayList<>(); + errorList.add(new ErrorMessage(org.openecomp.sdc.datatypes.error.ErrorLevel.WARNING, "Missing Nested File")); + errorMap.put("missingNested.yaml", errorList); + heatTreeManager.addErrors(errorMap); + HeatStructureTree tree = heatTreeManager.getTree(); + Assert.assertNotNull(tree); + Assert.assertEquals(tree.getHEAT(), null); + + } + + + @Test + public void testResourceGroupShowsAsNestedFileInTree() throws IOException { + INPUT_DIR = "/tree/nested_resource_group"; + HeatTreeManager heatTreeManager = initHeatTreeManager(); + heatTreeManager.createTree(); + HeatStructureTree tree = heatTreeManager.getTree(); + + Set heat = tree.getHEAT(); + Assert.assertNotNull(heat); + + HeatStructureTree addOnHeatSubTree = + HeatStructureTree.getHeatStructureTreeByName(heat, "addOn.yml"); + Assert.assertNotNull(addOnHeatSubTree); + + Set addOnNestedFiles = addOnHeatSubTree.getNested(); + Assert.assertNotNull(addOnNestedFiles); + + HeatStructureTree nestedFile = + HeatStructureTree.getHeatStructureTreeByName(addOnNestedFiles, "nested.yml"); + Assert.assertNotNull(nestedFile); + } + + + @Test + public void testVolumeNestedFileIsNotUnderVolumeSubTree() { + INPUT_DIR = "/tree/nested_volume"; + HeatTreeManager heatTreeManager = initHeatTreeManager(); + heatTreeManager.createTree(); + HeatStructureTree tree = heatTreeManager.getTree(); + + Set heat = tree.getHEAT(); + Set volume = tree.getVolume(); + Assert.assertNotNull(heat); + Assert.assertNull(volume); + + HeatStructureTree baseMobtSubTree = + HeatStructureTree.getHeatStructureTreeByName(heat, "base_mobt.yaml"); + Assert.assertNotNull(baseMobtSubTree); + + Set baseMobtNestedFiles = baseMobtSubTree.getNested(); + Assert.assertNotNull(baseMobtNestedFiles); + + HeatStructureTree nestedVolumeFile = HeatStructureTree + .getHeatStructureTreeByName(baseMobtNestedFiles, "hot_mobt_volume_attach_nested.yaml"); + Assert.assertNotNull(nestedVolumeFile); + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/tree/TreeBaseTest.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/tree/TreeBaseTest.java new file mode 100644 index 0000000000..df6cf54058 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/tree/TreeBaseTest.java @@ -0,0 +1,33 @@ +package org.openecomp.sdc.vendorsoftwareproduct.tree; + +import org.openecomp.sdc.heat.services.tree.HeatTreeManager; +import org.openecomp.core.utilities.file.FileUtils; + +import java.io.File; +import java.net.URISyntaxException; +import java.net.URL; + +public class TreeBaseTest { + + String INPUT_DIR; + + + HeatTreeManager initHeatTreeManager() { + HeatTreeManager heatTreeManager = new HeatTreeManager(); + + URL url = TreeBaseTest.class.getResource(INPUT_DIR); + + File inputDir = null; + try { + inputDir = new File(url.toURI()); + } catch (URISyntaxException e) { + e.printStackTrace(); + } + File[] files = inputDir.listFiles(); + for (File inputFile : files) { + heatTreeManager.addFile(inputFile.getName(), FileUtils.loadFileToInputStream( + INPUT_DIR.replace("/", File.separator) + File.separator + inputFile.getName())); + } + return heatTreeManager; + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/tree/UploadFileTest.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/tree/UploadFileTest.java new file mode 100644 index 0000000000..ee31ba4d70 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/tree/UploadFileTest.java @@ -0,0 +1,90 @@ +package org.openecomp.sdc.vendorsoftwareproduct.tree; + +import org.openecomp.sdc.vendorlicense.facade.VendorLicenseFacade; +import org.openecomp.sdc.vendorlicense.facade.VendorLicenseFacadeFactory; +import org.openecomp.sdc.vendorsoftwareproduct.VSPCommon; +import org.openecomp.sdc.vendorsoftwareproduct.VendorSoftwareProductManager; +import org.openecomp.sdc.vendorsoftwareproduct.dao.VendorSoftwareProductDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.VendorSoftwareProductDaoFactory; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.UploadDataEntity; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.VspDetails; +import org.openecomp.sdc.vendorsoftwareproduct.impl.VendorSoftwareProductManagerImpl; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.junit.BeforeClass; +import org.junit.Test; + +import java.io.*; +import java.net.URL; +import java.util.zip.ZipOutputStream; + +public class UploadFileTest { + + + public static final Version VERSION01 = new Version(0, 1); + private static final String USER1 = "vspTestUser1"; + public static String id001 = null; + public static String id002 = null; + public static Version activeVersion002 = null; + private static VendorSoftwareProductManager vendorSoftwareProductManager = + new VendorSoftwareProductManagerImpl(); + private static VendorSoftwareProductDao vendorSoftwareProductDao = + VendorSoftwareProductDaoFactory.getInstance().createInterface(); + private static VendorLicenseFacade vendorLicenseFacade = + VendorLicenseFacadeFactory.getInstance().createInterface(); + private static String vlm1Id; + + @BeforeClass + static public void init() { + + //testCreateVSP + vlm1Id = vendorLicenseFacade.createVendorLicenseModel( + VSPCommon.createVendorLicenseModel("vlmName", "vlm1Id desc", "icon1"), USER1).getId(); + VspDetails expectedVsp = VSPCommon + .createVspDetails(null, null, "VSP1", "Test-vsp", "vendorName", vlm1Id, "icon", "category", + "subCategory", "123", null); + + VspDetails createdVsp = vendorSoftwareProductManager.createNewVsp(expectedVsp, USER1); + id001 = createdVsp.getId(); + + VspDetails actualVsp = + vendorSoftwareProductDao.getVendorSoftwareProductInfo(new VspDetails(id001, VERSION01)); + expectedVsp.setId(id001); + expectedVsp.setVersion(VERSION01); + + + } + + @Test + public void testUploadFile() { + //vspActiveVersion = vendorSoftwareProductManager.checkout(id001, USER1); + vendorSoftwareProductManager.uploadFile(id001, getZipInputStream("/legalUpload"), USER1); + //testLegalUpload(id001, vspActiveVersion, getZipInputStream("/legalUpload"), USER1); + } + + + private void testLegalUpload(String vspId, Version version, InputStream upload, String user) { + vendorSoftwareProductManager.uploadFile(vspId, upload, user); + + UploadDataEntity uploadData = + vendorSoftwareProductDao.getUploadData(new UploadDataEntity(vspId, version)); + + } + + public InputStream getZipInputStream(String name) { + URL url = this.getClass().getResource(name); + File templateDir = new File(url.getFile()); + + ByteArrayOutputStream baos = new ByteArrayOutputStream(); + ZipOutputStream zos = new ZipOutputStream(baos); + + VSPCommon.zipDir(templateDir, "", zos, true); + try { + zos.close(); + } catch (IOException e) { + e.printStackTrace(); + } + return new ByteArrayInputStream(baos.toByteArray()); + } + + +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/upload/HeatCleanup/HeatCleanupOnNewUploadTest.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/upload/HeatCleanup/HeatCleanupOnNewUploadTest.java new file mode 100644 index 0000000000..f1bf5682e0 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/upload/HeatCleanup/HeatCleanupOnNewUploadTest.java @@ -0,0 +1,167 @@ +package org.openecomp.sdc.vendorsoftwareproduct.upload.HeatCleanup; + +import org.openecomp.sdc.datatypes.error.ErrorLevel; +import org.openecomp.sdc.vendorsoftwareproduct.VSPCommon; +import org.openecomp.sdc.vendorsoftwareproduct.VendorSoftwareProductConstants; +import org.openecomp.sdc.vendorsoftwareproduct.VendorSoftwareProductManager; +import org.openecomp.sdc.vendorsoftwareproduct.dao.VendorSoftwareProductDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.VendorSoftwareProductDaoFactory; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.UploadDataEntity; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.VspDetails; +import org.openecomp.sdc.vendorsoftwareproduct.impl.VendorSoftwareProductManagerImpl; +import org.openecomp.sdc.vendorsoftwareproduct.types.UploadFileResponse; +import org.openecomp.sdc.vendorsoftwareproduct.types.UploadFileStatus; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.core.model.dao.ServiceModelDao; +import org.openecomp.core.model.dao.ServiceModelDaoFactory; +import org.openecomp.core.util.UniqueValueUtil; +import org.openecomp.core.validation.types.MessageContainerUtil; +import org.apache.commons.collections4.CollectionUtils; +import org.apache.commons.collections4.MapUtils; +import org.testng.Assert; +import org.testng.annotations.BeforeClass; +import org.testng.annotations.Test; + +import java.io.IOException; +import java.io.InputStream; +import java.net.URL; +import java.util.List; + +public class HeatCleanupOnNewUploadTest { + private static final String USER1 = "vspTestUser1"; + + private static final VendorSoftwareProductManager vendorSoftwareProductManager = + new VendorSoftwareProductManagerImpl(); + private static final VendorSoftwareProductDao vendorSoftwareProductDao = + VendorSoftwareProductDaoFactory.getInstance().createInterface(); + private static final ServiceModelDao serviceModelDao = + ServiceModelDaoFactory.getInstance().createInterface(); + + private static String vspId = null; + private static Version vspActiveVersion = null; + + private static void validateUploadContentExistence(boolean exist) { + UploadDataEntity uploadDataEntity = + vendorSoftwareProductDao.getUploadData(new UploadDataEntity(vspId, vspActiveVersion)); + Assert.assertTrue((uploadDataEntity.getContentData() != null) == exist); + Assert.assertTrue((uploadDataEntity.getValidationData() != null) == exist); + Assert.assertTrue((uploadDataEntity.getPackageName() != null) == exist); + Assert.assertTrue((uploadDataEntity.getPackageVersion() != null) == exist); + Assert.assertTrue((serviceModelDao.getServiceModel(vspId, vspActiveVersion) != null) == exist); + } + + private static void validateCompositionDataExistence(boolean exist) { + Assert.assertTrue(CollectionUtils + .isNotEmpty(vendorSoftwareProductDao.listNetworks(vspId, vspActiveVersion)) == exist); + Assert.assertTrue(CollectionUtils + .isNotEmpty(vendorSoftwareProductDao.listComponents(vspId, vspActiveVersion)) == exist); + Assert.assertTrue(CollectionUtils + .isNotEmpty(vendorSoftwareProductDao.listNicsByVsp(vspId, vspActiveVersion)) == exist); + } + + private static InputStream getFileInputStream(String fileName) { + URL url = HeatCleanupOnNewUploadTest.class.getResource(fileName); + try { + return url.openStream(); + } catch (IOException e) { + e.printStackTrace(); + return null; + } + } + + @BeforeClass + private void init() { + UniqueValueUtil + .deleteUniqueValue(VendorSoftwareProductConstants.UniqueValues.VENDOR_SOFTWARE_PRODUCT_NAME, + "VSPTestEmpty"); + + VspDetails vspDetails = vendorSoftwareProductManager.createNewVsp(VSPCommon + .createVspDetails(null, null, "VSPTestEmpty", "Test-vsp-empty", "vendorName", "vlm1Id", + "icon", "category", "subCategory", "123", null), USER1); + vspId = vspDetails.getId(); + vspActiveVersion = vspDetails.getVersion(); + } + + @Test + public void testUploadWithComposition() { + InputStream zis = getFileInputStream("/vspmanager/zips/fullComposition.zip"); + + UploadFileResponse uploadFileResponse = + vendorSoftwareProductManager.uploadFile(vspId, zis, USER1); + + Assert.assertEquals(uploadFileResponse.getStatus(), UploadFileStatus.Success); + Assert.assertTrue(MapUtils.isEmpty( + MessageContainerUtil.getMessageByLevel(ErrorLevel.ERROR, uploadFileResponse.getErrors()))); + + validateUploadContentExistence(true); + validateCompositionDataExistence(true); + } + + @Test(dependsOnMethods = {"testUploadWithComposition"}) + public void testProccesesMIBsDeletionAfterNewUpload() { + InputStream zis1 = getFileInputStream("/vspmanager/zips/fullComposition.zip"); + InputStream zis2 = getFileInputStream("/vspmanager/zips/fullComposition.zip"); + InputStream mib = getFileInputStream("/vspmanager/zips/vDNS.zip"); + + vendorSoftwareProductManager.uploadFile(vspId, zis1, USER1); + List components = + (List) vendorSoftwareProductDao.listComponents(vspId, vspActiveVersion); + String componentId = components.get(0).getId(); + + vendorSoftwareProductManager + .uploadComponentMib(mib, "vDNS.zip", vspId, componentId, true, USER1); + vendorSoftwareProductManager + .createProcess(new org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity(vspId, vspActiveVersion, componentId, null), USER1); + + vendorSoftwareProductManager.uploadFile(vspId, zis2, USER1); + Assert.assertTrue( + vendorSoftwareProductManager.listMibFilenames(vspId, componentId, USER1).getSnmpTrap() == + null); + Assert.assertTrue(CollectionUtils + .isEmpty(vendorSoftwareProductDao.listProcesses(vspId, vspActiveVersion, componentId))); + } + + @Test(dependsOnMethods = {"testProccesesMIBsDeletionAfterNewUpload"}) + public void testInvalidStructureUploadAfterFullComposition() { + InputStream zis = getFileInputStream("/vspmanager/zips/withoutManifest.zip"); + + UploadFileResponse uploadFileResponse = + vendorSoftwareProductManager.uploadFile(vspId, zis, USER1); + Assert.assertEquals(uploadFileResponse.getStatus(), UploadFileStatus.Failure); + Assert.assertTrue(MapUtils.isNotEmpty( + MessageContainerUtil.getMessageByLevel(ErrorLevel.ERROR, uploadFileResponse.getErrors()))); + + validateUploadContentExistence(true); + validateCompositionDataExistence(true); + } + + @Test(dependsOnMethods = {"testInvalidStructureUploadAfterFullComposition"}) + public void testInvalidUploadAfterFullComposition() { + InputStream zis = getFileInputStream("/vspmanager/zips/missingYml.zip"); + + UploadFileResponse uploadFileResponse = + vendorSoftwareProductManager.uploadFile(vspId, zis, USER1); + Assert.assertEquals(uploadFileResponse.getStatus(), UploadFileStatus.Success); + Assert.assertTrue(MapUtils.isNotEmpty( + MessageContainerUtil.getMessageByLevel(ErrorLevel.ERROR, uploadFileResponse.getErrors()))); + + validateUploadContentExistence(true); + validateCompositionDataExistence(false); + } + + @Test(dependsOnMethods = {"testInvalidUploadAfterFullComposition"}) + public void testEmptyCompositionUploadAfterFullComposition() throws IOException { + testUploadWithComposition(); + + InputStream zis = getFileInputStream("/vspmanager/zips/emptyComposition.zip"); + UploadFileResponse uploadFileResponse = + vendorSoftwareProductManager.uploadFile(vspId, zis, USER1); + Assert.assertEquals(uploadFileResponse.getStatus(), UploadFileStatus.Success); + Assert.assertTrue(MapUtils.isEmpty( + MessageContainerUtil.getMessageByLevel(ErrorLevel.ERROR, uploadFileResponse.getErrors()))); + + validateUploadContentExistence(true); + validateCompositionDataExistence(false); + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/upload/validation/UploadFileValidationTest.java b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/upload/validation/UploadFileValidationTest.java new file mode 100644 index 0000000000..3ec8cb2e40 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/upload/validation/UploadFileValidationTest.java @@ -0,0 +1,199 @@ +package org.openecomp.sdc.vendorsoftwareproduct.upload.validation; + +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.common.utils.AsdcCommon; +import org.openecomp.sdc.datatypes.error.ErrorMessage; + +import org.openecomp.sdc.vendorsoftwareproduct.VendorSoftwareProductManager; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.VspDetails; +import org.openecomp.sdc.vendorsoftwareproduct.impl.VendorSoftwareProductManagerImpl; +import org.openecomp.sdc.vendorsoftwareproduct.types.UploadFileResponse; +import org.openecomp.core.util.UniqueValueUtil; +import org.openecomp.core.utilities.CommonMethods; +import org.openecomp.core.validation.errors.Messages; +import org.openecomp.core.validation.types.MessageContainerUtil; +import org.apache.commons.collections4.MapUtils; +import org.testng.Assert; +import org.testng.annotations.BeforeTest; +import org.testng.annotations.Test; + +import java.io.*; +import java.net.URL; +import java.util.List; +import java.util.Map; + +public class UploadFileValidationTest { + + private static final String USER1 = "UploadFileValidationTest"; + private static final String EMPTY_ZIP_FILE = "/validation/zips/emptyZip.zip"; + private static final String MISSING_MANIFEST_IN_ZIP_FILE = + "/validation/zips/missingManifestInZip.zip"; + private static final String ZIP_FILE_WITH_FOLDER = "/validation/zips/zipFileWithFolder.zip"; + private static VendorSoftwareProductManager vendorSoftwareProductManager = + new VendorSoftwareProductManagerImpl(); + private static String vspId; + + public static org.openecomp.sdc.vendorlicense.dao.types.VendorLicenseModelEntity createVendorLicenseModel(String name, String desc, + String icon) { + org.openecomp.sdc.vendorlicense.dao.types.VendorLicenseModelEntity + vendorLicenseModel = new org.openecomp.sdc.vendorlicense.dao.types.VendorLicenseModelEntity(); + vendorLicenseModel.setVendorName(name); + vendorLicenseModel.setDescription(desc); + vendorLicenseModel.setIconRef(icon); + return vendorLicenseModel; + } + + @BeforeTest + private void init() { + VspDetails vspDetails = new VspDetails(); + vspDetails.setVendorName("vspName_" + CommonMethods.nextUuId()); + vspId = vendorSoftwareProductManager.createNewVsp(vspDetails, USER1).getId(); + + UniqueValueUtil + .deleteUniqueValue(org.openecomp.sdc.vendorsoftwareproduct.VendorSoftwareProductConstants.UniqueValues.VENDOR_SOFTWARE_PRODUCT_NAME, + "VSP_syb_upload_various"); + UniqueValueUtil + .deleteUniqueValue(org.openecomp.sdc.vendorsoftwareproduct.VendorSoftwareProductConstants.UniqueValues.VENDOR_SOFTWARE_PRODUCT_NAME, + "vsp_syb_upload_no_error"); + UniqueValueUtil + .deleteUniqueValue(org.openecomp.sdc.vendorsoftwareproduct.VendorSoftwareProductConstants.UniqueValues.VENDOR_SOFTWARE_PRODUCT_NAME, + "vsp_syb"); + } + + @Test + public void testUploadZipNull() { + UploadFileResponse response = vendorSoftwareProductManager.uploadFile(vspId, null, USER1); + Assert.assertEquals(response.getErrors().size(), 1); + Assert.assertTrue(response.getErrors().containsKey(AsdcCommon.UPLOAD_FILE)); + Assert.assertEquals(response.getErrors().get(AsdcCommon.UPLOAD_FILE).get(0).getMessage(), + Messages.NO_ZIP_FILE_WAS_UPLOADED_OR_ZIP_NOT_EXIST.getErrorMessage()); + } + + @Test(dependsOnMethods = "testUploadZipNull") + public void testUploadEmptyFile() { + UploadFileResponse response = vendorSoftwareProductManager + .uploadFile(vspId, new ByteArrayInputStream("".getBytes()), USER1); + Assert.assertEquals(response.getErrors().size(), 1); + Assert.assertTrue(response.getErrors().containsKey(AsdcCommon.UPLOAD_FILE)); + Assert.assertEquals(response.getErrors().get(AsdcCommon.UPLOAD_FILE).get(0).getMessage(), + Messages.NO_ZIP_FILE_WAS_UPLOADED_OR_ZIP_NOT_EXIST.getErrorMessage()); + } + + @Test(dependsOnMethods = "testUploadEmptyFile") + public void testUploadEmptyZip() { + UploadFileResponse response = + vendorSoftwareProductManager.uploadFile(vspId, getFileInputStream(EMPTY_ZIP_FILE), USER1); + Assert.assertEquals(response.getErrors().size(), 1); + Assert.assertTrue(response.getErrors().containsKey(AsdcCommon.UPLOAD_FILE)); + Assert.assertEquals(response.getErrors().get(AsdcCommon.UPLOAD_FILE).get(0).getMessage(), + Messages.INVALID_ZIP_FILE.getErrorMessage()); + } + + @Test(dependsOnMethods = "testUploadEmptyZip") + public void testUploadMissingManifestInZip() { + UploadFileResponse response = vendorSoftwareProductManager + .uploadFile(vspId, getFileInputStream(MISSING_MANIFEST_IN_ZIP_FILE), USER1); + Assert.assertEquals(response.getErrors().size(), 1); + Assert.assertTrue(response.getErrors().containsKey(AsdcCommon.MANIFEST_NAME)); + Assert.assertEquals(response.getErrors().get(AsdcCommon.MANIFEST_NAME).get(0).getMessage(), + Messages.MANIFEST_NOT_EXIST.getErrorMessage()); + } + + @Test(dependsOnMethods = "testUploadMissingManifestInZip") + public void testUploadZipWithFolder() { + UploadFileResponse response = vendorSoftwareProductManager + .uploadFile(vspId, getFileInputStream(ZIP_FILE_WITH_FOLDER), USER1); + Assert.assertEquals(response.getErrors().size(), 1); + Assert.assertTrue(response.getErrors().containsKey(AsdcCommon.UPLOAD_FILE)); + Assert.assertEquals(response.getErrors().get(AsdcCommon.UPLOAD_FILE).get(0).getMessage(), + Messages.ZIP_SHOULD_NOT_CONTAIN_FOLDERS.getErrorMessage()); + } + + @Test(dependsOnMethods = "testUploadZipWithFolder") + public void testUploadVariousZips() { + + File[] files = getFileList("/validation/zips/various"); + InputStream is; + for (File file : files) { + if (file.isFile()) { + UploadFileResponse response = null; + try { + + is = new FileInputStream(file); + response = vendorSoftwareProductManager.uploadFile(vspId, is, USER1); + + } catch (FileNotFoundException e) { + throw new RuntimeException(e); + } catch (CoreException ce) { + throw new RuntimeException("failed upload:" + file.getName(), ce); + } catch (RuntimeException re) { + + throw new RuntimeException("failed upload:" + file.getName(), re); + } + System.out.println("zip:" + file.getName() + " Errors:" + calculateNumberOfMessages( + MessageContainerUtil.getMessageByLevel(org.openecomp.sdc.datatypes.error.ErrorLevel.ERROR, response.getErrors())) + + " Warnings:" + calculateNumberOfMessages( + MessageContainerUtil.getMessageByLevel(org.openecomp.sdc.datatypes.error.ErrorLevel.WARNING, response.getErrors()))); + } + } + } + + @Test(dependsOnMethods = "testUploadVariousZips") + public void testUploadNoErrorVariousZips() { + + + File[] files = getFileList("/validation/zips/various/noError"); + InputStream is; + for (File file : files) { + if (file.isFile()) { + try { + is = new FileInputStream(file); + UploadFileResponse response = vendorSoftwareProductManager.uploadFile(vspId, is, USER1); + Map> errors = response.getErrors(); + Assert.assertTrue( + MapUtils.isEmpty(MessageContainerUtil.getMessageByLevel( + org.openecomp.sdc.datatypes.error.ErrorLevel.ERROR, errors))); + + + } catch (FileNotFoundException e) { + throw new RuntimeException(e); + } catch (CoreException ce) { + Assert.fail("failed upload:" + file.getName() + " exception:" + ce.getMessage()); + + } catch (RuntimeException re) { + Assert.fail("failed upload:" + file.getName() + " exception:" + re.getMessage()); + } + } + } + } + + private InputStream getFileInputStream(String fileName) { + URL url = this.getClass().getResource(fileName); + try { + return url.openStream(); + } catch (IOException e) { + e.printStackTrace(); + return null; + } + } + + private File[] getFileList(String dir) { + URL url = UploadFileValidationTest.class.getResource(dir); + + String path = url.getPath(); + File pathFile = new File(path); + return pathFile.listFiles(); + + + } + + private int calculateNumberOfMessages(Map> messages) { + int sum = 0; + for (List errors : messages.values()) { + sum += errors.size(); + } + return sum; + } + + +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/emptyComposition/MANIFEST.json b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/emptyComposition/MANIFEST.json new file mode 100644 index 0000000000..af1e3fbbae --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/emptyComposition/MANIFEST.json @@ -0,0 +1,11 @@ +{ + "name": "vEP_JSA_Net", + "description": "Version 2.0 02-09-2016 (Authors: John Doe, user PROD)", + "version": "2013-05-23", + "data": [ + { + "file": "ep-jsa_net.yaml", + "type": "HEAT" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/emptyComposition/ep-jsa_net.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/emptyComposition/ep-jsa_net.yaml new file mode 100644 index 0000000000..f0773b7611 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/emptyComposition/ep-jsa_net.yaml @@ -0,0 +1,21 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + snapshot02: + type: string + description: prop + network_name: + type: string + description: prop + +resources: + + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_param: network_name} + - config: { get_param: snapshot02} \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/componentsWithPort/ComponentsWithPortST.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/componentsWithPort/ComponentsWithPortST.yaml new file mode 100644 index 0000000000..1446e98d91 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/componentsWithPort/ComponentsWithPortST.yaml @@ -0,0 +1,428 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.pcrf_psm: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.pcm: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + Internal2_name: + label: Internal2_name + hidden: false + immutable: false + type: string + description: Internal2_name + Internal1_shared: + label: Internal1_shared + hidden: false + immutable: false + type: string + description: Internal1_shared + FSB1_volume_name: + label: FSB1_volume + hidden: false + immutable: false + type: string + description: FSB1_volume_1 + jsa_cidr: + label: jsa_cidr + hidden: false + immutable: false + type: string + description: jsa_cidr + default: 107.243.7.128/26 + availabilityzone_name: + label: availabilityzone_name + hidden: false + immutable: false + type: string + description: availabilityzone_name + fsb1-name: + label: FSB1_name + hidden: false + immutable: false + type: string + description: FSB1_name + pcm_image_name: + label: pcm_image_name + hidden: false + immutable: false + type: string + description: pcm_image_name + Internal2_external: + label: Internal2_external + hidden: false + immutable: false + type: string + description: Internal2_external + Internal2_forwarding_mode: + label: Internal2_forwarding_mode + hidden: false + immutable: false + type: string + description: Internal2_forwarding_mode + pcrf_psm_flavor_name: + label: pcrf_psm_flavor_name + hidden: false + immutable: false + type: string + description: pcrf_psm_flavor_name + pcrf_psm_image_name: + label: pcrf_psm_image_name + hidden: false + immutable: false + type: string + description: pcrf_psm_image_name + FSB_1_image: + label: MME_FSB1 + hidden: false + immutable: false + type: string + description: MME_FSB1_15B-CP04-r5a01 + volume_size: + label: volume size + hidden: false + immutable: false + type: float + description: my volume size 320GB + fsb1-Internal1-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + Internal2_shared: + label: Internal2_shared + hidden: false + immutable: false + type: string + description: Internal2_shared + pcm_server_name: + label: pcm_server_name + hidden: false + immutable: false + type: string + description: pcm_server_name + Internal1_net_name: + label: Internal1_net_name + hidden: false + immutable: false + type: string + description: Internal1_net_name + oam_net_name: + label: oam_net_name + hidden: false + immutable: false + type: string + description: oam_net_name + fsb1-flavor: + label: FSB1_flavor + hidden: false + immutable: false + type: string + description: FSB1_flavor + fsb1-Internal2-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + volume_type: + label: volume type + hidden: false + immutable: false + type: string + description: volume type Gold + fsb1-zone: + label: FSB1_zone + hidden: false + immutable: false + type: string + description: FSB1_zone + fsb_zone: + label: FSB1_zone + hidden: false + immutable: false + type: string + description: FSB1_zone + security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + jsa_net_name: + label: jsa_net_name + hidden: false + immutable: false + type: string + description: jsa_net_name + default: jsa_log_net_0 + pcrf_psm_server_name: + label: pcrf_psm_server_name + hidden: false + immutable: false + type: string + description: pcrf_psm_server_name + pcm_flavor_name: + label: pcm_flavor_name + hidden: false + immutable: false + type: string + description: pcm_flavor_name + oam_net_id: + label: oam_net_id + hidden: false + immutable: false + type: string + description: oam_net_id + fsb2-Internal1-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + Internal1_forwarding_mode: + label: Internal1_forwarding_mode + hidden: false + immutable: false + type: string + description: Internal1_forwarding_mode + pcrf_cps_net_name: + label: pcrf_cps_net_name + hidden: false + immutable: false + type: string + description: pcrf_cps_net_name + cps_net_name: + label: cps_net_name + hidden: false + immutable: false + type: string + description: cps_net_name + pcrf_security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + Internal1_external: + label: Internal1_external + hidden: false + immutable: false + type: string + description: Internal1_external + node_templates: + pcm_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: oam_net_ip + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_pcm + relationship: tosca.relationships.network.BindsTo + FSB1_Internal2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: fsb1-Internal2-mac + network: Internal2-net + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: FSB2 + relationship: tosca.relationships.network.BindsTo + FSB1_Internal1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: fsb1-Internal1-mac + network: Internal1-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal1-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: FSB1 + relationship: tosca.relationships.network.BindsTo + FSB1_OAM: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + fixed_ips: + - ip_address: + get_input: fsb1-oam-ip + network: + get_input: oam_net_id + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: FSB1 + relationship: tosca.relationships.network.BindsTo + psm01_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: pcrf_security_group_name + fixed_ips: + - ip_address: + get_input: pcrf_cps_net_ip + network: + get_input: pcrf_cps_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: pcrf_server_psm + relationship: tosca.relationships.network.BindsTo + pcm_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: cps_net_ip + network: + get_input: cps_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_pcm + relationship: tosca.relationships.network.BindsTo + server_pcm: + type: org.openecomp.resource.vfc.nodes.heat.pcm + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + user_data: UNSUPPORTED_RESOURCE_server_init + pcrf_server_psm: + type: org.openecomp.resource.vfc.nodes.heat.pcrf_psm + properties: + flavor: + get_input: pcrf_psm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcrf_psm_image_name + config_drive: 'True' + metadata: + vnf_id: + get_input: pcrf_vnf_id + user_data_format: RAW + name: + get_input: pcrf_psm_server_name + user_data: UNSUPPORTED_RESOURCE_pcrf_server_init + FSB2: + type: org.openecomp.resource.vfc.nodes.heat.nova.Server + properties: + flavor: + get_input: fsb1-flavor + availability_zone: + get_input: fsb_zone + name: + get_input: fsb1-name + FSB1: + type: org.openecomp.resource.vfc.nodes.heat.nova.Server + properties: + flavor: + get_input: fsb1-flavor + availability_zone: + get_input: fsb_zone + metadata: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: '0644' + content: + str_replace: + template: + get_artifact: + - SELF + - nimbus-ethernet + params: + $dev: eth0 + $netmask: + get_input: cps_net_mask + $ip: + get_input: cps_net_ip + - path: /etc/sysconfig/network-scripts/ifcfg-eth1 + permissions: '0644' + content: + str_replace: + template: + get_artifact: + - SELF + - nimbus-ethernet-gw + params: + $dev: eth1 + $netmask: + get_input: oam_net_mask + $gateway: + get_input: oam_net_gw + $ip: + get_input: oam_net_ip + name: + get_input: fsb1-name + artifacts: + nimbus-ethernet-gw: + type: tosca.artifacts.Deployment + file: ../Artifacts/nimbus-ethernet-gw + nimbus-ethernet: + type: tosca.artifacts.Deployment + file: ../Artifacts/nimbus-ethernet + groups: + ep-jsa_net: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/ep-jsa_net.yaml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - pcm_port_1 + - FSB1_Internal2 + - FSB1_Internal1 + - FSB1_OAM + - psm01_port_0 + - pcm_port_0 + - server_pcm + - pcrf_server_psm + - FSB2 + - FSB1 \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/fullComposition/MainServiceTemplate.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/fullComposition/MainServiceTemplate.yaml new file mode 100644 index 0000000000..62865b3e78 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/fullComposition/MainServiceTemplate.yaml @@ -0,0 +1,473 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.pcrf_psm: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.pcm: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + Internal2_name: + label: Internal2_name + hidden: false + immutable: false + type: string + description: Internal2_name + Internal1_shared: + label: Internal1_shared + hidden: false + immutable: false + type: string + description: Internal1_shared + FSB1_volume_name: + label: FSB1_volume + hidden: false + immutable: false + type: string + description: FSB1_volume_1 + jsa_cidr: + label: jsa_cidr + hidden: false + immutable: false + type: string + description: jsa_cidr + default: 107.243.7.128/26 + availabilityzone_name: + label: availabilityzone_name + hidden: false + immutable: false + type: string + description: availabilityzone_name + fsb1-name: + label: FSB1_name + hidden: false + immutable: false + type: string + description: FSB1_name + pcm_image_name: + label: pcm_image_name + hidden: false + immutable: false + type: string + description: pcm_image_name + Internal2_external: + label: Internal2_external + hidden: false + immutable: false + type: string + description: Internal2_external + Internal2_forwarding_mode: + label: Internal2_forwarding_mode + hidden: false + immutable: false + type: string + description: Internal2_forwarding_mode + pcrf_psm_flavor_name: + label: pcrf_psm_flavor_name + hidden: false + immutable: false + type: string + description: pcrf_psm_flavor_name + pcrf_psm_image_name: + label: pcrf_psm_image_name + hidden: false + immutable: false + type: string + description: pcrf_psm_image_name + FSB_1_image: + label: MME_FSB1 + hidden: false + immutable: false + type: string + description: MME_FSB1_15B-CP04-r5a01 + volume_size: + label: volume size + hidden: false + immutable: false + type: float + description: my volume size 320GB + fsb1-Internal1-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + Internal2_shared: + label: Internal2_shared + hidden: false + immutable: false + type: string + description: Internal2_shared + pcm_server_name: + label: pcm_server_name + hidden: false + immutable: false + type: string + description: pcm_server_name + Internal1_net_name: + label: Internal1_net_name + hidden: false + immutable: false + type: string + description: Internal1_net_name + oam_net_name: + label: oam_net_name + hidden: false + immutable: false + type: string + description: oam_net_name + fsb1-flavor: + label: FSB1_flavor + hidden: false + immutable: false + type: string + description: FSB1_flavor + fsb1-Internal2-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + volume_type: + label: volume type + hidden: false + immutable: false + type: string + description: volume type Gold + fsb1-zone: + label: FSB1_zone + hidden: false + immutable: false + type: string + description: FSB1_zone + fsb_zone: + label: FSB1_zone + hidden: false + immutable: false + type: string + description: FSB1_zone + security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + jsa_net_name: + label: jsa_net_name + hidden: false + immutable: false + type: string + description: jsa_net_name + default: jsa_log_net_0 + pcrf_psm_server_name: + label: pcrf_psm_server_name + hidden: false + immutable: false + type: string + description: pcrf_psm_server_name + pcm_flavor_name: + label: pcm_flavor_name + hidden: false + immutable: false + type: string + description: pcm_flavor_name + oam_net_id: + label: oam_net_id + hidden: false + immutable: false + type: string + description: oam_net_id + fsb2-Internal1-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + Internal1_forwarding_mode: + label: Internal1_forwarding_mode + hidden: false + immutable: false + type: string + description: Internal1_forwarding_mode + pcrf_cps_net_name: + label: pcrf_cps_net_name + hidden: false + immutable: false + type: string + description: pcrf_cps_net_name + cps_net_name: + label: cps_net_name + hidden: false + immutable: false + type: string + description: cps_net_name + pcrf_security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + Internal1_external: + label: Internal1_external + hidden: false + immutable: false + type: string + description: Internal1_external + node_templates: + pcm_vol_02: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + image: + get_input: FSB_1_image + volume_type: + get_input: volume_type + size: '(get_input : volume_size) * 1024' + read_only: true + name: + get_input: FSB1_volume_name + Internal2-net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + shared: + get_input: Internal2_shared + forwarding_mode: + get_input: Internal2_forwarding_mode + external: + get_input: Internal2_external + network_name: + get_input: Internal2_name + pcm_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: oam_net_ip + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_pcm + relationship: tosca.relationships.network.BindsTo + server_VolumeTest_snapshot02: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + snapshot_id: + get_input: snapshot02 + FSB1_Internal2_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: fsb1-Internal2-mac + network: Internal2-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal2-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: FSB1 + relationship: tosca.relationships.network.BindsTo + server_VolumeTest_snapshot01: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + snapshot_id: + get_input: snapshot01 + FSB1_Internal1_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: fsb1-Internal1-mac + network: Internal1-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal1-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: FSB1 + relationship: tosca.relationships.network.BindsTo + FSB1_OAM_Port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + fixed_ips: + - ip_address: + get_input: fsb1-oam-ip + network: + get_input: oam_net_id + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: FSB1 + relationship: tosca.relationships.network.BindsTo + psm01_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: pcrf_security_group_name + fixed_ips: + - ip_address: + get_input: pcrf_cps_net_ip + network: + get_input: pcrf_cps_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: pcrf_server_psm + relationship: tosca.relationships.network.BindsTo + pcm_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: cps_net_ip + network: + get_input: cps_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_pcm + relationship: tosca.relationships.network.BindsTo + network: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + network_name: + get_input: Internal1_net_name + server_pcm: + type: org.openecomp.resource.vfc.nodes.heat.pcm + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + user_data: UNSUPPORTED_RESOURCE_server_init + Internal1-net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + shared: + get_input: Internal1_shared + forwarding_mode: + get_input: Internal1_forwarding_mode + external: + get_input: Internal1_external + network_name: + get_input: Internal1_net_name + pcrf_server_psm: + type: org.openecomp.resource.vfc.nodes.heat.pcrf_psm + properties: + flavor: + get_input: pcrf_psm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcrf_psm_image_name + config_drive: 'True' + metadata: + vnf_id: + get_input: pcrf_vnf_id + user_data_format: RAW + name: + get_input: pcrf_psm_server_name + user_data: UNSUPPORTED_RESOURCE_pcrf_server_init + FSB1: + type: org.openecomp.resource.vfc.nodes.heat.nova.Server + properties: + flavor: + get_input: fsb1-flavor + availability_zone: + get_input: fsb_zone + metadata: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: '0644' + content: + str_replace: + template: + get_artifact: + - SELF + - nimbus-ethernet + params: + $dev: eth0 + $netmask: + get_input: cps_net_mask + $ip: + get_input: cps_net_ip + - path: /etc/sysconfig/network-scripts/ifcfg-eth1 + permissions: '0644' + content: + str_replace: + template: + get_artifact: + - SELF + - nimbus-ethernet-gw + params: + $dev: eth1 + $netmask: + get_input: oam_net_mask + $gateway: + get_input: oam_net_gw + $ip: + get_input: oam_net_ip + name: + get_input: fsb1-name + artifacts: + nimbus-ethernet-gw: + type: tosca.artifacts.Deployment + file: ../Artifacts/nimbus-ethernet-gw + nimbus-ethernet: + type: tosca.artifacts.Deployment + file: ../Artifacts/nimbus-ethernet + groups: + ep-jsa_net: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/ep-jsa_net.yaml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - pcm_vol_02 + - Internal2-net + - pcm_port_1 + - FSB1_Internal2_port + - FSB1_Internal1_port + - FSB1_OAM_Port + - psm01_port_0 + - pcm_port_0 + - server_pcm + - Internal1-net + - pcrf_server_psm + - FSB1 \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/networks/MainServiceTemplate.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/networks/MainServiceTemplate.yaml new file mode 100644 index 0000000000..e5c68b61d0 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/networks/MainServiceTemplate.yaml @@ -0,0 +1,829 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml +topology_template: + inputs: + Internal2_name: + hidden: false + immutable: false + type: string + default: Internal2-subnet + vlc2-Internal2-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to vlc2-Internal2 + default: 00:81:37:0E:02:12 + epc-sctp-a-net-rt: + hidden: false + immutable: false + type: string + description: epc-sctp-a route target + default: 13979:105717 + epc-sctp-b-net-rt: + hidden: false + immutable: false + type: string + description: epc-sctp-b route target + default: 13979:105719 + gpb-flavor: + hidden: false + immutable: false + type: string + description: Flavor to use for servers gpb + default: m4.xlarge4 + Internal1_cidr: + hidden: false + immutable: false + type: string + default: 169.253.0.0/17 + epc-sctp-a-pool-start: + hidden: false + immutable: false + type: string + description: epc-sctp-a-net network ip pool start IP address + default: 107.243.37.3 + Internal2_subnet_name: + hidden: false + immutable: false + type: string + default: vmme_int_int_sub_2 + Internal1_subnet_name: + hidden: false + immutable: false + type: string + default: vmme_int_int_sub_1 + gpb1-Internal1-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to gpb1-Internal1 + default: 00:80:37:0E:01:22 + gpb1-Internal1-ip: + hidden: false + immutable: false + type: string + default: 169.254.0.101 + FSB_1_image: + hidden: false + immutable: false + type: string + description: image name + fsb1-Internal2-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to fsb1-Internal2 + default: 00:81:37:0E:0B:12 + ncb_zone: + hidden: false + immutable: false + type: string + description: cluster for spawnning ncb instances + default: nova + Internal2_net_name: + hidden: false + immutable: false + type: string + default: vmme_int_int_2 + epc-sctp-a-pool-end: + hidden: false + immutable: false + type: string + description: epc-sctp-a-net network ip pool end IP address + default: 107.243.37.30 + Internal1_name: + hidden: false + immutable: false + type: string + default: Internal1-subnet + gpb2-name: + hidden: false + immutable: false + type: string + description: Name of gpb2 + default: ZRDM1MMEX33GPB002 + fsb2-Internal1-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to fsb2-Internal1 + default: 00:80:37:0E:0D:12 + fsb2-name: + hidden: false + immutable: false + type: string + description: Name of fsb1 + default: ZRDM1MMEX33FSB002 + static_prefix_sctp_b_1: + hidden: false + immutable: false + type: string + description: Static Prefix + default: 107.239.40.64/30 + fsb2-oam-ip: + hidden: false + immutable: false + type: string + default: 107.250.172.222 + fsb2-flavor: + hidden: false + immutable: false + type: string + description: Flavor to use for servers fsb2 + default: m4.xlarge4 + fsb2-Internal2-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to fsb2-Internal2 + default: 00:81:37:0E:0D:12 + ncb2-Internal1-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to ncb2-Internal1 + default: 00:80:37:0E:0F:12 + ncb2-name: + hidden: false + immutable: false + type: string + description: Name of ncb2 + default: ZRDM1MMEX33NCB002 + epc-sctp-b-pool-end: + hidden: false + immutable: false + type: string + description: epc-sctp-b-net network ip pool end IP address + default: 107.243.37.62 + vlc1-gtp-ip: + hidden: false + immutable: false + type: string + default: 107.243.37.67 + epc-sctp-b-pool-start: + hidden: false + immutable: false + type: string + description: epc-sctp-b-net network ip pool start IP address + default: 107.243.37.35 + my_instance: + hidden: false + immutable: false + type: string + description: instance + Internal2_shared: + hidden: false + immutable: false + type: string + default: 'False' + Internal1_net_name: + hidden: false + immutable: false + type: string + default: vmme_int_int_1 + vlc2-name: + hidden: false + immutable: false + type: string + description: Name of vlc2 + default: ZRDM1MMEX33VLC002 + Internal2_ipam_name: + hidden: false + immutable: false + type: string + default: vmme_ipam_int2 + vlc1-sctp-b-ip: + hidden: false + immutable: false + type: string + default: 107.243.37.35 + Internal1_net_pool_end: + hidden: false + immutable: false + type: string + default: 169.253.0.254 + Internal1_default_gateway: + hidden: false + immutable: false + type: string + default: 169.253.0.3 + ncb1-Internal1-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to ncb1-Internal1 + default: 00:80:37:0E:09:12 + epc-gtp-net-name: + hidden: false + immutable: false + type: string + description: gtp net name + default: EPC-GTP + vlc1-Internal1-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to vlc1-Internal1 + default: 00:80:37:0E:01:12 + gpb2-Internal1-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to gpb2-Internal1 + default: 00:80:37:0E:02:22 + epc-gtp-net-cidr: + hidden: false + immutable: false + type: string + description: gtp stubnet + default: 107.243.37.64/27 + oam_net_id: + hidden: false + immutable: false + type: string + description: uuid of oam network + default: 47bf4cca-0961-422f-bcd6-d5a4fbb1a351 + vlc_zone: + hidden: false + immutable: false + type: string + description: cluster for spawnning vlc instances + default: nova + vlc2-Internal1-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to vlc2-Internal1 + default: 00:80:37:0E:02:12 + epc-sctp-a-net-cidr: + hidden: false + immutable: false + type: string + description: epc-sctp-a subnet + default: 107.243.37.0/27 + Internal1_forwarding_mode: + hidden: false + immutable: false + type: string + default: l2 + Internal2_dhcp: + hidden: false + immutable: false + type: string + default: 'False' + Internal4_dhcp: + hidden: false + immutable: false + type: string + fsb1-oam-ip: + hidden: false + immutable: false + type: string + default: 107.250.172.221 + FSB_2_image: + hidden: false + immutable: false + type: string + description: image name + vlc1-oam-ip: + hidden: false + immutable: false + type: string + default: 107.250.172.227 + epc-sctp-a-net-name: + hidden: false + immutable: false + type: string + description: epc-sctp-a net name + default: EPC-SCTP-A + vlc2-oam-ip: + hidden: false + immutable: false + type: string + default: 107.250.172.228 + Internal2_net_pool_start: + hidden: false + immutable: false + type: string + default: 169.255.0.100 + FSB1_volume_name: + hidden: false + immutable: false + type: string + description: volume name + vlc1-sctp-a-ip: + hidden: false + immutable: false + type: string + default: 107.243.37.3 + Internal1_ipam_name: + hidden: false + immutable: false + type: string + default: vmme_ipam_int1 + Internal1_dhcp: + hidden: false + immutable: false + type: string + default: 'False' + Internal3_dhcp: + hidden: false + immutable: false + type: string + default: 'True' + Internal2_external: + hidden: false + immutable: false + type: string + default: 'False' + Internal2_forwarding_mode: + hidden: false + immutable: false + type: string + default: l2 + vlc1-name: + hidden: false + immutable: false + type: string + description: Name of vlc1 + default: ZRDM1MMEX33VLC002 + vlc-flavor: + hidden: false + immutable: false + type: string + description: Flavor to use for servers vlc + default: m4.xlarge4 + epc-gtp-net-rt: + hidden: false + immutable: false + type: string + description: gtp route target + default: 13979:105715 + gpb_zone: + hidden: false + immutable: false + type: string + description: cluster for spawnning gpb instances + default: nova + Internal1-net: + hidden: false + immutable: false + type: string + description: net + gpb1-Internal2-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to gpb1-Internal2 + default: 00:81:37:0E:01:22 + fsb1-Internal1-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to fsb1-Internal1 + default: 00:80:37:0E:0B:12 + FSB2_volume_name: + hidden: false + immutable: false + type: string + description: volume name + VMME_FSB2_boot_volume: + hidden: false + immutable: false + type: string + default: 089a0d11-4b15-4370-8343-3f90907b1221 + fsb_zone: + hidden: false + immutable: false + type: string + description: cluster for spawnning fsb instances + default: nova + VMME_FSB1_boot_volume: + hidden: false + immutable: false + type: string + default: 8248e794-6173-4b49-b9c3-8219b0b56f4e + Internal2_default_gateway: + hidden: false + immutable: false + type: string + default: 169.255.0.3 + Internal1_external: + hidden: false + immutable: false + type: string + default: 'False' + vlc2-sctp-a-ip: + hidden: false + immutable: false + type: string + default: 107.243.37.4 + ncb-flavor: + hidden: false + immutable: false + type: string + description: Flavor to use for servers ncb + default: m4.xlarge4 + Internal1_shared: + hidden: false + immutable: false + type: string + default: 'False' + fsb1-name: + hidden: false + immutable: false + type: string + description: Name of fsb1 + default: ZRDM1MMEX33FSB001 + static_prefix_gtp_1: + hidden: false + immutable: false + type: string + description: Static Prefix + default: 107.239.40.96/30 + epc-sctp-b-net-gateway: + hidden: false + immutable: false + type: string + description: epc-sctp-b-net network gateway + default: 107.243.37.33 + epc-sctp-b-net-cidr: + hidden: false + immutable: false + type: string + description: epc-sctp-b subnet + default: 107.243.37.32/24 + epc-gtp-pool-end: + hidden: false + immutable: false + type: string + description: gtp network ip pool end IP address + default: 107.243.37.94 + epc-sctp-a-net-gateway: + hidden: false + immutable: false + type: string + description: epc-sctp-a-net network gateway + default: 107.243.37.1 + vlc2-gtp-ip: + hidden: false + immutable: false + type: string + default: 107.243.37.68 + vlc2-sctp-b-ip: + hidden: false + immutable: false + type: string + default: 107.243.37.36 + Internal1_net_pool_start: + hidden: false + immutable: false + type: string + default: 169.253.0.100 + volume_size: + hidden: false + immutable: false + type: string + description: volume + fsb2-image: + hidden: false + immutable: false + type: string + description: Name of image to use for server fsb2 + default: MME_FSB2_15B-CP04-r5a01 + ncb2-Internal2-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to ncb2-Internal2 + default: 00:81:37:0E:0F:12 + ncb1-name: + hidden: false + immutable: false + type: string + description: Name of ncb1 + default: ZRDM1MMEX33NCB001 + fsb1-image: + hidden: false + immutable: false + type: string + description: Name of image to use for server fsb1 + default: MME_FSB1_15B-CP04-r5a01 + fsb1-flavor: + hidden: false + immutable: false + type: string + description: Flavor to use for servers fsb1 + default: m4.xlarge4 + volume_type: + hidden: false + immutable: false + type: string + description: volume + Internal2_net_pool_end: + hidden: false + immutable: false + type: string + default: 169.255.0.254 + epc-sctp-b-net-name: + hidden: false + immutable: false + type: string + description: epc-sctp-b net name + default: EPC-SCTP-B + Internal2_cidr: + hidden: false + immutable: false + type: string + default: 169.255.0.0/17 + epc-gtp-net-gateway: + hidden: false + immutable: false + type: string + description: gtp network gateway + default: 107.243.37.65 + gpb2-Internal2-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to gpb2-Internal2 + default: 00:81:37:0E:02:22 + ncb1-Internal2-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to ncb1-Internal2 + default: 00:81:37:0E:09:12 + epc-gtp-pool-start: + hidden: false + immutable: false + type: string + description: gtp network ip pool start IP address + default: 107.243.37.67 + static_prefix_sctp_a_1: + hidden: false + immutable: false + type: string + description: Static Prefix + default: 107.239.40.32/30 + gpb1-name: + hidden: false + immutable: false + type: string + description: Name of gpb1 + default: ZRDM1MMEX33GPB001 + pxe-image: + hidden: false + immutable: false + type: string + description: Name of image to use for server ncb + default: MME_PXE-BOOT_cxp9025898_2r5a01.qcow2 + vlc1-Internal2-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to vlc1-Internal2 + default: 00:81:37:0E:01:12 + node_templates: + contail-net-default-true-dhcp: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + route_targets: + - get_input: epc-gtp-net-rt + network_name: + get_input: epc-gtp-net-name + subnets: + epc-gtp-subnet: + cidr: + get_input: epc-gtp-net-cidr + gateway_ip: + get_input: epc-gtp-net-gateway + allocation_pools: + - start: + get_input: epc-gtp-pool-start + end: + get_input: epc-gtp-pool-end + contail-net-dhcp-false-param: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + shared: + get_input: Internal1_shared + forwarding_mode: + get_input: Internal1_forwarding_mode + external: true + route_targets: + get_artifact: + - SELF + - nimbus-ethernet + network_name: + get_input: Internal1_net_name + subnets: + Internal3-subnet: + enable_dhcp: + get_input: Internal2_dhcp + cidr: + get_input: Internal2_cidr + gateway_ip: + get_input: Internal2_default_gateway + Internal1-subnet: + enable_dhcp: + get_input: Internal1_dhcp + cidr: + get_input: Internal1_cidr + gateway_ip: + get_input: Internal1_default_gateway + dhcp_enabled: + get_input: Internal1_dhcp + artifacts: + nimbus-ethernet: + type: tosca.artifacts.Deployment + file: ../Artifacts/nimbus-ethernet.sh + contail-net-dhcp-false: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + shared: + get_input: Internal1_shared + forwarding_mode: + get_input: Internal1_forwarding_mode + external: true + route_targets: + get_artifact: + - SELF + - nimbus-ethernet + network_name: + get_input: Internal1_net_name + subnets: + Internal3-subnet: + enable_dhcp: + get_input: Internal2_dhcp + cidr: + get_input: Internal2_cidr + gateway_ip: + get_input: Internal2_default_gateway + Internal1-subnet: + enable_dhcp: + get_input: Internal1_dhcp + cidr: + get_input: Internal1_cidr + gateway_ip: + get_input: Internal1_default_gateway + dhcp_enabled: false + artifacts: + nimbus-ethernet: + type: tosca.artifacts.Deployment + file: ../Artifacts/nimbus-ethernet.sh + contail-net-dhcp-true-param: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + shared: + get_input: Internal1_shared + forwarding_mode: + get_input: Internal1_forwarding_mode + external: true + route_targets: + get_artifact: + - SELF + - nimbus-ethernet + network_name: + get_input: Internal1_net_name + subnets: + Internal3-subnet: + enable_dhcp: + get_input: Internal2_dhcp + cidr: + get_input: Internal2_cidr + gateway_ip: + get_input: Internal2_default_gateway + Internal1-subnet: + enable_dhcp: + get_input: Internal1_dhcp + cidr: + get_input: Internal1_cidr + gateway_ip: + get_input: Internal1_default_gateway + dhcp_enabled: + get_input: Internal3_dhcp + artifacts: + nimbus-ethernet: + type: tosca.artifacts.Deployment + file: ../Artifacts/nimbus-ethernet.sh + contail-net-dhcp-true: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + shared: + get_input: Internal1_shared + forwarding_mode: + get_input: Internal1_forwarding_mode + external: true + route_targets: + get_artifact: + - SELF + - nimbus-ethernet + network_name: + get_input: Internal1_net_name + subnets: + Internal3-subnet: + enable_dhcp: + get_input: Internal2_dhcp + cidr: + get_input: Internal2_cidr + gateway_ip: + get_input: Internal2_default_gateway + Internal1-subnet: + enable_dhcp: + get_input: Internal1_dhcp + cidr: + get_input: Internal1_cidr + gateway_ip: + get_input: Internal1_default_gateway + dhcp_enabled: true + artifacts: + nimbus-ethernet: + type: tosca.artifacts.Deployment + file: ../Artifacts/nimbus-ethernet.sh + contail-net-dhcp-default-true-param: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + shared: + get_input: Internal1_shared + forwarding_mode: + get_input: Internal1_forwarding_mode + external: true + route_targets: + get_artifact: + - SELF + - nimbus-ethernet + network_name: + get_input: Internal1_net_name + subnets: + Internal3-subnet: + enable_dhcp: + get_input: Internal2_dhcp + cidr: + get_input: Internal2_cidr + gateway_ip: + get_input: Internal2_default_gateway + Internal1-subnet: + enable_dhcp: + get_input: Internal1_dhcp + cidr: + get_input: Internal1_cidr + gateway_ip: + get_input: Internal1_default_gateway + dhcp_enabled: + get_input: Internal4_dhcp + artifacts: + nimbus-ethernet: + type: tosca.artifacts.Deployment + file: ../Artifacts/nimbus-ethernet.sh + neutron-net-default-dhcp: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + network_name: + get_input: private_net_2_name + subnets: + private_subnet_2: + cidr: + get_input: private_net_2_cidr + gateway_ip: + get_input: private_net_2_gateway + allocation_pools: + - start: + get_input: private_net_2_pool_start + end: + get_input: private_net_2_pool_end + groups: + vmme_small: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/vmme_small.yml + description: | + HOT template to create vmme 2 fsb 2 ncb 2 gbp 2 vlc + members: + - contail-net-default-true-dhcp + - contail-net-dhcp-false-param + - contail-net-dhcp-false + - contail-net-dhcp-true-param + - contail-net-dhcp-true + - contail-net-dhcp-default-true-param + - neutron-net-default-dhcp \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/onlyComponents/OnlyComponentsST.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/onlyComponents/OnlyComponentsST.yaml new file mode 100644 index 0000000000..54f39e4219 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/onlyComponents/OnlyComponentsST.yaml @@ -0,0 +1,350 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.pcrf_psm: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.pcm: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + Internal2_name: + label: Internal2_name + hidden: false + immutable: false + type: string + description: Internal2_name + Internal1_shared: + label: Internal1_shared + hidden: false + immutable: false + type: string + description: Internal1_shared + FSB1_volume_name: + label: FSB1_volume + hidden: false + immutable: false + type: string + description: FSB1_volume_1 + jsa_cidr: + label: jsa_cidr + hidden: false + immutable: false + type: string + description: jsa_cidr + default: 107.243.7.128/26 + availabilityzone_name: + label: availabilityzone_name + hidden: false + immutable: false + type: string + description: availabilityzone_name + fsb1-name: + label: FSB1_name + hidden: false + immutable: false + type: string + description: FSB1_name + pcm_image_name: + label: pcm_image_name + hidden: false + immutable: false + type: string + description: pcm_image_name + Internal2_external: + label: Internal2_external + hidden: false + immutable: false + type: string + description: Internal2_external + Internal2_forwarding_mode: + label: Internal2_forwarding_mode + hidden: false + immutable: false + type: string + description: Internal2_forwarding_mode + pcrf_psm_flavor_name: + label: pcrf_psm_flavor_name + hidden: false + immutable: false + type: string + description: pcrf_psm_flavor_name + pcrf_psm_image_name: + label: pcrf_psm_image_name + hidden: false + immutable: false + type: string + description: pcrf_psm_image_name + FSB_1_image: + label: MME_FSB1 + hidden: false + immutable: false + type: string + description: MME_FSB1_15B-CP04-r5a01 + volume_size: + label: volume size + hidden: false + immutable: false + type: float + description: my volume size 320GB + fsb1-Internal1-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + Internal2_shared: + label: Internal2_shared + hidden: false + immutable: false + type: string + description: Internal2_shared + pcm_server_name: + label: pcm_server_name + hidden: false + immutable: false + type: string + description: pcm_server_name + Internal1_net_name: + label: Internal1_net_name + hidden: false + immutable: false + type: string + description: Internal1_net_name + oam_net_name: + label: oam_net_name + hidden: false + immutable: false + type: string + description: oam_net_name + fsb1-flavor: + label: FSB1_flavor + hidden: false + immutable: false + type: string + description: FSB1_flavor + fsb1-Internal2-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + volume_type: + label: volume type + hidden: false + immutable: false + type: string + description: volume type Gold + fsb1-zone: + label: FSB1_zone + hidden: false + immutable: false + type: string + description: FSB1_zone + fsb_zone: + label: FSB1_zone + hidden: false + immutable: false + type: string + description: FSB1_zone + security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + jsa_net_name: + label: jsa_net_name + hidden: false + immutable: false + type: string + description: jsa_net_name + default: jsa_log_net_0 + pcrf_psm_server_name: + label: pcrf_psm_server_name + hidden: false + immutable: false + type: string + description: pcrf_psm_server_name + pcm_flavor_name: + label: pcm_flavor_name + hidden: false + immutable: false + type: string + description: pcm_flavor_name + oam_net_id: + label: oam_net_id + hidden: false + immutable: false + type: string + description: oam_net_id + fsb2-Internal1-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + Internal1_forwarding_mode: + label: Internal1_forwarding_mode + hidden: false + immutable: false + type: string + description: Internal1_forwarding_mode + pcrf_cps_net_name: + label: pcrf_cps_net_name + hidden: false + immutable: false + type: string + description: pcrf_cps_net_name + cps_net_name: + label: cps_net_name + hidden: false + immutable: false + type: string + description: cps_net_name + pcrf_security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + Internal1_external: + label: Internal1_external + hidden: false + immutable: false + type: string + description: Internal1_external + node_templates: + nova_local_type_pcm1: + type: org.openecomp.resource.vfc.nodes.heat.pcm + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + user_data: UNSUPPORTED_RESOURCE_server_init + nova_local_type_pcm2: + type: org.openecomp.resource.vfc.nodes.heat.pcm + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + user_data: UNSUPPORTED_RESOURCE_server_init + nova_local_type_pcrf_psm: + type: org.openecomp.resource.vfc.nodes.heat.pcrf_psm + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + user_data: UNSUPPORTED_RESOURCE_server_init + nova_global_type1: + type: org.openecomp.resource.vfc.nodes.heat.nova.Server + properties: + flavor: + get_input: fsb1-flavor + availability_zone: + get_input: fsb_zone + name: + get_input: fsb1-name + nova_global_type2: + type: org.openecomp.resource.vfc.nodes.heat.nova.Server + properties: + flavor: + get_input: fsb1-flavor + availability_zone: + get_input: fsb_zone + metadata: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: '0644' + content: + str_replace: + template: + get_artifact: + - SELF + - nimbus-ethernet + params: + $dev: eth0 + $netmask: + get_input: cps_net_mask + $ip: + get_input: cps_net_ip + - path: /etc/sysconfig/network-scripts/ifcfg-eth1 + permissions: '0644' + content: + str_replace: + template: + get_artifact: + - SELF + - nimbus-ethernet-gw + params: + $dev: eth1 + $netmask: + get_input: oam_net_mask + $gateway: + get_input: oam_net_gw + $ip: + get_input: oam_net_ip + name: + get_input: fsb1-name + artifacts: + nimbus-ethernet-gw: + type: tosca.artifacts.Deployment + file: ../Artifacts/nimbus-ethernet-gw + nimbus-ethernet: + type: tosca.artifacts.Deployment + file: ../Artifacts/nimbus-ethernet + groups: + ep-jsa_net: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/ep-jsa_net.yaml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - nova_local_type_pcm1 + - nova_local_type_pcm2 + - nova_local_type_pcrf_psm + - nova_global_type1 + - nova_global_type2 \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/substitution/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/substitution/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..06e6fb0b01 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/substitution/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,235 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.nested1: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + cmaui_names: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + p1: + type: string + description: UID of OAM network + p2: + type: string + description: UID of OAM network + abc_flavor: + type: string + description: Flavor for CMAUI server + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + abc_names: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + security_group_name: + description: not impotrtant + availability_zone_0: + type: string + description: availabilityzone name + abc_image: + type: string + description: Image for CMAUI server + requirements: + - link_cmaui_port_2: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - local_storage_server_cmaui: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - local_storage_server_abc: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_abc_port_1: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_cmaui_port_1: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + scalable_server_abc: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + os_server_cmaui: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + attachment_abc_port_1: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + host_server_abc: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + scalable_server_cmaui: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + os_server_abc: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + host_server_cmaui: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + binding_server_abc: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + endpoint_server_cmaui: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + binding_server_cmaui: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + endpoint_server_abc: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_2: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_1: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + org.openecomp.resource.abstract.nodes.heat.nested2: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + cmaui_names: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + p1: + type: string + description: UID of OAM network + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + security_group_name: + description: not impotrtant + availability_zone_0: + type: string + description: availabilityzone name + requirements: + - local_storage_server_cmaui: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_cmaui_port_1: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + host_server_cmaui: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + os_server_cmaui: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + endpoint_server_cmaui: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + binding_server_cmaui: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + scalable_server_cmaui: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_1: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/substitution/MainServiceTemplate.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/substitution/MainServiceTemplate.yaml new file mode 100644 index 0000000000..6dd557798d --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/substitution/MainServiceTemplate.yaml @@ -0,0 +1,139 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml +topology_template: + inputs: + shared_network_id1: + hidden: false + immutable: false + type: string + description: network name of jsa log network + shared_network_id2: + hidden: false + immutable: false + type: string + description: network name of jsa log network + jsa_net_name: + hidden: false + immutable: false + type: string + description: network name of jsa log network + node_templates: + test_net2: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + shared: true + network_name: + get_input: jsa_net_name + test_nested2: + type: org.openecomp.resource.abstract.nodes.heat.nested2 + directives: + - substitutable + properties: + p1: + get_input: shared_network_id1 + service_template_filter: + substitute_service_template: nested2ServiceTemplate.yaml + requirements: + - link_cmaui_port_1: + capability: tosca.capabilities.network.Linkable + node: test_net1 + relationship: tosca.relationships.network.LinksTo + test_nested3: + type: org.openecomp.resource.abstract.nodes.heat.nested1 + directives: + - substitutable + properties: + p1: + get_input: shared_network_id1 + service_template_filter: + substitute_service_template: nested1ServiceTemplate.yaml + p2: + get_input: shared_network_id2 + requirements: + - link_cmaui_port_2: + capability: tosca.capabilities.network.Linkable + node: test_net2 + relationship: tosca.relationships.network.LinksTo + - link_abc_port_1: + capability: tosca.capabilities.network.Linkable + node: test_net2 + relationship: tosca.relationships.network.LinksTo + - link_cmaui_port_1: + capability: tosca.capabilities.network.Linkable + node: test_net1 + relationship: tosca.relationships.network.LinksTo + test_net1: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + shared: true + network_name: + get_input: jsa_net_name + test_nested1: + type: org.openecomp.resource.abstract.nodes.heat.nested1 + directives: + - substitutable + properties: + p1: + get_input: shared_network_id1 + service_template_filter: + substitute_service_template: nested1ServiceTemplate.yaml + p2: + get_input: shared_network_id2 + requirements: + - link_cmaui_port_2: + capability: tosca.capabilities.network.Linkable + node: test_net2 + relationship: tosca.relationships.network.LinksTo + - link_abc_port_1: + capability: tosca.capabilities.network.Linkable + node: test_net2 + relationship: tosca.relationships.network.LinksTo + - link_cmaui_port_1: + capability: tosca.capabilities.network.Linkable + node: test_net1 + relationship: tosca.relationships.network.LinksTo + groups: + addOn: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/addOn.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - test_nested2 + - test_nested3 + - test_nested1 + main: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/main.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - test_net2 + - test_net1 + outputs: + shared_network_id1: + value: test_net1 + shared_network_id2: + value: test_net2 \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/substitution/nested1ServiceTemplate.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/substitution/nested1ServiceTemplate.yaml new file mode 100644 index 0000000000..1eb0796736 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/substitution/nested1ServiceTemplate.yaml @@ -0,0 +1,241 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested1 +imports: + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + nested1: + file: GlobalSubstitutionTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui_image: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.abc_image: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + p1: + hidden: false + immutable: false + type: string + description: UID of OAM network + p2: + hidden: false + immutable: false + type: string + description: UID of OAM network + abc_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + abc_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + security_group_name: + hidden: false + immutable: false + description: not impotrtant + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + abc_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + node_templates: + cmaui_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: p2 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui_image + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + name: + get_input: + - cmaui_names + - 0 + server_abc: + type: org.openecomp.resource.vfc.nodes.heat.abc_image + properties: + flavor: + get_input: abc_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: abc_image + name: + get_input: + - abc_names + - 0 + abc_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - abc_oam_ips + - 0 + network: + get_input: p2 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_abc + relationship: tosca.relationships.network.BindsTo + cmaui_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: p1 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + Internal1-net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + network_name: + get_input: Internal1_net_name + groups: + nested1: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested1.yml + description: cmaui server template for vMMSC + members: + - cmaui_port_2 + - server_cmaui + - server_abc + - abc_port_1 + - cmaui_port_1 + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested1 + capabilities: + scalable_server_abc: + - server_abc + - scalable + os_server_cmaui: + - server_cmaui + - os + attachment_abc_port_1: + - abc_port_1 + - attachment + host_server_abc: + - server_abc + - host + scalable_server_cmaui: + - server_cmaui + - scalable + os_server_abc: + - server_abc + - os + host_server_cmaui: + - server_cmaui + - host + binding_server_abc: + - server_abc + - binding + endpoint_server_cmaui: + - server_cmaui + - endpoint + binding_server_cmaui: + - server_cmaui + - binding + endpoint_server_abc: + - server_abc + - endpoint + attachment_cmaui_port_2: + - cmaui_port_2 + - attachment + attachment_cmaui_port_1: + - cmaui_port_1 + - attachment + requirements: + local_storage_server_cmaui: + - server_cmaui + - local_storage + link_abc_port_1: + - abc_port_1 + - link + link_cmaui_port_2: + - cmaui_port_2 + - link + link_cmaui_port_1: + - cmaui_port_1 + - link + local_storage_server_abc: + - server_abc + - local_storage \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/substitution/nested2ServiceTemplate.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/substitution/nested2ServiceTemplate.yaml new file mode 100644 index 0000000000..3545683971 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/substitution/nested2ServiceTemplate.yaml @@ -0,0 +1,135 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested2 +imports: + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + nested2: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui_image: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + p1: + hidden: false + immutable: false + type: string + description: UID of OAM network + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + security_group_name: + hidden: false + immutable: false + description: not impotrtant + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + node_templates: + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui_image + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + name: + get_input: + - cmaui_names + - 0 + cmaui_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: p1 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + Internal1-net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + network_name: + get_input: Internal1_net_name + groups: + nested2: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested2.yml + description: cmaui server template for vMMSC + members: + - server_cmaui + - cmaui_port_1 + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested2 + capabilities: + host_server_cmaui: + - server_cmaui + - host + os_server_cmaui: + - server_cmaui + - os + endpoint_server_cmaui: + - server_cmaui + - endpoint + binding_server_cmaui: + - server_cmaui + - binding + scalable_server_cmaui: + - server_cmaui + - scalable + attachment_cmaui_port_1: + - cmaui_port_1 + - attachment + requirements: + local_storage_server_cmaui: + - server_cmaui + - local_storage + link_cmaui_port_1: + - cmaui_port_1 + - link \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/AbstractSubstituteGlobalTypesServiceTemplate.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/AbstractSubstituteGlobalTypesServiceTemplate.yaml new file mode 100644 index 0000000000..8813b0abf6 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/AbstractSubstituteGlobalTypesServiceTemplate.yaml @@ -0,0 +1,47 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: AbstractSubstituteGlobalTypes + template_version: 1.0.0 +description: Abstract Substitute Global Types +imports: + common_definitions: + file: CommonGlobalTypesServiceTemplate.yaml +data_types: + org.openecomp.datatypes.heat.substitution.SubstitutionFilter: + derived_from: tosca.datatypes.Root + description: Substitution Filter + properties: + substitute_service_template: + type: string + description: Substitute Service Template + required: true + status: SUPPORTED + index_variable: + type: string + description: Index variable + required: false + default: '%index%' + status: SUPPORTED + constraints: + - min_length: 3 + count: + type: string + description: Count + required: false + default: 1 + status: SUPPORTED + mandatory: + type: boolean + description: Mandatory + required: false + default: true + status: SUPPORTED +node_types: + org.openecomp.resource.abstract.nodes.AbstractSubstitute: + derived_from: tosca.nodes.Root + properties: + service_template_filter: + type: org.openecomp.datatypes.heat.substitution.SubstitutionFilter + description: Substitution Filter + required: true + status: SUPPORTED \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/CinderVolumeGlobalTypesServiceTemplate.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/CinderVolumeGlobalTypesServiceTemplate.yaml new file mode 100644 index 0000000000..3ef94f22e7 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/CinderVolumeGlobalTypesServiceTemplate.yaml @@ -0,0 +1,176 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: CinderVolumeGlobalTypes + template_version: 1.0.0 +description: Cinder Volume TOSCA Global Types +relationship_types: + org.openecomp.relationships.heat.cinder.VolumeAttachesTo: + derived_from: tosca.relationships.AttachesTo + description: This type represents an attachment relationship for associating volume + properties: + volume_id: + type: string + description: The ID of the volume to be attached + required: true + status: SUPPORTED + location: + type: string + description: The location where the volume is exposed on the instance, mountpoint + required: false + status: SUPPORTED + instance_uuid: + type: string + description: The ID of the server to which the volume attaches + required: true + status: SUPPORTED + attributes: + show: + type: string + description: Detailed information about resource + status: SUPPORTED +node_types: + org.openecomp.resource.vfc.nodes.heat.cinder.Volume: + derived_from: tosca.nodes.BlockStorage + properties: + availability_zone: + type: string + description: The availability zone in which the volume will be created + required: false + status: SUPPORTED + image: + type: string + description: If specified, the name or ID of the image to create the volume from + required: false + status: SUPPORTED + metadata: + type: map + description: Key/value pairs to associate with the volume + required: false + status: SUPPORTED + entry_schema: + type: string + volume_type: + type: string + description: If specified, the type of volume to use, mapping to a specific backend + required: false + status: SUPPORTED + description: + type: string + description: A description of the volume + required: false + status: SUPPORTED + device_type: + type: string + description: Device type + required: false + status: SUPPORTED + constraints: + - valid_values: + - cdrom + - disk + disk_bus: + type: string + description: 'Bus of the device: hypervisor driver chooses a suitable default + if omitted' + required: false + status: SUPPORTED + constraints: + - valid_values: + - ide + - lame_bus + - scsi + - usb + - virtio + backup_id: + type: string + description: If specified, the backup to create the volume from + required: false + status: SUPPORTED + source_volid: + type: string + description: If specified, the volume to use as source + required: false + status: SUPPORTED + boot_index: + type: integer + description: Integer used for ordering the boot disks + required: false + status: SUPPORTED + size: + type: scalar-unit.size + description: The requested storage size (default unit is MB) + required: false + status: SUPPORTED + constraints: + - greater_or_equal: 1 GB + read_only: + type: boolean + description: Enables or disables read-only access mode of volume + required: false + status: SUPPORTED + name: + type: string + description: A name used to distinguish the volume + required: false + status: SUPPORTED + scheduler_hints: + type: map + description: Arbitrary key-value pairs specified by the client to help the Cinder scheduler creating a volume + required: false + status: SUPPORTED + entry_schema: + type: string + swap_size: + type: scalar-unit.size + description: The size of the swap, in MB + required: false + status: SUPPORTED + delete_on_termination: + type: boolean + description: Indicate whether the volume should be deleted when the server is terminated + required: false + status: SUPPORTED + multiattach: + type: boolean + description: Whether allow the volume to be attached more than once + required: false + status: SUPPORTED + attributes: + display_description: + type: string + description: Description of the volume + status: SUPPORTED + attachments: + type: string + description: The list of attachments of the volume + status: SUPPORTED + entry_schema: + type: string + encrypted: + type: boolean + description: Boolean indicating if the volume is encrypted or not + status: SUPPORTED + show: + type: string + description: Detailed information about resource + status: SUPPORTED + created_at: + type: timestamp + description: The timestamp indicating volume creation + status: SUPPORTED + display_name: + type: string + description: Name of the volume + status: SUPPORTED + metadata_values: + type: map + description: Key/value pairs associated with the volume in raw dict form + status: SUPPORTED + bootable: + type: boolean + description: Boolean indicating if the volume can be booted or not + status: SUPPORTED + status: + type: string + description: The current status of the volume + status: SUPPORTED diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/CommonGlobalTypesServiceTemplate.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/CommonGlobalTypesServiceTemplate.yaml new file mode 100644 index 0000000000..3388d5a89b --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/CommonGlobalTypesServiceTemplate.yaml @@ -0,0 +1,213 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: CommonGlobalTypes + template_version: 1.0.0 +description: TOSCA Global Types +imports: + NativeTypesServiceTemplate: + file: NativeTypesServiceTemplateServiceTemplate.yaml +data_types: + org.openecomp.datatypes.heat.network.AddressPair: + derived_from: tosca.datatypes.Root + description: MAC/IP address pairs + properties: + mac_address: + type: string + description: MAC address + required: false + status: SUPPORTED + ip_address: + type: string + description: IP address + required: false + status: SUPPORTED + org.openecomp.datatypes.heat.network.subnet.HostRoute: + derived_from: tosca.datatypes.Root + description: Host route info for the subnet + properties: + destination: + type: string + description: The destination for static route + required: false + status: SUPPORTED + nexthop: + type: string + description: The next hop for the destination + required: false + status: SUPPORTED + org.openecomp.datatypes.heat.network.neutron.Subnet: + derived_from: tosca.datatypes.Root + description: A subnet represents an IP address block that can be used for assigning IP addresses to virtual instances + properties: + tenant_id: + type: string + description: The ID of the tenant who owns the network + required: false + status: SUPPORTED + enable_dhcp: + type: boolean + description: Set to true if DHCP is enabled and false if DHCP is disabled + required: false + default: true + status: SUPPORTED + ipv6_address_mode: + type: string + description: IPv6 address mode + required: false + status: SUPPORTED + constraints: + - valid_values: + - dhcpv6-stateful + - dhcpv6-stateless + - slaac + ipv6_ra_mode: + type: string + description: IPv6 RA (Router Advertisement) mode + required: false + status: SUPPORTED + constraints: + - valid_values: + - dhcpv6-stateful + - dhcpv6-stateless + - slaac + value_specs: + type: map + description: Extra parameters to include in the request + required: false + default: { + } + status: SUPPORTED + entry_schema: + type: string + allocation_pools: + type: list + description: The start and end addresses for the allocation pools + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.AllocationPool + subnetpool: + type: string + description: The name or ID of the subnet pool + required: false + status: SUPPORTED + dns_nameservers: + type: list + description: A specified set of DNS name servers to be used + required: false + default: [ + ] + status: SUPPORTED + entry_schema: + type: string + host_routes: + type: list + description: The gateway IP address + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.subnet.HostRoute + ip_version: + type: integer + description: The gateway IP address + required: false + default: 4 + status: SUPPORTED + constraints: + - valid_values: + - '4' + - '6' + name: + type: string + description: The name of the subnet + required: false + status: SUPPORTED + prefixlen: + type: integer + description: Prefix length for subnet allocation from subnet pool + required: false + status: SUPPORTED + constraints: + - greater_or_equal: 0 + cidr: + type: string + description: The CIDR + required: false + status: SUPPORTED + gateway_ip: + type: string + description: The gateway IP address + required: false + status: SUPPORTED + org.openecomp.datatypes.heat.network.AllocationPool: + derived_from: tosca.datatypes.Root + description: The start and end addresses for the allocation pool + properties: + start: + type: string + description: Start address for the allocation pool + required: false + status: SUPPORTED + end: + type: string + description: End address for the allocation pool + required: false + status: SUPPORTED +relationship_types: + org.openecomp.relationships.AttachesTo: + derived_from: tosca.relationships.Root + description: This type represents an attachment relationship +group_types: + org.openecomp.groups.heat.HeatStack: + derived_from: tosca.groups.Root + description: Grouped all heat resources which are in the same heat stack + properties: + heat_file: + type: string + description: Heat file which associate to this group/heat stack + required: true + status: SUPPORTED + description: + type: string + description: Heat file description + required: false + status: SUPPORTED +policy_types: + org.openecomp.policies.placement.Colocate: + derived_from: tosca.policy.placement + description: Keep associated nodes (groups of nodes) based upon affinity value + properties: + name: + type: string + description: The name of the policy + required: false + status: SUPPORTED + affinity: + type: string + description: affinity + required: true + status: SUPPORTED + constraints: + - valid_values: + - host + - region + - compute + org.openecomp.policies.placement.Antilocate: + derived_from: tosca.policy.placement + description: My placement policy for separation based upon container type value + properties: + name: + type: string + description: The name of the policy + required: false + status: SUPPORTED + container_type: + type: string + description: container type + required: false + status: SUPPORTED + constraints: + - valid_values: + - host + - region + - compute diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/ContrailNetworkRuleGlobalTypeServiceTemplate.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/ContrailNetworkRuleGlobalTypeServiceTemplate.yaml new file mode 100644 index 0000000000..98317310fa --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/ContrailNetworkRuleGlobalTypeServiceTemplate.yaml @@ -0,0 +1,117 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: ContrailNetworkRuleGlobalType + template_version: 1.0.0 +description: Contrail Network Rule Global Types +imports: + common_definitions: + file: CommonGlobalTypesServiceTemplate.yaml +data_types: + org.openecomp.datatypes.heat.contrail.network.rule.PortPairs: + derived_from: tosca.datatypes.Root + description: source and destination port pairs + properties: + start_port: + type: string + description: Start port + required: false + status: SUPPORTED + end_port: + type: string + description: End port + required: false + status: SUPPORTED + org.openecomp.datatypes.heat.contrail.network.rule.Rule: + derived_from: tosca.datatypes.Root + description: policy rule + properties: + src_ports: + type: list + description: Source ports + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.contrail.network.rule.PortPairs + protocol: + type: string + description: Protocol + required: false + status: SUPPORTED + dst_addresses: + type: list + description: Destination addresses + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.contrail.network.rule.VirtualNetwork + apply_service: + type: string + description: Service to apply + required: false + status: SUPPORTED + dst_ports: + type: list + description: Destination ports + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.contrail.network.rule.PortPairs + src_addresses: + type: list + description: Source addresses + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.contrail.network.rule.VirtualNetwork + direction: + type: string + description: Direction + required: false + status: SUPPORTED + org.openecomp.datatypes.heat.contrail.network.rule.RuleList: + derived_from: tosca.datatypes.Root + description: list of policy rules + properties: + policy_rule: + type: list + description: Contrail network rule + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.contrail.network.rule.Rule + org.openecomp.datatypes.heat.contrail.network.rule.VirtualNetwork: + derived_from: tosca.datatypes.Root + description: source and destination addresses + properties: + virtual_network: + type: string + description: Virtual network + required: false + status: SUPPORTED +node_types: + org.openecomp.resource.nodes.heat.network.contrail.NetworkRules: + derived_from: tosca.nodes.Root + properties: + entries: + type: org.openecomp.datatypes.heat.contrail.network.rule.RuleList + description: A symbolic name for this contrail network rule + required: false + status: SUPPORTED + name: + type: string + description: A symbolic name for this contrail network rule + required: false + status: SUPPORTED + attributes: + fq_name: + type: string + description: fq_name + status: SUPPORTED + requirements: + - network: + capability: tosca.capabilities.Attachment + node: tosca.nodes.network.Network + relationship: org.openecomp.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml new file mode 100644 index 0000000000..0927e3dd0e --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml @@ -0,0 +1,71 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: ContrailVirtualNetworkGlobalType + template_version: 1.0.0 +description: Contrail Virtual Network Global Types +imports: + common_definitions: + file: CommonGlobalTypesServiceTemplate.yaml +node_types: + org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork: + derived_from: tosca.nodes.network.Network + properties: + shared: + type: string + description: Is virtual network shared + required: false + status: SUPPORTED + forwarding_mode: + type: string + description: forwarding mode of the virtual network + required: false + status: SUPPORTED + external: + type: string + description: Is virtual network external + required: false + status: SUPPORTED + flood_unknown_unicast: + type: string + description: flood L2 packets on network + required: false + status: SUPPORTED + route_targets: + type: list + description: route targets associated with the virtual network + required: false + status: SUPPORTED + entry_schema: + type: string + subnets: + type: map + description: Network related subnets + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.neutron.Subnet + attributes: + subnets_name: + type: list + description: Subnets name of this network + status: SUPPORTED + entry_schema: + type: string + subnets_show: + type: map + description: Detailed information about each subnet + status: SUPPORTED + entry_schema: + type: string + subnets: + type: map + description: Network related subnets + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.neutron.Subnet + capabilities: + attachment: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..08c47bc646 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,93 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.nested: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + cmaui_names: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + p1: + type: string + description: UID of OAM network + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + security_group_name: + description: not impotrtant + availability_zone_0: + type: string + description: availabilityzone name + requirements: + - local_storage_server_cmaui: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_cmaui_port_0: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + host_server_cmaui: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + os_server_cmaui: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + endpoint_server_cmaui: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + binding_server_cmaui: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + scalable_server_cmaui: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_0: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NativeTypesServiceTemplateServiceTemplate.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NativeTypesServiceTemplateServiceTemplate.yaml new file mode 100644 index 0000000000..e7dfd49ed9 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NativeTypesServiceTemplateServiceTemplate.yaml @@ -0,0 +1,194 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: NativeTypesServiceTemplate + template_version: 1.0.0 +description: TOSCA Native Node Types +node_types: + tosca.nodes.Compute: + derived_from: tosca.nodes.Root + attributes: + private_address: + type: string + description: private address + status: SUPPORTED + public_address: + type: string + description: public_address + status: SUPPORTED + networks: + type: map + description: networks + status: SUPPORTED + entry_schema: + type: tosca.datatypes.network.NetworkInfo + ports: + type: map + description: ports + status: SUPPORTED + entry_schema: + type: tosca.datatypes.network.PortInfo + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + capabilities: + scalable: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + endpoint: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + os: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + host: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + binding: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + tosca.nodes.network.Port: + derived_from: tosca.nodes.Root + properties: + ip_range_end: + type: string + required: false + status: SUPPORTED + ip_range_start: + type: string + required: false + status: SUPPORTED + ip_address: + type: string + required: false + status: SUPPORTED + is_default: + type: boolean + required: false + default: false + status: SUPPORTED + order: + type: integer + required: true + default: 0 + status: SUPPORTED + constraints: + - greater_or_equal: 0 + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: tosca.nodes.Root + relationship: tosca.relationships.network.BindsTo + tosca.nodes.Root: + attributes: + tosca_name: + type: string + description: tosca name + status: SUPPORTED + state: + type: string + description: state + status: SUPPORTED + tosca_id: + type: string + description: tosca id + status: SUPPORTED + interfaces: { + } + tosca.nodes.network.Network: + derived_from: tosca.nodes.Root + properties: + physical_network: + type: string + required: false + status: SUPPORTED + segmentation_id: + type: string + required: false + status: SUPPORTED + network_id: + type: string + required: false + status: SUPPORTED + ip_version: + type: integer + required: false + default: 4 + status: SUPPORTED + constraints: + - valid_values: + - 4 + - 6 + start_ip: + type: string + required: false + status: SUPPORTED + network_name: + type: string + required: false + status: SUPPORTED + cidr: + type: string + required: false + status: SUPPORTED + gateway_ip: + type: string + required: false + status: SUPPORTED + network_type: + type: string + required: false + status: SUPPORTED + end_ip: + type: string + required: false + status: SUPPORTED + capabilities: + link: + type: tosca.capabilities.network.Linkable + occurrences: + - 1 + - UNBOUNDED + tosca.nodes.BlockStorage: + derived_from: tosca.nodes.Root + properties: + size: + type: scalar-unit.size + required: false + status: SUPPORTED + constraints: + - greater_or_equal: 1 MB + volume_id: + type: string + required: false + status: SUPPORTED + snapshot_id: + type: string + required: false + status: SUPPORTED + capabilities: + attachment: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NeutronNetGlobalTypesServiceTemplate.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NeutronNetGlobalTypesServiceTemplate.yaml new file mode 100644 index 0000000000..e80e2727c7 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NeutronNetGlobalTypesServiceTemplate.yaml @@ -0,0 +1,97 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: NeutronNetGlobalTypes + template_version: 1.0.0 +description: Neutron Network TOSCA Global Types +imports: + common_definitions: + file: CommonGlobalTypesServiceTemplate.yaml +node_types: + org.openecomp.resource.vl.nodes.heat.network.neutron.Net: + derived_from: tosca.nodes.network.Network + properties: + dhcp_agent_ids: + type: list + description: The IDs of the DHCP agent to schedule the network + required: false + status: SUPPORTED + entry_schema: + type: string + tenant_id: + type: string + description: The ID of the tenant which will own the network + required: false + status: SUPPORTED + port_security_enabled: + type: boolean + description: Flag to enable/disable port security on the network + required: false + status: SUPPORTED + shared: + type: boolean + description: Whether this network should be shared across all tenants + required: false + default: false + status: SUPPORTED + admin_state_up: + type: boolean + description: A boolean value specifying the administrative status of the network + required: false + default: true + status: SUPPORTED + qos_policy: + type: string + description: The name or ID of QoS policy to attach to this network + required: false + status: SUPPORTED + subnets: + type: map + description: Network related subnets + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.neutron.Subnet + value_specs: + type: map + description: Extra parameters to include in the request + required: false + default: { + } + status: SUPPORTED + entry_schema: + type: string + attributes: + qos_policy_id: + type: string + description: The QoS policy ID attached to this network + status: SUPPORTED + show: + type: string + description: Detailed information about resource + status: SUPPORTED + subnets_name: + type: list + description: Subnets name of this network + status: SUPPORTED + entry_schema: + type: string + subnets: + type: map + description: Network related subnets + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.neutron.Subnet + mtu: + type: scalar-unit.size + description: The maximum transmission unit size(in bytes) for the network + status: SUPPORTED + status: + type: string + description: The status of the network + status: SUPPORTED + capabilities: + attachment: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NeutronPortGlobalTypesServiceTemplate.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NeutronPortGlobalTypesServiceTemplate.yaml new file mode 100644 index 0000000000..a337d6ed18 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NeutronPortGlobalTypesServiceTemplate.yaml @@ -0,0 +1,151 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: NeutronPortGlobalTypes + template_version: 1.0.0 +description: Neutron Port TOSCA Global Types +imports: + common_definitions: + file: CommonGlobalTypesServiceTemplate.yaml +data_types: + org.openecomp.datatypes.heat.neutron.port.FixedIps: + derived_from: tosca.datatypes.Root + description: subnet/ip_address + properties: + subnet: + type: string + description: Subnet in which to allocate the IP address for this port + required: false + status: SUPPORTED + ip_address: + type: string + description: IP address desired in the subnet for this port + required: false + status: SUPPORTED +node_types: + org.openecomp.resource.cp.nodes.heat.network.neutron.Port: + derived_from: tosca.nodes.network.Port + properties: + port_security_enabled: + type: boolean + description: Flag to enable/disable port security on the network + required: false + status: SUPPORTED + device_id: + type: string + description: Device ID of this port + required: false + status: SUPPORTED + qos_policy: + type: string + description: The name or ID of QoS policy to attach to this network + required: false + status: SUPPORTED + allowed_address_pairs: + type: list + description: Additional MAC/IP address pairs allowed to pass through the port + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.AddressPair + binding:vnic_type: + type: string + description: The vnic type to be bound on the neutron port + required: false + status: SUPPORTED + constraints: + - valid_values: + - macvtap + - direct + - normal + value_specs: + type: map + description: Extra parameters to include in the request + required: false + default: { + } + status: SUPPORTED + entry_schema: + type: string + device_owner: + type: string + description: Name of the network owning the port + required: false + status: SUPPORTED + network: + type: string + description: Network this port belongs to + required: false + status: SUPPORTED + replacement_policy: + type: string + description: Policy on how to respond to a stack-update for this resource + required: false + default: AUTO + status: SUPPORTED + constraints: + - valid_values: + - REPLACE_ALWAYS + - AUTO + security_groups: + type: list + description: List of security group names or IDs + required: false + status: SUPPORTED + entry_schema: + type: string + fixed_ips: + type: list + description: Desired IPs for this port + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.neutron.port.FixedIps + mac_address: + type: string + description: MAC address to give to this port + required: false + status: SUPPORTED + admin_state_up: + type: boolean + description: A boolean value specifying the administrative status of the network + required: false + default: true + status: SUPPORTED + name: + type: string + description: A symbolic name for this port + required: false + status: SUPPORTED + attributes: + tenant_id: + type: string + description: Tenant owning the port + status: SUPPORTED + network_id: + type: string + description: Unique identifier for the network owning the port + status: SUPPORTED + qos_policy_id: + type: string + description: The QoS policy ID attached to this network + status: SUPPORTED + show: + type: string + description: Detailed information about resource + status: SUPPORTED + subnets: + type: list + description: Subnets of this network + status: SUPPORTED + entry_schema: + type: string + status: + type: string + description: The status of the network + status: SUPPORTED + capabilities: + attachment: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NeutronSecurityRulesGlobalTypesServiceTemplate.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NeutronSecurityRulesGlobalTypesServiceTemplate.yaml new file mode 100644 index 0000000000..49c9a102c8 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NeutronSecurityRulesGlobalTypesServiceTemplate.yaml @@ -0,0 +1,116 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: NeutronSecurityRulesGlobalTypes + template_version: 1.0.0 +description: Neutron Security Rules TOSCA Global Types +imports: + common_definitions: + file: CommonGlobalTypesServiceTemplate.yaml +data_types: + org.openecomp.datatypes.heat.network.neutron.SecurityRules.Rule: + derived_from: tosca.datatypes.Root + description: Rules Pairs + properties: + remote_group_id: + type: string + description: The remote group ID to be associated with this security group rule + required: false + status: SUPPORTED + protocol: + type: string + description: The protocol that is matched by the security group rule + required: false + status: SUPPORTED + constraints: + - valid_values: + - tcp + - udp + - icmp + ethertype: + type: string + description: Ethertype of the traffic + required: false + default: IPv4 + status: SUPPORTED + constraints: + - valid_values: + - IPv4 + - IPv6 + port_range_max: + type: integer + description: 'The maximum port number in the range that is matched by the + security group rule. ' + required: false + status: SUPPORTED + constraints: + - in_range: + - 0 + - 65535 + remote_ip_prefix: + type: string + description: The remote IP prefix (CIDR) to be associated with this security group rule + required: false + status: SUPPORTED + remote_mode: + type: string + description: Whether to specify a remote group or a remote IP prefix + required: false + default: remote_ip_prefix + status: SUPPORTED + constraints: + - valid_values: + - remote_ip_prefix + - remote_group_id + direction: + type: string + description: The direction in which the security group rule is applied + required: false + default: ingress + status: SUPPORTED + constraints: + - valid_values: + - egress + - ingress + port_range_min: + type: integer + description: The minimum port number in the range that is matched by the security group rule. + required: false + status: SUPPORTED + constraints: + - in_range: + - 0 + - 65535 +node_types: + org.openecomp.resource.nodes.heat.network.neutron.SecurityRules: + derived_from: tosca.nodes.Root + properties: + description: + type: string + description: Description of the security group + required: false + status: SUPPORTED + name: + type: string + description: A symbolic name for this security group, which is not required to be unique. + required: false + status: SUPPORTED + rules: + type: list + description: List of security group rules + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.neutron.SecurityRules.Rule + attributes: + show: + type: string + description: Detailed information about resource + status: SUPPORTED + requirements: + - port: + capability: tosca.capabilities.Attachment + node: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + relationship: org.openecomp.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NovaServerGlobalTypesServiceTemplate.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NovaServerGlobalTypesServiceTemplate.yaml new file mode 100644 index 0000000000..2253a1e4af --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NovaServerGlobalTypesServiceTemplate.yaml @@ -0,0 +1,249 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: NovaServerGlobalTypes + template_version: 1.0.0 +description: Nova Server TOSCA Global Types +imports: + common_definitions: + file: CommonGlobalTypesServiceTemplate.yaml +data_types: + org.openecomp.datatypes.heat.novaServer.network.PortExtraProperties: + derived_from: tosca.datatypes.Root + description: Nova server network expand properties for port + properties: + port_security_enabled: + type: boolean + description: Flag to enable/disable port security on the port + required: false + status: SUPPORTED + mac_address: + type: string + description: MAC address to give to this port + required: false + status: SUPPORTED + admin_state_up: + type: boolean + description: The administrative state of this port + required: false + default: true + status: SUPPORTED + qos_policy: + type: string + description: The name or ID of QoS policy to attach to this port + required: false + status: SUPPORTED + allowed_address_pairs: + type: list + description: Additional MAC/IP address pairs allowed to pass through the port + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.AddressPair + binding:vnic_type: + type: string + description: The vnic type to be bound on the neutron port + required: false + status: SUPPORTED + constraints: + - valid_values: + - macvtap + - direct + - normal + value_specs: + type: map + description: Extra parameters to include in the request + required: false + default: { + } + status: SUPPORTED + entry_schema: + type: string + org.openecomp.datatypes.heat.novaServer.network.AddressInfo: + derived_from: tosca.datatypes.network.NetworkInfo + description: Network addresses with corresponding port id + properties: + port_id: + type: string + description: Port id + required: false + status: SUPPORTED +node_types: + org.openecomp.resource.vfc.nodes.heat.nova.Server: + derived_from: tosca.nodes.Compute + properties: + admin_pass: + type: string + description: The administrator password for the server + required: false + status: SUPPORTED + availability_zone: + type: string + description: Availability zone to create servers in + required: false + status: SUPPORTED + image: + type: string + description: The ID or name of the image to boot with + required: false + status: SUPPORTED + image_update_policy: + type: string + description: Policy on how to apply an image-id update + required: false + default: REBUILD + status: SUPPORTED + constraints: + - valid_values: + - REBUILD_PRESERVE_EPHEMERAL + - REPLACE + - REBUILD + metadata: + type: map + description: Arbitrary key/value metadata to store for this server + required: false + status: SUPPORTED + constraints: + - max_length: 255 + entry_schema: + type: string + constraints: + - max_length: 255 + user_data_update_policy: + type: string + description: Policy on how to apply a user_data update + required: false + default: REPLACE + status: SUPPORTED + constraints: + - valid_values: + - REPLACE + - IGNORE + flavor_update_policy: + type: string + description: Policy on how to apply a flavor update + required: false + default: RESIZE + status: SUPPORTED + constraints: + - valid_values: + - RESIZE + - REPLACE + user_data: + type: string + description: User data script to be executed by cloud-init + required: false + default: '' + status: SUPPORTED + flavor: + type: string + description: The ID or name of the flavor to boot onto + required: true + status: SUPPORTED + key_name: + type: string + description: Name of keypair to inject into the server + required: false + status: SUPPORTED + reservation_id: + type: string + description: A UUID for the set of servers being requested + required: false + status: SUPPORTED + security_groups: + type: list + description: List of security group names or IDs + required: false + default: [ + ] + status: SUPPORTED + entry_schema: + type: string + config_drive: + type: boolean + description: enable config drive on the server + required: false + status: SUPPORTED + personality: + type: map + description: A map of files to create/overwrite on the server upon boot + required: false + default: { + } + status: SUPPORTED + entry_schema: + type: string + software_config_transport: + type: string + description: How the server should receive the metadata required for software configuration + required: false + default: POLL_SERVER_CFN + status: SUPPORTED + constraints: + - valid_values: + - POLL_SERVER_CFN + - POLL_SERVER_HEAT + - POLL_TEMP_URL + - ZAQAR_MESSAGE + user_data_format: + type: string + description: How the user_data should be formatted for the server + required: false + default: HEAT_CFNTOOLS + status: SUPPORTED + constraints: + - valid_values: + - SOFTWARE_CONFIG + - RAW + - HEAT_CFNTOOLS + diskConfig: + type: string + description: Control how the disk is partitioned when the server is created + required: false + status: SUPPORTED + constraints: + - valid_values: + - AUTO + - MANUAL + name: + type: string + description: Server name + required: false + status: SUPPORTED + scheduler_hints: + type: map + description: Arbitrary key-value pairs specified by the client to help boot a server + required: false + status: SUPPORTED + entry_schema: + type: string + attributes: + accessIPv4: + type: string + description: The manually assigned alternative public IPv4 address of the server + status: SUPPORTED + addresses: + type: map + description: A dict of all network addresses with corresponding port_id + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.novaServer.network.AddressInfo + accessIPv6: + type: string + description: The manually assigned alternative public IPv6 address of the server + status: SUPPORTED + instance_name: + type: string + description: AWS compatible instance name + status: SUPPORTED + name: + type: string + description: Name of the server + status: SUPPORTED + show: + type: string + description: Detailed information about resource + status: SUPPORTED + console_urls: + type: string + description: URLs of servers consoles + status: SUPPORTED \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/fullComposition/MANIFEST.json b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/fullComposition/MANIFEST.json new file mode 100644 index 0000000000..40c2b4c296 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/fullComposition/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-mog-0108-bs1271.yml", + "type": "HEAT", + "data": [ + { + "file": "hot-mog-0108-bs1271.env", + "type": "HEAT_ENV" + } + ] + } + ] +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/fullComposition/hot-mog-0108-bs1271.env b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/fullComposition/hot-mog-0108-bs1271.env new file mode 100644 index 0000000000..407bc8db30 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/fullComposition/hot-mog-0108-bs1271.env @@ -0,0 +1,60 @@ +parameters: + pd_server_names: ZRDM1MOGX01MPD001,ZRDM1MOGX01MPD002 + pd_image_name: MOG_BASE_8.0 + pd_flavor_name: m3.xlarge + oam_server_names: ZRDM1MOGX01OAM001,ZRDM1MOGX01OAM002 + oam_image_name: MOG_BASE_8.0 + oam_flavor_name: m3.xlarge + sm_server_names: ZRDM1MOGX01MSM001,ZRDM1MOGX01MSM002 + sm_image_name: MOG_BASE_8.0 + sm_flavor_name: m2.xlarge4 + ps_server_names: ZRDM1MOGX01MPS001,ZRDM1MOGX01MPS002,ZRDM1MOGX01MPS003,ZRDM1MOGX01MPS004 + ps_image_name: MOG_BASE_8.0 + ps_flavor_name: m3.xlarge + cm_server_names: ZRDM1MOGX01MCM001 + cm_image_name: MOG_BASE_8.0 + cm_flavor_name: m3.xlarge + availabilityzone_name: nova + oam_net_name: oam_protected_net_0 + oam_net_ips: 107.250.172.213,107.250.172.214,107.250.172.215,107.250.172.216,107.250.172.217 + #internet_net_name: dmz_protected_net_0 + #internet_net_ips: 107.239.53.4,107.239.53.5 + # internet_net_floating_ip: 107.239.53.6 + sl_net_name: exn_protected_net_0 + sl_net_ips: 107.239.45.4,107.239.45.5 + sl_net_floating_ip: 107.239.45.6 + repl_net_name: cor_direct_net_0 + repl_net_ips: 107.239.33.57,107.239.33.58 + rx_net_name: cor_direct_net_1 + rx_net_ips: 107.239.34.3,107.239.34.4 + rx_net_floating_ip: 107.239.34.5 + ran_net_name: gn_direct_net_0 + ran_net_ips: 107.239.36.3,107.239.36.4 + ran_net_floating_ip: 107.239.36.5 + dummy_net_name_0: mog_dummy_0 + dummy_net_start_0: 169.254.1.4 + dummy_net_end_0: 169.254.1.254 + dummy_net_cidr_0: 169.254.1.0/24 + dummy_net_netmask_0: 255.255.255.0 + dummy_net_name_1: mog_dummy_1 + dummy_net_start_1: 169.254.2.4 + dummy_net_end_1: 169.254.2.254 + dummy_net_cidr_1: 169.254.2.0/24 + dummy_net_netmask_1: 255.255.255.0 + csb_net_name: int_mog_csb_net + csb_net_ips: 172.26.0.10,172.26.0.11,172.26.0.12,172.26.0.13,172.26.0.14,172.26.0.15,172.26.0.16,172.26.0.17,172.26.0.18,172.26.0.19,172.26.0.20 + csb_net_start: 172.26.0.1 + csb_net_end: 172.26.0.254 + csb_net_cidr: 172.26.0.0/24 + csb_net_netmask: 255.255.255.0 + security_group_name: mog_security_group + mog_swift_container: http://10.147.38.210:8080/v1/AUTH_8e501b8121f34a6eaaf526d3305985cc/mogtestcontainer + mog_script_dir: /root + mog_script_name: http://10.147.38.210:8080/v1/AUTH_8e501b8121f34a6eaaf526d3305985cc/mogtestcontainer/mog-cloudinit.sh + mog_parameter_name: http://10.147.38.210:8080/v1/AUTH_8e501b8121f34a6eaaf526d3305985cc/mogtestcontainer + cluster-manager-vol-1: 43ccf5ba-2d50-427b-a38f-e8c7d8670eee + session-manager-vol-1: 49201898-333d-4c88-b58d-cf573b091633 + session-manager-vol-2: 4c35b5f1-ce99-4220-a6e2-cda6e2d713a0 + oam-vol-1: 0a7fcd9e-2624-401d-ac21-b0191f85ec77 + oam-vol-2: 6d169cb6-6ddc-41dc-920c-2839898a2924 + cluster-manager-vol-2: 6f92e211-2d61-487d-8f84-d2d00cea3698 diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/fullComposition/hot-mog-0108-bs1271.yml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/fullComposition/hot-mog-0108-bs1271.yml new file mode 100644 index 0000000000..85ca654ce1 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/fullComposition/hot-mog-0108-bs1271.yml @@ -0,0 +1,733 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates MOG stack + +parameters: + pd_server_names: + type: comma_delimited_list + label: PD server names + description: name of the PD instance + pd_image_name: + type: string + label: image name + description: PD image name + pd_flavor_name: + type: string + label: PD flavor name + description: flavor name of PD instance + oam_server_names: + type: comma_delimited_list + label: OAM server names + description: name of the OAM instance + oam_image_name: + type: string + label: image name + description: OAM image name + oam_flavor_name: + type: string + label: OAM flavor name + description: flavor name of OAM instance + sm_server_names: + type: comma_delimited_list + label: SM server names + description: name of the SM instance + sm_image_name: + type: string + label: image name + description: SM image name + sm_flavor_name: + type: string + label: SM flavor name + description: flavor name of SM instance + ps_server_names: + type: comma_delimited_list + label: PS server names + description: name of the PS instance + ps_image_name: + type: string + label: PS image name + description: PS image name + ps_flavor_name: + type: string + label: PS flavor name + description: flavor name of PS instance + cm_server_names: + type: comma_delimited_list + label: CM server names + description: name of the CM instance + cm_image_name: + type: string + label: image name + description: CM image name + cm_flavor_name: + type: string + label: CM flavor name + description: flavor name of CM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + oam_net_name: + type: string + label: oam network name + description: name of the oam network + oam_net_ips: + type: comma_delimited_list + label: internet network ips + description: ip of the OAM network + # internet_net_name: + # type: string + # label: internet network name + # description: id of the internet network + # internet_net_ips: + # type: comma_delimited_list + # label: internet network ips + # description: ip of the internet network + # internet_net_floating_ip: + # type: string + # label: mog internet virtual ip + # description: mog internet virtual ip + sl_net_name: + type: string + label: silver lining network name + description: id of the sl network + sl_net_ips: + type: comma_delimited_list + label: silver lining network ips + description: ips of the sl network + sl_net_floating_ip: + type: string + label: mog sl net virtual ip + description: mog sl net virtual ip + repl_net_name: + type: string + label: Replication network name + description: name of the replication network + repl_net_ips: + type: comma_delimited_list + label: repl network ips + description: ips of repl network + rx_net_name: + type: string + label: Rx network name + description: Rx network name + rx_net_ips: + type: comma_delimited_list + label: Rx network ips + description: Rx network ips + rx_net_floating_ip: + type: string + label: mog rx net virtual ip + description: mog rx net virtual ip + ran_net_name: + type: string + label: RAN network name + description: RAN network name + ran_net_ips: + type: comma_delimited_list + label: RAN network ips + description: RAN network ip + ran_net_floating_ip: + type: string + label: mog ran net virtual ip + description: mog ran net virtual ip + csb_net_name: + type: string + label: csb internal network name + description: csb internal network name + csb_net_start: + type: string + label: csb internal start + description: csb internal start + csb_net_end: + type: string + label: csb internal end + description: csb internal end + csb_net_cidr: + type: string + label: csb ineternal cidr + description: csb internal cidr + csb_net_netmask: + type: string + description: CSB internal network subnet mask + csb_net_ips: + type: comma_delimited_list + description: mog_csb_net IP addresses + dummy_net_name_0: + type: string + label: csb internal network name + description: csb internal network name + dummy_net_start_0: + type: string + label: csb internal start + description: csb internal start + dummy_net_end_0: + type: string + label: csb internal end + description: csb internal end + dummy_net_cidr_0: + type: string + label: csb ineternal cidr + description: csb internal cidr + dummy_net_netmask_0: + type: string + description: CSB internal network subnet mask + dummy_net_name_1: + type: string + label: csb internal network name + description: csb internal network name + dummy_net_start_1: + type: string + label: csb internal start + description: csb internal start + dummy_net_end_1: + type: string + label: csb internal end + description: csb internal end + dummy_net_cidr_1: + type: string + label: csb ineternal cidr + description: csb internal cidr + dummy_net_netmask_1: + type: string + description: CSB internal network subnet mask + + security_group_name: + type: string + label: security group name + description: the name of security group + cluster-manager-vol-1: + type: string + label: mog-cm-vol-1 + description: Cluster Manager volume 1 + session-manager-vol-1: + type: string + label: mog-sm-vol-1 + description: Session Manager volume 1 + session-manager-vol-2: + type: string + label: mog-sm-vol-2 + description: Session Manager volume 2 + oam-vol-1: + type: string + label: mog-oam-vol-1 + description: OAM volume 1 + oam-vol-2: + type: string + label: mog-oam-vol-2 + description: OAM volume 2 + mog_swift_container: + type: string + label: mog Config URL + description: Config URL + mog_script_dir: + type: string + label: mog Config script directory + description: Config script directory + mog_script_name: + type: string + label: mog Config script name + description: Config script name + mog_parameter_name: + type: string + label: mog script parameter name + description: Config script parameter csv file name + cluster-manager-vol-2: + type: string + label: mog-cm-vol-2 + description: Cluster Manager volume 2 with ISO image + +resources: + mog_security_group: + type: OS::Neutron::SecurityGroup + properties: + description: mog security group + name: {get_param: security_group_name} + rules: [{"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0} + ] + + csb_net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: csb_net_name} + + csb_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: csb_net_name} + network_id: { get_resource: csb_net } + cidr: { get_param: csb_net_cidr } + allocation_pools: [{"start": {get_param: csb_net_start}, "end": {get_param: csb_net_end}}] + enable_dhcp: true + + dummy_net_0: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: dummy_net_name_0} + + dummy_ip_subnet_0: + type: OS::Neutron::Subnet + properties: + name: {get_param: dummy_net_name_0} + network_id: { get_resource: dummy_net_0 } + cidr: { get_param: dummy_net_cidr_0 } + allocation_pools: [{"start": {get_param: dummy_net_start_0}, "end": {get_param: dummy_net_end_0}}] + enable_dhcp: true + + dummy_net_1: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: dummy_net_name_1} + + dummy_ip_subnet_1: + type: OS::Neutron::Subnet + properties: + name: {get_param: dummy_net_name_1} + network_id: { get_resource: dummy_net_1 } + cidr: { get_param: dummy_net_cidr_1 } + allocation_pools: [{"start": {get_param: dummy_net_start_1}, "end": {get_param: dummy_net_end_1}}] + enable_dhcp: true + + + mogconfig: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + template: | + #!/bin/bash + wget -P script_dir swift_container/script_name + wget -P script_dir swift_container/parameter_name + chmod 755 script_dir/script_name + script_dir/script_name + params: + swift_container: {get_param: mog_swift_container} + script_dir: {get_param: mog_script_dir} + script_name: {get_param: mog_script_name} + #parameter_name: {get_param: mog_parameter_name} + + + servergroup_mog01: + type: OS::Nova::ServerGroup + properties: + policies: + - anti-affinity + server_pd_01: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [pd_server_names, 0]} + image: {get_param: pd_image_name} + flavor: {get_param: pd_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: pd01_port_0} + - port: {get_resource: pd01_port_1} + - port: {get_resource: pd01_port_2} + - port: {get_resource: pd01_port_3} + - port: {get_resource: pd01_port_4} + - port: {get_resource: pd01_port_5} + - port: {get_resource: pd01_port_6} + # - port: {get_resource: pd01_port_7} + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog01}} + user_data_format: RAW + + + pd01_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + pd01_port_1: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [oam_net_ips, 0]}}] + security_groups: [{get_resource: mog_security_group}] + pd01_port_2: + type: OS::Neutron::Port + properties: + network: {get_resource: dummy_net_0} + security_groups: [{get_resource: mog_security_group}] + pd01_port_3: + type: OS::Neutron::Port + properties: + network: {get_param: rx_net_name} + fixed_ips: [{"ip_address": {get_param: [rx_net_ips, 0]}}] + allowed_address_pairs: [{"ip_address": {get_param: rx_net_floating_ip} }] + security_groups: [{get_resource: mog_security_group}] + pd01_port_4: + type: OS::Neutron::Port + properties: + network: {get_resource: dummy_net_1} + security_groups: [{get_resource: mog_security_group}] + pd01_port_5: + type: OS::Neutron::Port + properties: + network: {get_param: ran_net_name} + fixed_ips: [{"ip_address": {get_param: [ran_net_ips, 0]}}] + allowed_address_pairs: [{"ip_address": {get_param: ran_net_floating_ip} }] + security_groups: [{get_resource: mog_security_group}] + + pd01_port_6: + type: OS::Neutron::Port + properties: + network: {get_param: sl_net_name} + fixed_ips: [{"ip_address": {get_param: [sl_net_ips, 0]}}] + allowed_address_pairs: [{"ip_address": {get_param: sl_net_floating_ip}}] + security_groups: [{get_resource: mog_security_group}] + + # pd01_port_7: + #j type: OS::Neutron::Port + # properties: + # network: {get_param: internet_net_name} + # fixed_ips: [{"ip_address": {get_param: [internet_net_ips, 0]}}] + # allowed_address_pairs: [{"ip_address": {get_param: internet_net_floating_ip} }] + # security_groups: [{get_resource: mog_security_group}] + + server_pd_02: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [pd_server_names, 1]} + image: {get_param: pd_image_name} + flavor: {get_param: pd_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: pd02_port_0} + - port: {get_resource: pd02_port_1} + - port: {get_resource: pd02_port_2} + - port: {get_resource: pd02_port_3} + - port: {get_resource: pd02_port_4} + - port: {get_resource: pd02_port_5} + - port: {get_resource: pd02_port_6} + # - port: {get_resource: pd02_port_7} + + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog01}} + user_data_format: RAW + + pd02_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + pd02_port_1: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [oam_net_ips, 1]}}] + security_groups: [{get_resource: mog_security_group}] + + pd02_port_2: + type: OS::Neutron::Port + properties: + network: {get_resource: dummy_net_0} + security_groups: [{get_resource: mog_security_group}] + + pd02_port_3: + type: OS::Neutron::Port + properties: + network: {get_param: rx_net_name} + fixed_ips: [{"ip_address": {get_param: [rx_net_ips, 1]}}] + allowed_address_pairs: [{"ip_address": {get_param: rx_net_floating_ip} }] + security_groups: [{get_resource: mog_security_group}] + + pd02_port_4: + type: OS::Neutron::Port + properties: + network: {get_resource: dummy_net_1} + security_groups: [{get_resource: mog_security_group}] + + pd02_port_5: + type: OS::Neutron::Port + properties: + network: {get_param: ran_net_name} + fixed_ips: [{"ip_address": {get_param: [ran_net_ips, 1]}}] + allowed_address_pairs: [{"ip_address": {get_param: ran_net_floating_ip} }] + security_groups: [{get_resource: mog_security_group}] + + pd02_port_6: + type: OS::Neutron::Port + properties: + network: {get_param: sl_net_name} + fixed_ips: [{"ip_address": {get_param: [sl_net_ips, 1]}}] + allowed_address_pairs: [{"ip_address": {get_param: sl_net_floating_ip}}] + security_groups: [{get_resource: mog_security_group}] + + # pd02_port_7: + # type: OS::Neutron::Port + # properties: + # network: {get_param: internet_net_name} + # fixed_ips: [{"ip_address": {get_param: [internet_net_ips, 1]}}] + # allowed_address_pairs: [{"ip_address": {get_param: internet_net_floating_ip} }] + # security_groups: [{get_resource: mog_security_group}] + + servergroup_mog02: + type: OS::Nova::ServerGroup + properties: + policies: + - anti-affinity + server_oam01: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [oam_server_names, 0]} + image: {get_param: oam_image_name} + flavor: {get_param: oam_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: oam01_port_0} + - port: {get_resource: oam01_port_1} +# block_device_mapping: +# - device_name: vdd +# volume_id: { get_param: oam-vol-1 } + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog02}} + user_data_format: RAW + + oam01_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + oam01_port_1: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [oam_net_ips, 2]}}] + security_groups: [{get_resource: mog_security_group}] + + + server_oam02: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [oam_server_names, 1]} + image: {get_param: oam_image_name} + flavor: {get_param: oam_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: oam02_port_0} + - port: {get_resource: oam02_port_1} +# block_device_mapping: +# - device_name: vdd +# volume_id: { get_param: oam-vol-2 } + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog02}} + user_data_format: RAW + + oam02_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + oam02_port_1: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [oam_net_ips, 3]}}] + security_groups: [{get_resource: mog_security_group}] + + + server_sm01: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [sm_server_names, 0]} + image: {get_param: sm_image_name} + flavor: {get_param: sm_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: sm01_port_0} + - port: {get_resource: sm01_port_1} +# block_device_mapping: +# - device_name: vdd +# volume_id: { get_param: session-manager-vol-1 } + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog02}} + user_data_format: RAW + + sm01_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + sm01_port_1: + type: OS::Neutron::Port + properties: + network: {get_resource: dummy_net_0} + security_groups: [{get_resource: mog_security_group}] + + sm01_port_2: + type: OS::Neutron::Port + properties: + network: {get_param: repl_net_name} + fixed_ips: [{"ip_address": {get_param: [repl_net_ips, 0]}}] + security_groups: [{get_resource: mog_security_group}] + + server_sm02: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [sm_server_names, 1]} + image: {get_param: sm_image_name} + flavor: {get_param: sm_flavor_name} + availability_zone: {get_param: availabilityzone_name} +# block_device_mapping: +# - device_name: vdd +# volume_id: { get_param: session-manager-vol-2 } + networks: + - port: {get_resource: sm02_port_0} + - port: {get_resource: sm02_port_1} + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog02}} + user_data_format: RAW + + sm02_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + sm02_port_1: + type: OS::Neutron::Port + properties: + network: {get_resource: dummy_net_0} + security_groups: [{get_resource: mog_security_group}] + + sm02_port_2: + type: OS::Neutron::Port + properties: + network: {get_param: repl_net_name} + fixed_ips: [{"ip_address": {get_param: [repl_net_ips, 1]}}] + security_groups: [{get_resource: mog_security_group}] + + servergroup_mog03: + type: OS::Nova::ServerGroup + properties: + policies: + - anti-affinity + server_ps01: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [ps_server_names, 0]} + image: {get_param: ps_image_name} + flavor: {get_param: ps_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: ps01_port_0} + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog03}} + user_data_format: RAW + + ps01_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + server_ps02: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [ps_server_names, 1]} + image: {get_param: ps_image_name} + flavor: {get_param: ps_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: ps02_port_0} + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog03}} + user_data_format: RAW + + ps02_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + server_ps03: + type: OS::Nova::Server + properties: + name: {get_param: [ps_server_names, 2]} + image: {get_param: ps_image_name} + flavor: {get_param: ps_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: ps03_port_0} + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog03}} + user_data_format: RAW + + ps03_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + server_ps04: + type: OS::Nova::Server + properties: + name: {get_param: [ps_server_names, 3]} + image: {get_param: ps_image_name} + flavor: {get_param: ps_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: ps04_port_0} + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog03}} + user_data_format: RAW + + ps04_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + server_cm01: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [cm_server_names, 0]} + image: {get_param: cm_image_name} + flavor: {get_param: cm_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: cm01_port_0} + - port: {get_resource: cm01_port_1} +# block_device_mapping: +# - device_name: vdd +# volume_id: { get_param: cluster-manager-vol-2 } +# - device_name: vde +# volume_id: { get_param: cluster-manager-vol-1 } + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog03}} + user_data_format: RAW + + cm01_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + fixed_ips: [{"ip_address": {get_param: [csb_net_ips, 10]}}] + security_groups: [{get_resource: mog_security_group}] + + cm01_port_1: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [oam_net_ips, 4]}}] + security_groups: [{get_resource: mog_security_group}] + diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/MANIFEST.json b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/MANIFEST.json new file mode 100644 index 0000000000..6b48646d70 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/MANIFEST.json @@ -0,0 +1,42 @@ +{ + "name": "multiple_not_nested", + "description": "multiple heat files in zip, no nesting", + "version": "2013-05-23", + "data": [{ + "file": "cmaui.yml", + "type": "HEAT", + "data": [{ + "file": "cmaui.env", + "type": "HEAT_ENV" + }] + }, + { + "file": "eca_oam.yaml", + "type": "AAA", + "data": [{ + "file": "eca_oam.env", + "type": "AAA" + }] + }, + { + "file": "eca_oam_2.yaml", + "type": "AAA" + }, + { + "file": "MMSC_Capacity_Line.yml", + "type": "HEAT", + "data": [{ + "file": "MMSC_Capacity_Line_1.env", + "type": "HEAT_ENV" + }] + }, + { + "file": "SG_ECA_MGMT.yaml", + "type": "HEAT", + "data": [{ + "file": "sg_eca_mgmt.env", + "type": "HEAT_ENV" + }] + } + ] +} \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/MMSC_Capacity_Line.yml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/MMSC_Capacity_Line.yml new file mode 100644 index 0000000000..3b0bc56e09 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/MMSC_Capacity_Line.yml @@ -0,0 +1,3223 @@ +heat_template_version: 2013-05-23 + +description: > + HOT template that creates internal networks, load balancers and servers for vMMSC capacity Line 1. + #11/23: updated the network definition to meet the juniper best practices way of defining the gateway, DHCP enable for internal networks (L457-L547) + +parameters: + vnf_id: + type: string + description: Unique ID for this VNF instance + default: This_is_the_MMSC_id + oam_net_name: + type: string + label: UID of OAM network + description: UID of OAM network + oam_network_netmask: + type: string + label: oam network netmask + description: oam network gateway + oam_network_gateway: + type: string + label: oam network gateway + description: oam network gateway + oam_network_route_1: + type: string + label: oam network route 1 + description: oam network route 1 + oam_network_route_2: + type: string + label: oam network route 2 + description: oam network route 2 + external_dns: + type: string + label: dns server + description: dns server for MMSC + external_ntp: + type: string + label: ntp server + description: ntp server for MMSC + lb_oam_ips: + type: comma_delimited_list + label: management network ips for mmsc lb + description: the ips of the management network for mmsc lb + dmz_protected_net_name: + type: string + label: UID of dmz_protected network + description: UID of dmz_protected network + lb_dmz_protected_ips: + type: comma_delimited_list + label: dmz protected network local ips for lb VM + description: local ips of the dmz protected network for lb VM + cor_direct_net_name: + type: string + label: cor direct net UID + description: cor direct net + lb_cor_direct_ips: + type: comma_delimited_list + label: cor direct network local ips for lb VM + description: local ips of cor direct network for lb VM + mms_traffic_net_name: + type: string + label: Name of MMS traffic network + description: Name of MMS traffic network + mms_traffic_net_cidr: + type: string + label: MMS traffic network address (CIDR notation) + description: MMS traffic network address (CIDR notation) + mms_traffic_netmask: + type: string + label: MMS traffic network subnet mask + description: MMS traffic network subnet mask + mms_traffic_net_gateway: + type: string + label: MMS traffic network gateway address + description: MMS traffic network gateway address + mms_traffic_start: + type: string + label: mmsc traffic start IP + description: mmsc traffic start IP + mms_traffic_end: + type: string + label: mmsc traffic end IP + description: mmsc traffic end IP + mms_traffic_net_cidr: + type: string + label: mmsc traffic cidr + description: mmsc traffic cidr + mms_traffic_net_local_ip1: + type: string + label: mmsc traffic network local ip1 + description: the local ip1 of the mmsc traffic network + mms_traffic_net_local_ip2: + type: string + label: mmsc traffic network local ip2 + description: the local ip2 of the mmsc traffic network + mms_traffic_net_floating_ip: + type: string + label: mmsc traffic floating ip + description: mmsc traffic floating ip + nems_internal_name: + type: string + label: nems internal network name + description: nems internal network name + nems_internal_start: + type: string + label: nems internal start + description: nems internal start + nems_internal_end: + type: string + label: nems internal end + description: nems internal end + nems_internal_cidr: + type: string + label: nems ineternal cidr + description: nems internal cidr + nems_internal_netmask: + type: string + label: NEMS internal network subnet mask + description: NEMS internal network subnet mask + nems_internal_gateway: + type: string + label: nems internal gw + description: nems internal gw + nems_traffic_name: + type: string + label: nems traffic name + description: nems traffic name + nems_traffic_start: + type: string + label: nems traffic start + description: nems traffic start + nems_traffic_end: + type: string + label: nems traffic end + description: nems traffic end + nems_traffic_cidr: + type: string + label: nems traffic cidr + description: nems traffic cidr + nems_traffic_netmask: + type: string + label: NEMS traffic network subnet mask + description: NEMS traffic network subnet mask + nems_traffic_gateway: + type: string + label: NEMS traffic network gateway + description: NEMS traffic network gateway + nems_traffic_net_local_ip1: + type: string + label: nems traffic network local ip1 + description: the local ip1 of the nems traffic network + nems_traffic_net_local_ip2: + type: string + label: nems traffic network local ip2 + description: the local ip2 of the nems traffic network + nems_traffic_net_floating_ip: + type: string + label: nems traffic floating ip + description: nems traffic floating ip + nems_user_web_name: + type: string + label: nems user web name + description: nems user web name + nems_user_web_start: + type: string + label: nems user web start + description: nems user web end + nems_user_web_end: + type: string + label: nems user web end + description: nems user web end + nems_user_web_cidr: + type: string + label: nems user web cidr + description: nems user web cidr + nems_user_web_netmask: + type: string + label: NEMS user web network subnet mask + description: NEMS user web network subnet mask + nems_user_web_gateway: + type: string + label: NEMS user web network gateway + description: NEMS user web network gateway + nems_user_web_net_local_ip1: + type: string + label: nems user web network local ip1 + description: the local ip1 of the nems user web network + nems_user_web_net_local_ip2: + type: string + label: nems user web network local ip2 + description: the local ip2 of the nems user web network + nems_user_web_net_floating_ip: + type: string + label: nems user web floating ip + description: nems user web floating ip + nems_imap_name: + type: string + label: nems imap name + description: nems imap name + nems_imap_netmask: + type: string + label: nems imap subnet mask + description: nems imap subnet mask + nems_imap_start: + type: string + label: nems imap start + description: nems imap start + nems_imap_end: + type: string + label: nems imap end + description: nems imap end + nems_imap_cidr: + type: string + label: nems imap cidr + description: nems imap cidr + nems_imap_gateway: + type: string + label: nems imap gateway + description: nems imap gateway + eca_traffic_name: + type: string + label: eca traffic name + description: eca traffic name + eca_traffic_start: + type: string + label: eca traffic start + description: eca traffic start + eca_traffic_end: + type: string + label: eca traffic end + description: eca traffic end + eca_traffic_cidr: + type: string + label: eca traffic cidr + description: eca traffic cidr + eca_traffic_netmask: + type: string + label: ECA traffic network subnet mask + description: ECA traffic network subnet mask + eca_traffic_net_gateway: + type: string + label: eca_traffic network gateway + description: eca_traffic network gateway + eca_traffic_net_local_ip1: + type: string + label: eca traffic network local ip1 + description: the local ip1 of the eca traffic network + eca_traffic_net_local_ip2: + type: string + label: eca traffic network local ip2 + description: the local ip2 of the eca traffic network + eca_traffic_net_floating_ip: + type: string + label: eca traffic floating ip + description: eca traffic floating ip + ha_net_name: + type: string + label: ha_failover network name + description: ha_failover network name + ha_net_start: + type: string + label: ha net start + description: ha net start + ha_net_end: + type: string + label: ha net end + description: ha net end + ha_net_cidr: + type: string + label: ha net cidr + description: ha net cidr + ha_net_local_ip1: + type: string + label: ha net network local ip1 + description: the local ip1 of the ha network + ha_net_local_ip2: + type: string + label: ha net network local ip2 + description: the local ip2 of the ha network + lb_names: + type: comma_delimited_list + label: MMSC load balancer instance names + description: MMSC load balancer instance names + lb_image_name: + type: string + label: MMSC load balancer image name + description: MMSC load balancer image name + lb_flavor_name: + type: string + label: Load balancer flavor name + description: the flavor name of MMSC load balancer instance + availability_zone_0: + type: string + label: MMSC availabilityzone name + description: MMSC availabilityzone name + security_group_name: + type: string + label: MMSC security group name + description: MMSC security group name + mmsc_image: + type: string + label: Image for MMSC server + description: Image for MMSC server + mmsc_flavor: + type: string + label: Flavor for MMSC server + description: Flavor for MMSC server + mmsc_cinder_volume_size: + type: number + label: MMSC Cinder volume size + description: the size of the MMSC Cinder volume + nems_fe_image: + type: string + label: Image for NEMS FE server + description: Image for NEMS FE server + nems_fe_flavor: + type: string + label: Flavor for NEMS FE server + description: Flavor for NEMS FE server + nems_be_image: + type: string + label: Image for NEMS BE server + description: Image for NEMS BE server + nems_be_flavor: + type: string + label: Flavor for NEMS BE server + description: Flavor for NEMS BE server + eca_trx_image: + type: string + label: Image for ECA TRX server + description: Image for ECA TRX server + eca_trx_flavor: + type: string + label: Flavor for ECA TRX server + description: Flavor for ECA TRX server + mmsc_oam_ips: + type: comma_delimited_list + label: MMSC oam_net IP addresses + description: MMSC oam_net IP addresses + mmsc_mms_traffic_net_ips: + type: comma_delimited_list + label: MMSC mms_traffic_net IP addresses + description: MMSC mms_traffic_net IP addresses + nems_fe_names: + type: comma_delimited_list + label: NEMS_FE server names + description: NEMS_FE server names + nems_fe_node_roles: + type: comma_delimited_list + label: nems fe node roles + description: nems fe node roles + nems_fe_oam_ips: + type: comma_delimited_list + label: OAM_net IP for NEMS_FE + description: OAM_net IP for NEMS_FE + nems_fe_nems_traffic_net_ips: + type: comma_delimited_list + label: nems_traffic_net IPs for NEMS_FE + description: nems_traffic_net IPs for NEMS_FE + nems_fe_nems_user_web_net_ips: + type: comma_delimited_list + label: nems_web_user_net IPs for NEMS_FE + description: nems_web_user_net IPs for NEMS_FE + nems_fe_nems_internal_net_ips: + type: comma_delimited_list + label: nems_internal_net IPs for NEMS_FE + description: nems_internal_net IPs for NEMS_FE + nems_fe_nems_imap_net_ips: + type: comma_delimited_list + label: nems_imap_net IPs for NEMS_FE + description: nems_imap_net IPs for NEMS_FE + nems_be_names: + type: string + label: NEMS_BE server names + description: NEMS_BE server names + nems_be_node_roles: + type: string + label: nems node roles + description: nems node roles + nems_be_oam_ips: + type: string + label: OAM net IPs for NEMS_BE + description: OAM net IPs for NEMS_BE + nems_be_nems_internal_net_ips: + type: string + label: nems internal net IPs for NEMS_BE + description: nems internal net IPs for NEMS_BE + nems_be_nems_imap_net_ips: + type: string + label: nems imap_net IPs for NEMS_BE + description: nems imap net IPs for NEMS_BE + eca_trx_oam_ips: + type: comma_delimited_list + label: OAM net IP for ECA_TRX + description: OAM net IP for ECA_TRX + eca_trx_mgmt_ips: + type: comma_delimited_list + label: eca mgmt net IP for ECA_TRX + description: eca mgmt net IP for ECA_TRX + timezone: + type: string + label: timezone + description: timezone + eca_trx_names: + type: comma_delimited_list + label: ECA_TRX server names + description: ECA_TRX server names + eca_trx_eca_traffic_net_ips: + type: comma_delimited_list + label: eca traffic net IPs for ECA_TRX + description: eca traffic net IPs for ECA_TRX + mmsc_names: + type: comma_delimited_list + label: MMSC server names + description: MMSC server names + nems_volume_size: + type: number + label: nems fe volume size + description: nems fe volume size + nems_be_volume_size: + type: number + label: nems be volume size + description: nems be volume size + MMSC_volume_type: + type: string + label: MMSC vm volume type + description: the name of the target volume backend + NEMS_FE_volume_type: + type: string + label: nems fe vm volume type + description: the name of the target volume backend + NEMS_BE_volume_type: + type: string + label: nems be vm volume type + description: the name of the target volume backend + mmsc_core_virtual_server_ips: + type: comma_delimited_list + label: mmsc core virtual server ips + description: mmsc core virtual server ips + mmsc_core_snat_ips: + type: comma_delimited_list + label: mmsc core snat ips + description: mmsc core snat ips + mmsc_dmz_protected_virtual_server_ips: + type: comma_delimited_list + label: mmsc dmz_protected virtual server ips + description: mmsc dmz_protected virtual server ips + mmsc_dmz_protected_snat_ips: + type: comma_delimited_list + label: mmsc dmz_protected snat ips + description: mmsc dmz_protected snat ips + eca_mgmt_net_name: + type: string + label: eca management network ID + description: Network ID for eca management + +resources: + mms_traffic_net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: mms_traffic_net_name } + + mms_traffic_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: mms_traffic_net_name} + network_id: { get_resource: mms_traffic_net } + cidr: { get_param: mms_traffic_net_cidr } + allocation_pools: [{"start": {get_param: mms_traffic_start}, "end": {get_param: mms_traffic_end}}] + + nems_internal_net: + type: OS::Contrail::VirtualNetwork + properties: + name: {get_param: nems_internal_name} + + nems_internal_network_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: nems_internal_name} + allocation_pools: [{"start": {get_param: nems_internal_start}, "end": {get_param: nems_internal_end}}] + cidr: {get_param: nems_internal_cidr} + network_id: {get_resource: nems_internal_net} + + nems_traffic_net: + type: OS::Contrail::VirtualNetwork + properties: + name: {get_param: nems_traffic_name} + + nems_traffic_network_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: nems_traffic_name} + allocation_pools: [{"start": {get_param: nems_traffic_start}, "end": {get_param: nems_traffic_end}}] + cidr: {get_param: nems_traffic_cidr} + network_id: {get_resource: nems_traffic_net} + + nems_user_web_net: + type: OS::Contrail::VirtualNetwork + properties: + name: {get_param: nems_user_web_name} + + nems_user_web_network_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: nems_user_web_name} + allocation_pools: [{"start": {get_param: nems_user_web_start}, "end": {get_param: nems_user_web_end}}] + cidr: {get_param: nems_user_web_cidr} + network_id: {get_resource: nems_user_web_net} + + nems_imap_net: + type: OS::Contrail::VirtualNetwork + properties: + name: {get_param: nems_imap_name} + + nems_imap_network_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: nems_imap_name} + allocation_pools: [{"start": {get_param: nems_imap_start}, "end": {get_param: nems_imap_end}}] + cidr: {get_param: nems_imap_cidr} + network_id: {get_resource: nems_imap_net} + + eca_traffic_net: + type: OS::Contrail::VirtualNetwork + properties: + name: {get_param: eca_traffic_name} + + eca_traffic_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: eca_traffic_name} + allocation_pools: [{"start": {get_param: eca_traffic_start}, "end": {get_param: eca_traffic_end}}] + cidr: {get_param: eca_traffic_cidr} + network_id: {get_resource: eca_traffic_net} + + ha_net: + type: OS::Contrail::VirtualNetwork + properties: + name: {get_param: ha_net_name} + + ha_net_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: ha_net_name} + allocation_pools: [{"start": {get_param: ha_net_start}, "end": {get_param: ha_net_end}}] + cidr: {get_param: ha_net_cidr} + network_id: {get_resource: ha_net} + + lb1_instance: + type: OS::Nova::Server + properties: + name: {get_param: [lb_names, 0]} + image: {get_param: lb_image_name} + flavor: {get_param: lb_flavor_name} + availability_zone: {get_param: availability_zone_0} + networks: + - port: {get_resource: lb1_mgmt_port} + - port: {get_resource: lb1_dmz_protected_port} + - port: {get_resource: lb1_cor_direct_port} + - port: {get_resource: lb1_mms_traffic_port} + - port: {get_resource: lb1_nems_traffic_port} + - port: {get_resource: lb1_nems_user_web_port} + - port: {get_resource: lb1_eca_traffic_port} + - port: {get_resource: lb1_ha_net_port} + metadata: + vnf_id: { get_param: vnf_id } + + lb1_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [lb_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb1_mms_traffic_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: mms_traffic_net} + fixed_ips: [{"ip_address": {get_param: mms_traffic_net_local_ip1}}] + allowed_address_pairs: [{"ip_address": {get_param: mms_traffic_net_floating_ip} }] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb1_dmz_protected_port: + type: OS::Neutron::Port + properties: + network: {get_param: dmz_protected_net_name} + fixed_ips: [{"ip_address": {get_param: [lb_dmz_protected_ips, 0]}}] + allowed_address_pairs: [{"ip_address": {get_param: [mmsc_dmz_protected_virtual_server_ips, 0]}}, {"ip_address": {get_param: [mmsc_dmz_protected_virtual_server_ips, 1]}}, {"ip_address": {get_param: [mmsc_dmz_protected_virtual_server_ips, 2]}}, {"ip_address": {get_param: [mmsc_dmz_protected_snat_ips, 0]}}, {"ip_address": {get_param: [mmsc_dmz_protected_snat_ips, 1]}}, {"ip_address": {get_param: [mmsc_dmz_protected_snat_ips, 2]}}, {"ip_address": {get_param: [mmsc_dmz_protected_snat_ips, 3]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb1_cor_direct_port: + type: OS::Neutron::Port + properties: + network: {get_param: cor_direct_net_name} + fixed_ips: [{"ip_address": {get_param: [lb_cor_direct_ips, 0]}}] + allowed_address_pairs: [{"ip_address": {get_param: [mmsc_core_virtual_server_ips, 0]}}, {"ip_address": {get_param: [mmsc_core_virtual_server_ips, 1]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 0]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 1]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 2]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 3]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 4]}} ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb1_nems_traffic_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: nems_traffic_net} + fixed_ips: [{"ip_address": {get_param: nems_traffic_net_local_ip1}}] + allowed_address_pairs: [{"ip_address": {get_param: nems_traffic_net_floating_ip} }] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb1_nems_user_web_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: nems_user_web_net} + fixed_ips: [{"ip_address": {get_param: nems_user_web_net_local_ip1}}] + allowed_address_pairs: [{"ip_address": {get_param: nems_user_web_net_floating_ip} }] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb1_ha_net_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: ha_net} + fixed_ips: [{"ip_address": {get_param: ha_net_local_ip1}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb1_eca_traffic_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: eca_traffic_net} + fixed_ips: [{"ip_address": {get_param: eca_traffic_net_local_ip1}}] + allowed_address_pairs: [{"ip_address": {get_param: eca_traffic_net_floating_ip} }] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb2_instance: + type: OS::Nova::Server + properties: + name: {get_param: [lb_names, 1]} + image: {get_param: lb_image_name} + flavor: {get_param: lb_flavor_name} + availability_zone: {get_param: availability_zone_0} + networks: + - port: {get_resource: lb2_mgmt_port} + - port: {get_resource: lb2_dmz_protected_port} + - port: {get_resource: lb2_cor_direct_port} + - port: {get_resource: lb2_mms_traffic_port} + - port: {get_resource: lb2_nems_traffic_port} + - port: {get_resource: lb2_nems_user_web_port} + - port: {get_resource: lb2_eca_traffic_port} + - port: {get_resource: lb2_ha_net_port} + metadata: + vnf_id: { get_param: vnf_id } + + lb2_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [lb_oam_ips, 1]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb2_mms_traffic_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: mms_traffic_net} + fixed_ips: [{"ip_address": {get_param: mms_traffic_net_local_ip2}}] + allowed_address_pairs: [{"ip_address": {get_param: mms_traffic_net_floating_ip}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb2_dmz_protected_port: + type: OS::Neutron::Port + properties: + network: {get_param: dmz_protected_net_name} + fixed_ips: [{"ip_address": {get_param: [lb_dmz_protected_ips, 1]}}] + allowed_address_pairs: [{"ip_address": {get_param: [mmsc_dmz_protected_virtual_server_ips, 0]}}, {"ip_address": {get_param: [mmsc_dmz_protected_virtual_server_ips, 1]}}, {"ip_address": {get_param: [mmsc_dmz_protected_virtual_server_ips, 2]}}, {"ip_address": {get_param: [mmsc_dmz_protected_snat_ips, 0]}}, {"ip_address": {get_param: [mmsc_dmz_protected_snat_ips, 1]}}, {"ip_address": {get_param: [mmsc_dmz_protected_snat_ips, 2]}}, {"ip_address": {get_param: [mmsc_dmz_protected_snat_ips, 3]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb2_cor_direct_port: + type: OS::Neutron::Port + properties: + network: {get_param: cor_direct_net_name} + fixed_ips: [{"ip_address": {get_param: [lb_cor_direct_ips, 1]}}] + allowed_address_pairs: [{"ip_address": {get_param: [mmsc_core_virtual_server_ips, 0]}}, {"ip_address": {get_param: [mmsc_core_virtual_server_ips, 1]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 0]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 1]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 2]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 3]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 4]}} ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb2_nems_traffic_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: nems_traffic_net} + fixed_ips: [{"ip_address": {get_param: nems_traffic_net_local_ip2}}] + allowed_address_pairs: [{"ip_address": {get_param: nems_traffic_net_floating_ip}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb2_nems_user_web_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: nems_user_web_net} + fixed_ips: [{"ip_address": {get_param: nems_user_web_net_local_ip2}}] + allowed_address_pairs: [{"ip_address": {get_param: nems_user_web_net_floating_ip}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb2_ha_net_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: ha_net} + fixed_ips: [{"ip_address": {get_param: ha_net_local_ip2}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb2_eca_traffic_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: eca_traffic_net} + fixed_ips: [{"ip_address": {get_param: eca_traffic_net_local_ip2}}] + allowed_address_pairs: [{"ip_address": {get_param: eca_traffic_net_floating_ip} }] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_mmsc1: + type: OS::Nova::Server + properties: + name: { get_param: [mmsc_names, 0]} + image: { get_param: mmsc_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: mmsc_flavor } + networks: + - port: { get_resource: mmsc1_port_0 } + - port: { get_resource: mmsc1_port_1 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + mmsc.mgmt.ip=${mmsc.mgmt.ip} + mmsc.mgmt.netmask=${mmsc.mgmt.netmask} + mmsc.mgmt.gateway=${mmsc.mgmt.gateway} + mmsc.traffic.ip=${mmsc.traffic.ip} + mmsc.traffic.netmask=${mmsc.traffic.netmask} + mmsc.traffic.gateway=${mmsc.traffic.gateway} + mmsc.mgmt.route.1=${mmsc.mgmt.route.1} + mmsc.mgmt.route.2=${mmsc.mgmt.route.2} + mmsc.external.dns=${mmsc.external.dns} + mmsc.external.ntp=${mmsc.external.ntp} + mmsc.hostname=${mmsc.hostname} + mmsc.timezone=${mmsc.timezone} + params: + ${mmsc.mgmt.ip}: {get_param: [mmsc_oam_ips, 0]} + ${mmsc.mgmt.netmask}: {get_param: oam_network_netmask} + ${mmsc.mgmt.gateway}: {get_param: oam_network_gateway} + ${mmsc.traffic.ip}: {get_param: [mmsc_mms_traffic_net_ips, 0]} + ${mmsc.traffic.netmask}: {get_param: mms_traffic_netmask} + ${mmsc.traffic.gateway}: {get_param: mms_traffic_net_gateway} + ${mmsc.mgmt.route.1}: {get_param: oam_network_route_1} + ${mmsc.mgmt.route.2}: {get_param: oam_network_route_2} + ${mmsc.external.dns}: {get_param: external_dns} + ${mmsc.external.ntp}: {get_param: external_ntp} + ${mmsc.hostname}: {get_param: [mmsc_names, 0]} + ${mmsc.timezone}: {get_param: timezone} + user_data_format: RAW + + mmsc1_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: mmsc_cinder_volume_size} + volume_type: {get_param: MMSC_volume_type} + + mmsc1_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: mmsc1_volume} + instance_uuid: {get_resource: server_mmsc1} + + mmsc1_port_0: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [ + "ip_address": {get_param: [mmsc_oam_ips, 0]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + mmsc1_port_1: + type: OS::Neutron::Port + properties: + network_id: {get_resource: mms_traffic_net} + fixed_ips: [ + "ip_address": {get_param: [mmsc_mms_traffic_net_ips, 0]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_mmsc2: + type: OS::Nova::Server + properties: + name: { get_param: [mmsc_names, 1]} + image: { get_param: mmsc_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: mmsc_flavor } + networks: + - port: { get_resource: mmsc2_port_0 } + - port: { get_resource: mmsc2_port_1 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + mmsc.mgmt.ip=${mmsc.mgmt.ip} + mmsc.mgmt.netmask=${mmsc.mgmt.netmask} + mmsc.mgmt.gateway=${mmsc.mgmt.gateway} + mmsc.traffic.ip=${mmsc.traffic.ip} + mmsc.traffic.netmask=${mmsc.traffic.netmask} + mmsc.traffic.gateway=${mmsc.traffic.gateway} + mmsc.mgmt.route.1=${mmsc.mgmt.route.1} + mmsc.mgmt.route.2=${mmsc.mgmt.route.2} + mmsc.external.dns=${mmsc.external.dns} + mmsc.external.ntp=${mmsc.external.ntp} + mmsc.hostname=${mmsc.hostname} + mmsc.timezone=${mmsc.timezone} + params: + ${mmsc.mgmt.ip}: {get_param: [mmsc_oam_ips, 1]} + ${mmsc.mgmt.netmask}: {get_param: oam_network_netmask} + ${mmsc.mgmt.gateway}: {get_param: oam_network_gateway} + ${mmsc.traffic.ip}: {get_param: [mmsc_mms_traffic_net_ips, 1]} + ${mmsc.traffic.netmask}: {get_param: mms_traffic_netmask} + ${mmsc.traffic.gateway}: {get_param: mms_traffic_net_gateway} + ${mmsc.mgmt.route.1}: {get_param: oam_network_route_1} + ${mmsc.mgmt.route.2}: {get_param: oam_network_route_2} + ${mmsc.external.dns}: {get_param: external_dns} + ${mmsc.external.ntp}: {get_param: external_ntp} + ${mmsc.hostname}: {get_param: [mmsc_names, 1]} + ${mmsc.timezone}: {get_param: timezone} + user_data_format: RAW + + mmsc2_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: mmsc_cinder_volume_size} + volume_type: {get_param: MMSC_volume_type} + + mmsc2_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: mmsc2_volume} + instance_uuid: {get_resource: server_mmsc2} + + mmsc2_port_0: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [ + "ip_address": {get_param: [mmsc_oam_ips, 1]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + mmsc2_port_1: + type: OS::Neutron::Port + properties: + network_id: {get_resource: mms_traffic_net} + fixed_ips: [ + "ip_address": {get_param: [mmsc_mms_traffic_net_ips, 1]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_mmsc3: + type: OS::Nova::Server + properties: + name: { get_param: [mmsc_names, 2]} + image: { get_param: mmsc_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: mmsc_flavor } + networks: + - port: { get_resource: mmsc3_port_0 } + - port: { get_resource: mmsc3_port_1 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + mmsc.mgmt.ip=${mmsc.mgmt.ip} + mmsc.mgmt.netmask=${mmsc.mgmt.netmask} + mmsc.mgmt.gateway=${mmsc.mgmt.gateway} + mmsc.traffic.ip=${mmsc.traffic.ip} + mmsc.traffic.netmask=${mmsc.traffic.netmask} + mmsc.traffic.gateway=${mmsc.traffic.gateway} + mmsc.mgmt.route.1=${mmsc.mgmt.route.1} + mmsc.mgmt.route.2=${mmsc.mgmt.route.2} + mmsc.external.dns=${mmsc.external.dns} + mmsc.external.ntp=${mmsc.external.ntp} + mmsc.hostname=${mmsc.hostname} + mmsc.timezone=${mmsc.timezone} + params: + ${mmsc.mgmt.ip}: {get_param: [mmsc_oam_ips, 2]} + ${mmsc.mgmt.netmask}: {get_param: oam_network_netmask} + ${mmsc.mgmt.gateway}: {get_param: oam_network_gateway} + ${mmsc.traffic.ip}: {get_param: [mmsc_mms_traffic_net_ips, 2]} + ${mmsc.traffic.netmask}: {get_param: mms_traffic_netmask} + ${mmsc.traffic.gateway}: {get_param: mms_traffic_net_gateway} + ${mmsc.mgmt.route.1}: {get_param: oam_network_route_1} + ${mmsc.mgmt.route.2}: {get_param: oam_network_route_2} + ${mmsc.external.dns}: {get_param: external_dns} + ${mmsc.external.ntp}: {get_param: external_ntp} + ${mmsc.hostname}: {get_param: [mmsc_names, 2]} + ${mmsc.timezone}: {get_param: timezone} + user_data_format: RAW + + mmsc3_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: mmsc_cinder_volume_size} + volume_type: {get_param: MMSC_volume_type} + + mmsc3_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: mmsc3_volume} + instance_uuid: {get_resource: server_mmsc3} + + mmsc3_port_0: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [ + "ip_address": {get_param: [mmsc_oam_ips, 2]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + mmsc3_port_1: + type: OS::Neutron::Port + properties: + network_id: {get_resource: mms_traffic_net} + fixed_ips: [ + "ip_address": {get_param: [mmsc_mms_traffic_net_ips, 2]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_mmsc4: + type: OS::Nova::Server + properties: + name: { get_param: [mmsc_names, 3]} + image: { get_param: mmsc_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: mmsc_flavor } + networks: + - port: { get_resource: mmsc4_port_0 } + - port: { get_resource: mmsc4_port_1 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + mmsc.mgmt.ip=${mmsc.mgmt.ip} + mmsc.mgmt.netmask=${mmsc.mgmt.netmask} + mmsc.mgmt.gateway=${mmsc.mgmt.gateway} + mmsc.traffic.ip=${mmsc.traffic.ip} + mmsc.traffic.netmask=${mmsc.traffic.netmask} + mmsc.traffic.gateway=${mmsc.traffic.gateway} + mmsc.mgmt.route.1=${mmsc.mgmt.route.1} + mmsc.mgmt.route.2=${mmsc.mgmt.route.2} + mmsc.external.dns=${mmsc.external.dns} + mmsc.external.ntp=${mmsc.external.ntp} + mmsc.hostname=${mmsc.hostname} + mmsc.timezone=${mmsc.timezone} + params: + ${mmsc.mgmt.ip}: {get_param: [mmsc_oam_ips, 3]} + ${mmsc.mgmt.netmask}: {get_param: oam_network_netmask} + ${mmsc.mgmt.gateway}: {get_param: oam_network_gateway} + ${mmsc.traffic.ip}: {get_param: [mmsc_mms_traffic_net_ips, 3]} + ${mmsc.traffic.netmask}: {get_param: mms_traffic_netmask} + ${mmsc.traffic.gateway}: {get_param: mms_traffic_net_gateway} + ${mmsc.mgmt.route.1}: {get_param: oam_network_route_1} + ${mmsc.mgmt.route.2}: {get_param: oam_network_route_2} + ${mmsc.external.dns}: {get_param: external_dns} + ${mmsc.external.ntp}: {get_param: external_ntp} + ${mmsc.hostname}: {get_param: [mmsc_names, 3]} + ${mmsc.timezone}: {get_param: timezone} + user_data_format: RAW + + mmsc4_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: mmsc_cinder_volume_size} + volume_type: {get_param: MMSC_volume_type} + + mmsc4_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: mmsc4_volume} + instance_uuid: {get_resource: server_mmsc4} + + mmsc4_port_0: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [ + "ip_address": {get_param: [mmsc_oam_ips, 3]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + mmsc4_port_1: + type: OS::Neutron::Port + properties: + network_id: {get_resource: mms_traffic_net} + fixed_ips: [ + "ip_address": {get_param: [mmsc_mms_traffic_net_ips, 3]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_mmsc5: + type: OS::Nova::Server + properties: + name: { get_param: [mmsc_names, 4]} + image: { get_param: mmsc_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: mmsc_flavor } + networks: + - port: { get_resource: mmsc5_port_0 } + - port: { get_resource: mmsc5_port_1 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + mmsc.mgmt.ip=${mmsc.mgmt.ip} + mmsc.mgmt.netmask=${mmsc.mgmt.netmask} + mmsc.mgmt.gateway=${mmsc.mgmt.gateway} + mmsc.traffic.ip=${mmsc.traffic.ip} + mmsc.traffic.netmask=${mmsc.traffic.netmask} + mmsc.traffic.gateway=${mmsc.traffic.gateway} + mmsc.mgmt.route.1=${mmsc.mgmt.route.1} + mmsc.mgmt.route.2=${mmsc.mgmt.route.2} + mmsc.external.dns=${mmsc.external.dns} + mmsc.external.ntp=${mmsc.external.ntp} + mmsc.hostname=${mmsc.hostname} + mmsc.timezone=${mmsc.timezone} + params: + ${mmsc.mgmt.ip}: {get_param: [mmsc_oam_ips, 4]} + ${mmsc.mgmt.netmask}: {get_param: oam_network_netmask} + ${mmsc.mgmt.gateway}: {get_param: oam_network_gateway} + ${mmsc.traffic.ip}: {get_param: [mmsc_mms_traffic_net_ips, 4]} + ${mmsc.traffic.netmask}: {get_param: mms_traffic_netmask} + ${mmsc.traffic.gateway}: {get_param: mms_traffic_net_gateway} + ${mmsc.mgmt.route.1}: {get_param: oam_network_route_1} + ${mmsc.mgmt.route.2}: {get_param: oam_network_route_2} + ${mmsc.external.dns}: {get_param: external_dns} + ${mmsc.external.ntp}: {get_param: external_ntp} + ${mmsc.hostname}: {get_param: [mmsc_names, 4]} + ${mmsc.timezone}: {get_param: timezone} + user_data_format: RAW + + mmsc5_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: mmsc_cinder_volume_size} + volume_type: {get_param: MMSC_volume_type} + + mmsc5_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: mmsc5_volume} + instance_uuid: {get_resource: server_mmsc5} + + mmsc5_port_0: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [ + "ip_address": {get_param: [mmsc_oam_ips, 4]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + mmsc5_port_1: + type: OS::Neutron::Port + properties: + network_id: {get_resource: mms_traffic_net} + fixed_ips: [ + "ip_address": {get_param: [mmsc_mms_traffic_net_ips, 4]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_nems_fe1: + type: OS::Nova::Server + properties: + name: { get_param: [nems_fe_names, 0] } + image: { get_param: nems_fe_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: nems_fe_flavor } + networks: + - port: { get_resource: nems_fe1_port_0 } + - port: { get_resource: nems_fe1_port_1 } + - port: { get_resource: nems_fe1_port_2 } + - port: { get_resource: nems_fe1_port_3 } + - port: { get_resource: nems_fe1_port_4 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + nems.mgmt.ip=${nems.mgmt.ip} + nems.mgmt.netmask=${nems.mgmt.netmask} + nems.mgmt.gateway=${nems.mgmt.gateway} + nems.traffic.ip=${nems.traffic.ip} + nems.traffic.netmask=${nems.traffic.netmask} + nems.traffic.gateway=${nems.traffic.gateway} + nems.fe0.internal.ip=${nems.fe0.internal.ip} + nems.fe1.internal.ip=${nems.fe1.internal.ip} + nems.internal.netmask=${nems.internal.netmask} + nems.userweb.ip=${nems.userweb.ip} + nems.userweb.netmask=${nems.userweb.netmask} + nems.userweb.gateway=${nems.userweb.gateway} + nems.imap.ip=${nems.imap.ip} + nems.imap.netmask=${nems.imap.netmask} + nems.be.internal.ip=${nems.be.internal.ip} + nems.be.imap.ip=${nems.be.imap.ip} + nems.mgmt.route.1=${nems.mgmt.route.1} + nems.mgmt.route.2=${nems.mgmt.route.2} + nems.external.dns=${nems.external.dns} + nems.external.ntp=${nems.external.ntp} + nems.node=${nems.node} + nems.be0.host.name=${nems.be0.host.name} + nems.fe0.host.name=${nems.fe0.host.name} + nems.fe1.host.name=${nems.fe1.host.name} + nems.timezone=${nems.timezone} + params: + ${nems.mgmt.ip}: {get_param: [nems_fe_oam_ips, 0]} + ${nems.mgmt.netmask}: {get_param: oam_network_netmask} + ${nems.mgmt.gateway}: {get_param: oam_network_gateway} + ${nems.traffic.ip}: {get_param: [nems_fe_nems_traffic_net_ips, 0]} + ${nems.traffic.netmask}: {get_param: nems_traffic_netmask} + ${nems.traffic.gateway}: {get_param: nems_traffic_gateway} + ${nems.fe0.internal.ip}: {get_param: [nems_fe_nems_internal_net_ips, 0]} + ${nems.fe1.internal.ip}: {get_param: [nems_fe_nems_internal_net_ips, 1]} + ${nems.internal.netmask}: {get_param: nems_internal_netmask} + ${nems.userweb.ip}: {get_param: [nems_fe_nems_user_web_net_ips, 0]} + ${nems.userweb.netmask}: {get_param: nems_user_web_netmask} + ${nems.userweb.gateway}: {get_param: nems_user_web_gateway} + ${nems.imap.ip}: {get_param: [nems_fe_nems_imap_net_ips, 0]} + ${nems.imap.netmask}: {get_param: nems_imap_netmask} + ${nems.be.internal.ip}: {get_param: nems_be_nems_internal_net_ips} + ${nems.be.imap.ip}: {get_param: nems_be_nems_imap_net_ips} + ${nems.mgmt.route.1}: {get_param: oam_network_route_1} + ${nems.mgmt.route.2}: {get_param: oam_network_route_2} + ${nems.external.dns}: {get_param: external_dns} + ${nems.external.ntp}: {get_param: external_ntp} + ${nems.node}: {get_param: [nems_fe_node_roles, 0]} + ${nems.fe0.host.name}: {get_param: [nems_fe_names, 0]} + ${nems.fe1.host.name}: {get_param: [nems_fe_names, 1]} + ${nems.be0.host.name}: {get_param: nems_be_names} + ${nems.timezone}: {get_param: timezone} + user_data_format: RAW + + nems1_fe_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: nems_volume_size} + volume_type: {get_param: NEMS_FE_volume_type} + + nems1_fe_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: nems1_fe_volume} + instance_uuid: {get_resource: server_nems_fe1} + + nems_fe1_port_0: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [ + "ip_address": { get_param: [nems_fe_oam_ips, 0] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_fe1_port_1: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [nems_fe_nems_traffic_net_ips, 0] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_fe1_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_user_web_net } + fixed_ips: [ + "ip_address": { get_param: [nems_fe_nems_user_web_net_ips, 0] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_fe1_port_3: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_internal_net } + fixed_ips: [ + "ip_address": { get_param: [nems_fe_nems_internal_net_ips, 0] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_fe1_port_4: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_imap_net } + fixed_ips: [ + "ip_address": { get_param: [nems_fe_nems_imap_net_ips, 0] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_nems_fe2: + type: OS::Nova::Server + properties: + name: { get_param: [nems_fe_names, 1] } + image: { get_param: nems_fe_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: nems_fe_flavor } + networks: + - port: { get_resource: nems_fe2_port_0 } + - port: { get_resource: nems_fe2_port_1 } + - port: { get_resource: nems_fe2_port_2 } + - port: { get_resource: nems_fe2_port_3 } + - port: { get_resource: nems_fe2_port_4 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + nems.mgmt.ip=${nems.mgmt.ip} + nems.mgmt.netmask=${nems.mgmt.netmask} + nems.mgmt.gateway=${nems.mgmt.gateway} + nems.traffic.ip=${nems.traffic.ip} + nems.traffic.netmask=${nems.traffic.netmask} + nems.traffic.gateway=${nems.traffic.gateway} + nems.fe0.internal.ip=${nems.fe0.internal.ip} + nems.fe1.internal.ip=${nems.fe1.internal.ip} + nems.internal.netmask=${nems.internal.netmask} + nems.userweb.ip=${nems.userweb.ip} + nems.userweb.netmask=${nems.userweb.netmask} + nems.userweb.gateway=${nems.userweb.gateway} + nems.imap.ip=${nems.imap.ip} + nems.imap.netmask=${nems.imap.netmask} + nems.be.internal.ip=${nems.be.internal.ip} + nems.be.imap.ip=${nems.be.imap.ip} + nems.mgmt.route.1=${nems.mgmt.route.1} + nems.mgmt.route.2=${nems.mgmt.route.2} + nems.external.dns=${nems.external.dns} + nems.external.ntp=${nems.external.ntp} + nems.node=${nems.node} + nems.be0.host.name=${nems.be0.host.name} + nems.fe0.host.name=${nems.fe0.host.name} + nems.fe1.host.name=${nems.fe1.host.name} + nems.timezone=${nems.timezone} + params: + ${nems.mgmt.ip}: {get_param: [nems_fe_oam_ips, 1]} + ${nems.mgmt.netmask}: {get_param: oam_network_netmask} + ${nems.mgmt.gateway}: {get_param: oam_network_gateway} + ${nems.traffic.ip}: {get_param: [nems_fe_nems_traffic_net_ips, 1]} + ${nems.traffic.netmask}: {get_param: nems_traffic_netmask} + ${nems.traffic.gateway}: {get_param: nems_traffic_gateway} + ${nems.fe0.internal.ip}: {get_param: [nems_fe_nems_internal_net_ips, 0]} + ${nems.fe1.internal.ip}: {get_param: [nems_fe_nems_internal_net_ips, 1]} + ${nems.internal.netmask}: {get_param: nems_internal_netmask} + ${nems.userweb.ip}: {get_param: [nems_fe_nems_user_web_net_ips, 1]} + ${nems.userweb.netmask}: {get_param: nems_user_web_netmask} + ${nems.userweb.gateway}: {get_param: nems_user_web_gateway} + ${nems.imap.ip}: {get_param: [nems_fe_nems_imap_net_ips, 1]} + ${nems.imap.netmask}: {get_param: nems_imap_netmask} + ${nems.be.internal.ip}: {get_param: nems_be_nems_internal_net_ips} + ${nems.be.imap.ip}: {get_param: nems_be_nems_imap_net_ips} + ${nems.mgmt.route.1}: {get_param: oam_network_route_1} + ${nems.mgmt.route.2}: {get_param: oam_network_route_2} + ${nems.external.dns}: {get_param: external_dns} + ${nems.external.ntp}: {get_param: external_ntp} + ${nems.node}: {get_param: [nems_fe_node_roles, 1]} + ${nems.fe0.host.name}: {get_param: [nems_fe_names, 0]} + ${nems.fe1.host.name}: {get_param: [nems_fe_names, 1]} + ${nems.be0.host.name}: {get_param: nems_be_names} + ${nems.timezone}: {get_param: timezone} + user_data_format: RAW + + nems2_fe_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: nems_volume_size} + volume_type: {get_param: NEMS_FE_volume_type} + + nems2_fe_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: nems2_fe_volume} + instance_uuid: {get_resource: server_nems_fe2} + + nems_fe2_port_0: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [ + "ip_address": {get_param: [nems_fe_oam_ips, 1]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_fe2_port_1: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [nems_fe_nems_traffic_net_ips, 1] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_fe2_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_user_web_net } + fixed_ips: [ + "ip_address": { get_param: [nems_fe_nems_user_web_net_ips, 1] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_fe2_port_3: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_internal_net } + fixed_ips: [ + "ip_address": { get_param: [nems_fe_nems_internal_net_ips, 1] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + + nems_fe2_port_4: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_imap_net } + fixed_ips: [ + "ip_address": { get_param: [nems_fe_nems_imap_net_ips, 1] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_nems_be1: + type: OS::Nova::Server + properties: + name: { get_param: nems_be_names } + image: { get_param: nems_be_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: nems_be_flavor } + networks: + - port: { get_resource: nems_be1_port_0 } + - port: { get_resource: nems_be1_port_1 } + - port: { get_resource: nems_be1_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + nems.be.mgmt.ip=${nems.be.mgmt.ip} + nems.mgmt.netmask=${nems.mgmt.netmask} + nems.mgmt.gateway=${nems.mgmt.gateway} + nems.be.internal.ip=${nems.be.internal.ip} + nems.internal.netmask=${nems.internal.netmask} + nems.imap.netmask=${nems.imap.netmask} + nems.fe0.internal.ip=${nems.fe0.internal.ip} + nems.fe1.internal.ip=${nems.fe1.internal.ip} + nems.be.imap.ip=${nems.be.imap.ip} + nems.mgmt.route.1=${nems.mgmt.route.1} + nems.mgmt.route.2=${nems.mgmt.route.2} + nems.external.dns=${nems.external.dns} + nems.external.ntp=${nems.external.ntp} + nems.node=${nems.node} + nems.be0.host.name=${nems.be0.host.name} + nems.fe0.host.name=${nems.fe0.host.name} + nems.fe1.host.name=${nems.fe1.host.name} + nems.timezone=${nems.timezone} + params: + ${nems.be.mgmt.ip}: {get_param: nems_be_oam_ips} + ${nems.mgmt.netmask}: {get_param: oam_network_netmask} + ${nems.mgmt.gateway}: {get_param: oam_network_gateway} + ${nems.fe0.internal.ip}: {get_param: [nems_fe_nems_internal_net_ips, 0]} + ${nems.fe1.internal.ip}: {get_param: [nems_fe_nems_internal_net_ips, 1]} + ${nems.be.internal.ip}: {get_param: nems_be_nems_internal_net_ips} + ${nems.internal.netmask}: {get_param: nems_internal_netmask} + ${nems.imap.netmask}: {get_param: nems_imap_netmask} + ${nems.be.imap.ip}: {get_param: nems_be_nems_imap_net_ips} + ${nems.mgmt.route.1}: {get_param: oam_network_route_1} + ${nems.mgmt.route.2}: {get_param: oam_network_route_2} + ${nems.external.dns}: {get_param: external_dns} + ${nems.external.ntp}: {get_param: external_ntp} + ${nems.node}: {get_param: nems_be_node_roles} + ${nems.be0.host.name}: {get_param: nems_be_names} + ${nems.fe0.host.name}: {get_param: [nems_fe_names, 0]} + ${nems.fe1.host.name}: {get_param: [nems_fe_names, 1]} + ${nems.timezone}: {get_param: timezone} + user_data_format: RAW + + nems_be_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: nems_be_volume_size} + volume_type: {get_param: NEMS_BE_volume_type} + + nems_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: nems_be_volume} + instance_uuid: {get_resource: server_nems_be1} + + + nems_be1_port_0: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [ + "ip_address": { get_param: nems_be_oam_ips} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_be1_port_1: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_internal_net } + fixed_ips: [ + "ip_address": { get_param: nems_be_nems_internal_net_ips} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_be1_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_imap_net } + fixed_ips: [ + "ip_address": { get_param: nems_be_nems_imap_net_ips} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx1: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 0]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx1_port_0 } + - port: { get_resource: eca_trx1_port_1 } + - port: { get_resource: eca_trx1_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 0]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 0]} + + eca_trx1_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 0] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx1_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 0] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx1_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 0] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + + server_eca_trx2: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 1]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx2_port_0 } + - port: { get_resource: eca_trx2_port_1 } + - port: { get_resource: eca_trx2_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 1]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 1]} + + eca_trx2_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 1] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx2_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 1] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx2_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 1] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx3: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 2]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx3_port_0 } + - port: { get_resource: eca_trx3_port_1 } + - port: { get_resource: eca_trx3_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 2]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 2]} + + eca_trx3_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 2] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx3_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 2] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx3_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 2] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx4: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 3]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx4_port_0 } + - port: { get_resource: eca_trx4_port_1 } + - port: { get_resource: eca_trx4_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 3]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 3]} + + eca_trx4_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 3] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx4_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 3] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx4_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 3] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx5: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 4]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx5_port_0 } + - port: { get_resource: eca_trx5_port_1 } + - port: { get_resource: eca_trx5_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 4]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 4]} + + eca_trx5_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 4] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx5_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 4] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx5_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 4] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx6: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 5]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx6_port_0 } + - port: { get_resource: eca_trx6_port_1 } + - port: { get_resource: eca_trx6_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 5]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 5]} + + eca_trx6_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 5] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx6_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 5] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx6_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 5] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx7: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 6]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx7_port_0 } + - port: { get_resource: eca_trx7_port_1 } + - port: { get_resource: eca_trx7_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 6]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 6]} + + eca_trx7_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 6] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx7_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 6] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx7_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 6] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx8: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 7]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx8_port_0 } + - port: { get_resource: eca_trx8_port_1 } + - port: { get_resource: eca_trx8_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 7]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 7]} + + eca_trx8_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 7] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx8_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 7] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx8_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 7] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx9: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 8]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx9_port_0 } + - port: { get_resource: eca_trx9_port_1 } + - port: { get_resource: eca_trx9_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 8]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 8]} + + eca_trx9_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 8] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx9_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 8] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx9_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 8] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx10: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 9]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx10_port_0 } + - port: { get_resource: eca_trx10_port_1 } + - port: { get_resource: eca_trx10_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 9]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 9]} + + eca_trx10_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 9] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx10_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 9] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx10_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 9] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx11: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 10]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx11_port_0 } + - port: { get_resource: eca_trx11_port_1 } + - port: { get_resource: eca_trx11_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 10]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 10]} + + eca_trx11_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 10] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx11_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 10] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx11_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 10] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + + server_eca_trx12: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 11]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx12_port_0 } + - port: { get_resource: eca_trx12_port_1 } + - port: { get_resource: eca_trx12_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 11]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 11]} + + eca_trx12_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 11] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx12_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 11] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx12_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 11] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx13: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 12]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx13_port_0 } + - port: { get_resource: eca_trx13_port_1 } + - port: { get_resource: eca_trx13_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 12]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 12]} + + eca_trx13_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 12] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx13_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 12] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx13_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 12] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx14: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 13]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx14_port_0 } + - port: { get_resource: eca_trx14_port_1 } + - port: { get_resource: eca_trx14_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 13]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 13]} + + eca_trx14_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 13] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx14_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 13] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx14_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 13] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx15: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 14]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx15_port_0 } + - port: { get_resource: eca_trx15_port_1 } + - port: { get_resource: eca_trx15_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 14]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 14]} + + eca_trx15_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 14] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx15_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 14] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx15_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 14] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx16: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 15]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx16_port_0 } + - port: { get_resource: eca_trx16_port_1 } + - port: { get_resource: eca_trx16_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 15]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 15]} + + eca_trx16_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 15] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx16_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 15] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx16_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 15] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + + server_eca_trx17: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 16]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx17_port_0 } + - port: { get_resource: eca_trx17_port_1 } + - port: { get_resource: eca_trx17_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 16]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 16]} + + eca_trx17_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 16] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx17_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 16] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx17_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 16] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx18: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 17]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx18_port_0 } + - port: { get_resource: eca_trx18_port_1 } + - port: { get_resource: eca_trx18_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 17]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 17]} + + eca_trx18_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 17] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx18_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 17] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx18_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 17] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx19: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 18]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx19_port_0 } + - port: { get_resource: eca_trx19_port_1 } + - port: { get_resource: eca_trx19_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 8]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 18]} + + eca_trx19_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 18] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx19_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 18] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx19_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 18] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx20: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 19]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx20_port_0 } + - port: { get_resource: eca_trx20_port_1 } + - port: { get_resource: eca_trx20_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 19]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 19]} + + eca_trx20_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 19] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx20_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 19] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx20_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 19] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/MMSC_Capacity_Line_1.env b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/MMSC_Capacity_Line_1.env new file mode 100644 index 0000000000..b346d67d97 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/MMSC_Capacity_Line_1.env @@ -0,0 +1,111 @@ +parameters: + oam_net_name: oam_protected_net_0 + oam_network_netmask: 255.255.254.0 + oam_network_gateway: 107.250.172.1 + oam_network_route_1: 155.165.201.250/32,107.250.172.1 + oam_network_route_2: 155.165.194.100/32,107.250.172.1 + external_dns: 155.165.194.100 + external_ntp: 155.165.201.250 + lb_oam_ips: 107.250.172.50,107.250.172.51 + dmz_protected_net_name: dmz_protected_net_0 + lb_dmz_protected_ips: 107.239.14.19,107.239.14.20 + cor_direct_net_name: cor_direct_net_0 + lb_cor_direct_ips: 172.31.10.19,172.31.10.20 + mms_traffic_net_name: int_mms_mms_traffic_net_2 + mms_traffic_net_cidr: 172.26.2.0/24 + mms_traffic_netmask: 255.255.255.0 + mms_traffic_net_gateway: 172.26.2.1 + mms_traffic_start: 172.26.2.3 + mms_traffic_end: 172.26.2.254 + mms_traffic_net_local_ip1: 172.26.2.3 + mms_traffic_net_local_ip2: 172.26.2.4 + mms_traffic_net_floating_ip: 172.26.2.5 + nems_internal_name: int_mms_nems_internal_net_2 + nems_internal_start: 172.26.6.3 + nems_internal_end: 172.26.6.254 + nems_internal_cidr: 172.26.6.0/24 + nems_internal_netmask: 255.255.255.0 + nems_internal_gateway: 172.26.6.1 + nems_traffic_name: int_mms_nems_traffic_net_2 + nems_traffic_start: 172.26.3.3 + nems_traffic_end: 172.26.3.254 + nems_traffic_cidr: 172.26.3.0/24 + nems_traffic_netmask: 255.255.255.0 + nems_traffic_gateway: 172.26.3.1 + nems_traffic_net_local_ip1: 172.26.3.3 + nems_traffic_net_local_ip2: 172.26.3.4 + nems_traffic_net_floating_ip: 172.26.3.5 + nems_user_web_name: int_mms_nems_web_net_2 + nems_user_web_start: 172.26.4.3 + nems_user_web_end: 172.26.4.254 + nems_user_web_cidr: 172.26.4.0/24 + nems_user_web_netmask: 255.255.255.0 + nems_user_web_gateway: 172.26.4.1 + nems_user_web_net_local_ip1: 172.26.4.3 + nems_user_web_net_local_ip2: 172.26.4.4 + nems_user_web_net_floating_ip: 172.26.4.5 + nems_imap_name: int_mms_nems_imap_net_2 + nems_imap_start: 172.26.7.3 + nems_imap_end: 172.26.7.254 + nems_imap_cidr: 172.26.7.0/24 + nems_imap_netmask: 255.255.255.0 + nems_imap_gateway: 172.26.7.1 + eca_traffic_name: int_mms_eca_traffic_net_2 + eca_traffic_cidr: 172.26.5.0/24 + eca_traffic_netmask: 255.255.255.0 + eca_traffic_net_gateway: 172.26.5.1 + eca_traffic_start: 172.26.5.3 + eca_traffic_end: 172.26.5.254 + eca_traffic_net_local_ip1: 172.26.5.3 + eca_traffic_net_local_ip2: 172.26.5.4 + eca_traffic_net_floating_ip: 172.26.5.5 + ha_net_name: int_mms_ha_net_2 + ha_net_cidr: 172.26.1.0/24 + ha_net_start: 172.26.1.3 + ha_net_end: 172.26.1.254 + ha_net_local_ip1: 172.26.1.3 + ha_net_local_ip2: 172.26.1.4 + lb_names: ZRDM1MMSC03ALB001,ZRDM1MMSC03ALB002 + lb_image_name: BIGIP-11.5.3.0.0.163 + lb_flavor_name: m1.xlarge + security_group_name: mmsc_security_group_1 + availability_zone_0: nova + mmsc_mms_traffic_net_ips: 172.26.2.11,172.26.2.12,172.26.2.13,172.26.2.14,172.26.2.15 + mmsc_oam_ips: 107.250.172.54,107.250.172.55,107.250.172.56,107.250.172.57,107.250.172.58 + mmsc_flavor: lc.4xlarge4 + mmsc_image: mmsc-6.0.2_v5 + mmsc_cinder_volume_size: 480 + nems_fe_flavor: m1.large2 + nems_fe_image: nems-2.1.2_v29 + nems_fe_names: ZRDM1MMSC03NFE001,ZRDM1MMSC03NFE002 + nems_fe_node_roles: FE0,FE1 + nems_fe_oam_ips: 107.250.172.64,107.250.172.65 + nems_fe_nems_traffic_net_ips: 172.26.3.11,172.26.3.12 + nems_fe_nems_user_web_net_ips: 172.26.4.11,172.26.4.12 + nems_fe_nems_internal_net_ips: 172.26.6.11,172.26.6.12 + nems_fe_nems_imap_net_ips: 172.26.7.11,172.26.7.12 + nems_be_names: ZRDM1MMSC03NBE001 + nems_be_node_roles: BE0 + nems_be_oam_ips: 107.250.172.66 + nems_be_nems_internal_net_ips: 172.26.6.13 + nems_be_nems_imap_net_ips: 172.26.7.13 + nems_be_flavor: m1.large2 + nems_be_image: nems-2.1.2_v29 + eca_trx_oam_ips: 107.250.172.70,107.250.172.71,107.250.172.72,107.250.172.73,107.250.172.74,107.250.172.75,107.250.172.76,107.250.172.77,107.250.172.78,107.250.172.79,107.250.172.80,107.250.172.81,107.250.172.82,107.250.172.83,107.250.172.84,107.250.172.85,107.250.172.86,107.250.172.87,107.250.172.88,107.250.172.89 + eca_trx_mgmt_ips: 172.25.137.202,172.25.137.203,172.25.137.204,172.25.137.205,172.25.137.206,172.25.137.207,172.25.137.208,172.25.137.209,172.25.137.210,172.25.137.211,172.25.137.212,172.25.137.213,172.25.137.214,172.25.137.215,172.25.137.216,172.25.137.217,172.25.137.218,172.25.137.219,172.25.137.220,172.25.137.221 + eca_trx_flavor: m1.xlarge + eca_trx_image: ECABASE + timezone: UTC + eca_trx_names: ZRDM1MMSC03TRX001,ZRDM1MMSC03TRX002,ZRDM1MMSC03TRX003,ZRDM1MMSC03TRX004,ZRDM1MMSC03TRX005,ZRDM1MMSC03TRX006,ZRDM1MMSC03TRX007,ZRDM1MMSC03TRX008,ZRDM1MMSC03TRX009,ZRDM1MMSC03TRX010,ZRDM1MMSC03TRX011,ZRDM1MMSC03TRX012,ZRDM1MMSC03TRX013,ZRDM1MMSC03TRX014,ZRDM1MMSC03TRX015,ZRDM1MMSC03TRX016,ZRDM1MMSC03TRX017,ZRDM1MMSC03TRX018,ZRDM1MMSC03TRX019,ZRDM1MMSC03TRX020 + eca_trx_eca_traffic_net_ips: 172.26.5.11,172.26.5.12,172.26.5.13,172.26.5.14,172.26.5.15,172.26.5.16,172.26.5.17,172.26.5.18,172.26.5.19,172.26.5.20,172.26.5.21,172.26.5.22,172.26.5.23,172.26.5.24,172.26.5.25,172.26.5.26,172.26.5.27,172.26.5.28,172.26.5.29,172.26.5.30 + mmsc_names: ZRDM1MMSC03MMS001,ZRDM1MMSC03MMS002,ZRDM1MMSC03MMS003,ZRDM1MMSC03MMS004,ZRDM1MMSC03MMS005 + nems_volume_size: 50 + nems_be_volume_size: 610 + MMSC_volume_type: Platinum + NEMS_FE_volume_type: Platinum + NEMS_BE_volume_type: Platinum + mmsc_core_virtual_server_ips: 172.31.10.21,172.31.10.22 + mmsc_core_snat_ips: 172.31.10.23,172.31.10.24,172.31.10.25,172.31.10.26,172.31.10.27 + mmsc_dmz_protected_virtual_server_ips: 107.239.14.21,107.239.14.22,107.239.14.23 + mmsc_dmz_protected_snat_ips: 107.239.14.24,107.239.14.25,107.239.14.26,107.239.14.27 + eca_mgmt_net_name: int_eca_mgmt_net_1 \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/SG_ECA_MGMT.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/SG_ECA_MGMT.yaml new file mode 100644 index 0000000000..53efc5e36e --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/SG_ECA_MGMT.yaml @@ -0,0 +1,76 @@ +heat_template_version: 2013-05-23 + +################################# +# +# Changes from MSO - 11/5/2015 +# - Parameter changes as below +# - CDLs for vmNames, IPs +# - aZone->availability_zone_0 +# - nwName->{nwRole}_net_name +# - nwID->{nwRole}_net_id +# - vmName->{vmType}_names +# - ips ->{vmType}_{nwRole}_ips +# - fips->{vmType}_{nwRole}_floating_ip +# - added replacement_policy: AUTO to all ports +# - added vnf_id for metadata to all servers +# - externalized security group resource +# - externalized eca_mgmt network +# +################################# + +description: > + HOT template that creates Security Group and ECA network + +parameters: + eca_mgmt_name: + type: string + label: eca management name + description: eca management name + eca_mgmt_start: + type: string + label: eca management start + description: eca management start + eca_mgmt_end: + type: string + label: eca management end + description: eca management end + eca_mgmt_cidr: + type: string + label: eca management cidr + description: eca management cidr + eca_mgmt_netmask: + type: string + label: ECA mgmt network subnet mask + description: ECA mgmt network subnet mask + security_group_name: + type: string + label: MMSC security group name + description: MMSC security group name + +resources: + mms_security_group: + type: OS::Neutron::SecurityGroup + properties: + description: mmsc security group + name: {get_param: security_group_name} + rules: [{"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0} + ] + eca_mgmt_net: + type: OS::Contrail::VirtualNetwork + properties: + name: {get_param: eca_mgmt_name} + + eca_mgmt_network_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: eca_mgmt_name} + allocation_pools: [{"start": {get_param: eca_mgmt_start}, "end": {get_param: eca_mgmt_end}}] + cidr: {get_param: eca_mgmt_cidr} + #enable_dhcp: false + #gateway_ip: null + network_id: {get_resource: eca_mgmt_net} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/cmaui.env b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/cmaui.env new file mode 100644 index 0000000000..d37e1eedc2 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/cmaui.env @@ -0,0 +1,17 @@ +parameters: + cmaui_names: ZRDM1MMSC02CMI001,ZRDM1MMSC02CMI002 + cmaui_flavor: m1.large + cmaui_image: cmaui-5.0.2.5_v25 + cmaui_cinder_volume_size: 55 + oam_net_name: oam_protected_net_0 + oam_network_netmask: 255.255.254.0 + oam_network_gateway: 107.250.172.1 + oam_network_netmask: 255.255.255.192 + oam_network_gateway: 10.20.30.1 + external_dns: 155.165.201.250 + external_ntp: 155.165.194.100 + security_group_name: mmsc_security_group_1 + availability_zone_0: nova + timezone: UTC + cmaui_oam_ips: 107.250.172.42,107.250.172.43 + CMAUI_volume_type: Platinum \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/cmaui.yml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/cmaui.yml new file mode 100644 index 0000000000..0b925e2d85 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/cmaui.yml @@ -0,0 +1,202 @@ +heat_template_version: 2013-05-23 + +################################# +# +# Changes from MSO 01/26/2016 +# Updated per ECOMP feedback +# +################################# + +description: cmaui server template for vMMSC + +parameters: + vnf_id: + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-CMAUI_id + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_cinder_volume_size: + type: number + label: CMAUI Cinder volume size + description: the size of the CMAUI Cinder volume + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + oam_net_name: + type: string + description: UID of OAM network + oam_network_netmask: + type: string + label: oam network netmask + description: oam network gateway + oam_network_gateway: + type: string + label: oam network gateway + description: oam network gateway + external_dns: + type: string + label: dns server + description: dns server + external_ntp: + type: string + label: ntp server + description: ntp server + security_group_name: + type: string + label: security group name + description: the name of security group + timezone: + type: string + label: timezone + description: timezone + cmaui_oam_ips: + type: comma_delimited_list + label: CMAUI oam_net IP addresses + description: CMAUI oam_net IP addresses + CMAUI_volume_type: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + +resources: + server_cmaui: + type: eca_oam.yaml + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_0 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + cmaui.mgmt.ip=${cmaui.mgmt.ip} + cmaui.mgmt.netmask=${cmaui.mgmt.netmask} + cmaui.mgmt.gateway=${cmaui.mgmt.gateway} + cmaui.external.dns=${cmaui.external.dns} + cmaui.external.ntp=${cmaui.external.ntp} + cmaui.node=${cmaui.node} + cmaui.timezone=${cmaui.timezone} + params: + ${cmaui.mgmt.ip}: {get_param: [cmaui_oam_ips, 0]} + ${cmaui.mgmt.netmask}: {get_param: oam_network_netmask} + ${cmaui.mgmt.gateway}: {get_param: oam_network_gateway} + ${cmaui.external.dns}: {get_param: external_dns} + ${cmaui.external.ntp}: {get_param: external_ntp} + ${cmaui.node}: {get_param: [cmaui_names, 0]} + ${cmaui.timezone}: {get_param: timezone} + user_data_format: RAW + + server_cmaui_2: + type: eca_oam_2.yaml + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_0 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + cmaui.mgmt.ip=${cmaui.mgmt.ip} + cmaui.mgmt.netmask=${cmaui.mgmt.netmask} + cmaui.mgmt.gateway=${cmaui.mgmt.gateway} + cmaui.external.dns=${cmaui.external.dns} + cmaui.external.ntp=${cmaui.external.ntp} + cmaui.node=${cmaui.node} + cmaui.timezone=${cmaui.timezone} + params: + ${cmaui.mgmt.ip}: {get_param: [cmaui_oam_ips, 0]} + ${cmaui.mgmt.netmask}: {get_param: oam_network_netmask} + ${cmaui.mgmt.gateway}: {get_param: oam_network_gateway} + ${cmaui.external.dns}: {get_param: external_dns} + ${cmaui.external.ntp}: {get_param: external_ntp} + ${cmaui.node}: {get_param: [cmaui_names, 0]} + ${cmaui.timezone}: {get_param: timezone} + user_data_format: RAW + + cmaui_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: cmaui_cinder_volume_size} + volume_type: {get_param: CMAUI_volume_type} + + cmaui_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: cmaui_volume} + instance_uuid: {get_resource: server_cmaui} + + cmaui_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_cmaui1: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 1]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui1_port_0 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + cmaui.mgmt.ip=${cmaui.mgmt.ip} + cmaui.mgmt.netmask=${cmaui.mgmt.netmask} + cmaui.mgmt.gateway=${cmaui.mgmt.gateway} + cmaui.external.dns=${cmaui.external.dns} + cmaui.external.ntp=${cmaui.external.ntp} + cmaui.node=${cmaui.node} + cmaui.timezone=${cmaui.timezone} + params: + ${cmaui.mgmt.ip}: {get_param: [cmaui_oam_ips, 1]} + ${cmaui.mgmt.netmask}: {get_param: oam_network_netmask} + ${cmaui.mgmt.gateway}: {get_param: oam_network_gateway} + ${cmaui.external.dns}: {get_param: external_dns} + ${cmaui.external.ntp}: {get_param: external_ntp} + ${cmaui.node}: {get_param: [cmaui_names, 1]} + ${cmaui.timezone}: {get_param: timezone} + user_data_format: RAW + + cmaui1_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: cmaui_cinder_volume_size} + volume_type: {get_param: CMAUI_volume_type} + + cmaui1_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: cmaui1_volume} + instance_uuid: {get_resource: server_cmaui1} + + cmaui1_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 1]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/eca_oam.env b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/eca_oam.env new file mode 100644 index 0000000000..f9991722b3 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/eca_oam.env @@ -0,0 +1,20 @@ +parameters: + eca_names: ZRDM1MMSC02OAM001,ZRDM1MMSC02OAM002 + arb_names: ZRDM1MMSC02ARB001 + oam_image_name: ECABASE + oam_flavor: lc.xlarge4 + arbiter_flavor: m1.large2 + availability_zone_0: nova + oam_net_name: oam_protected_net_0 + eca_mgmt_net_name: int_mms_eca_mgmt_net_1 + eca_oam_ips: 107.250.172.44,107.250.172.45 + eca_eca_mgmt_ips: 172.25.137.242,172.25.137.243 + eca_oam_gateway: 107.250.172.1 + arb_oam_ips: 107.250.172.46 + arb_eca_mgmt_ips: 172.25.137.244 + security_group_name: mmsc_security_group_1 + oam_volume_size: 1800 + arb_volume_size: 40 + swift_eca_url: http://object-store.rdm2.cci.com:8080/v1/AUTH_1bbab536a19b4756926e7d0ec1eb543c/eca + ECA_OAM_volume_type: Platinum + ARB_volume_type: Platinum diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/eca_oam.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/eca_oam.yaml new file mode 100644 index 0000000000..b9fa48615c --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/eca_oam.yaml @@ -0,0 +1,383 @@ +heat_template_version: 2013-05-23 + +########################################################## +# +# Changes from MSO +# - Updated per ECOMP Feedback +# +# +########################################################## + +description: This stack creates two ECA OAM VM and one ARB VM + +parameters: + vnf_id: + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-ECA_id + eca_names: + type: comma_delimited_list + label: oam servers names + description: the names of the OAM1,OAM2 VM instances + arb_names: + type: comma_delimited_list + label: arbiter server names + description: the names of the arbiter VM instances + oam_image_name: + type: string + label: image name + description: the OAM image name + oam_flavor: + type: string + label: flavor name + description: OAM flavor name + arbiter_flavor: + type: string + label: flavor name + description: arbiter flavor name + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + oam_net_name: + type: string + label: oam network name + description: the name of the oam network + eca_mgmt_net_name: + type: string + label: internal network name + description: the name of the internal network + eca_oam_ips: + type: comma_delimited_list + label: oam network ips + description: the ips of oam networks for eca VM + eca_oam_gateway: + type: string + label: oam1 oam gateway + description: the ip of oam gateway + eca_eca_mgmt_ips: + type: comma_delimited_list + label: eca_mgmt network ips for eca VM + description: internal eca_mgmt network ips for eca VM + arb_oam_ips: + type: comma_delimited_list + label: oam network ips for arb VM + description: oam network ips for eca VM + arb_eca_mgmt_ips: + type: comma_delimited_list + label: eca_mgmt network ips + description: internal eca_mgmt network ips for arb VM + eca_oam_gateway: + type: string + label: oam network gateway + description: oam network gateway + security_group_name: + type: string + label: security group name + description: the name of security group + oam_volume_size: + type: number + label: volume size + description: the size of the OAM volume + arb_volume_size: + type: number + label: volume size + description: the size of the ARB volume + swift_eca_url: + type: string + label: Swift URL + description: Base URL for eca swift object store + ECA_OAM_volume_type: + type: string + label: eca oam vm volume type + description: the name of the target volume backend + ARB_volume_type: + type: string + label: arb vm volume type + description: the name of the target volume backend + +resources: + oam1_instance: + type: OS::Nova::Server + properties: + name: {get_param: [eca_names, 0]} + image: {get_param: oam_image_name} + flavor: {get_param: oam_flavor} + availability_zone: {get_param: availability_zone_0} + networks: + - port: {get_resource: oam1_int_port} + - port: {get_resource: oam1_mgmt_port} + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + sed -i s/HOSTNAME.*/"HOSTNAME=oam1_hostname"/g /etc/sysconfig/network + eth1_ip_address='oam1_mgt_ip' + eth1_gateway='oam_gateway' + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + mkdir /etc/puppet/files/roles/transcoder + mkdir /etc/puppet/files/roles/oam_primary + curl swift_url/etc/puppet/manifests/roles/oam_primary.pp > /etc/puppet/manifests/roles/oam_primary.pp + curl swift_url/etc/puppet/manifests/roles/transcoder.pp > /etc/puppet/manifests/roles/transcoder.pp + curl swift_url/etc/puppet/files/roles/oam_primary/config.yaml > /etc/puppet/files/roles/oam_primary/config.yaml + curl swift_url/etc/puppet/files/roles/transcoder/config.yaml > /etc/puppet/files/roles/transcoder/config.yaml + curl swift_url/etc/puppet/files/roles/transcoder/hpm.conf > /etc/puppet/files/roles/transcoder/hpm.conf + curl swift_url/etc/puppet/files/roles/transcoder/trx.conf > /etc/puppet/files/roles/transcoder/trx.conf + curl swift_url/etc/puppet/files/roles/transcoder/plugins-mo.conf > /etc/puppet/files/roles/transcoder/plugins-mo.conf + curl swift_url/etc/puppet/files/global/11-customer.conf > /etc/puppet/files/global/11-customer.conf + curl swift_url/etc/puppet/manifests/site.pp > /etc/puppet/manifests/site.pp + curl swift_url/scripts/van-init-replicaset > /usr/sbin/van-init-replicaset + van-role oam_primary > /root/startup-van-role.out + curl swift_url/scripts/fdisk-keystrokes > /root/fdisk-keystrokes + fdisk /dev/vdb < /root/fdisk-keystrokes + curl swift_url/scripts/os-conf-cinder-vol > /root/os-conf-cinder-vol + chmod 755 /root/os-conf-cinder-vol + /root/os-conf-cinder-vol 2>> /tmp/cinder_volume.log + params: + oam1_mgt_ip: {get_param: [eca_oam_ips, 0] } + oam_gateway: {get_param: eca_oam_gateway } + oam1_hostname: {get_param: [eca_names, 0]} + swift_url: {get_param: swift_eca_url} + + oam1_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [eca_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + oam1_int_port: + type: OS::Neutron::Port + properties: + network: {get_param: eca_mgmt_net_name} + fixed_ips: [{"ip_address": {get_param: [eca_eca_mgmt_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + oam1_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: oam_volume_size} + volume_type: {get_param: ECA_OAM_volume_type} + + oam1_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: oam1_volume} + instance_uuid: {get_resource: oam1_instance} + + oam2_instance: + type: OS::Nova::Server + properties: + name: {get_param: [eca_names, 1]} + image: {get_param: oam_image_name} + flavor: {get_param: oam_flavor} + availability_zone: {get_param: availability_zone_0} + networks: + - port: {get_resource: oam2_int_port} + - port: {get_resource: oam2_mgmt_port} + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + sed -i s/HOSTNAME.*/"HOSTNAME=oam2_hostname"/g /etc/sysconfig/network + eth1_ip_address='oam2_mgt_ip' + eth1_gateway='oam_gateway' + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + curl swift_url/etc/puppet/manifests/roles/oam_secondary.pp > /etc/puppet/manifests/roles/oam_secondary.pp + curl swift_url/etc/puppet/files/global/config.yaml > /etc/puppet/files/global/config.yaml + curl swift_url/etc/puppet/files/global/11-customer.conf > /etc/puppet/files/global/11-customer.conf + van-role oam_secondary > /root/startup-van-role.out + curl swift_url/scripts/fdisk-keystrokes > /root/fdisk-keystrokes + fdisk /dev/vdb < /root/fdisk-keystrokes + curl swift_url/scripts/os-conf-cinder-vol > /root/os-conf-cinder-vol + chmod 755 /root/os-conf-cinder-vol + /root/os-conf-cinder-vol 2>> /tmp/cinder_volume.log + + params: + oam2_mgt_ip: {get_param: [eca_oam_ips, 1] } + oam2_hostname: {get_param: [eca_names, 1]} + swift_url: {get_param: swift_eca_url} + oam_gateway: {get_param: eca_oam_gateway } + + oam2_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [eca_oam_ips, 1]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + oam2_int_port: + type: OS::Neutron::Port + properties: + network: {get_param: eca_mgmt_net_name} + fixed_ips: [{"ip_address": {get_param: [eca_eca_mgmt_ips, 1]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + oam2_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: oam_volume_size} + volume_type: {get_param: ECA_OAM_volume_type} + + oam2_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: oam2_volume} + instance_uuid: {get_resource: oam2_instance} + + arb_instance: + type: OS::Nova::Server + properties: + name: {get_param: [arb_names, 0]} + image: {get_param: oam_image_name} + flavor: {get_param: arbiter_flavor} + availability_zone: {get_param: availability_zone_0} + networks: + - port: {get_resource: arb_int_port} + - port: {get_resource: arb_mgmt_port} + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + sed -i s/HOSTNAME.*/"HOSTNAME=arb_hostname"/g /etc/sysconfig/network + eth1_ip_address='arb_mgt_ip' + eth1_gateway='oam_gateway' + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + curl swift_url/etc/puppet/manifests/roles/oam_arbiter.pp > /etc/puppet/manifests/roles/oam_arbiter.pp + curl swift_url/etc/puppet/files/global/config.yaml > /etc/puppet/files/global/config.yaml + curl swift_url/etc/puppet/files/global/11-customer.conf > /etc/puppet/files/global/11-customer.conf + van-role oam_arbiter > /root/startup-van-role.out + curl swift_url/scripts/fdisk-keystrokes > /root/fdisk-keystrokes + fdisk /dev/vdb < /root/fdisk-keystrokes + curl swift_url/scripts/os-conf-cinder-vol > /root/os-conf-cinder-vol + chmod 755 /root/os-conf-cinder-vol + /root/os-conf-cinder-vol 2>> /tmp/cinder_volume.log + params: + arb_mgt_ip: {get_param: [arb_oam_ips, 0] } + arb_hostname: {get_param: [arb_names, 0]} + swift_url: {get_param: swift_eca_url} + oam_gateway: {get_param: eca_oam_gateway } + + arb_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [arb_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + arb_int_port: + type: OS::Neutron::Port + properties: + network: {get_param: eca_mgmt_net_name} + fixed_ips: [{"ip_address": {get_param: [arb_eca_mgmt_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + arb_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: arb_volume_size} + volume_type: {get_param: ARB_volume_type} + arb_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: arb_volume} + instance_uuid: {get_resource: arb_instance} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/eca_oam_2.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/eca_oam_2.yaml new file mode 100644 index 0000000000..b9fa48615c --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/eca_oam_2.yaml @@ -0,0 +1,383 @@ +heat_template_version: 2013-05-23 + +########################################################## +# +# Changes from MSO +# - Updated per ECOMP Feedback +# +# +########################################################## + +description: This stack creates two ECA OAM VM and one ARB VM + +parameters: + vnf_id: + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-ECA_id + eca_names: + type: comma_delimited_list + label: oam servers names + description: the names of the OAM1,OAM2 VM instances + arb_names: + type: comma_delimited_list + label: arbiter server names + description: the names of the arbiter VM instances + oam_image_name: + type: string + label: image name + description: the OAM image name + oam_flavor: + type: string + label: flavor name + description: OAM flavor name + arbiter_flavor: + type: string + label: flavor name + description: arbiter flavor name + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + oam_net_name: + type: string + label: oam network name + description: the name of the oam network + eca_mgmt_net_name: + type: string + label: internal network name + description: the name of the internal network + eca_oam_ips: + type: comma_delimited_list + label: oam network ips + description: the ips of oam networks for eca VM + eca_oam_gateway: + type: string + label: oam1 oam gateway + description: the ip of oam gateway + eca_eca_mgmt_ips: + type: comma_delimited_list + label: eca_mgmt network ips for eca VM + description: internal eca_mgmt network ips for eca VM + arb_oam_ips: + type: comma_delimited_list + label: oam network ips for arb VM + description: oam network ips for eca VM + arb_eca_mgmt_ips: + type: comma_delimited_list + label: eca_mgmt network ips + description: internal eca_mgmt network ips for arb VM + eca_oam_gateway: + type: string + label: oam network gateway + description: oam network gateway + security_group_name: + type: string + label: security group name + description: the name of security group + oam_volume_size: + type: number + label: volume size + description: the size of the OAM volume + arb_volume_size: + type: number + label: volume size + description: the size of the ARB volume + swift_eca_url: + type: string + label: Swift URL + description: Base URL for eca swift object store + ECA_OAM_volume_type: + type: string + label: eca oam vm volume type + description: the name of the target volume backend + ARB_volume_type: + type: string + label: arb vm volume type + description: the name of the target volume backend + +resources: + oam1_instance: + type: OS::Nova::Server + properties: + name: {get_param: [eca_names, 0]} + image: {get_param: oam_image_name} + flavor: {get_param: oam_flavor} + availability_zone: {get_param: availability_zone_0} + networks: + - port: {get_resource: oam1_int_port} + - port: {get_resource: oam1_mgmt_port} + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + sed -i s/HOSTNAME.*/"HOSTNAME=oam1_hostname"/g /etc/sysconfig/network + eth1_ip_address='oam1_mgt_ip' + eth1_gateway='oam_gateway' + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + mkdir /etc/puppet/files/roles/transcoder + mkdir /etc/puppet/files/roles/oam_primary + curl swift_url/etc/puppet/manifests/roles/oam_primary.pp > /etc/puppet/manifests/roles/oam_primary.pp + curl swift_url/etc/puppet/manifests/roles/transcoder.pp > /etc/puppet/manifests/roles/transcoder.pp + curl swift_url/etc/puppet/files/roles/oam_primary/config.yaml > /etc/puppet/files/roles/oam_primary/config.yaml + curl swift_url/etc/puppet/files/roles/transcoder/config.yaml > /etc/puppet/files/roles/transcoder/config.yaml + curl swift_url/etc/puppet/files/roles/transcoder/hpm.conf > /etc/puppet/files/roles/transcoder/hpm.conf + curl swift_url/etc/puppet/files/roles/transcoder/trx.conf > /etc/puppet/files/roles/transcoder/trx.conf + curl swift_url/etc/puppet/files/roles/transcoder/plugins-mo.conf > /etc/puppet/files/roles/transcoder/plugins-mo.conf + curl swift_url/etc/puppet/files/global/11-customer.conf > /etc/puppet/files/global/11-customer.conf + curl swift_url/etc/puppet/manifests/site.pp > /etc/puppet/manifests/site.pp + curl swift_url/scripts/van-init-replicaset > /usr/sbin/van-init-replicaset + van-role oam_primary > /root/startup-van-role.out + curl swift_url/scripts/fdisk-keystrokes > /root/fdisk-keystrokes + fdisk /dev/vdb < /root/fdisk-keystrokes + curl swift_url/scripts/os-conf-cinder-vol > /root/os-conf-cinder-vol + chmod 755 /root/os-conf-cinder-vol + /root/os-conf-cinder-vol 2>> /tmp/cinder_volume.log + params: + oam1_mgt_ip: {get_param: [eca_oam_ips, 0] } + oam_gateway: {get_param: eca_oam_gateway } + oam1_hostname: {get_param: [eca_names, 0]} + swift_url: {get_param: swift_eca_url} + + oam1_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [eca_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + oam1_int_port: + type: OS::Neutron::Port + properties: + network: {get_param: eca_mgmt_net_name} + fixed_ips: [{"ip_address": {get_param: [eca_eca_mgmt_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + oam1_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: oam_volume_size} + volume_type: {get_param: ECA_OAM_volume_type} + + oam1_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: oam1_volume} + instance_uuid: {get_resource: oam1_instance} + + oam2_instance: + type: OS::Nova::Server + properties: + name: {get_param: [eca_names, 1]} + image: {get_param: oam_image_name} + flavor: {get_param: oam_flavor} + availability_zone: {get_param: availability_zone_0} + networks: + - port: {get_resource: oam2_int_port} + - port: {get_resource: oam2_mgmt_port} + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + sed -i s/HOSTNAME.*/"HOSTNAME=oam2_hostname"/g /etc/sysconfig/network + eth1_ip_address='oam2_mgt_ip' + eth1_gateway='oam_gateway' + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + curl swift_url/etc/puppet/manifests/roles/oam_secondary.pp > /etc/puppet/manifests/roles/oam_secondary.pp + curl swift_url/etc/puppet/files/global/config.yaml > /etc/puppet/files/global/config.yaml + curl swift_url/etc/puppet/files/global/11-customer.conf > /etc/puppet/files/global/11-customer.conf + van-role oam_secondary > /root/startup-van-role.out + curl swift_url/scripts/fdisk-keystrokes > /root/fdisk-keystrokes + fdisk /dev/vdb < /root/fdisk-keystrokes + curl swift_url/scripts/os-conf-cinder-vol > /root/os-conf-cinder-vol + chmod 755 /root/os-conf-cinder-vol + /root/os-conf-cinder-vol 2>> /tmp/cinder_volume.log + + params: + oam2_mgt_ip: {get_param: [eca_oam_ips, 1] } + oam2_hostname: {get_param: [eca_names, 1]} + swift_url: {get_param: swift_eca_url} + oam_gateway: {get_param: eca_oam_gateway } + + oam2_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [eca_oam_ips, 1]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + oam2_int_port: + type: OS::Neutron::Port + properties: + network: {get_param: eca_mgmt_net_name} + fixed_ips: [{"ip_address": {get_param: [eca_eca_mgmt_ips, 1]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + oam2_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: oam_volume_size} + volume_type: {get_param: ECA_OAM_volume_type} + + oam2_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: oam2_volume} + instance_uuid: {get_resource: oam2_instance} + + arb_instance: + type: OS::Nova::Server + properties: + name: {get_param: [arb_names, 0]} + image: {get_param: oam_image_name} + flavor: {get_param: arbiter_flavor} + availability_zone: {get_param: availability_zone_0} + networks: + - port: {get_resource: arb_int_port} + - port: {get_resource: arb_mgmt_port} + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + sed -i s/HOSTNAME.*/"HOSTNAME=arb_hostname"/g /etc/sysconfig/network + eth1_ip_address='arb_mgt_ip' + eth1_gateway='oam_gateway' + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + curl swift_url/etc/puppet/manifests/roles/oam_arbiter.pp > /etc/puppet/manifests/roles/oam_arbiter.pp + curl swift_url/etc/puppet/files/global/config.yaml > /etc/puppet/files/global/config.yaml + curl swift_url/etc/puppet/files/global/11-customer.conf > /etc/puppet/files/global/11-customer.conf + van-role oam_arbiter > /root/startup-van-role.out + curl swift_url/scripts/fdisk-keystrokes > /root/fdisk-keystrokes + fdisk /dev/vdb < /root/fdisk-keystrokes + curl swift_url/scripts/os-conf-cinder-vol > /root/os-conf-cinder-vol + chmod 755 /root/os-conf-cinder-vol + /root/os-conf-cinder-vol 2>> /tmp/cinder_volume.log + params: + arb_mgt_ip: {get_param: [arb_oam_ips, 0] } + arb_hostname: {get_param: [arb_names, 0]} + swift_url: {get_param: swift_eca_url} + oam_gateway: {get_param: eca_oam_gateway } + + arb_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [arb_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + arb_int_port: + type: OS::Neutron::Port + properties: + network: {get_param: eca_mgmt_net_name} + fixed_ips: [{"ip_address": {get_param: [arb_eca_mgmt_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + arb_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: arb_volume_size} + volume_type: {get_param: ARB_volume_type} + arb_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: arb_volume} + instance_uuid: {get_resource: arb_instance} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/sg_eca_mgmt.env b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/sg_eca_mgmt.env new file mode 100644 index 0000000000..8012063ac0 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/invalidTypes/sg_eca_mgmt.env @@ -0,0 +1,7 @@ +parameters: + eca_mgmt_name: int_eca_mgmt_net_1 + eca_mgmt_cidr: 172.25.137.192/26 + eca_mgmt_netmask: 255.255.255.192 + eca_mgmt_start: 172.25.137.195 + eca_mgmt_end: 172.25.137.254 + security_group_name: mmsc_security_group_1 diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload/MANIFEST.json b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload/MANIFEST.json new file mode 100644 index 0000000000..2ff7eec20e --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload/MANIFEST.json @@ -0,0 +1,20 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create vmme 2 fsb 2 ncb 2 gbp 2 vlc", + "version": "2013-05-23", + "data": [ + { + "file": "vmme_small_create_fsb.yml", + "type": "HEAT", + "data": [ + { + "file": "vmme_small_create_fsb.env", + "type": "HEAT_ENV" + } + ] + },{ + "file": "create_stack.sh", + "type": "SHELL" + } + ] +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload/create_stack.sh b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload/create_stack.sh new file mode 100644 index 0000000000..186d1c34fb --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload/create_stack.sh @@ -0,0 +1 @@ +heat stack-create vMME -e vmme_small.env -f vmme_small.yml diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload/vmme_small_create_fsb.env b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload/vmme_small_create_fsb.env new file mode 100644 index 0000000000..750bb2dd44 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload/vmme_small_create_fsb.env @@ -0,0 +1,8 @@ +parameters: + volume_type: Gold + volume_size: 320 + FSB_1_image: MME_FSB1_15B-CP04-r5a01 + FSB_2_image: MME_FSB2_15B-CP04-r5a01 + FSB1_volume_name: vFSB1_1_Vol_1 + FSB2_volume_name: vFSB2_1_Vol_1 + diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload/vmme_small_create_fsb.yml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload/vmme_small_create_fsb.yml new file mode 100644 index 0000000000..2d695a50c1 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload/vmme_small_create_fsb.yml @@ -0,0 +1,54 @@ +heat_template_version: 2013-05-23 + +description: server template for vMME + +parameters: + + volume_type: + type: string + label: volume type + description: volume type Gold + + volume_size: + type: number + label: volume size + description: my volume size 320GB + + FSB_1_image: + type: string + label: MME_FSB1 + description: MME_FSB1_15B-CP04-r5a01 + + FSB_2_image: + type: string + label: MME_FSB2 + description: MME_FSB2_15B-CP04-r5a01 + + FSB1_volume_name: + type: string + label: FSB1_volume + description: FSB1_volume_1 + + FSB2_volume_name: + type: string + label: FSB2_volume + description: FSB2_volume_1 + +resources: + + FSB1_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: volume_size} + volume_type: {get_param: volume_type} + name: {get_param: FSB1_volume_name} + image: {get_param: FSB_1_image} + + FSB2_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: volume_size} + volume_type: {get_param: volume_type} + name: {get_param: FSB2_volume_name} + image: {get_param: FSB_2_image} + diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload2/MANIFEST.json b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload2/MANIFEST.json new file mode 100644 index 0000000000..02733a6e3f --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload2/MANIFEST.json @@ -0,0 +1,29 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create vmme 2 fsb 2 ncb 2 gbp 2 vlc", + "version": "2013-05-23", + "data": [ + { + "file": "vmme_small.yml", + "type": "HEAT", + "data": [ + { + "file": "vmme_small.env", + "type": "HEAT_ENV" + },{ + "file": "vmme_small_create_fsb.yml", + "type": "HEAT_NET", + "data":[ + { + "file": "vmme_small_create_fsb.env", + "type": "HEAT_ENV" + } + ] + } + ] + },{ + "file": "create_stack.sh", + "type": "SHELL" + } + ] +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload2/create_stack.sh b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload2/create_stack.sh new file mode 100644 index 0000000000..186d1c34fb --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload2/create_stack.sh @@ -0,0 +1 @@ +heat stack-create vMME -e vmme_small.env -f vmme_small.yml diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload2/vmme_small.env b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload2/vmme_small.env new file mode 100644 index 0000000000..e46cfd2a2d --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload2/vmme_small.env @@ -0,0 +1,97 @@ +parameters: + oam_net_id: 47bf4cca-0961-422f-bcd6-d5a4fbb1a351 + fsb1-name: ZRDM1MMEX33FSB001 + fsb2-name: ZRDM1MMEX33FSB002 + ncb1-name: ZRDM1MMEX33NCB001 + ncb2-name: ZRDM1MMEX33NCB002 + vlc1-name: ZRDM1MMEX33VLC002 + vlc2-name: ZRDM1MMEX33VLC002 + gpb1-name: ZRDM1MMEX33GPB001 + gpb2-name: ZRDM1MMEX33GPB002 + epc-sctp-a-net-name: EPC-SCTP-A + epc-sctp-a-net-rt: 13979:105717 + epc-sctp-a-net-cidr: 107.243.37.0/27 + epc-sctp-a-net-gateway: 107.243.37.1 + epc-sctp-a-pool-start: 107.243.37.3 + epc-sctp-a-pool-end: 107.243.37.30 + epc-sctp-b-net-name: EPC-SCTP-B + epc-sctp-b-net-rt: 13979:105719 + epc-sctp-b-net-cidr: 107.243.37.32/24 + epc-sctp-b-net-gateway: 107.243.37.33 + epc-sctp-b-pool-start: 107.243.37.35 + epc-sctp-b-pool-end: 107.243.37.62 + epc-gtp-net-name: EPC-GTP + epc-gtp-net-rt: 13979:105715 + epc-gtp-net-cidr: 107.243.37.64/27 + epc-gtp-net-gateway: 107.243.37.65 + epc-gtp-pool-start: 107.243.37.67 + epc-gtp-pool-end: 107.243.37.94 + fsb1-image: MME_FSB1_15B-CP04-r5a01 + fsb2-image: MME_FSB2_15B-CP04-r5a01 + fsb1-flavor: m4.xlarge4 + fsb2-flavor: m4.xlarge4 + fsb_zone: nova + fsb1-Internal1-mac: 00:80:37:0E:0B:12 + fsb1-Internal2-mac: 00:81:37:0E:0B:12 + fsb1-oam-ip: 107.250.172.221 + fsb2-Internal1-mac: 00:80:37:0E:0D:12 + fsb2-Internal2-mac: 00:81:37:0E:0D:12 + fsb2-oam-ip: 107.250.172.222 + pxe-image: MME_PXE-BOOT_cxp9025898_2r5a01.qcow2 + ncb-flavor: m4.xlarge4 + ncb_zone: nova + ncb1-Internal1-mac: 00:80:37:0E:09:12 + ncb1-Internal2-mac: 00:81:37:0E:09:12 + ncb2-Internal1-mac: 00:80:37:0E:0F:12 + ncb2-Internal2-mac: 00:81:37:0E:0F:12 + gpb-flavor: m4.xlarge4 + gpb_zone: nova + gpb1-Internal1-mac: 00:80:37:0E:01:22 + gpb1-Internal1-ip: 169.254.0.101 + gpb1-Internal2-mac: 00:81:37:0E:01:22 + gpb2-Internal1-mac: 00:80:37:0E:02:22 + gpb2-Internal2-mac: 00:81:37:0E:02:22 + vlc-flavor: m4.xlarge4 + vlc_zone: nova + vlc1-sctp-a-ip: 107.243.37.3 + vlc1-sctp-b-ip: 107.243.37.35 + vlc1-gtp-ip: 107.243.37.67 + vlc1-oam-ip: 107.250.172.227 + vlc2-sctp-a-ip: 107.243.37.4 + vlc2-sctp-b-ip: 107.243.37.36 + vlc2-gtp-ip: 107.243.37.68 + vlc2-oam-ip: 107.250.172.228 + vlc1-Internal1-mac: 00:80:37:0E:01:12 + vlc1-Internal2-mac: 00:81:37:0E:01:12 + vlc2-Internal1-mac: 00:80:37:0E:02:12 + vlc2-Internal2-mac: 00:81:37:0E:02:12 + Internal1_net_name: vmme_int_int_1 + Internal1_subnet_name: vmme_int_int_sub_1 + Internal1_ipam_name: vmme_ipam_int1 + Internal1_cidr: 169.253.0.0/17 + Internal1_forwarding_mode: "l2" + Internal1_dhcp: "False" + Internal1_shared: "False" + Internal1_external: "False" + Internal1_name: "Internal1-subnet" + Internal1_default_gateway: 169.253.0.3 + Internal1_net_pool_start: 169.253.0.100 + Internal1_net_pool_end: 169.253.0.254 + Internal2_net_name: vmme_int_int_2 + Internal2_subnet_name: vmme_int_int_sub_2 + Internal2_ipam_name: vmme_ipam_int2 + Internal2_cidr: 169.255.0.0/17 + Internal2_shared: "False" + Internal2_external: "False" + Internal2_forwarding_mode: "l2" + Internal2_dhcp: "False" + Internal2_name: "Internal2-subnet" + Internal2_default_gateway: 169.255.0.3 + Internal2_net_pool_start: 169.255.0.100 + Internal2_net_pool_end: 169.255.0.254 + static_prefix_sctp_a_1: 107.239.40.32/30 + static_prefix_gtp_1: 107.239.40.96/30 + static_prefix_sctp_b_1: 107.239.40.64/30 + VMME_FSB1_boot_volume: 8248e794-6173-4b49-b9c3-8219b0b56f4e + VMME_FSB2_boot_volume: 089a0d11-4b15-4370-8343-3f90907b1221 + diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload2/vmme_small.yml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload2/vmme_small.yml new file mode 100644 index 0000000000..ab76c1ce0a --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload2/vmme_small.yml @@ -0,0 +1,661 @@ +heat_template_version: 2013-05-23 + +description: > + HOT template to create vmme 2 fsb 2 ncb 2 gbp 2 vlc + +parameters: + fsb1-oam-ip: + type: string + fsb2-oam-ip: + type: string + vlc1-oam-ip: + type: string + vlc2-oam-ip: + type: string + Internal1_net_pool_start: + type: string + Internal1_net_pool_end: + type: string + Internal2_net_pool_start: + type: string + Internal2_net_pool_end: + type: string + Internal1_default_gateway: + type: string + Internal2_default_gateway: + type: string + Internal1_shared: + type: string + Internal1_external: + type: string + Internal1_net_name: + type: string + Internal1_subnet_name: + type: string + Internal1_ipam_name: + type: string + Internal1_cidr: + type: string + Internal1_forwarding_mode: + type: string + Internal1_dhcp: + type: string + Internal1_name: + type: string + Internal2_net_name: + type: string + Internal2_subnet_name: + type: string + Internal2_ipam_name: + type: string + Internal2_cidr: + type: string + Internal2_forwarding_mode: + type: string + Internal2_dhcp: + type: string + Internal2_name: + type: string + Internal2_shared: + type: string + Internal2_external: + type: string + vlc1-sctp-a-ip: + type: string + vlc1-sctp-b-ip: + type: string + vlc1-gtp-ip: + type: string + vlc2-sctp-a-ip: + type: string + vlc2-sctp-b-ip: + type: string + vlc2-gtp-ip: + type: string + fsb1-name: + type: string + description: Name of fsb1 + fsb2-name: + type: string + description: Name of fsb1 + ncb1-name: + type: string + description: Name of ncb1 + ncb2-name: + type: string + description: Name of ncb2 + vlc1-name: + type: string + description: Name of vlc1 + vlc2-name: + type: string + description: Name of vlc2 + gpb1-name: + type: string + description: Name of gpb1 + gpb2-name: + type: string + description: Name of gpb2 + fsb_zone: + type: string + description: cluster for spawnning fsb instances + fsb1-image: + type: string + description: Name of image to use for server fsb1 + fsb1-flavor: + type: string + description: Flavor to use for servers fsb1 + oam_net_id: + type: string + description: uuid of oam network + fsb1-Internal1-mac: + type: string + description: static mac address assigned to fsb1-Internal1 + fsb1-Internal2-mac: + type: string + description: static mac address assigned to fsb1-Internal2 + fsb2-image: + type: string + description: Name of image to use for server fsb2 + fsb2-flavor: + type: string + description: Flavor to use for servers fsb2 + fsb2-Internal1-mac: + type: string + description: static mac address assigned to fsb2-Internal1 + fsb2-Internal2-mac: + type: string + description: static mac address assigned to fsb2-Internal2 + pxe-image: + type: string + description: Name of image to use for server ncb + ncb-flavor: + type: string + description: Flavor to use for servers ncb + ncb_zone: + type: string + description: cluster for spawnning ncb instances + ncb1-Internal1-mac: + type: string + description: static mac address assigned to ncb1-Internal1 + ncb1-Internal2-mac: + type: string + description: static mac address assigned to ncb1-Internal2 + ncb2-Internal1-mac: + type: string + description: static mac address assigned to ncb2-Internal1 + ncb2-Internal2-mac: + type: string + description: static mac address assigned to ncb2-Internal2 + gpb-flavor: + type: string + description: Flavor to use for servers gpb + gpb_zone: + type: string + description: cluster for spawnning gpb instances + gpb1-Internal1-ip: + type: string + gpb1-Internal1-mac: + type: string + description: static mac address assigned to gpb1-Internal1 + gpb1-Internal2-mac: + type: string + description: static mac address assigned to gpb1-Internal2 + gpb2-Internal1-mac: + type: string + description: static mac address assigned to gpb2-Internal1 + gpb2-Internal2-mac: + type: string + description: static mac address assigned to gpb2-Internal2 + vlc-flavor: + type: string + description: Flavor to use for servers vlc + vlc_zone: + type: string + description: cluster for spawnning vlc instances + vlc1-Internal1-mac: + type: string + description: static mac address assigned to vlc1-Internal1 + vlc1-Internal2-mac: + type: string + description: static mac address assigned to vlc1-Internal2 + vlc2-Internal1-mac: + type: string + description: static mac address assigned to vlc2-Internal1 + vlc2-Internal2-mac: + type: string + description: static mac address assigned to vlc2-Internal2 + epc-sctp-a-net-name: + type: string + description: epc-sctp-a net name + epc-sctp-a-net-rt: + type: string + description: epc-sctp-a route target + epc-sctp-a-net-cidr: + type: string + description: epc-sctp-a subnet + epc-sctp-a-net-gateway: + type: string + description: epc-sctp-a-net network gateway + epc-sctp-a-pool-start: + type: string + description: epc-sctp-a-net network ip pool start IP address + epc-sctp-a-pool-end: + type: string + description: epc-sctp-a-net network ip pool end IP address + epc-sctp-b-net-name: + type: string + description: epc-sctp-b net name + epc-sctp-b-net-rt: + type: string + description: epc-sctp-b route target + epc-sctp-b-net-cidr: + type: string + description: epc-sctp-b subnet + epc-sctp-b-net-gateway: + type: string + description: epc-sctp-b-net network gateway + epc-sctp-b-pool-start: + type: string + description: epc-sctp-b-net network ip pool start IP address + epc-sctp-b-pool-end: + type: string + description: epc-sctp-b-net network ip pool end IP address + epc-gtp-net-name: + type: string + description: gtp net name + epc-gtp-net-rt: + type: string + description: gtp route target + epc-gtp-net-cidr: + type: string + description: gtp stubnet + epc-gtp-net-gateway: + type: string + description: gtp network gateway + epc-gtp-pool-start: + type: string + description: gtp network ip pool start IP address + epc-gtp-pool-end: + type: string + description: gtp network ip pool end IP address + static_prefix_sctp_a_1: + type: string + description: Static Prefix + static_prefix_sctp_b_1: + type: string + description: Static Prefix + static_prefix_gtp_1: + type: string + description: Static Prefix + VMME_FSB1_boot_volume: + type: string + VMME_FSB2_boot_volume: + type: string + +resources: + Internal1_ipam: + type: OS::Contrail::NetworkIpam + properties: + name: { get_param: Internal1_ipam_name } + + Internal2_ipam: + type: OS::Contrail::NetworkIpam + properties: + name: { get_param: Internal2_ipam_name } + + Internal1-net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: Internal1_net_name } + template: { get_file: create_stack.sh } + forwarding_mode: { get_param: Internal1_forwarding_mode } + shared: { get_param: Internal1_shared } + external: true +# route_targets: { "Fn::Split" : [ ",", Ref: route_targets ] } + testConvertGetParamFunctions: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: Internal1_net_name } + forwarding_mode: { get_param: Internal1_forwarding_mode } + shared: { get_param: Internal1_shared } + +# route_targets: { "Fn::Split" : [ ",", Ref: route_targets ] } + testConvertGetAttributeFunctions: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: Internal1_net_name } + forwarding_mode: { get_param: Internal1_forwarding_mode } + shared: { get_param: Internal1_shared } + external: { get_param: Internal1_external } +# route_targets: { "Fn::Split" : [ ",", Ref: route_targets ] } + + Internal1-subnet: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: Internal1-net } + cidr: { get_param: Internal1_cidr } + gateway_ip: { get_param: Internal1_default_gateway } + enable_dhcp: { get_param: Internal1_dhcp } + + +# Internal1-subnet: +# type: OS::Contrail::VnSubnet +# properties: +# name: { get_param: Internal1_subnet_name } +# network: { get_resource: Internal1-net } +# ip_prefix: { get_param: Internal1_cidr } + # ipam: { get_resource: Internal1_ipam } + # enable_dhcp: { get_param: Internal1_dhcp } + # default_gateway: { get_param: Internal1_default_gateway } + # allocation_pools: + # - start: { get_param: Internal1_net_pool_start } + # end: { get_param: Internal1_net_pool_end } + + + + Internal2-net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: Internal2_name } + forwarding_mode: { get_param: Internal2_forwarding_mode } + shared: { get_param: Internal2_shared } + external: { get_param: Internal2_external } +# route_targets: { "Fn::Split" : [ ",", Ref: route_targets ] } + +# Internal2-subnet: +# type: OS::Contrail::VnSubnet +# properties: +# name: { get_param: Internal2_subnet_name } +# network: { get_resource: Internal2-net } +# ip_prefix: { get_param: Internal2_cidr } +# ipam: { get_resource: Internal2_ipam } +# enable_dhcp: { get_param: Internal2_dhcp } +# default_gateway: { get_param: Internal2_default_gateway } +# allocation_pools: +# - start: { get_param: Internal2_net_pool_start } +# end: { get_param: Internal2_net_pool_end } + + Internal2-subnet: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: Internal2-net } + cidr: { get_param: Internal2_cidr } + gateway_ip: { get_param: Internal2_default_gateway } + enable_dhcp: { get_param: Internal2_dhcp } + + epc-sctp-a-net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: epc-sctp-a-net-name } + route_targets: [ get_param: epc-sctp-a-net-rt ] + + + epc-sctp-a-subnet: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: epc-sctp-a-net } + cidr: { get_param: epc-sctp-a-net-cidr } + gateway_ip: { get_param: epc-sctp-a-net-gateway } + allocation_pools: + - start: { get_param: epc-sctp-a-pool-start } + end: { get_param: epc-sctp-a-pool-end } + + epc-sctp-b-net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: epc-sctp-b-net-name } + route_targets: [ get_param: epc-sctp-b-net-rt ] + + epc-sctp-b-subnet: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: epc-sctp-b-net } + cidr: { get_param: epc-sctp-b-net-cidr } + gateway_ip: { get_param: epc-sctp-b-net-gateway } + allocation_pools: + - start: { get_param: epc-sctp-b-pool-start } + end: { get_param: epc-sctp-b-pool-end } + + epc-gtp-net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: epc-gtp-net-name } + route_targets: [ get_param: epc-gtp-net-rt ] + + epc-gtp-subnet: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: epc-gtp-net } + cidr: { get_param: epc-gtp-net-cidr } + gateway_ip: { get_param: epc-gtp-net-gateway } + allocation_pools: + - start: { get_param: epc-gtp-pool-start } + end: { get_param: epc-gtp-pool-end } + + FSB1: + type: OS::Nova::Server + properties: + name: { get_param: fsb1-name } + block_device_mapping: [{device_name: "vda", volume_id : {get_param: VMME_FSB1_boot_volume }, delete_on_termination: "false" }] + flavor: { get_param: fsb1-flavor } + availability_zone: { get_param: fsb_zone } + networks: + - port: { get_resource: FSB1_Internal1 } + - port: { get_resource: FSB1_Internal2 } + - port: { get_resource: FSB1_OAM } + + FSB1_Internal1: + type: OS::Neutron::Port + properties: + network_id: { get_resource: Internal1-net } + mac_address: { get_param: fsb1-Internal1-mac } + + FSB1_Internal2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: Internal2-net } + mac_address: { get_param: fsb1-Internal2-mac } + + FSB1_OAM: + type: OS::Neutron::Port + properties: + network_id: { get_param: oam_net_id } + fixed_ips: + - ip_address: { get_param: fsb1-oam-ip } + + FSB2: + type: OS::Nova::Server + properties: + name: { get_param: fsb2-name } + block_device_mapping: [{device_name: "vda", volume_id : {get_param: VMME_FSB2_boot_volume }, delete_on_termination: "false" }] + flavor: { get_param: fsb2-flavor } + availability_zone: { get_param: fsb_zone } + networks: + - port: { get_resource: FSB2_Internal1 } + - port: { get_resource: FSB2_Internal2 } + - port: { get_resource: FSB2_OAM } + + FSB2_Internal1: + type: OS::Neutron::Port + properties: + network_id: { get_resource: Internal1-net } + mac_address: { get_param: fsb2-Internal1-mac } + + + FSB2_Internal2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: Internal2-net } + mac_address: { get_param: fsb2-Internal2-mac } + + FSB2_OAM: + type: OS::Neutron::Port + properties: + network_id: { get_param: oam_net_id } + fixed_ips: + - ip_address: { get_param: fsb2-oam-ip } + + NCB1: + type: OS::Nova::Server + properties: + name: { get_param: ncb1-name } + image: { get_param: pxe-image } + flavor: { get_param: ncb-flavor } + availability_zone: { get_param: ncb_zone } + networks: + - port: { get_resource: NCB1_Internal1 } + - port: { get_resource: NCB1_Internal2 } + + NCB1_Internal1: + type: OS::Neutron::Port + properties: + network_id: { get_resource: Internal1-net } + mac_address: { get_param: ncb1-Internal1-mac } + + NCB1_Internal2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: Internal2-net } + mac_address: { get_param: ncb1-Internal2-mac } + + NCB2: + type: OS::Nova::Server + properties: + name: { get_param: ncb2-name } + image: { get_param: pxe-image } + flavor: { get_param: ncb-flavor } + availability_zone: { get_param: ncb_zone } + networks: + - port: { get_resource: NCB2_Internal1 } + - port: { get_resource: NCB2_Internal2 } + + NCB2_Internal1: + type: OS::Neutron::Port + properties: + network_id: { get_resource: Internal1-net } + mac_address: { get_param: ncb2-Internal1-mac } + + NCB2_Internal2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: Internal2-net } + mac_address: { get_param: ncb2-Internal2-mac } + + GPB1: + type: OS::Nova::Server + properties: + name: { get_param: gpb1-name } + image: { get_param: pxe-image } + flavor: { get_param: gpb-flavor } + availability_zone: { get_param: gpb_zone } + networks: + - port: { get_resource: GPB1_Internal1 } + - port: { get_resource: GPB1_Internal2 } + + GPB1_Internal1: + type: OS::Neutron::Port + properties: + network_id: { get_resource: Internal1-net } + mac_address: { get_param: gpb1-Internal1-mac } + + GPB1_Internal2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: Internal2-net } + mac_address: { get_param: gpb1-Internal2-mac } + + GPB2: + type: OS::Nova::Server + properties: + name: { get_param: gpb2-name } + image: { get_param: pxe-image } + flavor: { get_param: gpb-flavor } + availability_zone: { get_param: gpb_zone } + networks: + - port: { get_resource: GPB2_Internal1 } + - port: { get_resource: GPB2_Internal2 } + + GPB2_Internal1: + type: OS::Neutron::Port + properties: + network_id: { get_resource: Internal1-net } + mac_address: { get_param: gpb2-Internal1-mac } + + GPB2_Internal2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: Internal2-net } + mac_address: { get_param: gpb2-Internal2-mac } + + VLC1: + type: OS::Nova::Server + properties: + name: { get_param: vlc1-name } + image: { get_param: pxe-image } + flavor: { get_param: vlc-flavor } + availability_zone: { get_param: vlc_zone } + networks: + - port: { get_resource: VLC1_Internal1 } + - port: { get_resource: VLC1_Internal2 } + - port: { get_resource: VLC1_OAM } + - port: { get_resource: VLC1_SCTP_A } + - port: { get_resource: VLC1_SCTP_B } + - port: { get_resource: VLC1_GTP } + + VLC1_Internal1: + type: OS::Neutron::Port + properties: + network_id: { get_resource: Internal1-net } + mac_address: { get_param: vlc1-Internal1-mac } + + VLC1_Internal2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: Internal2-net } + mac_address: { get_param: vlc1-Internal2-mac } + + VLC1_OAM: + type: OS::Neutron::Port + properties: + network_id: { get_param: oam_net_id } + fixed_ips: + - ip_address: { get_param: vlc1-oam-ip } + + VLC1_SCTP_A: + type: OS::Neutron::Port + properties: + network_id: { get_resource: epc-sctp-a-net } + fixed_ips: + - ip_address: { get_param: vlc1-sctp-a-ip } + + VLC1_SCTP_B: + type: OS::Neutron::Port + properties: + network_id: { get_resource: epc-sctp-b-net } + fixed_ips: + - ip_address: { get_param: vlc1-sctp-b-ip } + + VLC1_GTP: + type: OS::Neutron::Port + properties: + network_id: { get_resource: epc-gtp-net } + fixed_ips: + - ip_address: { get_param: vlc1-gtp-ip } + + VLC2: + type: OS::Nova::Server + properties: + name: { get_param: vlc2-name } + image: { get_param: pxe-image } + flavor: { get_param: vlc-flavor } + availability_zone: { get_param: vlc_zone } + networks: + - port: { get_resource: VLC2_Internal1 } + - port: { get_resource: VLC2_Internal2 } + - port: { get_resource: VLC2_OAM } + - port: { get_resource: VLC2_SCTP_A } + - port: { get_resource: VLC2_SCTP_B } + - port: { get_resource: VLC2_GTP } + + + VLC2_Internal1: + type: OS::Neutron::Port + properties: + network_id: { get_resource: Internal1-net } + mac_address: { get_param: vlc2-Internal1-mac } + + VLC2_OAM: + type: OS::Neutron::Port + properties: + network_id: { get_param: oam_net_id } + fixed_ips: + - ip_address: { get_param: vlc2-oam-ip } + + VLC2_Internal2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: Internal2-net } + mac_address: { get_param: vlc2-Internal2-mac } + + VLC2_SCTP_A: + type: OS::Neutron::Port + properties: + network_id: { get_resource: epc-sctp-a-net } + fixed_ips: + - ip_address: { get_param: vlc2-sctp-a-ip } + + VLC2_SCTP_B: + type: OS::Neutron::Port + properties: + network_id: { get_resource: epc-sctp-b-net } + fixed_ips: + - ip_address: { get_param: vlc2-sctp-b-ip } + + VLC2_GTP: + type: OS::Neutron::Port + properties: + network_id: { get_resource: epc-gtp-net } + fixed_ips: + - ip_address: { get_param: vlc2-gtp-ip } + diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload2/vmme_small_create_fsb.env b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload2/vmme_small_create_fsb.env new file mode 100644 index 0000000000..750bb2dd44 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload2/vmme_small_create_fsb.env @@ -0,0 +1,8 @@ +parameters: + volume_type: Gold + volume_size: 320 + FSB_1_image: MME_FSB1_15B-CP04-r5a01 + FSB_2_image: MME_FSB2_15B-CP04-r5a01 + FSB1_volume_name: vFSB1_1_Vol_1 + FSB2_volume_name: vFSB2_1_Vol_1 + diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload2/vmme_small_create_fsb.yml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload2/vmme_small_create_fsb.yml new file mode 100644 index 0000000000..2d695a50c1 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/legalUpload2/vmme_small_create_fsb.yml @@ -0,0 +1,54 @@ +heat_template_version: 2013-05-23 + +description: server template for vMME + +parameters: + + volume_type: + type: string + label: volume type + description: volume type Gold + + volume_size: + type: number + label: volume size + description: my volume size 320GB + + FSB_1_image: + type: string + label: MME_FSB1 + description: MME_FSB1_15B-CP04-r5a01 + + FSB_2_image: + type: string + label: MME_FSB2 + description: MME_FSB2_15B-CP04-r5a01 + + FSB1_volume_name: + type: string + label: FSB1_volume + description: FSB1_volume_1 + + FSB2_volume_name: + type: string + label: FSB2_volume + description: FSB2_volume_1 + +resources: + + FSB1_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: volume_size} + volume_type: {get_param: volume_type} + name: {get_param: FSB1_volume_name} + image: {get_param: FSB_1_image} + + FSB2_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: volume_size} + volume_type: {get_param: volume_type} + name: {get_param: FSB2_volume_name} + image: {get_param: FSB_2_image} + diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/missingYml/MANIFEST.json b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/missingYml/MANIFEST.json new file mode 100644 index 0000000000..2ff7eec20e --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/missingYml/MANIFEST.json @@ -0,0 +1,20 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create vmme 2 fsb 2 ncb 2 gbp 2 vlc", + "version": "2013-05-23", + "data": [ + { + "file": "vmme_small_create_fsb.yml", + "type": "HEAT", + "data": [ + { + "file": "vmme_small_create_fsb.env", + "type": "HEAT_ENV" + } + ] + },{ + "file": "create_stack.sh", + "type": "SHELL" + } + ] +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/missingYml/create_stack.sh b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/missingYml/create_stack.sh new file mode 100644 index 0000000000..186d1c34fb --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/missingYml/create_stack.sh @@ -0,0 +1 @@ +heat stack-create vMME -e vmme_small.env -f vmme_small.yml diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/missingYml/vmme_small_create_fsb.env b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/missingYml/vmme_small_create_fsb.env new file mode 100644 index 0000000000..750bb2dd44 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/missingYml/vmme_small_create_fsb.env @@ -0,0 +1,8 @@ +parameters: + volume_type: Gold + volume_size: 320 + FSB_1_image: MME_FSB1_15B-CP04-r5a01 + FSB_2_image: MME_FSB2_15B-CP04-r5a01 + FSB1_volume_name: vFSB1_1_Vol_1 + FSB2_volume_name: vFSB2_1_Vol_1 + diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/HEAT.meta b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/HEAT.meta new file mode 100644 index 0000000000..3981576218 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/HEAT.meta @@ -0,0 +1,215 @@ +{ + "importStructure": [ + { + "HEAT": [ + { + "fileName": "hot-nimbus-oam_v1.0.yaml", + "env": "hot-nimbus-oam_v1.0.env", + "volume": [ + { + "fileName": "hot-nimbus-oam-volumes_v1.0.yaml", + "env": "hot-nimbus-oam-volumes_v1.0.env" + } + ], + "nested": [ + { + "fileName": "nested-oam_v1.0.yaml" + }, + { + "fileName": "nested-oam_v1.0.yaml" + } + ], + "artifacts": [ + { + "name": "mount_iso_script.sh", + "status": "OK" + }, + { + "name": "cloud-nimbus.sh", + "status": "OK" + }, + { + "name": "nimbus-ethernet", + "status": "OK" + }, + { + "name": "nimbus-ethernet-gw", + "status": "OK" + } + ] + }, + { + "fileName": "hot-nimbus-pps_v1.0.yaml", + "env": "hot-nimbus-pps_v1.0.env", + "nested": [ + { + "fileName": "nested-pps_v1.0.yaml" + }, + { + "fileName": "nested-pps_v1.0.yaml" + }, + { + "fileName": "nested-pps_v1.0.yaml" + }, + { + "fileName": "nested-pps_v1.0.yaml" + }, + { + "fileName": "nested-pps_v1.0.yaml" + }, + { + "fileName": "nested-pps_v1.0.yaml" + } + ], + "artifacts": [ + { + "name": "mount_iso_script.sh", + "status": "OK" + }, + { + "name": "cloud-nimbus.sh", + "status": "OK" + }, + { + "name": "nimbus-ethernet", + "status": "OK" + }, + { + "name": "nimbus-ethernet-gw", + "status": "OK" + } + ] + }, + { + "fileName": "hot-nimbus-psm_v1.0.yaml", + "env": "hot-nimbus-psm_v1.0.env", + "nested": [ + { + "fileName": "nested-psm_v1.0.yaml" + }, + { + "fileName": "nested-psm_v1.0.yaml" + }, + { + "fileName": "nested-psm_v1.0.yaml" + }, + { + "fileName": "nested-psm_v1.0.yaml" + }, + { + "fileName": "nested-psm_v1.0.yaml" + }, + { + "fileName": "nested-psm_v1.0.yaml" + }, + { + "fileName": "nested-psm_v1.0.yaml" + }, + { + "fileName": "nested-psm_v1.0.yaml" + }, + { + "fileName": "nested-psm_v1.0.yaml" + }, + { + "fileName": "nested-psm_v1.0.yaml" + }, + { + "fileName": "nested-psm_v1.0.yaml" + }, + { + "fileName": "nested-psm_v1.0.yaml" + } + ], + "artifacts": [ + { + "name": "mount_iso_script.sh", + "status": "OK" + }, + { + "name": "cloud-nimbus.sh", + "status": "OK" + }, + { + "name": "nimbus-ethernet", + "status": "OK" + }, + { + "name": "nimbus-ethernet-gw", + "status": "OK" + } + ] + }, + { + "fileName": "hot-nimbus-ppd_v1.0.yaml", + "env": "hot-nimbus-ppd_v1.1.env", + "nested": [ + { + "fileName": "nested-ppd_v1.0.yaml" + }, + { + "fileName": "nested-ppd_v1.0.yaml" + }, + { + "fileName": "nested-ppd_v1.0.yaml" + }, + { + "fileName": "nested-ppd_v1.0.yaml" + } + ], + "artifacts": [ + { + "name": "mount_iso_script.sh", + "status": "OK" + }, + { + "name": "cloud-nimbus.sh", + "status": "OK" + }, + { + "name": "nimbus-ethernet", + "status": "OK" + }, + { + "name": "nimbus-ethernet-gw", + "status": "OK" + } + ] + }, + { + "fileName": "hot-nimbus-pcm_v1.0.yaml", + "env": "hot-nimbus-pcm_v1.0.env", + "volume": [ + { + "fileName": "hot-nimbus-pcm-volumes_v1.0.yaml", + "env": "hot-nimbus-pcm-volumes_v1.0.env" + } + ], + "nested": [ + { + "fileName": "nested-pcm_v1.0.yaml" + } + ], + "artifacts": [ + { + "name": "mount_iso_script.sh", + "status": "OK" + }, + { + "name": "cloud-nimbus.sh", + "status": "OK" + }, + { + "name": "nimbus-ethernet", + "status": "OK" + }, + { + "name": "nimbus-ethernet-gw", + "status": "OK" + } + ] + } + ] + } + ] +} \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/MANIFEST.json b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/MANIFEST.json new file mode 100644 index 0000000000..d85265d118 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/MANIFEST.json @@ -0,0 +1,113 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-oam_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-oam_v1.0.env", + "type": "HEAT_ENV" + }, + { + "file": "hot-nimbus-oam-volumes_v1.0.yaml", + "type": "HEAT_VOL", + "data": [ + { + "file": "hot-nimbus-oam-volumes_v1.0.env", + "type": "HEAT_ENV" + } + ] + } + ] + }, + { + "file": "hot-nimbus-pcm_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pcm_v1.0.env", + "type": "HEAT_ENV" + }, + { + "file": "hot-nimbus-pcm-volumes_v1.0.yaml", + "type": "HEAT_VOL", + "data": [ + { + "file": "hot-nimbus-pcm-volumes_v1.0.env", + "type": "HEAT_ENV" + } + ] + } + ] + }, + { + "file": "hot-nimbus-ppd_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-ppd_v1.1.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "hot-nimbus-psm_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "nested-oam_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "nested-pcm_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "nested-ppd_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "nested-pps_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "nested-psm_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "mount_iso_script.sh", + "type": "SHELL" + }, + { + "file": "cloud-nimbus.sh", + "type": "SHELL" + }, + { + "file": "nimbus-ethernet", + "type": "OTHER" + }, + { + "file": "nimbus-ethernet-gw", + "type": "OTHER" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/cloud-nimbus.sh b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/cloud-nimbus.sh new file mode 100644 index 0000000000..8e5a486289 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/cloud-nimbus.sh @@ -0,0 +1,12 @@ +#!/bin/bash +echo "Running first-boot script" +FLAG="first-boot.sh" +echo "First boot run" > ${FLAG} +echo "$vm_name" >> ${FLAG} +touch /var/lib/cloud/instance/payload/launch-params +chmod 644 /var/lib/cloud/instance/payload/launch-params +#for i in $(ls /sys/class/net); do +# echo "Restart $i" >> ${FLAG} +# ifdown ${i} +# ifup ${i} +#done diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-oam-volumes_v1.0.env b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-oam-volumes_v1.0.env new file mode 100644 index 0000000000..b494d8c270 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-oam-volumes_v1.0.env @@ -0,0 +1,6 @@ +parameters: + pcrf_oam_vol_size: 500 + pcrf_oam_volume_silver-1: Silver + pcrf_oam_volume_silver-2: Silver + pcrf_oam_vol_name_1: sde1-pcrfx01-oam001-vol-1 + pcrf_oam_vol_name_2: sde1-pcrfx01-oam001-vol-2 \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-oam-volumes_v1.0.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-oam-volumes_v1.0.yaml new file mode 100644 index 0000000000..9e120547b4 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-oam-volumes_v1.0.yaml @@ -0,0 +1,45 @@ +heat_template_version: 2013-05-23 + +parameters: + pcrf_oam_vol_size: + type: number + label: Cinder volume size + description: the size of the Cinder volume + pcrf_oam_vol_name_1: + type: string + label: OAM volume name 1 + description: Assigning name to volume + pcrf_oam_vol_name_2: + type: string + label: OAM volume name 2 + description: Assigning name to volume + pcrf_oam_volume_silver-1: + type: string + label: vm volume type + description: the name of the target volume backend for OAM1 + pcrf_oam_volume_silver-2: + type: string + label: vm volume type + description: the name of the target volume backend for OAM2 + +resources: + pcrf_oam_volume_1: + type: OS::Cinder::Volume + properties: + size: {get_param: pcrf_oam_vol_size} + volume_type: {get_param: pcrf_oam_volume_silver-1} + name: {get_param: pcrf_oam_vol_name_1} + + pcrf_oam_volume_2: + type: OS::Cinder::Volume + properties: + size: {get_param: pcrf_oam_vol_size} + volume_type: {get_param: pcrf_oam_volume_silver-2} + name: {get_param: pcrf_oam_vol_name_2} +outputs: + pcrf_oam_volume_id_1: + description: the oam 001 volume id + value: { get_resource: pcrf_oam_volume_1 } + pcrf_oam_volume_id_2: + description: the oam 002 volume id + value: { get_resource: pcrf_oam_volume_2 } \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-oam_v1.0.env b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-oam_v1.0.env new file mode 100644 index 0000000000..138feb5822 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-oam_v1.0.env @@ -0,0 +1,18 @@ +parameters: + pcrf_oam_server_names: ZRDM1PCRF01OAM001,ZRDM1PCRF01OAM002 + pcrf_oam_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_oam_flavor_name: lc.4xlarge4 + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.111,172.26.16.112 + pcrf_arbiter_vip: 172.26.16.115 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_oam_net_name: MNS-25180-L-01_oam_protected_net_0 + pcrf_oam_net_ips: 107.239.64.117,107.239.64.118 + pcrf_oam_net_gw: 107.239.64.1 + pcrf_oam_net_mask: 255.255.248.0 + pcrf_oam_volume_id_1: a4aa05fb-fcdc-457b-8077-6845fdfc3257 + pcrf_oam_volume_id_2: 93d8fc1f-f1c3-4933-86b2-039881ee910f + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-oam_v1.0.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-oam_v1.0.yaml new file mode 100644 index 0000000000..2aa1235de2 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-oam_v1.0.yaml @@ -0,0 +1,109 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates multiple PCRF OAM nodes stack + +parameters: + pcrf_oam_server_names: + type: comma_delimited_list + label: PCRF OAM server names + description: name of the PCRF OAM instance + pcrf_oam_image_name: + type: string + label: PCRF OAM image name + description: PCRF OAM image name + pcrf_oam_flavor_name: + type: string + label: PCRF OAM flavor name + description: flavor name of PCRF OAM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_arbiter_vip: + type: string + label: OAM Arbiter LB VIP + description: OAM Arbiter LB VIP + pcrf_oam_net_name: + type: string + label: OAM network name + description: OAM network name + pcrf_oam_net_ips: + type: comma_delimited_list + label: OAM network ips + description: OAM network ips + pcrf_oam_net_gw: + type: string + label: CPS network gateway + description: CPS network gateway + pcrf_oam_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_oam_volume_id_1: + type: string + label: CPS OAM 001 Cinder Volume + description: CPS OAM 001 Cinder Volumes + pcrf_oam_volume_id_2: + type: string + label: CPS OAM 002 Cinder Volume + description: CPS OAM 002 Cinder Volumes + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_oam_001: + type: nested-oam_v1.0.yaml + properties: + pcrf_oam_server_name: { get_param: [pcrf_oam_server_names, 0] } + pcrf_oam_image_name: { get_param: pcrf_oam_image_name } + pcrf_oam_flavor_name: { get_param: pcrf_oam_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_oam_volume_id: { get_param: pcrf_oam_volume_id_1 } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_oam_net_name: { get_param: pcrf_oam_net_name } + pcrf_oam_net_ip: { get_param: [pcrf_oam_net_ips, 0] } + pcrf_oam_net_mask: { get_param: pcrf_oam_net_mask } + pcrf_oam_net_gw: { get_param: pcrf_oam_net_gw } + pcrf_arbiter_vip: { get_param: pcrf_arbiter_vip } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_oam_002: + type: nested-oam_v1.0.yaml + depends_on: [server_pcrf_oam_001] + properties: + pcrf_oam_server_name: { get_param: [pcrf_oam_server_names, 1] } + pcrf_oam_image_name: { get_param: pcrf_oam_image_name } + pcrf_oam_flavor_name: { get_param: pcrf_oam_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_oam_volume_id: { get_param: pcrf_oam_volume_id_2 } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_oam_net_name: { get_param: pcrf_oam_net_name } + pcrf_oam_net_ip: { get_param: [pcrf_oam_net_ips, 1] } + pcrf_oam_net_mask: { get_param: pcrf_oam_net_mask } + pcrf_oam_net_gw: { get_param: pcrf_oam_net_gw } + pcrf_arbiter_vip: { get_param: pcrf_arbiter_vip } + pcrf_vnf_id: {get_param: pcrf_vnf_id} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-pcm-volumes_v1.0.env b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-pcm-volumes_v1.0.env new file mode 100644 index 0000000000..788365dcd3 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-pcm-volumes_v1.0.env @@ -0,0 +1,4 @@ +parameters: + pcrf_pcm_vol_size: 50 + pcrf_pcm_volume_silver: Silver + pcrf_pcm_vol_name_1: sde1-pcrfx01-pcm001-vol-1 diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-pcm-volumes_v1.0.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-pcm-volumes_v1.0.yaml new file mode 100644 index 0000000000..bcc3e89f71 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-pcm-volumes_v1.0.yaml @@ -0,0 +1,28 @@ +heat_template_version: 2013-05-23 + +parameters: + pcrf_pcm_vol_size: + type: number + label: Cinder volume size + description: the size of the Cinder volume + pcrf_pcm_vol_name_1: + type: string + label: PCM volume name + description: Assigning name to volume + pcrf_pcm_volume_silver: + type: string + label: vm volume type + description: the name of the target volume backend for PCM + +resources: + pcrf_pcm_volume_1: + type: OS::Cinder::Volume + properties: + size: { get_param: pcrf_pcm_vol_size } + volume_type: { get_param: pcrf_pcm_volume_silver } + name: { get_param: pcrf_pcm_vol_name_1 } + +outputs: + pcrf_pcm_volume_id_1: + description: the pcrf_pcm_volume_id + value: { get_resource: pcrf_pcm_volume_1 } \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-pcm_v1.0.env b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-pcm_v1.0.env new file mode 100644 index 0000000000..82fb510291 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-pcm_v1.0.env @@ -0,0 +1,16 @@ +parameters: + pcrf_pcm_server_names: ZRDM1PCRF01PCM001 + pcrf_pcm_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pcm_flavor_name: lc.2xlarge4 + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.113 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_oam_net_name: MNS-25180-L-01_oam_protected_net_0 + pcrf_oam_net_ips: 107.239.64.121 + pcrf_oam_net_gw: 107.239.64.1 + pcrf_oam_net_mask: 255.255.248.0 + pcrf_pcm_volume_id_1: 3438a3fe-1241-4390-80f2-d0b86238c40e + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-pcm_v1.0.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-pcm_v1.0.yaml new file mode 100644 index 0000000000..2dd7480bfc --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-pcm_v1.0.yaml @@ -0,0 +1,80 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Cluman stack + +parameters: + pcrf_pcm_server_names: + type: comma_delimited_list + label: PCRF CM server names + description: name of the PCRF CM instance + pcrf_pcm_image_name: + type: string + label: PCRF CM image name + description: PCRF CM image name + pcrf_pcm_flavor_name: + type: string + label: PCRF CM flavor name + description: flavor name of PCRF CM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_oam_net_name: + type: string + label: OAM network name + description: OAM network name + pcrf_oam_net_ips: + type: comma_delimited_list + label: OAM network ips + description: OAM network ips + pcrf_oam_net_gw: + type: string + label: CPS network gateway + description: CPS network gateway + pcrf_oam_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_pcm_volume_id_1: + type: string + label: CPS Cluman Cinder Volume + description: CPS Cluman Cinder Volume + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_pcm_001: + type: nested-pcm_v1.0.yaml + properties: + pcrf_pcm_server_name: { get_param: [pcrf_pcm_server_names, 0] } + pcrf_pcm_image_name: { get_param: pcrf_pcm_image_name } + pcrf_pcm_flavor_name: { get_param: pcrf_pcm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_pcm_volume_id: { get_param: pcrf_pcm_volume_id_1 } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_oam_net_name: { get_param: pcrf_oam_net_name } + pcrf_oam_net_ip: { get_param: [pcrf_oam_net_ips, 0] } + pcrf_oam_net_mask: { get_param: pcrf_oam_net_mask } + pcrf_oam_net_gw: { get_param: pcrf_oam_net_gw } + pcrf_vnf_id: {get_param: pcrf_vnf_id} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-ppd_v1.0.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-ppd_v1.0.yaml new file mode 100644 index 0000000000..2fffa0df8c --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-ppd_v1.0.yaml @@ -0,0 +1,286 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Director stack + +parameters: + pcrf_ppd_server_names: + type: comma_delimited_list + label: PCRF PD server names + description: name of the PCRF PD instance + pcrf_ppd_image_name: + type: string + label: PCRF PD image name + description: PCRF PD image name + pcrf_ppd_flavor_name: + type: string + label: PCRF PD flavor name + description: flavor name of PCRF PD instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_lb_internal_vip: + type: string + label: CPS Internal LB VIP + description: CPS Internal LB VIP + pcrf_oam_net_name: + type: string + label: OAM network name + description: OAM network name + pcrf_oam_net_ips: + type: comma_delimited_list + label: OAM network ips + description: OAM network ips + pcrf_oam_net_gw: + type: string + label: CPS network gateway + description: CPS network gateway + pcrf_oam_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_lb_management_vip: + type: string + label: CPS OAM LB VIP + description: CPS OAM LB VIP + pcrf_gx_net_name: + type: string + label: Gx network name + description: Gx network name + pcrf_gx_net_ips: + type: comma_delimited_list + label: Gx network ips + description: Gx network ips + pcrf_gx_net_mask: + type: string + label: Gx network mask + description: Gx network mask + pcrf_sp_net_name: + type: string + label: Sp network name + description: Sp network name + pcrf_sp_net_ips: + type: comma_delimited_list + label: Sp network ips + description: Sp network ips + pcrf_sp_net_mask: + type: string + label: Sp network mask + description: Sp network mask + pcrf_sy_net_name: + type: string + label: Sy network name + description: Sy network name + pcrf_sy_net_ips: + type: comma_delimited_list + label: Sy network ips + description: Sy network ips + pcrf_sy_net_mask: + type: string + label: Sy network mask + description: Sy network mask + pcrf_rx_net_name: + type: string + label: Rx network name + description: Rx network name + pcrf_rx_net_ips: + type: comma_delimited_list + label: Rx network ips + description: Rx network ips + pcrf_rx_net_mask: + type: string + label: Rx network mask + description: Rx network mask + pcrf_sd_net_name: + type: string + label: Sd network name + description: Sd network name + pcrf_sd_net_ips: + type: comma_delimited_list + label: Sd network ips + description: Sd network ips + pcrf_sd_net_mask: + type: string + label: Sd network mask + description: Sd network mask + pcrf_sgi_sy_net_name: + type: string + label: Sgi Sy network name + description: Sgi Sy network name + pcrf_sgi_sy_net_ips: + type: comma_delimited_list + label: Sgi Sy network ips + description: Sgi Sy network ips + pcrf_sgi_sy_net_mask: + type: string + label: Sgi Sy network mask + description: Sgi Sy network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_ppd_001: + type: nested-ppd_v1.0.yaml + properties: + pcrf_ppd_server_name: { get_param: [pcrf_ppd_server_names, 0] } + pcrf_ppd_image_name: { get_param: pcrf_ppd_image_name } + pcrf_ppd_flavor_name: { get_param: pcrf_ppd_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_lb_internal_vip: { get_param: pcrf_lb_internal_vip } + pcrf_oam_net_name: { get_param: pcrf_oam_net_name } + pcrf_oam_net_ip: { get_param: [pcrf_oam_net_ips, 0] } + pcrf_oam_net_mask: { get_param: pcrf_oam_net_mask } + pcrf_oam_net_gw: { get_param: pcrf_oam_net_gw } + pcrf_lb_management_vip: { get_param: pcrf_lb_management_vip } + pcrf_gx_net_name: { get_param: pcrf_gx_net_name } + pcrf_gx_net_ip: { get_param: [pcrf_gx_net_ips, 0] } + pcrf_gx_net_mask: { get_param: pcrf_gx_net_mask } + pcrf_sp_net_name: { get_param: pcrf_sp_net_name } + pcrf_sp_net_ip: { get_param: [pcrf_sp_net_ips, 0] } + pcrf_sp_net_mask: { get_param: pcrf_sp_net_mask } + pcrf_sy_net_name: { get_param: pcrf_sy_net_name } + pcrf_sy_net_ip: { get_param: [pcrf_sy_net_ips, 0] } + pcrf_sy_net_mask: { get_param: pcrf_sy_net_mask } + pcrf_rx_net_name: { get_param: pcrf_rx_net_name } + pcrf_rx_net_ip: { get_param: [pcrf_rx_net_ips, 0] } + pcrf_rx_net_mask: { get_param: pcrf_rx_net_mask } + pcrf_sd_net_name: { get_param: pcrf_sd_net_name } + pcrf_sd_net_ip: { get_param: [pcrf_sd_net_ips, 0] } + pcrf_sd_net_mask: { get_param: pcrf_sd_net_mask } + pcrf_sgi_sy_net_name: { get_param: pcrf_sgi_sy_net_name } + pcrf_sgi_sy_net_ip: { get_param: [pcrf_sgi_sy_net_ips, 0] } + pcrf_sgi_sy_net_mask: { get_param: pcrf_sgi_sy_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_ppd_002: + type: nested-ppd_v1.0.yaml + properties: + pcrf_ppd_server_name: { get_param: [pcrf_ppd_server_names, 1] } + pcrf_ppd_image_name: { get_param: pcrf_ppd_image_name } + pcrf_ppd_flavor_name: { get_param: pcrf_ppd_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_lb_internal_vip: { get_param: pcrf_lb_internal_vip } + pcrf_oam_net_name: { get_param: pcrf_oam_net_name } + pcrf_oam_net_ip: { get_param: [pcrf_oam_net_ips, 1] } + pcrf_oam_net_mask: { get_param: pcrf_oam_net_mask } + pcrf_oam_net_gw: { get_param: pcrf_oam_net_gw } + pcrf_lb_management_vip: { get_param: pcrf_lb_management_vip } + pcrf_gx_net_name: { get_param: pcrf_gx_net_name } + pcrf_gx_net_ip: { get_param: [pcrf_gx_net_ips, 1] } + pcrf_gx_net_mask: { get_param: pcrf_gx_net_mask } + pcrf_sp_net_name: { get_param: pcrf_sp_net_name } + pcrf_sp_net_ip: { get_param: [pcrf_sp_net_ips, 1] } + pcrf_sp_net_mask: { get_param: pcrf_sp_net_mask } + pcrf_sy_net_name: { get_param: pcrf_sy_net_name } + pcrf_sy_net_ip: { get_param: [pcrf_sy_net_ips, 1] } + pcrf_sy_net_mask: { get_param: pcrf_sy_net_mask } + pcrf_rx_net_name: { get_param: pcrf_rx_net_name } + pcrf_rx_net_ip: { get_param: [pcrf_rx_net_ips, 1] } + pcrf_rx_net_mask: { get_param: pcrf_rx_net_mask } + pcrf_sd_net_name: { get_param: pcrf_sd_net_name } + pcrf_sd_net_ip: { get_param: [pcrf_sd_net_ips, 1] } + pcrf_sd_net_mask: { get_param: pcrf_sd_net_mask } + pcrf_sgi_sy_net_name: { get_param: pcrf_sgi_sy_net_name } + pcrf_sgi_sy_net_ip: { get_param: [pcrf_sgi_sy_net_ips, 1] } + pcrf_sgi_sy_net_mask: { get_param: pcrf_sgi_sy_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_ppd_003: + type: nested-ppd_v1.0.yaml + properties: + pcrf_ppd_server_name: { get_param: [pcrf_ppd_server_names, 2] } + pcrf_ppd_image_name: { get_param: pcrf_ppd_image_name } + pcrf_ppd_flavor_name: { get_param: pcrf_ppd_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_lb_internal_vip: { get_param: pcrf_lb_internal_vip } + pcrf_oam_net_name: { get_param: pcrf_oam_net_name } + pcrf_oam_net_ip: { get_param: [pcrf_oam_net_ips, 2] } + pcrf_oam_net_mask: { get_param: pcrf_oam_net_mask } + pcrf_oam_net_gw: { get_param: pcrf_oam_net_gw } + pcrf_lb_management_vip: { get_param: pcrf_lb_management_vip } + pcrf_gx_net_name: { get_param: pcrf_gx_net_name } + pcrf_gx_net_ip: { get_param: [pcrf_gx_net_ips, 2] } + pcrf_gx_net_mask: { get_param: pcrf_gx_net_mask } + pcrf_sp_net_name: { get_param: pcrf_sp_net_name } + pcrf_sp_net_ip: { get_param: [pcrf_sp_net_ips, 2] } + pcrf_sp_net_mask: { get_param: pcrf_sp_net_mask } + pcrf_sy_net_name: { get_param: pcrf_sy_net_name } + pcrf_sy_net_ip: { get_param: [pcrf_sy_net_ips, 2] } + pcrf_sy_net_mask: { get_param: pcrf_sy_net_mask } + pcrf_rx_net_name: { get_param: pcrf_rx_net_name } + pcrf_rx_net_ip: { get_param: [pcrf_rx_net_ips, 2] } + pcrf_rx_net_mask: { get_param: pcrf_rx_net_mask } + pcrf_sd_net_name: { get_param: pcrf_sd_net_name } + pcrf_sd_net_ip: { get_param: [pcrf_sd_net_ips, 2] } + pcrf_sd_net_mask: { get_param: pcrf_sd_net_mask } + pcrf_sgi_sy_net_name: { get_param: pcrf_sgi_sy_net_name } + pcrf_sgi_sy_net_ip: { get_param: [pcrf_sgi_sy_net_ips, 2] } + pcrf_sgi_sy_net_mask: { get_param: pcrf_sgi_sy_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_ppd_004: + type: nested-ppd_v1.0.yaml + properties: + pcrf_ppd_server_name: { get_param: [pcrf_ppd_server_names, 3] } + pcrf_ppd_image_name: { get_param: pcrf_ppd_image_name } + pcrf_ppd_flavor_name: { get_param: pcrf_ppd_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_lb_internal_vip: { get_param: pcrf_lb_internal_vip } + pcrf_oam_net_name: { get_param: pcrf_oam_net_name } + pcrf_oam_net_ip: { get_param: [pcrf_oam_net_ips, 3] } + pcrf_oam_net_mask: { get_param: pcrf_oam_net_mask } + pcrf_oam_net_gw: { get_param: pcrf_oam_net_gw } + pcrf_lb_management_vip: { get_param: pcrf_lb_management_vip } + pcrf_gx_net_name: { get_param: pcrf_gx_net_name } + pcrf_gx_net_ip: { get_param: [pcrf_gx_net_ips, 3] } + pcrf_gx_net_mask: { get_param: pcrf_gx_net_mask } + pcrf_sp_net_name: { get_param: pcrf_sp_net_name } + pcrf_sp_net_ip: { get_param: [pcrf_sp_net_ips, 3] } + pcrf_sp_net_mask: { get_param: pcrf_sp_net_mask } + pcrf_sy_net_name: { get_param: pcrf_sy_net_name } + pcrf_sy_net_ip: { get_param: [pcrf_sy_net_ips, 3] } + pcrf_sy_net_mask: { get_param: pcrf_sy_net_mask } + pcrf_rx_net_name: { get_param: pcrf_rx_net_name } + pcrf_rx_net_ip: { get_param: [pcrf_rx_net_ips, 3] } + pcrf_rx_net_mask: { get_param: pcrf_rx_net_mask } + pcrf_sd_net_name: { get_param: pcrf_sd_net_name } + pcrf_sd_net_ip: { get_param: [pcrf_sd_net_ips, 3] } + pcrf_sd_net_mask: { get_param: pcrf_sd_net_mask } + pcrf_sgi_sy_net_name: { get_param: pcrf_sgi_sy_net_name } + pcrf_sgi_sy_net_ip: { get_param: [pcrf_sgi_sy_net_ips, 3] } + pcrf_sgi_sy_net_mask: { get_param: pcrf_sgi_sy_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-ppd_v1.1.env b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-ppd_v1.1.env new file mode 100644 index 0000000000..bb6dfe468c --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-ppd_v1.1.env @@ -0,0 +1,35 @@ +parameters: + pcrf_ppd_server_names: ZRDM1PCRF01PPD001,ZRDM1PCRF01PPD002,ZRDM1PCRF01PPD003,ZRDM1PCRF01PPD004 + pcrf_ppd_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_ppd_flavor_name: lc.4xlarge4 + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.3,172.26.16.4,172.26.16.5,172.26.16.6 + pcrf_lb_internal_vip: 172.26.16.114 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_oam_net_name: MNS-25180-L-01_oam_protected_net_0 + pcrf_oam_net_ips: 107.239.64.113,107.239.64.114,107.239.64.115,107.239.64.116 + pcrf_lb_management_vip: 107.239.64.123 + pcrf_oam_net_gw: 107.239.64.1 + pcrf_oam_net_mask: 255.255.248.0 + pcrf_gx_net_name: Mobisupport-25193-I-INT1_cor_pcrf_gx_net_0 + pcrf_gx_net_ips: 107.239.24.67,107.239.24.68,107.239.24.69,107.239.24.70 + pcrf_gx_net_mask: 255.255.255.248 + pcrf_sp_net_name: Mobisupport-25193-I-INT1_cor_pcrf_sp_net_0 + pcrf_sp_net_ips: 107.239.24.75,107.239.24.76,107.239.24.77,107.239.24.78 + pcrf_sp_net_mask: 255.255.255.248 + pcrf_sy_net_name: Mobisupport-25193-I-INT1_cor_pcrf_sy_net_0 + pcrf_sy_net_ips: 107.239.24.83,107.239.24.84,107.239.24.85,107.239.24.86 + pcrf_sy_net_mask: 255.255.255.248 + pcrf_rx_net_name: Mobisupport-25193-I-INT1_cor_pcrf_rx_net_0 + pcrf_rx_net_ips: 107.239.24.91,107.239.24.92,107.239.24.93,107.239.24.94 + pcrf_rx_net_mask: 255.255.255.248 + pcrf_sd_net_name: Mobisupport-25193-I-INT1_cor_pcrf_sd_net_0 + pcrf_sd_net_ips: 107.239.24.99,107.239.24.100,107.239.24.101,107.239.24.102 + pcrf_sd_net_mask: 255.255.255.248 + pcrf_sgi_sy_net_name: Mobisupport-25193-I-INT1_sgi_pcrf_sy_net_0 + pcrf_sgi_sy_net_ips: 107.239.26.131,107.239.26.132,107.239.26.133,107.239.26.134 + pcrf_sgi_sy_net_mask: 255.255.255.248 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-pps_v1.0.env b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-pps_v1.0.env new file mode 100644 index 0000000000..340be2b815 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-pps_v1.0.env @@ -0,0 +1,11 @@ +parameters: + pcrf_pps_server_names: ZRDM1PCRF01PPS001,ZRDM1PCRF01PPS002,ZRDM1PCRF01PPS003,ZRDM1PCRF01PPS004,ZRDM1PCRF01PPS005,ZRDM1PCRF01PPS006 + pcrf_pps_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pps_flavor_name: lc.3xlarge + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.7,172.26.16.8,172.26.16.9,172.26.16.10,172.26.16.11,172.26.16.12 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-pps_v1.0.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..05bd6c9318 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,121 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_pps_001: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_002: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 1] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_003: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 2] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_004: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 3] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_005: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 4] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_006: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 5] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-psm_v1.0.env b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-psm_v1.0.env new file mode 100644 index 0000000000..f24e4763c6 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-psm_v1.0.env @@ -0,0 +1,10 @@ +parameters: + pcrf_psm_server_names: ZRDM1PCRF01PSM001,ZRDM1PCRF01PSM002,ZRDM1PCRF01PSM003,ZRDM1PCRF01PSM004,ZRDM1PCRF01PSM005,ZRDM1PCRF01PSM006,ZRDM1PCRF01PSM007,ZRDM1PCRF01PSM008,ZRDM1PCRF01PSM009,ZRDM1PCRF01PSM010,ZRDM1PCRF01PSM011,ZRDM1PCRF01PSM012 + pcrf_psm_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_psm_flavor_name: lc.4xlarge4 + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.63,172.26.16.64,172.26.16.65,172.26.16.66,172.26.16.67,172.26.16.68,172.26.16.69,172.26.16.70,172.26.16.71,172.26.16.72,172.26.16.73,172.26.16.74 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-psm_v1.0.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-psm_v1.0.yaml new file mode 100644 index 0000000000..c2d7b05ead --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-psm_v1.0.yaml @@ -0,0 +1,199 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_names: + type: comma_delimited_list + label: PCRF SM server names + description: name of the PCRF SM instance + pcrf_psm_image_name: + type: string + label: PCRF SM image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_psm_001: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 0] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_002: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 1] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_003: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 2] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_004: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 3] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_005: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 4] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_006: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 5] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_007: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 6] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 6] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_008: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 7] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 7] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_009: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 8] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 8] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_010: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 9] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 9] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_011: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 10] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 10] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_012: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 11] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 11] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-swift-container_v1.0.env b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-swift-container_v1.0.env new file mode 100644 index 0000000000..5424c1bbf3 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-swift-container_v1.0.env @@ -0,0 +1,3 @@ +parameters: + pcrf_swift_container_name_1: PCRF_Config_Container_1 + pcrf_swift_container_purge_on_delete_flag_1: false diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-swift-container_v1.0.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-swift-container_v1.0.yaml new file mode 100644 index 0000000000..9597f234b0 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/hot-nimbus-swift-container_v1.0.yaml @@ -0,0 +1,30 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_swift_container_name_1: + type: string + label: Swift Container name + description: Swift Container Name + pcrf_swift_container_purge_on_delete_flag_1: + type: boolean + label: Purge on Delete Flag + description: Purge on Delete Flag + +resources: + pcrf_swift_container_1: + type: OS::Swift::Container + properties: + name: { get_param: pcrf_swift_container_name_1 } + PurgeOnDelete: { get_param: pcrf_swift_container_purge_on_delete_flag_1 } + X-Container-Read: ".r:*" + +outputs: + pcrf_swift_container_id_1: + description: the pcrf_swift_container_1 id + value: { get_resource: pcrf_swift_container_1 } + pcrf_swift_container_url_1: + description: the pcrf_swift_container_1 url + value: { get_attr: [ pcrf_swift_container_1, WebsiteURL ] } + \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/mount_iso_script.sh b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/mount_iso_script.sh new file mode 100644 index 0000000000..da5d9c4e9a --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/mount_iso_script.sh @@ -0,0 +1,34 @@ +#!/bin/bash + +#. .config +#following would be in the .config file + device_name="/dev/vde" + install_script="install_nimbus.sh" + enable_logic_flag_file=".flag" +#end of config file + +#get the semaphore, 0 - disbaled, 1- enabled +flag=$(cat ${enable_logic_flag_file}) + +#check if device is mounted already +test=$(mount | grep ${device_name}) +if [ "$flag" == "1" ]; then + if [ -e ${device_name} ] && [ ! "${test}" ]; then + #mount the iso image + mount -t iso9660 -v -o loop /dev/vde/ /mnt/iso + #if availabe run the install script (it contains the install.sh steps) + if [ -e "${install_script}" ] && [ -f "${install_script}" ]; then + ${install_script} + fi + #disable the script from attempting to + # mount and run install again until needed; + echo "0" > ${enable_logic_flag_file} + #if nedeed add step to comment out the crontab line here; + fi +else + echo "Auto mounting ISO & run install logic disabled!" +fi + +#cron job +# * * * * * /mount_iso_script.sh + diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/nested-oam_v1.0.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/nested-oam_v1.0.yaml new file mode 100644 index 0000000000..d3baf41da5 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/nested-oam_v1.0.yaml @@ -0,0 +1,156 @@ +heat_template_version: 2013-05-23 + +description: nested heat template that creates a PCRF OAM node stack + +parameters: + pcrf_oam_server_name: + type: string + label: PCRF OAM server name + description: PCRF OAM server name + pcrf_oam_image_name: + type: string + label: image name + description: PCRF OAM image name + pcrf_oam_flavor_name: + type: string + label: PCRF OAM flavor name + description: flavor name of PCRF OAM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_arbiter_vip: + type: string + label: OAM Arbiter LB VIP + description: OAM Arbiter LB VIP + pcrf_oam_net_name: + type: string + label: OAM network name + description: OAM network name + pcrf_oam_net_ip: + type: string + label: OAM network ip + description: OAM network ip + pcrf_oam_net_gw: + type: string + label: CPS network gateway + description: CPS network gateway + pcrf_oam_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_oam_volume_id: + type: string + label: CPS OAM Cinder Volume + description: CPS OAM Cinder Volume + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet } + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + - path: /etc/sysconfig/network-scripts/ifcfg-eth1 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet-gw } + params: + $dev: eth1 + $ip: { get_param: pcrf_oam_net_ip } + $netmask: { get_param: pcrf_oam_net_mask } + $gateway: { get_param: pcrf_oam_net_gw } + runcmd: + - ifdown eth0 && ifup eth0 + - ifdown eth1 && ifup eth1 + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + template: { get_file: cloud-nimbus.sh } + params: + $vm_name: { get_param: pcrf_oam_server_name } + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_oam: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_oam_server_name } + image: { get_param: pcrf_oam_image_name } + flavor: { get_param: pcrf_oam_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcrf_oam_port_0} + - port: { get_resource: pcrf_oam_port_1} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + + pcrf_oam_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + allowed_address_pairs: + - ip_address: { get_param: pcrf_arbiter_vip } + security_groups: [{ get_param: pcrf_security_group_name }] + + pcrf_oam_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_oam_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_oam_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] + + pcrf_oam_vol_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: { get_param: pcrf_oam_volume_id } + mountpoint: /dev/vdd + instance_uuid: { get_resource: pcrf_server_oam } + +outputs: + pcrf_oam_vol_attachment_id: + description: the pcrf_oam_vol_attachment_id id + value: { get_resource: pcrf_oam_vol_attachment } diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/nested-pcm_v1.0.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/nested-pcm_v1.0.yaml new file mode 100644 index 0000000000..820d09b3dc --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/nested-pcm_v1.0.yaml @@ -0,0 +1,150 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Cluman stack + +parameters: + pcrf_pcm_server_name: + type: string + label: PCRF CM server name + description: PCRF CM server name + pcrf_pcm_image_name: + type: string + label: image name + description: PCRF CM image name + pcrf_pcm_flavor_name: + type: string + label: PCRF CM flavor name + description: flavor name of PCRF CM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_oam_net_name: + type: string + label: OAM network name + description: OAM network name + pcrf_oam_net_ip: + type: string + label: OAM network ip + description: OAM network ip + pcrf_oam_net_gw: + type: string + label: CPS network gateway + description: CPS network gateway + pcrf_oam_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_pcm_volume_id: + type: string + label: CPS Cluman Cinder Volume + description: CPS Cluman Cinder Volume + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet } + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + - path: /etc/sysconfig/network-scripts/ifcfg-eth1 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet-gw } + params: + $dev: eth1 + $ip: { get_param: pcrf_oam_net_ip } + $netmask: { get_param: pcrf_oam_net_mask } + $gateway: { get_param: pcrf_oam_net_gw } + runcmd: + - ifdown eth0 && ifup eth0 + - ifdown eth1 && ifup eth1 + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + template: { get_file: cloud-nimbus.sh } + params: + $vm_name: { get_param: pcrf_pcm_server_name } + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_pcm: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_pcm_server_name } + image: { get_param: pcrf_pcm_image_name } + flavor: { get_param: pcrf_pcm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcrf_pcm_port_0} + - port: { get_resource: pcrf_pcm_port_1} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + + pcrf_pcm_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] + + pcrf_pcm_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_oam_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_oam_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] + + volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: { get_param: pcrf_pcm_volume_id } + mountpoint: /dev/vdd + instance_uuid: { get_resource: pcrf_server_pcm } + +outputs: + pcrf_server_pcm_id: + description: the pcm server id + value: { get_resource: pcrf_server_pcm } \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/nested-ppd_v1.0.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/nested-ppd_v1.0.yaml new file mode 100644 index 0000000000..397e85c252 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/nested-ppd_v1.0.yaml @@ -0,0 +1,333 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Director stack + +parameters: + pcrf_ppd_server_name: + type: string + label: PCRF PD server name + description: PCRF PD server name + pcrf_ppd_image_name: + type: string + label: image name + description: PCRF PD image name + pcrf_ppd_flavor_name: + type: string + label: PCRF PD flavor name + description: flavor name of PCRF PD instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_lb_internal_vip: + type: string + label: CPS Internal LB VIP + description: CPS Internal LB VIP + pcrf_oam_net_name: + type: string + label: OAM network name + description: OAM network name + pcrf_oam_net_ip: + type: string + label: OAM network ip + description: OAM network ip + pcrf_oam_net_gw: + type: string + label: CPS network gateway + description: CPS network gateway + pcrf_oam_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_lb_management_vip: + type: string + label: CPS OAM LB VIP + description: CPS OAM LB VIP + pcrf_gx_net_name: + type: string + label: Gx network name + description: Gx network name + pcrf_gx_net_ip: + type: string + label: Gx network ip + description: Gx network ip + pcrf_gx_net_mask: + type: string + label: Gx network mask + description: Gx network mask + pcrf_sp_net_name: + type: string + label: Sp network name + description: Sp network name + pcrf_sp_net_ip: + type: string + label: Sp network ip + description: Sp network ip + pcrf_sp_net_mask: + type: string + label: Sp network mask + description: Sp network mask + pcrf_sy_net_name: + type: string + label: Sy network name + description: Sy network name + pcrf_sy_net_ip: + type: string + label: Sy network ip + description: Sy network ip + pcrf_sy_net_mask: + type: string + label: Sy network mask + description: Sy network mask + pcrf_rx_net_name: + type: string + label: Rx network name + description: Rx network name + pcrf_rx_net_ip: + type: string + label: Rx network ip + description: Rx network ip + pcrf_rx_net_mask: + type: string + label: Rx network mask + description: Rx network mask + pcrf_sd_net_name: + type: string + label: Sd network name + description: Sd network name + pcrf_sd_net_ip: + type: string + label: Sd network ip + description: Sd network ip + pcrf_sd_net_mask: + type: string + label: Sd network mask + description: Sd network mask + pcrf_sgi_sy_net_name: + type: string + label: Sgi Sy network name + description: Sgi Sy network name + pcrf_sgi_sy_net_ip: + type: string + label: Sgi Sy network ip + description: Sgi Sy network ip + pcrf_sgi_sy_net_mask: + type: string + label: Sgi Sy network mask + description: Sgi Sy network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet } + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + - path: /etc/sysconfig/network-scripts/ifcfg-eth1 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet-gw } + params: + $dev: eth1 + $ip: { get_param: pcrf_oam_net_ip } + $netmask: { get_param: pcrf_oam_net_mask } + $gateway: { get_param: pcrf_oam_net_gw } + - path: /etc/sysconfig/network-scripts/ifcfg-eth2 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet } + params: + $dev: eth2 + $ip: { get_param: pcrf_gx_net_ip } + $netmask: { get_param: pcrf_gx_net_mask } + - path: /etc/sysconfig/network-scripts/ifcfg-eth3 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet } + params: + $dev: eth3 + $ip: { get_param: pcrf_sp_net_ip } + $netmask: { get_param: pcrf_sp_net_mask } + - path: /etc/sysconfig/network-scripts/ifcfg-eth4 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet } + params: + $dev: eth4 + $ip: { get_param: pcrf_sy_net_ip } + $netmask: { get_param: pcrf_sy_net_mask } + - path: /etc/sysconfig/network-scripts/ifcfg-eth5 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet } + params: + $dev: eth5 + $ip: { get_param: pcrf_rx_net_ip } + $netmask: { get_param: pcrf_rx_net_mask } + - path: /etc/sysconfig/network-scripts/ifcfg-eth6 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet } + params: + $dev: eth6 + $ip: { get_param: pcrf_sd_net_ip } + $netmask: { get_param: pcrf_sd_net_mask } + - path: /etc/sysconfig/network-scripts/ifcfg-eth7 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet } + params: + $dev: eth7 + $ip: { get_param: pcrf_sgi_sy_net_ip } + $netmask: { get_param: pcrf_sgi_sy_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + - ifdown eth1 && ifup eth1 + - ifdown eth2 && ifup eth2 + - ifdown eth3 && ifup eth3 + - ifdown eth4 && ifup eth4 + - ifdown eth5 && ifup eth5 + - ifdown eth6 && ifup eth6 + - ifdown eth7 && ifup eth7 + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + template: { get_file: cloud-nimbus.sh } + params: + $vm_name: { get_param: pcrf_ppd_server_name } + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_ppd: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_ppd_server_name } + image: { get_param: pcrf_ppd_image_name } + flavor: { get_param: pcrf_ppd_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcrf_ppd_port_0} + - port: { get_resource: pcrf_ppd_port_1} + - port: { get_resource: pcrf_ppd_port_2} + - port: { get_resource: pcrf_ppd_port_3} + - port: { get_resource: pcrf_ppd_port_4} + - port: { get_resource: pcrf_ppd_port_5} + - port: { get_resource: pcrf_ppd_port_6} + - port: { get_resource: pcrf_ppd_port_7} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + + pcrf_ppd_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] + allowed_address_pairs: + - ip_address: { get_param: pcrf_lb_internal_vip } + + pcrf_ppd_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_oam_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_oam_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] + allowed_address_pairs: + - ip_address: { get_param: pcrf_lb_management_vip } + + pcrf_ppd_port_2: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_gx_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_gx_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] + + pcrf_ppd_port_3: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_sp_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_sp_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] + + pcrf_ppd_port_4: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_sy_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_sy_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] + + pcrf_ppd_port_5: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_rx_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_rx_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] + + pcrf_ppd_port_6: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_sd_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_sd_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] + + pcrf_ppd_port_7: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_sgi_sy_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_sgi_sy_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] + diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/nested-pps_v1.0.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/nested-pps_v1.0.yaml new file mode 100644 index 0000000000..fc5b6f74c3 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/nested-pps_v1.0.yaml @@ -0,0 +1,99 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_name: + type: string + label: PCRF PS server name + description: PCRF PS server name + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + template: { get_file: cloud-nimbus.sh } + params: + $vm_name: { get_param: pcrf_pps_server_name } + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet } + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_pps: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_pps_server_name } + image: { get_param: pcrf_pps_image_name } + flavor: { get_param: pcrf_pps_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcrf_pps_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + + pcrf_pps_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/nested-psm_v1.0.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/nested-psm_v1.0.yaml new file mode 100644 index 0000000000..c86aa34713 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/nested-psm_v1.0.yaml @@ -0,0 +1,99 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_name: + type: string + label: PCRF SM server name + description: PCRF SM server name + pcrf_psm_image_name: + type: string + label: image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet } + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + template: { get_file: cloud-nimbus.sh } + params: + $vm_name: { get_param: pcrf_psm_server_name } + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_psm: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_psm_server_name } + image: { get_param: pcrf_psm_image_name } + flavor: { get_param: pcrf_psm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: psm01_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + #scheduler_hints: {group: { get_resource: servergroup_nimbus }} + + psm01_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/nimbus-ethernet b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/nimbus-ethernet new file mode 100644 index 0000000000..51250a7b82 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/nimbus-ethernet @@ -0,0 +1,5 @@ +DEVICE=$dev +BOOTPROTO=none +NM_CONTROLLED=no +IPADDR=$ip +NETMASK=$netmask diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/nimbus-ethernet-gw b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/nimbus-ethernet-gw new file mode 100644 index 0000000000..3e08d643bb --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/nimbus/nimbus-ethernet-gw @@ -0,0 +1,6 @@ +DEVICE=$dev +BOOTPROTO=none +NM_CONTROLLED=no +IPADDR=$ip +NETMASK=$netmask +GATEWAY=$gateway diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/notZipFile b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/notZipFile new file mode 100644 index 0000000000..0f0f2a483c --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/notZipFile @@ -0,0 +1 @@ +test text file \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/quesionnaire/invalidComponent.json b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/quesionnaire/invalidComponent.json new file mode 100644 index 0000000000..9b10297572 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/quesionnaire/invalidComponent.json @@ -0,0 +1,34 @@ +{ + "general": { + "hypervisor": { + "hypervisor": "KVM", + "containerFeaturesDescription": "Nn8XhahKjo,FapqJ4Ale11LkO-f3,TlCJ2d0S Q B1w0JJwZgWo MeqEk85utsaM tdM33ZmAiAKp__c_PRBt_5-24gBU21unWme", + "drivers": ",Lz-m3R7iwRREmjBA3Ss6b0K8YBcH4SS66UJSG8OGTlaMs6Be" + }, + "image": { + "ephemeralDiskSizePerVM": 8, + "format": "iso", + "bootDiskSizePerVM": 100, + "providedBy": "Vendor" + }, + "dnsConfiguration": "dolore adipisicing proident aute amet", + "recovery": { + "vmProcessFailuresHandling": "in ad est ut", + "pointObjective": 20 + } + }, + "network": {}, + "highAvailabilityAndLoadBalancing": { + "architectureChoice": "nostrud eu culpa velit Lorem", + "slaRequirements": "est esse Excepteur eu", + "failureLoadDistribution": "velit reprehenderit aute dolor in", + "loadDistributionMechanism": "quis fugiat veniam cillum" + }, + "storage": { + "backup": { + "backupType": "On Site", + "backupStorageSize": 9, + "backupSolution": "fugiat tempor" + } + } +} \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/quesionnaire/invalidNic.json b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/quesionnaire/invalidNic.json new file mode 100644 index 0000000000..7297cdcc84 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/quesionnaire/invalidNic.json @@ -0,0 +1,36 @@ +{ + "ipConfiguration": { + "ipv6Required": false + }, + "protocols": { + "protocolWithHighestTrafficProfile": "TCP" + }, + "network": { + "networkDescription": "mLRqrnteBeIIUQsuvZEetXjllKPnYvbG" + }, + "sizing": { + "describeQualityOfService": "adipisicing voluptate aute", + "acceptableJitter": { + "mean": "98690087997256150885582732516496929349161209784564642159997681825133065" + }, + "flowLength": { + "packets": {}, + "bytes": {} + }, + "outflowTrafficPerSecond": { + "packets": {} + }, + "acceptablePacketLoss": "15", + "inflowTrafficPerSecond": { + "bytes": {} + } + }, + "describeQualityOfService": "minim dolore", + "acceptablePacketLoss": "4", + "flowLength": {}, + "acceptableJitter": { + "mean": "61827261335222870878257995122569227177432366697624312367018960696207118652325834319325112734287", + "max": "498307229580528005673649352861421755", + "variable": "5085363947608755025538570280250262251802454469028997134802881591362" + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/quesionnaire/validComponent.json b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/quesionnaire/validComponent.json new file mode 100644 index 0000000000..4e9e9aa6c0 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/quesionnaire/validComponent.json @@ -0,0 +1,34 @@ +{ + "general": { + "hypervisor": { + "hypervisor": "KVM", + "containerFeaturesDescription": "Nn8XhahKjo,FapqJ4Ale11LkO-f3,TlCJ2d0S Q B1w0JJwZgWo MeqEk85utsaM tdM33ZmAiAKp__c_PRBt_5-24gBU21unWme", + "drivers": ",Lz-m3R7iwRREmjBA3Ss6b0K8YBcH4SS66UJSG8OGTlaMs6Be" + }, + "image": { + "ephemeralDiskSizePerVM": 8, + "format": "iso", + "bootDiskSizePerVM": 100, + "providedBy": "Vendor" + }, + "dnsConfiguration": "dolore adipisicing proident aute amet", + "recovery": { + "vmProcessFailuresHandling": "in ad est ut", + "pointObjective": 6 + } + }, + "network": {}, + "highAvailabilityAndLoadBalancing": { + "architectureChoice": "nostrud eu culpa velit Lorem", + "slaRequirements": "est esse Excepteur eu", + "failureLoadDistribution": "velit reprehenderit aute dolor in", + "loadDistributionMechanism": "quis fugiat veniam cillum" + }, + "storage": { + "backup": { + "backupType": "On Site", + "backupStorageSize": 9, + "backupSolution": "fugiat tempor" + } + } +} \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/quesionnaire/validNic.json b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/quesionnaire/validNic.json new file mode 100644 index 0000000000..e30dcfd668 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/quesionnaire/validNic.json @@ -0,0 +1,30 @@ +{ + "ipConfiguration": { + "ipv6Required": false + }, + "protocols": { + "protocolWithHighestTrafficProfile": "TCP" + }, + "network": { + "networkDescription": "mLRqrnteBeIIUQsuvZEetXjllKPnYvbG" + }, + "sizing": { + "describeQualityOfService": "adipisicing voluptate aute", + "flowLength": { + "packets": {}, + "bytes": {} + }, + "outflowTrafficPerSecond": { + "packets": {} + }, + "acceptablePacketLoss": 15, + "inflowTrafficPerSecond": { + "bytes": {} + }, + "acceptableJitter": { + "mean": 2000, + "max": 3000, + "variable": 4000 + } + } +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/missing_manifest/input/heat_missing_from_manifast.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/missing_manifest/input/heat_missing_from_manifast.yaml new file mode 100644 index 0000000000..d5608abfb4 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/missing_manifest/input/heat_missing_from_manifast.yaml @@ -0,0 +1,250 @@ +### Heat Template ### +description: Generated template +heat_template_version: 2013-05-23 +parameters: {} +resources: + network_0: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + network_1: + properties: + admin_state_up: true + name: NET_169 + shared: true + type: OS::Neutron::Net + network_2: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_3: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: OS::Neutron::Net + network_4: + properties: + admin_state_up: true + name: NET_169 + shared: true + type: OS::Neutron::Net + network_5: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_6: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: OS::Neutron::Net + network_7: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_8: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_9: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + security_group_0: + properties: + description: Default security group + name: _default + rules: + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + security_group_1: + properties: + description: Default security group + name: _default + rules: + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + subnet_0: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_9 + type: OS::Neutron::Subnet + subnet_1: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_0 + type: OS::Neutron::Subnet + subnet_2: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_8 + type: OS::Neutron::Subnet + subnet_3: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_2 + type: OS::Neutron::Subnet + subnet_4: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_5 + type: OS::Neutron::Subnet + subnet_5: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_6 + type: OS::Neutron::Subnet + subnet_6: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_3 + type: OS::Neutron::Subnet + subnet_7: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_1 + type: OS::Neutron::Subnet + subnet_8: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_4 + type: OS::Neutron::Subnet + subnet_9: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_7 + type: OS::Neutron::Subnet + diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/missing_manifest/input/mainValid.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/missing_manifest/input/mainValid.yaml new file mode 100644 index 0000000000..318c8f1283 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/missing_manifest/input/mainValid.yaml @@ -0,0 +1,250 @@ +### Heat Template ### +description: Generated template +heat_template_version: 2013-05-23 +parameters: {} +resources: + network_0: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + network_1: + properties: + admin_state_up: true + name: NET_169 + shared: true + type: OS::Neutron::Net + network_2: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_3: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: missingNested.yaml + network_4: + properties: + admin_state_up: true + name: { get_file: missing-artifact } + shared: true + type: OS::Neutron::Net + network_5: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_6: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: OS::Neutron::Net + network_7: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_8: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_9: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + security_group_0: + properties: + description: Default security group + name: _default + rules: + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + security_group_1: + properties: + description: Default security group + name: _default + rules: + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + subnet_0: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_9 + type: OS::Neutron::Subnet + subnet_1: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_0 + type: OS::Neutron::Subnet + subnet_2: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_8 + type: OS::Neutron::Subnet + subnet_3: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_2 + type: OS::Neutron::Subnet + subnet_4: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_5 + type: OS::Neutron::Subnet + subnet_5: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_6 + type: OS::Neutron::Subnet + subnet_6: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_3 + type: OS::Neutron::Subnet + subnet_7: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_1 + type: OS::Neutron::Subnet + subnet_8: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_4 + type: OS::Neutron::Subnet + subnet_9: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_7 + type: OS::Neutron::Subnet + diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/missing_manifest/input/validHeat.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/missing_manifest/input/validHeat.yaml new file mode 100644 index 0000000000..d5608abfb4 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/missing_manifest/input/validHeat.yaml @@ -0,0 +1,250 @@ +### Heat Template ### +description: Generated template +heat_template_version: 2013-05-23 +parameters: {} +resources: + network_0: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + network_1: + properties: + admin_state_up: true + name: NET_169 + shared: true + type: OS::Neutron::Net + network_2: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_3: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: OS::Neutron::Net + network_4: + properties: + admin_state_up: true + name: NET_169 + shared: true + type: OS::Neutron::Net + network_5: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_6: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: OS::Neutron::Net + network_7: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_8: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_9: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + security_group_0: + properties: + description: Default security group + name: _default + rules: + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + security_group_1: + properties: + description: Default security group + name: _default + rules: + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + subnet_0: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_9 + type: OS::Neutron::Subnet + subnet_1: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_0 + type: OS::Neutron::Subnet + subnet_2: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_8 + type: OS::Neutron::Subnet + subnet_3: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_2 + type: OS::Neutron::Subnet + subnet_4: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_5 + type: OS::Neutron::Subnet + subnet_5: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_6 + type: OS::Neutron::Subnet + subnet_6: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_3 + type: OS::Neutron::Subnet + subnet_7: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_1 + type: OS::Neutron::Subnet + subnet_8: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_4 + type: OS::Neutron::Subnet + subnet_9: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_7 + type: OS::Neutron::Subnet + diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/nested_resource_group/MANIFEST.json b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/nested_resource_group/MANIFEST.json new file mode 100644 index 0000000000..522029634e --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/nested_resource_group/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "nested.yml", + "type": "HEAT", + "isBase": "false" + }, + { + "file": "addOn.yml", + "type": "HEAT", + "isBase": "false" + } + ] +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/nested_resource_group/addOn.yml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/nested_resource_group/addOn.yml new file mode 100644 index 0000000000..39c34742a4 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/nested_resource_group/addOn.yml @@ -0,0 +1,31 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + shared_security_group_id1: + type: string + description: network name of jsa log network + shared_security_group_id2: + type: string + description: network name of jsa log network + jsa_net_name: + type: string + description: network name of jsa log network + security_group_name: + type: string + label: security group name + description: the name of security group + +resources: + mvs_modules: + type: OS::Heat::ResourceGroup + properties: + count: 3 + index_var: "%index%" + resource_def: + type: nested.yml + properties: + p1: { get_param: shared_security_group_id1} + p2: { get_param: shared_security_group_id2} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/nested_resource_group/nested.yml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/nested_resource_group/nested.yml new file mode 100644 index 0000000000..4614bdce93 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/nested_resource_group/nested.yml @@ -0,0 +1,56 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + p1: + type: string + description: UID of OAM network + p2: + type: string + description: UID of OAM network + net: + type: string + description: UID of OAM network + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + cmaui_flavor: + type: string + description: Flavor for CMAUI server + +resources: + + cmaui_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: net } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: p1}, {get_param: p2}] + replacement_policy: AUTO + + cmaui_port_2: + type: OS::Neutron::Port + properties: + network: { get_param: net } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: p1}] + replacement_policy: AUTO + + server_cmaui: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_1 } + - port: { get_resource: cmaui_port_2 } \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/nested_volume/MANIFEST.json b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/nested_volume/MANIFEST.json new file mode 100644 index 0000000000..1e2b0c7997 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/nested_volume/MANIFEST.json @@ -0,0 +1,16 @@ +{ + "name": "", + "description": "", + "data": [ + { + "file": "hot_mobt_volume_attach_nested.yaml", + "type": "HEAT_VOL", + "isBase": "false" + }, + { + "file": "base_mobt.yaml", + "type": "HEAT", + "isBase": "true" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/nested_volume/base_mobt.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/nested_volume/base_mobt.yaml new file mode 100644 index 0000000000..c3be156e38 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/nested_volume/base_mobt.yaml @@ -0,0 +1,26 @@ +heat_template_version: 2014-10-16 + +description: heat template that creates additional MOBT nodes in stack + +parameters: + mobt_vol_count: + type: number + label: MOBT OAM server count + description: MOBT OAM server instance count + default: 2 + constraints: + - range: { min: 2, max: 2 } + +resources: + server_volume_attach_group: + type: OS::Heat::ResourceGroup + properties: + count: { get_param: mobt_vol_count } + resource_def: + type: hot_mobt_volume_attach_nested.yaml + properties: + mobt_vol_index: "%index%" + server_mobt_group_ids: { get_attr: [ server_mobt_group_data, mobt_server_adm_x_id ] } + update_policy: + batch_create: + max_batch_size: 1 diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/nested_volume/hot_mobt_volume_attach_nested.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/nested_volume/hot_mobt_volume_attach_nested.yaml new file mode 100644 index 0000000000..8e6d07f899 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/nested_volume/hot_mobt_volume_attach_nested.yaml @@ -0,0 +1,28 @@ +heat_template_version: 2014-10-16 + +description: nested heat template that associtate the cinder volumes to OAM nodes stack + +parameters: + mobt_volume_ids: + type: comma_delimited_list + label: MOBT OAM Cinder Volumes + description: MOBT OAM Cinder Volumes + + server_mobt_group_ids: + type: comma_delimited_list + label: MOBT OAM Resource Group + description: MOBT OAM Resource Group + + mobt_vol_index: + type: number + label: ADM volume index + description: ADM volume UUID in list + +resources: + mobt_adm_vol_attachment_x: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: { get_param: [ mobt_volume_ids, get_param: mobt_vol_index ]} + mountpoint: /dev/vdb + instance_uuid: { get_param: [ server_mobt_group_ids, get_param: mobt_vol_index ]} + diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/valid_tree/input/MANIFEST.json b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/valid_tree/input/MANIFEST.json new file mode 100644 index 0000000000..a4065d0b68 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/valid_tree/input/MANIFEST.json @@ -0,0 +1,39 @@ +{ + "data": [ + { + "file": "validHeat.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-oam_v1.0.env", + "type": "HEAT_ENV" + }, + { + "file": "hot-nimbus-oam-volumes_v1.0", + "type": "HEAT_VOL", + "data": [{ + "file": "hot-nimbus-oam-volumes_v1.0.env", + "type": "HEAT_ENV" + }] + } + ] + }, + { + "file": "mainValid.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-oam-networks_v1.0", + "type": "HEAT_NET" + } + ] + }, + { + "file": "missingHeatFromZip.yaml.yaml", + "type": "HEAT" + } + ], + "description": "RXAEmleoRDWLeWVvmXUJxDKCItgjkMEXuKJcUWyVUZrCUiMzZSyHPzhqLcJSIUNBzohsIGXLBIwstuVDEuFtxuLIwWgCCdjprtvzruHIUKdVnCyifJQUJjqSCoKKKyVaWFTFKzHNhTZNlZTYaMKGEpIMXOpIxSyTZZCgVsGkItQelBbFVrmCltTgkuppYMrEfvwqNBLVRSGCucNwliWFZUuXloXBiZaqtodZjyFpqBNqhlpcrARmMpvLiz", + "name": "FCTRQGcMevNngRDvECQYfiEXCYbGeAWRHdaGggLUgyOnssHAiU", + "version": "2013-05-23" +} \ No newline at end of file diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/valid_tree/input/heat_missing_from_manifast.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/valid_tree/input/heat_missing_from_manifast.yaml new file mode 100644 index 0000000000..d5608abfb4 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/valid_tree/input/heat_missing_from_manifast.yaml @@ -0,0 +1,250 @@ +### Heat Template ### +description: Generated template +heat_template_version: 2013-05-23 +parameters: {} +resources: + network_0: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + network_1: + properties: + admin_state_up: true + name: NET_169 + shared: true + type: OS::Neutron::Net + network_2: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_3: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: OS::Neutron::Net + network_4: + properties: + admin_state_up: true + name: NET_169 + shared: true + type: OS::Neutron::Net + network_5: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_6: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: OS::Neutron::Net + network_7: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_8: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_9: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + security_group_0: + properties: + description: Default security group + name: _default + rules: + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + security_group_1: + properties: + description: Default security group + name: _default + rules: + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + subnet_0: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_9 + type: OS::Neutron::Subnet + subnet_1: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_0 + type: OS::Neutron::Subnet + subnet_2: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_8 + type: OS::Neutron::Subnet + subnet_3: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_2 + type: OS::Neutron::Subnet + subnet_4: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_5 + type: OS::Neutron::Subnet + subnet_5: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_6 + type: OS::Neutron::Subnet + subnet_6: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_3 + type: OS::Neutron::Subnet + subnet_7: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_1 + type: OS::Neutron::Subnet + subnet_8: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_4 + type: OS::Neutron::Subnet + subnet_9: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_7 + type: OS::Neutron::Subnet + diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/valid_tree/input/mainValid.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/valid_tree/input/mainValid.yaml new file mode 100644 index 0000000000..318c8f1283 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/valid_tree/input/mainValid.yaml @@ -0,0 +1,250 @@ +### Heat Template ### +description: Generated template +heat_template_version: 2013-05-23 +parameters: {} +resources: + network_0: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + network_1: + properties: + admin_state_up: true + name: NET_169 + shared: true + type: OS::Neutron::Net + network_2: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_3: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: missingNested.yaml + network_4: + properties: + admin_state_up: true + name: { get_file: missing-artifact } + shared: true + type: OS::Neutron::Net + network_5: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_6: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: OS::Neutron::Net + network_7: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_8: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_9: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + security_group_0: + properties: + description: Default security group + name: _default + rules: + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + security_group_1: + properties: + description: Default security group + name: _default + rules: + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + subnet_0: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_9 + type: OS::Neutron::Subnet + subnet_1: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_0 + type: OS::Neutron::Subnet + subnet_2: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_8 + type: OS::Neutron::Subnet + subnet_3: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_2 + type: OS::Neutron::Subnet + subnet_4: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_5 + type: OS::Neutron::Subnet + subnet_5: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_6 + type: OS::Neutron::Subnet + subnet_6: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_3 + type: OS::Neutron::Subnet + subnet_7: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_1 + type: OS::Neutron::Subnet + subnet_8: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_4 + type: OS::Neutron::Subnet + subnet_9: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_7 + type: OS::Neutron::Subnet + diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/valid_tree/input/validHeat.yaml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/valid_tree/input/validHeat.yaml new file mode 100644 index 0000000000..d5608abfb4 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/tree/valid_tree/input/validHeat.yaml @@ -0,0 +1,250 @@ +### Heat Template ### +description: Generated template +heat_template_version: 2013-05-23 +parameters: {} +resources: + network_0: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + network_1: + properties: + admin_state_up: true + name: NET_169 + shared: true + type: OS::Neutron::Net + network_2: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_3: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: OS::Neutron::Net + network_4: + properties: + admin_state_up: true + name: NET_169 + shared: true + type: OS::Neutron::Net + network_5: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_6: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: OS::Neutron::Net + network_7: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_8: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_9: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + security_group_0: + properties: + description: Default security group + name: _default + rules: + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + security_group_1: + properties: + description: Default security group + name: _default + rules: + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + subnet_0: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_9 + type: OS::Neutron::Subnet + subnet_1: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_0 + type: OS::Neutron::Subnet + subnet_2: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_8 + type: OS::Neutron::Subnet + subnet_3: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_2 + type: OS::Neutron::Subnet + subnet_4: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_5 + type: OS::Neutron::Subnet + subnet_5: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_6 + type: OS::Neutron::Subnet + subnet_6: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_3 + type: OS::Neutron::Subnet + subnet_7: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_1 + type: OS::Neutron::Subnet + subnet_8: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_4 + type: OS::Neutron::Subnet + subnet_9: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_7 + type: OS::Neutron::Subnet + diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/emptyZip.zip b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/emptyZip.zip new file mode 100644 index 0000000000000000000000000000000000000000..15cb0ecb3e219d1701294bfdf0fe3f5cb5d208e7 GIT binary patch literal 22 NcmWIWW@Tf*000g10H*)| literal 0 HcmV?d00001 diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/missingManifestInZip.zip b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/missingManifestInZip.zip new file mode 100644 index 0000000000000000000000000000000000000000..1d1e626efee76b4f4a5c1cabebc803180df327ba GIT binary patch literal 397 zcmWIWW@Zs#U}E54V2MBPq4PPD?8-1lk{-21O^x>O?Ioz~$y7Tk5V9qmacV`vM zmludVIit-_l8f(%W8mxWIot1Uu#UQ*B!9AqAQ4K?%)55F~FOVNrVAc_^1Fw zh=GBTK>Od`}?%YNAR4y-BKp=P{qKQ?#1q3g7dHk{wq2Elr-(ZZOZvq~w zG$!_&50hOsG>|lv!h^+d#6gPk9TQ0du+$*fU;sj5q`&bF_(qU{64+y)D7*zqt^gZF zbS^tDNTCh0r-0fE!ZH&QgcCFpJec(~3%In%x<_R0(kjtZ)fU$SRqwjSu2LFsj@_a{ zTGJNYpvlt-Deo387ay&q{+(>H0f79pir!R=jWQ(w$T9-}+u17cz`IgDu6O-iU8Fo* zo&2RjoZ#N;H%$-=*O=eX^hI(~Dq=oM^eL@6HE2Zh2SO;4dD`ok&XLC?d*oOrSc)5( zHugnsLW;q-dh}yEHr3G#jm6g?vRw!G6mt_fqv6aux^yKnQb?vZ+k>FlgBpj;Py3(u z#hh)*f-4A>bB~h%@)FO+PfEA6q;uNMmRsh%sV{TM-j9N=^a@}Zxr#CXlgDoac9g!Myb_8{G->qc-jeFG zu-nh?DV9^gL^wiMyYim+vb7vjo{Q*cBi+DxPblSc-j)mOUf@i}IBI+xrqAGrpQ?GS7Uc+B%Y-R^7L4WqNbnzfIFVD{V0=&iw+- zn-qt)pj+DPQ87IsX-oyi7RDC~)Sq~;Q=XJy7gXj;@kr~-`|eLacIqsAipN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?7zALHy+Wq$7NBdmG1*d*fD;5 z*GY8Y`-jxoC#rlsuCYngX!m`Bn!0l35vu;}qD=|L%N~2X38Y?)-Am!4KenFlB|qh( z3*TL!n^x93f^4)zR*_&xzRSnr>^^ve`|#^!o(l~(E}#aN%#m~RdS1+yc~fWd=?OOx z=%)|zWP|~HVTjX~aWr;9NVgry;MzBDBt{xQ)$ zb_ISj+rhZbRO>OwKx#v&Bi;MDQBv`X%;u3u3WyOIIonyV`E_y=I&%;JkOBOE*MH?W zy8k?r0h|C(OnaE{b%>0=fQ=<=eTeM8{lCZmoTmOco^XcvRkr#SrB?Q#bj<&u{H)P` hQWU8EmsEenAqk}Xi$g{I*H2KK9m%t3+jQ=)?oa$8`>p^0 literal 0 HcmV?d00001 diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/MMSC.zip b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/MMSC.zip new file mode 100644 index 0000000000000000000000000000000000000000..8d8e669a87862580090cfddd3aaf47e8d9bd6827 GIT binary patch literal 21273 zcmeF1W3wR5(yo^|%eHOXw!LQAwr$(CZQHhO+nO`a>;3KgfF04{9>Jx>w}FhL?K_cbOqo^wo*%kaj%73%O}g24&FGf$>MNS;M0mj{tZP+5?tdZE@E z<@FbS4(=&HBoYf)WyMGMk5NhF;|CZi7eEdm>0#dm=lupM3Yuk>@qUI(y^5PMiDGgG zEs!*K2S7tkZ|a=nu4aU)@6*$F<3HiY*Kfo?Ns=lX1P^(0WB1TTN@cDII>;)t4K~yh zZ^*Np2E0N(>gIx^G3*1VTjUAYEXPp zXHS=qQlTYOi6&F9_|v= zb(Aff7nL2FXSOOQhxv}rS+=y}7$=l1j(CpgZyOpqW@68j21MaIJusX$)Lp)fO2TV> zt5LQ9tE0?mXSImgykly=*l0Y+tv6M1X%*|;(>W!MM%1xk3X0>bO5ViNTZZ@{>0c<^zO_gM!a-jhk z3E$I1a&kzySE@sMu(mA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>M zl&po%n*^Bu7fK!r*NG*L-u{EZWdjGMZk$j$ys)1IhZY9>$2>rDeTr%X zYtQ;m{Arkf#{b_s*#CqqVfbG6FOdJ*Df$z6{&$h?5RIsNx=|L6K=xc@3*|3qfO`zJ~JPsShKraS(H z@xN-mKaK0*|C|Y7vpRg&vf0KVLJpb!k1X$NnZv3|&5X5g<`nTy> OXh8bkq%GCouKo|Q3uyiT literal 0 HcmV?d00001 diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/cmd-frwl-v302.zip b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/cmd-frwl-v302.zip new file mode 100644 index 0000000000000000000000000000000000000000..e169a8c0c31336873e7b5a877671ba580c5c3026 GIT binary patch literal 8239 zcmaKxWl&sg7Ofk14eoBi-Q67;*Wm8KU4m=l5F{kHyLWJcdvF3l0*$-F%{OyrzSNzW zdrsAP|2Y@*A9Zbq5LUty>PziLS?W_) z^5$;{a>%@SDf)Qpre*la^ImT4(Nv|5NDQ*Jq-Ik$L=~QkM_nMuC8jp6?e{@&H7IkE zsVPk1Bd**e{X98}xI{yk<|fvlx<#=^yh+{Mo+yXrK_NuV?7mK?Yr6nV@agr#aE%FL z!gvaQ?yGEsOy94{h5P07!~8KtnYtkOYe11O-biwLRDKz_91J^35v%p2oa{zkX8|hDH~Bg zEl+h%NUnK7>>1eYA0w4!qtBqyX>p*KTwWPGatEI_cR~|+ZH;T9+#i>%XA;pT^ls9J zJ0@Oz+QLqIjGeNycM^{{QWPdBO;DWJGk3Oz7xvR3ylo3p-}4fQleLWbDry$Swn+gJ zFNFllXambkvLs&JwcDJdK)$B&x!xx_1S8ipvi%a{+8_i2&|LYlwNL1N+v+9F=w|nL zLyboz>H;TF4U}~w+R}{fPFSpHAtc-TQ$O-UjXY!@jWA7qH$Oc-deMHmYehN^4W(lV z1t10N;q?F=9}2|YC*hg z4WDRp`4L2)V-L8P_j#P*gI(;*x|_nBd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pSBD_` zT^YiwltnQ|HKYqLhDl(8@Ump8viJRZeeauMOWzLqMBsP%=2ROW18Zg#H8CxWvqj!+ zp{PZ%vY?&_b3gxtg9h^sE*$?Xtb<@ipuI>W`j+SAS8r|vpk(iOYgJmnVz zbtNchT$umW8l(P>EC2C`ABX;R{;v)h@!uWtpS=I<@&4q2f5)Kzh4&A8`cK|pt=^x! z{|r(8=6wlG`JFTVKauJ`F@Hs>e`5YKnEV@a92)U^PyYX7%70S-iYfo3{-*=~lY0K< zzfu480090E D(Yz&= literal 0 HcmV?d00001 diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/noError/GWv12.zip b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/noError/GWv12.zip new file mode 100644 index 0000000000000000000000000000000000000000..cbf0adff5b0e597b33bf2677340a778d3c81d0d7 GIT binary patch literal 9312 zcma)?byQSs*N15k=>{1(r6d#(B&0)9xCsAMRm`qPd} zkBEE+^ok}S4JCM*0-Od;4w2kwTUd8lwsSdf0~u`~0lY9p_~z>?0#-Aj=+yT%fefq0 zUY^}K5YxjXy`B%>mno%NEDAPX_Pw1HD*YBb(4)Iicpf|`FT|qOBF7ySrq@~LP(q>$ z&mG?sXV82c72nAnWyx|!{)-<^Muoo1$49TDGG~BK###MG3qDUT))wm!uSm}x(c1eq zatoovn&>zLze~;pO<8C@tmGOKy(c?bo}m2%Wr*CYxD{bpQ-5{P>vYn2T$A`#uj=^W;afQ}4JPPf#ZV<3b1* zgiVtAzQ(qWIO~)=A|isy&?Fo0Y3&Oyw>0riS&X%Pa>8(SW@W~w586zhKdHY*I#b;L z`5Az!x0IrFd;G=ZC+SYRi4^6rNBY90Pdwf%WVbCa*oZT)a|hnIY`HK`@KCQdpY%Cl zp*VgI2&p$Q8H?>&Zq1UB`xZ}~J^+nrl}%%gV2WVml+y~!$Al_|$OUztmJw$dteZC$ z5^)A863a$1Xko-Lg_B9=<1lp+afT`K%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bqA52@@HAJ2?zQ+E5f|^gmfP1cvN3&oi zQi#STV}R<~swQF;NtV~&*Bfv`9uGf4vkH*t3|D58!vp097aaabd~R87+h3ZEZVu|c zBNJWC1hllaJaMNl*r@6XGA13d~nkp@Ath ziqj@I2#If`rhdPb1Lk_i9Q!rp5{Xkf$G@(!GtwmkJKP;JV#?b6^Qtf_zx(vxzT9`nCKj5AJt3#m?1+ zleLCwiW`z03DCX*j6+ANC5dI@srOsvUT}PnUu|lsf$1f*yT>VkobcRbZp|X+Q=VaR z(aQo=)HQNC!(UlEdImqLI%^`885+2Gv8oZ7E(>4qRp!HXIZj+H1h*50NHa8qZu_8Z+_5odIt9>0H77)Q%pxn7Q!Y-p#y#0OhM%KRejmo&vmCGJe-YO|A&F~% zRnl;1fJ1A%koX|OlB@HagvjV(mnWaKCp0iNv4wR8R8)$l!DTRkfTzrZO$Da1TGoc4 zQ6#u;fp%&W_B*(Kwr4QLWc%TPq@09iB$gIU>@P&Pg*GmnBSbgu@41-x%|bZFUZ-5i zf8@=}h@-q?``zHZsAY_3asD>x#f|=LM_ZcMx`<$5a97Oa@yF$FPoTR`)Y!resuY-w z$AE#V3%sG4ikT0Xw`38mk;s{N)9YXDx{4ndjuA|!j5zjUqAuFHSDiMnQ|kqBRXegyZLiU5O44By6S& zm#t^s!!B9vVJgtZ=|T*cD4d!i96UbY|L*trBOd@b0QFzPpX)#F{`e>M-yLB61^X{- z=%0lDKf?aesDD!bT~YXNYWN@N`zQ5Z48;F-s{CCd{wMq2nX$jwb_D-o&Hg#{-}#t- pOeOqJUClq4|4!5YX4X^uC(Qr9dq}{)rUC!lhj0ME3C&+`{}0OIBYyw@ literal 0 HcmV?d00001 diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/noError/base_module_mns_oam_fixed.zip b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/noError/base_module_mns_oam_fixed.zip new file mode 100644 index 0000000000000000000000000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y#K_g4)ghCej^Z4v%e4xk3s{w_zvV1LN{iD)F_QK|y~hNA;N%BR7{ Hf4}_)*<{Hl literal 0 HcmV?d00001 diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/noError/vDNS.zip b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/noError/vDNS.zip new file mode 100644 index 0000000000000000000000000000000000000000..0bd8efbec860b37b174bdd36d527306eb190de15 GIT binary patch literal 3499 zcmaKu2{@E%8^>pcY*{AJNV3#S)*)n+CCq6wMs`CEAsH7Q+9@|!`MQ$ z$i8PQWjRSBj&0WB( zV@`W2rL9A><>+K{)zzIqaB^{jU&Xt@U0rSAc$}Lw4(}m}mcq2@z_s8KCGW=#o7(kS zq@>|uO)?V1&NfM+jI=JXQyWfH4DDpdDyW4&FmjxVzD4WGM;&2Lb>Y4F5l;8;%ZXhN@0}$9dju zN)Er~3`4(?w(Lnhj3K2@T{|_0$?b9O}*CleD^~ zS&U+9Fk>yWRZ4^|N4&8J68J;2!S&W$sh2+|XGJ&rK@=PN+;so3-eF~%jH;0+N)ECq z3T0vxMD6HiX8BuTlI@fP2DrJuMbp?1Fj{$*)u;J&%H~|F8Nc)BaAPrZU+BniX4?lh zqHT3#hiff()NX!Z4%APJP_MSGcL1Rl8LoKg}C)&3{k|Cs)UGLcUiSMvO-DQ)F(H$~UeTiQampIPLtY2fbBu-Bu&6?^(c7 zqU+v?g`J=5U-)Stg<2+|t)R7taIr`Z#%M_NkX-DYSwtdr^LC-6i9m>rLiJPgr%@I6 z9R{&2sZfJN6!q{tx8yz~%rc!b-zEC%h#He`O$3Xj+?aUe8yj9+QD5Q7d~DL?B`x+y zw!i8L?)TFB)WtLhN`o)pAO|L=H#%!Uun;obTmf>6DK{d6{X`Cagz=eXPJgS-s^rj( zcvy8m!KJFL$ini(3RA>ws=~8sCgSEiGFu&ISMw#42|mtm-%@$)ex$Neicrsk(XzBG zorC6Gz^^hR7f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enKe2nKWv^Xo{WwUs#FeMSp=Ri< zpfe}5{utj0neomMc&DDQI*?_egwLrhT4h7<6rn%g!%YwJPez9_yW{+8Y~MqRNQ8#|*j3w@XE!6wFJDV~lx7%?^TcPg=Xg&B5s;he! z`tOF-v*e5Z*C%Z6_t5A{4*>1`eFVS-03;oGU^zZ`WYfm*@lA?&VEccKij>=bB=1Gh zPbddRN>G@=3A`B@ps@QlXg?kX9h?FwL1=Ol`yGgU8U7B$RB5!QXg?kX9h`_LK|NFl zL5JoeN*G|Fa8H#9+;|VR9}mM04my-D8**EwR7D9pq--B{e(P`8ex!u`yW>;B+Ngiu z|0yMfg+gn885RD*WKYt5JWM&*q$nx=w7;Po(y~u^7jC*o*^hc~8uHr!z%lZ7oa{px I{jaD00nW3-oB#j- literal 0 HcmV?d00001 diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/vDNS_21_8.zip b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/vDNS_21_8.zip new file mode 100644 index 0000000000000000000000000000000000000000..c5fcf72d642499bc676b81946b7d3e9d301a9526 GIT binary patch literal 3480 zcmaKu2T+q)7ltDOA|Qk&RR|W8MIZ#FN~B0j=+y*}Zs-9*?;yp1AfWW3Qly5a0Ti$x zy?2NrC}5;WSem*5@<(=<4Xpbob93g)%y*yro_EeYM-P6KnjHWD&;e$VM2)JYo9J5d zQ}a;(-~>5pE9q#esTvxIIbqOly-5aYqU~tiS^cq^7COZf7r?*@5^~y zR{lW3E$vfl&TDvAo)HV%A5U<^hDTLH`Y<>YvmoP@g-@!e*~Hk zH6Ylwd<0ooDS2^{mn+)F5##Odj`s8tb-=iYy4ib)*}M4!cf;w!K_ynB z1vVFg@=h3^GTn8M7|kUH)E{|&@HE5kGX*ak0RX(n>He?N_`AB~7-*xL!Hi9xO~2Ql zN~Cv5GbdQfGZsiJ^F)o^awx>|aYhRL+?u@e1^!fdT@bc}dinXY%Rr6wWb|7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4KEzXZ-fX+J+YvrBNJ=XzijOzAVuobm&c$)kv2QmK<$}1am&7V%QkoEWi zG4V#7O)(_qTpkhjMD1LM(R0~jDO)op#lWY6Y!MGR5;&>mN2AGF7!8$!k7dcqLy>xp#0%kZ3-s|{RXrNz?k8+4 zJ|bmqzwJ=#7xOcnu|oEN+4>)~f zSuM&Qn-7}(9_NA(%R&hM43mp(&EgH7osh4%)@9ekg%VX7n*eW1aW2dnNfBetI9J#= z8{x zu$-pbu5j8|WC;@)Kw`Ci+UXL8xlCiA0yIqJxrt4uPo05oNzcHrkKc-5VlBEXj5k;} z9NF3{OASOO1NqS9Yh`T7Ou;Kb~!EJusw$qmh4cSE=m@S_2k=pgXRh9ywS)Oz+a(}G;K z-8O$YNjcnZ>dmRkmABW?8AY4MVc#QUx!?P61QE43iR$n=0ZEdz!R#@`HxA%w>dj;C zKH;5h=S?eK0m|_W*&553K@+9)EK=-tjM)aN@aiMP|*9j?v1?9{`o z12fPUp8z)#?7nmRAyp#%`3#3Vi{xF^vuBD%sEUenKe2nKWv^Xo{WwUs#FeMSp=Ri< zpfe}5{utj0neomMc&DDQI*?_egwLrhT4h7<6rn%g!%YwJPez9_yW{+8Y~MqRNQ8#|*j3w@XE!6wFJDV~lx7%?^TcPg=Xg&B5s;he! z`tOF-v*e5Z*C%Z6_t5A{4*>1`eFVS-03;oGU^zZ`WYfm*@lA?&VEccKij>=bB=1Gh zPbddRN>G@=3A`B@ps@QlXg?kX9h?FwL1=Ol`yGgU8U7B$RB5!QXg?kX9h`_LK|NFl zL5JoeN*G|Fa8H#9+;|VR9}mM04my-D8**EwR7D9pq--B{e(P`8ex!u`yW>;B+Ngiu z|0yMfg+gn885RD*WKYt5JWM&*q$nx=w7;Po(y~u^7jC*o*^hc~8uHr!z%lZ7oa{px I{jaD00nW3-oB#j- literal 0 HcmV?d00001 diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/vProb.zip b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/vProb.zip new file mode 100644 index 0000000000000000000000000000000000000000..86472e23fdbfaaf974b34fd58028dedf96cf1eb7 GIT binary patch literal 33429 zcmafbV{j+m-sdm2ZA_AhCbn(c=ESx=v2EM7ZQHh;?EG)l)_v|i&+bO=h%mpAk*=(@uC$Gjlclk)vy=e8 zsj;=AprwtIk)VyWiMc6_o4%Fhr0T299vkYH*Ee){?r$n^E%Hvjh@^5U%_x=`hRy`~ zFrZ`-8AAxM=x?uV6mls^Qx49#-?4m8_s7?n-YnU$;qNAMJ2KgDUjid!@K|!05`qNw zM8fcoVWi|0pk0+73x~uID1j0}a@qlIOu{7)z}xlq9t37y_g1;lse=iObv4H6mB2y$ffD={FKdSMLfa)L=Rl@N=gM zx=L|b*5ZSoFR~U6ROkM{uHf@$0{uO})bgpREFxaj@x!AzWC2AVp;xI5XwazBNbl$pM zrr|;D>Vc|ofF(1dSyDt%$8BqB@F91>%PdysEiV!A(7dUe*DP{v*rTctZ~yaj(TlD_ zY{N;Uvob=mz0+e=+VQ$v3Zq;*eU|5uD^X*VJsd2-XIW{jI|>ijT~XB@_cHF+Lm^4Re+up7p!an5exOgQNmdz9T|p zPQUP1^ajJBJ&YI-NH^*Gntt3;fmmK~BJ0OT)s7B8KKmC4yDy~e#-%2cFobsoVFSpJHHO52YnV2TbBCcm z)I$noJzqipj;mv%XXT4So->*tk!7Oq;oy+-)FW2r zQUhZkp68!ikVm7{E0_gBiAilDnZvjN4=rkgJciLy*M1$O*Pm%h88q_k z7xk4%67v1>mFyOLmc;0vntk~*^r&D5xKuMOx_WVz&Ae)^Ykt>?el}B6HM64kMlikY z#RczwmXn8?_M5$!{uQ;7qW*%^p~ zscbSzrz*RdQ(4*u9Y?t%v_=1Q7faq|i`faOv%mY#o03IhS#_9fzQiktM(7NV;dcxj zG=IG^kb~y&Fng$3}=vR=J%U?{U!y=_+o19yQ_xV+l9V;dk>|!k&7WKq z{Nv*TcIw0%Y1U%xN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8Wq zzo#YtLKqPE&m`r)-}&=@|DMhF>&{`3KU9g7;6K*KpVCTxp+!pl0qsAh&fk0WpJcbc z06P_b0{(HZ0Z9D*{+NG~3I4)SQvE~0{?(EH-AjH${8{C{3&(yTCaM1~{rK-PvcDJd zPeP|(kZhX&UC4h8VgFkhe^<@?0_4*ElZNK+1^U@IehSzU_Y_{zm@%y?B431Ac)` v+y4RVucrUMjhla3d;Y>~a{VXFe?ReGZ59kLtG|1P3;0z6OwKeOKR^8+qp_-7 literal 0 HcmV?d00001 diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/vProbe_FE_081816.zip b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/vProbe_FE_081816.zip new file mode 100644 index 0000000000000000000000000000000000000000..578c561e4cf52aacc059310b44cfb0dc48d19010 GIT binary patch literal 33443 zcmafbV{j+m-sdm2ZA_AhCbn(c=ESx=v2EM7ZQHh;?EG)l)_v|i&+bO=h%mpAk*=(@uC$Gjlclk)vy=e8 zsj;=AprwtIk)VyWiMc6_o4%Fhr0T299vkYH*Ee){?r$n^E%Hvjh@^5U%_x=`hRy`~ zFrZ`-8AAxM=x?uV6mls^Qx49#-?4m8_s7?n-YnU$;qNAMJ2KgDUjid!@K|!05`qNw zM8fcoVWi|0pk0+73x~uID1j0}a@qlIOu{7)z}xlq9t37y_g1;lse=iObv4H6mB2y$ffD={FKdSMLfa)L=Rl@N=gM zx=L|b*5ZSoFR~U6ROkM{uHf@$0{uO})bgpREFxaj@x!AzWC2AVp;xI5XwazBNbl$pM zrr|;D>Vc|ofF(1dSyDt%$8BqB@F91>%PdysEiV!A(7dUe*DP{v*rTctZ~yaj(TlD_ zY{N;Uvob=mz0+e=+VQ$v3Zq;*eU|5uD^X*VJsd2-XIW{jI|>ijT~XB@_cHF+Lm^4Re+up7p!an5exOgQNmdz9T|p zPQUP1^ajJBJ&YI-NH^*Gntt3;fmmK~BJ0OT)s7B8K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product-manager/src/test/resources/validation/zips/various/vid_test_pcrf_base_template.zip b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/various/vid_test_pcrf_base_template.zip new file mode 100644 index 0000000000000000000000000000000000000000..49c16f6774cf92fbc6cd8cf6af659f822a283dc2 GIT binary patch literal 4223 zcmai2XH*l)whlcg1OlN87%38ZRYH-Dl!&3X&;p@1=?Kz`f)u4o6C?~-aDcw zy$I3?MM3K0-1Xk`oO{k)cg>HPJ!|c6*391P+xr`&CJ`|N00001R*{f|gcP?`p|ItUuAU#CRH+Ne+fvdr%S|tNPxf_{)MVe(7se_S91=w@wCW!NHYRO7 z=;;KLCYtJXd|k)Q4W!qM<8ISA&!wg$C_fE>BFR! z2OYL6&ObR4&4-^v-IHRv_oMaG0R}%Csh3<AbYT~ioaxrc>COcva(-*53b-O!REOG?M{|_;@kES~J zh0GT8GQ@=>007)nbLR5SGJW zL{t4y{Ewx#mv3252mnxC&i53w)Kyh<^#mO~-CRpnmURGx*v5`&JuW^HE-qG*A~g-i z2OiqC3hK5&Y%i42>Nk*_%xxs0j>NR3Hw47UoQ;faH3HQgAE*Z^cxamhDm-{+jzPPE zra3FgV^jR zAq2UunZO$)f0${kGyel{4hbq7zi=Pd02)xLm+5>Lfb`{K^YSNg z*KOcpIUQ3>Q+_fqy2a+5-D%OBfe5I)<<}Y=lM|F2d+;5f?@yW0Mx{3#8I6Ur-C;74 z%&a*e)tlii#?!HTrnHL7I2IOuUd;j=kIWRprM{TFH?8g6u-aAzApELw>2`)LT+f0<79WE3^92fi7NqE{?#9blUFaM59IjmQWn z-np(x(2_ZKY+;DYU?j};JX6m^LJw%Ey)WBb#{mr zC=zT$85|Ek^1qTo#H_NHL!zu5E>?s)JV`mbu7ILc zG4$&F`JXhBX!*!oAwJY10uf2Vr;RG$g@=&DAw>jrl#K)mgt%*|_a4i>^_bvKy~_Ut z*)N%yBYMz&UH@4D0V#=U+tJD|m5jAu=AdK)lk@gK-LCD$=4Ny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 z9lq$UJkV)V&vftEJ7-PMhQBE3j$=SWmOVIN%}eIC=f1@7ZNK4fJPIy;rgF6LPVyJk zj;yW}_OIQ9vl>ro7qT}ue@qs!Rn*S7Vc7)L<*r>F^{zpke0O5M7@Fvhy0)kGfq1Ur2vcX|C1vZxuD^7yc1E4TLA;ozr_wf@Psc_B! literal 0 HcmV?d00001 diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/zipFileWithFolder.zip b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/validation/zips/zipFileWithFolder.zip new file mode 100644 index 0000000000000000000000000000000000000000..9d2fb1e8abf08483fdd18bce15f0d5e66abf02ce GIT binary patch literal 290 zcmWIWW@h1H0DwU9 literal 0 HcmV?d00001 diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/vspmanager/zips/emptyComposition.zip b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/vspmanager/zips/emptyComposition.zip new file mode 100644 index 0000000000000000000000000000000000000000..76b3bfd8730c83869a6ddbc2c579d644db17211d GIT binary patch literal 722 zcmWIWW@Zs#U}E54=#J(0RQO|A!D8(hh;zHzR_XI00W-M2Gir`d8ooA%`V^e68x zbc)KXC~x}4Z241yC!=)hsw=xLt=^>3ZSKQcJ!xlYycom!ZhU;9f2n@|{r%o^r3?WFi~5`#eCI4__nsoR({WyCT#UW;!XAz8iv^FT z%DFADV{|gSndBvwJ;QbD$x~kK6E;LSP2$vSy(FjMYQ9=k<@x2jf7v<9x;EyXV4JbV zfcM|^8HvpW^5PA7O^x;3ng1Vi)th*8=lz-Xw8$&6J#%X5o5wG@)V9e#d}#GoJiwcg zNrVAc?5hC%#=yYHpa7;Z(gGJ$f{{UjVSyco`NeM+84FIbqtNIUpavbX1uDPol8kG+4W@Q68jtK}40O>zKLl_tU5;O|| literal 0 HcmV?d00001 diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/vspmanager/zips/emptyZip.zip b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/vspmanager/zips/emptyZip.zip new file mode 100644 index 0000000000000000000000000000000000000000..15cb0ecb3e219d1701294bfdf0fe3f5cb5d208e7 GIT binary patch literal 22 NcmWIWW@Tf*000g10H*)| literal 0 HcmV?d00001 diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/vspmanager/zips/fullComposition.zip b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/vspmanager/zips/fullComposition.zip new file mode 100644 index 0000000000000000000000000000000000000000..027f2c039a02f01d8a842334f3c7430153e2e59b GIT binary patch literal 3905 zcmZ`+2T&8*whe@?(xe$ciu5L-3(|Wvf}w?ofDnp=jx_0^gNP^sp%=YWX`x6HsgZ=< zi&6xn7byXO&%5*I&-Kl}bI#0~Gjq;fv(MUlW-o|7kc0t144?o|KB3jUqg_#A2?PM@ zsQ>_G007|V<}K>#h7c78i_3}HdVwWm!D9AE-@3P7D>CI7qE@xn6*Q(t-kpRe_B}h! z&(Y4_mRjT4TPc$OoML-seiWeS2897;mq* z?6uP3P@*&~W>NAR{A=XEhHUGOw}@4NFQI4B0TtkvZgO_@csv(})+I0gCYx`uvGWxk z!lkyuy(uP9(b7bY)06yVDLL$rb^n50M#c}b7S!k#f zV09b@#mLS>CAcIS8lG(6pWY3A(G2n+8L10;>6#V0L%}>3QQX#H$w<9zJ{!nEVuE(} zux-DAwa;$Y?H3#ffydHCoi*RrN)yPY$}k;seb31q8HhXXMR}P_b{HJ&Dni#rM@=Z_ zhtkQE8l8iEC9sXM!Mow`#c5uB-@Zi6v`wS^ufF^#J-&V6@VQPrvLi26{*(GBqm^%s z!l#Z1^@RF*ut)dkElI?tg57okN|G8~<=wsDYQSH7M%Gj@%kvAbdn1wcHGBrWIa%W( zE5;66GqXGVD@xnhyX>opw31(*{fGwtR>9?a%0X;C)X9d3P~cj6j?`v}&Tgkm-4*E! zjOCrr>f0u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8-1H?4-0(n5bhWV zDxWc!36*LZpE=gt?fVqam(Vzw&s(&_PR|DKWp`N9Wutv?4rph~72x%%ol1@|*`*pX z^vhGYJ{~S-unPsNw|2u#h8S|!v&y|!L?g3j!ORl}wMQ%i(1zLPsccLx17M3ZIFLGZO zHsBcqk#oqKe2s@;MyV_ECdG~J9a0nN;y9ELuI_20XPq>n(fH!0NPYFvCXa~Ox?;wP zX#yb0$GJbPyUHl>FsJT_opmB4HXzy3rA?SU6Nb=|;+u%86}W5!yG2Z%Eu8vk-`|Vm z()A047BgY@Wt^t6c7zi-L$nKLe?s5B8dz+nOtR0r@)fqsXMIdmZMko zf>%j-m235a<$U+QNb)NOG4&~Lxo&u_Eh7p7Z&hatqB3PO3?H90%V zCj&MF1hDdgUjhFY85Q~5R%u%b=G(TgviI#3vc|`MeNPv9BiW}X9ZZ0*L_)(NWk{<% zez+&;k>;oug%1=Ne~vX1LJaCbyJkFV%|f2lYKQc14{=DgGG7%Sv%Mjctks+aXnwP5 zwLKXd6M=}6TP@OHL#uUuMlg8j&%{X52%Q**JKsa)S}GOfHr5Nz+=Asp_3*)UOjaUl~wvprMl)0NdQ9>w4440^_1*F5R!S%KenoqPpn&@S5cxJ214dDiLK7@RTf~f4(_Om_JUIVd! z%-8rBSwZQn>(G@I74Hb>+eb{H(0~T{C{D@(P=c+T>NVp7EG?gnIsMK$b8%#HISOpY zbzPjJmn;qlfantuGXVb0`|(^Q2LKQOIRD0fb%Ip?dw~eR0!SXW$V49x5vkn#6aSm& z&#CsGL@%$b=l^FpuV&nT64BDY{w5mqwEP4Ao9Ium{z=4jrQILW{WJXT1M|PbeylP3 X10njPWdHdM;MD?O>3{m40s#CEi()HE literal 0 HcmV?d00001 diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/vspmanager/zips/invalidTypes.zip b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/vspmanager/zips/invalidTypes.zip new file mode 100644 index 0000000000000000000000000000000000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cJkvTePrcF40;7+ zQ6yzYHzp&?M6Vevr6)2(_mJJMYDagIWm$!OdR3bTY+87bW)LMZr+#;0U#dpV;DCHE zuUjb7LV4mfk!}`JxT@~Y#~>#YLW9rs??H9#NmijYn);&rAi*B8C|;090t2JUL@eqQ zv-@sc%wf;E*RI=e{&Z5nA)xX(y+Nors@rfB;1sik(Na4)+Blf^b>P3yG&(z9^G_!0 zBda`O5=yEA^L(6H=qa8?qEe@N&Dx6%KoIE{MvVi6T~j80vMo-hjSvkRy7Yn9g_gnt zR^FTD*3rZJE+o3bVb{rtp$F}FouLHLt5x`0y5@+N0HN^k&WI zP2ut(&)sWFkR%{H1^5(LK#){GkYaKRp?~Y*HyeO!%maH}j{k#~i{%#^VD`g}J#l~h zmm>hdgzuv?Zm8Z6szYP6;evgG*ZVbML`sBVwc39S4yr293J;Xxld-a~1b&v(!sN5EtaKtMOgGkTBU?v*q}UWrg;Te6%Disc+B3|^L10i5Wj zn4It(fvbfdNpvD;6iNT#=p^4>QI*BJjPlC=73}3WG@jVz+`&Z=wwrtkY?99p0W-yx z)MdZbcv}O?jY;JWC1jy3$vE9n!&b>RdN{c(6J2b_Eu?ua(vkj;#>v(&amCpb z=BO&6&QWd09ILyrbTMsq&{dkz#q! zpqtw;V>u}{UvQ1Ci5rzD5tSmccQ>RYJds*;S8=2d=1ZFXW%o#b?ygzi;XeOR0EQa2 zOE_{TNCLox|FuDX=6`YN z-2cu0Tf6=&wP^m|TlpP-m-@B6ewGrwJR$hsrGDSl%l{;Gh3K!6A-cTuFVACg|2pmg F{1-XqAFlua literal 0 HcmV?d00001 diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/vspmanager/zips/missingYml.zip b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/vspmanager/zips/missingYml.zip new file mode 100644 index 0000000000000000000000000000000000000000..5bc0bea15d31e23819b25502315c901db52bff8c GIT binary patch literal 838 zcmWIWW@Zs#U}E54_z-g58HNlD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iMP|*9j?v1?9{`o z12fPUp8z)#?7nmRAyp#%`3#3Vi{xF^vuBD%sEUenKe2nKWv^Xo{WwUs#FeMSp=Ri< zpfe}5{utj0neomMc&DDQI*?_egwLrhT4h7<6rn%g!%YwJPez9_yW{+8Y~MqRNQ8#|*j3w@XE!6wFJDV~lx7%?^TcPg=Xg&B5s;he! z`tOF-v*e5Z*C%Z6_t5A{4*>1`eFVS-03;oGU^zZ`WYfm*@lA?&VEccKij>=bB=1Gh zPbddRN>G@=3A`B@ps@QlXg?kX9h?FwL1=Ol`yGgU8U7B$RB5!QXg?kX9h`_LK|NFl zL5JoeN*G|Fa8H#9+;|VR9}mM04my-D8**EwR7D9pq--B{e(P`8ex!u`yW>;B+Ngiu z|0yMfg+gn885RD*WKYt5JWM&*q$nx=w7;Po(y~u^7jC*o*^hc~8uHr!z%lZ7oa{px I{jaD00nW3-oB#j- literal 0 HcmV?d00001 diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/vspmanager/zips/withoutManifest.zip b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/vspmanager/zips/withoutManifest.zip new file mode 100644 index 0000000000000000000000000000000000000000..6b52cf6065a5b7cd004621f038733372a7c451b5 GIT binary patch literal 970 zcmWIWW@Zs#U}E54_z-g58HNlD3^qW_55&nusfi`2@x>*H$=Q0v8K*sbbpkc? zJblhx^VMV86fAnGrZ!fzq_HF~FRP|7FUhYjE-P+kQ=Zf&kJLOqeQ|~W6w|-#UaVIJ zH1#|XO9F9OZZ6R5+{B!mc&J5b#YuXpd1cxjI$mddbv<>pwmo_p6rgeXyyjWoUj3Ci z9$SM7&Y$;m6w*1jhKWl`TC(BDou;{ucpn=V3tw(b+P81rM+e5k70$uxvCkQph3_g| zc42mAo#CWx((0DMweS_sx? zWX0#$%G{i*lMm({R^VxSKlK;i9)~3@dg6U6x6NDSyK0N}qTcC>tt^s4D`)?D=lx=n z!|syY{Kstn-uB<0Q7$koI$)QGSOs@RO01z%#vGkR7QHW$>}H=YGO(U-e-@rwEwz<(&Xcc}!ZusKyQVlk4mC5HZzk!#BV^HzTglgr?k!an-lKSC zvPt(e{g2KqD?26&c)oYKblRhebLNNl-@@)X$DjWCN$o=2Qvr|nESKyXO&FAB>^dmh zGx_!1m+jR{?D8d|Pie8IyfIynvBq@4)OBYV$|if*ac{U&EAXuUMdFp8@=whxwU9 literal 0 HcmV?d00001 diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/withNetwork/MANIFEST.json b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/withNetwork/MANIFEST.json new file mode 100644 index 0000000000..3d7004f8c0 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/withNetwork/MANIFEST.json @@ -0,0 +1,21 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-mog-0108-bs1271.yml", + "type": "HEAT", + "data": [ + { + "file": "hot-mog-0108-bs1271.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "network.yml", + "type": "HEAT_NET" + } + ] +} diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/withNetwork/hot-mog-0108-bs1271.env b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/withNetwork/hot-mog-0108-bs1271.env new file mode 100644 index 0000000000..407bc8db30 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/withNetwork/hot-mog-0108-bs1271.env @@ -0,0 +1,60 @@ +parameters: + pd_server_names: ZRDM1MOGX01MPD001,ZRDM1MOGX01MPD002 + pd_image_name: MOG_BASE_8.0 + pd_flavor_name: m3.xlarge + oam_server_names: ZRDM1MOGX01OAM001,ZRDM1MOGX01OAM002 + oam_image_name: MOG_BASE_8.0 + oam_flavor_name: m3.xlarge + sm_server_names: ZRDM1MOGX01MSM001,ZRDM1MOGX01MSM002 + sm_image_name: MOG_BASE_8.0 + sm_flavor_name: m2.xlarge4 + ps_server_names: ZRDM1MOGX01MPS001,ZRDM1MOGX01MPS002,ZRDM1MOGX01MPS003,ZRDM1MOGX01MPS004 + ps_image_name: MOG_BASE_8.0 + ps_flavor_name: m3.xlarge + cm_server_names: ZRDM1MOGX01MCM001 + cm_image_name: MOG_BASE_8.0 + cm_flavor_name: m3.xlarge + availabilityzone_name: nova + oam_net_name: oam_protected_net_0 + oam_net_ips: 107.250.172.213,107.250.172.214,107.250.172.215,107.250.172.216,107.250.172.217 + #internet_net_name: dmz_protected_net_0 + #internet_net_ips: 107.239.53.4,107.239.53.5 + # internet_net_floating_ip: 107.239.53.6 + sl_net_name: exn_protected_net_0 + sl_net_ips: 107.239.45.4,107.239.45.5 + sl_net_floating_ip: 107.239.45.6 + repl_net_name: cor_direct_net_0 + repl_net_ips: 107.239.33.57,107.239.33.58 + rx_net_name: cor_direct_net_1 + rx_net_ips: 107.239.34.3,107.239.34.4 + rx_net_floating_ip: 107.239.34.5 + ran_net_name: gn_direct_net_0 + ran_net_ips: 107.239.36.3,107.239.36.4 + ran_net_floating_ip: 107.239.36.5 + dummy_net_name_0: mog_dummy_0 + dummy_net_start_0: 169.254.1.4 + dummy_net_end_0: 169.254.1.254 + dummy_net_cidr_0: 169.254.1.0/24 + dummy_net_netmask_0: 255.255.255.0 + dummy_net_name_1: mog_dummy_1 + dummy_net_start_1: 169.254.2.4 + dummy_net_end_1: 169.254.2.254 + dummy_net_cidr_1: 169.254.2.0/24 + dummy_net_netmask_1: 255.255.255.0 + csb_net_name: int_mog_csb_net + csb_net_ips: 172.26.0.10,172.26.0.11,172.26.0.12,172.26.0.13,172.26.0.14,172.26.0.15,172.26.0.16,172.26.0.17,172.26.0.18,172.26.0.19,172.26.0.20 + csb_net_start: 172.26.0.1 + csb_net_end: 172.26.0.254 + csb_net_cidr: 172.26.0.0/24 + csb_net_netmask: 255.255.255.0 + security_group_name: mog_security_group + mog_swift_container: http://10.147.38.210:8080/v1/AUTH_8e501b8121f34a6eaaf526d3305985cc/mogtestcontainer + mog_script_dir: /root + mog_script_name: http://10.147.38.210:8080/v1/AUTH_8e501b8121f34a6eaaf526d3305985cc/mogtestcontainer/mog-cloudinit.sh + mog_parameter_name: http://10.147.38.210:8080/v1/AUTH_8e501b8121f34a6eaaf526d3305985cc/mogtestcontainer + cluster-manager-vol-1: 43ccf5ba-2d50-427b-a38f-e8c7d8670eee + session-manager-vol-1: 49201898-333d-4c88-b58d-cf573b091633 + session-manager-vol-2: 4c35b5f1-ce99-4220-a6e2-cda6e2d713a0 + oam-vol-1: 0a7fcd9e-2624-401d-ac21-b0191f85ec77 + oam-vol-2: 6d169cb6-6ddc-41dc-920c-2839898a2924 + cluster-manager-vol-2: 6f92e211-2d61-487d-8f84-d2d00cea3698 diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/withNetwork/hot-mog-0108-bs1271.yml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/withNetwork/hot-mog-0108-bs1271.yml new file mode 100644 index 0000000000..f069d4dd23 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/withNetwork/hot-mog-0108-bs1271.yml @@ -0,0 +1,733 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates MOG stack + +parameters: + pd_server_names: + type: comma_delimited_list + label: PD server names + description: name of the PD instance + pd_image_name: + type: string + label: image name + description: PD image name + pd_flavor_name: + type: string + label: PD flavor name + description: flavor name of PD instance + oam_server_names: + type: comma_delimited_list + label: OAM server names + description: name of the OAM instance + oam_image_name: + type: string + label: image name + description: OAM image name + oam_flavor_name: + type: string + label: OAM flavor name + description: flavor name of OAM instance + sm_server_names: + type: comma_delimited_list + label: SM server names + description: name of the SM instance + sm_image_name: + type: string + label: image name + description: SM image name + sm_flavor_name: + type: string + label: SM flavor name + description: flavor name of SM instance + ps_server_names: + type: comma_delimited_list + label: PS server names + description: name of the PS instance + ps_image_name: + type: string + label: PS image name + description: PS image name + ps_flavor_name: + type: string + label: PS flavor name + description: flavor name of PS instance + cm_server_names: + type: comma_delimited_list + label: CM server names + description: name of the CM instance + cm_image_name: + type: string + label: image name + description: CM image name + cm_flavor_name: + type: string + label: CM flavor name + description: flavor name of CM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + oam_net_name: + type: string + label: oam network name + description: name of the oam network + oam_net_ips: + type: comma_delimited_list + label: internet network ips + description: ip of the OAM network + # internet_net_name: + # type: string + # label: internet network name + # description: id of the internet network + # internet_net_ips: + # type: comma_delimited_list + # label: internet network ips + # description: ip of the internet network + # internet_net_floating_ip: + # type: string + # label: mog internet virtual ip + # description: mog internet virtual ip + sl_net_name: + type: string + label: silver lining network name + description: id of the sl network + sl_net_ips: + type: comma_delimited_list + label: silver lining network ips + description: ips of the sl network + sl_net_floating_ip: + type: string + label: mog sl net virtual ip + description: mog sl net virtual ip + repl_net_name: + type: string + label: Replication network name + description: name of the replication network + repl_net_ips: + type: comma_delimited_list + label: repl network ips + description: ips of repl network + rx_net_name: + type: string + label: Rx network name + description: Rx network name + rx_net_ips: + type: comma_delimited_list + label: Rx network ips + description: Rx network ips + rx_net_floating_ip: + type: string + label: mog rx net virtual ip + description: mog rx net virtual ip + ran_net_name: + type: string + label: RAN network name + description: RAN network name + ran_net_ips: + type: comma_delimited_list + label: RAN network ips + description: RAN network ip + ran_net_floating_ip: + type: string + label: mog ran net virtual ip + description: mog ran net virtual ip + csb_net_name: + type: string + label: csb internal network name + description: csb internal network name + csb_net_start: + type: string + label: csb internal start + description: csb internal start + csb_net_end: + type: string + label: csb internal end + description: csb internal end + csb_net_cidr: + type: string + label: csb ineternal cidr + description: csb internal cidr + csb_net_netmask: + type: string + description: CSB internal network subnet mask + csb_net_ips: + type: comma_delimited_list + description: mog_csb_net IP addresses + dummy_net_name_0: + type: string + label: csb internal network name + description: csb internal network name + dummy_net_start_0: + type: string + label: csb internal start + description: csb internal start + dummy_net_end_0: + type: string + label: csb internal end + description: csb internal end + dummy_net_cidr_0: + type: string + label: csb ineternal cidr + description: csb internal cidr + dummy_net_netmask_0: + type: string + description: CSB internal network subnet mask + dummy_net_name_1: + type: string + label: csb internal network name + description: csb internal network name + dummy_net_start_1: + type: string + label: csb internal start + description: csb internal start + dummy_net_end_1: + type: string + label: csb internal end + description: csb internal end + dummy_net_cidr_1: + type: string + label: csb ineternal cidr + description: csb internal cidr + dummy_net_netmask_1: + type: string + description: CSB internal network subnet mask + + security_group_name: + type: string + label: security group name + description: the name of security group + cluster-manager-vol-1: + type: string + label: mog-cm-vol-1 + description: Cluster Manager volume 1 + session-manager-vol-1: + type: string + label: mog-sm-vol-1 + description: Session Manager volume 1 + session-manager-vol-2: + type: string + label: mog-sm-vol-2 + description: Session Manager volume 2 + oam-vol-1: + type: string + label: mog-oam-vol-1 + description: OAM volume 1 + oam-vol-2: + type: string + label: mog-oam-vol-2 + description: OAM volume 2 + mog_swift_container: + type: string + label: mog Config URL + description: Config URL + mog_script_dir: + type: string + label: mog Config script directory + description: Config script directory + mog_script_name: + type: string + label: mog Config script name + description: Config script name + mog_parameter_name: + type: string + label: mog script parameter name + description: Config script parameter csv file name + cluster-manager-vol-2: + type: string + label: mog-cm-vol-2 + description: Cluster Manager volume 2 with ISO image + +resources: + mog_security_group: + type: OS::Neutron::SecurityGroup + properties: + description: mog security group + name: {get_param: security_group_name} + rules: [{"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0} + ] + + csb_net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: csb_net_name} + + csb_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: csb_net_name} + network_id: { get_resource: csb_net } + cidr: { get_param: csb_net_cidr } + allocation_pools: [{"start": {get_param: csb_net_start}, "end": {get_param: csb_net_end}}] + enable_dhcp: true + + dummy_net_0: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: dummy_net_name_0} + + dummy_ip_subnet_0: + type: OS::Neutron::Subnet + properties: + name: {get_param: dummy_net_name_0} + network_id: { get_resource: dummy_net_0 } + cidr: { get_param: dummy_net_cidr_0 } + allocation_pools: [{"start": {get_param: dummy_net_start_0}, "end": {get_param: dummy_net_end_0}}] + enable_dhcp: true + + dummy_net_1: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: dummy_net_name_1} + + dummy_ip_subnet_1: + type: OS::Neutron::Subnet + properties: + name: {get_param: dummy_net_name_1} + network_id: { get_resource: dummy_net_1 } + cidr: { get_param: dummy_net_cidr_1 } + allocation_pools: [{"start": {get_param: dummy_net_start_1}, "end": {get_param: dummy_net_end_1}}] + enable_dhcp: true + + + mogconfig: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + template: | + #!/bin/bash + wget -P script_dir swift_container/script_name + wget -P script_dir swift_container/parameter_name + chmod 755 script_dir/script_name + script_dir/script_name + params: + swift_container: {get_param: mog_swift_container} + script_dir: {get_param: mog_script_dir} + script_name: {get_param: mog_script_name} + #parameter_name: {get_param: mog_parameter_name} + + + servergroup_mog01: + type: OS::Nova::ServerGroup + properties: + policies: + - anti-affinity + server_pd_01: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [pd_server_names, 0]} + image: {get_param: pd_image_name} + flavor: {get_param: pd_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: pd01_port_0} + - port: {get_resource: pd01_port_1} + - port: {get_resource: pd01_port_2} + - port: {get_resource: pd01_port_3} + - port: {get_resource: pd01_port_4} + - port: {get_resource: pd01_port_5} + - port: {get_resource: pd01_port_6} + # - port: {get_resource: pd01_port_7} + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog01}} + user_data_format: RAW + + + pd01_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + pd01_port_1: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [oam_net_ips, 0]}}] + security_groups: [{get_resource: mog_security_group}] + pd01_port_2: + type: OS::Neutron::Port + properties: + network: {get_resource: dummy_net_0} + security_groups: [{get_resource: mog_security_group}] + pd01_port_3: + type: OS::Neutron::Port + properties: + network: {get_param: rx_net_name} + fixed_ips: [{"ip_address": {get_param: [rx_net_ips, 0]}}] + allowed_address_pairs: [{"ip_address": {get_param: rx_net_floating_ip} }] + security_groups: [{get_resource: mog_security_group}] + pd01_port_4: + type: OS::Neutron::Port + properties: + network: {get_resource: dummy_net_1} + security_groups: [{get_resource: mog_security_group}] + pd01_port_5: + type: OS::Neutron::Port + properties: + network: {get_param: ran_net_name} + fixed_ips: [{"ip_address": {get_param: [ran_net_ips, 0]}}] + allowed_address_pairs: [{"ip_address": {get_param: ran_net_floating_ip} }] + security_groups: [{get_resource: mog_security_group}] + + pd01_port_6: + type: OS::Neutron::Port + properties: + network: {get_param: sl_net_name} + fixed_ips: [{"ip_address": {get_param: [sl_net_ips, 0]}}] + allowed_address_pairs: [{"ip_address": {get_param: sl_net_floating_ip}}] + security_groups: [{get_resource: mog_security_group}] + + # pd01_port_7: + #j type: OS::Neutron::Port + # properties: + # network: {get_param: internet_net_name} + # fixed_ips: [{"ip_address": {get_param: [internet_net_ips, 0]}}] + # allowed_address_pairs: [{"ip_address": {get_param: internet_net_floating_ip} }] + # security_groups: [{get_resource: mog_security_group}] + + server_pd_02: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [pd_server_names, 1]} + image: {get_param: pd_image_name} + flavor: {get_param: pd_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: pd02_port_0} + - port: {get_resource: pd02_port_1} + - port: {get_resource: pd01_port_2} + - port: {get_resource: pd01_port_3} + - port: {get_resource: pd02_port_4} + - port: {get_resource: pd02_port_5} + - port: {get_resource: pd02_port_6} + # - port: {get_resource: pd02_port_7} + + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog01}} + user_data_format: RAW + + pd02_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + pd02_port_1: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [oam_net_ips, 1]}}] + security_groups: [{get_resource: mog_security_group}] + + pd02_port_2: + type: OS::Neutron::Port + properties: + network: {get_resource: dummy_net_0} + security_groups: [{get_resource: mog_security_group}] + + pd02_port_3: + type: OS::Neutron::Port + properties: + network: {get_param: rx_net_name} + fixed_ips: [{"ip_address": {get_param: [rx_net_ips, 1]}}] + allowed_address_pairs: [{"ip_address": {get_param: rx_net_floating_ip} }] + security_groups: [{get_resource: mog_security_group}] + + pd02_port_4: + type: OS::Neutron::Port + properties: + network: {get_resource: dummy_net_1} + security_groups: [{get_resource: mog_security_group}] + + pd02_port_5: + type: OS::Neutron::Port + properties: + network: {get_param: ran_net_name} + fixed_ips: [{"ip_address": {get_param: [ran_net_ips, 1]}}] + allowed_address_pairs: [{"ip_address": {get_param: ran_net_floating_ip} }] + security_groups: [{get_resource: mog_security_group}] + + pd02_port_6: + type: OS::Neutron::Port + properties: + network: {get_param: sl_net_name} + fixed_ips: [{"ip_address": {get_param: [sl_net_ips, 1]}}] + allowed_address_pairs: [{"ip_address": {get_param: sl_net_floating_ip}}] + security_groups: [{get_resource: mog_security_group}] + + # pd02_port_7: + # type: OS::Neutron::Port + # properties: + # network: {get_param: internet_net_name} + # fixed_ips: [{"ip_address": {get_param: [internet_net_ips, 1]}}] + # allowed_address_pairs: [{"ip_address": {get_param: internet_net_floating_ip} }] + # security_groups: [{get_resource: mog_security_group}] + + servergroup_mog02: + type: OS::Nova::ServerGroup + properties: + policies: + - anti-affinity + server_oam01: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [oam_server_names, 0]} + image: {get_param: oam_image_name} + flavor: {get_param: oam_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: oam01_port_0} + - port: {get_resource: oam01_port_1} +# block_device_mapping: +# - device_name: vdd +# volume_id: { get_param: oam-vol-1 } + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog02}} + user_data_format: RAW + + oam01_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + oam01_port_1: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [oam_net_ips, 2]}}] + security_groups: [{get_resource: mog_security_group}] + + + server_oam02: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [oam_server_names, 1]} + image: {get_param: oam_image_name} + flavor: {get_param: oam_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: oam02_port_0} + - port: {get_resource: oam02_port_1} +# block_device_mapping: +# - device_name: vdd +# volume_id: { get_param: oam-vol-2 } + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog02}} + user_data_format: RAW + + oam02_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + oam02_port_1: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [oam_net_ips, 3]}}] + security_groups: [{get_resource: mog_security_group}] + + + server_sm01: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [sm_server_names, 0]} + image: {get_param: sm_image_name} + flavor: {get_param: sm_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: sm01_port_0} + - port: {get_resource: sm01_port_1} +# block_device_mapping: +# - device_name: vdd +# volume_id: { get_param: session-manager-vol-1 } + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog02}} + user_data_format: RAW + + sm01_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + sm01_port_1: + type: OS::Neutron::Port + properties: + network: {get_resource: dummy_net_0} + security_groups: [{get_resource: mog_security_group}] + + sm01_port_2: + type: OS::Neutron::Port + properties: + network: {get_param: repl_net_name} + fixed_ips: [{"ip_address": {get_param: [repl_net_ips, 0]}}] + security_groups: [{get_resource: mog_security_group}] + + server_sm02: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [sm_server_names, 1]} + image: {get_param: sm_image_name} + flavor: {get_param: sm_flavor_name} + availability_zone: {get_param: availabilityzone_name} +# block_device_mapping: +# - device_name: vdd +# volume_id: { get_param: session-manager-vol-2 } + networks: + - port: {get_resource: sm02_port_0} + - port: {get_resource: sm02_port_1} + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog02}} + user_data_format: RAW + + sm02_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + sm02_port_1: + type: OS::Neutron::Port + properties: + network: {get_resource: dummy_net_0} + security_groups: [{get_resource: mog_security_group}] + + sm02_port_2: + type: OS::Neutron::Port + properties: + network: {get_param: repl_net_name} + fixed_ips: [{"ip_address": {get_param: [repl_net_ips, 1]}}] + security_groups: [{get_resource: mog_security_group}] + + servergroup_mog03: + type: OS::Nova::ServerGroup + properties: + policies: + - anti-affinity + server_ps01: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [ps_server_names, 0]} + image: {get_param: ps_image_name} + flavor: {get_param: ps_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: ps01_port_0} + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog03}} + user_data_format: RAW + + ps01_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + server_ps02: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [ps_server_names, 1]} + image: {get_param: ps_image_name} + flavor: {get_param: ps_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: ps02_port_0} + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog03}} + user_data_format: RAW + + ps02_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + server_ps03: + type: OS::Nova::Server + properties: + name: {get_param: [ps_server_names, 2]} + image: {get_param: ps_image_name} + flavor: {get_param: ps_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: ps03_port_0} + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog03}} + user_data_format: RAW + + ps03_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + server_ps04: + type: OS::Nova::Server + properties: + name: {get_param: [ps_server_names, 3]} + image: {get_param: ps_image_name} + flavor: {get_param: ps_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: ps04_port_0} + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog03}} + user_data_format: RAW + + ps04_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + server_cm01: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [cm_server_names, 0]} + image: {get_param: cm_image_name} + flavor: {get_param: cm_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: cm01_port_0} + - port: {get_resource: cm01_port_1} +# block_device_mapping: +# - device_name: vdd +# volume_id: { get_param: cluster-manager-vol-2 } +# - device_name: vde +# volume_id: { get_param: cluster-manager-vol-1 } + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog03}} + user_data_format: RAW + + cm01_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + fixed_ips: [{"ip_address": {get_param: [csb_net_ips, 10]}}] + security_groups: [{get_resource: mog_security_group}] + + cm01_port_1: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [oam_net_ips, 4]}}] + security_groups: [{get_resource: mog_security_group}] + diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/withNetwork/network.yml b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/withNetwork/network.yml new file mode 100644 index 0000000000..f069d4dd23 --- /dev/null +++ b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/withNetwork/network.yml @@ -0,0 +1,733 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates MOG stack + +parameters: + pd_server_names: + type: comma_delimited_list + label: PD server names + description: name of the PD instance + pd_image_name: + type: string + label: image name + description: PD image name + pd_flavor_name: + type: string + label: PD flavor name + description: flavor name of PD instance + oam_server_names: + type: comma_delimited_list + label: OAM server names + description: name of the OAM instance + oam_image_name: + type: string + label: image name + description: OAM image name + oam_flavor_name: + type: string + label: OAM flavor name + description: flavor name of OAM instance + sm_server_names: + type: comma_delimited_list + label: SM server names + description: name of the SM instance + sm_image_name: + type: string + label: image name + description: SM image name + sm_flavor_name: + type: string + label: SM flavor name + description: flavor name of SM instance + ps_server_names: + type: comma_delimited_list + label: PS server names + description: name of the PS instance + ps_image_name: + type: string + label: PS image name + description: PS image name + ps_flavor_name: + type: string + label: PS flavor name + description: flavor name of PS instance + cm_server_names: + type: comma_delimited_list + label: CM server names + description: name of the CM instance + cm_image_name: + type: string + label: image name + description: CM image name + cm_flavor_name: + type: string + label: CM flavor name + description: flavor name of CM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + oam_net_name: + type: string + label: oam network name + description: name of the oam network + oam_net_ips: + type: comma_delimited_list + label: internet network ips + description: ip of the OAM network + # internet_net_name: + # type: string + # label: internet network name + # description: id of the internet network + # internet_net_ips: + # type: comma_delimited_list + # label: internet network ips + # description: ip of the internet network + # internet_net_floating_ip: + # type: string + # label: mog internet virtual ip + # description: mog internet virtual ip + sl_net_name: + type: string + label: silver lining network name + description: id of the sl network + sl_net_ips: + type: comma_delimited_list + label: silver lining network ips + description: ips of the sl network + sl_net_floating_ip: + type: string + label: mog sl net virtual ip + description: mog sl net virtual ip + repl_net_name: + type: string + label: Replication network name + description: name of the replication network + repl_net_ips: + type: comma_delimited_list + label: repl network ips + description: ips of repl network + rx_net_name: + type: string + label: Rx network name + description: Rx network name + rx_net_ips: + type: comma_delimited_list + label: Rx network ips + description: Rx network ips + rx_net_floating_ip: + type: string + label: mog rx net virtual ip + description: mog rx net virtual ip + ran_net_name: + type: string + label: RAN network name + description: RAN network name + ran_net_ips: + type: comma_delimited_list + label: RAN network ips + description: RAN network ip + ran_net_floating_ip: + type: string + label: mog ran net virtual ip + description: mog ran net virtual ip + csb_net_name: + type: string + label: csb internal network name + description: csb internal network name + csb_net_start: + type: string + label: csb internal start + description: csb internal start + csb_net_end: + type: string + label: csb internal end + description: csb internal end + csb_net_cidr: + type: string + label: csb ineternal cidr + description: csb internal cidr + csb_net_netmask: + type: string + description: CSB internal network subnet mask + csb_net_ips: + type: comma_delimited_list + description: mog_csb_net IP addresses + dummy_net_name_0: + type: string + label: csb internal network name + description: csb internal network name + dummy_net_start_0: + type: string + label: csb internal start + description: csb internal start + dummy_net_end_0: + type: string + label: csb internal end + description: csb internal end + dummy_net_cidr_0: + type: string + label: csb ineternal cidr + description: csb internal cidr + dummy_net_netmask_0: + type: string + description: CSB internal network subnet mask + dummy_net_name_1: + type: string + label: csb internal network name + description: csb internal network name + dummy_net_start_1: + type: string + label: csb internal start + description: csb internal start + dummy_net_end_1: + type: string + label: csb internal end + description: csb internal end + dummy_net_cidr_1: + type: string + label: csb ineternal cidr + description: csb internal cidr + dummy_net_netmask_1: + type: string + description: CSB internal network subnet mask + + security_group_name: + type: string + label: security group name + description: the name of security group + cluster-manager-vol-1: + type: string + label: mog-cm-vol-1 + description: Cluster Manager volume 1 + session-manager-vol-1: + type: string + label: mog-sm-vol-1 + description: Session Manager volume 1 + session-manager-vol-2: + type: string + label: mog-sm-vol-2 + description: Session Manager volume 2 + oam-vol-1: + type: string + label: mog-oam-vol-1 + description: OAM volume 1 + oam-vol-2: + type: string + label: mog-oam-vol-2 + description: OAM volume 2 + mog_swift_container: + type: string + label: mog Config URL + description: Config URL + mog_script_dir: + type: string + label: mog Config script directory + description: Config script directory + mog_script_name: + type: string + label: mog Config script name + description: Config script name + mog_parameter_name: + type: string + label: mog script parameter name + description: Config script parameter csv file name + cluster-manager-vol-2: + type: string + label: mog-cm-vol-2 + description: Cluster Manager volume 2 with ISO image + +resources: + mog_security_group: + type: OS::Neutron::SecurityGroup + properties: + description: mog security group + name: {get_param: security_group_name} + rules: [{"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0} + ] + + csb_net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: csb_net_name} + + csb_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: csb_net_name} + network_id: { get_resource: csb_net } + cidr: { get_param: csb_net_cidr } + allocation_pools: [{"start": {get_param: csb_net_start}, "end": {get_param: csb_net_end}}] + enable_dhcp: true + + dummy_net_0: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: dummy_net_name_0} + + dummy_ip_subnet_0: + type: OS::Neutron::Subnet + properties: + name: {get_param: dummy_net_name_0} + network_id: { get_resource: dummy_net_0 } + cidr: { get_param: dummy_net_cidr_0 } + allocation_pools: [{"start": {get_param: dummy_net_start_0}, "end": {get_param: dummy_net_end_0}}] + enable_dhcp: true + + dummy_net_1: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: dummy_net_name_1} + + dummy_ip_subnet_1: + type: OS::Neutron::Subnet + properties: + name: {get_param: dummy_net_name_1} + network_id: { get_resource: dummy_net_1 } + cidr: { get_param: dummy_net_cidr_1 } + allocation_pools: [{"start": {get_param: dummy_net_start_1}, "end": {get_param: dummy_net_end_1}}] + enable_dhcp: true + + + mogconfig: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + template: | + #!/bin/bash + wget -P script_dir swift_container/script_name + wget -P script_dir swift_container/parameter_name + chmod 755 script_dir/script_name + script_dir/script_name + params: + swift_container: {get_param: mog_swift_container} + script_dir: {get_param: mog_script_dir} + script_name: {get_param: mog_script_name} + #parameter_name: {get_param: mog_parameter_name} + + + servergroup_mog01: + type: OS::Nova::ServerGroup + properties: + policies: + - anti-affinity + server_pd_01: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [pd_server_names, 0]} + image: {get_param: pd_image_name} + flavor: {get_param: pd_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: pd01_port_0} + - port: {get_resource: pd01_port_1} + - port: {get_resource: pd01_port_2} + - port: {get_resource: pd01_port_3} + - port: {get_resource: pd01_port_4} + - port: {get_resource: pd01_port_5} + - port: {get_resource: pd01_port_6} + # - port: {get_resource: pd01_port_7} + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog01}} + user_data_format: RAW + + + pd01_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + pd01_port_1: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [oam_net_ips, 0]}}] + security_groups: [{get_resource: mog_security_group}] + pd01_port_2: + type: OS::Neutron::Port + properties: + network: {get_resource: dummy_net_0} + security_groups: [{get_resource: mog_security_group}] + pd01_port_3: + type: OS::Neutron::Port + properties: + network: {get_param: rx_net_name} + fixed_ips: [{"ip_address": {get_param: [rx_net_ips, 0]}}] + allowed_address_pairs: [{"ip_address": {get_param: rx_net_floating_ip} }] + security_groups: [{get_resource: mog_security_group}] + pd01_port_4: + type: OS::Neutron::Port + properties: + network: {get_resource: dummy_net_1} + security_groups: [{get_resource: mog_security_group}] + pd01_port_5: + type: OS::Neutron::Port + properties: + network: {get_param: ran_net_name} + fixed_ips: [{"ip_address": {get_param: [ran_net_ips, 0]}}] + allowed_address_pairs: [{"ip_address": {get_param: ran_net_floating_ip} }] + security_groups: [{get_resource: mog_security_group}] + + pd01_port_6: + type: OS::Neutron::Port + properties: + network: {get_param: sl_net_name} + fixed_ips: [{"ip_address": {get_param: [sl_net_ips, 0]}}] + allowed_address_pairs: [{"ip_address": {get_param: sl_net_floating_ip}}] + security_groups: [{get_resource: mog_security_group}] + + # pd01_port_7: + #j type: OS::Neutron::Port + # properties: + # network: {get_param: internet_net_name} + # fixed_ips: [{"ip_address": {get_param: [internet_net_ips, 0]}}] + # allowed_address_pairs: [{"ip_address": {get_param: internet_net_floating_ip} }] + # security_groups: [{get_resource: mog_security_group}] + + server_pd_02: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [pd_server_names, 1]} + image: {get_param: pd_image_name} + flavor: {get_param: pd_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: pd02_port_0} + - port: {get_resource: pd02_port_1} + - port: {get_resource: pd01_port_2} + - port: {get_resource: pd01_port_3} + - port: {get_resource: pd02_port_4} + - port: {get_resource: pd02_port_5} + - port: {get_resource: pd02_port_6} + # - port: {get_resource: pd02_port_7} + + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog01}} + user_data_format: RAW + + pd02_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + pd02_port_1: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [oam_net_ips, 1]}}] + security_groups: [{get_resource: mog_security_group}] + + pd02_port_2: + type: OS::Neutron::Port + properties: + network: {get_resource: dummy_net_0} + security_groups: [{get_resource: mog_security_group}] + + pd02_port_3: + type: OS::Neutron::Port + properties: + network: {get_param: rx_net_name} + fixed_ips: [{"ip_address": {get_param: [rx_net_ips, 1]}}] + allowed_address_pairs: [{"ip_address": {get_param: rx_net_floating_ip} }] + security_groups: [{get_resource: mog_security_group}] + + pd02_port_4: + type: OS::Neutron::Port + properties: + network: {get_resource: dummy_net_1} + security_groups: [{get_resource: mog_security_group}] + + pd02_port_5: + type: OS::Neutron::Port + properties: + network: {get_param: ran_net_name} + fixed_ips: [{"ip_address": {get_param: [ran_net_ips, 1]}}] + allowed_address_pairs: [{"ip_address": {get_param: ran_net_floating_ip} }] + security_groups: [{get_resource: mog_security_group}] + + pd02_port_6: + type: OS::Neutron::Port + properties: + network: {get_param: sl_net_name} + fixed_ips: [{"ip_address": {get_param: [sl_net_ips, 1]}}] + allowed_address_pairs: [{"ip_address": {get_param: sl_net_floating_ip}}] + security_groups: [{get_resource: mog_security_group}] + + # pd02_port_7: + # type: OS::Neutron::Port + # properties: + # network: {get_param: internet_net_name} + # fixed_ips: [{"ip_address": {get_param: [internet_net_ips, 1]}}] + # allowed_address_pairs: [{"ip_address": {get_param: internet_net_floating_ip} }] + # security_groups: [{get_resource: mog_security_group}] + + servergroup_mog02: + type: OS::Nova::ServerGroup + properties: + policies: + - anti-affinity + server_oam01: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [oam_server_names, 0]} + image: {get_param: oam_image_name} + flavor: {get_param: oam_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: oam01_port_0} + - port: {get_resource: oam01_port_1} +# block_device_mapping: +# - device_name: vdd +# volume_id: { get_param: oam-vol-1 } + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog02}} + user_data_format: RAW + + oam01_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + oam01_port_1: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [oam_net_ips, 2]}}] + security_groups: [{get_resource: mog_security_group}] + + + server_oam02: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [oam_server_names, 1]} + image: {get_param: oam_image_name} + flavor: {get_param: oam_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: oam02_port_0} + - port: {get_resource: oam02_port_1} +# block_device_mapping: +# - device_name: vdd +# volume_id: { get_param: oam-vol-2 } + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog02}} + user_data_format: RAW + + oam02_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + oam02_port_1: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [oam_net_ips, 3]}}] + security_groups: [{get_resource: mog_security_group}] + + + server_sm01: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [sm_server_names, 0]} + image: {get_param: sm_image_name} + flavor: {get_param: sm_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: sm01_port_0} + - port: {get_resource: sm01_port_1} +# block_device_mapping: +# - device_name: vdd +# volume_id: { get_param: session-manager-vol-1 } + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog02}} + user_data_format: RAW + + sm01_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + sm01_port_1: + type: OS::Neutron::Port + properties: + network: {get_resource: dummy_net_0} + security_groups: [{get_resource: mog_security_group}] + + sm01_port_2: + type: OS::Neutron::Port + properties: + network: {get_param: repl_net_name} + fixed_ips: [{"ip_address": {get_param: [repl_net_ips, 0]}}] + security_groups: [{get_resource: mog_security_group}] + + server_sm02: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [sm_server_names, 1]} + image: {get_param: sm_image_name} + flavor: {get_param: sm_flavor_name} + availability_zone: {get_param: availabilityzone_name} +# block_device_mapping: +# - device_name: vdd +# volume_id: { get_param: session-manager-vol-2 } + networks: + - port: {get_resource: sm02_port_0} + - port: {get_resource: sm02_port_1} + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog02}} + user_data_format: RAW + + sm02_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + sm02_port_1: + type: OS::Neutron::Port + properties: + network: {get_resource: dummy_net_0} + security_groups: [{get_resource: mog_security_group}] + + sm02_port_2: + type: OS::Neutron::Port + properties: + network: {get_param: repl_net_name} + fixed_ips: [{"ip_address": {get_param: [repl_net_ips, 1]}}] + security_groups: [{get_resource: mog_security_group}] + + servergroup_mog03: + type: OS::Nova::ServerGroup + properties: + policies: + - anti-affinity + server_ps01: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [ps_server_names, 0]} + image: {get_param: ps_image_name} + flavor: {get_param: ps_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: ps01_port_0} + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog03}} + user_data_format: RAW + + ps01_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + server_ps02: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [ps_server_names, 1]} + image: {get_param: ps_image_name} + flavor: {get_param: ps_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: ps02_port_0} + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog03}} + user_data_format: RAW + + ps02_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + server_ps03: + type: OS::Nova::Server + properties: + name: {get_param: [ps_server_names, 2]} + image: {get_param: ps_image_name} + flavor: {get_param: ps_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: ps03_port_0} + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog03}} + user_data_format: RAW + + ps03_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + server_ps04: + type: OS::Nova::Server + properties: + name: {get_param: [ps_server_names, 3]} + image: {get_param: ps_image_name} + flavor: {get_param: ps_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: ps04_port_0} + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog03}} + user_data_format: RAW + + ps04_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + server_cm01: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [cm_server_names, 0]} + image: {get_param: cm_image_name} + flavor: {get_param: cm_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: cm01_port_0} + - port: {get_resource: cm01_port_1} +# block_device_mapping: +# - device_name: vdd +# volume_id: { get_param: cluster-manager-vol-2 } +# - device_name: vde +# volume_id: { get_param: cluster-manager-vol-1 } + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog03}} + user_data_format: RAW + + cm01_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + fixed_ips: [{"ip_address": {get_param: [csb_net_ips, 10]}}] + security_groups: [{get_resource: mog_security_group}] + + cm01_port_1: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [oam_net_ips, 4]}}] + security_groups: [{get_resource: mog_security_group}] + diff --git a/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/withNetwork/zip/withNetwork.zip b/openecomp-be/backend/openecomp-sdc-vendor-software-product-manager/src/test/resources/withNetwork/zip/withNetwork.zip new file mode 100644 index 0000000000000000000000000000000000000000..7cd81437d3a76f452366a3521a1021bf25edcf12 GIT binary patch literal 6442 zcmeI1XHZk!+J-|wX-X3mDbj)v5TrA!H*&s#5q(p_`2(R)t9q3dU#?VFeWm%Qc z{Bmr-h#1Pe%!v=P_(pD1yP28*n4hSd($A06MY)yQ#592*+y zI_bKTstbSDJY;XFel9rmc;WEb2JQUj*EuO2nv5x19qcv*`*I(Y-Ngz!r6}Wjc(lb8 zckNoAW-b9PKaX6fwaZr+6*kX568+x4ZGC=?$KwVx+iSmN#4g0wJK6B??BSuzE|eyD z?v&I!^OcPb*fTE32KTD47`nEKyh}^`yM_3qXBV@PGg<8r!qdbtclMU{m{om;4K$m- z+iCnG9;;lIYV1k0n6T(?DG}5XbklH~z85XepdZ74O(Pr=QQZqRlC)Jj8GS%Ki0hnF z(|mnWfliK;@{RA(+vgA9c%{>_KP( zpi)1nvt^~mMOKGCmRC}f#$sGz6%`Lw2oG-tJgs4IC+jcwk8w#0+n~5I5tLhxw_u`K zHyiikATva{x!W{cY=@^;Y<7aXpTWZDLl0}@)ROqqsZvY^UGg}&gZ;YpT0@YABY2(d zO?l&`fdNCx$=>Ai3YAU)USjQ)QURNRu-Q>wZLhW{)udIutqw1~xE8OrK-feh0fEm7 zlc`o7V1jyKWUKK(%8@vnsC)CkRdM@OS=;r<5OEq*iAVE{iw+0*{c*wLC~KilQwF+!dB zWqJdB!sd-ezcAj(w6^vAm854pj<>IufD%BRrg(uwH-QVbZ(qha*9L`Hj+G4?7m2{~ zjK|Vij_pj7;Ii7#&XbGeFu>OWx#Thp%c6bJxR2j92v)&+t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pZ;T4 zp6dT6kN}tg(-0OKVskG^59{x$ul>8xuc&tg@T*bG*)hO>YyY1?;IBrTj{hoTvE>V1F$Rc>SNX|IF}H^|jBP|M#mV QJG-LKa6k0lM + + 4.0.0 + + + openecomp-sdc + org.openecomp.sdc + 1.0.0-SNAPSHOT + + + org.openecomp.sdc + backend + pom + + + openecomp-sdc-vendor-license-manager + openecomp-sdc-vendor-software-product-manager + openecomp-sdc-validation-manager + openecomp-sdc-action-manager + openecomp-sdc-application-config-manager + + + + diff --git a/openecomp-be/configuration/pom.xml b/openecomp-be/configuration/pom.xml new file mode 100644 index 0000000000..59d5712d61 --- /dev/null +++ b/openecomp-be/configuration/pom.xml @@ -0,0 +1,15 @@ + + 4.0.0 + + + org.openecomp.sdc + openecomp-sdc + 1.0.0-SNAPSHOT + + + openecomp-sdc-configuration + openecomp-sdc-configuration + pom + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-common-lib/pom.xml b/openecomp-be/lib/openecomp-common-lib/pom.xml new file mode 100644 index 0000000000..78c5e86ec7 --- /dev/null +++ b/openecomp-be/lib/openecomp-common-lib/pom.xml @@ -0,0 +1,46 @@ + + 4.0.0 + + + openecomp-sdc-lib + org.openecomp.sdc + 1.0.0-SNAPSHOT + + + openecomp-common-lib + org.openecomp.core + openecomp-common-lib + + + + org.openecomp.core + openecomp-utilities-lib + 1.0.0-SNAPSHOT + + + + org.openecomp.sdc + openecomp-sdc-datatypes-lib + 1.0.0-SNAPSHOT + + + javax.ws.rs + javax.ws.rs-api + ${ws.rs.version} + + + ch.qos.logback + logback-classic + 1.1.2 + + + ch.qos.logback + logback-classic + 1.1.2 + + + + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/errors/BaseErrorBuilder.java b/openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/errors/BaseErrorBuilder.java new file mode 100644 index 0000000000..367cbf7df6 --- /dev/null +++ b/openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/errors/BaseErrorBuilder.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.common.errors; + +public abstract class BaseErrorBuilder { + private final ErrorCode.ErrorCodeBuilder builder = new ErrorCode.ErrorCodeBuilder(); + + public ErrorCode build() { + return builder.build(); + } + + protected ErrorCode.ErrorCodeBuilder getErrorCodeBuilder() { + return builder; + } +} diff --git a/openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/errors/CoreException.java b/openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/errors/CoreException.java new file mode 100644 index 0000000000..3b464ca107 --- /dev/null +++ b/openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/errors/CoreException.java @@ -0,0 +1,39 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.common.errors; + +public class CoreException extends RuntimeException { + + private ErrorCode errorCode; + + public CoreException(ErrorCode errorCode) { + this(errorCode, null); + } + + public CoreException(ErrorCode errorCode, Throwable cause) { + super(errorCode.toString(), cause); + this.errorCode = errorCode; + } + + public ErrorCode code() { + return errorCode; + } +} diff --git a/openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/errors/ErrorCategory.java b/openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/errors/ErrorCategory.java new file mode 100644 index 0000000000..d24ee62124 --- /dev/null +++ b/openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/errors/ErrorCategory.java @@ -0,0 +1,64 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.common.errors; + +public enum ErrorCategory { + /** + * System-level problems caused by external factors, resources shortage and similar. For instance: + *

    + *
  • I/O problems (network connectivity, filesystem access etc)
  • + *
  • Java issues (missing or incompatible class definitions etc)
  • + *
  • Environment problems
  • + *
+ */ + SYSTEM, + + /** + * Application-level issues related to implementation of certain functionality (such as detected + * illegal states of a program or data inconsistency). + */ + APPLICATION, + + /** + * Problems related to violations of different rules set either by product metadata (catalog + * definitions or similar) or other types of constraints. + */ + VALIDATION, + + /** + * Problems caused by attempt of a user to perform certain operations which contradict the + * system rules. Mostly applicable to UI-driven flows in presentation tier. + */ + USER, + + /** + * Improper values set in the system configuration (negative numbers, missing or inconsistent + * definitions, mismatch with valid values list etc). + * */ + CONFIGURATION, + + /** + * Security constraint violations (failed login attempts, lack of permissions to perform + * operation and so on). Any problems related to authentication/authorization should use the + * special category for system auditing purposes. + */ + SECURITY +} diff --git a/openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/errors/ErrorCode.java b/openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/errors/ErrorCode.java new file mode 100644 index 0000000000..aa0b123d4a --- /dev/null +++ b/openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/errors/ErrorCode.java @@ -0,0 +1,105 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.common.errors; + +import java.io.Serializable; + +public class ErrorCode implements Serializable { + + private static final long serialVersionUID = 1L; + + private String id; + private String message; + private ErrorCategory category; + + protected ErrorCode() { + } + + public String id() { + return id; + } + + @Deprecated + protected void id(String id) { + this.id = id; + } + + public String message() { + return message; + } + + @Deprecated + protected void message(String message) { + this.message = message; + } + + public ErrorCategory category() { + return category; + } + + @Deprecated + protected void category(ErrorCategory category) { + this.category = category; + } + + @Override + public String toString() { + return message; + } + + public static class ErrorCodeBuilder { + + private String id; + private String message; + private ErrorCategory category = ErrorCategory.APPLICATION; + + public ErrorCodeBuilder withId(String id) { + this.id = id; + return this; + } + + //todo remove later + + public ErrorCodeBuilder withMessage(String message) { + this.message = message; + return this; + } + + //todo remove later + public ErrorCodeBuilder withCategory(ErrorCategory category) { + this.category = category; + return this; + } + + /** + * Build error code. + * + * @return the error code + */ + public ErrorCode build() { + ErrorCode inst = new ErrorCode(); + inst.id = id; + inst.message = message; + inst.category = category; + return inst; + } + } +} diff --git a/openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/errors/ErrorCodeAndMessage.java b/openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/errors/ErrorCodeAndMessage.java new file mode 100644 index 0000000000..672397f53c --- /dev/null +++ b/openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/errors/ErrorCodeAndMessage.java @@ -0,0 +1,88 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.common.errors; + + +import javax.ws.rs.core.Response; + +/** + * This class represents an error object to be returned in failed REST instead of just returning one + * of HTTP fail statuses. + * + */ +public class ErrorCodeAndMessage { + + /** + * the HTTP status code. + */ + private Response.Status status; + + /** + * Error code no. if available. + */ + private String errorCode; + + /** + * the error message to be displayed. + */ + private String message; + + public ErrorCodeAndMessage() { + } + + /** + * Instantiates a new Error code and message. + * + * @param status the status + * @param errorCode the error code + */ + public ErrorCodeAndMessage(Response.Status status, ErrorCode errorCode) { + this.status = status; + this.message = errorCode.message(); + this.errorCode = errorCode.id(); + } + + + public Response.Status getStatus() { + return status; + } + + public void setStatus(Response.Status status) { + this.status = status; + } + + public String getErrorCode() { + return errorCode; + } + + public void setErrorCode(String errorCode) { + this.errorCode = errorCode; + } + + public String getMessage() { + return message; + } + + public void setMessage(String message) { + this.message = message; + } + +} diff --git a/openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/errors/GeneralErrorBuilder.java b/openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/errors/GeneralErrorBuilder.java new file mode 100644 index 0000000000..155d020396 --- /dev/null +++ b/openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/errors/GeneralErrorBuilder.java @@ -0,0 +1,53 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.common.errors; + +/** + * The type General error builder. + */ +public class GeneralErrorBuilder { + + private static final String GENERAL_ERROR_REST_ID = "GENERAL_ERROR_REST_ID"; + private static final String GENERAL_ERROR_REST_MSG = "An error has occurred: %s"; + + private final ErrorCode.ErrorCodeBuilder builder = new ErrorCode.ErrorCodeBuilder(); + + /** + * Instantiates a new General error builder. + * + * @param detailedError the detailed error + */ + public GeneralErrorBuilder(String detailedError) { + builder.withId(GENERAL_ERROR_REST_ID); + builder.withCategory(ErrorCategory.APPLICATION); + builder.withMessage(String.format(GENERAL_ERROR_REST_MSG, detailedError)); + } + + /** + * Build error code. + * + * @return the error code + */ + public ErrorCode build() { + return builder.build(); + } + +} diff --git a/openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/errors/JsonMappingErrorBuilder.java b/openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/errors/JsonMappingErrorBuilder.java new file mode 100644 index 0000000000..2a916dbf90 --- /dev/null +++ b/openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/errors/JsonMappingErrorBuilder.java @@ -0,0 +1,53 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.common.errors; + +/** + * The type Json mapping error builder. + */ +public class JsonMappingErrorBuilder { + + private static final String JSON_MAPPING_ERROR_ERR_ID = "JSON_MAPPING_ERROR_ERR_ID"; + private static final String JSON_MAPPING_ERROR_ERR_ERR_MSG = + "Error occurred while parsing the JSON input/body. Further info can be found in the log"; + + + private final ErrorCode.ErrorCodeBuilder builder = new ErrorCode.ErrorCodeBuilder(); + + /** + * Instantiates a new Json mapping error builder. + */ + public JsonMappingErrorBuilder() { + builder.withId(JSON_MAPPING_ERROR_ERR_ID); + builder.withCategory(ErrorCategory.APPLICATION); + builder.withMessage(String.format(JSON_MAPPING_ERROR_ERR_ERR_MSG)); + } + + /** + * Build error code. + * + * @return the error code + */ + public ErrorCode build() { + return builder.build(); + } + +} diff --git a/openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/errors/ValidationErrorBuilder.java b/openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/errors/ValidationErrorBuilder.java new file mode 100644 index 0000000000..eb60a63a4b --- /dev/null +++ b/openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/errors/ValidationErrorBuilder.java @@ -0,0 +1,68 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.common.errors; + +/** + * The type Validation error builder. + */ +public class ValidationErrorBuilder { + + /** + * The constant FIELD_VALIDATION_ERROR_ERR_ID. + */ + public static final String FIELD_VALIDATION_ERROR_ERR_ID = "FIELD_VALIDATION_ERROR_ERR_ID"; + private static final String FIELD_VALIDATION_ERROR_ERR_MSG = + "Field does not conform to predefined criteria : %s : %s"; + private static final String FIELD_VALIDATION_ERROR_ERR_MSG_USE_PREDEFINED_FOR_FIELD = "%s"; + private static final String FIELD_WITH_PREDEFINED_MESSAGE = "arg\\d"; + + + private final ErrorCode.ErrorCodeBuilder builder = new ErrorCode.ErrorCodeBuilder(); + + /** + * Instantiates a new Validation error builder. + * + * @param detailedMessage the detailed message + * @param fieldName the field name + */ + public ValidationErrorBuilder(String detailedMessage, String fieldName) { + builder.withId(FIELD_VALIDATION_ERROR_ERR_ID); + builder.withCategory(ErrorCategory.APPLICATION); + + if (fieldName.matches(FIELD_WITH_PREDEFINED_MESSAGE)) { + builder.withMessage( + String.format(FIELD_VALIDATION_ERROR_ERR_MSG_USE_PREDEFINED_FOR_FIELD, detailedMessage)); + } else { + builder + .withMessage(String.format(FIELD_VALIDATION_ERROR_ERR_MSG, fieldName, detailedMessage)); + } + } + + /** + * Build error code. + * + * @return the error code + */ + public ErrorCode build() { + return builder.build(); + } + +} diff --git a/openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/utils/AsdcCommon.java b/openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/utils/AsdcCommon.java new file mode 100644 index 0000000000..d3806ff34e --- /dev/null +++ b/openecomp-be/lib/openecomp-common-lib/src/main/java/org/openecomp/sdc/common/utils/AsdcCommon.java @@ -0,0 +1,31 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.common.utils; + +public class AsdcCommon { + + public static final String MANIFEST_NAME = "MANIFEST.json"; + public static final String UPLOAD_FILE = "uploadFile"; + + public static final String HEAT_TO_TOSCA_MAPPING_CONF = "heatToToscaMapping.json"; + public static final String HEAT_META = "HEAT.meta"; + public static final String PARENT = "parent"; +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/pom.xml b/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/pom.xml new file mode 100644 index 0000000000..a10e9cbd04 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/pom.xml @@ -0,0 +1,48 @@ + + + 4.0.0 + + + org.openecomp.core + openecomp-core-lib + 1.0.0-SNAPSHOT + + + openecomp-config-lib + + + + com.google.code.gson + gson + 2.3.1 + test + + + org.yaml + snakeyaml + 1.14 + test + + + org.openecomp.core + openecomp-nosqldb-core + ${project.version} + + + org.testng + testng + 6.9.10 + test + + + org.openecomp.sdc + openecomp-sdc-vendor-software-product-api + ${project.version} + test + + + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/ApplicationConfig.java b/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/ApplicationConfig.java new file mode 100644 index 0000000000..a68c6b614a --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/ApplicationConfig.java @@ -0,0 +1,35 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.utilities.applicationconfig; + +import org.openecomp.core.utilities.applicationconfig.dao.type.ApplicationConfigEntity; +import org.openecomp.core.utilities.applicationconfig.type.ConfigurationData; + +import java.util.Collection; + +public interface ApplicationConfig { + + ConfigurationData getConfigurationData(String namespace, String key); + + void insertValue(String namespace, String key, String value); + + Collection getListOfConfigurationByNamespace(String namespace); +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/ApplicationConfigFactory.java b/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/ApplicationConfigFactory.java new file mode 100644 index 0000000000..e022294dfd --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/ApplicationConfigFactory.java @@ -0,0 +1,31 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.utilities.applicationconfig; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; + +public abstract class ApplicationConfigFactory extends AbstractComponentFactory { + + public static ApplicationConfigFactory getInstance() { + return AbstractFactory.getInstance(ApplicationConfigFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/dao/ApplicationConfigDao.java b/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/dao/ApplicationConfigDao.java new file mode 100644 index 0000000000..a4c582744a --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/dao/ApplicationConfigDao.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.utilities.applicationconfig.dao; + +import org.openecomp.core.dao.BaseDao; +import org.openecomp.core.utilities.applicationconfig.dao.type.ApplicationConfigEntity; +import org.openecomp.core.utilities.applicationconfig.type.ConfigurationData; + + +public interface ApplicationConfigDao extends BaseDao { + + long getValueTimestamp(String namespace, String key); + + ConfigurationData getConfigurationData(String namespace, String key); +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/dao/ApplicationConfigDaoFactory.java b/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/dao/ApplicationConfigDaoFactory.java new file mode 100644 index 0000000000..f60e4a9010 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/dao/ApplicationConfigDaoFactory.java @@ -0,0 +1,32 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.utilities.applicationconfig.dao; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; + +public abstract class ApplicationConfigDaoFactory + extends AbstractComponentFactory { + + public static ApplicationConfigDaoFactory getInstance() { + return AbstractFactory.getInstance(ApplicationConfigDaoFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/dao/impl/ApplicationConfigDaoCassandraImpl.java b/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/dao/impl/ApplicationConfigDaoCassandraImpl.java new file mode 100644 index 0000000000..7fb0e2f5ae --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/dao/impl/ApplicationConfigDaoCassandraImpl.java @@ -0,0 +1,115 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.utilities.applicationconfig.dao.impl; + +import com.datastax.driver.core.ResultSet; +import com.datastax.driver.core.Row; +import com.datastax.driver.mapping.Mapper; +import com.datastax.driver.mapping.Result; +import com.datastax.driver.mapping.annotations.Accessor; +import com.datastax.driver.mapping.annotations.Query; +import org.openecomp.core.dao.impl.CassandraBaseDao; +import org.openecomp.core.nosqldb.api.NoSqlDb; +import org.openecomp.core.nosqldb.factory.NoSqlDbFactory; +import org.openecomp.core.utilities.applicationconfig.dao.ApplicationConfigDao; +import org.openecomp.core.utilities.applicationconfig.dao.type.ApplicationConfigEntity; +import org.openecomp.core.utilities.applicationconfig.type.ConfigurationData; + +import java.util.Collection; +import java.util.Objects; + +public class ApplicationConfigDaoCassandraImpl extends CassandraBaseDao + implements ApplicationConfigDao { + + private static final NoSqlDb noSqlDb = NoSqlDbFactory.getInstance().createInterface(); + private static final Mapper mapper = + noSqlDb.getMappingManager().mapper(ApplicationConfigEntity.class); + private static final ApplicationConfigAccessor accessor = + noSqlDb.getMappingManager().createAccessor(ApplicationConfigAccessor.class); + + @Override + protected Mapper getMapper() { + return mapper; + } + + @Override + protected Object[] getKeys(ApplicationConfigEntity entity) { + return new Object[]{entity.getNamespace(), entity.getKey(), entity.getValue()}; + } + + @Override + public Collection list(ApplicationConfigEntity entity) { + return accessor.list(entity.getNamespace()).all(); + } + + @Override + public void create(ApplicationConfigEntity entity) { + accessor.updateApplicationConfigData(entity.getNamespace(), entity.getKey(), entity.getValue()); + } + + @Override + public void update(ApplicationConfigEntity entity) { + accessor.updateApplicationConfigData(entity.getNamespace(), entity.getKey(), entity.getValue()); + } + + @Override + public ApplicationConfigEntity get(ApplicationConfigEntity entity) { + return accessor.get(entity.getNamespace(), entity.getKey()); + } + + @Override + public long getValueTimestamp(String namespace, String key) { + ResultSet resultSet = accessor.getValueAndTimestampOfConfigurationValue(namespace, key); + + return resultSet.one().getLong("writetime(value)"); + } + + @Override + public ConfigurationData getConfigurationData(String namespace, String key) { + //String value = accessor.getValue(namespace, key).one().getString("value"); + ResultSet resultSet = accessor.getValueAndTimestampOfConfigurationValue(namespace, key); + Row one = resultSet.one(); + + if (Objects.nonNull(one)) { + return new ConfigurationData(one.getString("value"), one.getLong("writetime(value)")); + } + + return null; + } + + + @Accessor + interface ApplicationConfigAccessor { + + @Query("select namespace, key, value from application_config where namespace=?") + Result list(String namespace); + + @Query("insert into application_config (namespace, key, value) values (?,?,?)") + ResultSet updateApplicationConfigData(String namespace, String key, String value); + + @Query("select namespace, key, value from application_config where namespace=? and key=?") + ApplicationConfigEntity get(String namespace, String key); + + @Query("select value, writetime(value) from application_config where namespace=? and key=?") + ResultSet getValueAndTimestampOfConfigurationValue(String namespace, String key); + + } +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/dao/impl/ApplicationConfigDaoFactoryImpl.java b/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/dao/impl/ApplicationConfigDaoFactoryImpl.java new file mode 100644 index 0000000000..cea49ea8d1 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/dao/impl/ApplicationConfigDaoFactoryImpl.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.utilities.applicationconfig.dao.impl; + +import org.openecomp.core.utilities.applicationconfig.dao.ApplicationConfigDao; +import org.openecomp.core.utilities.applicationconfig.dao.ApplicationConfigDaoFactory; + +public class ApplicationConfigDaoFactoryImpl extends ApplicationConfigDaoFactory { + private static final ApplicationConfigDao INSTANCE = new ApplicationConfigDaoCassandraImpl(); + + @Override + public ApplicationConfigDao createInterface() { + return INSTANCE; + } +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/dao/type/ApplicationConfigEntity.java b/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/dao/type/ApplicationConfigEntity.java new file mode 100644 index 0000000000..c73ce36744 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/dao/type/ApplicationConfigEntity.java @@ -0,0 +1,79 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.utilities.applicationconfig.dao.type; + + +import com.datastax.driver.mapping.annotations.ClusteringColumn; +import com.datastax.driver.mapping.annotations.PartitionKey; +import com.datastax.driver.mapping.annotations.Table; + +@Table(keyspace = "dox", name = "application_config") +public class ApplicationConfigEntity { + + @PartitionKey + private String namespace; + @ClusteringColumn + private String key; + private String value; + + /** + * Instantiates a new Application config entity. + * + * @param namespace the namespace + * @param key the key + * @param value the value + */ + public ApplicationConfigEntity(String namespace, String key, String value) { + this.namespace = namespace; + this.key = key; + this.value = value; + } + + + public ApplicationConfigEntity() { + } + + + public String getNamespace() { + return namespace; + } + + public void setNamespace(String namespace) { + this.namespace = namespace; + } + + public String getKey() { + return key; + } + + public void setKey(String key) { + this.key = key; + } + + public String getValue() { + return value; + } + + public void setValue(String value) { + this.value = value; + } + +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/impl/ApplicationConfigFactoryImpl.java b/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/impl/ApplicationConfigFactoryImpl.java new file mode 100644 index 0000000000..cca07fc227 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/impl/ApplicationConfigFactoryImpl.java @@ -0,0 +1,34 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.utilities.applicationconfig.impl; + +import org.openecomp.core.utilities.applicationconfig.ApplicationConfig; +import org.openecomp.core.utilities.applicationconfig.ApplicationConfigFactory; + +public class ApplicationConfigFactoryImpl extends ApplicationConfigFactory { + + private static final ApplicationConfig INSTANCE = new ApplicationConfigImpl(); + + @Override + public ApplicationConfig createInterface() { + return INSTANCE; + } +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/impl/ApplicationConfigImpl.java b/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/impl/ApplicationConfigImpl.java new file mode 100644 index 0000000000..ff9c9aea87 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/impl/ApplicationConfigImpl.java @@ -0,0 +1,74 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.utilities.applicationconfig.impl; + +import org.openecomp.core.utilities.applicationconfig.ApplicationConfig; +import org.openecomp.core.utilities.applicationconfig.dao.ApplicationConfigDao; +import org.openecomp.core.utilities.applicationconfig.dao.ApplicationConfigDaoFactory; +import org.openecomp.core.utilities.applicationconfig.dao.type.ApplicationConfigEntity; +import org.openecomp.core.utilities.applicationconfig.type.ConfigurationData; +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; + +import java.util.Collection; +import java.util.Objects; + +/** + * The type Application config. + */ +public class ApplicationConfigImpl implements ApplicationConfig { + private static final ApplicationConfigDao applicationConfigDao = + ApplicationConfigDaoFactory.getInstance().createInterface(); + + private static final String CONFIGURATION_SEARCH_ERROR = "CONFIGURATION_NOT_FOUND"; + private static final String CONFIGURATION_SEARCH_ERROR_MSG = + "Configuration for namespace %s and key %s was not found"; + + @Override + public ConfigurationData getConfigurationData(String namespace, String key) { + ConfigurationData configurationData = applicationConfigDao.getConfigurationData(namespace, key); + + if (Objects.isNull(configurationData)) { + throw new CoreException(new ErrorCode.ErrorCodeBuilder() + .withCategory(ErrorCategory.APPLICATION) + .withId(CONFIGURATION_SEARCH_ERROR) + .withMessage(String.format(CONFIGURATION_SEARCH_ERROR_MSG, namespace, key)) + .build()); + } + + return configurationData; + } + + @Override + public void insertValue(String namespace, String key, String value) { + ApplicationConfigEntity applicationConfigEntity = + new ApplicationConfigEntity(namespace, key, value); + applicationConfigDao.create(applicationConfigEntity); + } + + @Override + public Collection getListOfConfigurationByNamespace(String namespace) { + ApplicationConfigEntity applicationConfigEntity = + new ApplicationConfigEntity(namespace, null, null); + return applicationConfigDao.list(applicationConfigEntity); + } +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/type/ConfigurationData.java b/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/type/ConfigurationData.java new file mode 100644 index 0000000000..53d3797e53 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/java/org/openecomp/core/utilities/applicationconfig/type/ConfigurationData.java @@ -0,0 +1,48 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.utilities.applicationconfig.type; + +public class ConfigurationData { + + private String value; + private long timeStamp; + + public ConfigurationData(String value, long timeStamp) { + this.value = value; + this.timeStamp = timeStamp; + } + + public String getValue() { + return value; + } + + public void setValue(String value) { + this.value = value; + } + + public long getTimeStamp() { + return timeStamp; + } + + public void setTimeStamp(long timeStamp) { + this.timeStamp = timeStamp; + } +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/resources/factoryConfiguration.json b/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/resources/factoryConfiguration.json new file mode 100644 index 0000000000..19d2cafe8f --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/resources/factoryConfiguration.json @@ -0,0 +1,4 @@ +{ + "org.openecomp.core.utilities.applicationconfig.ApplicationConfigFactory":"org.openecomp.core.utilities.applicationconfig.impl.ApplicationConfigFactoryImpl", + "org.openecomp.core.utilities.applicationconfig.dao.ApplicationConfigDaoFactory":"org.openecomp.core.utilities.applicationconfig.dao.impl.ApplicationConfigDaoFactoryImpl" +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/resources/logback.xml b/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/resources/logback.xml new file mode 100644 index 0000000000..e256e0b10a --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/main/resources/logback.xml @@ -0,0 +1,90 @@ + + + + + + + + + + + + + + + + + + + ${defaultPattern} + + + + + + + + ${logDirectory}/${eventType}.log + + ${logDirectory}/${eventType}.%i.log.zip + 1 + 9 + + + 5MB + + + ${default-log-pattern} + + + + + + + + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/test/java/org/openecomp/sdc/applicationconfig/dao/ApplicationConfigImplDaoTest.java b/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/test/java/org/openecomp/sdc/applicationconfig/dao/ApplicationConfigImplDaoTest.java new file mode 100644 index 0000000000..40cde1ecb2 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/test/java/org/openecomp/sdc/applicationconfig/dao/ApplicationConfigImplDaoTest.java @@ -0,0 +1,88 @@ +package org.openecomp.sdc.applicationconfig.dao; + +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionEntityType; +import org.openecomp.core.utilities.applicationconfig.ApplicationConfig; +import org.openecomp.core.utilities.applicationconfig.ApplicationConfigFactory; +import org.openecomp.core.utilities.applicationconfig.dao.ApplicationConfigDao; +import org.openecomp.core.utilities.applicationconfig.dao.ApplicationConfigDaoFactory; +import org.openecomp.core.utilities.applicationconfig.dao.type.ApplicationConfigEntity; +import org.openecomp.core.utilities.applicationconfig.type.ConfigurationData; +import org.openecomp.core.utilities.file.FileUtils; +import org.testng.Assert; +import org.testng.annotations.BeforeClass; +import org.testng.annotations.Test; + + +public class ApplicationConfigImplDaoTest { + + private static final String SCHEMA_GENERATOR_INITIALIZATION_ERROR = + "SCHEMA_GENERATOR_INITIALIZATION_ERROR"; + private static final String SCHEMA_GENERATOR_INITIALIZATION_ERROR_MSG = + "Error occurred while loading questionnaire schema templates"; + private static ApplicationConfigDao applicationConfigDao = + ApplicationConfigDaoFactory.getInstance().createInterface(); + private static ApplicationConfig applicationConfig = + ApplicationConfigFactory.getInstance().createInterface(); + +// @BeforeClass + public static void init() { + try { + + ApplicationConfigEntity applicationConfigEntity1 = + new ApplicationConfigEntity("test - namespace", "vsp", "vspTemplate"); + ApplicationConfigEntity applicationConfigEntity2 = + new ApplicationConfigEntity("test - namespace", "nic", "nicTemplate"); + ApplicationConfigEntity applicationConfigEntity3 = + new ApplicationConfigEntity("test - namespace", "component", "componentTemplate"); + + applicationConfigDao.create(applicationConfigEntity1); + applicationConfigDao.create(applicationConfigEntity2); + applicationConfigDao.create(applicationConfigEntity3); + + } catch (Exception e) { + throw new CoreException(new ErrorCode.ErrorCodeBuilder(). + withCategory(ErrorCategory.APPLICATION). + withId(SCHEMA_GENERATOR_INITIALIZATION_ERROR). + withMessage(SCHEMA_GENERATOR_INITIALIZATION_ERROR_MSG). + build()); + } + } + + private static String loadFileToString(String path) { + return new String(FileUtils.toByteArray(FileUtils.loadFileToInputStream(path))); + } + +// @Test + public void testApplicationConfigTimestampValue() { + ConfigurationData configurationData = applicationConfig + .getConfigurationData("test - namespace", CompositionEntityType.vsp.name()); + + Assert.assertNotNull(configurationData); + Assert.assertNotEquals(configurationData.getTimeStamp(), 0); + + } + +// @Test(dependsOnMethods = "testApplicationConfigTimestampValue") + public void testNotExistingApplicationConfigTimestampValue() { + try { + applicationConfig.getConfigurationData("test - namespace", "aaa"); + } catch (CoreException ce) { + Assert.assertEquals(ce.getMessage(), + "Configuration for namespace test - namespace and key aaa was not found"); + } + + } + +// @Test(dependsOnMethods = "testApplicationConfigTimestampValue") + public void testInsertApplicationConfiguration() { + String testTemplate = loadFileToString("questionnaire/testTemplate.txt"); + applicationConfig.insertValue("test_namespace", "test_key", testTemplate); + + Assert.assertEquals(testTemplate, + applicationConfig.getConfigurationData("test_namespace", "test_key").getValue()); + } + +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/test/resources/questionnaire/testTemplate.txt b/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/test/resources/questionnaire/testTemplate.txt new file mode 100644 index 0000000000..0bb19c5984 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-config-lib/src/test/resources/questionnaire/testTemplate.txt @@ -0,0 +1,12 @@ +{ + "$schema": "http://json-schema.org/draft-04/schema#", + "type": "object", + "properties": { + "general": { + "type": "object", + "properties": { + "testObject":{ + "type": "string" + } + } +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-api/pom.xml b/openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-api/pom.xml new file mode 100644 index 0000000000..ccb3db833e --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-api/pom.xml @@ -0,0 +1,31 @@ + + 4.0.0 + + + org.openecomp.sdc + openecomp-sdc-lib + 1.0.0-SNAPSHOT + ../../.. + + + openecomp-facade-api + openecomp-facade-api + org.openecomp.core + + + + + + org.openecomp.core + openecomp-utilities-lib + ${project.version} + + + org.openecomp.core + openecomp-common-lib + ${project.version} + + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-api/src/main/java/org/openecomp/core/factory/api/AbstractFactory.java b/openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-api/src/main/java/org/openecomp/core/factory/api/AbstractFactory.java new file mode 100644 index 0000000000..53b8f00fc0 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-api/src/main/java/org/openecomp/core/factory/api/AbstractFactory.java @@ -0,0 +1,81 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.factory.api; + +import org.openecomp.core.factory.impl.AbstractFactoryBase; + +/** + * This class provides generic implementation of an abstract factory. Components exposed as Java + * interfaces should have their own concrete factories derived from the given class. This assures + * code alignment and consistency across all Service Management components. + * The class actually + * uses singleton pattern to instantiate and reuse just one instance of a factory. Therefore, each + * factory implementation has to be thread-safe. + * In a general case, the hierarchy of + * factory objects for an Java interface IUknown may look as follows: + *
+ *                     AbstractFactory<IUnknown>
+ *                                ^
+ *                                |
+ *   Application code ----> ConcreteFactory
+ *                                ^
+ *                                |
+ *                      +---------+---------+
+ *                      |                   |
+ *             BaselineFactoryImpl   CustomFactoryImpl
+ * 
+ * Where the classes responsibility is:
  • Abstract factory - common logic to retrieve the + * implementation class name from a central repository.
  • Concrete factory - abstract class + * that only exposes to application layer the type specific API such as:
    • public static + * ConcreteFactory getInstance()
  • Baseline factory - out of the box + * implementation of concrete factory (that can be replaced by a custom one depending on customer + * needs) which actually implements method:
    • public IUnknown createInterface()
    • + *
The normal concrete factory class may look like: + *
+ * public abstract class ConcreteFactory extends AbstractFactory<IUnknown> {
+ *   static {
+ *     registerFactory(ConcreteFactory.class, BaselineFactoryImpl.class);
+ *   }
+ * public static ConcreteFactory getInstance() {
+ * return AbstractFactory.<IUnknown, ConcreteFactory.class>getInstance(ConcreteFactory.class);
+ *   }
+ * }
+ * 
+ * + * @param Java interface type created by the factory. + */ +public abstract class AbstractFactory extends AbstractFactoryBase { + + + /** + * Returns the interface implementor instance. + * Note: It's up to the concrete factory to decide on the actual + * implementation of the returned interface. Therefore, the call can get the + * same instance per each call in case of singleton implementation or new + * instance otherwise. However, the API consumer may not assume anything + * regarding the underlying logic and has always go through the factory to + * obtain the reference. + * + * @return Implementor of the exposed Java interface. + */ + public abstract I createInterface(); + +} // End of class diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-api/src/main/java/org/openecomp/core/factory/impl/AbstractFactoryBase.java b/openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-api/src/main/java/org/openecomp/core/factory/impl/AbstractFactoryBase.java new file mode 100644 index 0000000000..e19d9e972f --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-api/src/main/java/org/openecomp/core/factory/impl/AbstractFactoryBase.java @@ -0,0 +1,212 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.factory.impl; + +import static org.openecomp.core.utilities.CommonMethods.isEmpty; +import static org.openecomp.core.utilities.CommonMethods.newInstance; + +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; + + +import java.util.Collection; +import java.util.Map; +import java.util.concurrent.ConcurrentHashMap; + +/** + * The type Abstract factory base. + */ +public abstract class AbstractFactoryBase { + + /** + * Temporary registry of default implementations. The map keeps class names rather then class + * types to allow unloading of those classes from memory by garbage collector if + * factory is not actually used. + */ + private static Map registry = new ConcurrentHashMap(); + + /** + * Cached factory instances. + */ + private static Map factoryMap = + new ConcurrentHashMap(); + + /** + * Registers implementor for an abstract factory. The method accepts Java classes rather + * then class names to ensure type safety at compilation time. + * + * @param Java interface type instantiated by abstract factory + * @param Type specific abstract factory for concrete Java interface + * @param factory Java class of a type specific abstract factory + * @param impl Java class of type specific factory implementor + */ + public static void registerFactory(Class factory, + Class impl) { + if (factory == null) { + throw new CoreException( + new ErrorCode.ErrorCodeBuilder().withId("E0001").withMessage("Mandatory input factory.") + .withCategory(ErrorCategory.SYSTEM).build()); + } + + if (impl == null) { + throw new CoreException( + new ErrorCode.ErrorCodeBuilder().withId("E0001").withMessage("Mandatory input impl.") + .withCategory(ErrorCategory.SYSTEM).build()); + } + if (factoryMap != null && factoryMap.containsKey(factory.getName())) { + factoryMap.remove(factory.getName()); + } + registry.put(factory.getName(), impl.getName()); + } // registerFactory + + /** + * Register factory. + * + * @param factoryName the factory name + * @param implName the impl name + */ + // TODO: Remove + protected static void registerFactory(String factoryName, String implName) { + registry.put(factoryName, implName); + } // registerFactory + + /** + * Unregister factory. + * + * @param the type parameter + * @param factory the factory + */ + public static void unregisterFactory(Class factory) { + if (factory == null) { + throw new CoreException( + new ErrorCode.ErrorCodeBuilder().withId("E0001").withMessage("Mandatory input factory.") + .withCategory(ErrorCategory.SYSTEM).build()); + } + if (factoryMap != null) { + factoryMap.remove(factory.getName()); + } + } + + /** + * Instantiates the configured implementation of an abstract factory. + * + * @param Java interface type instantiated by abstract factory + * @param Type specific abstract factory for concrete Java interface + * @param factoryType Java class of type specific abstract factory + * @return Instance of implementation class + */ + @SuppressWarnings("unchecked") + public static F getInstance(Class factoryType) { + if (factoryType == null) { + throw new CoreException( + new ErrorCode.ErrorCodeBuilder().withId("E0001") + .withMessage("Mandatory input factory type.").withCategory(ErrorCategory.SYSTEM) + .build()); + + } + // Pick up factory instance from cache + F factory = (F) factoryMap.get(factoryType.getName()); + // Check for the first time access + if (factory == null) { + // Synchronize factory instantiation + synchronized (factoryType) { + // Re-check the factory instance + factory = (F) factoryMap.get(factoryType.getName()); + if (factory == null) { + // Get the implementation class name + String implName = registry.get(factoryType.getName()); + + if (isEmpty(implName)) { + throw new CoreException( + new ErrorCode.ErrorCodeBuilder().withId("E0001") + .withMessage("Mandatory input factory implementation.") + .withCategory(ErrorCategory.SYSTEM).build()); + } + + factory = newInstance(implName, factoryType); + + factory.init(); + + // Cache the instantiated singleton + factoryMap.put(factoryType.getName(), factory); + } + } + } + + return factory; + + } // getInstance + + + /** + * Is factory registered boolean. + * + * @param the type parameter + * @param factoryType the factory type + * @return the boolean + */ + public static boolean isFactoryRegistered(Class factoryType) { + boolean isFactoryRegistered = false; + if (factoryType == null) { + throw new CoreException( + new ErrorCode.ErrorCodeBuilder().withId("E0001") + .withMessage("Mandatory input factory type.").withCategory(ErrorCategory.SYSTEM) + .build()); + } + // Pick up factory instance from cache + F factory = (F) factoryMap.get(factoryType.getName()); + // Check for the first time access + if (factory != null) { + isFactoryRegistered = true; + } else { + // Get the implementation class name + String implName = registry.get(factoryType.getName()); + if (!isEmpty(implName)) { + isFactoryRegistered = true; + } + } + return isFactoryRegistered; + } + + /** + * Stop all. + */ + public static void stopAll() { + Collection factorylist = factoryMap.values(); + for (AbstractFactoryBase factory : factorylist) { + factory.stop(); + } + } + + /** + * Init. + */ + protected void init() { + } + + /** + * Stop. + */ + protected void stop() { + } + +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-core/pom.xml b/openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-core/pom.xml new file mode 100644 index 0000000000..0c5d36abcc --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-core/pom.xml @@ -0,0 +1,36 @@ + + 4.0.0 + + + openecomp-sdc-lib + org.openecomp.sdc + 1.0.0-SNAPSHOT + ../../.. + + + openecomp-facade-core + openecomp-facade-core + org.openecomp.core + + + + org.openecomp.core + openecomp-utilities-lib + ${project.version} + + + org.openecomp.core + openecomp-common-lib + ${project.version} + + + org.openecomp.core + openecomp-facade-api + ${project.version} + + + + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-core/src/main/java/org/openecomp/core/factory/AbstractContextFactory.java b/openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-core/src/main/java/org/openecomp/core/factory/AbstractContextFactory.java new file mode 100644 index 0000000000..f4e1a85fee --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-core/src/main/java/org/openecomp/core/factory/AbstractContextFactory.java @@ -0,0 +1,27 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.factory; + +import org.openecomp.core.factory.impl.AbstractFactoryBase; + +public abstract class AbstractContextFactory extends AbstractFactoryBase { + public abstract I createInterface(C contextType); +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-core/src/main/java/org/openecomp/core/factory/FactoriesConfigImpl.java b/openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-core/src/main/java/org/openecomp/core/factory/FactoriesConfigImpl.java new file mode 100644 index 0000000000..173f9b15b1 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-core/src/main/java/org/openecomp/core/factory/FactoriesConfigImpl.java @@ -0,0 +1,61 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.factory; + + +import org.openecomp.core.factory.api.FactoriesConfiguration; +import org.openecomp.core.utilities.file.FileUtils; +import org.openecomp.core.utilities.json.JsonUtil; + +import java.io.InputStream; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +public final class FactoriesConfigImpl implements FactoriesConfiguration { + + + private static final String FACTORY_CONFIG_FILE_NAME = "factoryConfiguration.json"; + private static Map factoryMap = new HashMap(); + private static boolean initialized = false; + + @SuppressWarnings("unchecked") + @Override + public Map getFactoriesMap() { + synchronized (this) { + if (!initialized) { + init(); + initialized = true; + } + } + return factoryMap; + } + + private void init() { + List factoryConfigIsList = FileUtils.getFileInputStreams(FACTORY_CONFIG_FILE_NAME); + for (InputStream factoryConfigIs : factoryConfigIsList) { + factoryMap.putAll(JsonUtil.json2Object(factoryConfigIs, Map.class)); + } + } + + +} + diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-core/src/main/java/org/openecomp/core/factory/FactoryConfig.java b/openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-core/src/main/java/org/openecomp/core/factory/FactoryConfig.java new file mode 100644 index 0000000000..d664cbee38 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-core/src/main/java/org/openecomp/core/factory/FactoryConfig.java @@ -0,0 +1,46 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.factory; + +import org.openecomp.core.factory.api.FactoriesConfiguration; +import org.openecomp.core.utilities.CommonMethods; + +import java.util.Map; + +public final class FactoryConfig { + + private static final FactoriesConfiguration INSTANCE; + + static { + + try { + INSTANCE = CommonMethods.newInstance( + "org.openecomp.core.factory.FactoriesConfigImpl", FactoriesConfiguration.class); + } catch (Exception exception) { + exception.printStackTrace(); + throw exception; + } + } + + public static Map getFactoriesMap() { + return INSTANCE.getFactoriesMap(); + } +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-core/src/main/java/org/openecomp/core/factory/api/AbstractComponentFactory.java b/openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-core/src/main/java/org/openecomp/core/factory/api/AbstractComponentFactory.java new file mode 100644 index 0000000000..9cd7749f55 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-core/src/main/java/org/openecomp/core/factory/api/AbstractComponentFactory.java @@ -0,0 +1,105 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.factory.api; + +import org.openecomp.core.factory.FactoryConfig; +import org.openecomp.core.factory.impl.AbstractFactoryBase; +import org.openecomp.core.utilities.CommonMethods; +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; + +import java.util.Map; + +public abstract class AbstractComponentFactory extends AbstractFactory { + + static { + Registry registry = new RegistryImpl(); + InitializationHelper.registerFactoryMapping(registry); + } + + interface Registry { + void register(String factory, String impl); + } + + private static class RegistryImpl implements Registry { + @Override + public void register(String factory, String impl) { + AbstractFactoryBase.registerFactory(factory, impl); + } + } + + static class InitializationHelper { + + + private static boolean isRegistered = false; + + private InitializationHelper() { + } + + static synchronized boolean registerFactoryMapping(Registry registry) { + + boolean done = !isRegistered; + + if (!isRegistered) { + registerFactoryMappingImpl(registry); + isRegistered = true; + } + + return done; + } + + private static void registerFactoryMappingImpl(Registry registry) { + Map factoryMap = FactoryConfig.getFactoriesMap(); + + try { + for (Map.Entry entry : factoryMap.entrySet()) { + String abstractClassName = entry.getKey(); + String concreteTypeName = entry.getValue(); + + if (CommonMethods.isEmpty(concreteTypeName)) { + throw new CoreException( + new ErrorCode.ErrorCodeBuilder().withId("E0003") + .withMessage("Missing configuration value:" + concreteTypeName + ".") + .withCategory(ErrorCategory.SYSTEM).build()); + + } + + registry.register(abstractClassName, concreteTypeName); + } + } catch (RuntimeException exception) { + throw exception; + } catch (Exception exception) { + throw new RuntimeException(exception); + } + } + + @SuppressWarnings("unchecked") + private static Class unsecureCast(Class cls) { + return (Class) cls; + } + + private static String nameOf(Class clazz) { + return (clazz != null) ? clazz.getName() : "null"; + } + } + +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-core/src/main/java/org/openecomp/core/factory/api/FactoriesConfiguration.java b/openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-core/src/main/java/org/openecomp/core/factory/api/FactoriesConfiguration.java new file mode 100644 index 0000000000..8086181204 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/openecomp-facade-core/src/main/java/org/openecomp/core/factory/api/FactoriesConfiguration.java @@ -0,0 +1,29 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.factory.api; + +import java.util.Map; + + +public interface FactoriesConfiguration { + + Map getFactoriesMap(); +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/pom.xml b/openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/pom.xml new file mode 100644 index 0000000000..29e9cce688 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-facade-lib/pom.xml @@ -0,0 +1,34 @@ + + 4.0.0 + + + openecomp-core-lib + org.openecomp.core + 1.0.0-SNAPSHOT + + + pom + openecomp-facade-lib + openecomp-facade-lib + + + openecomp-facade-api + openecomp-facade-core + + + + + org.openecomp.core + openecomp-facade-api + ${project.version} + compile + + + org.openecomp.core + openecomp-facade-core + ${project.version} + runtime + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/pom.xml b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/pom.xml new file mode 100644 index 0000000000..174f2a36d9 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/pom.xml @@ -0,0 +1,40 @@ + + 4.0.0 + + + openecomp-sdc-lib + org.openecomp.sdc + 1.0.0-SNAPSHOT + ../../.. + + + openecomp-nosqldb-api + openecomp-nosqldb-api + org.openecomp.core + + + + org.openecomp.core + openecomp-facade-api + ${project.version} + + + com.datastax.cassandra + cassandra-driver-core + ${datasatx.version} + + + com.datastax.cassandra + cassandra-driver-mapping + ${datasatx.version} + + + org.openecomp.core + openecomp-facade-core + ${project.version} + + + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/java/org/openecomp/core/dao/BaseDao.java b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/java/org/openecomp/core/dao/BaseDao.java new file mode 100644 index 0000000000..c7623f8181 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/java/org/openecomp/core/dao/BaseDao.java @@ -0,0 +1,36 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.dao; + +import java.util.Collection; + +public interface BaseDao { + + Collection list(T entity); + + void create(T entity); + + void update(T entity); + + T get(T entity); + + void delete(T entity); +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/java/org/openecomp/core/dao/UniqueValueDao.java b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/java/org/openecomp/core/dao/UniqueValueDao.java new file mode 100644 index 0000000000..1fa4bb23fe --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/java/org/openecomp/core/dao/UniqueValueDao.java @@ -0,0 +1,28 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.dao; + + +import org.openecomp.core.dao.types.UniqueValueEntity; + +public interface UniqueValueDao extends BaseDao { + +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/java/org/openecomp/core/dao/UniqueValueDaoFactory.java b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/java/org/openecomp/core/dao/UniqueValueDaoFactory.java new file mode 100644 index 0000000000..9f57e4fadd --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/java/org/openecomp/core/dao/UniqueValueDaoFactory.java @@ -0,0 +1,30 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.dao; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; + +public abstract class UniqueValueDaoFactory extends AbstractComponentFactory { + public static UniqueValueDaoFactory getInstance() { + return AbstractFactory.getInstance(UniqueValueDaoFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/java/org/openecomp/core/dao/types/UniqueValueEntity.java b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/java/org/openecomp/core/dao/types/UniqueValueEntity.java new file mode 100644 index 0000000000..1147644253 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/java/org/openecomp/core/dao/types/UniqueValueEntity.java @@ -0,0 +1,58 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.dao.types; + +import com.datastax.driver.mapping.annotations.PartitionKey; +import com.datastax.driver.mapping.annotations.Table; + +@Table(keyspace = "dox", name = "unique_value") +public class UniqueValueEntity { + + @PartitionKey + private String type; + + @PartitionKey(value = 1) + private String value; + + public UniqueValueEntity() { + } + + public UniqueValueEntity(String type, String value) { + this.type = type; + this.value = value; + } + + public String getType() { + return type; + } + + public void setType(String type) { + this.type = type; + } + + public String getValue() { + return value; + } + + public void setValue(String value) { + this.value = value; + } +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/java/org/openecomp/core/nosqldb/api/NoSqlDb.java b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/java/org/openecomp/core/nosqldb/api/NoSqlDb.java new file mode 100644 index 0000000000..6b13ee71e4 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/java/org/openecomp/core/nosqldb/api/NoSqlDb.java @@ -0,0 +1,37 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.nosqldb.api; + +import com.datastax.driver.core.ResultSet; +import com.datastax.driver.mapping.MappingManager; + +public interface NoSqlDb { + + //TODO: remove cassandra types from here!! (like done in SDC...). + + void insert(String tableName, String[] colNames, Object[] values); + + ResultSet execute(String statement); + + ResultSet execute(String statementName, Object... values); + + MappingManager getMappingManager(); +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/java/org/openecomp/core/nosqldb/factory/NoSqlDbFactory.java b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/java/org/openecomp/core/nosqldb/factory/NoSqlDbFactory.java new file mode 100644 index 0000000000..ede264f288 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/java/org/openecomp/core/nosqldb/factory/NoSqlDbFactory.java @@ -0,0 +1,34 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.nosqldb.factory; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; +import org.openecomp.core.nosqldb.api.NoSqlDb; + + +public abstract class NoSqlDbFactory extends AbstractComponentFactory { + + public static NoSqlDbFactory getInstance() { + + return AbstractFactory.getInstance(NoSqlDbFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/java/org/openecomp/core/util/UniqueValueUtil.java b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/java/org/openecomp/core/util/UniqueValueUtil.java new file mode 100644 index 0000000000..a82c97c51c --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/java/org/openecomp/core/util/UniqueValueUtil.java @@ -0,0 +1,127 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.util; + +import org.openecomp.core.dao.UniqueValueDao; +import org.openecomp.core.dao.UniqueValueDaoFactory; +import org.openecomp.core.dao.types.UniqueValueEntity; +import org.openecomp.core.utilities.CommonMethods; +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; + +import java.util.Optional; + +/** + * The type Unique value util. + */ +public class UniqueValueUtil { + /** + * The constant UNIQUE_VALUE_VIOLATION. + */ + public static final String UNIQUE_VALUE_VIOLATION = "UNIQUE_VALUE_VIOLATION"; + private static final String UNIQUE_VALUE_VIOLATION_MSG = "%s with the value '%s' already exists."; + + private static final UniqueValueDao uniqueValueDao = + UniqueValueDaoFactory.getInstance().createInterface(); + + /** + * Create unique value. + * + * @param type the type + * @param uniqueCombination the unique combination + */ + public static void createUniqueValue(String type, String... uniqueCombination) { + Optional value = formatValue(uniqueCombination); + if (!value.isPresent()) { + return; + } + validateUniqueValue(type, value.get(), uniqueCombination); + uniqueValueDao.create(new UniqueValueEntity(type, value.get())); + } + + /** + * Delete unique value. + * + * @param type the type + * @param uniqueCombination the unique combination + */ + public static void deleteUniqueValue(String type, String... uniqueCombination) { + Optional value = formatValue(uniqueCombination); + if (!value.isPresent()) { + return; + } + uniqueValueDao.delete(new UniqueValueEntity(type, value.get())); + } + + /** + * Update unique value. + * + * @param type the type + * @param oldValue the old value + * @param newValue the new value + * @param uniqueContext the unique context + */ + public static void updateUniqueValue(String type, String oldValue, String newValue, + String... uniqueContext) { + if ((newValue != null && oldValue != null + && !newValue.toLowerCase().equals(oldValue.toLowerCase())) + || newValue == null || oldValue == null) { + createUniqueValue(type, CommonMethods.concat(uniqueContext, new String[]{newValue})); + deleteUniqueValue(type, CommonMethods.concat(uniqueContext, new String[]{oldValue})); + } + } + + /** + * Validate unique value. + * + * @param type the type + * @param uniqueCombination the unique combination + */ + public static void validateUniqueValue(String type, String... uniqueCombination) { + Optional value = formatValue(uniqueCombination); + if (!value.isPresent()) { + return; + } + validateUniqueValue(type, value.get(), uniqueCombination); + } + + private static void validateUniqueValue(String type, String value, String... uniqueCombination) { + if (uniqueValueDao.get(new UniqueValueEntity(type, value)) != null) { + throw new CoreException(new ErrorCode.ErrorCodeBuilder() + .withCategory(ErrorCategory.APPLICATION) + .withId(UNIQUE_VALUE_VIOLATION) + .withMessage(String.format(UNIQUE_VALUE_VIOLATION_MSG, type, + uniqueCombination[uniqueCombination.length - 1])).build()); + } + } + + private static Optional formatValue(String[] uniqueCombination) { + if (uniqueCombination == null || uniqueCombination.length == 0 + || uniqueCombination[uniqueCombination.length - 1] == null) { + return Optional.empty(); + } + + uniqueCombination[uniqueCombination.length - 1] = + uniqueCombination[uniqueCombination.length - 1].toLowerCase(); + return Optional.of(CommonMethods.arrayToSeparatedString(uniqueCombination, '_')); + } +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/resources/cassandraStatements.json b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/resources/cassandraStatements.json new file mode 100644 index 0000000000..e83b9f0126 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/resources/cassandraStatements.json @@ -0,0 +1,6 @@ +{ + "test.select.all": "SELECT * FROM test", + "test.drop": "DROP TABLE IF EXISTS test", + "test.create": "CREATE TABLE test (name text PRIMARY KEY,value text)", + "test.insert": "INSERT INTO test (name,value) VALUES ( ?,?)" +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/resources/factoryConfiguration.json b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/resources/factoryConfiguration.json new file mode 100644 index 0000000000..0d5440508f --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-api/src/main/resources/factoryConfiguration.json @@ -0,0 +1,4 @@ +{ + "org.openecomp.core.dao.UniqueValueDaoFactory": "org.openecomp.core.dao.impl.UniqueValueDaoFactoryImpl", + "org.openecomp.core.nosqldb.factory.NoSqlDbFactory": "org.openecomp.core.nosqldb.impl.cassandra.CassandraNoSqlDbFactoryImpl" +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/pom.xml b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/pom.xml new file mode 100644 index 0000000000..d799edb961 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/pom.xml @@ -0,0 +1,60 @@ + + 4.0.0 + + + openecomp-sdc-lib + org.openecomp.sdc + 1.0.0-SNAPSHOT + ../../.. + + + org.openecomp.core + openecomp-nosqldb-core + openecomp-nosqldb-core + + + + + org.openecomp.core + openecomp-nosqldb-api + ${project.version} + + + org.yaml + snakeyaml + 1.14 + test + + + com.google.code.gson + gson + 2.3.1 + test + + + org.mockito + mockito-all + test + 1.10.19 + + + org.testng + testng + test + 6.8.5 + + + snakeyaml + org.yaml + + + + + junit + junit + test + RELEASE + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/java/org/openecomp/core/dao/impl/CassandraBaseDao.java b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/java/org/openecomp/core/dao/impl/CassandraBaseDao.java new file mode 100644 index 0000000000..1b3dbc4c6f --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/java/org/openecomp/core/dao/impl/CassandraBaseDao.java @@ -0,0 +1,50 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.dao.impl; + +import com.datastax.driver.mapping.Mapper; +import org.openecomp.core.dao.BaseDao; + +public abstract class CassandraBaseDao implements BaseDao { + protected abstract Mapper getMapper(); + + protected abstract Object[] getKeys(T entity); + + @Override + public void create(T entity) { + getMapper().save(entity); + } + + @Override + public void update(T entity) { + getMapper().save(entity); + } + + @Override + public T get(T entity) { + return getMapper().get(getKeys(entity)); + } + + @Override + public void delete(T entity) { + getMapper().delete(entity); + } +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/java/org/openecomp/core/dao/impl/UniqueValueCassandraDaoImpl.java b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/java/org/openecomp/core/dao/impl/UniqueValueCassandraDaoImpl.java new file mode 100644 index 0000000000..31dd602400 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/java/org/openecomp/core/dao/impl/UniqueValueCassandraDaoImpl.java @@ -0,0 +1,65 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.dao.impl; + +import com.datastax.driver.mapping.Mapper; +import com.datastax.driver.mapping.Result; +import com.datastax.driver.mapping.annotations.Accessor; +import com.datastax.driver.mapping.annotations.Query; +import org.openecomp.core.dao.UniqueValueDao; +import org.openecomp.core.dao.types.UniqueValueEntity; +import org.openecomp.core.nosqldb.api.NoSqlDb; +import org.openecomp.core.nosqldb.factory.NoSqlDbFactory; + +import java.util.Collection; + +public class UniqueValueCassandraDaoImpl extends CassandraBaseDao + implements UniqueValueDao { + + private static NoSqlDb noSqlDb = NoSqlDbFactory.getInstance().createInterface(); + private static Mapper mapper = + noSqlDb.getMappingManager().mapper(UniqueValueEntity.class); + private static UniqueValueAccessor accessor = + noSqlDb.getMappingManager().createAccessor(UniqueValueAccessor.class); + + + @Override + protected Mapper getMapper() { + return mapper; + } + + @Override + protected Object[] getKeys(UniqueValueEntity entity) { + return new Object[]{entity.getType(), entity.getValue()}; + } + + @Override + public Collection list(UniqueValueEntity entity) { + return accessor.listAll().all(); + } + + @Accessor + interface UniqueValueAccessor { + + @Query("select * from unique_value") + Result listAll(); + } +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/java/org/openecomp/core/dao/impl/UniqueValueDaoFactoryImpl.java b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/java/org/openecomp/core/dao/impl/UniqueValueDaoFactoryImpl.java new file mode 100644 index 0000000000..b717fcbee1 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/java/org/openecomp/core/dao/impl/UniqueValueDaoFactoryImpl.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.dao.impl; + +import org.openecomp.core.dao.UniqueValueDao; +import org.openecomp.core.dao.UniqueValueDaoFactory; + +public class UniqueValueDaoFactoryImpl extends UniqueValueDaoFactory { + private static UniqueValueDao INSTANCE = new UniqueValueCassandraDaoImpl(); + + @Override + public UniqueValueDao createInterface() { + return INSTANCE; + } +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/java/org/openecomp/core/nosqldb/impl/cassandra/CassandraNoSqlDbFactoryImpl.java b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/java/org/openecomp/core/nosqldb/impl/cassandra/CassandraNoSqlDbFactoryImpl.java new file mode 100644 index 0000000000..2922925171 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/java/org/openecomp/core/nosqldb/impl/cassandra/CassandraNoSqlDbFactoryImpl.java @@ -0,0 +1,43 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.nosqldb.impl.cassandra; + +import com.datastax.driver.core.Session; +import org.openecomp.core.nosqldb.api.NoSqlDb; +import org.openecomp.core.nosqldb.factory.NoSqlDbFactory; + +public class CassandraNoSqlDbFactoryImpl extends NoSqlDbFactory { + + @Override + public NoSqlDb createInterface() { + + + return new CassandraNoSqlDbImpl(ReferenceHolder.CASSANDRA); + } + + protected void stop() { + ReferenceHolder.CASSANDRA.close(); + } + + private static class ReferenceHolder { + private static final Session CASSANDRA = CassandraSessionFactory.getSession(); + } +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/java/org/openecomp/core/nosqldb/impl/cassandra/CassandraNoSqlDbImpl.java b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/java/org/openecomp/core/nosqldb/impl/cassandra/CassandraNoSqlDbImpl.java new file mode 100644 index 0000000000..bcac5f8d79 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/java/org/openecomp/core/nosqldb/impl/cassandra/CassandraNoSqlDbImpl.java @@ -0,0 +1,104 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.nosqldb.impl.cassandra; + +import com.datastax.driver.core.BoundStatement; +import com.datastax.driver.core.PreparedStatement; +import com.datastax.driver.core.ResultSet; +import com.datastax.driver.core.Session; +import com.datastax.driver.mapping.MappingManager; +import org.openecomp.core.nosqldb.api.NoSqlDb; +import org.openecomp.core.nosqldb.util.CassandraUtils; +import org.openecomp.core.utilities.CommonMethods; +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; + +class CassandraNoSqlDbImpl implements NoSqlDb { + + private final Session session; + private final String keySpace; + private final MappingManager mappingManager; + + + public CassandraNoSqlDbImpl(Session session) { + this.session = session; + this.keySpace = this.session.getLoggedKeyspace(); + this.mappingManager = new MappingManager(this.session); + + } + + @Override + public void insert(String tableName, String[] colNames, Object[] values) { + if (colNames.length != values.length) { + throw new CoreException((new ErrorCode.ErrorCodeBuilder()).withMessage( + "number of colmuns[" + colNames.length + "] is not equal to the number of values[" + + values.length + "].").withId("E0005").withCategory(ErrorCategory.APPLICATION) + .build()); + } + + StringBuilder sb = new StringBuilder(); + sb.append("insert into ") + .append(tableName) + .append(" (") + .append(CommonMethods.arrayToCommaSeparatedString(colNames)) + .append(") values (") + .append(CommonMethods.duplicateStringWithDelimiter("?", ',', values.length)) + .append(")"); + System.out.println(sb.toString()); + PreparedStatement prepared = session.prepare(sb.toString()); + + BoundStatement bound; + bound = prepared.bind(values); + session.execute(bound); + + } + + @Override + public ResultSet execute(String statement) { + return session.execute(statement); + } + + @Override + public ResultSet execute(String statementName, Object... values) { + + String statement = CassandraUtils.getStatement(statementName); + if (statement == null) { + statement = statementName; + } + if (values != null) { + PreparedStatement prepared = session.prepare(statement); + + BoundStatement bound; + bound = prepared.bind(values); + return session.execute(bound); + } else { + return session.execute(statement); + } + + } + + @Override + public MappingManager getMappingManager() { + return mappingManager; + } + +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/java/org/openecomp/core/nosqldb/impl/cassandra/CassandraSessionFactory.java b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/java/org/openecomp/core/nosqldb/impl/cassandra/CassandraSessionFactory.java new file mode 100644 index 0000000000..1b98f095b5 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/java/org/openecomp/core/nosqldb/impl/cassandra/CassandraSessionFactory.java @@ -0,0 +1,124 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.nosqldb.impl.cassandra; + +import com.google.common.base.Optional; + +import com.datastax.driver.core.Cluster; +import com.datastax.driver.core.SSLOptions; +import com.datastax.driver.core.Session; + +import org.openecomp.core.nosqldb.util.CassandraUtils; + +import java.io.FileInputStream; +import java.io.IOException; +import java.security.KeyManagementException; +import java.security.KeyStore; +import java.security.KeyStoreException; +import java.security.NoSuchAlgorithmException; +import java.security.SecureRandom; +import java.security.UnrecoverableKeyException; +import java.security.cert.CertificateException; +import javax.net.ssl.SSLContext; +import javax.net.ssl.TrustManagerFactory; + +public class CassandraSessionFactory { + public static Session getSession() { + return ReferenceHolder.CASSANDRA; + } + + /** + * New cassandra session session. + * + * @return the session + */ + public static Session newCassandraSession() { + Cluster.Builder builder = Cluster.builder(); + String[] addresses = CassandraUtils.getAddresses(); + for (String address : addresses) { + builder.addContactPoint(address); + } + Boolean isSsl = CassandraUtils.isSsl(); + if (isSsl) { + builder.withSSL(getSslOptions().get()); + } + int port = CassandraUtils.getCassandraPort(); + if (port > 0) { + builder.withPort(port); + } + //Check if user/pass + Boolean isAuthenticate = CassandraUtils.isAuthenticate(); + if (isAuthenticate) { + builder.withCredentials(CassandraUtils.getUser(), CassandraUtils.getPassword()); + } + + Cluster cluster = builder.build(); + String keyStore = CassandraUtils.getKeySpace(); + return cluster.connect(keyStore); + } + + private static Optional getSslOptions() { + Optional truststorePath = Optional.of(CassandraUtils.getTruststore()); + Optional truststorePassword = Optional.of(CassandraUtils.getTruststorePassword()); + + if (truststorePath.isPresent() && truststorePassword.isPresent()) { + SSLContext context; + try { + context = getSslContext(truststorePath.get(), truststorePassword.get()); + } catch (UnrecoverableKeyException | KeyManagementException + | NoSuchAlgorithmException | KeyStoreException | CertificateException | IOException e0) { + throw new RuntimeException(e0); + } + String[] css = new String[]{"TLS_RSA_WITH_AES_128_CBC_SHA"}; + return Optional.of(new SSLOptions(context, css)); + } + return Optional.absent(); + } + + private static SSLContext getSslContext(String truststorePath, String truststorePassword) + throws NoSuchAlgorithmException, KeyStoreException, CertificateException, IOException, + UnrecoverableKeyException, KeyManagementException { + FileInputStream tsf = null; + SSLContext ctx = null; + try { + tsf = new FileInputStream(truststorePath); + ctx = SSLContext.getInstance("SSL"); + + KeyStore ts = KeyStore.getInstance("JKS"); + ts.load(tsf, truststorePassword.toCharArray()); + TrustManagerFactory tmf = + TrustManagerFactory.getInstance(TrustManagerFactory.getDefaultAlgorithm()); + tmf.init(ts); + + ctx.init(null, tmf.getTrustManagers(), new SecureRandom()); + } catch (Exception e0) { + e0.printStackTrace(); + } finally { + tsf.close(); + + } + return ctx; + } + + private static class ReferenceHolder { + private static final Session CASSANDRA = newCassandraSession(); + } +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/java/org/openecomp/core/nosqldb/util/CassandraUtils.java b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/java/org/openecomp/core/nosqldb/util/CassandraUtils.java new file mode 100644 index 0000000000..2a88d0e521 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/java/org/openecomp/core/nosqldb/util/CassandraUtils.java @@ -0,0 +1,92 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.nosqldb.util; + +import org.openecomp.core.utilities.file.FileUtils; +import org.openecomp.core.utilities.json.JsonUtil; + +import java.io.InputStream; +import java.util.HashMap; +import java.util.Map; + +public class CassandraUtils { + + + private static final String CASSANDRA_STATEMENT_DEFINITION_FILE = "cassandraStatements.json"; + private static Map statementMap = new HashMap<>(); + + public static String[] getAddresses() { + return ConfigurationManager.getInstance().getAddresses(); + + } + + public static String getKeySpace() { + return ConfigurationManager.getInstance().getKeySpace(); + } + + /** + * Gets statement. + * + * @param statementName the statement name + * @return the statement + */ + public static String getStatement(String statementName) { + if (statementMap.size() == 0) { + InputStream statementJson = FileUtils.getFileInputStream(CASSANDRA_STATEMENT_DEFINITION_FILE); + statementMap = JsonUtil.json2Object(statementJson, Map.class); + } + return statementMap.get(statementName); + } + + public static String getUser() { + + return ConfigurationManager.getInstance().getUsername(); + } + + public static String getPassword() { + return ConfigurationManager.getInstance().getPassword(); + + } + + public static String getTruststore() { + return ConfigurationManager.getInstance().getTruststorePath(); + + } + + public static String getTruststorePassword() { + return ConfigurationManager.getInstance().getTruststorePassword(); + + } + + public static int getCassandraPort() { + return ConfigurationManager.getInstance().getSslPort(); + + } + + public static boolean isSsl() { + return ConfigurationManager.getInstance().isSsl(); + + } + + public static boolean isAuthenticate() { + return ConfigurationManager.getInstance().isAuthenticate(); + } +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/java/org/openecomp/core/nosqldb/util/ConfigurationManager.java b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/java/org/openecomp/core/nosqldb/util/ConfigurationManager.java new file mode 100644 index 0000000000..a1c0b528fb --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/java/org/openecomp/core/nosqldb/util/ConfigurationManager.java @@ -0,0 +1,234 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.nosqldb.util; + +import org.openecomp.core.utilities.yaml.YamlUtil; + +import java.io.FileInputStream; +import java.io.FileNotFoundException; +import java.io.InputStream; +import java.util.ArrayList; +import java.util.LinkedHashMap; +import java.util.List; +import java.util.Map; + +/** + * The type Configuration manager. + */ +public class ConfigurationManager { + + private static final String CONFIGURATION_YAML_FILE = "configuration.yaml"; + private static final String cassandraKey = "cassandraConfig"; + private static final String DEFAULT_KEYSPACE_NAME = "dox"; + private static final String CASSANDRA_ADDRESSES = "cassandra.addresses"; + private static final String CASSANDRA_DOX_KEY_STORE = "cassandra.dox.keystore"; + private static final String CASSANDRA_AUTHENTICATE = "cassandra.authenticate"; + private static final String CASSANDRA_USER = "cassandra.user"; + private static final String CASSANDRA_PASSWORD = "cassandra.password"; + private static final String CASSANDRA_PORT = "cassandra.port"; + private static final String CASSANDRA_SSL = "cassandra.ssl"; + private static final String CASSANDRA_TRUSTSTORE = "cassandra.Truststore"; + private static final String CASSANDRA_TRUSTSTORE_PASSWORD = "cassandra.TruststorePassword"; + private static final String cassandraHostsKey = "cassandraHosts"; + private static final String cassandraPortKey = "port"; + private static final String cassandraUsernameKey = "username"; + private static final String cassandraPasswordKey = "password"; + private static final String cassandraAuthenticateKey = "authenticate"; + private static final String cassandraSSLKey = "ssl"; + private static final String cassandraTruststorePathKey = "truststorePath"; + private static final String cassandraTruststorePasswordKey = "truststorePassword"; + private static ConfigurationManager instance = null; + private final LinkedHashMap cassandraConfiguration; + + + private ConfigurationManager() { + YamlUtil yamlUtil = new YamlUtil(); + String configurationYamlFile = System.getProperty(CONFIGURATION_YAML_FILE); + InputStream yamlAsString; + if (configurationYamlFile != null) { + yamlAsString = getConfigFileIs(configurationYamlFile); + } else { + //Load from resources + yamlAsString = yamlUtil.loadYamlFileIs("/" + CONFIGURATION_YAML_FILE); + } + Map> configurationMap = yamlUtil.yamlToMap(yamlAsString); + cassandraConfiguration = configurationMap.get(cassandraKey); + + } + + /** + * Gets instance. + * + * @return the instance + */ + public static ConfigurationManager getInstance() { + if (instance == null) { + instance = new ConfigurationManager(); + } + return instance; + } + + /** + * Get addresses string [ ]. + * + * @return the string [ ] + */ + public String[] getAddresses() { + + String addresses = System.getProperty(CASSANDRA_ADDRESSES); + if (addresses != null) { + return addresses.split(","); + } + List locAddresses = (ArrayList) cassandraConfiguration.get(cassandraHostsKey); + String[] addressesArray; + addressesArray = (String[]) locAddresses.toArray(new String[locAddresses.size()]); + return addressesArray; + + } + + /** + * Gets key space. + * + * @return the key space + */ + public String getKeySpace() { + String keySpace = System.getProperty(CASSANDRA_DOX_KEY_STORE); + if (keySpace == null) { + //keySpace = cassandraConfiguration.get(cassandraKeySpaceKey); + //if (keySpace == null) + keySpace = DEFAULT_KEYSPACE_NAME; + } + return keySpace; + } + + /** + * Gets username. + * + * @return the username + */ + public String getUsername() { + String username = System.getProperty(CASSANDRA_USER); + if (username == null) { + username = (String) cassandraConfiguration.get(cassandraUsernameKey); + } + return username; + } + + /** + * Gets password. + * + * @return the password + */ + public String getPassword() { + String password = System.getProperty(CASSANDRA_PASSWORD); + if (password == null) { + password = (String) cassandraConfiguration.get(cassandraPasswordKey); + } + return password; + } + + /** + * Gets truststore path. + * + * @return the truststore path + */ + public String getTruststorePath() { + String truststorePath = System.getProperty(CASSANDRA_TRUSTSTORE); + if (truststorePath == null) { + truststorePath = (String) cassandraConfiguration.get(cassandraTruststorePathKey); + } + return truststorePath; + } + + /** + * Gets truststore password. + * + * @return the truststore password + */ + public String getTruststorePassword() { + String truststorePassword = System.getProperty(CASSANDRA_TRUSTSTORE_PASSWORD); + if (truststorePassword == null) { + truststorePassword = (String) cassandraConfiguration.get(cassandraTruststorePasswordKey); + } + return truststorePassword; + } + + /** + * Gets ssl port. + * + * @return the ssl port + */ + public int getSslPort() { + int port; + String sslPort = System.getProperty(CASSANDRA_PORT); + if (sslPort == null) { + sslPort = (String) cassandraConfiguration.get(cassandraPortKey); + if (sslPort == null) { + sslPort = "0"; + } + } + port = Integer.valueOf(sslPort); + return port; + } + + + /** + * Is ssl boolean. + * + * @return the boolean + */ + public boolean isSsl() { + return getBooleanResult(CASSANDRA_SSL, cassandraSSLKey); + } + + /** + * Is authenticate boolean. + * + * @return the boolean + */ + public boolean isAuthenticate() { + return getBooleanResult(CASSANDRA_AUTHENTICATE, cassandraAuthenticateKey); + } + + private Boolean getBooleanResult(String property, String key) { + Boolean res; + String value; + if (System.getProperty(property) == null) { + value = String.valueOf(cassandraConfiguration.get(key)); + } else { + value = System.getProperty(property); + } + + res = Boolean.valueOf(value); + + return res; + } + + private InputStream getConfigFileIs(String file) { + InputStream is = null; + try { + is = new FileInputStream(file); + } catch (FileNotFoundException e0) { + e0.printStackTrace(); + } + return is; + } +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/resources/configuration.yaml b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/resources/configuration.yaml new file mode 100644 index 0000000000..0988f50237 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/main/resources/configuration.yaml @@ -0,0 +1,253 @@ +identificationHeaderFields: + - HTTP_IV_USER + - HTTP_CSP_FIRSTNAME + - HTTP_CSP_LASTNAME + - HTTP_IV_REMOTE_ADDRESS + - HTTP_CSP_WSTYPE + + + +# catalog backend hostname +beFqdn: sdccatalog.att.com + +# catalog backend http port +beHttpPort: 8080 + +# catalog backend http context +beContext: /sdc/rest/config/get + +# catalog backend protocol +beProtocol: http + +# catalog backend ssl port +beSslPort: 8443 + +version: 1.0 +released: 2012-11-30 + +titanCfgFile: /home/vagrant/catalog-be/config/catalog-be/titan.properties +titanInMemoryGraph: false +titanLockTimeout: 30 +titanReconnectIntervalInSeconds: 3 +titanHealthCheckReadTimeout: 1 +esReconnectIntervalInSeconds: 3 +uebHealthCheckReconnectIntervalInSeconds: 15 +uebHealthCheckReadTimeout: 4 + +# Protocols +protocols: + - http + - https + +# Users +users: + tom: passwd + bob: passwd + +neo4j: + host: neo4jhost + port: 7474 + user: neo4j + password: "12345" + +cassandraConfig: + cassandraHosts: ['127.0.0.1'] + reconnectTimeout : 30000 + authenticate: false + username: sdc_user + password: Aa1234%^! + ssl: false + truststorePath : /path/path + truststorePassword : Aa123456 + keySpaces: + - { name: dox, replicationStrategy: SimpleStrategy, replicationInfo: ['1']} + - { name: sdcartifact, replicationStrategy: SimpleStrategy, replicationInfo: ['1']} + +#Application-specific settings of ES +elasticSearch: + # Mapping of index prefix to time-based frame. For example, if below is configured: + # + # - indexPrefix: auditingevents + # creationPeriod: minute + # + # then ES object of type which is mapped to "auditingevents-*" template, and created on 2015-12-23 13:24:54, will enter "auditingevents-2015-12-23-13-24" index. + # Another object created on 2015-12-23 13:25:54, will enter "auditingevents-2015-12-23-13-25" index. + # If creationPeriod: month, both of the above will enter "auditingevents-2015-12" index. + # + # PLEASE NOTE: the timestamps are created in UTC/GMT timezone! This is needed so that timestamps will be correctly presented in Kibana. + # + # Legal values for creationPeriod - year, month, day, hour, minute, none (meaning no time-based behaviour). + # + # If no creationPeriod is configured for indexPrefix, default behavour is creationPeriod: month. + + indicesTimeFrequency: + - indexPrefix: auditingevents + creationPeriod: month + - indexPrefix: monitoring_events + creationPeriod: month + +artifactTypes: + - CHEF + - PUPPET + - SHELL + - YANG + - YANG_XML + - HEAT + - BPEL + - DG_XML + - MURANO_PKG + - OTHER + +licenseTypes: + - User + - Installation + - CPU + +#Deployment artifacts placeHolder +deploymentResourceArtifacts: + heat: + displayName: "HEAT Template" + type: HEAT + +deploymentResourceInstanceArtifacts: + heatEnv: + displayName: "HEAT ENV" + type: HEAT_ENV + description: "Auto-generated HEAT Environment deployment artifact" + fileExtension: "env" + +#Informational artifacts placeHolder +excludeResourceCategory: + - Generic +informationalResourceArtifacts: + features: + displayName: Features + type: OTHER + capacity: + displayName: Capacity + type: OTHER + vendorTestResult: + displayName: Vendor Test Result + type: OTHER + testScripts: + displayName: Test Scripts + type: OTHER + cloudQuestionnaire: + displayName: Cloud Questionnaire (completed) + type: OTHER + HEATTemplateFromVendor: + displayName: HEAT Template from Vendor + type: HEAT + +excludeServiceCategory: + +informationalServiceArtifacts: + messageFlows: + displayName: Message Flows + type: OTHER + instantiationFlows: + displayName: Management Flows + type: OTHER + serviceArtifactPlan: + displayName: Service Artifact Plan + type: OTHER + summaryOfImpactsToECOMPElements: + displayName: Summary of impacts to ECOMP elements,OSSs, BSSs + type: OTHER + controlLoopFunctions: + displayName: Control Loop Functions + type: OTHER + dimensioningInfo: + displayName: Dimensioning Info + type: OTHER + affinityRules: + displayName: Affinity Rules + type: OTHER + operationalPolicies: + displayName: Operational Policies + type: OTHER + serviceSpecificPolicies: + displayName: Service-specific Policies + type: OTHER + engineeringRules: + displayName: Engineering Rules (ERD) + type: OTHER + distributionInstructions: + displayName: Distribution Instructions + type: OTHER + certificationTestResults: + displayName: TD Certification Test Results + type: OTHER + deploymentVotingRecord: + displayName: Deployment Voting Record + type: OTHER + serviceQuestionnaire: + displayName: Service Questionnaire + type: OTHER + +serviceApiArtifacts: + configuration: + displayName: Configuration + type: OTHER + instantiation: + displayName: Instantiation + type: OTHER + monitoring: + displayName: Monitoring + type: OTHER + reporting: + displayName: Reporting + type: OTHER + logging: + displayName: Logging + type: OTHER + testing: + displayName: Testing + type: OTHER + + +additionalInformationMaxNumberOfKeys: 50 + +systemMonitoring: + enabled: false + isProxy: false + probeIntervalInSeconds: 15 + +defaultHeatArtifactTimeoutMinutes: 60 + +serviceDeploymentArtifacts: + +resourceDeploymentArtifacts: + HEAT: + acceptedTypes: + - yaml + - yml + +resourceInformationalDeployedArtifacts: + YANG_XML: + acceptedTypes: + - xml + + +unLoggedUrls: + - /sdc2/rest/healthCheck + +cleanComponentsConfiguration: + cleanIntervalInMinutes: 1440 + componentsToClean: + - Resource + +artifactsIndex: resources + +heatEnvArtifactHeader: + " # _______________________________________________________________________________________________________________________________________\n + #| AT&T Proprietary (Restricted) |\n + #| Only for use by authorized individuals or any above-designated team(s) |\n + #| within the AT&T companies and not for general distribution |\n + #|_______________________________________________________________________________________________________________________________________|\n" +heatEnvArtifactFooter: + " # _______________________________________________________________________________________________________________________________________\n + #| AT&T Proprietary (Restricted) |\n + #| Only for use by authorized individuals or any above-designated team(s) |\n + #| within the AT&T companies and not for general distribution |\n + #|_______________________________________________________________________________________________________________________________________|\n" diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/test/java/org/openecomp/core/nosqldb/NoSqlDbTest.java b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/test/java/org/openecomp/core/nosqldb/NoSqlDbTest.java new file mode 100644 index 0000000000..e53c482b86 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/test/java/org/openecomp/core/nosqldb/NoSqlDbTest.java @@ -0,0 +1,48 @@ +package org.openecomp.core.nosqldb; + +import org.openecomp.core.nosqldb.api.NoSqlDb; + +import org.openecomp.core.nosqldb.factory.NoSqlDbFactory; + +import com.datastax.driver.core.ResultSet; +import com.datastax.driver.core.Row; + +import org.testng.Assert; +import org.testng.annotations.Test; + +import java.util.List; + +public class NoSqlDbTest { + + private static NoSqlDb noSqlDb; + + +// @Test + public void testNoSqlDbFactoryFactoryInit(){ + this.noSqlDb = NoSqlDbFactory.getInstance().createInterface(); + Assert.assertNotNull(this.noSqlDb); + Assert.assertEquals(this.noSqlDb.getClass().getName(),"org.openecomp.core.nosqldb.impl.cassandra.CassandraNoSqlDbImpl"); + } + +// @Test(dependsOnMethods = {"testNoSqlDbFactoryFactoryInit"}) + public void testCreateTable(){ + this.noSqlDb.execute("test.drop",null); + this.noSqlDb.execute("test.create",null); + } + +// @Test(dependsOnMethods = {"testCreateTable"}) + public void testInsertTable(){ + this.noSqlDb.insert("test",new String[]{"name","value"},new String[]{"TestName","testValue"}); + this.noSqlDb.execute("test.insert",new String[]{"TestName2","testValue2"}); + } + +// @Test(dependsOnMethod`s = {"testInsertTable"}) + public void gettestSelectTable(){ + ResultSet result = this.noSqlDb.execute("test.select.all",null); + List rows = result.all(); + Assert.assertEquals(rows.size(),2); + for (Row row:rows){ + System.out.format("%s %s\n", row.getString("name"), row.getString("value")); + } + } +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/test/java/org/openecomp/core/utilities/Yaml/YamlUtilTest.java b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/test/java/org/openecomp/core/utilities/Yaml/YamlUtilTest.java new file mode 100644 index 0000000000..baf9bfb350 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/test/java/org/openecomp/core/utilities/Yaml/YamlUtilTest.java @@ -0,0 +1,47 @@ +package org.openecomp.core.utilities.Yaml; + +import org.openecomp.core.utilities.yaml.YamlUtil; +import org.junit.Before; +import org.junit.Test; +import testobjects.yaml.YamlFile; + + +public class YamlUtilTest { + + String yamlContent; + + @Before + public void setup() { + initYamlFileContent(); + } + + void initYamlFileContent() { + yamlContent = "heat_template_version: ss\n" + + "description: ab\n" + + "parameters:\n" + + " jsa_net_name: \n" + + " description: network name of jsa log network\n" + + " hidden: true\n" + + " inner:\n" + + " inner1:\n" + + " name: shiri\n" + + " inner2:\n" + + " name: avi"; + } + + @Test + public void shouldConvertSimpleYamlToObject() { + new YamlUtil().yamlToObject(yamlContent, YamlFile.class); + } + + + /*public void loadCassandraParameters(){ + YamlUtil yamlutil = new YamlUtil(); + String cassandraKey = "cassandraConfig"; + String configurationFile = "/configuration.yaml"; + InputStream yamlAsIS = yamlutil.loadYamlFileIs(configurationFile); + Map> configurationMap = yamlutil.yamlToMap(yamlAsIS); + LinkedHashMap cassandraConfiguration = configurationMap.get(cassandraKey); + System.out.println(cassandraConfiguration.entrySet()); + }*/ +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/test/java/org/openecomp/core/utilities/json/JsonUtilTest.java b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/test/java/org/openecomp/core/utilities/json/JsonUtilTest.java new file mode 100644 index 0000000000..5cf8988c06 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/test/java/org/openecomp/core/utilities/json/JsonUtilTest.java @@ -0,0 +1,13 @@ +package org.openecomp.core.utilities.json; + +import org.junit.Test; + +import static org.junit.Assert.*; + +public class JsonUtilTest { + @Test + public void abc() { + System.out.println("as"); + } + +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/test/java/testobjects/yaml/InnerP.java b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/test/java/testobjects/yaml/InnerP.java new file mode 100644 index 0000000000..eda4143e3e --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/test/java/testobjects/yaml/InnerP.java @@ -0,0 +1,25 @@ +package testobjects.yaml; + +public class InnerP { + String name; + String label; + + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getLabel() { + return label; + } + + public void setLabel(String label) { + this.label = label; + } + + +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/test/java/testobjects/yaml/Parameter.java b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/test/java/testobjects/yaml/Parameter.java new file mode 100644 index 0000000000..febcef9c40 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/test/java/testobjects/yaml/Parameter.java @@ -0,0 +1,68 @@ +package testobjects.yaml; + +import java.util.Map; + +public class Parameter { + String name; + String label; + String description; + String paramDefault; + boolean hidden; + Map inner; + + public Map getInner() { + return inner; + } + + public void setInner(Map inner) { + this.inner = inner; + } + + public String getParamDefault() { + return paramDefault; + } + + public void setParamDefault(String paramDefault) { + this.paramDefault = paramDefault; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getLabel() { + return label; + } + + public void setLabel(String label) { + this.label = label; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public String getDefault() { + return paramDefault; + } + + public void setDefault(String paramDefault) { + this.paramDefault = paramDefault; + } + + public boolean isHidden() { + return hidden; + } + + public void setHidden(boolean hidden) { + this.hidden = hidden; + } +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/test/java/testobjects/yaml/YamlFile.java b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/test/java/testobjects/yaml/YamlFile.java new file mode 100644 index 0000000000..1c4989da37 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/openecomp-nosqldb-core/src/test/java/testobjects/yaml/YamlFile.java @@ -0,0 +1,37 @@ +package testobjects.yaml; + +import java.util.Map; + +public class YamlFile { + String heat_template_version; + String description; + Map parameters; + + + public YamlFile() { + } + + public String getHeat_template_version() { + return heat_template_version; + } + + public void setHeat_template_version(String heat_template_version) { + this.heat_template_version = heat_template_version; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public Map getParameters() { + return parameters; + } + + public void setParameters(Map parameters) { + this.parameters = parameters; + } +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/pom.xml b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/pom.xml new file mode 100644 index 0000000000..cb1d810547 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-nosqldb-lib/pom.xml @@ -0,0 +1,36 @@ + + 4.0.0 + + + openecomp-sdc-lib + org.openecomp.sdc + 1.0.0-SNAPSHOT + ../.. + + + openecomp-nosqldb-lib + org.openecomp.core + openecomp-nosqldb-lib + pom + + + openecomp-nosqldb-api + openecomp-nosqldb-core + + + + + org.openecomp.core + openecomp-nosqldb-api + ${project.version} + compile + + + org.openecomp.core + openecomp-nosqldb-core + ${project.version} + runtime + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/pom.xml b/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/pom.xml new file mode 100644 index 0000000000..a7a53a32f0 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/pom.xml @@ -0,0 +1,82 @@ + + 4.0.0 + + + openecomp-core-lib + org.openecomp.core + 1.0.0-SNAPSHOT + + + openecomp-utilities-lib + openecomp-utilities-lib + + + + + org.yaml + snakeyaml + 1.14 + + + org.apache.commons + commons-lang3 + 3.4 + + + org.apache.commons + commons-collections4 + 4.1 + + + com.google.code.gson + gson + 2.3.1 + + + org.slf4j + slf4j-api + 1.7.10 + + + + + commons-codec + commons-codec + ${commons.codec.version} + + + junit + junit + test + RELEASE + + + org.codehaus.jackson + jackson-mapper-asl + ${org.codehaus.jackson.version} + + + org.everit.json + org.everit.json.schema + ${org.everit.json.schema.version} + + + org.testng + testng + test + 6.8.5 + + + snakeyaml + org.yaml + + + + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/main/java/org/openecomp/core/utilities/CommonMethods.java b/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/main/java/org/openecomp/core/utilities/CommonMethods.java new file mode 100644 index 0000000000..343636bd15 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/main/java/org/openecomp/core/utilities/CommonMethods.java @@ -0,0 +1,555 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.utilities; + +import org.apache.commons.codec.binary.Base64; + +import java.io.ByteArrayInputStream; +import java.io.ByteArrayOutputStream; +import java.io.IOException; +import java.io.ObjectInputStream; +import java.io.ObjectOutputStream; +import java.io.PrintWriter; +import java.io.Serializable; +import java.io.StringWriter; +import java.lang.reflect.Array; +import java.net.URL; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.Collection; +import java.util.Collections; +import java.util.List; +import java.util.Map; +import java.util.Set; +import java.util.UUID; + +/** + * This class provides auxiliary static methods. + */ +public class CommonMethods { + //private static final Logger logger = LoggerFactory.getLogger(CommonMethods.class); + + private static final char[] hexArray = "0123456789ABCDEF".toCharArray(); + + private static final char[] CHARS = new char[]{ + '0', '1', '2', '3', '4', '5', '6', '7', + '8', '9', 'A', 'B', 'C', 'D', 'E', 'F' + }; + + /** + * Private default constructor to prevent instantiation of the class objects. + */ + private CommonMethods() { + } + + /** + * Serializes an object instance into byte array. + * + * @param object An instance to be serialized. + * @return Java array of bytes. + * @see #deserializeObject(byte[]) #deserializeObject(byte[]) + */ + public static byte[] serializeObject(Serializable object) { + ByteArrayOutputStream byteArray = new ByteArrayOutputStream(2048); + try { + ObjectOutputStream ds = new ObjectOutputStream(byteArray); + ds.writeObject(object); + ds.close(); + } catch (IOException e0) { + throw new RuntimeException(e0); + } + + return byteArray.toByteArray(); + } // serializeObject + + /** + * Deserializes an object instance. + * + * @param bytes Java array of bytes. + * @return Deserialized instance of an object. + * @see #serializeObject(Serializable) #serializeObject(Serializable) + */ + public static Serializable deserializeObject(byte[] bytes) { + Serializable obj = null; + try { + ObjectInputStream stream = new ObjectInputStream(new ByteArrayInputStream(bytes)); + obj = (Serializable) stream.readObject(); + stream.close(); + } catch (IOException | ClassNotFoundException e0) { + throw new RuntimeException(e0); + } + + return obj; + } // deserializeObject + + /** + * Encodes binary byte stream to ASCII format. + * + * @param binary An Java array of bytes in binary format. + * @return An Java array of bytes encoded in ASCII format. + * @see #decode(byte[]) #decode(byte[]) + */ + public static byte[] encode(byte[] binary) { + return Base64.encodeBase64(binary); + } + + /** + * Decodes ASCII byte stream into binary format. + * + * @param ascii An Java array of bytes in ASCII format. + * @return An Java array of bytes encoded in binary format. + * @see #encode(byte[]) #encode(byte[]) + */ + public static byte[] decode(byte[] ascii) { + return Base64.decodeBase64(ascii); + } + + /** + * Checks whether the given Object is empty. + * + * @param obj Object to be checked. + * @return true - if the Object is null, false otherwise. + */ + public static boolean isEmpty(Object obj) { + return obj == null; + } + + /** + * Checks whether the given Object is empty. + * + * @param byteArray Object to be checked. + * @return true - if the Object is null, false otherwise. + */ + public static boolean isEmpty(byte[] byteArray) { + return (byteArray == null || byteArray.length == 0); + } + + /** + * Checks whether the given String is empty. + * + * @param str String object to be checked. + * @return true - if the String is null or empty, false - otherwise. + */ + public static boolean isEmpty(String str) { + return str == null || str.length() == 0; + } + + /** + * Checks whether the given Java array is empty. + * + * @param array Java array to be checked. + * @return true - if the array is null or empty, false - otherwise. + */ + public static boolean isEmpty(Object[] array) { + return array == null || array.length == 0; + } + + /** + * Checks whether the given collection is empty. + * + * @param collection A collection to be checked. + * @return true - if the collection is null or empty, false - otherwise. + */ + public static boolean isEmpty(Collection collection) { + return collection == null || collection.isEmpty(); + } + + /** + * Checks whether the given map is empty. + * + * @param map A map to be checked. + * @return true - if the map is null or empty, false - otherwise. + */ + public static boolean isEmpty(Map map) { + return map == null || map.isEmpty(); + } + + /** + * Converts the array with Long elements to the array with long (primitive type). + * + * @param array input array with Long elements. + * @return array with the same elements converted to the long type (primitive). + */ + public static long[] toPrimitive(Long[] array) { + if (array == null) { + return null; + } + + long[] result = new long[array.length]; + for (int i = 0; i < array.length; i++) { + result[i] = array[i] != null ? array[i] : 0L; + } + return result; + } + + /** + * Converts a collection to Java array. + * + * @param Java type of the collection element. + * @param col Collection to be converted to array + * @param type Java type of collection/array element + * @return An Java array of collection elements, or empty array if collection is null or empty. + */ + @SuppressWarnings("unchecked") + public static T[] toArray(Collection col, Class type) { + int length = isEmpty(col) ? 0 : col.size(); + T[] array = (T[]) Array.newInstance(type, length); + return col != null ? col.toArray(array) : array; + } + + /** + * Gets an universally unique identifier (UUID). + * + * @return String representation of generated UUID. + */ + public static String nextUuId() { + UUID uuid = UUID.randomUUID(); + + StringBuilder buff = new StringBuilder(32); + long2string(uuid.getMostSignificantBits(), buff); + long2string(uuid.getLeastSignificantBits(), buff); + + return buff.toString(); + } + + private static void long2string(long lng, StringBuilder buff) { + for (int i = 0; i < 16; i++) { + long nextByte = lng & 0xF000000000000000L; + lng <<= 4; + boolean isNegative = nextByte < 0; + nextByte = rightShift(nextByte, 60); + + if (isNegative) { + nextByte |= 0x08; + } + + buff.append(CHARS[(int) nextByte]); + } + } + + private static long rightShift(long lng, int num) { + return lng >>> num; + } + + /** + * Concatenates two Java arrays. The method allocates a new array and copies + * all elements to it or returns one of input arrays if another one is + * empty. + * + * @param the type parameter + * @param left Elements of this array will be copied to positions from 0 to + * left.length - 1 in the target array. + * @param right Elements of this array will be copied to positions from + * left.length to left.length + right.length + * @return A newly allocate Java array that accommodates elements of source (left/right) + arraysor one of source arrays if another is empty, null - otherwise. + */ + @SuppressWarnings("unchecked") + public static T[] concat(T[] left, T[] right) { + T[] res = null; + + if (isEmpty(left)) { + res = right; + } else if (isEmpty(right)) { + res = left; + } else { + res = (T[]) Array.newInstance(left[0].getClass(), left.length + right.length); + System.arraycopy(left, 0, res, 0, left.length); + System.arraycopy(right, 0, res, left.length, right.length); + } + + return res; + } // concat + + /** + * Casts an object to the class or interface represented by the specified + * Class object. The method logic is similar to Java method + * Class.cast(Object) with the only difference that unlike Java's + * version the type name of the current object instance is specified in the + * error message if casting fails to simplify error tracking. + * + * @param the type parameter + * @param the type parameter + * @param b0 An object instance to be casted to the specified Java type. + * @param cls Target Java type. + * @return Object instance safely casted to the requested Java type. + * @throws ClassCastException In case which is the given object is not instance of the + * specified Java type. + */ + @SuppressWarnings("unchecked") + public static D cast(B b0, Class cls) { + D d0 = null; + if (b0 != null) { + if (!cls.isInstance(b0)) { + throw new ClassCastException(String + .format("Failed to cast from '%s' to '%s'", b0.getClass().getName(), cls.getName())); + } else { + d0 = (D) b0; + } + } + + return d0; + } // cast + + /** + * New instance object. + * + * @param classname the classname + * @return the object + */ + public static Object newInstance(String classname) { + return newInstance(classname, Object.class); + } + + /** + * New instance t. + * + * @param the type parameter + * @param classname the classname + * @param cls the cls + * @return the t + */ + @SuppressWarnings("unchecked") + public static T newInstance(String classname, Class cls) { + + if (isEmpty(classname)) { + throw new IllegalArgumentException(); + } + + if (cls == null) { + throw new IllegalArgumentException(); + } + + try { + Class temp = Class.forName(classname); + + if (!cls.isAssignableFrom(temp)) { + throw new ClassCastException( + String.format("Failed to cast from '%s' to '%s'", classname, cls.getName())); + } + + Class impl = (Class) temp; + + return newInstance(impl); + } catch (ClassNotFoundException e0) { + throw new IllegalArgumentException(e0); + } + } + + /** + * New instance t. + * + * @param the type parameter + * @param cls the cls + * @return the t + */ + public static T newInstance(Class cls) { + try { + return cls.newInstance(); + } catch (InstantiationException e0) { + throw new RuntimeException(e0); + } catch (IllegalAccessException e0) { + throw new RuntimeException(e0); + } + } + + /** + * Gets resources path. + * + * @param resourceName the resource name + * @return the resources path + */ + public static String getResourcesPath(String resourceName) { + URL resourceUrl = CommonMethods.class.getClassLoader().getResource(resourceName); + String resourcePath = resourceUrl.getPath(); + String dirPath = resourcePath.substring(0, resourcePath.lastIndexOf("/") + 1); + + return dirPath; + } + + /** + * Gets stack trace. + * + * @param t0 the t 0 + * @return the stack trace + */ + public static String getStackTrace(Throwable t0) { + if (null == t0) { + return ""; + } + StringWriter sw = new StringWriter(); + t0.printStackTrace(new PrintWriter(sw)); + return sw.toString(); + } + + /** + * Print stack trace string. + * + * @return the string + */ + public static String printStackTrace() { + + StringWriter sw = new StringWriter(); + StackTraceElement[] trace = Thread.currentThread().getStackTrace(); + for (StackTraceElement traceElement : trace) { + sw.write("\t " + traceElement); + sw.write(System.lineSeparator()); + } + String str = sw.toString(); + try { + sw.close(); + } catch (IOException e0) { + System.err.println(e0); + } + return str; + + } + + /** + * Is equal object boolean. + * + * @param obj1 the obj 1 + * @param obj2 the obj 2 + * @return the boolean + */ + public static boolean isEqualObject(Object obj1, Object obj2) { + boolean isEqualValue = false; + if (obj1 == null && obj2 == null) { + isEqualValue = true; + } + + if (!isEqualValue && obj1 != null && obj2 != null && obj1.equals(obj2)) { + isEqualValue = true; + } + return isEqualValue; + } + + /** + * Converts array of strings to comma-separated string. + * + * @param arr array of strings + * @return the string + */ + public static String arrayToCommaSeparatedString(String[] arr) { + return arrayToSeparatedString(arr, ','); + } + + /** + * Collection to comma separated string string. + * + * @param elementCollection the element collection + * @return the string + */ + public static String collectionToCommaSeparatedString(Collection elementCollection) { + List list = new ArrayList<>(); + elementCollection.stream().forEach(element -> list.add(element)); + return listToSeparatedString(list, ','); + } + + /** + * Converts array of strings to string separated with specified character. + * + * @param arr array of strings + * @param separator the separator + * @return the string + */ + public static String arrayToSeparatedString(String[] arr, char separator) { + return listToSeparatedString(Arrays.asList(arr), separator); + } + + /** + * Converts array of strings to string separated with specified character. + * + * @param list array of strings + * @param separator the separator + * @return the string + */ + public static String listToSeparatedString(List list, char separator) { + String res = null; + if (null != list) { + StringBuilder sb = new StringBuilder(); + int sz = list.size(); + for (int i = 0; i < sz; i++) { + if (i > 0) { + sb.append(separator); + } + sb.append(list.get(i)); + } + res = sb.toString(); + } + return res; + } + + /** + * Duplicate string with delimiter string. + * + * @param arg the arg + * @param separator the separator + * @param numberOfDuplications the number of duplications + * @return the string + */ + public static String duplicateStringWithDelimiter(String arg, char separator, + int numberOfDuplications) { + String res = null; + StringBuilder sb = new StringBuilder(); + + for (int i = 0; i < numberOfDuplications; i++) { + if (i > 0) { + sb.append(separator); + } + sb.append(arg); + } + res = sb.toString(); + return res; + } + + /** + * Bytes to hex string. + * + * @param bytes the bytes + * @return the string + */ + public static String bytesToHex(byte[] bytes) { + char[] hexChars = new char[bytes.length * 2]; + for (int j = 0; j < bytes.length; j++) { + int v0 = bytes[j] & 0xFF; + int x0 = j << 1; + hexChars[x0] = hexArray[v0 >>> 4]; + hexChars[x0 + 1] = hexArray[v0 & 0x0F]; + } + return new String(hexChars); + } + + /** + * To single element set set. + * + * @param the class of the objects in the set + * @param element the single element to be contained in the returned Set + * @return an immutable set containing only the specified object.The returned set is serializable. + */ + public static Set toSingleElementSet(T element) { + return Collections.singleton(element); + + } + + +} + diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/main/java/org/openecomp/core/utilities/file/FileContentHandler.java b/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/main/java/org/openecomp/core/utilities/file/FileContentHandler.java new file mode 100644 index 0000000000..67a79875d4 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/main/java/org/openecomp/core/utilities/file/FileContentHandler.java @@ -0,0 +1,88 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.utilities.file; + +import org.apache.commons.collections4.MapUtils; + +import java.io.ByteArrayInputStream; +import java.io.InputStream; +import java.util.HashMap; +import java.util.Map; +import java.util.Set; + +public class FileContentHandler { + private Map files = new HashMap<>(); + + /** + * Gets file content. + * + * @param fileName the file name + * @return the file content + */ + public InputStream getFileContent(String fileName) { + + byte[] content = files.get(fileName); + if (content == null || content.length == 0) { + return null; + } + + ByteArrayInputStream is = new ByteArrayInputStream(content); + return is; + } + + public void addFile(String fileName, byte[] contect) { + files.put(fileName, contect); + } + + public void addFile(String fileName, InputStream is) { + + files.put(fileName, FileUtils.toByteArray(is)); + } + + public void setFiles(FileContentHandler extFiles) { + extFiles.getFileList().stream() + .forEach(fileName -> this.addFile(fileName, extFiles.getFileContent(fileName))); + } + + public Set getFileList() { + return files.keySet(); + } + + public void putAll(Map files) { + this.files = files; + } + + public void addAll(FileContentHandler other) { + this.files.putAll(other.files); + } + + public boolean isEmpty() { + return MapUtils.isEmpty(this.files); + } + + public void remove(String fileName) { + files.remove(fileName); + } + + public boolean containsFile(String fileName) { + return files.containsKey(fileName); + } +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/main/java/org/openecomp/core/utilities/file/FileUtils.java b/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/main/java/org/openecomp/core/utilities/file/FileUtils.java new file mode 100644 index 0000000000..72fa9ac7b8 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/main/java/org/openecomp/core/utilities/file/FileUtils.java @@ -0,0 +1,286 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.utilities.file; + +import org.openecomp.core.utilities.json.JsonUtil; +import org.openecomp.core.utilities.yaml.YamlUtil; + +import java.io.ByteArrayInputStream; +import java.io.ByteArrayOutputStream; +import java.io.IOException; +import java.io.InputStream; +import java.io.OutputStream; +import java.net.URL; +import java.util.ArrayList; +import java.util.Enumeration; +import java.util.List; +import java.util.zip.ZipEntry; +import java.util.zip.ZipInputStream; + +/** + * The type File utils. + */ +public class FileUtils { + + /** + * Gets file input stream. + * + * @param fileName the file name + * @return the file input stream + */ + public static InputStream getFileInputStream(String fileName) { + URL urlFile = FileUtils.class.getClassLoader().getResource(fileName); + InputStream is; + try { + assert urlFile != null; + is = urlFile.openStream(); + } catch (IOException exception) { + throw new RuntimeException(exception); + } + return is; + } + + /** + * Gets file input streams. + * + * @param fileName the file name + * @return the file input streams + */ + public static List getFileInputStreams(String fileName) { + Enumeration urlFiles; + List streams = new ArrayList<>(); + InputStream is; + URL url; + try { + urlFiles = FileUtils.class.getClassLoader().getResources(fileName); + while (urlFiles.hasMoreElements()) { + url = urlFiles.nextElement(); + is = url.openStream(); + streams.add(is); + } + + + } catch (IOException exception) { + throw new RuntimeException(exception); + } + return streams; + } + + /** + * Convert to bytes byte [ ]. + * + * @param object the object + * @param extension the extension + * @return the byte [ ] + */ + public static byte[] convertToBytes(Object object, FileExtension extension) { + if (object != null) { + if (extension.equals(FileExtension.YAML) || extension.equals(FileExtension.YML)) { + return new YamlUtil().objectToYaml(object).getBytes(); + } else { + return JsonUtil.object2Json(object).getBytes(); + } + } else { + return new byte[]{}; + } + } + + /** + * Convert to input stream input stream. + * + * @param object the object + * @param extension the extension + * @return the input stream + */ + public static InputStream convertToInputStream(Object object, FileExtension extension) { + if (object != null) { + + byte[] content; + + if (extension.equals(FileExtension.YAML) || extension.equals(FileExtension.YML)) { + content = new YamlUtil().objectToYaml(object).getBytes(); + } else { + content = JsonUtil.object2Json(object).getBytes(); + + } + return new ByteArrayInputStream(content); + } else { + return null; + } + } + + /** + * Load file to input stream input stream. + * + * @param fileName the file name + * @return the input stream + */ + public static InputStream loadFileToInputStream(String fileName) { + URL urlFile = FileUtils.class.getClassLoader().getResource(fileName); + try { + Enumeration en = FileUtils.class.getClassLoader().getResources(fileName); + while (en.hasMoreElements()) { + urlFile = en.nextElement(); + } + } catch (IOException | NullPointerException exception) { + throw new RuntimeException(exception); + } + try { + if (urlFile != null) { + return urlFile.openStream(); + } else { + throw new RuntimeException(); + } + } catch (IOException | NullPointerException exception) { + throw new RuntimeException(exception); + } + + } + + /** + * To byte array byte [ ]. + * + * @param input the input + * @return the byte [ ] + */ + public static byte[] toByteArray(InputStream input) { + ByteArrayOutputStream output = new ByteArrayOutputStream(); + try { + copy(input, output); + } catch (IOException exception) { + throw new RuntimeException( + "error will convertion input stream to byte array:" + exception.getMessage()); + } + return output.toByteArray(); + } + + /** + * Copy int. + * + * @param input the input + * @param output the output + * @return the int + * @throws IOException the io exception + */ + public static int copy(InputStream input, OutputStream output) throws IOException { + long count = copyLarge(input, output); + return count > 2147483647L ? -1 : (int) count; + } + + private static long copyLarge(InputStream input, OutputStream output) throws IOException { + return copyLarge(input, output, new byte[4096]); + } + + private static long copyLarge(InputStream input, OutputStream output, byte[] buffer) + throws IOException { + long count = 0L; + + int n1; + if (input == null) { + return count; + } + for (; -1 != (n1 = input.read(buffer)); count += (long) n1) { + output.write(buffer, 0, n1); + } + + return count; + + + } + + /** + * Gets file without extention. + * + * @param fileName the file name + * @return the file without extention + */ + public static String getFileWithoutExtention(String fileName) { + if (!fileName.contains(".")) { + return fileName; + } + return fileName.substring(0, fileName.lastIndexOf(".")); + } + + /** + * Gets file content map from zip. + * + * @param zipData the zip data + * @return the file content map from zip + * @throws IOException the io exception + */ + public static FileContentHandler getFileContentMapFromZip(byte[] zipData) throws IOException { + ZipEntry zipEntry; + FileContentHandler mapFileContent = new FileContentHandler(); + try { + ZipInputStream inputZipStream; + + byte[] fileByteContent; + String currentEntryName; + inputZipStream = new ZipInputStream(new ByteArrayInputStream(zipData)); + + while ((zipEntry = inputZipStream.getNextEntry()) != null) { + currentEntryName = zipEntry.getName(); + fileByteContent = FileUtils.toByteArray(inputZipStream); + mapFileContent.addFile(currentEntryName, fileByteContent); + } + + } catch (RuntimeException exception) { + throw new IOException(exception); + } + return mapFileContent; + } + + /** + * The enum File extension. + */ + public enum FileExtension { + + /** + * Json file extension. + */ + JSON("json"), + /** + * Yaml file extension. + */ + YAML("yaml"), + /** + * Yml file extension. + */ + YML("yml"); + + private String displayName; + + FileExtension(String displayName) { + this.displayName = displayName; + } + + /** + * Gets display name. + * + * @return the display name + */ + public String getDisplayName() { + return displayName; + } + } + + +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/main/java/org/openecomp/core/utilities/json/JsonSchemaDataGenerator.java b/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/main/java/org/openecomp/core/utilities/json/JsonSchemaDataGenerator.java new file mode 100644 index 0000000000..8968eeb323 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/main/java/org/openecomp/core/utilities/json/JsonSchemaDataGenerator.java @@ -0,0 +1,185 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.utilities.json; + +import org.json.JSONException; +import org.json.JSONObject; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import java.util.HashMap; +import java.util.Map; + +/** + * The type Json schema data generator. + */ +public class JsonSchemaDataGenerator { + + private static final String ROOT = "root"; + private static final Logger logger = LoggerFactory.getLogger(JsonSchemaDataGenerator.class); + /** + * The Include defaults. + */ + boolean includeDefaults = true; + private JSONObject root; + private Map referencesData; + + /** + * Instantiates a new Json schema data generator. + * + * @param jsonSchema the json schema + */ + public JsonSchemaDataGenerator(String jsonSchema) { + if (jsonSchema == null) { + throw new IllegalArgumentException("Input string jsonSchema can not be null"); + } + root = new JSONObject(jsonSchema); + } + + /** + * Sets include defaults. + * + * @param includeDefaults the include defaults + */ + public void setIncludeDefaults(boolean includeDefaults) { + this.includeDefaults = includeDefaults; + } + + /** + * Generates json data that conform to the schema according to turned on flags. + * + * @return json that conform to the schema. + */ + public String generateData() { + referencesData = new HashMap<>(); + JSONObject data = new JSONObject(); + + generateData(ROOT, root, + data); // "root" is dummy name to represent the top level object (which, as apposed to + // inner objects, doesn't have a name in the schema) + return data.has(ROOT) ? data.get(ROOT).toString() : data.toString(); + } + + private void generateData(String propertyName, JSONObject property, JSONObject propertyData) { + if (property.has(JsonSchemaKeyword.TYPE)) { + String propertyType = property.getString(JsonSchemaKeyword.TYPE); + if (JsonSchemaKeyword.OBJECT.equals(propertyType)) { + generateObjectData(propertyName, property, propertyData); + } else { + generatePrimitiveData(propertyType, propertyName, property, propertyData); + } + } else if (property.has(JsonSchemaKeyword.REF)) { + generateReferenceData(propertyName, property.getString(JsonSchemaKeyword.REF), propertyData); + } + } + + private void generateObjectData(String propertyName, JSONObject property, + JSONObject propertyData) { + JSONObject subProperties = property.getJSONObject(JsonSchemaKeyword.PROPERTIES); + + JSONObject subPropertiesData = new JSONObject(); + for (String subPropertyName : subProperties.keySet()) { + generateData(subPropertyName, subProperties.getJSONObject(subPropertyName), + subPropertiesData); + } + + if (subPropertiesData.length() > 0) { + propertyData.put(propertyName, subPropertiesData); + } + } + + private void generateReferenceData(String propertyName, String referencePath, + JSONObject propertyData) { + if (referencesData.containsKey(referencePath)) { + Object referenceData = referencesData.get(referencePath); + if (referenceData != null) { + propertyData.put(propertyName, referenceData); + } + } else { + generateData(propertyName, resolveReference(referencePath), propertyData); + referencesData.put(referencePath, propertyData.opt(propertyName)); + } + } + + private JSONObject resolveReference(String referencePath) { + String[] keys = referencePath.replaceFirst("#/", "").split("/"); + + JSONObject reference = root; + for (String key : keys) { + reference = reference.getJSONObject(key); + } + return reference; + } + + private void generatePrimitiveData(String propertyType, String propertyName, JSONObject property, + JSONObject propertyData) { + if (includeDefaults) { + populateWithDefaultValue(propertyType, propertyName, property, propertyData); + } + } + + private void populateWithDefaultValue(String propertyType, String propertyName, + JSONObject property, JSONObject propertyData) { + if (!property.has(JsonSchemaKeyword.DEFAULT)) { + return; + } + try { + switch (propertyType) { + case JsonSchemaKeyword.ARRAY: + propertyData.put(propertyName, property.getJSONArray(JsonSchemaKeyword.DEFAULT)); + break; + case JsonSchemaKeyword.BOOLEAN: + propertyData.put(propertyName, property.getBoolean(JsonSchemaKeyword.DEFAULT)); + break; + case JsonSchemaKeyword.INTEGER: + propertyData.put(propertyName, property.getInt(JsonSchemaKeyword.DEFAULT)); + break; + case JsonSchemaKeyword.NUMBER: + propertyData.put(propertyName, property.getDouble(JsonSchemaKeyword.DEFAULT)); + break; + case JsonSchemaKeyword.STRING: + propertyData.put(propertyName, property.getString(JsonSchemaKeyword.DEFAULT)); + break; + default: + break; + } + } catch (JSONException e0) { + Object defaultValue = property.get(JsonSchemaKeyword.DEFAULT); + logger.error(String.format( + "Invalid schema: '%s' property type is '%s' but it has a default value which is not: %s.", + propertyName, propertyType, defaultValue), e0); + throw e0; + } + } + + private static class JsonSchemaKeyword { + private static final String DEFAULT = "default"; + private static final String TYPE = "type"; + private static final String PROPERTIES = "properties"; + private static final String ARRAY = "array"; + private static final String BOOLEAN = "boolean"; + private static final String INTEGER = "integer"; + private static final String NUMBER = "number"; + private static final String STRING = "string"; + private static final String OBJECT = "object"; + private static final String REF = "$ref"; + } +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/main/java/org/openecomp/core/utilities/json/JsonUtil.java b/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/main/java/org/openecomp/core/utilities/json/JsonUtil.java new file mode 100644 index 0000000000..6ae3677a8d --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/main/java/org/openecomp/core/utilities/json/JsonUtil.java @@ -0,0 +1,187 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.utilities.json; + + +import com.google.gson.Gson; +import com.google.gson.GsonBuilder; +import com.google.gson.JsonIOException; +import com.google.gson.JsonParser; +import com.google.gson.JsonSyntaxException; + +import org.apache.commons.collections.CollectionUtils; +import org.everit.json.schema.EnumSchema; +import org.everit.json.schema.Schema; +import org.everit.json.schema.ValidationException; +import org.everit.json.schema.loader.SchemaLoader; +import org.json.JSONObject; +import org.openecomp.core.utilities.CommonMethods; + +import java.io.BufferedReader; +import java.io.IOException; +import java.io.InputStream; +import java.io.InputStreamReader; +import java.io.Reader; +import java.io.StringReader; +import java.util.Collections; +import java.util.List; +import java.util.Set; +import java.util.stream.Collectors; + +/** + * The type Json util. + */ +public class JsonUtil { + + /** + * Object 2 json string. + * + * @param obj the obj + * @return the string + */ + //TODO: refactor all other ugly code to use this + public static String object2Json(Object obj) { + return sbObject2Json(obj).toString(); + + } + + /** + * Sb object 2 json string buffer. + * + * @param obj the obj + * @return the string buffer + */ + public static StringBuffer sbObject2Json(Object obj) { + return new StringBuffer((new GsonBuilder()).setPrettyPrinting().create().toJson(obj)); + } + + /** + * Json 2 object t. + * + * @param the type parameter + * @param json the json + * @param classOfT the class of t + * @return the t + */ + public static T json2Object(String json, Class classOfT) { + T type; + try { + try (Reader br = new StringReader(json)) { + type = new Gson().fromJson(br, classOfT); + } catch (IOException e0) { + throw e0; + } + } catch (JsonIOException | JsonSyntaxException | IOException e0) { + throw new RuntimeException(e0); + } + return type; + } + + /** + * Json 2 object t. + * + * @param the type parameter + * @param is the is + * @param classOfT the class of t + * @return the t + */ + public static T json2Object(InputStream is, Class classOfT) { + T type; + try { + try (Reader br = new BufferedReader(new InputStreamReader(is))) { + type = new Gson().fromJson(br, classOfT); + } + } catch (JsonIOException | JsonSyntaxException | IOException e0) { + throw new RuntimeException(e0); + } finally { + if (is != null) { + try { + is.close(); + } catch (IOException ignore) { + //do nothing + } + } + } + return type; + } + + + /** + * Is valid json boolean. + * + * @param json the json + * @return the boolean + */ + //todo check https://github.com/stleary/JSON-java as replacement for this code + public static boolean isValidJson(String json) { + try { + return new JsonParser().parse(json).isJsonObject(); + } catch (JsonSyntaxException jse) { + return false; + } + } + + /** + * Validate list. + * + * @param json the json + * @param jsonSchema the json schema + * @return the list + */ + public static List validate(String json, String jsonSchema) { + List validationErrors = validateUsingEverit(json, jsonSchema); + return validationErrors == null ? null + : validationErrors.stream().map(JsonUtil::mapValidationExceptionToMessage) + .collect(Collectors.toList()); + } + + private static String mapValidationExceptionToMessage(ValidationException e0) { + if (e0.getViolatedSchema() instanceof EnumSchema) { + return mapEnumViolationToMessage(e0); + } + return e0.getMessage(); + } + + private static String mapEnumViolationToMessage(ValidationException e1) { + Set possibleValues = ((EnumSchema) e1.getViolatedSchema()).getPossibleValues(); + return e1.getMessage().replaceFirst("enum value", possibleValues.size() == 1 + ? String.format("value. %s is the only possible value for this field", + possibleValues.iterator().next()) + : String.format("value. Possible values: %s", CommonMethods + .collectionToCommaSeparatedString( + possibleValues.stream().map(Object::toString).collect(Collectors.toList())))); + } + + private static List validateUsingEverit(String json, String jsonSchema) { + if (json == null || jsonSchema == null) { + throw new IllegalArgumentException("Input strings json and jsonSchema can not be null"); + } + + Schema schemaObj = SchemaLoader.load(new JSONObject(jsonSchema)); + try { + schemaObj.validate(new JSONObject(json)); + } catch (ValidationException ve) { + return CollectionUtils.isEmpty(ve.getCausingExceptions()) ? Collections.singletonList(ve) + : ve.getCausingExceptions(); + } + return null; + } +} diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/main/java/org/openecomp/core/utilities/yaml/YamlUtil.java b/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/main/java/org/openecomp/core/utilities/yaml/YamlUtil.java new file mode 100644 index 0000000000..56261f08de --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/main/java/org/openecomp/core/utilities/yaml/YamlUtil.java @@ -0,0 +1,289 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.utilities.yaml; + +import org.openecomp.core.utilities.CommonMethods; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; +import org.yaml.snakeyaml.DumperOptions; +import org.yaml.snakeyaml.TypeDescription; +import org.yaml.snakeyaml.Yaml; +import org.yaml.snakeyaml.constructor.Constructor; +import org.yaml.snakeyaml.introspector.BeanAccess; +import org.yaml.snakeyaml.introspector.Property; +import org.yaml.snakeyaml.introspector.PropertyUtils; +import org.yaml.snakeyaml.nodes.MappingNode; +import org.yaml.snakeyaml.nodes.NodeTuple; +import org.yaml.snakeyaml.nodes.Tag; +import org.yaml.snakeyaml.parser.ParserException; +import org.yaml.snakeyaml.representer.Representer; + +import java.beans.IntrospectionException; +import java.io.IOException; +import java.io.InputStream; +import java.util.AbstractMap; +import java.util.LinkedHashMap; +import java.util.LinkedHashSet; +import java.util.Map; +import java.util.Set; + +/** + * The type Yaml util. + */ +public class YamlUtil { + + private static Logger logger = LoggerFactory.getLogger(YamlUtil.class); + + /** + * Yaml to object t. + * + * @param the type parameter + * @param yamlContent the yaml content + * @param typClass the typ class + * @return the t + */ + public T yamlToObject(String yamlContent, Class typClass) { + Constructor constructor = getConstructor(typClass); + constructor.setPropertyUtils(getPropertyUtils()); + TypeDescription yamlFileDescription = new TypeDescription(typClass); + constructor.addTypeDescription(yamlFileDescription); + Yaml yaml = new Yaml(constructor); + T yamlObj = (T) yaml.load(yamlContent); + yamlObj.toString(); + return yamlObj; + } + + /** + * Yaml to object t. + * + * @param the type parameter + * @param yamlContent the yaml content + * @param typClass the typ class + * @return the t + */ + public T yamlToObject(InputStream yamlContent, Class typClass) { + try { + Constructor constructor = getConstructor(typClass); + constructor.setPropertyUtils(getPropertyUtils()); + TypeDescription yamlFileDescription = new TypeDescription(typClass); + constructor.addTypeDescription(yamlFileDescription); + Yaml yaml = new Yaml(constructor); + T yamlObj = (T) yaml.load(yamlContent); + if (yamlObj != null) { + yamlObj.toString(); + return yamlObj; + } else { + throw new RuntimeException(); + } + } catch (Exception exception) { + logger.error("Error will trying to convert yaml to object:" + exception.getMessage()); + throw new RuntimeException(exception); + } finally { + try { + if (yamlContent != null) { + yamlContent.close(); + } + } catch (IOException ignore) { + //nothing to dd + } + } + } + + + /** + * Gets constructor. + * + * @param the type parameter + * @param typClass the typ class + * @return the constructor + */ + public Constructor getConstructor(Class typClass) { + return new StrictMapAppenderConstructor(typClass); + } + + /** + * Gets property utils. + * + * @return the property utils + */ + protected PropertyUtils getPropertyUtils() { + return new MyPropertyUtils(); + } + + /** + * Yaml to map map. + * + * @param yamlContent the yaml content + * @return the map + */ + public Map> yamlToMap(InputStream yamlContent) { + Yaml yaml = new Yaml(); + Map> yamlData = + (Map>) yaml.load(yamlContent); + return yamlData; + } + + /** + * Object to yaml string. + * + * @param the type parameter + * @param obj the obj + * @return the string + */ + public String objectToYaml(Object obj) { + DumperOptions options = new DumperOptions(); + options.setPrettyFlow(true); + options.setDefaultFlowStyle(DumperOptions.FlowStyle.BLOCK); + Representer representer = new CustomRepresenter(); + representer.addClassTag(obj.getClass(), Tag.MAP); + representer.setPropertyUtils(new MyPropertyUtils()); + + Yaml yaml = new Yaml(representer, options); + return yaml.dump(obj); + } + + /** + * Load yaml file is input stream. + * + * @param yamlFullFileName the yaml full file name + * @return the input stream + */ + public InputStream loadYamlFileIs(String yamlFullFileName) { + return CommonMethods.class.getResourceAsStream(yamlFullFileName); + } + + /** + * Is yaml file content valid boolean. + * + * @param yamlFullFileName the yaml full file name + * @return the boolean + */ + public boolean isYamlFileContentValid(String yamlFullFileName) { + Yaml yaml = new Yaml(); + try { + Object loadResult = yaml.load(yamlFullFileName); + if (loadResult == null) { + return false; + } + return true; + } catch (Exception exception) { + return false; + } + } + + + private class CustomRepresenter extends Representer { + @Override + protected NodeTuple representJavaBeanProperty(Object javaBean, Property property, + Object propertyValue, Tag customTag) { + if (propertyValue == null) { + return null; + } else { + NodeTuple defaultNode = + super.representJavaBeanProperty(javaBean, property, propertyValue, customTag); + + return property.getName().equals("_default") + ? new NodeTuple(representData("default"), defaultNode.getValueNode()) + : defaultNode; + } + } + + @Override + protected MappingNode representJavaBean(Set properties, Object javaBean) { + //remove the bean type from the output yaml (!! ...) + if (!classTags.containsKey(javaBean.getClass())) { + addClassTag(javaBean.getClass(), Tag.MAP); + } + + return super.representJavaBean(properties, javaBean); + } + } + + + /** + * The type My property utils. + */ + public class MyPropertyUtils extends PropertyUtils { + @Override + public Property getProperty(Class type, String name) throws IntrospectionException { + if (name.equals("default")) { + name = "_default"; + } + return super.getProperty(type, name); + } + + //Unsorted properties + @Override + protected Set createPropertySet(Class type, BeanAccess beanAccess) + throws IntrospectionException { + return new LinkedHashSet(getPropertiesMap(type, + BeanAccess.FIELD).values()); + } + + } + + /** + * The type Strict map appender constructor. + */ + protected class StrictMapAppenderConstructor extends Constructor { + + /** + * Instantiates a new Strict map appender constructor. + * + * @param theRoot the the root + */ + public StrictMapAppenderConstructor(Class theRoot) { + super(theRoot); + } + + @Override + protected Map constructMapping(MappingNode node) { + try { + return super.constructMapping(node); + } catch (IllegalStateException exception) { + throw new ParserException("while parsing MappingNode", node.getStartMark(), + exception.getMessage(), node.getEndMark()); + } + } + + @Override + protected Map createDefaultMap() { + final Map delegate = super.createDefaultMap(); + return new AbstractMap() { + @Override + public Object put(Object key, Object value) { + if (delegate.containsKey(key)) { + throw new IllegalStateException("duplicate key: " + key); + } + return delegate.put(key, value); + } + + @Override + public Set> entrySet() { + return delegate.entrySet(); + } + }; + } + } +} + + + diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/test/java/org/openecomp/core/utilities/json/JsonSchemaDataGeneratorTest.java b/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/test/java/org/openecomp/core/utilities/json/JsonSchemaDataGeneratorTest.java new file mode 100644 index 0000000000..83c87737d2 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/test/java/org/openecomp/core/utilities/json/JsonSchemaDataGeneratorTest.java @@ -0,0 +1,50 @@ +package org.openecomp.core.utilities.json; + +import org.openecomp.core.utilities.file.FileUtils; +import org.json.JSONException; +import org.json.JSONObject; +import org.testng.Assert; +import org.testng.annotations.Test; + +public class JsonSchemaDataGeneratorTest { + + public static final String SCHEMA_WITHOUT_DEFAULTS = new String( + FileUtils.toByteArray(FileUtils.getFileInputStream("jsonUtil/json_schema/aSchema.json"))); + public static final String SCHEMA_WITH_REFS_AND_DEFAULTS = new String(FileUtils.toByteArray( + FileUtils.getFileInputStream("jsonUtil/json_schema/schemaWithRefsAndDefaults.json"))); + public static final String SCHEMA_WITH_INVALID_DEFAULT = new String(FileUtils.toByteArray( + FileUtils.getFileInputStream("jsonUtil/json_schema/schemaWithInvalidDefault.json"))); + public static final String SCHEMA_NIC = new String( + FileUtils.toByteArray(FileUtils.getFileInputStream("jsonUtil/json_schema/nicSchema.json"))); + + @Test + public void testSchemaWithoutDefaults() { + testGenerate(SCHEMA_WITHOUT_DEFAULTS, new JSONObject()); + } + + @Test + public void testSchemaWithRefsAndDefaults() { + testGenerate(SCHEMA_WITH_REFS_AND_DEFAULTS, + new JSONObject( + "{\"cityOfBirth\":\"Tel Aviv\",\"address\":{\"city\":\"Tel Aviv\"},\"phoneNumber\":[{\"code\":1,\"location\":\"Home\"},{\"code\":2,\"location\":\"Office\"}]}")); + } + + @Test(expectedExceptions = JSONException.class) + public void testSchemaWithInvalidDefault() { + testGenerate(SCHEMA_WITH_INVALID_DEFAULT, null); + } + + @Test + public void testNicQuestionnaireSchema() { + testGenerate(SCHEMA_NIC, + new JSONObject("{\"ipConfiguration\":{\"ipv4Required\":true,\"ipv6Required\":false}}")); + } + + private void testGenerate(String schema, JSONObject expectedData) { + JsonSchemaDataGenerator jsonSchemaDataGenerator = new JsonSchemaDataGenerator(schema); + String data = jsonSchemaDataGenerator.generateData(); + System.out.println(data); + JSONObject dataJson = new JSONObject(data); + Assert.assertTrue(expectedData.similar(dataJson)); + } +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/test/java/org/openecomp/core/utilities/json/JsonUtilTest.java b/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/test/java/org/openecomp/core/utilities/json/JsonUtilTest.java new file mode 100644 index 0000000000..e232f72f38 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/test/java/org/openecomp/core/utilities/json/JsonUtilTest.java @@ -0,0 +1,40 @@ +package org.openecomp.core.utilities.json; + + +import org.openecomp.core.utilities.file.FileUtils; +import org.testng.Assert; +import org.testng.annotations.Test; + +import java.util.List; + +public class JsonUtilTest { + + @Test + public void testValidJsonValidate() throws Exception { + String json = + new String(FileUtils.toByteArray(FileUtils.getFileInputStream("jsonUtil/json/a.json"))); + String jsonSchema = new String( + FileUtils.toByteArray(FileUtils.getFileInputStream("jsonUtil/json_schema/aSchema.json"))); + + List validationErrors = JsonUtil.validate(json, jsonSchema); + Assert.assertNull(validationErrors); + } + + @Test + public void testInValidJsonValidate() throws Exception { + String json = new String( + FileUtils.toByteArray(FileUtils.getFileInputStream("jsonUtil/json/a_invalid.json"))); + String jsonSchema = new String( + FileUtils.toByteArray(FileUtils.getFileInputStream("jsonUtil/json_schema/aSchema.json"))); + + List validationErrors = JsonUtil.validate(json, jsonSchema); + Assert.assertNotNull(validationErrors); + Assert.assertEquals(validationErrors.size(), 3); + Assert.assertEquals(validationErrors.get(0), + "#/cityOfBirth: Paris is not a valid value. Possible values: New York,Tel Aviv,London"); + Assert.assertEquals(validationErrors.get(1), + "#/address: {\"streetAddress\":\"21 2nd Street\",\"city\":\"Paris\"} is not a valid value. {\"streetAddress\":\"21 2nd Street\",\"city\":\"New York\"} is the only possible value for this field"); + Assert.assertEquals(validationErrors.get(2), + "#/phoneNumber/0/code: expected type: Number, found: String"); + } +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/test/resources/jsonUtil/json/a.json b/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/test/resources/jsonUtil/json/a.json new file mode 100644 index 0000000000..a3320d5fc7 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/test/resources/jsonUtil/json/a.json @@ -0,0 +1,12 @@ +{ + "address": { + "streetAddress": "21 2nd Street", + "city": "New York" + }, + "phoneNumber": [ + { + "location": "home", + "code": 44 + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/test/resources/jsonUtil/json/a_invalid.json b/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/test/resources/jsonUtil/json/a_invalid.json new file mode 100644 index 0000000000..8a02522ea9 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/test/resources/jsonUtil/json/a_invalid.json @@ -0,0 +1,13 @@ +{ + "address": { + "streetAddress": "21 2nd Street", + "city": "Paris" + }, + "phoneNumber": [ + { + "location": "home", + "code": "test" + } + ], + "cityOfBirth": "Paris" +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/test/resources/jsonUtil/json_schema/aSchema.json b/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/test/resources/jsonUtil/json_schema/aSchema.json new file mode 100644 index 0000000000..a77e38df87 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/test/resources/jsonUtil/json_schema/aSchema.json @@ -0,0 +1,60 @@ +{ + "$schema": "http://json-schema.org/draft-04/schema#", + "type": "object", + "definitions": { + "city": { + "type": "string", + "enum": [ + "Tel Aviv", + "New York", + "London" + ] + } + }, + "properties": { + "address": { + "type": "object", + "properties": { + "streetAddress": { + "type": "string" + }, + "city": { + "$ref": "#/definitions/city" + } + }, + "enum": [ + { + "streetAddress": "21 2nd Street", + "city": "New York" + } + ], + "required": [ + "streetAddress", + "city" + ] + }, + "phoneNumber": { + "type": "array", + "items": { + "type": "object", + "properties": { + "location": { + "type": "string" + }, + "code": { + "type": "integer" + } + }, + "required": [ + "location", + "code" + ] + } + }, + "cityOfBirth" : { "$ref" : "#/definitions/city"} + }, + "required": [ + "address", + "phoneNumber" + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/test/resources/jsonUtil/json_schema/nicSchema.json b/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/test/resources/jsonUtil/json_schema/nicSchema.json new file mode 100644 index 0000000000..d96de6aa31 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/test/resources/jsonUtil/json_schema/nicSchema.json @@ -0,0 +1,118 @@ +{ + "$schema": "http://json-schema.org/draft-04/schema#", + "type": "object", + "properties": { + "protocols": { + "type": "object", + "properties": { + "protocols": { + "type": "array", + "items": { + "type": "string", + "enum": [ + "TCP", + "UDP", + "SCTP", + "IPsec" + ] + }, + "minItems": 1 + }, + "protocolWithHighestTrafficProfile": { + "$ref": "#/properties/protocols/properties/protocols/items" + } + }, + "additionalProperties": false + }, + "ipConfiguration": { + "type": "object", + "properties": { + "ipv4Required": { + "type": "boolean", + "default": true + }, + "ipv6Required": { + "type": "boolean", + "default": false + } + }, + "additionalProperties": false + }, + "network": { + "type": "object", + "properties": { + "networkDescription": { + "type": "string", + "pattern": "[A-Za-z]+", + "maxLength": 300 + } + }, + "additionalProperties": false + }, + "sizing": { + "type": "object", + "definitions": { + "peakAndAvg": { + "type": "object", + "properties": { + "peak": { + "type": "number" + }, + "avg": { + "type": "number" + } + }, + "additionalProperties": false + }, + "packetsAndBytes": { + "type": "object", + "properties": { + "packets": { + "$ref": "#/properties/sizing/definitions/peakAndAvg" + }, + "bytes": { + "$ref": "#/properties/sizing/definitions/peakAndAvg" + } + }, + "additionalProperties": false + } + }, + "properties": { + "describeQualityOfService": { + "type": "string" + }, + "inflowTrafficPerSecond": { + "$ref": "#/properties/sizing/definitions/packetsAndBytes" + }, + "outflowTrafficPerSecond": { + "$ref": "#/properties/sizing/definitions/packetsAndBytes" + }, + "flowLength": { + "$ref": "#/properties/sizing/definitions/packetsAndBytes" + }, + "acceptableJitter": { + "type": "object", + "properties": { + "mean": { + "type": "number" + }, + "max": { + "type": "number" + }, + "variable": { + "type": "number" + } + }, + "additionalProperties": false + }, + "acceptablePacketLoss": { + "type": "number", + "minimum": 0, + "maximum": 100 + } + }, + "additionalProperties": false + } + }, + "additionalProperties": false +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/test/resources/jsonUtil/json_schema/schemaWithInvalidDefault.json b/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/test/resources/jsonUtil/json_schema/schemaWithInvalidDefault.json new file mode 100644 index 0000000000..100d17f48e --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/test/resources/jsonUtil/json_schema/schemaWithInvalidDefault.json @@ -0,0 +1,67 @@ +{ + "$schema": "http://json-schema.org/draft-04/schema#", + "definitions": { + "city": { + "type": "string", + "enum": [ + "Tel Aviv", + "New York", + "London" + ], + "default": "Tel Aviv" + } + }, + "type": "object", + "properties": { + "address": { + "type": "object", + "properties": { + "streetAddress": { + "type": "string", + "default" : 7 + }, + "city": { + "$ref": "#/definitions/city" + } + }, + "required": [ + "streetAddress", + "city" + ] + }, + "phoneNumber": { + "type": "array", + "items": { + "type": "object", + "properties": { + "location": { + "type": "string" + }, + "code": { + "type": "integer", + "default": 777 + } + }, + "required": [ + "location", + "code" + ] + }, + "default": [ + { + "location": "Home", + "code": 1 + }, + { + "location": "Office", + "code": 2 + } + ] + }, + "cityOfBirth" : { "$ref" : "#/definitions/city"} + }, + "required": [ + "address", + "phoneNumber" + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/test/resources/jsonUtil/json_schema/schemaWithRefsAndDefaults.json b/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/test/resources/jsonUtil/json_schema/schemaWithRefsAndDefaults.json new file mode 100644 index 0000000000..de027b9d56 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/openecomp-utilities-lib/src/test/resources/jsonUtil/json_schema/schemaWithRefsAndDefaults.json @@ -0,0 +1,71 @@ +{ + "$schema": "http://json-schema.org/draft-04/schema#", + "definitions": { + "city": { + "type": "string", + "enum": [ + "Tel Aviv", + "New York", + "London" + ], + "default": "Tel Aviv" + }, + "zipCode" : { + "type" : "integer" + } + }, + "type": "object", + "properties": { + "address": { + "type": "object", + "properties": { + "streetAddress": { + "type": "string" + }, + "city": { + "$ref": "#/definitions/city" + }, + "cityZipCode" : {"$ref" : "#/definitions/zipCode"} + }, + "required": [ + "streetAddress", + "city" + ] + }, + "phoneNumber": { + "type": "array", + "items": { + "type": "object", + "properties": { + "location": { + "type": "string" + }, + "locationZipCode" : {"$ref" : "#/definitions/zipCode"}, + "code": { + "type": "integer", + "default": 777 + } + }, + "required": [ + "location", + "code" + ] + }, + "default": [ + { + "location": "Home", + "code": 1 + }, + { + "location": "Office", + "code": 2 + } + ] + }, + "cityOfBirth" : { "$ref" : "#/definitions/city"} + }, + "required": [ + "address", + "phoneNumber" + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-core-lib/pom.xml b/openecomp-be/lib/openecomp-core-lib/pom.xml new file mode 100644 index 0000000000..312b085424 --- /dev/null +++ b/openecomp-be/lib/openecomp-core-lib/pom.xml @@ -0,0 +1,23 @@ + + 4.0.0 + + + openecomp-sdc-lib + org.openecomp.sdc + 1.0.0-SNAPSHOT + + + org.openecomp.core + openecomp-core-lib + openecomp-core-lib + + pom + + + /openecomp-facade-lib + /openecomp-nosqldb-lib + /openecomp-utilities-lib + /openecomp-config-lib + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-heat-lib/pom.xml b/openecomp-be/lib/openecomp-heat-lib/pom.xml new file mode 100644 index 0000000000..47c7c728a0 --- /dev/null +++ b/openecomp-be/lib/openecomp-heat-lib/pom.xml @@ -0,0 +1,59 @@ + + 4.0.0 + + + + openecomp-sdc-lib + org.openecomp.sdc + 1.0.0-SNAPSHOT + + + openecomp-heat-lib + org.openecomp.core + openecomp-heat-lib + + + + org.yaml + snakeyaml + 1.17 + test + + + org.openecomp.core + openecomp-utilities-lib + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-datatypes-lib + ${project.version} + + + org.openecomp.core + openecomp-common-lib + ${project.version} + + + ch.qos.logback + logback-classic + 1.1.2 + + + junit + junit + RELEASE + test + + + org.openecomp.sdc + openecomp-sdc-validation-api + ${project.version} + + + + + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/DefinedHeatParameterTypes.java b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/DefinedHeatParameterTypes.java new file mode 100644 index 0000000000..62364e7a11 --- /dev/null +++ b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/DefinedHeatParameterTypes.java @@ -0,0 +1,110 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.heat.datatypes; + +import org.apache.commons.lang.math.NumberUtils; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.Objects; + +public enum DefinedHeatParameterTypes { + NUMBER("number"), + STRING("string"), + COMMA_DELIMITED_LIST("comma_delimited_list"), + JSON("json"), + BOOLEAN("boolean"); + // TODO : ASK SEGEV ABOUT STRING + + private static Map stringToDefinedType = new HashMap<>(); + + static { + stringToDefinedType = new HashMap<>(); + for (DefinedHeatParameterTypes definedHeatParameterType : DefinedHeatParameterTypes.values()) { + stringToDefinedType.put(definedHeatParameterType.type, definedHeatParameterType); + } + } + + private String type; + + DefinedHeatParameterTypes(String type) { + this.type = type; + } + + public static DefinedHeatParameterTypes findByHeatResource(String type) { + return stringToDefinedType.get(type); + } + + /** + * Is value is from given type boolean. + * + * @param value the value + * @param parameterType the parameter type + * @return the boolean + */ + public static boolean isValueIsFromGivenType(Object value, String parameterType) { + DefinedHeatParameterTypes definedType = findByHeatResource(parameterType); + + if (Objects.nonNull(definedType)) { + switch (definedType) { + case NUMBER: + return NumberUtils.isNumber(String.valueOf(value)); + + case BOOLEAN: + return HeatBoolean.isValueBoolean(value); + + case COMMA_DELIMITED_LIST: + String valAsString = String.valueOf(value); + return valAsString.split(",") instanceof String[]; + + case JSON: + return (value instanceof Map) || (value instanceof List); + + case STRING: + //return value instanceof String; + return true; + + default: + // return false; + } + } + + return false; + } + + public static boolean isNovaServerEnvValueIsFromRightType(Object value) { + return isValueIsFromGivenType(value, COMMA_DELIMITED_LIST.getType()) + || isValueIsFromGivenType(value, STRING.getType()); + } + + public static boolean isEmptyValueInEnv(Object value) { + return Objects.isNull(value); + } + + public String getType() { + return type; + } + + public void setType(String type) { + this.type = type; + } +} diff --git a/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/HeatBoolean.java b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/HeatBoolean.java new file mode 100644 index 0000000000..249dcaf4a5 --- /dev/null +++ b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/HeatBoolean.java @@ -0,0 +1,96 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.heat.datatypes; + +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; +import org.openecomp.sdc.heat.services.ErrorCodes; + +import java.util.HashSet; +import java.util.Set; + +public class HeatBoolean { + + private static Set heatFalse; + private static Set heatTrue; + + static { + + + heatFalse = new HashSet<>(); + heatFalse.add("f"); + heatFalse.add(false); + heatFalse.add("false"); + heatFalse.add("off"); + heatFalse.add("n"); + heatFalse.add("no"); + heatFalse.add(0); + + heatTrue = new HashSet<>(); + heatTrue.add("t"); + heatTrue.add(true); + heatTrue.add("true"); + heatTrue.add("on"); + heatTrue.add("y"); + heatTrue.add("yes"); + heatTrue.add(1); + + } + + /** + * Eval boolean. + * + * @param value the value + * @return the boolean + */ + public static Boolean eval(Object value) { + + if (value instanceof String) { + value = (String) ((String) value).toLowerCase(); + } + if (heatFalse.contains(value)) { + return false; + } else if (heatTrue.contains(value)) { + return true; + } else { + throw new CoreException((new ErrorCode.ErrorCodeBuilder()).withId(ErrorCodes.INVALID_BOOLEAN) + .withCategory(ErrorCategory.APPLICATION) + .withMessage("Invalid boolean value [" + value + "].").build()); + } + + } + + /** + * Is value boolean boolean. + * + * @param value the value + * @return the boolean + */ + public static boolean isValueBoolean(Object value) { + try { + Boolean answer = eval(value); + return true; + } catch (CoreException ce) { + return false; + } + } +} diff --git a/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/manifest/FileData.java b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/manifest/FileData.java new file mode 100644 index 0000000000..728b714868 --- /dev/null +++ b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/manifest/FileData.java @@ -0,0 +1,107 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.heat.datatypes.manifest; + +import java.util.Arrays; +import java.util.HashSet; +import java.util.List; +import java.util.Set; +import java.util.function.Predicate; + +public class FileData { + + public static Set heatFileTypes = + new HashSet<>(Arrays.asList(Type.HEAT, Type.HEAT_NET, Type.HEAT_VOL)); + private Boolean isBase; + private String file; + private Type type; + private List data; + + public static Predicate buildFileDataPredicateByType(Type... types) { + return fileData -> Arrays.asList(types).contains(fileData.getType()); + } + + public static boolean isHeatFile(Type type) { + return heatFileTypes.contains(type); + } + + public Boolean getBase() { + return isBase; + } + + public void setBase(Boolean base) { + isBase = base; + } + + public String getFile() { + return file; + } + + public void setFile(String file) { + this.file = file; + } + + public Type getType() { + return type; + } + + public void setType(Type type) { + this.type = type; + } + + public List getData() { + return data; + } + + public void setData(List data) { + this.data = data; + } + + public enum Type { + + HEAT("HEAT"), + HEAT_ENV("HEAT_ENV"), + HEAT_NET("HEAT_NET"), + HEAT_VOL("HEAT_VOL"), + CHEF("CHEF"), + PUPPET("PUPPET"), + SHELL("SHELL"), + YANG("YANG"), + YANG_XML("YANG_XML"), + BPEL("BPEL"), + DG_XML("DG_XML"), + MURANO_PKG("MURANO_PKG"), + VENDOR_LICENSE("VENDOR_LICENSE"), + VF_LICENSE("VF_LICENSE"), + OTHER("OTHER"); + + private String displayName; + + Type(String displayName) { + this.displayName = displayName; + } + + public String getDisplayName() { + return displayName; + } + + } +} diff --git a/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/manifest/ManifestContent.java b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/manifest/ManifestContent.java new file mode 100644 index 0000000000..d89717125a --- /dev/null +++ b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/manifest/ManifestContent.java @@ -0,0 +1,63 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.heat.datatypes.manifest; + +import java.util.List; + +public class ManifestContent { + + String name; + String description; + String version; + List data; + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public String getVersion() { + return version; + } + + public void setVersion(String version) { + this.version = version; + } + + public List getData() { + return data; + } + + public void setData(List data) { + this.data = data; + } +} diff --git a/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/manifest/ManifestFile.java b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/manifest/ManifestFile.java new file mode 100644 index 0000000000..607f52a86d --- /dev/null +++ b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/manifest/ManifestFile.java @@ -0,0 +1,43 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.heat.datatypes.manifest; + +public class ManifestFile { + + String name; + ManifestContent content; + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public ManifestContent getContent() { + return content; + } + + public void setContent(ManifestContent content) { + this.content = content; + } +} diff --git a/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/Constraint.java b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/Constraint.java new file mode 100644 index 0000000000..8aad825055 --- /dev/null +++ b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/Constraint.java @@ -0,0 +1,78 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.heat.datatypes.model; + +import java.util.ArrayList; +import java.util.List; + +public class Constraint { + private Object[] length; + private Integer[] range; + private List valid_values; + private String pattern; + + public Constraint() { + } + + public Integer[] getRange() { + return range; + } + + public void setRange(Integer[] inRange) { + this.range = new Integer[]{inRange[0], inRange[1]}; + } + + public List getValid_values() { + return valid_values; + } + + public void setValid_values(List validValues) { + this.valid_values = validValues; + } + + /** + * Add valid value. + * + * @param validValue the valid value + */ + public void addValidValue(Object validValue) { + if (this.valid_values == null) { + this.valid_values = new ArrayList<>(); + } + valid_values.add(validValue); + } + + public Object[] getLength() { + return length; + } + + public void setLength(Object[] length) { + this.length = length; + } + + public String getPattern() { + return pattern; + } + + public void setPattern(String pattern) { + this.pattern = pattern; + } +} diff --git a/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/Environment.java b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/Environment.java new file mode 100644 index 0000000000..b2f45d06d9 --- /dev/null +++ b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/Environment.java @@ -0,0 +1,35 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.heat.datatypes.model; + +import java.util.Map; + +public class Environment { + Map parameters; + + public Map getParameters() { + return parameters; + } + + public void setParameters(Map parameters) { + this.parameters = parameters; + } +} diff --git a/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/GroupTypeValues.java b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/GroupTypeValues.java new file mode 100644 index 0000000000..84259b1807 --- /dev/null +++ b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/GroupTypeValues.java @@ -0,0 +1,49 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.heat.datatypes.model; + +import java.util.ArrayList; +import java.util.List; + +public enum GroupTypeValues { + EXCLUSIVITY("exclusivity"), + AFFINITY("affinity"), + DIVERSITY("diversity"); + + private static List groupTypeAsStrings; + + static { + groupTypeAsStrings = new ArrayList<>(); + for (GroupTypeValues attGroupTypeValue : GroupTypeValues.values()) { + groupTypeAsStrings.add(attGroupTypeValue.groupTypeValue); + } + } + + private String groupTypeValue; + + GroupTypeValues(String groupTypeValue) { + this.groupTypeValue = groupTypeValue; + } + + public static boolean isGroupTypeValid(String groupType) { + return groupTypeAsStrings.contains(groupType); + } +} diff --git a/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/HeatOrchestrationTemplate.java b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/HeatOrchestrationTemplate.java new file mode 100644 index 0000000000..4170d35d7a --- /dev/null +++ b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/HeatOrchestrationTemplate.java @@ -0,0 +1,90 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.heat.datatypes.model; + +import java.util.List; +import java.util.Map; + +public class HeatOrchestrationTemplate { + String heat_template_version; + String description; + List parameter_groups; + Map parameters; + Map resources; + Map outputs; + Map conditions; + + public String getHeat_template_version() { + return heat_template_version; + } + + public void setHeat_template_version(String heatTemplateVersion) { + this.heat_template_version = heatTemplateVersion; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public List getParameter_groups() { + return parameter_groups; + } + + public void setParameter_groups(List parameterGroups) { + this.parameter_groups = parameterGroups; + } + + public Map getParameters() { + return parameters; + } + + public void setParameters(Map parameters) { + this.parameters = parameters; + } + + public Map getResources() { + return resources; + } + + public void setResources(Map resources) { + this.resources = resources; + } + + public Map getOutputs() { + return outputs; + } + + public void setOutputs(Map outputs) { + this.outputs = outputs; + } + + public Map getConditions() { + return conditions; + } + + public void setConditions(Map conditions) { + this.conditions = conditions; + } +} diff --git a/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/HeatPseudoParameters.java b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/HeatPseudoParameters.java new file mode 100644 index 0000000000..c822a78a93 --- /dev/null +++ b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/HeatPseudoParameters.java @@ -0,0 +1,61 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.heat.datatypes.model; + +import java.util.ArrayList; +import java.util.List; + +public enum HeatPseudoParameters { + OS_STACK_NAME("OS::stack_name"), + OS_STACK_ID("OS::stack_id"), + OS_PROJECT_ID("OS::project_id"); + + private static List pseudoParameterNames; + + static { + pseudoParameterNames = new ArrayList<>(); + for (HeatPseudoParameters parameter : HeatPseudoParameters.values()) { + pseudoParameterNames.add(parameter.getPseudoParameter()); + } + } + + private String pseudoParameter; + + HeatPseudoParameters(String pseudoParameter) { + this.pseudoParameter = pseudoParameter; + } + + public static List getPseudoParameterNames() { + return pseudoParameterNames; + } + + public static void setPseudoParameterNames(List pseudoParameterNames) { + HeatPseudoParameters.pseudoParameterNames = pseudoParameterNames; + } + + public String getPseudoParameter() { + return pseudoParameter; + } + + public void setPseudoParameter(String pseudoParameter) { + this.pseudoParameter = pseudoParameter; + } +} diff --git a/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/HeatResourcesTypes.java b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/HeatResourcesTypes.java new file mode 100644 index 0000000000..d4adfe7d32 --- /dev/null +++ b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/HeatResourcesTypes.java @@ -0,0 +1,206 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.heat.datatypes.model; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.Objects; + +/** + * The enum Heat resources types. + */ +public enum HeatResourcesTypes { + /** + * Nova server resource type heat resources types. + */ + NOVA_SERVER_RESOURCE_TYPE("OS::Nova::Server"), + /** + * Nova server group resource type heat resources types. + */ + NOVA_SERVER_GROUP_RESOURCE_TYPE("OS::Nova::ServerGroup"), + /** + * Neutron port resource type heat resources types. + */ + NEUTRON_PORT_RESOURCE_TYPE("OS::Neutron::Port"), + /** + * Contrail network rule resource type heat resources types. + */ + CONTRAIL_NETWORK_RULE_RESOURCE_TYPE("OS::Contrail::NetworkPolicy"), + /** + * Contrail network attach rule resource type heat resources types. + */ + CONTRAIL_NETWORK_ATTACH_RULE_RESOURCE_TYPE("OS::Contrail::AttachPolicy"), + /** + * Contrail virtual network resource type heat resources types. + */ + CONTRAIL_VIRTUAL_NETWORK_RESOURCE_TYPE("OS::Contrail::VirtualNetwork"), + /** + * Cinder volume resource type heat resources types. + */ + CINDER_VOLUME_RESOURCE_TYPE("OS::Cinder::Volume"), + /** + * Cinder volume attachment resource type heat resources types. + */ + CINDER_VOLUME_ATTACHMENT_RESOURCE_TYPE("OS::Cinder::VolumeAttachment"), + /** + * Neutron net resource type heat resources types. + */ + NEUTRON_NET_RESOURCE_TYPE("OS::Neutron::Net"), + /** + * Neutron subnet resource type heat resources types. + */ + NEUTRON_SUBNET_RESOURCE_TYPE("OS::Neutron::Subnet"), + /** + * Neutron security group resource type heat resources types. + */ + NEUTRON_SECURITY_GROUP_RESOURCE_TYPE("OS::Neutron::SecurityGroup"), + /** + * Heat software config type heat resources types. + */ + HEAT_SOFTWARE_CONFIG_TYPE("OS::Heat::SoftwareConfig"), + /** + * Heat cloud config type heat resources types. + */ + HEAT_CLOUD_CONFIG_TYPE("OS::Heat::CloudConfig"), + /** + * Heat multipart mime type heat resources types. + */ + HEAT_MULTIPART_MIME_TYPE("OS::Heat::MultipartMime"), + /** + * Heat contrail network ipam type heat resources types. + */ + HEAT_CONTRAIL_NETWORK_IPAM_TYPE("OS::Contrail::NetworkIpam"), + /** + * Contrail v 2 virtual network resource type heat resources types. + */ + CONTRAIL_V2_VIRTUAL_NETWORK_RESOURCE_TYPE("OS::ContrailV2::VirtualNetwork"), + /** + * Contrail v 2 virtual machine interface resource type heat resources types. + */ + CONTRAIL_V2_VIRTUAL_MACHINE_INTERFACE_RESOURCE_TYPE("OS::ContrailV2::VirtualMachineInterface"), + /** + * Contrail service template heat resources types. + */ + CONTRAIL_SERVICE_TEMPLATE("OS::Contrail::ServiceTemplate"), + /** + * Contrail service instance heat resources types. + */ + CONTRAIL_SERVICE_INSTANCE("OS::Contrail::ServiceInstance"), + /** + * Contrail v 2 network rule resource type heat resources types. + */ + CONTRAIL_V2_NETWORK_RULE_RESOURCE_TYPE("OS::ContrailV2::NetworkPolicy"), + /** + * Resource group resource type heat resources types. + */ + RESOURCE_GROUP_RESOURCE_TYPE("OS::Heat::ResourceGroup"); + + private static Map stringToHeatResourceTypeMap; + + static { + stringToHeatResourceTypeMap = new HashMap<>(); + + for (HeatResourcesTypes type : HeatResourcesTypes.values()) { + stringToHeatResourceTypeMap.put(type.heatResource, type); + } + } + + private String heatResource; + + + HeatResourcesTypes(String heatResource) { + this.heatResource = heatResource; + } + + /** + * Find by heat resource heat resources types. + * + * @param heatResource the heat resource + * @return the heat resources types + */ + public static HeatResourcesTypes findByHeatResource(String heatResource) { + return stringToHeatResourceTypeMap.get(heatResource); + } + + /** + * Is resource type valid boolean. + * + * @param resourceType the resource type + * @return the boolean + */ + public static boolean isResourceTypeValid(String resourceType) { + return Objects.nonNull(findByHeatResource(resourceType)); + } + + /** + * Is resource expected to be exposed boolean. + * + * @param resourceType the resource type + * @return the boolean + */ + public static boolean isResourceExpectedToBeExposed(String resourceType) { + return (resourceType.equals(NOVA_SERVER_GROUP_RESOURCE_TYPE.getHeatResource()) + || resourceType.equals(CONTRAIL_VIRTUAL_NETWORK_RESOURCE_TYPE.getHeatResource()) + || resourceType.equals(NEUTRON_NET_RESOURCE_TYPE.getHeatResource()) + || resourceType.equals(CINDER_VOLUME_RESOURCE_TYPE.getHeatResource()) + || resourceType.equals(NEUTRON_SECURITY_GROUP_RESOURCE_TYPE.getHeatResource()) + ); + } + + /** + * Gets list for resource type. + * + * @param types the types + * @return the list for resource type + */ + public static Map> getListForResourceType( + HeatResourcesTypes... types) { + Map> result = new HashMap<>(); + + for (HeatResourcesTypes type : types) { + result.put(type, new ArrayList<>()); + } + + return result; + } + + /** + * Gets heat resource. + * + * @return the heat resource + */ + public String getHeatResource() { + + return heatResource; + } + + /** + * Sets heat resource. + * + * @param heatResource the heat resource + */ + public void setHeatResource(String heatResource) { + this.heatResource = heatResource; + } + +} diff --git a/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/Output.java b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/Output.java new file mode 100644 index 0000000000..8222edded2 --- /dev/null +++ b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/Output.java @@ -0,0 +1,42 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.heat.datatypes.model; + +public class Output { + String description; + Object value; + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public Object getValue() { + return value; + } + + public void setValue(Object value) { + this.value = value; + } +} diff --git a/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/Parameter.java b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/Parameter.java new file mode 100644 index 0000000000..63681cc80c --- /dev/null +++ b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/Parameter.java @@ -0,0 +1,90 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.heat.datatypes.model; + +import java.util.List; +import java.util.Map; + +public class Parameter { + String type; + String label; + String description; + Object _default; + boolean hidden; + List> constraints; + boolean immutable; + + public String getType() { + return type; + } + + public void setType(String type) { + this.type = type; + } + + public String getLabel() { + return label; + } + + public void setLabel(String label) { + this.label = label; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public Object get_default() { + return _default; + } + + public void set_default(Object defaultValue) { + this._default = defaultValue; + } + + public boolean isHidden() { + return hidden; + } + + public void setHidden(boolean hidden) { + this.hidden = hidden; + } + + public List> getConstraints() { + return constraints; + } + + public void setConstraints(List> constraints) { + this.constraints = constraints; + } + + public boolean isImmutable() { + return immutable; + } + + public void setImmutable(boolean immutable) { + this.immutable = immutable; + } +} diff --git a/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/ParameterGroup.java b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/ParameterGroup.java new file mode 100644 index 0000000000..8ab066f4a4 --- /dev/null +++ b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/ParameterGroup.java @@ -0,0 +1,53 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.heat.datatypes.model; + +import java.util.List; + +public class ParameterGroup { + String label; + String description; + List parameters; + + public String getLabel() { + return label; + } + + public void setLabel(String label) { + this.label = label; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public List getParameters() { + return parameters; + } + + public void setParameters(List parameters) { + this.parameters = parameters; + } +} diff --git a/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/ParameterType.java b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/ParameterType.java new file mode 100644 index 0000000000..37c430ec36 --- /dev/null +++ b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/ParameterType.java @@ -0,0 +1,42 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.heat.datatypes.model; + +public enum ParameterType { + + STRING("string"), + NUMBER("number"), + JSON("json"), + BOOLEAN("boolean"), + COMMA_DELIMITED_LIST("comma_delimited_list"); + + private String displayName; + + ParameterType(String displayName) { + this.displayName = displayName; + } + + public String getDisplayName() { + return displayName; + } + + +} diff --git a/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/PolicyTypes.java b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/PolicyTypes.java new file mode 100644 index 0000000000..3195e61fe5 --- /dev/null +++ b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/PolicyTypes.java @@ -0,0 +1,61 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.heat.datatypes.model; + +import java.util.HashMap; +import java.util.Map; +import java.util.Objects; + +public enum PolicyTypes { + AFFINITY("affinity"), + ANTI_AFFINITY("anti-affinity"); + + private static Map stringToPolicyTypesMap; + + static { + stringToPolicyTypesMap = new HashMap<>(); + for (PolicyTypes type : PolicyTypes.values()) { + stringToPolicyTypesMap.put(type.policy, type); + } + } + + private String policy; + + PolicyTypes(String policy) { + this.policy = policy; + } + + public static PolicyTypes findByPolicy(String policy) { + return stringToPolicyTypesMap.get(policy); + } + + public static boolean isGivenPolicyValid(String policyToCheck) { + return Objects.nonNull(findByPolicy(policyToCheck)); + } + + public String getPolicy() { + return policy; + } + + public void setPolicy(String policy) { + this.policy = policy; + } +} diff --git a/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/PropertiesMapKeyTypes.java b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/PropertiesMapKeyTypes.java new file mode 100644 index 0000000000..e8d43fc10c --- /dev/null +++ b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/PropertiesMapKeyTypes.java @@ -0,0 +1,42 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.heat.datatypes.model; + +public enum PropertiesMapKeyTypes { + IMAGE("image"), + FLAVOR("flavor"), + NETWORKS("networks"), + RESOURCE_DEF("resource_def"); + + private String keyMap; + + PropertiesMapKeyTypes(String keyMap) { + this.keyMap = keyMap; + } + + public String getKeyMap() { + return keyMap; + } + + public void setKeyMap(String keyMap) { + this.keyMap = keyMap; + } +} diff --git a/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/Resource.java b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/Resource.java new file mode 100644 index 0000000000..f4c3cd91cb --- /dev/null +++ b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/Resource.java @@ -0,0 +1,92 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.heat.datatypes.model; + +import java.util.Map; + +public class Resource { + String type; + Map properties; + Object metadata; + Object depends_on; + Object update_policy; + Object deletion_policy; + + public String getType() { + return type; + } + + public void setType(String type) { + this.type = type; + } + + public Map getProperties() { + return properties; + } + + public void setProperties(Map properties) { + this.properties = properties; + } + + public Object getMetadata() { + return metadata; + } + + public void setMetadata(Object metadata) { + this.metadata = metadata; + } + + public Object getDepends_on() { + return depends_on; + } + + public void setDepends_on(Object dependsOn) { + this.depends_on = dependsOn; + } + + public Object getUpdate_policy() { + return update_policy; + } + + public void setUpdate_policy(Object updatePolicy) { + this.update_policy = updatePolicy; + } + + public Object getDeletion_policy() { + return deletion_policy; + } + + public void setDeletion_policy(Object deletionPolicy) { + this.deletion_policy = deletionPolicy; + } + + @Override + public String toString() { + return "Resource{" + + "type='" + type + '\'' + + ", properties=" + properties + + ", metadata=" + metadata + + ", depends_on=" + depends_on + + ", update_policy='" + update_policy + '\'' + + ", deletion_policy='" + deletion_policy + '\'' + + '}'; + } +} diff --git a/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/ResourceReferenceFunctions.java b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/ResourceReferenceFunctions.java new file mode 100644 index 0000000000..b36d130597 --- /dev/null +++ b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/ResourceReferenceFunctions.java @@ -0,0 +1,44 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.heat.datatypes.model; + +public enum ResourceReferenceFunctions { + GET_RESOURCE("get_resource"), + GET_PARAM("get_param"), + GET_ATTR("get_attr"), + GET_FILE("get_file"), + SCHEDULER_HINTS("scheduler_hints"); + + + private String function; + + ResourceReferenceFunctions(String function) { + this.function = function; + } + + public String getFunction() { + return function; + } + + public void setFunction(String function) { + this.function = function; + } +} diff --git a/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/ResourceTypeToMessageString.java b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/ResourceTypeToMessageString.java new file mode 100644 index 0000000000..d7ede70942 --- /dev/null +++ b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/model/ResourceTypeToMessageString.java @@ -0,0 +1,55 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.heat.datatypes.model; + +import java.util.HashMap; +import java.util.Map; + +public enum ResourceTypeToMessageString { + SERVER_GROUP(HeatResourcesTypes.NOVA_SERVER_GROUP_RESOURCE_TYPE, "ServerGroup"), + SECURITY_GROUP(HeatResourcesTypes.NEUTRON_SECURITY_GROUP_RESOURCE_TYPE, "SecurityGroup"), + NETWORK_POLICY(HeatResourcesTypes.CONTRAIL_NETWORK_RULE_RESOURCE_TYPE, "NetworkPolicy"); + + private static Map resourcesTypesStringMap; + + static { + resourcesTypesStringMap = new HashMap<>(); + + for (ResourceTypeToMessageString resourceTypeToMessageString : ResourceTypeToMessageString + .values()) { + resourcesTypesStringMap + .put(resourceTypeToMessageString.type, resourceTypeToMessageString.messageString); + } + } + + private String messageString; + private HeatResourcesTypes type; + + + ResourceTypeToMessageString(HeatResourcesTypes type, String messgageString) { + this.type = type; + this.messageString = messgageString; + } + + public static String getTypeForMessageFromResourceType(HeatResourcesTypes type) { + return resourcesTypesStringMap.get(type); + } +} diff --git a/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/structure/Artifact.java b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/structure/Artifact.java new file mode 100644 index 0000000000..b5c263f545 --- /dev/null +++ b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/structure/Artifact.java @@ -0,0 +1,105 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.heat.datatypes.structure; + + +import org.openecomp.sdc.datatypes.error.ErrorMessage; +import org.openecomp.sdc.heat.datatypes.manifest.FileData; + +import java.util.ArrayList; +import java.util.List; + +public class Artifact implements Comparable { + + private String fileName; + private FileData.Type type; + private List errors; + + public Artifact(String fileName, FileData.Type type) { + this.fileName = fileName; + this.type = type; + } + + + public String getFileName() { + return fileName; + } + + public void setFileName(String name) { + this.fileName = name; + } + + + public FileData.Type getType() { + return type; + } + + public List getErrors() { + return errors; + } + + public void setErrors(List errors) { + this.errors = errors; + } + + /** + * Add error to error list. + * + * @param error the error + */ + public void addErrorToErrorList(ErrorMessage error) { + if (this.errors == null || this.errors.isEmpty()) { + this.errors = new ArrayList<>(); + } + + this.errors.add(error); + } + + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (obj == null || getClass() != obj.getClass()) { + return false; + } + + Artifact artifact = (Artifact) obj; + + if (!fileName.equals(artifact.fileName)) { + return false; + } + return true; + + } + + @Override + public int hashCode() { + int result = fileName.hashCode(); + return result; + } + + @Override + public int compareTo(Artifact artifact) { + return artifact.getFileName().compareTo(this.getFileName()); + } +} diff --git a/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/structure/HeatStructureTree.java b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/structure/HeatStructureTree.java new file mode 100644 index 0000000000..c86425fd43 --- /dev/null +++ b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/structure/HeatStructureTree.java @@ -0,0 +1,467 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.heat.datatypes.structure; + + +import org.codehaus.jackson.annotate.JsonProperty; +import org.openecomp.sdc.datatypes.error.ErrorMessage; +import org.openecomp.sdc.heat.datatypes.manifest.FileData; + +import java.util.ArrayList; +import java.util.List; +import java.util.Set; +import java.util.TreeSet; + +/** + * The type Heat structure tree. + */ +public class HeatStructureTree implements Comparable { + + private String fileName; + private FileData.Type type; + private Boolean isBase; + private HeatStructureTree env; + private List errors; + private Set HEAT; + private Set volume; + private Set network; + private Set nested; + private Set other; + private Set artifacts; + + /** + * Instantiates a new Heat structure tree. + */ + public HeatStructureTree() { + } + + ; + + /** + * Instantiates a new Heat structure tree. + * + * @param fileName the file name + * @param isBase the is base + */ + public HeatStructureTree(String fileName, boolean isBase) { + setBase(isBase); + setFileName(fileName); + } + + /** + * Gets heat structure tree by name. + * + * @param filesSet the files set + * @param filename the filename + * @return the heat structure tree by name + */ + public static HeatStructureTree getHeatStructureTreeByName(Set filesSet, + String filename) { + for (HeatStructureTree heatStructureTree : filesSet) { + if (heatStructureTree.getFileName().equals(filename)) { + return heatStructureTree; + } + } + + return null; + } + + /** + * Sets type. + * + * @param type the type + */ + public void setType(FileData.Type type) { + this.type = type; + } + + /** + * Gets base. + * + * @return the base + */ + public Boolean getBase() { + return isBase; + } + + /** + * Sets base. + * + * @param base the base + */ + public void setBase(Boolean base) { + isBase = base; + } + + /** + * Gets file name. + * + * @return the file name + */ + public String getFileName() { + return fileName; + } + + /** + * Sets file name. + * + * @param file the file + */ + public void setFileName(String file) { + this.fileName = file; + } + + /** + * Gets heat. + * + * @return the heat + */ + @JsonProperty(value = "HEAT") + public Set getHEAT() { + return HEAT; + } + + /** + * Sets heat. + * + * @param heat the heat + */ + public void setHEAT(Set heat) { + this.HEAT = heat; + } + + /** + * Gets nested. + * + * @return the nested + */ + public Set getNested() { + return nested; + } + + /** + * Sets nested. + * + * @param nested the nested + */ + public void setNested(Set nested) { + this.nested = nested; + } + + /** + * Gets artifacts. + * + * @return the artifacts + */ + public Set getArtifacts() { + return artifacts; + } + + /** + * Sets artifacts. + * + * @param artifacts the artifacts + */ + public void setArtifacts(Set artifacts) { + this.artifacts = artifacts; + } + + /** + * Add heat structure tree to nested heat list. + * + * @param heatStructureTree the heat structure tree + */ + public void addHeatStructureTreeToNestedHeatList(HeatStructureTree heatStructureTree) { + if (this.nested == null) { + this.nested = new TreeSet<>(); + } + if (!findItemInSetByName(this.nested, heatStructureTree)) { + this.nested.add(heatStructureTree); + } + } + + /** + * Add artifact to artifact list. + * + * @param artifact the artifact + */ + public void addArtifactToArtifactList(Artifact artifact) { + if (this.artifacts == null || this.artifacts.isEmpty()) { + this.artifacts = new TreeSet<>(); + } + this.artifacts.add(artifact); + } + + /** + * Gets env. + * + * @return the env + */ + public HeatStructureTree getEnv() { + return env; + } + + /** + * Sets env. + * + * @param env the env + */ + public void setEnv(HeatStructureTree env) { + this.env = env; + } + + /** + * Gets volume. + * + * @return the volume + */ + public Set getVolume() { + return volume; + } + + /** + * Sets volume. + * + * @param volume the volume + */ + public void setVolume(Set volume) { + this.volume = volume; + } + + /** + * Gets network. + * + * @return the network + */ + public Set getNetwork() { + return network; + } + + /** + * Sets network. + * + * @param network the network + */ + public void setNetwork(Set network) { + this.network = network; + } + + /** + * Add network to network list. + * + * @param heatStructureTree the heat structure tree + */ + public void addNetworkToNetworkList(HeatStructureTree heatStructureTree) { + if (this.network == null) { + this.network = new TreeSet<>(); + } + if (!findItemInSetByName(this.network, heatStructureTree)) { + this.network.add(heatStructureTree); + } + } + + /** + * Add volume file to volume list. + * + * @param heatStructureTree the heat structure tree + */ + public void addVolumeFileToVolumeList(HeatStructureTree heatStructureTree) { + if (this.volume == null) { + this.volume = new TreeSet<>(); + } + if (!findItemInSetByName(this.volume, heatStructureTree)) { + this.volume.add(heatStructureTree); + } + } + + /** + * Add heat to heat list. + * + * @param heat the heat + */ + public void addHeatToHEATList(HeatStructureTree heat) { + if (this.HEAT == null) { + this.HEAT = new TreeSet<>(); + } + + this.HEAT.add(heat); + } + + /** + * Add other to other list. + * + * @param other the other + */ + public void addOtherToOtherList(HeatStructureTree other) { + if (this.other == null) { + this.other = new TreeSet<>(); + } + + this.other.add(other); + } + + /** + * Find item in set by name boolean. + * + * @param searchSet the search set + * @param toFind the to find + * @return the boolean + */ + public boolean findItemInSetByName(Set searchSet, HeatStructureTree toFind) { + for (HeatStructureTree heatStructureTree : searchSet) { + if (heatStructureTree.getFileName().equals(toFind.getFileName())) { + return true; + } + + } + + return false; + } + + /** + * Remove from volume or network. + * + * @param fileNameToRemove the file name to remove + * @param type the type + */ + public void removeFromVolumeOrNetwork(String fileNameToRemove, FileData.Type type) { + Set volumeOrNetworkSet = + type.equals(FileData.Type.HEAT_VOL) ? this.volume : this.network; + HeatStructureTree toRemove = getHeatStructureTreeByName(volumeOrNetworkSet, fileNameToRemove); + + volumeOrNetworkSet.remove(toRemove); + } + + @Override + public boolean equals(Object other) { + if (this == other) { + return true; + } + if (other == null || getClass() != other.getClass()) { + return false; + } + + HeatStructureTree heatStructureTree = (HeatStructureTree) other; + + if (fileName != null ? !fileName.equals(heatStructureTree.fileName) + : heatStructureTree.fileName != null) { + return false; + } + if (env != null ? !env.equals(heatStructureTree.env) : heatStructureTree.env != null) { + return false; + } + if (HEAT != null ? !HEAT.equals(heatStructureTree.HEAT) : heatStructureTree.HEAT != null) { + return false; + } + if (volume != null ? !volume.equals(heatStructureTree.volume) + : heatStructureTree.volume != null) { + return false; + } + if (network != null ? !network.equals(heatStructureTree.network) + : heatStructureTree.network != null) { + return false; + } + if (artifacts != null ? !artifacts.equals(heatStructureTree.artifacts) + : heatStructureTree.artifacts != null) { + return false; + } + if (nested != null ? !nested.equals(heatStructureTree.nested) + : heatStructureTree.nested != null) { + return false; + } + if (errors != null ? !errors.equals(heatStructureTree.errors) + : heatStructureTree.errors != null) { + return false; + } + + return true; + } + + @Override + public int hashCode() { + int result1 = fileName != null ? fileName.hashCode() : 0; + result1 = 31 * result1 + (env != null ? env.hashCode() : 0); + result1 = 31 * result1 + (HEAT != null ? HEAT.hashCode() : 0); + result1 = 31 * result1 + (volume != null ? volume.hashCode() : 0); + result1 = 31 * result1 + (network != null ? network.hashCode() : 0); + result1 = 31 * result1 + (artifacts != null ? artifacts.hashCode() : 0); + result1 = 31 * result1 + (nested != null ? nested.hashCode() : 0); + result1 = 31 * result1 + (errors != null ? errors.hashCode() : 0); + + + return result1; + } + + /** + * Gets errors. + * + * @return the errors + */ + public List getErrors() { + return errors; + } + + /** + * Sets errors. + * + * @param errors the errors + */ + public void setErrors(List errors) { + this.errors = errors; + } + + /** + * Add error to errors list. + * + * @param error the error + */ + public void addErrorToErrorsList(ErrorMessage error) { + if (this.errors == null || this.errors.isEmpty()) { + this.errors = new ArrayList<>(); + } + if (!this.errors.contains(error)) { + this.errors.add(error); + } + } + + /** + * Gets other. + * + * @return the other + */ + public Set getOther() { + return other; + } + + /** + * Sets other. + * + * @param other the other + */ + public void setOther(Set other) { + this.other = other; + } + + @Override + public int compareTo(HeatStructureTree heatStructureTree) { + return heatStructureTree.getFileName().compareTo(this.getFileName()); + } +} diff --git a/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/structure/ValidationStructureList.java b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/structure/ValidationStructureList.java new file mode 100644 index 0000000000..f2acb2810d --- /dev/null +++ b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/datatypes/structure/ValidationStructureList.java @@ -0,0 +1,40 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.heat.datatypes.structure; + +public class ValidationStructureList { + private HeatStructureTree importStructure; + + public ValidationStructureList() { + } + + public ValidationStructureList(HeatStructureTree importStructure) { + this.importStructure = importStructure; + } + + public HeatStructureTree getImportStructure() { + return importStructure; + } + + public void setImportStructure(HeatStructureTree importStructure) { + this.importStructure = importStructure; + } +} diff --git a/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/services/ErrorCodes.java b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/services/ErrorCodes.java new file mode 100644 index 0000000000..c48d732e63 --- /dev/null +++ b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/services/ErrorCodes.java @@ -0,0 +1,25 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.heat.services; + +public class ErrorCodes { + public static final String INVALID_BOOLEAN = "INVALID_BOOLEAN"; +} diff --git a/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/services/HeatConstants.java b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/services/HeatConstants.java new file mode 100644 index 0000000000..e2afe89a06 --- /dev/null +++ b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/services/HeatConstants.java @@ -0,0 +1,34 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.heat.services; + +public class HeatConstants { + public static final String GET_ATT_FROM_RESOURCE_GROUP_PREFIX = "resource."; + public static final String RESOURCE_GROUP_INDEX_VAR_DEFAULT_VALUE = "%index%"; + + public static final String INDEX_PROPERTY_NAME = "index_var"; + public static final String SERVICE_SCALING_PROPERTY_NAME = "service_scaling"; + public static final String INSTANCE_UUID_PROPERTY_NAME = "instance_uuid"; + public static final String VOLUME_ID_PROPERTY_NAME = "volume_id"; + public static final String RESOURCE_DEF_PROPERTY_NAME = "resource_def"; + public static final String SCALE_OUT_PROPERTY_NAME = "scale_out"; + +} diff --git a/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/services/HeatStructureUtil.java b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/services/HeatStructureUtil.java new file mode 100644 index 0000000000..a216b224af --- /dev/null +++ b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/services/HeatStructureUtil.java @@ -0,0 +1,261 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.heat.services; + +import org.apache.commons.collections4.CollectionUtils; +import org.apache.commons.collections4.MapUtils; +import org.openecomp.core.validation.errors.ErrorMessagesFormatBuilder; +import org.openecomp.core.validation.errors.Messages; +import org.openecomp.core.validation.types.GlobalValidationContext; +import org.openecomp.sdc.datatypes.error.ErrorLevel; +import org.openecomp.sdc.heat.datatypes.model.HeatOrchestrationTemplate; +import org.openecomp.sdc.heat.datatypes.model.HeatResourcesTypes; +import org.openecomp.sdc.heat.datatypes.model.PropertiesMapKeyTypes; +import org.openecomp.sdc.heat.datatypes.model.Resource; +import org.openecomp.sdc.heat.datatypes.model.ResourceReferenceFunctions; + +import java.util.Collection; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.Set; + +/** + * The type Heat structure util. + */ +public class HeatStructureUtil { + + /** + * Gets nested files. + * + * @param filename the filename + * @param hot the hot + * @param globalContext the global context + * @return the nested files + */ + public static Set getNestedFiles(String filename, HeatOrchestrationTemplate hot, + GlobalValidationContext globalContext) { + + Set nestedFileList = new HashSet<>(); + Set resourceDefNestedFiles; + hot.getResources().values().stream().filter( + resource -> (resource.getType().endsWith(".yaml") || resource.getType().endsWith(".yml"))) + .forEach(resource -> nestedFileList.add(resource.getType())); + + resourceDefNestedFiles = getResourceDefNestedFiles(filename, hot, globalContext); + nestedFileList.addAll(resourceDefNestedFiles); + + return nestedFileList; + } + + + private static Set getResourceDefNestedFiles(String filename, + HeatOrchestrationTemplate hot, + GlobalValidationContext globalContext) { + Set resourceDefNestedFiles = new HashSet<>(); + hot.getResources() + .entrySet() + .stream() + .filter(entry -> entry.getValue().getType() + .equals(HeatResourcesTypes.RESOURCE_GROUP_RESOURCE_TYPE.getHeatResource())) + .filter(entry -> + getResourceDef(filename, entry.getKey(), entry.getValue(), globalContext) != null + && isNestedResource( + getResourceDef(filename, entry.getKey(), entry.getValue(), globalContext) + .getType())) + .forEach(entry -> resourceDefNestedFiles.add( + getResourceDef(filename, entry.getKey(), entry.getValue(), globalContext).getType())); + + return resourceDefNestedFiles; + } + + + /** + * Gets resource def. + * + * @param filename the filename + * @param resourceName the resource name + * @param resource the resource + * @param globalContext the global context + * @return the resource def + */ + @SuppressWarnings("unchecked") + public static Resource getResourceDef(String filename, String resourceName, Resource resource, + GlobalValidationContext globalContext) { + Resource resourceDef = null; + Map resourceDefValueMap = resource.getProperties() == null ? null + : (Map) resource.getProperties() + .get(PropertiesMapKeyTypes.RESOURCE_DEF.getKeyMap()); + if (MapUtils.isNotEmpty(resourceDefValueMap)) { + Object resourceDefType = resourceDefValueMap.get("type"); + if (Objects.nonNull(resourceDefType)) { + if (resourceDefType instanceof String) { + boolean isNested = + checkIfResourceGroupTypeIsNested(filename, resourceName, (String) resourceDefType, + globalContext); + if (isNested) { + resourceDef = new Resource(); + resourceDef.setType((String) resourceDefType); + //noinspection unchecked + resourceDef.setProperties((Map) resourceDefValueMap.get("properties")); + } + } else { + globalContext.addMessage(filename, ErrorLevel.WARNING, ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.INVALID_RESOURCE_GROUP_TYPE.getErrorMessage(), + resourceName, resourceDefType.toString())); + } + } else { + globalContext.addMessage(filename, ErrorLevel.WARNING, ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.INVALID_RESOURCE_TYPE.getErrorMessage(), "null", + resourceName)); + } + + } + return resourceDef; + } + + + /** + * Check if resource group type is nested boolean. + * + * @param filename the filename + * @param resourceName the resource name + * @param resourceDefType the resource def type + * @param globalContext the global context + * @return the boolean + */ + public static boolean checkIfResourceGroupTypeIsNested(String filename, String resourceName, + String resourceDefType, + GlobalValidationContext globalContext) { + if (!HeatStructureUtil.isNestedResource(resourceDefType)) { + globalContext.addMessage(filename, ErrorLevel.WARNING, ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.INVALID_RESOURCE_GROUP_TYPE.getErrorMessage(), + resourceName, resourceDefType)); + return false; + } + return true; + } + + /** + * Gets artifact files. + * + * @param filename the filename + * @param hot the hot + * @param globalContext the global context + * @return the artifact files + */ + public static Set getArtifactFiles(String filename, HeatOrchestrationTemplate hot, + GlobalValidationContext globalContext) { + Set artifactSet = new HashSet<>(); + Collection resourcesValue = + hot.getResources() == null ? null : hot.getResources().values(); + if (CollectionUtils.isNotEmpty(resourcesValue)) { + for (Resource resource : resourcesValue) { + Collection properties = + resource.getProperties() == null ? null : resource.getProperties().values(); + if (CollectionUtils.isNotEmpty(properties)) { + for (Object property : properties) { + Set artifactNames = + getReferencedValuesByFunctionName(filename, "get_file", property, globalContext); + artifactSet.addAll(artifactNames); + } + } + } + } + return artifactSet; + } + + /** + * Gets referenced values by function name. + * + * @param filename the filename + * @param functionName the function name + * @param propertyValue the property value + * @param globalContext the global context + * @return the referenced values by function name + */ + public static Set getReferencedValuesByFunctionName(String filename, String functionName, + Object propertyValue, + GlobalValidationContext globalContext) { + Set valuesNames = new HashSet<>(); + if (propertyValue instanceof Map) { + Map currPropertyMap = (Map) propertyValue; + if (currPropertyMap.containsKey(functionName)) { + Object getFunctionValue = currPropertyMap.get(functionName); + if (!(getFunctionValue instanceof String) + && functionName.equals(ResourceReferenceFunctions.GET_RESOURCE.getFunction())) { + globalContext.addMessage(filename, ErrorLevel.ERROR, ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.INVALID_GET_RESOURCE_SYNTAX.getErrorMessage(), + getFunctionValue == null ? "null" : getFunctionValue.toString())); + return valuesNames; + } + if (getFunctionValue instanceof String) { + + if (functionName.equals(ResourceReferenceFunctions.GET_FILE.getFunction())) { + getFunctionValue = ((String) getFunctionValue).replace("file:///", ""); + } + + valuesNames.add((String) getFunctionValue); + } else if (getFunctionValue instanceof List) { + if (CollectionUtils.isNotEmpty((List) getFunctionValue)) { + if (((List) getFunctionValue).get(0) instanceof String) { + valuesNames.add(((String) ((List) getFunctionValue).get(0)).replace("file:///", "")); + } else { + valuesNames.addAll(getReferencedValuesByFunctionName(filename, functionName, + ((List) getFunctionValue).get(0), globalContext)); + } + + } + } else { + valuesNames.addAll( + getReferencedValuesByFunctionName(filename, functionName, getFunctionValue, + globalContext)); + } + } else { + for (Map.Entry nestedPropertyMap : currPropertyMap.entrySet()) { + valuesNames.addAll(getReferencedValuesByFunctionName(filename, functionName, + nestedPropertyMap.getValue(), globalContext)); + } + } + } else if (propertyValue instanceof List) { + List propertyValueArray = (List) propertyValue; + for (Object propertyValueArrayInstance : propertyValueArray) { + valuesNames.addAll( + getReferencedValuesByFunctionName(filename, functionName, propertyValueArrayInstance, + globalContext)); + } + } + + return valuesNames; + } + + + /** + * Is nested resource boolean. + * + * @param resourceType the resource type + * @return the boolean + */ + public static boolean isNestedResource(String resourceType) { + return resourceType.endsWith(".yaml") || resourceType.endsWith(".yml"); + } +} diff --git a/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/services/manifest/ManifestUtil.java b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/services/manifest/ManifestUtil.java new file mode 100644 index 0000000000..09378cebf4 --- /dev/null +++ b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/services/manifest/ManifestUtil.java @@ -0,0 +1,176 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.heat.services.manifest; + +import org.apache.commons.collections4.CollectionUtils; +import org.openecomp.sdc.heat.datatypes.manifest.FileData; +import org.openecomp.sdc.heat.datatypes.manifest.ManifestContent; + +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Set; + + +/** + * The type Manifest util. + */ +public class ManifestUtil { + + + /** + * Gets file and its env. + * + * @param manifestContent the manifest content + * @return the file and its env + */ + public static Map getFileAndItsEnv(ManifestContent manifestContent) { + Map fileEnvMap = new HashMap<>(); + scanFileEnvMap(null, manifestContent.getData(), fileEnvMap); + return fileEnvMap; + } + + + /** + * Scan file env map. + * + * @param fileData the file data + * @param fileDataList the file data list + * @param fileEnvMap the file env map + */ + public static void scanFileEnvMap(FileData fileData, List fileDataList, + Map fileEnvMap) { + if (CollectionUtils.isEmpty(fileDataList)) { + return; + } + + for (FileData childFileData : fileDataList) { + FileData.Type childType = childFileData.getType(); + if (fileData != null) { + if (childType != null && childType.equals(FileData.Type.HEAT_ENV)) { + fileEnvMap.put(fileData.getFile(), childFileData); + } + } + scanFileEnvMap(childFileData, childFileData.getData(), fileEnvMap); + } + } + + + /** + * Gets file type map. + * + * @param manifestContent the manifest content + * @return the file type map + */ + public static Map getFileTypeMap(ManifestContent manifestContent) { + Map fileTypeMap = new HashMap<>(); + scanFileTypeMap(null, manifestContent.getData(), fileTypeMap); + return fileTypeMap; + } + + private static FileData.Type scanFileTypeMap(FileData fileData, List data, + Map fileTypeMap) { + if (fileData != null) { + fileTypeMap.put(fileData.getFile(), fileData.getType()); + } + if (data == null) { + return null; + } + + for (FileData chileFileData : data) { + FileData.Type type = scanFileTypeMap(chileFileData, chileFileData.getData(), fileTypeMap); + if (type != null) { + return type; + } + } + return null; + } + + + /** + * Gets artifacts. + * + * @param manifestContent the manifest content + * @return the artifacts + */ + public static Set getArtifacts(ManifestContent manifestContent) { + Set artifacts = new HashSet<>(); + scanArtifacts(null, manifestContent.getData(), artifacts); + + return artifacts; + } + + + private static void scanArtifacts(FileData fileData, List data, Set artifacts) { + if (fileData != null && fileData.getType() != null) { + if (isArtifact(fileData)) { + artifacts.add(fileData.getFile()); + } + } + + if (data == null) { + return; + } + + for (FileData chileFileData : data) { + scanArtifacts(chileFileData, chileFileData.getData(), artifacts); + } + } + + private static boolean isArtifact(FileData fileData) { + if (FileData.Type.valueOf(fileData.getType().name()) != null + && !fileData.getType().equals(FileData.Type.HEAT) + && !fileData.getType().equals(FileData.Type.HEAT_ENV) + && !fileData.getType().equals(FileData.Type.HEAT_NET) + && !fileData.getType().equals(FileData.Type.HEAT_VOL)) { + return true; + } + return false; + } + + /** + * Gets base files. + * + * @param manifestContent the manifest content + * @return the base files + */ + public static Set getBaseFiles(ManifestContent manifestContent) { + Set baseFiles = new HashSet<>(); + scanBase(null, manifestContent.getData(), baseFiles); + return baseFiles; + } + + private static void scanBase(FileData fileData, List data, Set baseFiles) { + if (fileData != null && fileData.getBase() != null) { + if (fileData.getBase()) { + baseFiles.add(fileData.getFile()); + } + } + if (data == null) { + return; + } + + for (FileData chileFileData : data) { + scanBase(chileFileData, chileFileData.getData(), baseFiles); + } + } +} diff --git a/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/services/tree/HeatTreeManager.java b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/services/tree/HeatTreeManager.java new file mode 100644 index 0000000000..71c532dbd3 --- /dev/null +++ b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/services/tree/HeatTreeManager.java @@ -0,0 +1,298 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.heat.services.tree; + +import org.openecomp.core.utilities.file.FileContentHandler; +import org.openecomp.core.utilities.file.FileUtils; +import org.openecomp.core.utilities.json.JsonUtil; +import org.openecomp.core.utilities.yaml.YamlUtil; +import org.openecomp.core.validation.types.GlobalValidationContext; +import org.openecomp.sdc.common.utils.AsdcCommon; +import org.openecomp.sdc.datatypes.error.ErrorMessage; +import org.openecomp.sdc.heat.datatypes.manifest.FileData; +import org.openecomp.sdc.heat.datatypes.manifest.ManifestContent; +import org.openecomp.sdc.heat.datatypes.model.HeatOrchestrationTemplate; +import org.openecomp.sdc.heat.datatypes.structure.Artifact; +import org.openecomp.sdc.heat.datatypes.structure.HeatStructureTree; +import org.openecomp.sdc.heat.services.HeatStructureUtil; + +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import java.io.InputStream; +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Set; + +/** + * The type Heat tree manager. + */ +public class HeatTreeManager { + + private static Logger logger = LoggerFactory.getLogger(HeatTreeManager.class); + + + private FileContentHandler heatContentMap = new FileContentHandler(); + private byte[] manifest; + private HeatStructureTree tree = new HeatStructureTree(); + private Map fileTreeRef = new HashMap<>(); + private Map artifactRef = new HashMap<>(); + private Map candidateOrphanArtifacts = new HashMap<>(); + private Map nestedFiles = new HashMap<>(); + private Map volumeFileToParent = new HashMap<>(); + private Map networkFileToParent = new HashMap<>(); + private Set manifestFiles = new HashSet<>(); + + /** + * Add file. + * + * @param fileName the file name + * @param content the content + */ + public void addFile(String fileName, InputStream content) { + if (fileName.equals(AsdcCommon.MANIFEST_NAME)) { + manifest = FileUtils.toByteArray(content); + + } else { + heatContentMap.addFile(fileName, content); + } + } + + /** + * Create tree. + */ + public void createTree() { + if (manifest == null) { + logger.error("Missing manifest file in the zip."); + return; + } + ManifestContent manifestData = + JsonUtil.json2Object(new String(manifest), ManifestContent.class); + scanTree(null, manifestData.getData()); + addNonNestedVolumeNetworkToTree(volumeFileToParent, nestedFiles.keySet(), true); + addNonNestedVolumeNetworkToTree(networkFileToParent, nestedFiles.keySet(), false); + handleOrphans(); + + tree = fileTreeRef.get(AsdcCommon.PARENT); + } + + private void handleOrphans() { + tree = fileTreeRef.get(AsdcCommon.PARENT); + candidateOrphanArtifacts.entrySet().stream() + .forEach(entry -> tree.addArtifactToArtifactList(entry.getValue())); + nestedFiles + .values() + .stream() + .filter(heatStructureTree -> tree.getHEAT().contains(heatStructureTree)) + .forEach(heatStructureTree -> tree.getHEAT().remove(heatStructureTree)); + + heatContentMap.getFileList().stream().filter(fileName -> !manifestFiles.contains(fileName)) + .forEach(fileName -> addTreeOther(fileName)); + } + + private void addTreeOther(String fileName) { + if (tree.getOther() == null) { + tree.setOther(new HashSet<>()); + } + HeatStructureTree other = new HeatStructureTree(fileName, false); + fileTreeRef.put(fileName, other); + tree.getOther().add(other); + } + + + private void handleHeatContentReference(String filename, HeatStructureTree fileHeatStructureTree, + GlobalValidationContext globalContext) { + + String fileName = fileHeatStructureTree.getFileName(); + InputStream fileContent = this.heatContentMap.getFileContent(fileName); + if (fileContent == null) { + return; // file exist in manifest but does not exist in zip + } + try { + HeatOrchestrationTemplate hot = + new YamlUtil().yamlToObject(fileContent, HeatOrchestrationTemplate.class); + + Set nestedSet = HeatStructureUtil.getNestedFiles(filename, hot, globalContext); + addHeatNestedFiles(fileHeatStructureTree, nestedSet); + + Set artifactSet = HeatStructureUtil.getArtifactFiles(filename, hot, globalContext); + addHeatArtifactFiles(fileHeatStructureTree, artifactSet); + } catch (Exception ignore) { /* invalid yaml no need to process reference */ } + } + + private void addHeatArtifactFiles(HeatStructureTree fileHeatStructureTree, + Set artifactSet) { + Artifact artifact; + for (String artifactName : artifactSet) { + FileData.Type type = + candidateOrphanArtifacts.get(artifactName) != null ? candidateOrphanArtifacts + .get(artifactName).getType() : null; + artifact = new Artifact(artifactName, type); + artifactRef.put(artifactName, artifact); + candidateOrphanArtifacts.remove(artifactName); + fileHeatStructureTree.addArtifactToArtifactList(artifact); + } + } + + + private void addHeatNestedFiles(HeatStructureTree fileHeatStructureTree, Set nestedSet) { + HeatStructureTree childHeatStructureTree; + for (String nestedName : nestedSet) { + childHeatStructureTree = fileTreeRef.get(nestedName); + if (childHeatStructureTree == null) { + childHeatStructureTree = new HeatStructureTree(); + childHeatStructureTree.setFileName(nestedName); + fileTreeRef.put(nestedName, childHeatStructureTree); + } + fileHeatStructureTree.addHeatStructureTreeToNestedHeatList(childHeatStructureTree); + nestedFiles.put(childHeatStructureTree.getFileName(), childHeatStructureTree); + } + } + + + /** + * Add errors. + * + * @param validationErrors the validation errors + */ + public void addErrors(Map> validationErrors) { + + validationErrors.entrySet().stream().filter(entry -> { + return fileTreeRef.get(entry.getKey()) != null; + }).forEach(entry -> entry.getValue().stream().forEach(error -> + fileTreeRef.get(entry.getKey()).addErrorToErrorsList(error))); + + validationErrors.entrySet().stream().filter(entry -> { + return artifactRef.get(entry.getKey()) != null; + }).forEach(entry -> artifactRef.get(entry.getKey()).setErrors(entry.getValue())); + + } + + /** + * Scan tree. + * + * @param parent the parent + * @param data the data + */ + public void scanTree(String parent, List data) { + String fileName; + FileData.Type type; + HeatStructureTree parentHeatStructureTree; + HeatStructureTree fileHeatStructureTree; + HeatStructureTree childHeatStructureTree; + Artifact artifact; + if (parent == null) { + parentHeatStructureTree = new HeatStructureTree(); + fileTreeRef.put(AsdcCommon.PARENT, parentHeatStructureTree); + } else { + parentHeatStructureTree = fileTreeRef.get(parent); + } + + for (FileData fileData : data) { + fileName = fileData.getFile(); + manifestFiles.add(fileName); + type = fileData.getType(); + + if (FileData.Type.HEAT.equals(type)) { + fileHeatStructureTree = fileTreeRef.get(fileName); + if (fileHeatStructureTree == null) { + fileHeatStructureTree = new HeatStructureTree(); + fileTreeRef.put(fileName, fileHeatStructureTree); + } + fileHeatStructureTree.setFileName(fileName); + fileHeatStructureTree.setBase(fileData.getBase()); + fileHeatStructureTree.setType(type); + handleHeatContentReference(null, fileHeatStructureTree, null); + parentHeatStructureTree.addHeatToHEATList(fileHeatStructureTree); + if (fileData.getData() != null) { + scanTree(fileName, fileData.getData()); + } + } else { + childHeatStructureTree = new HeatStructureTree(); + childHeatStructureTree.setFileName(fileName); + childHeatStructureTree.setBase(fileData.getBase()); + childHeatStructureTree.setType(type); + fileTreeRef.put(childHeatStructureTree.getFileName(), childHeatStructureTree); + + if (type == null) { + parentHeatStructureTree.addOtherToOtherList(childHeatStructureTree); + } else if (FileData.Type.HEAT_NET.equals(type)) { + // parentHeatStructureTree.addNetworkToNetworkList(childHeatStructureTree); + networkFileToParent.put(childHeatStructureTree, parentHeatStructureTree); + if (fileData.getData() != null) { + scanTree(fileName, fileData.getData()); + } + + } else if (FileData.Type.HEAT_VOL.equals(type)) { + // parentHeatStructureTree.addVolumeFileToVolumeList(childHeatStructureTree); + volumeFileToParent.put(childHeatStructureTree, parentHeatStructureTree); + if (fileData.getData() != null) { + scanTree(fileName, fileData.getData()); + } + } else if (FileData.Type.HEAT_ENV.equals(type)) { + if (parentHeatStructureTree != null && parentHeatStructureTree.getFileName() != null) { + parentHeatStructureTree.setEnv(childHeatStructureTree); + } else { + if (parentHeatStructureTree.getOther() == null) { + parentHeatStructureTree.setOther(new HashSet<>()); + } + parentHeatStructureTree.getOther().add(childHeatStructureTree); + } + } else { + artifact = new Artifact(fileName, type); + if (!artifactRef.keySet().contains(fileName)) { + artifactRef.put(fileName, artifact); + candidateOrphanArtifacts.put(fileName, artifact); + } + } + } + } + } + + + private void addNonNestedVolumeNetworkToTree( + Map netVolToParent, Set nestedFileNames, + boolean isVolume) { + for (Map.Entry entry : netVolToParent.entrySet()) { + HeatStructureTree netOrVolNode = entry.getKey(); + HeatStructureTree parent = entry.getValue(); + if (!nestedFileNames.contains(netOrVolNode.getFileName())) { + if (isVolume) { + parent.addVolumeFileToVolumeList(netOrVolNode); + } else { + parent.addNetworkToNetworkList(netOrVolNode); + } + } + } + } + + + /** + * Gets tree. + * + * @return the tree + */ + public HeatStructureTree getTree() { + return tree; + } +} diff --git a/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/services/tree/HeatTreeManagerUtil.java b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/services/tree/HeatTreeManagerUtil.java new file mode 100644 index 0000000000..dac7cdbbcb --- /dev/null +++ b/openecomp-be/lib/openecomp-heat-lib/src/main/java/org/openecomp/sdc/heat/services/tree/HeatTreeManagerUtil.java @@ -0,0 +1,43 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.heat.services.tree; + +import org.openecomp.core.utilities.file.FileContentHandler; + +/** + * The type Heat tree manager util. + */ +public class HeatTreeManagerUtil { + /** + * Init heat tree manager heat tree manager. + * + * @param fileContentMap the file content map + * @return the heat tree manager + */ + public static HeatTreeManager initHeatTreeManager(FileContentHandler fileContentMap) { + + HeatTreeManager heatTreeManager = new HeatTreeManager(); + fileContentMap.getFileList().stream().forEach( + fileName -> heatTreeManager.addFile(fileName, fileContentMap.getFileContent(fileName))); + + return heatTreeManager; + } +} diff --git a/openecomp-be/lib/openecomp-heat-lib/src/test/java/org/openecomp/sdc/heat/datatypes/model/EnvironmentTest.java b/openecomp-be/lib/openecomp-heat-lib/src/test/java/org/openecomp/sdc/heat/datatypes/model/EnvironmentTest.java new file mode 100644 index 0000000000..2c0cf0b1aa --- /dev/null +++ b/openecomp-be/lib/openecomp-heat-lib/src/test/java/org/openecomp/sdc/heat/datatypes/model/EnvironmentTest.java @@ -0,0 +1,38 @@ +package org.openecomp.sdc.heat.datatypes.model; + +import org.openecomp.core.utilities.yaml.YamlUtil; +import org.junit.Test; + +import java.io.InputStream; + +public class EnvironmentTest { + + @Test + public void testYamlToServiceTemplateObj() { + YamlUtil yamlUtil = new YamlUtil(); + InputStream yamlFile = yamlUtil.loadYamlFileIs("/mock/model/envSettings.env"); + Environment envVars = yamlUtil.yamlToObject(yamlFile, Environment.class); + envVars.toString(); + } + + @Test + public void test() { + String heatResourceName = "server_abc_0u"; + String novaServerPrefix = "server_"; + if (heatResourceName.startsWith(novaServerPrefix)) { + heatResourceName = heatResourceName.substring(novaServerPrefix.length()); + } + int lastIndexOfUnderscore = heatResourceName.lastIndexOf("_"); + if (heatResourceName.length() == lastIndexOfUnderscore) { + System.out.println(heatResourceName); + } else { + String heatResourceNameSuffix = heatResourceName.substring(lastIndexOfUnderscore + 1); + try { + Integer.parseInt(heatResourceNameSuffix); + System.out.println(heatResourceName.substring(0, lastIndexOfUnderscore)); + } catch (NumberFormatException ignored) { + System.out.println(heatResourceName); + } + } + } +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-heat-lib/src/test/java/org/openecomp/sdc/heat/datatypes/model/HeatOrchestrationTemplateTest.java b/openecomp-be/lib/openecomp-heat-lib/src/test/java/org/openecomp/sdc/heat/datatypes/model/HeatOrchestrationTemplateTest.java new file mode 100644 index 0000000000..09c83ca217 --- /dev/null +++ b/openecomp-be/lib/openecomp-heat-lib/src/test/java/org/openecomp/sdc/heat/datatypes/model/HeatOrchestrationTemplateTest.java @@ -0,0 +1,122 @@ +package org.openecomp.sdc.heat.datatypes.model; + +import org.openecomp.core.utilities.yaml.YamlUtil; +import org.junit.Assert; +import org.junit.Test; + +import java.io.InputStream; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +public class HeatOrchestrationTemplateTest { + + @Test + public void testYamlToServiceTemplateObj() { + YamlUtil yamlUtil = new YamlUtil(); + InputStream yamlFile = yamlUtil.loadYamlFileIs("/mock/model/testHeat.yml"); + HeatOrchestrationTemplate heatOrchestrationTemplate = + yamlUtil.yamlToObject(yamlFile, HeatOrchestrationTemplate.class); + heatOrchestrationTemplate.toString(); + } + + @Test + public void createHotTemplate() { + HeatOrchestrationTemplate template = new HeatOrchestrationTemplate(); + template.setHeat_template_version("2016-04-14"); + template.setDescription("test description for hot template"); + Map params = createParameters(); + template.setParameters(params); + List parameterGroup = new ArrayList<>(); + ParameterGroup paramsGroup = new ParameterGroup(); + paramsGroup.setDescription("params group test description"); + paramsGroup.setLabel("params group test label"); + String paramName = params.get("param1").getLabel(); + List paramsNames = new ArrayList<>(); + paramsNames.add(paramName); + paramsGroup.setParameters(paramsNames); + parameterGroup.add(paramsGroup); + template.setParameter_groups(parameterGroup); + Map conditions = new HashMap<>(); + conditions.put("key1", "val1"); + HashMap mapValue = new HashMap<>(); + mapValue.put("innerKey", "innerVal"); + conditions.put("key2", mapValue); + template.setConditions(conditions); + + Map resources = new HashMap<>(); + Resource resource = new Resource(); + resource.setMetadata("resource metadata"); + resource.setType("resource type"); + //Map resourceProps = new ; + Map resourceProps = new HashMap<>(); + resourceProps.put("aaa", "bbb"); + //resourceProps.add(resourceProp); + resource.setProperties(resourceProps); + resources.put("R1", resource); + resource = new Resource(); + resource.setMetadata("resource2 metadata"); + resource.setType("resource2 type"); + //resourceProps = new ArrayList<>(); + resourceProps = new HashMap<>(); + resourceProps.put("aaa2", "bbb2"); + //resourceProps.add(resourceProp); + resource.setProperties(resourceProps); + List dependsOn = new ArrayList<>(); + dependsOn.add("R1"); + resource.setDepends_on(dependsOn); + resource.setDeletion_policy("all"); + resource.setUpdate_policy("once"); + resources.put("R2", resource); + template.setResources(resources); + + YamlUtil yamlUtil = new YamlUtil(); + String yml = yamlUtil.objectToYaml(template); + Assert.assertNotNull(yml); + try { + HeatOrchestrationTemplate heatOrchestrationTemplate = + yamlUtil.yamlToObject(yml, HeatOrchestrationTemplate.class); + Assert.assertNotNull(heatOrchestrationTemplate); + } catch (Exception ignored) { + } + } + + private Map createParameters() { + Map params = new HashMap<>(); + Parameter param; + for (int i = 0; i < 2; i++) { + param = new Parameter(); + param.setDescription("param " + i + " desc"); + param.setLabel("param " + i + " label"); + param.set_default("PARAM " + i + " default"); + param.setHidden(i % 2 == 0); + param.setImmutable(i % 2 == 0); + param.setType(i % 2 == 0 ? ParameterType.STRING.getDisplayName() + : ParameterType.BOOLEAN.getDisplayName()); + params.put("param" + i, param); + } + + return params; + } + + private List createConstraints() { + List constraints = new ArrayList<>(); + Constraint constraint = new Constraint(); + constraint.setLength(new Integer[]{2, 4}); + constraints.add(constraint); + constraint = new Constraint(); + constraint.setPattern("some regex"); + constraints.add(constraint); + constraint = new Constraint(); + constraint.setRange(new Integer[]{5, 8}); + constraints.add(constraint); + constraint = new Constraint(); + List validValues = new ArrayList<>(); + validValues.add("abc"); + validValues.add("def"); + constraint.setValid_values(validValues); + constraints.add(constraint); + return constraints; + } +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-heat-lib/src/test/resources/mock/model/envSettings.env b/openecomp-be/lib/openecomp-heat-lib/src/test/resources/mock/model/envSettings.env new file mode 100644 index 0000000000..4f5e20a55f --- /dev/null +++ b/openecomp-be/lib/openecomp-heat-lib/src/test/resources/mock/model/envSettings.env @@ -0,0 +1,36 @@ +parameters: + czid: RDM1 + vf_inst_number: 01 + admin_password: cisco123 + vpc_vip_addr: 172.17.32.112 + vpc_vip_gateway: 172.17.32.1 + availability_zone: nova + + instance_image_cf1: SGW_19.2.0v-CF1-ATTM1.0.1_nimbus + instance_image_cf2: SGW_19.2.0v-CF2-ATTM1.0.1_nimbus + instance_image_sf: SGW_19.2.0v-SFn-ATTM1.0.1_nimbus + instance_flavor_cf: m1.xlarge + instance_flavor_sf: m1.xlarge + + + instance_network: mns-oam_direct_net_0 + cgw_int_di2_net: nimbus_int_sae_gw_di-2_net_0 + cgw_gn_net: mns-gn_direct_net_0 + cgw_cor_net: mns-cor_direct_net_0 + cgw_sgi_protected_net: nimbus_sgi_protected_net_0 + cgw_sgi_ims_net: nimbus_sgi_ims_net_0 + cgw_oam_calea_net: nimbus_oam_calea_net_0 + cgw_int_icsr_net: nimbus_int_icsr_net_0 + + # CF VNFs Neutron static IP for management port + CF01-OAM-IP: 172.17.32.110 + CF02-OAM-IP: 172.17.32.111 + # SF VNFs Neutron static IPs for port 1-6 + SF03-IP: { gn_ip: [107.243.0.5, "2606:ae00:2e01:140::5"], cor_ip: [107.243.3.5, "fd00:ae00:2e01:40::5"], sgi_prot_ip: [107.243.1.5, "fd00:ae00:2030:a40::5"], sgi_ims_ip: [107.243.2.5, "fd00:ae00:2030:b40::5"], oam_calea_ip: [107.243.4.5], int_icsr_ip: [172.26.0.5, "fd00:2600:2600::5"]} + SF04-IP: { gn_ip: [107.243.0.6, "2606:ae00:2e01:140::6"], cor_ip: [107.243.3.6, "fd00:ae00:2e01:40::6"], sgi_prot_ip: [107.243.1.6, "fd00:ae00:2030:a40::6"], sgi_ims_ip: [107.243.2.6, "fd00:ae00:2030:b40::6"], oam_calea_ip: [107.243.4.6], int_icsr_ip: [172.26.0.10, "fd00:2600:2600::10"]} + SF05-IP: { gn_ip: [107.243.0.7, "2606:ae00:2e01:140::7"], cor_ip: [107.243.3.7, "fd00:ae00:2e01:40::7"], sgi_prot_ip: [107.243.1.7, "fd00:ae00:2030:a40::7"], sgi_ims_ip: [107.243.2.7, "fd00:ae00:2030:b40::7"], oam_calea_ip: [107.243.4.7], int_icsr_ip: [172.26.0.9, "fd00:2600:2600::9"]} + SF06-IP: { gn_ip: [107.243.0.8, "2606:ae00:2e01:140::8"], cor_ip: [107.243.3.8, "fd00:ae00:2e01:40::8"], sgi_prot_ip: [107.243.1.8, "fd00:ae00:2030:a40::8"], sgi_ims_ip: [107.243.2.8, "fd00:ae00:2030:b40::8"], oam_calea_ip: [107.243.4.8], int_icsr_ip: [172.26.0.8, "fd00:2600:2600::8"]} + # Volume size for HDD attaching to CF card for CDR storage + vol_size_1: 16 + vol_size_2: 16 + diff --git a/openecomp-be/lib/openecomp-heat-lib/src/test/resources/mock/model/testHeat.yml b/openecomp-be/lib/openecomp-heat-lib/src/test/resources/mock/model/testHeat.yml new file mode 100644 index 0000000000..d1eb621731 --- /dev/null +++ b/openecomp-be/lib/openecomp-heat-lib/src/test/resources/mock/model/testHeat.yml @@ -0,0 +1,524 @@ +heat_template_version: 2013-05-23 + +description: vSeGW/vSRX Firewall Template + +parameter_groups: +- label: System Settings + description: System Level Settings + parameters: + - availability_zone_0 + - vnf_name + - vnf_id + +parameters: + availability_zone_0: + type: string + description: Availability Zone + vnf_name: + type: string + description: Unique name for this VNF instance + vnf_id: + type: string + description: Unique ID for this VNF instance + +# Note we are requesting a flavor with 10 physical CPU cores and may be limited by 16 vCPU flavor. + flavor_segw_name: + type: string + description: flavor type +# The image will be provided as a qcow2 KVM image. + image_segw_name: + type: string + description: Image use to boot a server + + flavor_vsrxfw_name: + type: string + description: flavor type + image_vsrxfw_name: + type: string + description: Image use to boot a server + + INTERNET_direct_net_id: + type: string + description: The Internet + + oam_mgmt_net_0_id: + type: string + description: Name of OAM mgmt network + + oam_protected_net_0_id: + type: string + description: Name of OAM protected network + + Mobility_OAM_protected_net_0_id: + type: string + description: Network name for OAM + + GN_direct_net_0_id: + type: string + description: Network name for GN network + + Mobility_OAM_protected_net_1_id: + type: string + description: Network name for OAM + + GN_direct_net_1_id: + type: string + description: Network name for GN network + + HSL_direct_net_id: + type: string + description: Name of HSL (Logging) network + HSL_direct_net_cidr: + type: string + description: HSL (Logging) network address (CIDR notation) + + int_dummi0_net_id: + type: string + description: Dummi Parent Network for port + int_dummi1_net_id: + type: string + description: Dummi Parent Network for port +# int_dummi2_net_id: +# type: string +# description: Dummi Parent Network for port +# int_dummi3_net_id: +# type: string +# description: Dummi Parent Network for port +# int_dummi4_net_id: +# type: string +# description: Dummi Parent Network for port +# int_dummi5_net_id: +# type: string +# description: Dummi Parent Network for port + + int_dummi0_cidr: + type: string + description: IPv4 prefix (CIDR notation) + int_dummi1_cidr: + type: string + description: IPv4 prefix (CIDR notation) +# int_dummi2_cidr: +# type: string +# description: IPv4 prefix (CIDR notation) +# int_dummi3_cidr: +# type: string +# description: IPv4 prefix (CIDR notation) +# int_dummi4_cidr: +# type: string +# description: IPv4 prefix (CIDR notation) +# int_dummi5_cidr: +# type: string +# description: IPv4 prefix (CIDR notation) + + segw_0_inet_ip_0: + type: string + label: segw_0 port ens10 Ingress IP address alias_0 + description: SeGW's Ingress interface IPv4 address, primary + segw_0_inet_ip_1: + type: string + label: segw_0 port ens10 Ingress IP address alias_1 + description: SeGW's Ingress interface IPv4 address, alias 1 + segw_0_inet_ip_2: + type: string + label: segw_0 port ens10 Ingress IP address alias_2 + description: SeGW's Ingress interface IPv4 address, alias 2 + + segw_1_inet_ip_0: + type: string + label: segw_1 port ens10 Ingress IP address alias_0 + description: SeGW's Ingress interface IPv4 address, primary + segw_1_inet_ip_1: + type: string + label: segw_1 port ens10 Ingress IP address alias_1 + description: SeGW's Ingress interface IPv4 address, alias 1 + segw_1_inet_ip_2: + type: string + label: segw_1 port ens10 Ingress IP address alias_2 + description: SeGW's Ingress interface IPv4 address, alias 2 + segw_0_oam_protected_ip: + type: string + label: segw_0 OAM MGMT IP address + description: segw_0 OAM MGMT IP address + segw_1_oam_protected_ip: + type: string + label: segw_1 OAM MGMT IP address + description: segw_1 OAM MGMT IP address + +# vsrx_fw_0_GN_direct_ip: +# type: string +# label: vsrx_fw_0 GN Direct IP address +# description: vsrx_fw_0 GN Direct IP address +# vsrx_fw_1_GN_direct_ip: +# type: string +# label: vsrx_fw_1 GN Direct IP address +# description: vsrx_fw_1 GN Direct IP address +# vsrx_fw_2_OAM_protected_ip: +# type: string +# label: vsrx_fw_2 OAM Protected IP address +# description: vsrx_fw_2 OAM Protected IP address +# vsrx_fw_3_OAM_protected_ip: +# type: string +# label: vsrx_fw_3 OAM Protected IP address +# description: vsrx_fw_3 OAM Protected IP address + + segw_0_name: + type: string + default: vSeGW_0 + description: name of VM + segw_1_name: + type: string + default: vSeGW_1 + description: name of VM + vsrx_fw_0_name: + type: string + default: vSRX_FW_0 + description: name of VM + vsrx_fw_1_name: + type: string + default: vSRX_FW_1 + description: name of VM + vsrx_fw_2_name: + type: string + default: vSRX_FW_2 + description: name of VM + vsrx_fw_3_name: + type: string + default: vSRX_FW_3 + description: name of VM + + security_group_name: + type: string + label: SEGW security group name + description: SEGW security group name + +resources: + + SeGW_Affinity: + type: OS::Nova::ServerGroup + properties: + policies: ["anti-affinity"] + vSRXFW_Affinity: + type: OS::Nova::ServerGroup + properties: + policies: ["anti-affinity"] + + Dummi0_net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: int_dummi0_net_id } + Dummi0_subnet: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: Dummi0_net } + cidr: { get_param: int_dummi0_cidr } + + Dummi1_net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: int_dummi1_net_id } + Dummi1_subnet: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: Dummi1_net } + cidr: { get_param: int_dummi1_cidr } + + hsl_direct_net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: HSL_direct_net_id } + + hsl_ip_subnet: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: hsl_direct_net } + cidr: { get_param: HSL_direct_net_cidr } + + segw_security_group: + type: OS::Neutron::SecurityGroup + properties: + description: vscp security group + name: {get_param: security_group_name} +# Need to add any-any rule through GUI to get SCTP traffic to work - any-any rules are not supported in heat template + rules: [{"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0} + ] + + server_segw_segw_0: + type: OS::Nova::Server + properties: + name: { get_param: segw_0_name } + image: { get_param: image_segw_name } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: flavor_segw_name } + scheduler_hints: { group: { get_resource: SeGW_Affinity } } + networks: + - port: { get_resource: port_segw_0_oam_protected } + - port: { get_resource: port_segw_0_internet } + - port: { get_resource: port_segw_0_dummi } + metadata: + vnf_id: { get_param: vnf_id } + + port_segw_0_oam_protected: + type: OS::Neutron::Port + properties: + network: { get_param: oam_protected_net_0_id } + fixed_ips: [{"ip_address": {get_param: segw_0_oam_protected_ip}}] + security_groups: [{get_resource: segw_security_group}] + + port_segw_0_internet: + type: OS::Neutron::Port + properties: + network: { get_param: INTERNET_direct_net_id } + fixed_ips: [{"ip_address": {get_param: segw_0_inet_ip_0}}, {"ip_address": {get_param: segw_0_inet_ip_1}}, {"ip_address": {get_param: segw_0_inet_ip_2}}] + security_groups: [{get_resource: segw_security_group}] + + port_segw_0_dummi: + type: OS::Neutron::Port + properties: + network: { get_resource: Dummi0_net } + security_groups: [{get_resource: segw_security_group}] + + server_segw_segw_1: + type: OS::Nova::Server + properties: + name: { get_param: segw_1_name } + image: { get_param: image_segw_name } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: flavor_segw_name } + scheduler_hints: { group: { get_resource: SeGW_Affinity } } + networks: + - port: { get_resource: port_segw_1_oam_protected } + - port: { get_resource: port_segw_1_internet } + - port: { get_resource: port_segw_1_dummi } + metadata: + vnf_id: { get_param: vnf_id } + + port_segw_1_oam_protected: + type: OS::Neutron::Port + properties: + network: { get_param: oam_protected_net_0_id } + fixed_ips: [{"ip_address": {get_param: segw_1_oam_protected_ip}}] + security_groups: [{get_resource: segw_security_group}] + + port_segw_1_internet: + type: OS::Neutron::Port + properties: + network: { get_param: INTERNET_direct_net_id } + fixed_ips: [{"ip_address": {get_param: segw_1_inet_ip_0}}, {"ip_address": {get_param: segw_1_inet_ip_1}}, {"ip_address": {get_param: segw_1_inet_ip_2}}] + security_groups: [{get_resource: segw_security_group}] + + port_segw_1_dummi: + type: OS::Neutron::Port + properties: + network: { get_resource: Dummi1_net } + security_groups: [{get_resource: segw_security_group}] + + server_vsrx_fw_0: + type: OS::Nova::Server + properties: + name: { get_param: vsrx_fw_0_name } + image: { get_param: image_vsrxfw_name } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: flavor_vsrxfw_name } + scheduler_hints: { group: { get_resource: vSRXFW_Affinity } } + networks: + - port: { get_resource: port_vsrx_fw_0_oam_mgmt } + - port: { get_resource: port_vsrx_fw_0_dummi } + - port: { get_resource: port_vsrx_fw_0_GN } + - port: { get_resource: port_vsrx_fw_0_HSL } + + metadata: + vnf_id: { get_param: vnf_id } + + port_vsrx_fw_0_oam_mgmt: + type: OS::Neutron::Port + properties: + network: { get_param: oam_mgmt_net_0_id } + security_groups: [{get_resource: segw_security_group}] + + port_vsrx_fw_0_dummi: + type: OS::Neutron::Port + properties: + network: { get_resource: Dummi0_net } + security_groups: [{get_resource: segw_security_group}] + + port_vsrx_fw_0_GN: + type: OS::Neutron::Port + properties: + network: { get_param: GN_direct_net_0_id } +# fixed_ips: [{"ip_address": {get_param: vsrx_fw_0_GN_direct_ip}}] + security_groups: [{get_resource: segw_security_group}] + + port_vsrx_fw_0_HSL: + type: OS::Neutron::Port + properties: + network: { get_resource: hsl_direct_net } + security_groups: [{get_resource: segw_security_group}] + + server_vsrx_fw_1: + type: OS::Nova::Server + properties: + name: { get_param: vsrx_fw_1_name } + image: { get_param: image_vsrxfw_name } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: flavor_vsrxfw_name } + scheduler_hints: { group: { get_resource: vSRXFW_Affinity } } + networks: + - port: { get_resource: port_vsrx_fw_1_oam_mgmt } + - port: { get_resource: port_vsrx_fw_1_dummi } + - port: { get_resource: port_vsrx_fw_1_GN } + - port: { get_resource: port_vsrx_fw_1_HSL } + + metadata: + vnf_id: { get_param: vnf_id } + + port_vsrx_fw_1_oam_mgmt: + type: OS::Neutron::Port + properties: + network: { get_param: oam_mgmt_net_0_id } + security_groups: [{get_resource: segw_security_group}] + + port_vsrx_fw_1_dummi: + type: OS::Neutron::Port + properties: + network: { get_resource: Dummi1_net } + security_groups: [{get_resource: segw_security_group}] + + port_vsrx_fw_1_GN: + type: OS::Neutron::Port + properties: + network: { get_param: GN_direct_net_1_id } +# fixed_ips: [{"ip_address": {get_param: vsrx_fw_1_GN_direct_ip}}] + security_groups: [{get_resource: segw_security_group}] + + port_vsrx_fw_1_HSL: + type: OS::Neutron::Port + properties: + network: { get_resource: hsl_direct_net } + security_groups: [{get_resource: segw_security_group}] + + server_vsrx_fw_2: + type: OS::Nova::Server + properties: + name: { get_param: vsrx_fw_2_name } + image: { get_param: image_vsrxfw_name } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: flavor_vsrxfw_name } + scheduler_hints: { group: { get_resource: vSRXFW_Affinity } } + networks: + - port: { get_resource: port_vsrx_fw_2_oam_mgmt } + - port: { get_resource: port_vsrx_fw_2_dummi } + - port: { get_resource: port_vsrx_fw_2_OAM } + - port: { get_resource: port_vsrx_fw_2_HSL } + + metadata: + vnf_id: { get_param: vnf_id } + + port_vsrx_fw_2_oam_mgmt: + type: OS::Neutron::Port + properties: + network: { get_param: oam_mgmt_net_0_id } + security_groups: [{get_resource: segw_security_group}] + + port_vsrx_fw_2_dummi: + type: OS::Neutron::Port + properties: + network: { get_resource: Dummi0_net } + security_groups: [{get_resource: segw_security_group}] + + port_vsrx_fw_2_OAM: + type: OS::Neutron::Port + properties: + network: { get_param: Mobility_OAM_protected_net_0_id } +# fixed_ips: [{"ip_address": {get_param: vsrx_fw_2_OAM_protected_ip}}] + security_groups: [{get_resource: segw_security_group}] + + port_vsrx_fw_2_HSL: + type: OS::Neutron::Port + properties: + network: { get_resource: hsl_direct_net } + security_groups: [{get_resource: segw_security_group}] + + server_vsrx_fw_3: + type: OS::Nova::Server + properties: + name: { get_param: vsrx_fw_3_name } + image: { get_param: image_vsrxfw_name } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: flavor_vsrxfw_name } + scheduler_hints: { group: { get_resource: vSRXFW_Affinity } } + networks: + - port: { get_resource: port_vsrx_fw_3_oam_mgmt } + - port: { get_resource: port_vsrx_fw_3_dummi } + - port: { get_resource: port_vsrx_fw_3_OAM } + - port: { get_resource: port_vsrx_fw_3_HSL } + + metadata: + vnf_id: { get_param: vnf_id } + + port_vsrx_fw_3_oam_mgmt: + type: OS::Neutron::Port + properties: + network: { get_param: oam_mgmt_net_0_id } + security_groups: [{get_resource: segw_security_group}] + + port_vsrx_fw_3_dummi: + type: OS::Neutron::Port + properties: + network: { get_resource: Dummi1_net } + security_groups: [{get_resource: segw_security_group}] + + port_vsrx_fw_3_OAM: + type: OS::Neutron::Port + properties: + network: { get_param: Mobility_OAM_protected_net_1_id } +# fixed_ips: [{"ip_address": {get_param: vsrx_fw_3_OAM_protected_ip}}] + security_groups: [{get_resource: segw_security_group}] + + port_vsrx_fw_3_HSL: + type: OS::Neutron::Port + properties: + network: { get_resource: hsl_direct_net } + security_groups: [{get_resource: segw_security_group}] + +conditions: + cd1: True + cd2: + get_param: param1 + cd3: + equals: + - get_param: param2 + - yes + cd4: + not: + equals: + - get_param: param3 + - yes + cd5: + and: + - equals: + - get_param: env_type + - prod + - not: + equals: + - get_param: zone + - beijing + cd6: + or: + - equals: + - get_param: zone + - shanghai + - equals: + - get_param: zone + - beijing + cd7: + not: cd4 + cd8: + and: + - cd1 + - cd2 + create_prod_res: {equals : [{get_param: env_type}, "prod"]} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/pom.xml b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/pom.xml new file mode 100644 index 0000000000..d0512a480d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/pom.xml @@ -0,0 +1,45 @@ + + + 4.0.0 + + + org.openecomp.sdc + openecomp-sdc-action-lib + 1.0.0-SNAPSHOT + + + openecomp-sdc-action-api + + + + + org.openecomp.core + openecomp-core-lib + pom + ${project.version} + + + org.openecomp.core + openecomp-facade-core + ${project.version} + + + org.openecomp.core + openecomp-nosqldb-core + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-versioning-api + ${project.version} + + + com.fasterxml.jackson.core + jackson-annotations + 2.7.4 + + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/ActionConstants.java b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/ActionConstants.java new file mode 100644 index 0000000000..625ce7efe8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/ActionConstants.java @@ -0,0 +1,104 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.action; + +public class ActionConstants { + + // + public static final long MAX_ACTION_ARTIFACT_SIZE = 20 * 1024 * 1024; //20 MB + //REST layer constants + public static final String X_ECOMP_INSTANCE_ID_HEADER_PARAM = "X-ECOMP-InstanceID"; + public static final String X_ECOMP_REQUEST_ID_HEADER_PARAM = "X-ECOMP-RequestID"; + public static final String WWW_AUTHENTICATE_HEADER_PARAM = "WWW-Authenticate"; + + public static final String ACTION_REQUEST_PARAM_NAME = "name"; + public static final String ACTION_REQUEST_PARAM_END_POINT_URI = "endpointUri"; + public static final String SUPPORTED_MODELS_VERSION_ID = "versionId"; + public static final String SUPPORTED_COMPONENTS_ID = "Id"; + public static final String ACTION_REQUEST_PARAM_SUPPORTED_MODELS = SUPPORTED_MODELS_VERSION_ID + + " in supportedModels"; + public static final String ACTION_REQUEST_PARAM_SUPPORTED_COMPONENTS = + SUPPORTED_COMPONENTS_ID + " in supportedComponents"; + + public static final String REQUEST_EMPTY_BODY = "{}"; + public static final String REQUEST_TYPE_CREATE_ACTION = "REQUEST_CREATE_ACTION"; + public static final String REQUEST_TYPE_UPDATE_ACTION = "REQUEST_UPDATE_ACTION"; + public static final String REQUEST_TYPE_VERSION_ACTION = "REQUEST_VERSION_ACTION"; + + //DAO layer constants + public static final String ACTION_VERSIONABLE_TYPE = "Action"; + + //Manager constants + public static final String UNIQUE_ID = "actionUuId"; + public static final String VERSION = "version"; + public static final String INVARIANTUUID = "actionInvariantUuId"; + public static final String STATUS = "status"; + public static final String ARTIFACTS = "artifacts"; + public static final String TIMESTAMP = "timeStamp"; + public static final String UPDATED_BY = "updatedBy"; + public static final String ARTIFACT_NAME = "artifactName"; + public static final String ARTIFACT_FILE = "Artifact to be uploaded"; + + // Status + public static final String UNDO_CHECKOUT_RESPONSE_TEXT = + "Changes to the Action object successfully reverted back."; + + //GET Request Filter Types + public static final String FILTER_TYPE_VENDOR = "VENDOR"; + public static final String FILTER_TYPE_CATEGORY = "CATEGORY"; + public static final String FILTER_TYPE_NAME = "NAME"; + public static final String FILTER_TYPE_MODEL = "MODEL"; + public static final String FILTER_TYPE_ECOMP_COMPONENT = "ECOMP_COMPONENT"; + public static final String FILTER_TYPE_NONE = "NONE"; + + public static final String ARTIFACT_METADATA_ATTR_UUID = "ARTIFACT_UUID"; + public static final String ARTIFACT_METADATA_ATTR_NAME = "ARTIFACT_NAME"; + + public static final String REQUEST_ID = "uuid"; + public static final String SERVICE_INSTANCE_ID = "serviceInstanceID"; + public static final String PARTNER_NAME = "userId"; + public static final String SERVICE_NAME = "ServiceName"; + public static final String INSTANCE_UUID = "InstanceUUID"; + public static final String REMOTE_HOST = "RemoteHost"; + public static final String CLIENT_IP = "ClientIP"; + public static final String CATEGORY_LOG_LEVEL = "level"; + public static final String STATUS_CODE = "StatusCode"; + public static final String RESPONSE_CODE = "ResponseCode"; + public static final String RESPONSE_DESCRIPTION = "ResponseDescription"; + public static final String ELAPSED_TIME = "ElapsedTime"; + public static final String BEGIN_TIMESTAMP = "BeginTimestamp"; + public static final String TARGET_SERVICE_NAME = "TargetServiceName"; + public static final String TARGET_ENTITY = "TargetEntity"; + public static final String TARGET_ENTITY_API = "API"; + public static final String TARGET_ENTITY_DB = "DB"; + public static final String END_TIMESTAMP = "EndTimestamp"; + public static final String ERROR_CATEGORY = "ErrorCategory"; + public static final String ERROR_CODE = "ErrorCode"; + public static final String ERROR_DESCRIPTION = "ErrorDescription"; + public static final String MDC_ASDC_INSTANCE_UUID = "ASDC"; + public static final String SERVICE_METRIC_BEGIN_TIMESTAMP = "SERVICE-METRIC-BEGIN-TIMESTAMP"; + public static final String LOCAL_ADDR = "localAddr"; //map ServerIPAddress from loggingfilter + public static final String BE_FQDN = "beFqdn"; //map ServerFQDN from logging filter + + public final class UniqueValues { + public static final String ACTION_NAME = "Action name"; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/dao/ActionArtifactDao.java b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/dao/ActionArtifactDao.java new file mode 100644 index 0000000000..a120645512 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/dao/ActionArtifactDao.java @@ -0,0 +1,34 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.action.dao; + +import org.openecomp.core.dao.BaseDao; +import org.openecomp.sdc.action.dao.types.ActionArtifactEntity; +import org.openecomp.sdc.action.types.ActionArtifact; + +public interface ActionArtifactDao extends BaseDao { + + void uploadArtifact(ActionArtifact data); + + ActionArtifact downloadArtifact(int effectiveVersion, String artifactUuId); + + void updateArtifact(ActionArtifact data); +} diff --git a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/dao/ActionArtifactDaoFactory.java b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/dao/ActionArtifactDaoFactory.java new file mode 100644 index 0000000000..f0936976ba --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/dao/ActionArtifactDaoFactory.java @@ -0,0 +1,31 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.action.dao; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; + +public abstract class ActionArtifactDaoFactory extends AbstractComponentFactory { + + public static ActionArtifactDaoFactory getInstance() { + return AbstractFactory.getInstance(ActionArtifactDaoFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/dao/ActionDao.java b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/dao/ActionDao.java new file mode 100644 index 0000000000..01f5014ad4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/dao/ActionDao.java @@ -0,0 +1,51 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.action.dao; + +import org.openecomp.core.dao.BaseDao; +import org.openecomp.sdc.action.dao.types.ActionEntity; +import org.openecomp.sdc.action.errors.ActionException; +import org.openecomp.sdc.action.types.Action; +import org.openecomp.sdc.action.types.EcompComponent; +import org.openecomp.sdc.versioning.dao.VersionableDao; + +import java.util.List; + +public interface ActionDao extends VersionableDao, BaseDao { + + Action createAction(Action actionDto) throws ActionException; + + Action updateAction(Action actionDto) throws ActionException; + + void deleteAction(String actionInvariantUuId) throws ActionException; + + List getFilteredActions(String filterType, String filterId) throws ActionException; + + Action getActionsByActionUuId(String uniqueId) throws ActionException; + + List getEcompComponents() throws ActionException; + + List getActionsByActionInvariantUuId(String actionInvariantUuId) + throws ActionException; + + Action getLockedAction(String actionInvariantUuId, String user) throws ActionException; + +} diff --git a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/dao/ActionDaoFactory.java b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/dao/ActionDaoFactory.java new file mode 100644 index 0000000000..d8b0c1889e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/dao/ActionDaoFactory.java @@ -0,0 +1,31 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.action.dao; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; + +public abstract class ActionDaoFactory extends AbstractComponentFactory { + + public static ActionDaoFactory getInstance() { + return AbstractFactory.getInstance(ActionDaoFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/dao/types/ActionArtifactEntity.java b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/dao/types/ActionArtifactEntity.java new file mode 100644 index 0000000000..7e56a04e1b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/dao/types/ActionArtifactEntity.java @@ -0,0 +1,89 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.action.dao.types; + +import com.datastax.driver.mapping.annotations.Column; +import com.datastax.driver.mapping.annotations.PartitionKey; +import com.datastax.driver.mapping.annotations.Table; +import org.openecomp.sdc.action.types.ActionArtifact; + +import java.nio.ByteBuffer; + +@Table(keyspace = "dox", name = "action_artifact") +public class ActionArtifactEntity { + + @PartitionKey + @Column(name = "artifactuuid") + private String artifactUuId; + + @PartitionKey(value = 1) + @Column(name = "effective_version") + private int effectiveVersion; + + @Column(name = "artifact") + private ByteBuffer artifact; + + public ActionArtifactEntity() { + //Default constructor implementation + } + + public ActionArtifactEntity(String artifactUuId, int effectiveVersion) { + this.artifactUuId = artifactUuId; + this.effectiveVersion = effectiveVersion; + } + + public String getArtifactUuId() { + return artifactUuId; + } + + public void setArtifactUuId(String artifactUuId) { + this.artifactUuId = artifactUuId; + } + + public int getEffectiveVersion() { + return effectiveVersion; + } + + public void setEffectiveVersion(int effectiveVersion) { + this.effectiveVersion = effectiveVersion; + } + + public ByteBuffer getArtifact() { + return artifact; + } + + public void setArtifact(ByteBuffer artifact) { + this.artifact = artifact; + } + + /** + * To dto action artifact. + * + * @return the action artifact + */ + public ActionArtifact toDto() { + ActionArtifact destination = new ActionArtifact(); + destination.setArtifactUuId(this.getArtifactUuId()); + destination.setEffectiveVersion(this.getEffectiveVersion()); + destination.setArtifact(this.getArtifact().array()); + return destination; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/dao/types/ActionEntity.java b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/dao/types/ActionEntity.java new file mode 100644 index 0000000000..9aa9e8d375 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/dao/types/ActionEntity.java @@ -0,0 +1,224 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.action.dao.types; + +import com.datastax.driver.mapping.annotations.Column; +import com.datastax.driver.mapping.annotations.Frozen; +import com.datastax.driver.mapping.annotations.PartitionKey; +import com.datastax.driver.mapping.annotations.Table; +import org.openecomp.core.utilities.json.JsonUtil; +import org.openecomp.sdc.action.types.Action; +import org.openecomp.sdc.versioning.dao.types.Version; + + +import java.util.ArrayList; +import java.util.Date; +import java.util.List; +import java.util.stream.Collectors; + +@Table(keyspace = "dox", name = "Action") +public class ActionEntity { + + @Column(name = "actionUUID") + private String actionUuId; + @PartitionKey(value = 0) + @Column(name = "actionInvariantUUID") + private String actionInvariantUuId; + @PartitionKey(value = 1) + @Frozen + @Column(name = "version") + private Version version; + @Column(name = "status") + private String status; + @Column(name = "name") + private String name; + @Column(name = "vendor_list") + private List vendorList; + @Column(name = "category_list") + private List categoryList; + @Column(name = "timestamp") + private Date timestamp; + @Column(name = "user") + private String user; + @Column(name = "supportedModels") + private List supportedModels; + @Column(name = "supportedComponents") + private List supportedComponents; + @Column(name = "data") + private String data; + + public ActionEntity() { + } + + public ActionEntity(String actionInvariantUuId, Version version) { + this.actionInvariantUuId = actionInvariantUuId; + this.version = version; + } + + public String getActionUuId() { + return actionUuId; + } + + public void setActionUuId(String actionUuId) { + this.actionUuId = actionUuId; + } + + public String getActionInvariantUuId() { + return actionInvariantUuId; + } + + public void setActionInvariantUuId(String actionInvariantUuId) { + this.actionInvariantUuId = actionInvariantUuId; + } + + public Version getVersion() { + return version; + } + + public void setVersion(Version version) { + this.version = version; + } + + public String getStatus() { + return status; + } + + public void setStatus(String status) { + this.status = status; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public List getVendorList() { + return vendorList; + } + + /** + * Sets vendor list. + * + * @param vendorList the vendor list + */ + public void setVendorList(List vendorList) { + if (vendorList != null && !vendorList.isEmpty()) { + List lowerCaseVendorList = new ArrayList<>(); + lowerCaseVendorList + .addAll(vendorList.stream().map(String::toLowerCase).collect(Collectors.toList())); + this.vendorList = lowerCaseVendorList; + } else { + this.vendorList = vendorList; + } + } + + public List getCategoryList() { + return categoryList; + } + + /** + * Sets category list. + * + * @param categoryList the category list + */ + public void setCategoryList(List categoryList) { + if (categoryList != null && !categoryList.isEmpty()) { + List lowerCaseCategoryList = new ArrayList<>(); + lowerCaseCategoryList + .addAll(categoryList.stream().map(String::toLowerCase).collect(Collectors.toList())); + this.categoryList = lowerCaseCategoryList; + } else { + this.categoryList = categoryList; + } + } + + public Date getTimestamp() { + return timestamp; + } + + public void setTimestamp(Date timestamp) { + this.timestamp = timestamp; + } + + public String getUser() { + return user; + } + + public void setUser(String user) { + this.user = user; + } + + public List getSupportedModels() { + return supportedModels; + } + + public void setSupportedModels(List supportedModels) { + this.supportedModels = supportedModels; + } + + public List getSupportedComponents() { + return supportedComponents; + } + + public void setSupportedComponents(List supportedComponents) { + this.supportedComponents = supportedComponents; + } + + public String getData() { + return data; + } + + public void setData(String data) { + this.data = data; + } + + /** + * To dto action. + * + * @return the action + */ + public Action toDto() { + //Action destination = new Action(); + + Action destination = JsonUtil.json2Object(this.getData(), Action.class); + destination.setData(this.getData()); + destination.setTimestamp(this.getTimestamp()); + destination.setUser(this.getUser()); + destination.setData(this.getData()); + return destination; + } + + /*private List> createMapFromList(List list, String idName){ + List> keyValueList = new ArrayList<>(); + if(list != null && !list.isEmpty()){ + for(String attributeId : list){ + HashMap attributeIdMap = new HashMap<>(); + attributeIdMap.put(idName,attributeId); + keyValueList.add(attributeIdMap); + } + return keyValueList; + } + return null; + }*/ +} diff --git a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/dao/types/EcompComponentEntity.java b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/dao/types/EcompComponentEntity.java new file mode 100644 index 0000000000..9a71023629 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/dao/types/EcompComponentEntity.java @@ -0,0 +1,73 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.action.dao.types; + +import com.datastax.driver.mapping.annotations.Column; +import com.datastax.driver.mapping.annotations.PartitionKey; +import com.datastax.driver.mapping.annotations.Table; +import org.openecomp.sdc.action.types.EcompComponent; + +@Table(keyspace = "dox", name = "ECOMPComponent") +public class EcompComponentEntity { + + @PartitionKey + @Column(name = "id") + private String id; + + @Column(name = "name") + private String name; + + public EcompComponentEntity() { + } + + public EcompComponentEntity(String id, String name) { + this.id = id; + this.name = name; + } + + public String getId() { + return id; + } + + public void setId(String id) { + this.id = id; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + /** + * To dto ecomp component. + * + * @return the ecomp component + */ + public EcompComponent toDto() { + EcompComponent destination = new EcompComponent(); + destination.setId(this.getId()); + destination.setName(this.getName()); + return destination; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/errors/ActionErrorConstants.java b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/errors/ActionErrorConstants.java new file mode 100644 index 0000000000..092d9abee5 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/errors/ActionErrorConstants.java @@ -0,0 +1,136 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.action.errors; + +public class ActionErrorConstants { + + //Error Codes + public static final String ACTION_REQUEST_INVALID_GENERIC_CODE = "ACT0001"; + public static final String ACTION_AUTHENTICATION_ERR_CODE = "ACT1000"; + public static final String ACTION_AUTHORIZATION_ERR_CODE = "ACT1001"; + public static final String ACTION_INVALID_INSTANCE_ID_CODE = "ACT1002"; + public static final String ACTION_INVALID_REQUEST_ID_CODE = "ACT1003"; + public static final String ACTION_INVALID_PARAM_CODE = "ACT1004"; + //Operation is not supported + public static final String ACTION_INVALID_REQUEST_BODY_CODE = "ACT1005"; + //ACTION_REQUEST_BODY_EMPTY + public static final String ACTION_UPDATE_NOT_ALLOWED_CODE_NAME = "ACT1007"; + public static final String ACTION_CHECKOUT_ON_LOCKED_ENTITY = "ACT1008"; + public static final String ACTION_ENTITY_UNIQUE_VALUE_ERROR = "ACT1009"; + + public static final String ACTION_INVALID_SEARCH_CRITERIA = "ACT1011"; + public static final String ACTION_MULT_SEARCH_CRITERIA = "ACT1012"; + public static final String ACTION_UPDATE_ON_UNLOCKED_ENTITY = "ACT1013"; + public static final String ACTION_UPDATE_INVALID_VERSION = "ACT1014"; + public static final String ACTION_UPDATE_NOT_ALLOWED_CODE = "ACT1015"; + + public static final String ACTION_CHECKIN_ON_UNLOCKED_ENTITY = "ACT1017"; + public static final String ACTION_SUBMIT_FINALIZED_ENTITY_NOT_ALLOWED = "ACT1018"; + public static final String ACTION_SUBMIT_LOCKED_ENTITY_NOT_ALLOWED = "ACT1019"; + public static final String ACTION_UNDO_CHECKOUT_ON_UNLOCKED_ENTITY = "ACT1020"; + public static final String ACTION_NOT_LOCKED_CODE = "ACT1021"; + public static final String ACTION_ARTIFACT_CHECKSUM_ERROR_CODE = "ACT1022"; + public static final String ACTION_ARTIFACT_TOO_BIG_ERROR_CODE = "ACT1023"; + public static final String ACTION_ARTIFACT_ALREADY_EXISTS_CODE = "ACT1025"; + public static final String ACTION_ARTIFACT_UPDATE_READ_ONLY = "ACT1026"; + public static final String ACTION_ARTIFACT_DELETE_READ_ONLY = "ACT1027"; + public static final String ACTION_ARTIFACT_INVALID_PROTECTION_CODE = "ACT1028"; + public static final String ACTION_ARTIFACT_INVALID_NAME_CODE = "ACT1029"; + + public static final String ACTION_EDIT_ON_ENTITY_LOCKED_BY_OTHER_USER = "ACT1041"; + public static final String ACTION_CHECKIN_ON_ENTITY_LOCKED_BY_OTHER_USER = "ACT1042"; + public static final String ACTION_CHECKOUT_ON_LOCKED_ENTITY_OTHER_USER = "ACT1043"; + public static final String ACTION_UNDO_CHECKOUT_ON_ENTITY_LOCKED_BY_OTHER_USER = "ACT1044"; + public static final String ACTION_ENTITY_NOT_EXIST_CODE = "ACT1045"; + public static final String ACTION_ARTIFACT_ENTITY_NOT_EXIST_CODE = "ACT1046"; + public static final String ACTION_ARTIFACT_DEL_LOCKED_OTHER_USER_CODE = "ACT1047"; + public static final String ACTION_DELETE_ON_LOCKED_ENTITY_CODE = "ACT1048"; + + public static final String ACTION_INTERNAL_SERVER_ERR_CODE = "ACT1060"; + public static final String ACTION_QUERY_FAILURE_CODE = "QUERY_FAILURE"; + public static final String ACTION_QUERY_FAILURE_MSG = "Query Failure"; + + + //Error Messages + public static final String ACTION_REQUEST_BODY_EMPTY = "Request Body is missing"; + //"The API failed due to missing body"; + public static final String ACTION_REQUEST_MISSING_MANDATORY_PARAM = + "Missing mandatory parameter(s) : "; + public static final String ACTION_REQUEST_ECOMP_INSTANCE_ID_INVALID = + "X-ECOMP-InstanceID HTTP header missing or empty"; + public static final String ACTION_REQUEST_ECOMP_REQUEST_ID_INVALID = + "X-ECOMP-RequestID HTTP header missing or empty"; + public static final String ACTION_REQUEST_CONTENT_TYPE_INVALID = + "Content-Type HTTP header missing or empty"; + public static final String ACTION_REQUEST_AUTHORIZATION_HEADER_INVALID = + "Authentication is required to use the API"; + public static final String ACTION_REQUEST_INVALID_NAME = + "Invalid syntax for action name. No whitespaces allowed."; + public static final String ACTION_REQUEST_FILTER_PARAM_INVALID = + "Invalid Search filter criteria provided"; + public static final String ACTION_FILTER_MULTIPLE_QUERY_PARAM_NOT_SUPPORTED = + "Multiple filter criteria are not supported"; + //"Operation supports filter by one property at a time"; + public static final String ACTION_ARTIFACT_ENTITY_NOT_EXIST = "Specified artifact is not found"; + public static final String ACTION_REQUEST_ARTIFACT_CHECKSUM_ERROR = "Checksum error"; + public static final String ACTION_REQUEST_ARTIFACT_INVALID_PROTECTION_VALUE = + "Invalid artifact protection value"; + + public static final String ACTION_ARTIFACT_INVALID_NAME = + "Artifact name cannot contain any of the following characters : #<>$+%!`&*'|{}?=/:@ " + + "including whitespaces, double quotes and back-slash"; + public static final String ACTION_ARTIFACT_READ_FILE_ERROR = "Error Occurred while reading file"; + public static final String ACTION_REQUEST_ARTIFACT_OPERATION_ALLOWED = + "Artifacts cannot be created/updated using this operation"; + public static final String ACTION_ARTIFACT_TOO_BIG_ERROR = + "Operation is not allowed. Artifact size exceeds the maximum file size limit (20MB)."; + + //Business Validation Error messages + public static final String ACTION_UPDATE_NOT_ALLOWED_FOR_NAME = + "Action Name update is not allowed"; + public static final String ACTION_UPDATE_PARAM_INVALID = + "Update not allowed for the parameter(s) : %s"; + public static final String ACTION_ENTITY_NOT_EXIST = "Specified Action is not found"; + public static final String ACTION_REQUESTED_VERSION_INVALID = "Invalid requested version : %s"; + public static final String ACTION_UNSUPPORTED_OPERATION = "Operation %s not supported"; + public static final String ACTION_ENTITY_UNIQUE_VALUE_MSG = + "%s with the value '%s' already exists."; + public static final String ACTION_ARTIFACT_ALREADY_EXISTS = + "Artifact name already exists for Action with id %s. Please use another name."; + public static final String ACTION_ENTITY_INTERNAL_SERVER_ERROR_MSG = + "The request failed due to an internal ASDC problem. ECOMP Component should continue the " + + "attempts, with corrected data if required, to create the resource."; + public static final String ACTION_ARTIFACT_DELETE_READ_ONLY_MSG = + "Cannot delete read only artifact."; + public static final String ACTION_ARTIFACT_UPDATE_READ_ONLY_MSG = + "Cannot update read only artifact."; + public static final String ACTION_NOT_LOCKED_MSG = + "Operation is not allowed. Action status should be Locked."; + public static final String ACTION_ARTIFACT_UPDATE_NAME_INVALID = + "Artifact name cannot be updated."; + public static final String ACTION_ARTIFACT_DEL_LOCKED_OTHER_USER = + "Cannot delete artifact since it is locked by other user %s."; + public static final String UNDO_CHECKOUT_ON_UNLOCKED_ENTITY_MSG = + "Can not undo checkout on versionable entity %s with id %s since it is not checked out."; + public static final String UNDO_CHECKOUT_ON_ENTITY_LOCKED_BY_OTHER_USER_MSG = + "Can not undo checkout on versionable entity %s with id" + + " %s since it is checked out by other user: %s."; +} diff --git a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/errors/ActionException.java b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/errors/ActionException.java new file mode 100644 index 0000000000..fff88d6f84 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/errors/ActionException.java @@ -0,0 +1,52 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.action.errors; + +public class ActionException extends RuntimeException { + + private String errorCode; + private String description; + + public ActionException() { + + } + + public ActionException(String errorCode, String description) { + this.errorCode = errorCode; + this.description = description; + } + + public String getErrorCode() { + return errorCode; + } + + public void setErrorCode(String errorCode) { + this.errorCode = errorCode; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/errors/ActionExceptionMapper.java b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/errors/ActionExceptionMapper.java new file mode 100644 index 0000000000..23c14aaaa2 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/errors/ActionExceptionMapper.java @@ -0,0 +1,114 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.action.errors; + +import org.openecomp.sdc.action.ActionConstants; + +import javax.ws.rs.core.MediaType; +import javax.ws.rs.core.Response; +import javax.ws.rs.ext.ExceptionMapper; + +public class ActionExceptionMapper implements ExceptionMapper { + + @Override + public Response toResponse(ActionException actionException) { + Response response; + String errorCode = actionException.getErrorCode(); + switch (errorCode) { + case ActionErrorConstants.ACTION_REQUEST_INVALID_GENERIC_CODE: + case ActionErrorConstants.ACTION_INVALID_INSTANCE_ID_CODE: + case ActionErrorConstants.ACTION_INVALID_REQUEST_ID_CODE: + case ActionErrorConstants.ACTION_INVALID_REQUEST_BODY_CODE: + case ActionErrorConstants.ACTION_INVALID_PARAM_CODE: + case ActionErrorConstants.ACTION_UPDATE_NOT_ALLOWED_FOR_NAME: + case ActionErrorConstants.ACTION_CHECKOUT_ON_LOCKED_ENTITY: + case ActionErrorConstants.ACTION_ENTITY_UNIQUE_VALUE_ERROR: + case ActionErrorConstants.ACTION_INVALID_SEARCH_CRITERIA: + case ActionErrorConstants.ACTION_MULT_SEARCH_CRITERIA: + case ActionErrorConstants.ACTION_UPDATE_ON_UNLOCKED_ENTITY: + case ActionErrorConstants.ACTION_UPDATE_INVALID_VERSION: + case ActionErrorConstants.ACTION_UPDATE_NOT_ALLOWED_CODE: + case ActionErrorConstants.ACTION_CHECKIN_ON_UNLOCKED_ENTITY: + case ActionErrorConstants.ACTION_SUBMIT_FINALIZED_ENTITY_NOT_ALLOWED: + case ActionErrorConstants.ACTION_SUBMIT_LOCKED_ENTITY_NOT_ALLOWED: + case ActionErrorConstants.ACTION_UNDO_CHECKOUT_ON_UNLOCKED_ENTITY: + case ActionErrorConstants.ACTION_UPDATE_NOT_ALLOWED_CODE_NAME: + case ActionErrorConstants.ACTION_ARTIFACT_CHECKSUM_ERROR_CODE: + case ActionErrorConstants.ACTION_ARTIFACT_ALREADY_EXISTS_CODE: + case ActionErrorConstants.ACTION_ARTIFACT_INVALID_NAME_CODE: + case ActionErrorConstants.ACTION_ARTIFACT_TOO_BIG_ERROR_CODE: + case ActionErrorConstants.ACTION_ARTIFACT_INVALID_PROTECTION_CODE: + case ActionErrorConstants.ACTION_ARTIFACT_DELETE_READ_ONLY: + case ActionErrorConstants.ACTION_NOT_LOCKED_CODE: + response = Response + .status(Response.Status.BAD_REQUEST) + .entity(new ActionExceptionResponse(errorCode, + Response.Status.BAD_REQUEST.getReasonPhrase(), actionException.getDescription())) + .type(MediaType.APPLICATION_JSON) + .build(); + break; + case ActionErrorConstants.ACTION_AUTHENTICATION_ERR_CODE: + response = Response + .status(Response.Status.UNAUTHORIZED) + .header(ActionConstants.WWW_AUTHENTICATE_HEADER_PARAM, + ActionErrorConstants.ACTION_REQUEST_AUTHORIZATION_HEADER_INVALID) + .entity(new ActionExceptionResponse(errorCode, + Response.Status.UNAUTHORIZED.getReasonPhrase(), actionException.getDescription())) + .type(MediaType.APPLICATION_JSON) + .build(); + break; + case ActionErrorConstants.ACTION_AUTHORIZATION_ERR_CODE: + case ActionErrorConstants.ACTION_EDIT_ON_ENTITY_LOCKED_BY_OTHER_USER: + case ActionErrorConstants.ACTION_CHECKIN_ON_ENTITY_LOCKED_BY_OTHER_USER: + case ActionErrorConstants.ACTION_CHECKOUT_ON_LOCKED_ENTITY_OTHER_USER: + case ActionErrorConstants.ACTION_UNDO_CHECKOUT_ON_ENTITY_LOCKED_BY_OTHER_USER: + case ActionErrorConstants.ACTION_DELETE_ON_LOCKED_ENTITY_CODE: + case ActionErrorConstants.ACTION_ARTIFACT_DEL_LOCKED_OTHER_USER_CODE: + case ActionErrorConstants.ACTION_ARTIFACT_UPDATE_READ_ONLY: + response = Response + .status(Response.Status.FORBIDDEN) + .entity( + new ActionExceptionResponse(errorCode, Response.Status.FORBIDDEN.getReasonPhrase(), + actionException.getDescription())).type(MediaType.APPLICATION_JSON) + .build(); + break; + case ActionErrorConstants.ACTION_ENTITY_NOT_EXIST_CODE: + case ActionErrorConstants.ACTION_ARTIFACT_ENTITY_NOT_EXIST_CODE: + response = Response + .status(Response.Status.NOT_FOUND) + .entity( + new ActionExceptionResponse(errorCode, Response.Status.NOT_FOUND.getReasonPhrase(), + actionException.getDescription())).type(MediaType.APPLICATION_JSON) + .build(); + break; + case ActionErrorConstants.ACTION_INTERNAL_SERVER_ERR_CODE: + default: + response = Response + .status(Response.Status.INTERNAL_SERVER_ERROR) + .entity(new ActionExceptionResponse(errorCode, + Response.Status.INTERNAL_SERVER_ERROR.getReasonPhrase(), + actionException.getDescription())) + .type(MediaType.APPLICATION_JSON) + .build(); + } + return response; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/errors/ActionExceptionResponse.java b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/errors/ActionExceptionResponse.java new file mode 100644 index 0000000000..51848464a7 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/errors/ActionExceptionResponse.java @@ -0,0 +1,66 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.action.errors; + +public class ActionExceptionResponse { + private String code; + private String description; + private String message; + + /** + * Instantiates a new Action exception response. + * + * @param code the code + * @param description the description + * @param message the message + */ + public ActionExceptionResponse(String code, String description, String message) { + this.code = code; + this.description = description; + this.message = message; + } + + public String getCode() { + return code; + } + + public void setCode(String code) { + this.code = code; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public String getMessage() { + return message; + } + + public void setMessage(String message) { + this.message = message; + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/logging/CategoryLogLevel.java b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/logging/CategoryLogLevel.java new file mode 100644 index 0000000000..d87bed310f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/logging/CategoryLogLevel.java @@ -0,0 +1,29 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.action.logging; + +public enum CategoryLogLevel { + INFO, + WARN, + DEBUG, + ERROR, + FATAL +} diff --git a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/logging/StatusCode.java b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/logging/StatusCode.java new file mode 100644 index 0000000000..b0d5bab12b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/logging/StatusCode.java @@ -0,0 +1,26 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.action.logging; + +public enum StatusCode { + COMPLETE, + ERROR +} diff --git a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/Action.java b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/Action.java new file mode 100644 index 0000000000..176d443a81 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/Action.java @@ -0,0 +1,255 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.action.types; + +import org.openecomp.sdc.action.ActionConstants; +import org.openecomp.sdc.action.dao.types.ActionEntity; +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.util.ArrayList; +import java.util.Date; +import java.util.HashMap; +import java.util.List; + +public class Action implements Comparable { + private String actionUuId; + private String actionInvariantUuId; + private String version; + private ActionStatus status; + private String name; + private String displayName; + private String endpointUri; + private List vendorList; + private List categoryList; + private Date timestamp; + private String user; + private List> supportedModels; + private List> supportedComponents; + //private List> artifacts; + private List artifacts; + private String data; + + public Action() { + } + + /** + * Instantiates a new Action. + * + * @param action the action + */ + public Action(Action action) { + this.actionUuId = action.getActionUuId(); + this.actionInvariantUuId = action.getActionInvariantUuId(); + this.name = action.getName(); + this.setDisplayName(action.getDisplayName()); + this.setVendorList(action.getVendorList()); + this.setCategoryList(action.getCategoryList()); + this.setTimestamp(action.getTimestamp()); + this.setUser(action.getUser()); + this.version = action.getVersion(); + this.status = action.getStatus(); + this.data = action.getData(); + this.supportedComponents = action.getSupportedComponents(); + this.supportedModels = action.getSupportedModels(); + this.artifacts = action.getArtifacts(); + } + + public String getActionUuId() { + return actionUuId; + } + + public void setActionUuId(String actionUuId) { + this.actionUuId = actionUuId; + } + + public String getActionInvariantUuId() { + return actionInvariantUuId; + } + + public void setActionInvariantUuId(String actionInvariantUuId) { + this.actionInvariantUuId = actionInvariantUuId; + } + + public String getVersion() { + return version; + } + + public void setVersion(String version) { + this.version = version; + } + + public ActionStatus getStatus() { + return status; + } + + public void setStatus(ActionStatus status) { + this.status = status; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getDisplayName() { + return displayName; + } + + public void setDisplayName(String displayName) { + this.displayName = displayName; + } + + public String getEndpointUri() { + return endpointUri; + } + + public void setEndpointUri(String endpointUri) { + this.endpointUri = endpointUri; + } + + public List getVendorList() { + return vendorList; + } + + public void setVendorList(List vendorList) { + this.vendorList = vendorList; + } + + public List getCategoryList() { + return categoryList; + } + + public void setCategoryList(List categoryList) { + this.categoryList = categoryList; + } + + public Date getTimestamp() { + return timestamp; + } + + public void setTimestamp(Date timestamp) { + this.timestamp = timestamp; + } + + public String getUser() { + return user; + } + + public void setUser(String user) { + this.user = user; + } + + public List> getSupportedModels() { + return supportedModels; + } + + public void setSupportedModels(List> supportedModels) { + this.supportedModels = supportedModels; + } + + public List> getSupportedComponents() { + return supportedComponents; + } + + public void setSupportedComponents(List> supportedComponents) { + this.supportedComponents = supportedComponents; + } + + public List getArtifacts() { + return artifacts; + } + + public void setArtifacts(List artifacts) { + this.artifacts = artifacts; + } + + public String getData() { + return data; + } + + public void setData(String data) { + this.data = data; + } + + /** + * To entity action entity. + * + * @return the action entity + */ + public ActionEntity toEntity() { + ActionEntity destination = new ActionEntity(); + + destination + .setActionUuId(this.getActionUuId() != null ? this.getActionUuId().toUpperCase() : null); + destination.setActionInvariantUuId( + this.getActionInvariantUuId() != null ? this.getActionInvariantUuId().toUpperCase() : null); + destination.setName(this.getName() != null ? this.getName().toLowerCase() : null); + destination.setVendorList(this.getVendorList()); + destination.setCategoryList(this.getCategoryList()); + destination.setTimestamp(this.getTimestamp()); + destination.setUser(this.getUser()); + destination.setVersion(Version.valueOf(this.getVersion())); + if (this.getStatus() != null) { + destination.setStatus(this.getStatus().name()); + } + destination.setSupportedComponents( + getIdFromMap(this.getSupportedComponents(), ActionConstants.SUPPORTED_COMPONENTS_ID)); + destination.setSupportedModels( + getIdFromMap(this.getSupportedModels(), ActionConstants.SUPPORTED_MODELS_VERSION_ID)); + destination.setData(this.getData()); + return destination; + } + + private List getIdFromMap(List> map, String idName) { + List list = new ArrayList<>(); + if (map != null && !map.isEmpty()) { + map.forEach(entry -> { + if (entry.containsKey(idName)) { + list.add(entry.get(idName) != null ? entry.get(idName).toLowerCase() : null); + } + }); + return list; + } + return null; + } + + @Override + public int compareTo(Object object) { + Action obj = (Action) object; + Version thisVersion = Version.valueOf(this.version); + Version objVersion = Version.valueOf(obj.getVersion()); + if (obj.getName().compareTo(this.getName()) == 0) { + return compareVersions(objVersion, thisVersion); + } + return obj.getName().compareTo(this.getName()); + } + + private int compareVersions(Version objVersion, Version thisVersion) { + if (objVersion.getMajor() == thisVersion.getMajor()) { + return Integer.compare(objVersion.getMinor(), thisVersion.getMinor()); + } + return Integer.compare(objVersion.getMajor(), thisVersion.getMajor()); + } + +} diff --git a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/ActionArtifact.java b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/ActionArtifact.java new file mode 100644 index 0000000000..ef41673541 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/ActionArtifact.java @@ -0,0 +1,139 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.action.types; + +import com.fasterxml.jackson.annotation.JsonIgnore; +import org.openecomp.sdc.action.dao.types.ActionArtifactEntity; + +import java.nio.ByteBuffer; +import java.util.Date; + +public class ActionArtifact { + private String artifactUuId; + + @JsonIgnore + private Integer effectiveVersion; + + private String artifactName; + private String artifactLabel; + private String artifactCategory; + private String artifactDescription; + private String artifactProtection; + private Date timestamp; + private byte[] artifact; + + public String getArtifactUuId() { + return artifactUuId; + } + + public void setArtifactUuId(String artifactUuId) { + this.artifactUuId = artifactUuId; + } + + public Integer getEffectiveVersion() { + return effectiveVersion; + } + + public void setEffectiveVersion(Integer effectiveVersion) { + this.effectiveVersion = effectiveVersion; + } + + public String getArtifactName() { + return artifactName; + } + + public void setArtifactName(String artifactName) { + this.artifactName = artifactName; + } + + public String getArtifactLabel() { + return artifactLabel; + } + + public void setArtifactLabel(String artifactLabel) { + this.artifactLabel = artifactLabel; + } + + public String getArtifactCategory() { + return artifactCategory; + } + + public void setArtifactCategory(String artifactCategory) { + this.artifactCategory = artifactCategory; + } + + public String getArtifactDescription() { + return artifactDescription; + } + + public void setArtifactDescription(String artifactDescription) { + this.artifactDescription = artifactDescription; + } + + public String getArtifactProtection() { + return artifactProtection; + } + + public void setArtifactProtection(String artifactProtection) { + this.artifactProtection = artifactProtection; + } + + public Date getTimestamp() { + return timestamp; + } + + public void setTimestamp(Date timestamp) { + this.timestamp = timestamp; + } + + public byte[] getArtifact() { + return artifact; + } + + public void setArtifact(byte[] artifact) { + this.artifact = artifact; + } + + /** + * To entity action artifact entity. + * + * @return the action artifact entity + */ + public ActionArtifactEntity toEntity() { + ActionArtifactEntity destination = new ActionArtifactEntity(); + destination.setArtifactUuId(this.getArtifactUuId()); + destination.setEffectiveVersion(this.getEffectiveVersion()); + destination.setArtifact(ByteBuffer.wrap(this.getArtifact())); + + return destination; + } + + @Override + public boolean equals(Object obj) { + if (obj instanceof ActionArtifact) { + ActionArtifact temp = (ActionArtifact) obj; + if (artifactUuId.equals(temp.getArtifactUuId())) { + return true; + } + } + return false; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/ActionArtifactProtection.java b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/ActionArtifactProtection.java new file mode 100644 index 0000000000..636f24d781 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/ActionArtifactProtection.java @@ -0,0 +1,26 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.action.types; + +public enum ActionArtifactProtection { + readOnly, + readWrite +} diff --git a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/ActionLogResponseCode.java b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/ActionLogResponseCode.java new file mode 100644 index 0000000000..c3de8aa4dc --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/ActionLogResponseCode.java @@ -0,0 +1,90 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.action.types; + +import java.util.HashMap; +import java.util.Map; + +public enum ActionLogResponseCode { + + MISSING_AUTHORIZATION(100), + FORBIDDEN(101), + UPDATE_ON_LOCKED_ENTITY(102), + CHECKIN_ON_LOCKED_ENTITY_OTHER_USER(103), + CHECKOUT_ON_LOCKED_ENTITY(104), + UNDO_CHECKOUT_ON_LOCKED_ENTITY(105), + DELETE_ARTIFACT_ON_LOCKED_ENTITY(106), + DELETE_ON_LOCKED_ENTITY_OTHER_USER(107), + INTERNAL_SERVER_ERROR(201), + MISSING_MANDATORY_PARAMS(300), + MISSING_INSTANCE_ID_HEADER(301), + MISSING_REQUEST_ID_HEADER(302), + MISSING_REQUEST_BODY(303), + INVALID_SEARCH_FILTER_CRITERIA(304), + INVALID_REQUESTED_VERSION(305), + CHECKSUM_ERROR(306), + ARTIFACT_TOO_BIG(307), + ACTION_NOT_FOUND(308), + ARTIFACT_NOT_FOUND(309), + METHOD_NOT_ALLOWED(310), + INVALID_REQUEST_PARAM(311), + ARTIFACT_PROTECTION_INVALID(312), + ACTION_NAME_UPDATE_NOT_ALLOWED(501), + //METHOD_NOT_ALLOWED(502), + ACTION_NAME_ALREADY_EXISTS(503), + MULTIPLE_FILTER_CRITERIA_NOT_SUPPORTED(504), + UPDATE_ON_UNLOCKED_ENTITY(505), + UPDATE_NOT_ALLOWED(506), + //METHOD_NOT_ALLOWED(507), + CHECKIN_ON_UNLOCKED_ENTITY(508), + SUBMIT_ON_FINAL_ENTITY(509), + SUBMIT_ON_LOCKED_ENTITY_OTHER_USER(510), + UNDO_CHECKOUT_ON_UNLOCKED_ENTITY(511), + ACTION_NOT_LOCKED(512), + ARTIFACT_ALREADY_EXISTS(513), + ARTIFACT_UPDATE_READ_ONLY(514), + ARTIFACT_DELETE_READ_ONLY(515), + ARTIFACT_NAME_INVALID(516), + ARTIFACT_CREATE_UPDATE_NOT_ALLOWED(518), + QUERY_FAILURE(519); + + private static Map mapValueToEnum = new HashMap<>(); + + static { + for (ActionLogResponseCode responseCode : ActionLogResponseCode.values()) { + mapValueToEnum.put(responseCode.value, responseCode); + } + } + + private int value; + + ActionLogResponseCode(int value) { + this.value = value; + } + + public static ActionLogResponseCode parseValue(int value) { + return mapValueToEnum.get(value); + } + + public int getValue() { + return value; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/ActionRequest.java b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/ActionRequest.java new file mode 100644 index 0000000000..1a20f9ecb7 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/ActionRequest.java @@ -0,0 +1,40 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.action.types; + +public enum ActionRequest { + CREATE_ACTION, + UPDATE_ACTION, + DELETE_ACTION, + GET_FILTERED_ACTIONS, + GET_ACTIONS_INVARIANT_ID, + GET_ECOMP_COMPONENTS, + ACTION_VERSIONING, + CHECKOUT_ACTION, + CHECKIN_ACTION, + SUBMIT_ACTION, + UNDO_CHECKOUT_ACTION, + UPLOAD_ARTIFACT, + DOWNLOAD_ARTIFACT, + UPDATE_ARTIFACT, + DELETE_ARTIFACT, + GET_ACTION_UUID +} diff --git a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/ActionStatus.java b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/ActionStatus.java new file mode 100644 index 0000000000..af3516e1eb --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/ActionStatus.java @@ -0,0 +1,28 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.action.types; + +public enum ActionStatus { + Locked, + Available, + Final, + Deleted +} diff --git a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/ActionSubOperation.java b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/ActionSubOperation.java new file mode 100644 index 0000000000..0dd97e6646 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/ActionSubOperation.java @@ -0,0 +1,59 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.action.types; + +public enum ActionSubOperation { + //Versioning operations + CREATE_ACTION_VERSION, + CREATE_ACTION_UNIQUE_VALUE, + GET_ACTION_VERSION, + //Action DAO operations + CREATE_ACTION_ENTITY, + GET_ACTIONENTITY_BY_ACTIONINVID, + GET_ACTIONENTITY_BY_ACTIONUUID, + GET_ACTIONENTITY_BY_VENDOR, + GET_ACTIONENTITY_BY_CATEGORY, + GET_ACTIONENTITY_BY_MODEL, + GET_ACTIONENTITY_BY_COMPONENT, + GET_ACTIONENTITY_BY_VERSION, + GET_ALL_ACTIONS, + GET_ACTIONINVID_BY_NAME, + GET_ECOMP_COMPONENTS_ENTITY, + GET_VERSIONINFO_FOR_ALL_ACTIONS, + GET_NAME_BY_ACTIONINVID, + CHECKOUT_ACTION, + UNDO_CHECKOUT_ACTION, + CHECKIN_ACTION, + SUBMIT_ACTION, + UPDATE_ACTION, + UPDATE_ACTION_STATUS, + DELETE_UNIQUEVALUE, + DELETE_ACTIONVERSION, + DELETE_ARTIFACT, + DELETE_ACTION, + //Validations + VALIDATE_ACTION_UNIQUE_NAME, + //Artifacts + GET_ARTIFACT_BY_ARTIFACTUUID, + CREATE_ACTION_ARTIFACT, + UPDATE_ACTION_ARTIFACT, + DELETE_ACTION_ARTIFACT, +} diff --git a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/EcompComponent.java b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/EcompComponent.java new file mode 100644 index 0000000000..cbcebb13ef --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/types/EcompComponent.java @@ -0,0 +1,104 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.action.types; + +import org.openecomp.sdc.action.dao.types.EcompComponentEntity; + +public class EcompComponent { + + private String id; + private String name; + + public EcompComponent() { + //Default constructor + } + + public EcompComponent(String name, String id) { + this.name = name; + this.id = id; + } + + public String getId() { + return id; + } + + public void setId(String id) { + this.id = id; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + /** + * To entity ecomp component entity. + * + * @return the ecomp component entity + */ + public EcompComponentEntity toEntity() { + EcompComponentEntity destination = new EcompComponentEntity(); + destination.setId(this.getId()); + destination.setName(this.getName()); + return destination; + } + + @Override + public int hashCode() { + final int prime = 31; + int result = 1; + result = prime * result + ((id == null) ? 0 : id.hashCode()); + result = prime * result + ((name == null) ? 0 : name.hashCode()); + return result; + } + + @Override + public boolean equals(Object object) { + if (this == object) { + return true; + } + if (object == null) { + return false; + } + if (this.getClass() != object.getClass()) { + return false; + } + EcompComponent obj = (EcompComponent) object; + if (id == null) { + if (obj.id != null) { + return false; + } + } else if (!id.equals(obj.id)) { + return false; + } + if (name == null) { + if (obj.name != null) { + return false; + } + } else if (!name.equals(obj.name)) { + return false; + } + return true; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/util/ActionUtil.java b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/util/ActionUtil.java new file mode 100644 index 0000000000..787f6abc26 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/java/org/openecomp/sdc/action/util/ActionUtil.java @@ -0,0 +1,372 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.action.util; + +import static org.openecomp.sdc.action.ActionConstants.BEGIN_TIMESTAMP; +import static org.openecomp.sdc.action.ActionConstants.ELAPSED_TIME; +import static org.openecomp.sdc.action.ActionConstants.END_TIMESTAMP; +import static org.openecomp.sdc.action.ActionConstants.ERROR_CATEGORY; +import static org.openecomp.sdc.action.ActionConstants.ERROR_CODE; +import static org.openecomp.sdc.action.ActionConstants.ERROR_DESCRIPTION; +import static org.openecomp.sdc.action.ActionConstants.RESPONSE_CODE; +import static org.openecomp.sdc.action.ActionConstants.RESPONSE_DESCRIPTION; +import static org.openecomp.sdc.action.ActionConstants.SERVICE_METRIC_BEGIN_TIMESTAMP; +import static org.openecomp.sdc.action.ActionConstants.STATUS_CODE; +import static org.openecomp.sdc.action.ActionConstants.TARGET_ENTITY; +import static org.openecomp.sdc.action.ActionConstants.TARGET_SERVICE_NAME; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ARTIFACT_ALREADY_EXISTS_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ARTIFACT_CHECKSUM_ERROR_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ARTIFACT_DELETE_READ_ONLY; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ARTIFACT_DEL_LOCKED_OTHER_USER_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ARTIFACT_ENTITY_NOT_EXIST_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ARTIFACT_INVALID_NAME_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ARTIFACT_INVALID_PROTECTION_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ARTIFACT_TOO_BIG_ERROR_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ARTIFACT_UPDATE_READ_ONLY; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_AUTHENTICATION_ERR_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_AUTHORIZATION_ERR_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_CHECKIN_ON_ENTITY_LOCKED_BY_OTHER_USER; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_CHECKIN_ON_UNLOCKED_ENTITY; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_CHECKOUT_ON_LOCKED_ENTITY; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_CHECKOUT_ON_LOCKED_ENTITY_OTHER_USER; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_DELETE_ON_LOCKED_ENTITY_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_EDIT_ON_ENTITY_LOCKED_BY_OTHER_USER; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ENTITY_NOT_EXIST_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ENTITY_UNIQUE_VALUE_ERROR; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_INTERNAL_SERVER_ERR_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_INVALID_INSTANCE_ID_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_INVALID_PARAM_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_INVALID_REQUEST_BODY_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_INVALID_REQUEST_ID_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_INVALID_SEARCH_CRITERIA; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_MULT_SEARCH_CRITERIA; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_NOT_LOCKED_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_QUERY_FAILURE_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_REQUEST_INVALID_GENERIC_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_SUBMIT_FINALIZED_ENTITY_NOT_ALLOWED; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_SUBMIT_LOCKED_ENTITY_NOT_ALLOWED; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_UNDO_CHECKOUT_ON_ENTITY_LOCKED_BY_OTHER_USER; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_UNDO_CHECKOUT_ON_UNLOCKED_ENTITY; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_UPDATE_INVALID_VERSION; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_UPDATE_NOT_ALLOWED_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_UPDATE_NOT_ALLOWED_CODE_NAME; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_UPDATE_ON_UNLOCKED_ENTITY; +import static org.openecomp.sdc.action.types.ActionLogResponseCode.ACTION_NAME_ALREADY_EXISTS; +import static org.openecomp.sdc.action.types.ActionLogResponseCode.ACTION_NAME_UPDATE_NOT_ALLOWED; +import static org.openecomp.sdc.action.types.ActionLogResponseCode.ACTION_NOT_FOUND; +import static org.openecomp.sdc.action.types.ActionLogResponseCode.ACTION_NOT_LOCKED; +import static org.openecomp.sdc.action.types.ActionLogResponseCode.ARTIFACT_ALREADY_EXISTS; +import static org.openecomp.sdc.action.types.ActionLogResponseCode.ARTIFACT_DELETE_READ_ONLY; +import static org.openecomp.sdc.action.types.ActionLogResponseCode.ARTIFACT_NAME_INVALID; +import static org.openecomp.sdc.action.types.ActionLogResponseCode.ARTIFACT_NOT_FOUND; +import static org.openecomp.sdc.action.types.ActionLogResponseCode.ARTIFACT_PROTECTION_INVALID; +import static org.openecomp.sdc.action.types.ActionLogResponseCode.ARTIFACT_TOO_BIG; +import static org.openecomp.sdc.action.types.ActionLogResponseCode.ARTIFACT_UPDATE_READ_ONLY; +import static org.openecomp.sdc.action.types.ActionLogResponseCode.CHECKIN_ON_LOCKED_ENTITY_OTHER_USER; +import static org.openecomp.sdc.action.types.ActionLogResponseCode.CHECKIN_ON_UNLOCKED_ENTITY; +import static org.openecomp.sdc.action.types.ActionLogResponseCode.CHECKOUT_ON_LOCKED_ENTITY; +import static org.openecomp.sdc.action.types.ActionLogResponseCode.CHECKSUM_ERROR; +import static org.openecomp.sdc.action.types.ActionLogResponseCode.DELETE_ARTIFACT_ON_LOCKED_ENTITY; +import static org.openecomp.sdc.action.types.ActionLogResponseCode.DELETE_ON_LOCKED_ENTITY_OTHER_USER; +import static org.openecomp.sdc.action.types.ActionLogResponseCode.INTERNAL_SERVER_ERROR; +import static org.openecomp.sdc.action.types.ActionLogResponseCode.INVALID_REQUESTED_VERSION; +import static org.openecomp.sdc.action.types.ActionLogResponseCode.INVALID_REQUEST_PARAM; +import static org.openecomp.sdc.action.types.ActionLogResponseCode.INVALID_SEARCH_FILTER_CRITERIA; +import static org.openecomp.sdc.action.types.ActionLogResponseCode.MISSING_AUTHORIZATION; +import static org.openecomp.sdc.action.types.ActionLogResponseCode.MISSING_INSTANCE_ID_HEADER; +import static org.openecomp.sdc.action.types.ActionLogResponseCode.MISSING_REQUEST_BODY; +import static org.openecomp.sdc.action.types.ActionLogResponseCode.MISSING_REQUEST_ID_HEADER; +import static org.openecomp.sdc.action.types.ActionLogResponseCode.MULTIPLE_FILTER_CRITERIA_NOT_SUPPORTED; +import static org.openecomp.sdc.action.types.ActionLogResponseCode.QUERY_FAILURE; +import static org.openecomp.sdc.action.types.ActionLogResponseCode.SUBMIT_ON_FINAL_ENTITY; +import static org.openecomp.sdc.action.types.ActionLogResponseCode.SUBMIT_ON_LOCKED_ENTITY_OTHER_USER; +import static org.openecomp.sdc.action.types.ActionLogResponseCode.UNDO_CHECKOUT_ON_LOCKED_ENTITY; +import static org.openecomp.sdc.action.types.ActionLogResponseCode.UNDO_CHECKOUT_ON_UNLOCKED_ENTITY; +import static org.openecomp.sdc.action.types.ActionLogResponseCode.UPDATE_NOT_ALLOWED; +import static org.openecomp.sdc.action.types.ActionLogResponseCode.UPDATE_ON_LOCKED_ENTITY; +import static org.openecomp.sdc.action.types.ActionLogResponseCode.UPDATE_ON_UNLOCKED_ENTITY; + +import org.openecomp.sdc.action.logging.CategoryLogLevel; +import org.openecomp.sdc.action.logging.StatusCode; +import org.openecomp.sdc.action.types.ActionLogResponseCode; +import org.openecomp.sdc.action.types.ActionSubOperation; +import org.slf4j.MDC; + +import java.text.DateFormat; +import java.text.SimpleDateFormat; +import java.time.ZoneOffset; +import java.util.Date; +import java.util.TimeZone; + + +public class ActionUtil { + + private static final String UTC_DATE_FORMAT = "dd MMM yyyy kk:mm:ss z"; + private static final String LOG_UTC_DATE_FORMAT = "yyyy-MM-dd'T'HH:mm:ss.SSS"; + + /** + * Get Current Timestamp in UTC format. + * + * @return Current Timestamp in UTC format. + */ + public static Date getCurrentTimeStampUtc() { + return Date.from(java.time.ZonedDateTime.now(ZoneOffset.UTC).toInstant()); + } + + /** + * Convert timestamp to UTC format date string. + * + * @param timeStamp UTC timestamp to be converted to the UTC Date format. + * @return UTC formatted Date string from timestamp. + */ + public static String getUtcDateStringFromTimestamp(Date timeStamp) { + DateFormat df = new SimpleDateFormat(UTC_DATE_FORMAT); + df.setTimeZone(TimeZone.getTimeZone("GMT")); + return df.format(timeStamp); + } + + /** + * Convert timestamp to UTC format date string. + * + * @param timeStamp UTC timestamp to be converted to the UTC Date format. + * @return UTC formatted Date string from timestamp. + */ + public static String getLogUtcDateStringFromTimestamp(Date timeStamp) { + DateFormat df = new SimpleDateFormat(LOG_UTC_DATE_FORMAT); + df.setTimeZone(TimeZone.getTimeZone("GMT")); + return df.format(timeStamp); + } + + /** + * Method to set up specific attributes MDC for the current logging operation. + * + * @param subOperation Request Name. + */ + public static void actionLogPreProcessor(ActionSubOperation subOperation, String targetEntity) { + MDC.put(BEGIN_TIMESTAMP, String.valueOf(System.currentTimeMillis())); + if (subOperation != null) { + MDC.put(TARGET_SERVICE_NAME, subOperation.name()); + } + + MDC.put(TARGET_ENTITY, targetEntity); + } + + /** + * Method to enhance the MDC after the logging operation for Metrics and Audit logs. + * + * @param statusCode Response code for the current operation. + */ + public static void actionLogPostProcessor(StatusCode statusCode) { + actionLogPostProcessor(statusCode, false); + } + + public static void actionLogPostProcessor(StatusCode statusCode, boolean isServiceMetricLog) { + actionLogPostProcessor(statusCode, null, isServiceMetricLog); + } + + public static void actionLogPostProcessor(StatusCode statusCode, String responseCode, + boolean isServiceMetricLog) { + actionLogPostProcessor(statusCode, responseCode, null, isServiceMetricLog); + } + + /** + * Method to enhance the MDC after the logging operation for Metrics and Audit logs. + * + * @param statusCode Response code for the current operation. + */ + + public static void actionLogPostProcessor(StatusCode statusCode, String responseCode, + String responseDescription, + boolean isServiceMetricLog) { + MDC.put(STATUS_CODE, statusCode.name()); + if (responseCode != null) { + int logResponseCode = getLogResponseCode(responseCode); + MDC.put(RESPONSE_CODE, Integer.toString(logResponseCode)); + } + MDC.put(RESPONSE_DESCRIPTION, responseDescription); + long beginTimestamp; + if (isServiceMetricLog) { + beginTimestamp = Long.valueOf(MDC.get(SERVICE_METRIC_BEGIN_TIMESTAMP)); + } else { + beginTimestamp = Long.valueOf(MDC.get(BEGIN_TIMESTAMP)); + } + long endTimestamp = System.currentTimeMillis(); + MDC.put(BEGIN_TIMESTAMP, getLogUtcDateStringFromTimestamp(new Date(beginTimestamp))); + MDC.put(END_TIMESTAMP, getLogUtcDateStringFromTimestamp(new Date(endTimestamp))); + MDC.put(ELAPSED_TIME, String.valueOf(endTimestamp - beginTimestamp)); + } + + /** + * Action Library Error logging Helper. + * + * @param errorCategory WARN or ERROR. + * @param errorCode Action Library exception code. + * @param errorDescription Description of the error. + */ + public static void actionErrorLogProcessor(CategoryLogLevel errorCategory, String errorCode, + String errorDescription) { + MDC.put(ERROR_CATEGORY, errorCategory.name()); + if (errorCode != null) { + String errorType = ""; + switch (errorCategory) { + case WARN: + errorType = "W"; + break; + case ERROR: + errorType = "E"; + break; + case FATAL: + errorType = "F"; + break; + default: + break; + } + MDC.put(ERROR_CODE, getLogResponseCode(errorCode) + errorType); + } + MDC.put(ERROR_DESCRIPTION, errorDescription); + } + + /** + * Method to convert Action Library exception codes to OPENECOMP Audit codes in {@link. + * ActionLogResponseCode} e.g: ACT1060 --> 201. + * + * @param errorCode Action library exception code. + * @return Audit log code corresponding to the Action Library exception. + */ + public static int getLogResponseCode(String errorCode) { + ActionLogResponseCode responseCode = INTERNAL_SERVER_ERROR; + switch (errorCode) { + case ACTION_REQUEST_INVALID_GENERIC_CODE: + responseCode = INVALID_REQUEST_PARAM; + break; + case ACTION_AUTHENTICATION_ERR_CODE: + break; + case ACTION_AUTHORIZATION_ERR_CODE: + responseCode = MISSING_AUTHORIZATION; + break; + case ACTION_INVALID_INSTANCE_ID_CODE: + responseCode = MISSING_INSTANCE_ID_HEADER; + break; + case ACTION_INVALID_REQUEST_ID_CODE: + responseCode = MISSING_REQUEST_ID_HEADER; + break; + case ACTION_INVALID_PARAM_CODE: + responseCode = INVALID_REQUEST_PARAM; + break; + case ACTION_INVALID_REQUEST_BODY_CODE: + responseCode = MISSING_REQUEST_BODY; + break; + case ACTION_UPDATE_NOT_ALLOWED_CODE_NAME: + responseCode = ACTION_NAME_UPDATE_NOT_ALLOWED; + break; + case ACTION_CHECKOUT_ON_LOCKED_ENTITY: + responseCode = CHECKOUT_ON_LOCKED_ENTITY; + break; + case ACTION_ENTITY_UNIQUE_VALUE_ERROR: + responseCode = ACTION_NAME_ALREADY_EXISTS; + break; + case ACTION_INVALID_SEARCH_CRITERIA: + responseCode = INVALID_SEARCH_FILTER_CRITERIA; + break; + case ACTION_MULT_SEARCH_CRITERIA: + responseCode = MULTIPLE_FILTER_CRITERIA_NOT_SUPPORTED; + break; + case ACTION_UPDATE_ON_UNLOCKED_ENTITY: + responseCode = UPDATE_ON_UNLOCKED_ENTITY; + break; + case ACTION_UPDATE_INVALID_VERSION: + responseCode = INVALID_REQUESTED_VERSION; + break; + case ACTION_UPDATE_NOT_ALLOWED_CODE: + responseCode = UPDATE_NOT_ALLOWED; + break; + case ACTION_CHECKIN_ON_UNLOCKED_ENTITY: + responseCode = CHECKIN_ON_UNLOCKED_ENTITY; + break; + case ACTION_SUBMIT_FINALIZED_ENTITY_NOT_ALLOWED: + responseCode = SUBMIT_ON_FINAL_ENTITY; + break; + case ACTION_SUBMIT_LOCKED_ENTITY_NOT_ALLOWED: + responseCode = SUBMIT_ON_LOCKED_ENTITY_OTHER_USER; + break; + case ACTION_UNDO_CHECKOUT_ON_UNLOCKED_ENTITY: + responseCode = UNDO_CHECKOUT_ON_UNLOCKED_ENTITY; + break; + case ACTION_NOT_LOCKED_CODE: + responseCode = ACTION_NOT_LOCKED; + break; + case ACTION_ARTIFACT_CHECKSUM_ERROR_CODE: + responseCode = CHECKSUM_ERROR; + break; + case ACTION_ARTIFACT_TOO_BIG_ERROR_CODE: + responseCode = ARTIFACT_TOO_BIG; + break; + case ACTION_ARTIFACT_ALREADY_EXISTS_CODE: + responseCode = ARTIFACT_ALREADY_EXISTS; + break; + case ACTION_ARTIFACT_UPDATE_READ_ONLY: + responseCode = ARTIFACT_UPDATE_READ_ONLY; + break; + case ACTION_ARTIFACT_DELETE_READ_ONLY: + responseCode = ARTIFACT_DELETE_READ_ONLY; + break; + case ACTION_ARTIFACT_INVALID_PROTECTION_CODE: + responseCode = ARTIFACT_PROTECTION_INVALID; + break; + case ACTION_ARTIFACT_INVALID_NAME_CODE: + responseCode = ARTIFACT_NAME_INVALID; + break; + case ACTION_EDIT_ON_ENTITY_LOCKED_BY_OTHER_USER: + responseCode = UPDATE_ON_LOCKED_ENTITY; + break; + case ACTION_CHECKIN_ON_ENTITY_LOCKED_BY_OTHER_USER: + responseCode = CHECKIN_ON_LOCKED_ENTITY_OTHER_USER; + break; + case ACTION_CHECKOUT_ON_LOCKED_ENTITY_OTHER_USER: + responseCode = CHECKOUT_ON_LOCKED_ENTITY; + break; + case ACTION_UNDO_CHECKOUT_ON_ENTITY_LOCKED_BY_OTHER_USER: + responseCode = UNDO_CHECKOUT_ON_LOCKED_ENTITY; + break; + case ACTION_ENTITY_NOT_EXIST_CODE: + responseCode = ACTION_NOT_FOUND; + break; + case ACTION_ARTIFACT_ENTITY_NOT_EXIST_CODE: + responseCode = ARTIFACT_NOT_FOUND; + break; + case ACTION_ARTIFACT_DEL_LOCKED_OTHER_USER_CODE: + responseCode = DELETE_ARTIFACT_ON_LOCKED_ENTITY; + break; + case ACTION_DELETE_ON_LOCKED_ENTITY_CODE: + responseCode = DELETE_ON_LOCKED_ENTITY_OTHER_USER; + break; + case ACTION_INTERNAL_SERVER_ERR_CODE: + responseCode = INTERNAL_SERVER_ERROR; + break; + case ACTION_QUERY_FAILURE_CODE: + responseCode = QUERY_FAILURE; + break; + default: + break; + } + return responseCode.getValue(); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/resources/factoryConfiguration.json b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/resources/factoryConfiguration.json new file mode 100644 index 0000000000..44da8f085e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-api/src/main/resources/factoryConfiguration.json @@ -0,0 +1,4 @@ +{ + "org.openecomp.sdc.action.dao.ActionDaoFactory":"org.openecomp.sdc.action.dao.impl.ActionDaoFactoryImpl", + "org.openecomp.sdc.action.dao.ActionArtifactDaoFactory":"org.openecomp.sdc.action.dao.impl.ActionArtifactDaoFactoryImpl" +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-core/pom.xml b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-core/pom.xml new file mode 100644 index 0000000000..3abcbb55e7 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-core/pom.xml @@ -0,0 +1,37 @@ + + + 4.0.0 + + + + org.openecomp.sdc + openecomp-sdc-action-lib + 1.0.0-SNAPSHOT + + + + openecomp-sdc-action-core + + + + + + org.openecomp.sdc + openecomp-sdc-action-api + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-versioning-api + ${project.version} + + + org.openecomp.sdc.sdc_common + openecomp-logging-api + ${project.version} + + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-core/src/main/java/org/openecomp/sdc/action/dao/impl/ActionArtifactDaoFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-core/src/main/java/org/openecomp/sdc/action/dao/impl/ActionArtifactDaoFactoryImpl.java new file mode 100644 index 0000000000..2767c9eeca --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-core/src/main/java/org/openecomp/sdc/action/dao/impl/ActionArtifactDaoFactoryImpl.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.action.dao.impl; + +import org.openecomp.sdc.action.dao.ActionArtifactDao; +import org.openecomp.sdc.action.dao.ActionArtifactDaoFactory; + +public class ActionArtifactDaoFactoryImpl extends ActionArtifactDaoFactory { + private static final ActionArtifactDao INSTANCE = new ActionArtifactDaoImpl(); + + @Override + public ActionArtifactDao createInterface() { + return INSTANCE; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-core/src/main/java/org/openecomp/sdc/action/dao/impl/ActionArtifactDaoImpl.java b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-core/src/main/java/org/openecomp/sdc/action/dao/impl/ActionArtifactDaoImpl.java new file mode 100644 index 0000000000..3e884c24e3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-core/src/main/java/org/openecomp/sdc/action/dao/impl/ActionArtifactDaoImpl.java @@ -0,0 +1,150 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.action.dao.impl; + +import static org.openecomp.sdc.action.ActionConstants.TARGET_ENTITY_DB; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_ENTITY_INTERNAL_SERVER_ERROR_MSG; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_INTERNAL_SERVER_ERR_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_QUERY_FAILURE_CODE; +import static org.openecomp.sdc.action.errors.ActionErrorConstants.ACTION_QUERY_FAILURE_MSG; +import static org.openecomp.sdc.action.util.ActionUtil.actionLogPostProcessor; + +import com.datastax.driver.core.exceptions.NoHostAvailableException; +import com.datastax.driver.mapping.Mapper; +import com.datastax.driver.mapping.Result; +import com.datastax.driver.mapping.annotations.Accessor; +import com.datastax.driver.mapping.annotations.Query; +import org.openecomp.core.dao.impl.CassandraBaseDao; +import org.openecomp.core.logging.api.Logger; +import org.openecomp.core.logging.api.LoggerFactory; +import org.openecomp.core.nosqldb.api.NoSqlDb; +import org.openecomp.core.nosqldb.factory.NoSqlDbFactory; +import org.openecomp.sdc.action.dao.ActionArtifactDao; +import org.openecomp.sdc.action.dao.types.ActionArtifactEntity; +import org.openecomp.sdc.action.errors.ActionException; +import org.openecomp.sdc.action.logging.CategoryLogLevel; +import org.openecomp.sdc.action.logging.StatusCode; +import org.openecomp.sdc.action.types.ActionArtifact; +import org.openecomp.sdc.action.types.ActionSubOperation; +import org.openecomp.sdc.action.util.ActionUtil; + +import java.util.Collection; +import java.util.List; + +public class ActionArtifactDaoImpl extends CassandraBaseDao + implements ActionArtifactDao { + private static final NoSqlDb noSqlDb = NoSqlDbFactory.getInstance().createInterface(); + private static final Mapper mapper = + noSqlDb.getMappingManager().mapper(ActionArtifactEntity.class); + private static final ActionArtifactAccessor accessor = + noSqlDb.getMappingManager().createAccessor(ActionArtifactAccessor.class); + private final Logger log = (Logger) LoggerFactory.getLogger(this.getClass().getName()); + + @Override + protected Mapper getMapper() { + return mapper; + } + + @Override + protected Object[] getKeys(ActionArtifactEntity entity) { + return new Object[]{entity.getArtifactUuId(), entity.getEffectiveVersion()}; + } + + @Override + public Collection list(ActionArtifactEntity entity) { + return null; + } + + + @Override + public void uploadArtifact(ActionArtifact data) { + log.debug(" entering uploadArtifact with artifactName= " + data.getArtifactName()); + try { + ActionUtil.actionLogPreProcessor(ActionSubOperation.CREATE_ACTION_ARTIFACT, TARGET_ENTITY_DB); + this.create(data.toEntity()); + ActionUtil.actionLogPostProcessor(StatusCode.COMPLETE, null, "", false); + log.metrics(""); + } catch (NoHostAvailableException noHostAvailableException) { + logGenericException(noHostAvailableException); + throw new ActionException(ACTION_INTERNAL_SERVER_ERR_CODE, + ACTION_ENTITY_INTERNAL_SERVER_ERROR_MSG); + } + log.debug(" exit uploadArtifact with artifactName= " + data.getArtifactName()); + } + + @Override + public ActionArtifact downloadArtifact(int effectiveVersion, String artifactUuId) { + log.debug(" entering downloadArtifact with artifactUUID= " + artifactUuId); + ActionArtifact actionArtifact = null; + try { + ActionUtil + .actionLogPreProcessor(ActionSubOperation.GET_ARTIFACT_BY_ARTIFACTUUID, TARGET_ENTITY_DB); + Result result; + result = accessor.getArtifactByUuId(effectiveVersion, artifactUuId); + ActionUtil.actionLogPostProcessor(StatusCode.COMPLETE, null, "", false); + log.metrics(""); + List artifactEntities = result.all(); + if (artifactEntities != null && !artifactEntities.isEmpty()) { + ActionArtifactEntity artifactEntity = artifactEntities.get(0); + actionArtifact = artifactEntity.toDto(); + } + } catch (NoHostAvailableException noHostAvailableException) { + logGenericException(noHostAvailableException); + throw new ActionException(ACTION_INTERNAL_SERVER_ERR_CODE, + ACTION_ENTITY_INTERNAL_SERVER_ERROR_MSG); + } + log.debug(" exit downloadArtifact with artifactUUID= " + artifactUuId); + return actionArtifact; + } + + @Override + public void updateArtifact(ActionArtifact data) { + log.debug(" entering updateArtifact with artifactName= " + data.getArtifactName()); + try { + ActionUtil.actionLogPreProcessor(ActionSubOperation.UPDATE_ACTION_ARTIFACT, TARGET_ENTITY_DB); + this.update(data.toEntity()); + ActionUtil.actionLogPostProcessor(StatusCode.COMPLETE, null, "", false); + log.metrics(""); + } catch (NoHostAvailableException noHostAvailableException) { + logGenericException(noHostAvailableException); + throw new ActionException(ACTION_INTERNAL_SERVER_ERR_CODE, + ACTION_ENTITY_INTERNAL_SERVER_ERROR_MSG); + } + log.debug(" exit updateArtifact with artifactName= " + data.getArtifactName()); + } + + private void logGenericException(Exception exception) { + ActionUtil.actionLogPostProcessor(StatusCode.ERROR, ACTION_QUERY_FAILURE_CODE, + ACTION_ENTITY_INTERNAL_SERVER_ERROR_MSG, false); + log.metrics(""); + ActionUtil.actionErrorLogProcessor(CategoryLogLevel.FATAL, ACTION_QUERY_FAILURE_CODE, + ACTION_QUERY_FAILURE_MSG); + log.error(exception.getMessage()); + } + + @Accessor + interface ActionArtifactAccessor { + + @Query( + "SELECT * FROM action_artifact WHERE effective_version <= ? and artifactuuid = ? limit 1") + Result getArtifactByUuId(int effectiveVersion, String artifactUuId); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-core/src/main/java/org/openecomp/sdc/action/dao/impl/ActionDaoFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-core/src/main/java/org/openecomp/sdc/action/dao/impl/ActionDaoFactoryImpl.java new file mode 100644 index 0000000000..66bd20687d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-core/src/main/java/org/openecomp/sdc/action/dao/impl/ActionDaoFactoryImpl.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.action.dao.impl; + +import org.openecomp.sdc.action.dao.ActionDao; +import org.openecomp.sdc.action.dao.ActionDaoFactory; + +public class ActionDaoFactoryImpl extends ActionDaoFactory { + private static final ActionDao INSTANCE = new ActionDaoImpl(); + + @Override + public ActionDao createInterface() { + return INSTANCE; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-core/src/main/java/org/openecomp/sdc/action/dao/impl/ActionDaoImpl.java b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-core/src/main/java/org/openecomp/sdc/action/dao/impl/ActionDaoImpl.java new file mode 100644 index 0000000000..29b5171470 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-action-lib/openecomp-sdc-action-core/src/main/java/org/openecomp/sdc/action/dao/impl/ActionDaoImpl.java @@ -0,0 +1,583 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.action.dao.impl; + +import static com.datastax.driver.core.querybuilder.QueryBuilder.eq; +import static com.datastax.driver.core.querybuilder.QueryBuilder.in; +import static com.datastax.driver.core.querybuilder.QueryBuilder.set; +import static org.openecomp.core.nosqldb.impl.cassandra.CassandraSessionFactory.getSession; +import static org.openecomp.sdc.action.util.ActionUtil.actionLogPostProcessor; + +import com.datastax.driver.core.ResultSet; +import com.datastax.driver.core.Row; +import com.datastax.driver.core.Statement; +import com.datastax.driver.core.UDTValue; +import com.datastax.driver.core.exceptions.NoHostAvailableException; +import com.datastax.driver.core.querybuilder.QueryBuilder; +import com.datastax.driver.mapping.Mapper; +import com.datastax.driver.mapping.Result; +import com.datastax.driver.mapping.UDTMapper; +import com.datastax.driver.mapping.annotations.Accessor; +import com.datastax.driver.mapping.annotations.Query; +import org.openecomp.core.dao.impl.CassandraBaseDao; +import org.openecomp.core.logging.api.Logger; +import org.openecomp.core.logging.api.LoggerFactory; +import org.openecomp.core.nosqldb.api.NoSqlDb; +import org.openecomp.core.nosqldb.factory.NoSqlDbFactory; +import org.openecomp.core.utilities.json.JsonUtil; +import org.openecomp.sdc.action.ActionConstants; +import org.openecomp.sdc.action.dao.ActionDao; +import org.openecomp.sdc.action.dao.types.ActionEntity; +import org.openecomp.sdc.action.dao.types.EcompComponentEntity; +import org.openecomp.sdc.action.errors.ActionErrorConstants; +import org.openecomp.sdc.action.errors.ActionException; +import org.openecomp.sdc.action.logging.CategoryLogLevel; +import org.openecomp.sdc.action.logging.StatusCode; +import org.openecomp.sdc.action.types.Action; +import org.openecomp.sdc.action.types.ActionStatus; +import org.openecomp.sdc.action.types.ActionSubOperation; +import org.openecomp.sdc.action.types.EcompComponent; +import org.openecomp.sdc.action.util.ActionUtil; +import org.openecomp.sdc.versioning.VersioningManagerFactory; +import org.openecomp.sdc.versioning.dao.VersionInfoDao; +import org.openecomp.sdc.versioning.dao.VersionInfoDaoFactory; +import org.openecomp.sdc.versioning.dao.VersionInfoDeletedDao; +import org.openecomp.sdc.versioning.dao.VersionInfoDeletedDaoFactory; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.dao.types.VersionInfoDeletedEntity; +import org.openecomp.sdc.versioning.dao.types.VersionInfoEntity; +import org.openecomp.sdc.versioning.types.VersionableEntityMetadata; +import org.slf4j.MDC; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.HashSet; +import java.util.LinkedHashMap; +import java.util.List; +import java.util.Map; +import java.util.Set; +import java.util.stream.Collectors; + +public class ActionDaoImpl extends CassandraBaseDao implements ActionDao { + private static final NoSqlDb noSqlDb = NoSqlDbFactory.getInstance().createInterface(); + private static final Mapper mapper = + noSqlDb.getMappingManager().mapper(ActionEntity.class); + private static final ActionAccessor accessor = + noSqlDb.getMappingManager().createAccessor(ActionAccessor.class); + private static final UDTMapper versionMapper = + noSqlDb.getMappingManager().udtMapper(Version.class); + private static final VersionInfoDao versionInfoDao = + VersionInfoDaoFactory.getInstance().createInterface(); + private static final VersionInfoDeletedDao versionInfoDeletedDao = + VersionInfoDeletedDaoFactory.getInstance().createInterface(); + + private final Logger log = (Logger) LoggerFactory.getLogger(this.getClass().getName()); + + + @Override + public void registerVersioning(String versionableEntityType) { + VersioningManagerFactory.getInstance().createInterface() + .register(versionableEntityType, new VersionableEntityMetadata( + mapper.getTableMetadata().getName(), + mapper.getTableMetadata().getPartitionKey().get(0).getName(), + mapper.getTableMetadata().getPartitionKey().get(1).getName())); + } + + @Override + public Action createAction(Action actionDto) { + try { + ActionUtil.actionLogPreProcessor( + ActionSubOperation.CREATE_ACTION_ENTITY, ActionConstants.TARGET_ENTITY_DB); + this.create(actionDto.toEntity()); + ActionUtil.actionLogPostProcessor(StatusCode.COMPLETE, null, "", false); + log.metrics(""); + return actionDto; + } catch (NoHostAvailableException noHostAvailableException) { + logGenericException(noHostAvailableException); + throw new ActionException(ActionErrorConstants.ACTION_INTERNAL_SERVER_ERR_CODE, + ActionErrorConstants.ACTION_ENTITY_INTERNAL_SERVER_ERROR_MSG); + } + } + + @Override + public Action updateAction(Action actionDto) { + try { + log.debug(" entering updateAction with actionUUID= " + actionDto.getActionUuId()); + ActionUtil + .actionLogPreProcessor(ActionSubOperation.UPDATE_ACTION, + ActionConstants.TARGET_ENTITY_DB); + this.update(actionDto.toEntity()); + ActionUtil.actionLogPostProcessor(StatusCode.COMPLETE, null, "", false); + log.metrics(""); + log.debug(" exit updateAction with actionUUID= " + actionDto.getActionUuId()); + return actionDto; + } catch (NoHostAvailableException noHostAvailableException) { + logGenericException(noHostAvailableException); + throw new ActionException(ActionErrorConstants.ACTION_INTERNAL_SERVER_ERR_CODE, + ActionErrorConstants.ACTION_ENTITY_INTERNAL_SERVER_ERROR_MSG); + } + } + + @Override + public void deleteAction(String actionInvariantUuId) { + try { + log.debug("entering deleteAction with actionInvariantUUID = " + actionInvariantUuId); + ActionUtil + .actionLogPreProcessor(ActionSubOperation.GET_ACTION_VERSION, + ActionConstants.TARGET_ENTITY_DB); + VersionInfoDeletedEntity activeVersionEntity = versionInfoDeletedDao.get( + new VersionInfoDeletedEntity(ActionConstants.ACTION_VERSIONABLE_TYPE, + actionInvariantUuId)); + ActionUtil.actionLogPostProcessor(StatusCode.COMPLETE, null, "", false); + log.metrics(""); + Version activeVersion = activeVersionEntity.getActiveVersion(); + Statement getNameFromInvUuId = QueryBuilder.select().column("name").from("dox", "Action") + .where(eq("actioninvariantuuid", actionInvariantUuId)) + .and(in("version", versionMapper.toUDT(activeVersion))); + ActionUtil + .actionLogPreProcessor(ActionSubOperation.GET_NAME_BY_ACTIONINVID, + ActionConstants.TARGET_ENTITY_DB); + ResultSet results = getSession().execute(getNameFromInvUuId); + ActionUtil.actionLogPostProcessor(StatusCode.COMPLETE, null, "", false); + log.metrics(""); + if (!results.isExhausted()) { + String name = results.one().getString("name"); + List versions = getVersionsByName(name); + updateActionStatusForDelete(actionInvariantUuId, versions); + } + } catch (NoHostAvailableException noHostAvailableException) { + logGenericException(noHostAvailableException); + throw new ActionException(ActionErrorConstants.ACTION_INTERNAL_SERVER_ERR_CODE, + ActionErrorConstants.ACTION_ENTITY_INTERNAL_SERVER_ERROR_MSG); + } + log.debug("exit deleteAction"); + } + + + @Override + public List getActionsByActionInvariantUuId(String actionInvariantUuId) { + List actions = new ArrayList<>(); + try { + log.debug(" entering getActionsByActionInvariantUUID with actionInvariantUUID= " + + actionInvariantUuId); + Set viewableVersions = new HashSet<>(); + VersionPredicate filter = new VersionPredicate(); + ActionUtil + .actionLogPreProcessor(ActionSubOperation.GET_ACTION_VERSION, + ActionConstants.TARGET_ENTITY_DB); + VersionInfoEntity versionInfoEntity = versionInfoDao + .get(new VersionInfoEntity(ActionConstants.ACTION_VERSIONABLE_TYPE, actionInvariantUuId)); + if (versionInfoEntity == null) { + //Check for action in the Delete version info table + VersionInfoDeletedEntity versionInfoDeletedEntity = versionInfoDeletedDao.get( + new VersionInfoDeletedEntity(ActionConstants.ACTION_VERSIONABLE_TYPE, + actionInvariantUuId)); + if (versionInfoDeletedEntity != null) { + viewableVersions = versionInfoDeletedEntity.getViewableVersions(); + //Remove intermediate minor versions from viewable versions + if (versionInfoDeletedEntity.getActiveVersion() != null) { + filter.activeVersion = versionInfoDeletedEntity.getActiveVersion(); + filter.finalVersion = versionInfoDeletedEntity.getLatestFinalVersion(); + viewableVersions.removeIf(filter::isIntermediateMinorVersion); + } + } + } else { + viewableVersions = versionInfoEntity.getViewableVersions(); + //Remove intermediate minor versions from viewable versions + if (versionInfoEntity.getActiveVersion() != null) { + filter.activeVersion = versionInfoEntity.getActiveVersion(); + filter.finalVersion = versionInfoEntity.getLatestFinalVersion(); + viewableVersions.removeIf(filter::isIntermediateMinorVersion); + } + //Add candidate version if available + if (versionInfoEntity.getCandidate() != null) { + viewableVersions.add(versionInfoEntity.getCandidate().getVersion()); + } + } + MDC.put(ActionConstants.TARGET_ENTITY, ActionConstants.TARGET_ENTITY_DB); + ActionUtil.actionLogPostProcessor(StatusCode.COMPLETE, null, "", false); + log.metrics(""); + + log.debug( + "Found " + viewableVersions + " viewable version for action with actionInvariantUUID " + + actionInvariantUuId); + + //Fetch action data for the viewable versions + if (!viewableVersions.isEmpty()) { + ActionUtil.actionLogPreProcessor(ActionSubOperation.GET_ACTIONENTITY_BY_ACTIONINVID, + ActionConstants.TARGET_ENTITY_DB); + Result result = + accessor.getActionsByInvId(actionInvariantUuId, viewableVersions); + ActionUtil.actionLogPostProcessor(StatusCode.COMPLETE, null, "", false); + log.metrics(""); + if (result != null) { + actions + .addAll(result.all().stream().map(ActionEntity::toDto).collect(Collectors.toList())); + } + } + } catch (NoHostAvailableException noHostAvailableException) { + logGenericException(noHostAvailableException); + throw new ActionException(ActionErrorConstants.ACTION_INTERNAL_SERVER_ERR_CODE, + ActionErrorConstants.ACTION_ENTITY_INTERNAL_SERVER_ERROR_MSG); + } + log.debug( + " exit getActionsByActionInvariantUUID with actionInvariantUUID= " + actionInvariantUuId); + return actions; + } + + private void logGenericException(Exception exception) { + ActionUtil + .actionLogPostProcessor(StatusCode.ERROR, ActionErrorConstants.ACTION_QUERY_FAILURE_CODE, + ActionErrorConstants.ACTION_ENTITY_INTERNAL_SERVER_ERROR_MSG, false); + log.metrics(""); + ActionUtil.actionErrorLogProcessor( + CategoryLogLevel.FATAL, ActionErrorConstants.ACTION_QUERY_FAILURE_CODE, + ActionErrorConstants.ACTION_QUERY_FAILURE_MSG); + log.error(exception.getMessage()); + } + + + @Override + public List getFilteredActions(String filterType, String filterId) { + List actions = new ArrayList<>(); + Result result = null; + log.debug( + " entering getFilteredActions By filterType = " + filterType + " With value = " + filterId); + try { + switch (filterType) { + case ActionConstants.FILTER_TYPE_VENDOR: + ActionUtil + .actionLogPreProcessor(ActionSubOperation.GET_ACTIONENTITY_BY_VENDOR, + ActionConstants.TARGET_ENTITY_DB); + result = accessor.getActionsByVendor(filterId); + ActionUtil.actionLogPostProcessor(StatusCode.COMPLETE); + log.metrics(""); + break; + case ActionConstants.FILTER_TYPE_CATEGORY: + ActionUtil.actionLogPreProcessor(ActionSubOperation.GET_ACTIONENTITY_BY_CATEGORY, + ActionConstants.TARGET_ENTITY_DB); + result = accessor.getActionsByCategory(filterId); + ActionUtil.actionLogPostProcessor(StatusCode.COMPLETE); + log.metrics(""); + break; + case ActionConstants.FILTER_TYPE_MODEL: + ActionUtil + .actionLogPreProcessor(ActionSubOperation.GET_ACTIONENTITY_BY_MODEL, + ActionConstants.TARGET_ENTITY_DB); + result = accessor.getActionsByModel(filterId); + ActionUtil.actionLogPostProcessor(StatusCode.COMPLETE); + log.metrics(""); + break; + case ActionConstants.FILTER_TYPE_ECOMP_COMPONENT: + ActionUtil.actionLogPreProcessor(ActionSubOperation.GET_ACTIONENTITY_BY_COMPONENT, + ActionConstants.TARGET_ENTITY_DB); + result = accessor.getActionsByEcompComponent(filterId); + ActionUtil.actionLogPostProcessor(StatusCode.COMPLETE); + log.metrics(""); + break; + case ActionConstants.FILTER_TYPE_NONE: + ActionUtil + .actionLogPreProcessor(ActionSubOperation.GET_ALL_ACTIONS, + ActionConstants.TARGET_ENTITY_DB); + result = accessor.getAllActions(); + ActionUtil.actionLogPostProcessor(StatusCode.COMPLETE); + log.metrics(""); + break; + case ActionConstants.FILTER_TYPE_NAME: + ActionUtil + .actionLogPreProcessor(ActionSubOperation.GET_ACTIONINVID_BY_NAME, + ActionConstants.TARGET_ENTITY_DB); + result = accessor.getInvIdByName(filterId); + ActionUtil.actionLogPostProcessor(StatusCode.COMPLETE); + log.metrics(""); + List actionEntities = result.all(); + if (actionEntities != null && !actionEntities.isEmpty()) { + String actionInvariantUuId = actionEntities.get(0).getActionInvariantUuId(); + if (actionInvariantUuId != null) { + return getActionsByActionInvariantUuId(actionInvariantUuId); + } else { + return actions; + } + } + break; + default: + break; + } + if (result != null) { + actions.addAll(result.all().stream().map(ActionEntity::toDto).collect(Collectors.toList())); + } + log.debug( + " exit getFilteredActions By filterType = " + filterType + " With value = " + filterId); + } catch (NoHostAvailableException noHostAvailableException) { + logGenericException(noHostAvailableException); + throw new ActionException(ActionErrorConstants.ACTION_INTERNAL_SERVER_ERR_CODE, + ActionErrorConstants.ACTION_ENTITY_INTERNAL_SERVER_ERROR_MSG); + } + return actions; + } + + @Override + public List getEcompComponents() { + List ecompComponents = new ArrayList<>(); + Result result; + try { + log.debug(" entering getECOMPComponents "); + ActionUtil + .actionLogPreProcessor(ActionSubOperation.GET_ECOMP_COMPONENTS_ENTITY, + ActionConstants.TARGET_ENTITY_DB); + result = accessor.getEcompComponents(); + ActionUtil.actionLogPostProcessor(StatusCode.COMPLETE, null, "", false); + log.metrics(""); + if (result != null) { + ecompComponents.addAll( + result.all().stream().map(EcompComponentEntity::toDto).collect(Collectors.toList())); + } + } catch (NoHostAvailableException noHostAvailableException) { + logGenericException(noHostAvailableException); + throw new ActionException(ActionErrorConstants.ACTION_INTERNAL_SERVER_ERR_CODE, + ActionErrorConstants.ACTION_ENTITY_INTERNAL_SERVER_ERROR_MSG); + } + log.debug(" exit getECOMPComponents "); + return ecompComponents; + } + + @Override + public Action getActionsByActionUuId(String uniqueId) { + try { + log.debug(" entering getActionsByActionUUID with actionUUID= " + uniqueId); + ActionUtil + .actionLogPreProcessor(ActionSubOperation.GET_ACTIONENTITY_BY_ACTIONUUID, + ActionConstants.TARGET_ENTITY_DB); + Result result = accessor.actionInvariantUuId(uniqueId); + ActionUtil.actionLogPostProcessor(StatusCode.COMPLETE, null, "", false); + log.metrics(""); + if (result != null) { + log.debug(" exit getActionsByActionUUID with actionUUID= " + uniqueId); + ActionEntity entity = result.one(); + if (entity != null) { + return entity.toDto(); + } + } + log.debug(" exit getActionsByActionUUID with actionUUID= " + uniqueId); + return null; + } catch (NoHostAvailableException noHostAvailableException) { + logGenericException(noHostAvailableException); + throw new ActionException(ActionErrorConstants.ACTION_INTERNAL_SERVER_ERR_CODE, + ActionErrorConstants.ACTION_ENTITY_INTERNAL_SERVER_ERROR_MSG); + } + } + + @Override + public Action getLockedAction(String actionInvariantUuId, String user) throws ActionException { + log.debug(" entering getLockedAction with actionInvariantUUID= " + actionInvariantUuId); + ActionUtil + .actionLogPreProcessor(ActionSubOperation.GET_ACTION_VERSION, + ActionConstants.TARGET_ENTITY_DB); + Action action = null; + VersionInfoEntity versionInfoEntity = versionInfoDao + .get(new VersionInfoEntity(ActionConstants.ACTION_VERSIONABLE_TYPE, actionInvariantUuId)); + ActionUtil.actionLogPostProcessor(StatusCode.COMPLETE, null, "", false); + log.metrics(""); + if (versionInfoEntity != null) { + if (versionInfoEntity.getCandidate() != null) { + String actionUser = versionInfoEntity.getCandidate().getUser(); + if (actionUser != null && actionUser.equals(user)) { + Set versions = new HashSet<>(); + versions.add(versionInfoEntity.getCandidate().getVersion()); + ActionUtil.actionLogPreProcessor(ActionSubOperation.GET_ACTIONENTITY_BY_ACTIONINVID, + ActionConstants.TARGET_ENTITY_DB); + Result result = accessor.getActionsByInvId(actionInvariantUuId, versions); + ActionUtil.actionLogPostProcessor(StatusCode.COMPLETE, null, "", false); + log.metrics(""); + if (result != null) { + ActionEntity actionEntity = result.one(); + action = actionEntity != null ? actionEntity.toDto() : null; + } + } else { + throw new ActionException(ActionErrorConstants.ACTION_ARTIFACT_DEL_LOCKED_OTHER_USER_CODE, + String + .format(ActionErrorConstants.ACTION_ARTIFACT_DEL_LOCKED_OTHER_USER, actionUser)); + } + } else { + throw new ActionException( + ActionErrorConstants.ACTION_NOT_LOCKED_CODE, + ActionErrorConstants.ACTION_NOT_LOCKED_MSG); + } + } else { + throw new ActionException(ActionErrorConstants.ACTION_ENTITY_NOT_EXIST_CODE, + ActionErrorConstants.ACTION_ENTITY_NOT_EXIST); + } + return action; + } + + @Override + protected Mapper getMapper() { + return mapper; + } + + + @Override + protected Object[] getKeys(ActionEntity entity) { + return new Object[]{entity.getActionInvariantUuId(), versionMapper.toUDT(entity.getVersion())}; + } + + @Override + public Collection list(ActionEntity entity) { + return accessor.getAllActions().all(); + } + + /** + * param actionInvariantUuId. param versions. + */ + private void updateActionStatusForDelete(String actionInvariantUuId, List versions) { + log.debug( + "entering updateActionStatusForDelete with actionInvariantUUID = " + actionInvariantUuId + + " for versions " + versions); + List versionUdt = new ArrayList<>(); + + versions.forEach(v -> versionMapper.toUDT(v)); + ActionUtil + .actionLogPreProcessor(ActionSubOperation.UPDATE_ACTION_STATUS, + ActionConstants.TARGET_ENTITY_DB); + + //Update the status column of action table + Statement updateStatusStatement = + QueryBuilder.update("dox", "Action").with(set("status", ActionStatus.Deleted.name())) + .where(eq("actioninvariantuuid", actionInvariantUuId)).and(in("version", versionUdt)); + getSession().execute(updateStatusStatement); + ActionUtil.actionLogPostProcessor(StatusCode.COMPLETE, null, "", false); + log.metrics(""); + //Update the status in the data field of action table + updateStatusInActionData(actionInvariantUuId, versions, ActionStatus.Deleted); + log.debug("exit updateActionStatusForDelete with actionInvariantUUID = " + actionInvariantUuId + + " for versions " + versions); + } + + /** + * Update status for a list of versions for a given action. + * + * @param actionInvariantUuId Invariant UUID of the action. + * @param versions List of {@link Version} for which the status has to be updated. + * @param status The status value. + */ + private void updateStatusInActionData(String actionInvariantUuId, List versions, + ActionStatus status) { + log.debug("entering updateStatusInActionData for actionInvariantUUID = " + actionInvariantUuId + + " and status = " + status + " for versions " + versions); + for (Version v : versions) { + ActionEntity entity = this.get(new ActionEntity(actionInvariantUuId, v)); + String currentData = entity.getData(); + Map currentDataMap = JsonUtil.json2Object(currentData, LinkedHashMap.class); + currentDataMap.put(ActionConstants.STATUS, status); + String updatedActionData = JsonUtil.object2Json(currentDataMap); + entity.setData(updatedActionData); + this.updateAction(entity.toDto()); + } + log.debug("exit updateStatusInActionData"); + } + + /** + * Get list of all major and minor version values for a given action by action name. + * + * @param name Name of the action + * @return List of {@link Version} objects for the action + */ + private List getVersionsByName(String name) { + log.debug("entering getVersionsByName for Action Name = " + name); + ActionUtil + .actionLogPreProcessor(ActionSubOperation.GET_ACTION_VERSION, + ActionConstants.TARGET_ENTITY_DB); + Statement statement = + QueryBuilder.select().column("version").from("dox", "Action").where(eq("name", name)); + ResultSet results = getSession().execute(statement); + ActionUtil.actionLogPostProcessor(StatusCode.COMPLETE, null, "", false); + log.metrics(""); + List versionList = new ArrayList<>(); + for (Row row : results) { + Version version = versionMapper.fromUDT((UDTValue) row.getObject("version")); + versionList.add(version); + } + log.debug("exit getVersionsByName for Action Name = " + name); + return versionList; + } + + @Accessor + interface ActionAccessor { + + @Query("SELECT * FROM Action") + Result getAllActions(); + + @Query("SELECT * FROM Action where actionInvariantUuId = ? and version in ? ") + Result getActionsByInvId(String actionInvariantUuId, Set versions); + + @Query("SELECT * FROM Action where supportedModels CONTAINS ?") + Result getActionsByModel(String resource); + + @Query("SELECT * FROM Action where supportedComponents CONTAINS ?") + Result getActionsByEcompComponent(String resource); + + @Query("SELECT * FROM Action where vendor_list CONTAINS ?") + Result getActionsByVendor(String vendor); + + @Query("SELECT * FROM Action where category_list CONTAINS ?") + Result getActionsByCategory(String vendor); + + @Query("SELECT actionInvariantUuId FROM Action where name = ? limit 1") + Result getInvIdByName(String name); + + @Query("SELECT * FROM ECOMPComponent") + Result getEcompComponents(); + + @Query("SELECT * FROM Action where actionUUID = ?") + Result actionInvariantUuId(String actionUuId); + + } + + class VersionPredicate { + Version activeVersion; + Version finalVersion; + + public boolean isIntermediateMinorVersion(Version version) { + int activeMajorVersion = activeVersion.getMajor(); + int activeMinorVersion = activeVersion.getMinor(); + int currentMinorVersion = version.getMinor(); + int currentMajorVersion = version.getMajor(); + + if (finalVersion != null) { + if (finalVersion.getMajor() == activeMajorVersion + && currentMajorVersion == finalVersion.getMajor()) { + if (currentMinorVersion < activeMinorVersion && currentMinorVersion != 0) { + return true; + } + } else { + return false; + } + } else { + if (!version.equals(activeVersion)) { + return true; + } + } + + return false; + } + + } +} diff --git a/openecomp-be/lib/openecomp-sdc-action-lib/pom.xml b/openecomp-be/lib/openecomp-sdc-action-lib/pom.xml new file mode 100644 index 0000000000..7ff15d6bce --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-action-lib/pom.xml @@ -0,0 +1,25 @@ + + + 4.0.0 + + + org.openecomp.sdc + openecomp-sdc-lib + 1.0.0-SNAPSHOT + + + openecomp-sdc-action-lib + pom + + + + + + openecomp-sdc-action-api + openecomp-sdc-action-core + + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-datatypes-lib/pom.xml b/openecomp-be/lib/openecomp-sdc-datatypes-lib/pom.xml new file mode 100644 index 0000000000..d9c7beb3e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-datatypes-lib/pom.xml @@ -0,0 +1,38 @@ + + 4.0.0 + + + openecomp-sdc-lib + org.openecomp.sdc + 1.0.0-SNAPSHOT + + + openecomp-sdc-datatypes-lib + openecomp-sdc-datatypes-lib + + + + org.apache.commons + commons-collections4 + 4.1 + + + org.codehaus.jackson + jackson-mapper-asl + 1.9.13 + + + io.swagger + swagger-annotations + 1.5.3 + + + commons-lang + commons-lang + ${commons.lang.version} + + + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-datatypes-lib/src/main/java/org/openecomp/sdc/datatypes/error/ErrorLevel.java b/openecomp-be/lib/openecomp-sdc-datatypes-lib/src/main/java/org/openecomp/sdc/datatypes/error/ErrorLevel.java new file mode 100644 index 0000000000..44b0733388 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-datatypes-lib/src/main/java/org/openecomp/sdc/datatypes/error/ErrorLevel.java @@ -0,0 +1,25 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.datatypes.error; + +public enum ErrorLevel { + ERROR, WARNING, INFO +} diff --git a/openecomp-be/lib/openecomp-sdc-datatypes-lib/src/main/java/org/openecomp/sdc/datatypes/error/ErrorMessage.java b/openecomp-be/lib/openecomp-sdc-datatypes-lib/src/main/java/org/openecomp/sdc/datatypes/error/ErrorMessage.java new file mode 100644 index 0000000000..29a443c1a0 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-datatypes-lib/src/main/java/org/openecomp/sdc/datatypes/error/ErrorMessage.java @@ -0,0 +1,91 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.datatypes.error; + +import org.apache.commons.collections4.CollectionUtils; + +import java.util.ArrayList; +import java.util.List; +import java.util.Map; + +public class ErrorMessage { + private final ErrorLevel level; + private final String message; + + public ErrorMessage(ErrorLevel level, String message) { + this.level = level; + this.message = message; + } + + public ErrorLevel getLevel() { + return level; + } + + public String getMessage() { + return message; + } + + @Override + public boolean equals(Object object) { + if (this == object) { + return true; + } + if (object == null || getClass() != object.getClass()) { + return false; + } + + ErrorMessage that = (ErrorMessage) object; + + return level == that.level && message.equals(that.message); + + } + + @Override + public int hashCode() { + int result = level.hashCode(); + result = 31 * result + message.hashCode(); + return result; + } + + public static class ErrorMessageUtil { + + /** + * Add message list. + * + * @param fileName the file name + * @param errorMap the error map + * @return the list + */ + public static List addMessage(String fileName, + Map> errorMap) { + List fileErrorList; + fileErrorList = errorMap.get(fileName); + if (CollectionUtils.isEmpty(fileErrorList)) { + fileErrorList = new ArrayList<>(); + errorMap.put(fileName, fileErrorList); + } + + return fileErrorList; + } + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-datatypes-lib/src/main/java/org/openecomp/sdc/datatypes/model/AsdcModel.java b/openecomp-be/lib/openecomp-sdc-datatypes-lib/src/main/java/org/openecomp/sdc/datatypes/model/AsdcModel.java new file mode 100644 index 0000000000..7d873432b9 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-datatypes-lib/src/main/java/org/openecomp/sdc/datatypes/model/AsdcModel.java @@ -0,0 +1,24 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.datatypes.model; + +public interface AsdcModel { +} diff --git a/openecomp-be/lib/openecomp-sdc-datatypes-lib/src/main/java/org/openecomp/sdc/datatypes/model/heat/ForbiddenHeatResourceTypes.java b/openecomp-be/lib/openecomp-sdc-datatypes-lib/src/main/java/org/openecomp/sdc/datatypes/model/heat/ForbiddenHeatResourceTypes.java new file mode 100644 index 0000000000..a8df6bbbe4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-datatypes-lib/src/main/java/org/openecomp/sdc/datatypes/model/heat/ForbiddenHeatResourceTypes.java @@ -0,0 +1,56 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.datatypes.model.heat; + +import java.util.HashMap; +import java.util.Map; +import java.util.Objects; + +public enum ForbiddenHeatResourceTypes { + HEAT_FLOATING_IP_TYPE("OS::Neutron::FloatingIP"); + + + private static Map stringToForbiddenHeatResourceTypeMap; + + static { + stringToForbiddenHeatResourceTypeMap = new HashMap<>(); + + for (ForbiddenHeatResourceTypes type : ForbiddenHeatResourceTypes.values()) { + stringToForbiddenHeatResourceTypeMap.put(type.forbiddenType, type); + } + } + + private String forbiddenType; + + + ForbiddenHeatResourceTypes(String forbiddenType) { + this.forbiddenType = forbiddenType; + } + + public static ForbiddenHeatResourceTypes findByForbiddenHeatResource(String heatResource) { + return stringToForbiddenHeatResourceTypeMap.get(heatResource); + } + + + public static boolean isResourceTypeValid(String resourceType) { + return Objects.nonNull(findByForbiddenHeatResource(resourceType)); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/pom.xml b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/pom.xml new file mode 100644 index 0000000000..a2038a212e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/pom.xml @@ -0,0 +1,46 @@ + + 4.0.0 + + + + + org.openecomp.sdc + openecomp-sdc-lib + 1.0.0-SNAPSHOT + ../.. + + + openecomp-sdc-enrichment-api + openecomp-sdc-enrichment-api + + + + + org.openecomp.core + openecomp-facade-core + ${project.version} + + + io.swagger + swagger-annotations + 1.5.3 + + + org.openecomp.sdc + openecomp-sdc-datatypes-lib + ${project.version} + + + ch.qos.logback + logback-classic + 1.1.2 + + + org.openecomp.sdc + openecomp-sdc-versioning-api + ${project.version} + + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/EnrichmentArtifactsServiceFactory.java b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/EnrichmentArtifactsServiceFactory.java new file mode 100644 index 0000000000..63daa03f15 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/EnrichmentArtifactsServiceFactory.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.enrichment; + +import org.openecomp.core.enrichment.enrichmentartifacts.EnrichmentArtifactsService; +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; + +public abstract class EnrichmentArtifactsServiceFactory + extends AbstractComponentFactory { + + public static EnrichmentArtifactsServiceFactory getInstance() { + return AbstractFactory.getInstance(EnrichmentArtifactsServiceFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/EnrichmentConstants.java b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/EnrichmentConstants.java new file mode 100644 index 0000000000..c3726aa4e9 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/EnrichmentConstants.java @@ -0,0 +1,29 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.enrichment; + +import java.io.File; + +public final class EnrichmentConstants { + public static final String EXTERNAL_ARTIFACTS_DIR = + "Artifacts" + File.separator + "ExternalArtifacts"; + //public static final String HEAT_META_FILNAME = "HEAT.meta"; +} diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/api/EnrichmentManager.java b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/api/EnrichmentManager.java new file mode 100644 index 0000000000..2ddde6001b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/api/EnrichmentManager.java @@ -0,0 +1,43 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.enrichment.api; + +import org.openecomp.core.enrichment.types.EntityInfo; +import org.openecomp.sdc.datatypes.error.ErrorMessage; +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.util.List; +import java.util.Map; + +public interface EnrichmentManager { + + + Map> enrich(); + + void addEntityInput(String type, EntityInfo info); + + void initInput(String key, Version version); + + void addModel(T model); + + T getModel(); + +} diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/enrichmentartifacts/EnrichmentArtifactsService.java b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/enrichmentartifacts/EnrichmentArtifactsService.java new file mode 100644 index 0000000000..0eab0a916c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/enrichmentartifacts/EnrichmentArtifactsService.java @@ -0,0 +1,29 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.enrichment.enrichmentartifacts; + +import org.openecomp.core.utilities.file.FileContentHandler; +import org.openecomp.sdc.versioning.dao.types.Version; + +public interface EnrichmentArtifactsService { + + FileContentHandler addMibs(String vspId, Version version); +} diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/factory/EnrichmentManagerFactory.java b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/factory/EnrichmentManagerFactory.java new file mode 100644 index 0000000000..9199aeff6c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/factory/EnrichmentManagerFactory.java @@ -0,0 +1,32 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.enrichment.factory; + +import org.openecomp.core.enrichment.api.EnrichmentManager; +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; + +public abstract class EnrichmentManagerFactory extends AbstractComponentFactory { + + public static EnrichmentManagerFactory getInstance() { + return AbstractFactory.getInstance(EnrichmentManagerFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/types/CeilometerInfo.java b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/types/CeilometerInfo.java new file mode 100644 index 0000000000..71c1ff5cec --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/types/CeilometerInfo.java @@ -0,0 +1,71 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.enrichment.types; + +public class CeilometerInfo { + + private String name; + private String type; + private String unit; + private String category; + private String description; + + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getType() { + return type; + } + + public void setType(String type) { + this.type = type; + } + + public String getUnit() { + return unit; + } + + public void setUnit(String unit) { + this.unit = unit; + } + + public String getCategory() { + return category; + } + + public void setCategory(String category) { + this.category = category; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/types/ComponentArtifactType.java b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/types/ComponentArtifactType.java new file mode 100644 index 0000000000..c91cff0e1e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/types/ComponentArtifactType.java @@ -0,0 +1,34 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.enrichment.types; + +public enum ComponentArtifactType { + SNMP_POLL, + SNMP_TRAP; + + + public static ComponentArtifactType getComponentArtifactType(boolean isTrap) { + return isTrap ? SNMP_TRAP : SNMP_POLL; + } + +} + + diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/types/ComponentCeilometerInfo.java b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/types/ComponentCeilometerInfo.java new file mode 100644 index 0000000000..a0c1be51e9 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/types/ComponentCeilometerInfo.java @@ -0,0 +1,36 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.enrichment.types; + +import java.util.List; + +public class ComponentCeilometerInfo { + + private List ceilometerInfoList; + + public List getCeilometerInfoList() { + return ceilometerInfoList; + } + + public void setCeilometerInfoList(List ceilometerInfoList) { + this.ceilometerInfoList = ceilometerInfoList; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/types/ComponentMibInfo.java b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/types/ComponentMibInfo.java new file mode 100644 index 0000000000..88dbedc136 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/types/ComponentMibInfo.java @@ -0,0 +1,45 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.enrichment.types; + +public class ComponentMibInfo { + private MibInfo snmpTrap; + private MibInfo snmpPoll; + + + public MibInfo getSnmpTrap() { + return snmpTrap; + } + + public void setSnmpTrap(MibInfo snmpTrap) { + this.snmpTrap = snmpTrap; + } + + public MibInfo getSnmpPoll() { + return snmpPoll; + } + + public void setSnmpPoll(MibInfo snmpPoll) { + this.snmpPoll = snmpPoll; + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/types/EntityInfo.java b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/types/EntityInfo.java new file mode 100644 index 0000000000..ac80eb9d03 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/types/EntityInfo.java @@ -0,0 +1,27 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.enrichment.types; + + +public interface EntityInfo { + + +} diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/types/MibInfo.java b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/types/MibInfo.java new file mode 100644 index 0000000000..f5d2fcb90d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/java/org/openecomp/core/enrichment/types/MibInfo.java @@ -0,0 +1,45 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.enrichment.types; + +import java.io.ByteArrayInputStream; +import java.io.InputStream; + +public class MibInfo { + private String name; + private byte[] content; + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public InputStream getContent() { + return new ByteArrayInputStream(this.content); + } + + public void setContent(byte[] content) { + this.content = content; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/resources/factoryConfiguration.json b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/resources/factoryConfiguration.json new file mode 100644 index 0000000000..d22184e3da --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-api/src/main/resources/factoryConfiguration.json @@ -0,0 +1,4 @@ +{ + "org.openecomp.core.enrichment.factory.EnrichmentManagerFactory": "org.openecomp.sdc.enrichment.impl.EnrichmentManagerFactoryImpl", + "org.openecomp.core.enrichment.EnrichmentArtifactsServiceFactory": "org.openecomp.sdc.enrichment.EnrichmentArtifactsServiceFactoryImpl" +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/pom.xml b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/pom.xml new file mode 100644 index 0000000000..1f0452cdfb --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/pom.xml @@ -0,0 +1,90 @@ + + 4.0.0 + + + + + + org.openecomp.sdc + openecomp-sdc-lib + 1.0.0-SNAPSHOT + ../.. + + + openecomp-sdc-enrichment-core + openecomp-sdc-enrichment-core + + + + org.slf4j + slf4j-api + 1.7.10 + + + + + + ch.qos.logback + logback-classic + 1.1.2 + + + + org.testng + testng + test + 6.8.5 + + + snakeyaml + org.yaml + + + + + junit + junit + RELEASE + test + + + org.openecomp.core + openecomp-utilities-lib + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-enrichment-api + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-enrichment-impl + ${project.version} + + + + org.openecomp.sdc + openecomp-sdc-datatypes-lib + ${project.version} + + + org.mockito + mockito-all + test + 1.10.19 + + + com.google.guava + guava + 19.0 + + + org.openecomp.sdc + openecomp-sdc-model-impl + ${project.version} + test + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/main/java/org/openecomp/sdc/enrichment/EnrichmentArtifactsServiceFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/main/java/org/openecomp/sdc/enrichment/EnrichmentArtifactsServiceFactoryImpl.java new file mode 100644 index 0000000000..1075b07a49 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/main/java/org/openecomp/sdc/enrichment/EnrichmentArtifactsServiceFactoryImpl.java @@ -0,0 +1,34 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.enrichment; + +import org.openecomp.core.enrichment.EnrichmentArtifactsServiceFactory; +import org.openecomp.core.enrichment.enrichmentartifacts.EnrichmentArtifactsService; +import org.openecomp.sdc.enrichment.enrichmentartifacts.EnrichmentArtifactsServiceImpl; + +public class EnrichmentArtifactsServiceFactoryImpl extends EnrichmentArtifactsServiceFactory { + private static EnrichmentArtifactsService INSTANCE = new EnrichmentArtifactsServiceImpl(); + + @Override + public EnrichmentArtifactsService createInterface() { + return INSTANCE; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/main/java/org/openecomp/sdc/enrichment/enrichmentartifacts/EnrichmentArtifactsServiceImpl.java b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/main/java/org/openecomp/sdc/enrichment/enrichmentartifacts/EnrichmentArtifactsServiceImpl.java new file mode 100644 index 0000000000..2b7fef1e6b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/main/java/org/openecomp/sdc/enrichment/enrichmentartifacts/EnrichmentArtifactsServiceImpl.java @@ -0,0 +1,61 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.enrichment.enrichmentartifacts; + +import org.openecomp.core.enrichment.enrichmentartifacts.EnrichmentArtifactsService; +import org.openecomp.core.model.dao.EnrichedServiceModelDao; +import org.openecomp.core.model.dao.EnrichedServiceModelDaoFactory; +import org.openecomp.core.model.types.ServiceArtifact; +import org.openecomp.core.model.types.ServiceElement; +import org.openecomp.core.utilities.file.FileContentHandler; +import org.openecomp.sdc.common.utils.AsdcCommon; +import org.openecomp.sdc.tosca.datatypes.ToscaServiceModel; +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.util.List; + +public class EnrichmentArtifactsServiceImpl implements EnrichmentArtifactsService { + EnrichedServiceModelDao enrichedServiceModelDao = + EnrichedServiceModelDaoFactory.getInstance().createInterface(); + + @Override + public FileContentHandler addMibs(String vspId, Version version) { + FileContentHandler externalArtifacts = new FileContentHandler(); + List mibsList = enrichedServiceModelDao.getExternalArtifacts(vspId, version); + addMibsToFileContentHandler(mibsList, externalArtifacts); + + return externalArtifacts; + } + + + private void addMibsToFileContentHandler(List mibsList, + FileContentHandler externalArtifacts) { + for (ServiceArtifact serviceArtifact : mibsList) { + String filename = serviceArtifact.getName(); + externalArtifacts.addFile(filename, serviceArtifact.getContent()); + } + } + + + private boolean isFileArtifact(String filename) { + return !filename.contains(AsdcCommon.HEAT_META) && !filename.contains(AsdcCommon.MANIFEST_NAME); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/main/java/org/openecomp/sdc/enrichment/impl/EnrichmentManagerFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/main/java/org/openecomp/sdc/enrichment/impl/EnrichmentManagerFactoryImpl.java new file mode 100644 index 0000000000..abbb577075 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/main/java/org/openecomp/sdc/enrichment/impl/EnrichmentManagerFactoryImpl.java @@ -0,0 +1,34 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.enrichment.impl; + + +import org.openecomp.core.enrichment.api.EnrichmentManager; +import org.openecomp.core.enrichment.factory.EnrichmentManagerFactory; + + +public class EnrichmentManagerFactoryImpl extends EnrichmentManagerFactory { + + @Override + public EnrichmentManager createInterface() { + return new EnrichmentManagerImpl(); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/main/java/org/openecomp/sdc/enrichment/impl/EnrichmentManagerImpl.java b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/main/java/org/openecomp/sdc/enrichment/impl/EnrichmentManagerImpl.java new file mode 100644 index 0000000000..ef29108402 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/main/java/org/openecomp/sdc/enrichment/impl/EnrichmentManagerImpl.java @@ -0,0 +1,84 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.enrichment.impl; + +import org.openecomp.core.enrichment.api.EnrichmentManager; +import org.openecomp.core.enrichment.types.EntityInfo; +import org.openecomp.sdc.datatypes.error.ErrorMessage; +import org.openecomp.sdc.enrichment.EnrichmentInfo; +import org.openecomp.sdc.enrichment.factory.EnricherHandlerFactory; +import org.openecomp.sdc.enrichment.inter.Enricher; +import org.openecomp.sdc.tosca.datatypes.ToscaServiceModel; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import java.util.List; +import java.util.Map; + +public class EnrichmentManagerImpl implements EnrichmentManager { + + private static Logger logger = LoggerFactory.getLogger(EnrichmentManagerImpl.class); + + private EnrichmentInfo input = null; + private ToscaServiceModel model; + + + @Override + public Map> enrich() { + List enricherList = + EnricherHandlerFactory.getInstance().createInterface().getEnrichers(); + for (Enricher enricher : enricherList) { + enricher.setInput(input); + enricher.setModel(model); + enricher.enrich(); + } + + return null; + } + + @Override + public void addEntityInput(String type, EntityInfo info) { + this.input.addEntityInfo(type, info); + } + + + @Override + public void initInput(String key, Version version) { + input = new EnrichmentInfo(); + input.setKey(key); + input.setVersion(version); + } + + @Override + public void addModel(ToscaServiceModel model) { + + this.model = model; + } + + + @Override + public ToscaServiceModel getModel() { + return this.model; + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/java/org/openecomp/sdc/enrichment/impl/EnrichmentManagerImplTest.java b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/java/org/openecomp/sdc/enrichment/impl/EnrichmentManagerImplTest.java new file mode 100644 index 0000000000..6bc5a0e864 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/java/org/openecomp/sdc/enrichment/impl/EnrichmentManagerImplTest.java @@ -0,0 +1,245 @@ +package org.openecomp.sdc.enrichment.impl; + +import org.openecomp.sdc.enrichment.impl.tosca.ComponentInfo; +import org.openecomp.sdc.tosca.datatypes.ToscaServiceModel; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.services.ToscaFileOutputService; +import org.openecomp.sdc.tosca.services.impl.ToscaFileOutputServiceCsarImpl; +import org.openecomp.sdc.tosca.services.yamlutil.ToscaExtensionYamlUtil; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.core.enrichment.api.EnrichmentManager; +import org.openecomp.core.enrichment.factory.EnrichmentManagerFactory; + +import org.openecomp.core.enrichment.types.CeilometerInfo; +import org.openecomp.core.enrichment.types.ComponentCeilometerInfo; +import org.openecomp.core.utilities.file.FileUtils; +import org.testng.Assert; +import org.testng.annotations.Test; + +import java.io.*; +import java.net.URL; +import java.nio.file.NotDirectoryException; +import java.util.*; +import java.util.zip.ZipEntry; +import java.util.zip.ZipInputStream; + +import static org.junit.Assert.assertEquals; + + +public class EnrichmentManagerImplTest { + + + private static ToscaServiceModel loadToscaServiceModel(String serviceTemplatesPath, + String globalServiceTemplatesPath, + String entryDefinitionServiceTemplate) + throws IOException { + ToscaExtensionYamlUtil toscaExtensionYamlUtil = new ToscaExtensionYamlUtil(); + Map serviceTemplates = new HashMap<>(); + if (entryDefinitionServiceTemplate == null) { + entryDefinitionServiceTemplate = "MainServiceTemplate.yaml"; + } + + loadServiceTemplates(serviceTemplatesPath, toscaExtensionYamlUtil, serviceTemplates); + if (globalServiceTemplatesPath != null) { + loadServiceTemplates(globalServiceTemplatesPath, toscaExtensionYamlUtil, serviceTemplates); + } + + return new ToscaServiceModel(null, serviceTemplates, entryDefinitionServiceTemplate); + } + + private static void loadServiceTemplates(String serviceTemplatesPath, + ToscaExtensionYamlUtil toscaExtensionYamlUtil, + Map serviceTemplates) + throws IOException { + URL urlFile = EnrichmentManagerImplTest.class.getResource(serviceTemplatesPath); + if (urlFile != null) { + File pathFile = new File(urlFile.getFile()); + File[] files = pathFile.listFiles(); + if (files != null) { + addServiceTemplateFiles(serviceTemplates, files, toscaExtensionYamlUtil); + } else { + throw new NotDirectoryException(serviceTemplatesPath); + } + } else { + throw new NotDirectoryException(serviceTemplatesPath); + } + } + + private static void addServiceTemplateFiles(Map serviceTemplates, + File[] files, + ToscaExtensionYamlUtil toscaExtensionYamlUtil) + throws IOException { + for (File file : files) { + if (!file.getName().equals("CSR.zip") && !file.isDirectory()) { + try (InputStream yamlFile = new FileInputStream(file)) { + ServiceTemplate serviceTemplateFromYaml = + toscaExtensionYamlUtil.yamlToObject(yamlFile, ServiceTemplate.class); + serviceTemplates.put(file.getName(), serviceTemplateFromYaml); + try { + yamlFile.close(); + } catch (IOException ignore) { + } + } catch (FileNotFoundException e) { + throw e; + } catch (IOException e) { + throw e; + } + } + } + } + +// @Test + public void testEnrichmentManagerImpl() throws Exception { + Assert.assertTrue( + EnrichmentManagerFactory.getInstance().createInterface() instanceof EnrichmentManagerImpl); + } + +// @Test + public void testEnrichModel() throws Exception { + ToscaServiceModel toscaServiceModel = + loadToscaServiceModel("/extractServiceComposition/onlyComponents/", + "/extractServiceComposition/toscaGlobalServiceTemplates/", "OnlyComponentsST.yaml"); + EnrichmentManager enrichmentManager = EnrichmentManagerFactory.getInstance().createInterface(); + enrichmentManager.initInput("vsp_enrich", new Version(0, 1)); + enrichmentManager.addModel(toscaServiceModel); + + String[] componentNames = new String[]{"org.openecomp.resource.vfc.nodes.heat.pcrf_psm", + "org.openecomp.resource.vfc.nodes.heat.pcm"}; + ComponentInfo componentInfo = new ComponentInfo(); + + CeilometerInfo ceilometerInfo; + ComponentCeilometerInfo componentCeilometerInfo = new ComponentCeilometerInfo(); + componentCeilometerInfo.setCeilometerInfoList(new ArrayList<>()); + componentInfo.setCeilometerInfo(componentCeilometerInfo); + + for (String componentName : componentNames) { + ceilometerInfo = + getCeilometerInfo("instance", "Gauge", "instance", "compute", "Existence of instance"); + componentInfo.getCeilometerInfo().getCeilometerInfoList().add(ceilometerInfo); + ceilometerInfo = getCeilometerInfo("memory", "Gauge", "MB", "compute", + "Volume of RAM allocated to the instance"); + componentInfo.getCeilometerInfo().getCeilometerInfoList().add(ceilometerInfo); + ceilometerInfo = getCeilometerInfo("cpu", "Cumulative", "ns", "compute", "CPU time used"); + componentInfo.getCeilometerInfo().getCeilometerInfoList().add(ceilometerInfo); + enrichmentManager.addEntityInput(componentName, componentInfo); + } + + enrichmentManager.enrich(); + + File csrFile = getToscaModelAsFile(toscaServiceModel); + compareActualAndExpected(csrFile); + + } + +// @Test + public void testAllEnrichModel() throws Exception { + ToscaServiceModel toscaServiceModel = loadToscaServiceModel("/extractServiceComposition/all/", + "/extractServiceComposition/toscaGlobalServiceTemplates/", "OnlyComponentsST.yaml"); + EnrichmentManager enrichmentManager = EnrichmentManagerFactory.getInstance().createInterface(); + enrichmentManager.initInput("vsp_enrich", new Version(0, 1)); + enrichmentManager.addModel(toscaServiceModel); + + String[] componentNames = new String[]{"org.openecomp.resource.vfc.nodes.heat.pcrf_psm", + "org.openecomp.resource.vfc.nodes.heat.pcm"}; + ComponentInfo componentInfo = new ComponentInfo(); + + CeilometerInfo ceilometerInfo; + ComponentCeilometerInfo componentCeilometerInfo = new ComponentCeilometerInfo(); + componentCeilometerInfo.setCeilometerInfoList(new ArrayList<>()); + componentInfo.setCeilometerInfo(componentCeilometerInfo); + + for (String componentName : componentNames) { + ceilometerInfo = + getCeilometerInfo("instance", "Gauge", "instance", "compute", "Existence of instance"); + componentInfo.getCeilometerInfo().getCeilometerInfoList().add(ceilometerInfo); + ceilometerInfo = getCeilometerInfo("memory", "Gauge", "MB", "compute", + "Volume of RAM allocated to the instance"); + componentInfo.getCeilometerInfo().getCeilometerInfoList().add(ceilometerInfo); + ceilometerInfo = getCeilometerInfo("cpu", "Cumulative", "ns", "compute", "CPU time used"); + componentInfo.getCeilometerInfo().getCeilometerInfoList().add(ceilometerInfo); + enrichmentManager.addEntityInput(componentName, componentInfo); + } + + enrichmentManager.enrich(); + + File csrFile = getToscaModelAsFile(toscaServiceModel); + compareActualAndExpected(csrFile); + + } + + private CeilometerInfo getCeilometerInfo(String name, String type, String unit, String category, + String description) { + CeilometerInfo ceilometerInfo = new CeilometerInfo(); + ceilometerInfo.setName(name); + ceilometerInfo.setType(type); + ceilometerInfo.setUnit(unit); + ceilometerInfo.setCategory(category); + ceilometerInfo.setDescription(description); + return ceilometerInfo; + } + + private File getToscaModelAsFile(ToscaServiceModel toscaServiceModel) throws IOException { + + URL inputFilesUrl = + EnrichmentManagerImplTest.class.getResource("/extractServiceComposition/onlyComponents"); + String path = inputFilesUrl.getPath(); + + + File file = new File(path + "/" + "CSR.zip"); + file.createNewFile(); + + try (FileOutputStream fos = new FileOutputStream(file)) + + { + ToscaFileOutputService toscaFileOutputService = new ToscaFileOutputServiceCsarImpl(); + fos.write(toscaFileOutputService.createOutputFile(toscaServiceModel, null)); + } + + return file; + } + + protected void compareActualAndExpected(File actualFile) throws IOException { + + URL url = EnrichmentManagerImplTest.class + .getResource("/extractServiceComposition/onlyComponents/expectedOutput"); + Set expectedResultFileNameSet = new HashSet<>(); + Map expectedResultMap = new HashMap<>(); + String path = url.getPath(); + File pathFile = new File(path); + File[] files = pathFile.listFiles(); + org.junit.Assert.assertNotNull("manifest files is empty", files); + for (File expectedFile : files) { + expectedResultFileNameSet.add(expectedFile.getName()); + try (FileInputStream input = new FileInputStream(expectedFile)) { + expectedResultMap.put(expectedFile.getName(), FileUtils.toByteArray(input)); + } + } + + try (FileInputStream fis = new FileInputStream(actualFile); + ZipInputStream zis = new ZipInputStream(new BufferedInputStream(fis))) { + ZipEntry entry; + String name; + String expected; + String actual; + + while ((entry = zis.getNextEntry()) != null) { + + name = entry.getName() + .substring(entry.getName().lastIndexOf(File.separator) + 1, entry.getName().length()); + if (expectedResultFileNameSet.contains(name)) { + expected = new String(expectedResultMap.get(name)).trim().replace("\r", ""); + actual = new String(FileUtils.toByteArray(zis)).trim().replace("\r", ""); + assertEquals("difference in file: " + name, expected, actual); + + expectedResultFileNameSet.remove(name); + } + } + if (expectedResultFileNameSet.isEmpty()) { + expectedResultFileNameSet.forEach(System.out::println); + } + } + assertEquals(0, expectedResultFileNameSet.size()); + } + + +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/all/OnlyComponentsST.yaml b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/all/OnlyComponentsST.yaml new file mode 100644 index 0000000000..54f39e4219 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/all/OnlyComponentsST.yaml @@ -0,0 +1,350 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.pcrf_psm: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.pcm: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + Internal2_name: + label: Internal2_name + hidden: false + immutable: false + type: string + description: Internal2_name + Internal1_shared: + label: Internal1_shared + hidden: false + immutable: false + type: string + description: Internal1_shared + FSB1_volume_name: + label: FSB1_volume + hidden: false + immutable: false + type: string + description: FSB1_volume_1 + jsa_cidr: + label: jsa_cidr + hidden: false + immutable: false + type: string + description: jsa_cidr + default: 107.243.7.128/26 + availabilityzone_name: + label: availabilityzone_name + hidden: false + immutable: false + type: string + description: availabilityzone_name + fsb1-name: + label: FSB1_name + hidden: false + immutable: false + type: string + description: FSB1_name + pcm_image_name: + label: pcm_image_name + hidden: false + immutable: false + type: string + description: pcm_image_name + Internal2_external: + label: Internal2_external + hidden: false + immutable: false + type: string + description: Internal2_external + Internal2_forwarding_mode: + label: Internal2_forwarding_mode + hidden: false + immutable: false + type: string + description: Internal2_forwarding_mode + pcrf_psm_flavor_name: + label: pcrf_psm_flavor_name + hidden: false + immutable: false + type: string + description: pcrf_psm_flavor_name + pcrf_psm_image_name: + label: pcrf_psm_image_name + hidden: false + immutable: false + type: string + description: pcrf_psm_image_name + FSB_1_image: + label: MME_FSB1 + hidden: false + immutable: false + type: string + description: MME_FSB1_15B-CP04-r5a01 + volume_size: + label: volume size + hidden: false + immutable: false + type: float + description: my volume size 320GB + fsb1-Internal1-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + Internal2_shared: + label: Internal2_shared + hidden: false + immutable: false + type: string + description: Internal2_shared + pcm_server_name: + label: pcm_server_name + hidden: false + immutable: false + type: string + description: pcm_server_name + Internal1_net_name: + label: Internal1_net_name + hidden: false + immutable: false + type: string + description: Internal1_net_name + oam_net_name: + label: oam_net_name + hidden: false + immutable: false + type: string + description: oam_net_name + fsb1-flavor: + label: FSB1_flavor + hidden: false + immutable: false + type: string + description: FSB1_flavor + fsb1-Internal2-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + volume_type: + label: volume type + hidden: false + immutable: false + type: string + description: volume type Gold + fsb1-zone: + label: FSB1_zone + hidden: false + immutable: false + type: string + description: FSB1_zone + fsb_zone: + label: FSB1_zone + hidden: false + immutable: false + type: string + description: FSB1_zone + security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + jsa_net_name: + label: jsa_net_name + hidden: false + immutable: false + type: string + description: jsa_net_name + default: jsa_log_net_0 + pcrf_psm_server_name: + label: pcrf_psm_server_name + hidden: false + immutable: false + type: string + description: pcrf_psm_server_name + pcm_flavor_name: + label: pcm_flavor_name + hidden: false + immutable: false + type: string + description: pcm_flavor_name + oam_net_id: + label: oam_net_id + hidden: false + immutable: false + type: string + description: oam_net_id + fsb2-Internal1-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + Internal1_forwarding_mode: + label: Internal1_forwarding_mode + hidden: false + immutable: false + type: string + description: Internal1_forwarding_mode + pcrf_cps_net_name: + label: pcrf_cps_net_name + hidden: false + immutable: false + type: string + description: pcrf_cps_net_name + cps_net_name: + label: cps_net_name + hidden: false + immutable: false + type: string + description: cps_net_name + pcrf_security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + Internal1_external: + label: Internal1_external + hidden: false + immutable: false + type: string + description: Internal1_external + node_templates: + nova_local_type_pcm1: + type: org.openecomp.resource.vfc.nodes.heat.pcm + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + user_data: UNSUPPORTED_RESOURCE_server_init + nova_local_type_pcm2: + type: org.openecomp.resource.vfc.nodes.heat.pcm + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + user_data: UNSUPPORTED_RESOURCE_server_init + nova_local_type_pcrf_psm: + type: org.openecomp.resource.vfc.nodes.heat.pcrf_psm + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + user_data: UNSUPPORTED_RESOURCE_server_init + nova_global_type1: + type: org.openecomp.resource.vfc.nodes.heat.nova.Server + properties: + flavor: + get_input: fsb1-flavor + availability_zone: + get_input: fsb_zone + name: + get_input: fsb1-name + nova_global_type2: + type: org.openecomp.resource.vfc.nodes.heat.nova.Server + properties: + flavor: + get_input: fsb1-flavor + availability_zone: + get_input: fsb_zone + metadata: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: '0644' + content: + str_replace: + template: + get_artifact: + - SELF + - nimbus-ethernet + params: + $dev: eth0 + $netmask: + get_input: cps_net_mask + $ip: + get_input: cps_net_ip + - path: /etc/sysconfig/network-scripts/ifcfg-eth1 + permissions: '0644' + content: + str_replace: + template: + get_artifact: + - SELF + - nimbus-ethernet-gw + params: + $dev: eth1 + $netmask: + get_input: oam_net_mask + $gateway: + get_input: oam_net_gw + $ip: + get_input: oam_net_ip + name: + get_input: fsb1-name + artifacts: + nimbus-ethernet-gw: + type: tosca.artifacts.Deployment + file: ../Artifacts/nimbus-ethernet-gw + nimbus-ethernet: + type: tosca.artifacts.Deployment + file: ../Artifacts/nimbus-ethernet + groups: + ep-jsa_net: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/ep-jsa_net.yaml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - nova_local_type_pcm1 + - nova_local_type_pcm2 + - nova_local_type_pcrf_psm + - nova_global_type1 + - nova_global_type2 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/all/OnlyComponentsST_01.yaml b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/all/OnlyComponentsST_01.yaml new file mode 100644 index 0000000000..54f39e4219 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/all/OnlyComponentsST_01.yaml @@ -0,0 +1,350 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.pcrf_psm: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.pcm: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + Internal2_name: + label: Internal2_name + hidden: false + immutable: false + type: string + description: Internal2_name + Internal1_shared: + label: Internal1_shared + hidden: false + immutable: false + type: string + description: Internal1_shared + FSB1_volume_name: + label: FSB1_volume + hidden: false + immutable: false + type: string + description: FSB1_volume_1 + jsa_cidr: + label: jsa_cidr + hidden: false + immutable: false + type: string + description: jsa_cidr + default: 107.243.7.128/26 + availabilityzone_name: + label: availabilityzone_name + hidden: false + immutable: false + type: string + description: availabilityzone_name + fsb1-name: + label: FSB1_name + hidden: false + immutable: false + type: string + description: FSB1_name + pcm_image_name: + label: pcm_image_name + hidden: false + immutable: false + type: string + description: pcm_image_name + Internal2_external: + label: Internal2_external + hidden: false + immutable: false + type: string + description: Internal2_external + Internal2_forwarding_mode: + label: Internal2_forwarding_mode + hidden: false + immutable: false + type: string + description: Internal2_forwarding_mode + pcrf_psm_flavor_name: + label: pcrf_psm_flavor_name + hidden: false + immutable: false + type: string + description: pcrf_psm_flavor_name + pcrf_psm_image_name: + label: pcrf_psm_image_name + hidden: false + immutable: false + type: string + description: pcrf_psm_image_name + FSB_1_image: + label: MME_FSB1 + hidden: false + immutable: false + type: string + description: MME_FSB1_15B-CP04-r5a01 + volume_size: + label: volume size + hidden: false + immutable: false + type: float + description: my volume size 320GB + fsb1-Internal1-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + Internal2_shared: + label: Internal2_shared + hidden: false + immutable: false + type: string + description: Internal2_shared + pcm_server_name: + label: pcm_server_name + hidden: false + immutable: false + type: string + description: pcm_server_name + Internal1_net_name: + label: Internal1_net_name + hidden: false + immutable: false + type: string + description: Internal1_net_name + oam_net_name: + label: oam_net_name + hidden: false + immutable: false + type: string + description: oam_net_name + fsb1-flavor: + label: FSB1_flavor + hidden: false + immutable: false + type: string + description: FSB1_flavor + fsb1-Internal2-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + volume_type: + label: volume type + hidden: false + immutable: false + type: string + description: volume type Gold + fsb1-zone: + label: FSB1_zone + hidden: false + immutable: false + type: string + description: FSB1_zone + fsb_zone: + label: FSB1_zone + hidden: false + immutable: false + type: string + description: FSB1_zone + security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + jsa_net_name: + label: jsa_net_name + hidden: false + immutable: false + type: string + description: jsa_net_name + default: jsa_log_net_0 + pcrf_psm_server_name: + label: pcrf_psm_server_name + hidden: false + immutable: false + type: string + description: pcrf_psm_server_name + pcm_flavor_name: + label: pcm_flavor_name + hidden: false + immutable: false + type: string + description: pcm_flavor_name + oam_net_id: + label: oam_net_id + hidden: false + immutable: false + type: string + description: oam_net_id + fsb2-Internal1-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + Internal1_forwarding_mode: + label: Internal1_forwarding_mode + hidden: false + immutable: false + type: string + description: Internal1_forwarding_mode + pcrf_cps_net_name: + label: pcrf_cps_net_name + hidden: false + immutable: false + type: string + description: pcrf_cps_net_name + cps_net_name: + label: cps_net_name + hidden: false + immutable: false + type: string + description: cps_net_name + pcrf_security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + Internal1_external: + label: Internal1_external + hidden: false + immutable: false + type: string + description: Internal1_external + node_templates: + nova_local_type_pcm1: + type: org.openecomp.resource.vfc.nodes.heat.pcm + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + user_data: UNSUPPORTED_RESOURCE_server_init + nova_local_type_pcm2: + type: org.openecomp.resource.vfc.nodes.heat.pcm + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + user_data: UNSUPPORTED_RESOURCE_server_init + nova_local_type_pcrf_psm: + type: org.openecomp.resource.vfc.nodes.heat.pcrf_psm + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + user_data: UNSUPPORTED_RESOURCE_server_init + nova_global_type1: + type: org.openecomp.resource.vfc.nodes.heat.nova.Server + properties: + flavor: + get_input: fsb1-flavor + availability_zone: + get_input: fsb_zone + name: + get_input: fsb1-name + nova_global_type2: + type: org.openecomp.resource.vfc.nodes.heat.nova.Server + properties: + flavor: + get_input: fsb1-flavor + availability_zone: + get_input: fsb_zone + metadata: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: '0644' + content: + str_replace: + template: + get_artifact: + - SELF + - nimbus-ethernet + params: + $dev: eth0 + $netmask: + get_input: cps_net_mask + $ip: + get_input: cps_net_ip + - path: /etc/sysconfig/network-scripts/ifcfg-eth1 + permissions: '0644' + content: + str_replace: + template: + get_artifact: + - SELF + - nimbus-ethernet-gw + params: + $dev: eth1 + $netmask: + get_input: oam_net_mask + $gateway: + get_input: oam_net_gw + $ip: + get_input: oam_net_ip + name: + get_input: fsb1-name + artifacts: + nimbus-ethernet-gw: + type: tosca.artifacts.Deployment + file: ../Artifacts/nimbus-ethernet-gw + nimbus-ethernet: + type: tosca.artifacts.Deployment + file: ../Artifacts/nimbus-ethernet + groups: + ep-jsa_net: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/ep-jsa_net.yaml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - nova_local_type_pcm1 + - nova_local_type_pcm2 + - nova_local_type_pcrf_psm + - nova_global_type1 + - nova_global_type2 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/all/VariouseST.yaml b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/all/VariouseST.yaml new file mode 100644 index 0000000000..1f39bfb314 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/all/VariouseST.yaml @@ -0,0 +1,363 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.pcrf_psm: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.pcm: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + Internal2_name: + label: Internal2_name + hidden: false + immutable: false + type: string + description: Internal2_name + Internal1_shared: + label: Internal1_shared + hidden: false + immutable: false + type: string + description: Internal1_shared + FSB1_volume_name: + label: FSB1_volume + hidden: false + immutable: false + type: string + description: FSB1_volume_1 + jsa_cidr: + label: jsa_cidr + hidden: false + immutable: false + type: string + description: jsa_cidr + default: 107.243.7.128/26 + availabilityzone_name: + label: availabilityzone_name + hidden: false + immutable: false + type: string + description: availabilityzone_name + fsb1-name: + label: FSB1_name + hidden: false + immutable: false + type: string + description: FSB1_name + pcm_image_name: + label: pcm_image_name + hidden: false + immutable: false + type: string + description: pcm_image_name + Internal2_external: + label: Internal2_external + hidden: false + immutable: false + type: string + description: Internal2_external + Internal2_forwarding_mode: + label: Internal2_forwarding_mode + hidden: false + immutable: false + type: string + description: Internal2_forwarding_mode + pcrf_psm_flavor_name: + label: pcrf_psm_flavor_name + hidden: false + immutable: false + type: string + description: pcrf_psm_flavor_name + pcrf_psm_image_name: + label: pcrf_psm_image_name + hidden: false + immutable: false + type: string + description: pcrf_psm_image_name + FSB_1_image: + label: MME_FSB1 + hidden: false + immutable: false + type: string + description: MME_FSB1_15B-CP04-r5a01 + volume_size: + label: volume size + hidden: false + immutable: false + type: float + description: my volume size 320GB + fsb1-Internal1-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + Internal2_shared: + label: Internal2_shared + hidden: false + immutable: false + type: string + description: Internal2_shared + pcm_server_name: + label: pcm_server_name + hidden: false + immutable: false + type: string + description: pcm_server_name + Internal1_net_name: + label: Internal1_net_name + hidden: false + immutable: false + type: string + description: Internal1_net_name + oam_net_name: + label: oam_net_name + hidden: false + immutable: false + type: string + description: oam_net_name + fsb1-flavor: + label: FSB1_flavor + hidden: false + immutable: false + type: string + description: FSB1_flavor + fsb1-Internal2-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + volume_type: + label: volume type + hidden: false + immutable: false + type: string + description: volume type Gold + fsb1-zone: + label: FSB1_zone + hidden: false + immutable: false + type: string + description: FSB1_zone + fsb_zone: + label: FSB1_zone + hidden: false + immutable: false + type: string + description: FSB1_zone + security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + jsa_net_name: + label: jsa_net_name + hidden: false + immutable: false + type: string + description: jsa_net_name + default: jsa_log_net_0 + pcrf_psm_server_name: + label: pcrf_psm_server_name + hidden: false + immutable: false + type: string + description: pcrf_psm_server_name + pcm_flavor_name: + label: pcm_flavor_name + hidden: false + immutable: false + type: string + description: pcm_flavor_name + oam_net_id: + label: oam_net_id + hidden: false + immutable: false + type: string + description: oam_net_id + fsb2-Internal1-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + Internal1_forwarding_mode: + label: Internal1_forwarding_mode + hidden: false + immutable: false + type: string + description: Internal1_forwarding_mode + pcrf_cps_net_name: + label: pcrf_cps_net_name + hidden: false + immutable: false + type: string + description: pcrf_cps_net_name + cps_net_name: + label: cps_net_name + hidden: false + immutable: false + type: string + description: cps_net_name + pcrf_security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + Internal1_external: + label: Internal1_external + hidden: false + immutable: false + type: string + description: Internal1_external + node_templates: + + jsa_net: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + shared: true + network_name: + get_input: jsa_net_name + jsa_net1: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + shared: true + network_name: + get_input: jsa_net_name + nova_local_type_pcm1: + type: org.openecomp.resource.vfc.nodes.heat.pcm + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + user_data: UNSUPPORTED_RESOURCE_server_init + nova_local_type_pcm2: + type: org.openecomp.resource.vfc.nodes.heat.pcm + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + user_data: UNSUPPORTED_RESOURCE_server_init + nova_local_type_pcrf_psm: + type: org.openecomp.resource.vfc.nodes.heat.pcrf_psm + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + user_data: UNSUPPORTED_RESOURCE_server_init + nova_global_type1: + type: org.openecomp.resource.vfc.nodes.heat.nova.Server + properties: + flavor: + get_input: fsb1-flavor + availability_zone: + get_input: fsb_zone + name: + get_input: fsb1-name + nova_global_type2: + type: org.openecomp.resource.vfc.nodes.heat.nova.Server + properties: + flavor: + get_input: fsb1-flavor + availability_zone: + get_input: fsb_zone + metadata: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: '0644' + content: + str_replace: + template: + get_artifact: + - SELF + - nimbus-ethernet + params: + $dev: eth0 + $netmask: + get_input: cps_net_mask + $ip: + get_input: cps_net_ip + - path: /etc/sysconfig/network-scripts/ifcfg-eth1 + permissions: '0644' + content: + str_replace: + template: + get_artifact: + - SELF + - nimbus-ethernet-gw + params: + $dev: eth1 + $netmask: + get_input: oam_net_mask + $gateway: + get_input: oam_net_gw + $ip: + get_input: oam_net_ip + name: + get_input: fsb1-name + artifacts: + nimbus-ethernet-gw: + type: tosca.artifacts.Deployment + file: ../Artifacts/nimbus-ethernet-gw + nimbus-ethernet: + type: tosca.artifacts.Deployment + file: ../Artifacts/nimbus-ethernet + groups: + ep-jsa_net: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/ep-jsa_net.yaml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - nova_local_type_pcm1 + - nova_local_type_pcm2 + - nova_local_type_pcrf_psm + - nova_global_type1 + - nova_global_type2 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/all/expectedOutput/OnlyComponentsST.yaml b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/all/expectedOutput/OnlyComponentsST.yaml new file mode 100644 index 0000000000..9ec1aa2a8d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/all/expectedOutput/OnlyComponentsST.yaml @@ -0,0 +1,550 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.pcrf_psm: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + capabilities: + instance: + type: org.openecomp.capabilities.metric.Ceilometer + description: Existence of instance + properties: + name: + type: string + description: Ceilometer metric type name to monitor. (The name ceilometer is using) + required: true + default: instance + status: SUPPORTED + description: + type: string + description: Description of the metric + required: false + status: SUPPORTED + unit: + type: string + description: Unit of the metric value + required: true + default: instance + status: SUPPORTED + type: + type: string + description: Type of the metric value, for an example, Cumulative, Delta, Gauge and etc. + required: true + default: Gauge + status: SUPPORTED + category: + type: string + description: Category of the metric, for an example, compute, disk, network, storage and etc. + required: false + default: compute + status: SUPPORTED + memory: + type: org.openecomp.capabilities.metric.Ceilometer + description: Volume of RAM allocated to the instance + properties: + name: + type: string + description: Ceilometer metric type name to monitor. (The name ceilometer is using) + required: true + default: memory + status: SUPPORTED + description: + type: string + description: Description of the metric + required: false + status: SUPPORTED + unit: + type: string + description: Unit of the metric value + required: true + default: MB + status: SUPPORTED + type: + type: string + description: Type of the metric value, for an example, Cumulative, Delta, Gauge and etc. + required: true + default: Gauge + status: SUPPORTED + category: + type: string + description: Category of the metric, for an example, compute, disk, network, storage and etc. + required: false + default: compute + status: SUPPORTED + cpu: + type: org.openecomp.capabilities.metric.Ceilometer + description: CPU time used + properties: + name: + type: string + description: Ceilometer metric type name to monitor. (The name ceilometer is using) + required: true + default: cpu + status: SUPPORTED + description: + type: string + description: Description of the metric + required: false + status: SUPPORTED + unit: + type: string + description: Unit of the metric value + required: true + default: ns + status: SUPPORTED + type: + type: string + description: Type of the metric value, for an example, Cumulative, Delta, Gauge and etc. + required: true + default: Cumulative + status: SUPPORTED + category: + type: string + description: Category of the metric, for an example, compute, disk, network, storage and etc. + required: false + default: compute + status: SUPPORTED + org.openecomp.resource.vfc.nodes.heat.pcm: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + capabilities: + instance: + type: org.openecomp.capabilities.metric.Ceilometer + description: Existence of instance + properties: + name: + type: string + description: Ceilometer metric type name to monitor. (The name ceilometer is using) + required: true + default: instance + status: SUPPORTED + description: + type: string + description: Description of the metric + required: false + status: SUPPORTED + unit: + type: string + description: Unit of the metric value + required: true + default: instance + status: SUPPORTED + type: + type: string + description: Type of the metric value, for an example, Cumulative, Delta, Gauge and etc. + required: true + default: Gauge + status: SUPPORTED + category: + type: string + description: Category of the metric, for an example, compute, disk, network, storage and etc. + required: false + default: compute + status: SUPPORTED + memory: + type: org.openecomp.capabilities.metric.Ceilometer + description: Volume of RAM allocated to the instance + properties: + name: + type: string + description: Ceilometer metric type name to monitor. (The name ceilometer is using) + required: true + default: memory + status: SUPPORTED + description: + type: string + description: Description of the metric + required: false + status: SUPPORTED + unit: + type: string + description: Unit of the metric value + required: true + default: MB + status: SUPPORTED + type: + type: string + description: Type of the metric value, for an example, Cumulative, Delta, Gauge and etc. + required: true + default: Gauge + status: SUPPORTED + category: + type: string + description: Category of the metric, for an example, compute, disk, network, storage and etc. + required: false + default: compute + status: SUPPORTED + cpu: + type: org.openecomp.capabilities.metric.Ceilometer + description: CPU time used + properties: + name: + type: string + description: Ceilometer metric type name to monitor. (The name ceilometer is using) + required: true + default: cpu + status: SUPPORTED + description: + type: string + description: Description of the metric + required: false + status: SUPPORTED + unit: + type: string + description: Unit of the metric value + required: true + default: ns + status: SUPPORTED + type: + type: string + description: Type of the metric value, for an example, Cumulative, Delta, Gauge and etc. + required: true + default: Cumulative + status: SUPPORTED + category: + type: string + description: Category of the metric, for an example, compute, disk, network, storage and etc. + required: false + default: compute + status: SUPPORTED +topology_template: + inputs: + Internal2_name: + label: Internal2_name + hidden: false + immutable: false + type: string + description: Internal2_name + Internal1_shared: + label: Internal1_shared + hidden: false + immutable: false + type: string + description: Internal1_shared + FSB1_volume_name: + label: FSB1_volume + hidden: false + immutable: false + type: string + description: FSB1_volume_1 + jsa_cidr: + label: jsa_cidr + hidden: false + immutable: false + type: string + description: jsa_cidr + default: 107.243.7.128/26 + availabilityzone_name: + label: availabilityzone_name + hidden: false + immutable: false + type: string + description: availabilityzone_name + fsb1-name: + label: FSB1_name + hidden: false + immutable: false + type: string + description: FSB1_name + pcm_image_name: + label: pcm_image_name + hidden: false + immutable: false + type: string + description: pcm_image_name + Internal2_external: + label: Internal2_external + hidden: false + immutable: false + type: string + description: Internal2_external + Internal2_forwarding_mode: + label: Internal2_forwarding_mode + hidden: false + immutable: false + type: string + description: Internal2_forwarding_mode + pcrf_psm_flavor_name: + label: pcrf_psm_flavor_name + hidden: false + immutable: false + type: string + description: pcrf_psm_flavor_name + pcrf_psm_image_name: + label: pcrf_psm_image_name + hidden: false + immutable: false + type: string + description: pcrf_psm_image_name + FSB_1_image: + label: MME_FSB1 + hidden: false + immutable: false + type: string + description: MME_FSB1_15B-CP04-r5a01 + volume_size: + label: volume size + hidden: false + immutable: false + type: float + description: my volume size 320GB + fsb1-Internal1-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + Internal2_shared: + label: Internal2_shared + hidden: false + immutable: false + type: string + description: Internal2_shared + pcm_server_name: + label: pcm_server_name + hidden: false + immutable: false + type: string + description: pcm_server_name + Internal1_net_name: + label: Internal1_net_name + hidden: false + immutable: false + type: string + description: Internal1_net_name + oam_net_name: + label: oam_net_name + hidden: false + immutable: false + type: string + description: oam_net_name + fsb1-flavor: + label: FSB1_flavor + hidden: false + immutable: false + type: string + description: FSB1_flavor + fsb1-Internal2-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + volume_type: + label: volume type + hidden: false + immutable: false + type: string + description: volume type Gold + fsb1-zone: + label: FSB1_zone + hidden: false + immutable: false + type: string + description: FSB1_zone + fsb_zone: + label: FSB1_zone + hidden: false + immutable: false + type: string + description: FSB1_zone + security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + jsa_net_name: + label: jsa_net_name + hidden: false + immutable: false + type: string + description: jsa_net_name + default: jsa_log_net_0 + pcrf_psm_server_name: + label: pcrf_psm_server_name + hidden: false + immutable: false + type: string + description: pcrf_psm_server_name + pcm_flavor_name: + label: pcm_flavor_name + hidden: false + immutable: false + type: string + description: pcm_flavor_name + oam_net_id: + label: oam_net_id + hidden: false + immutable: false + type: string + description: oam_net_id + fsb2-Internal1-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + Internal1_forwarding_mode: + label: Internal1_forwarding_mode + hidden: false + immutable: false + type: string + description: Internal1_forwarding_mode + pcrf_cps_net_name: + label: pcrf_cps_net_name + hidden: false + immutable: false + type: string + description: pcrf_cps_net_name + cps_net_name: + label: cps_net_name + hidden: false + immutable: false + type: string + description: cps_net_name + pcrf_security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + Internal1_external: + label: Internal1_external + hidden: false + immutable: false + type: string + description: Internal1_external + node_templates: + nova_local_type_pcm1: + type: org.openecomp.resource.vfc.nodes.heat.pcm + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + user_data: UNSUPPORTED_RESOURCE_server_init + nova_local_type_pcm2: + type: org.openecomp.resource.vfc.nodes.heat.pcm + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + user_data: UNSUPPORTED_RESOURCE_server_init + nova_local_type_pcrf_psm: + type: org.openecomp.resource.vfc.nodes.heat.pcrf_psm + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + user_data: UNSUPPORTED_RESOURCE_server_init + nova_global_type1: + type: org.openecomp.resource.vfc.nodes.heat.nova.Server + properties: + flavor: + get_input: fsb1-flavor + availability_zone: + get_input: fsb_zone + name: + get_input: fsb1-name + nova_global_type2: + type: org.openecomp.resource.vfc.nodes.heat.nova.Server + properties: + flavor: + get_input: fsb1-flavor + availability_zone: + get_input: fsb_zone + metadata: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: '0644' + content: + str_replace: + template: + get_artifact: + - SELF + - nimbus-ethernet + params: + $dev: eth0 + $netmask: + get_input: cps_net_mask + $ip: + get_input: cps_net_ip + - path: /etc/sysconfig/network-scripts/ifcfg-eth1 + permissions: '0644' + content: + str_replace: + template: + get_artifact: + - SELF + - nimbus-ethernet-gw + params: + $dev: eth1 + $netmask: + get_input: oam_net_mask + $gateway: + get_input: oam_net_gw + $ip: + get_input: oam_net_ip + name: + get_input: fsb1-name + artifacts: + nimbus-ethernet-gw: + type: tosca.artifacts.Deployment + file: ../Artifacts/nimbus-ethernet-gw + nimbus-ethernet: + type: tosca.artifacts.Deployment + file: ../Artifacts/nimbus-ethernet + groups: + ep-jsa_net: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/ep-jsa_net.yaml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - nova_local_type_pcm1 + - nova_local_type_pcm2 + - nova_local_type_pcrf_psm + - nova_global_type1 + - nova_global_type2 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/all/expectedOutput/OnlyComponentsST_01.yaml b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/all/expectedOutput/OnlyComponentsST_01.yaml new file mode 100644 index 0000000000..9ec1aa2a8d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/all/expectedOutput/OnlyComponentsST_01.yaml @@ -0,0 +1,550 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.pcrf_psm: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + capabilities: + instance: + type: org.openecomp.capabilities.metric.Ceilometer + description: Existence of instance + properties: + name: + type: string + description: Ceilometer metric type name to monitor. (The name ceilometer is using) + required: true + default: instance + status: SUPPORTED + description: + type: string + description: Description of the metric + required: false + status: SUPPORTED + unit: + type: string + description: Unit of the metric value + required: true + default: instance + status: SUPPORTED + type: + type: string + description: Type of the metric value, for an example, Cumulative, Delta, Gauge and etc. + required: true + default: Gauge + status: SUPPORTED + category: + type: string + description: Category of the metric, for an example, compute, disk, network, storage and etc. + required: false + default: compute + status: SUPPORTED + memory: + type: org.openecomp.capabilities.metric.Ceilometer + description: Volume of RAM allocated to the instance + properties: + name: + type: string + description: Ceilometer metric type name to monitor. (The name ceilometer is using) + required: true + default: memory + status: SUPPORTED + description: + type: string + description: Description of the metric + required: false + status: SUPPORTED + unit: + type: string + description: Unit of the metric value + required: true + default: MB + status: SUPPORTED + type: + type: string + description: Type of the metric value, for an example, Cumulative, Delta, Gauge and etc. + required: true + default: Gauge + status: SUPPORTED + category: + type: string + description: Category of the metric, for an example, compute, disk, network, storage and etc. + required: false + default: compute + status: SUPPORTED + cpu: + type: org.openecomp.capabilities.metric.Ceilometer + description: CPU time used + properties: + name: + type: string + description: Ceilometer metric type name to monitor. (The name ceilometer is using) + required: true + default: cpu + status: SUPPORTED + description: + type: string + description: Description of the metric + required: false + status: SUPPORTED + unit: + type: string + description: Unit of the metric value + required: true + default: ns + status: SUPPORTED + type: + type: string + description: Type of the metric value, for an example, Cumulative, Delta, Gauge and etc. + required: true + default: Cumulative + status: SUPPORTED + category: + type: string + description: Category of the metric, for an example, compute, disk, network, storage and etc. + required: false + default: compute + status: SUPPORTED + org.openecomp.resource.vfc.nodes.heat.pcm: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + capabilities: + instance: + type: org.openecomp.capabilities.metric.Ceilometer + description: Existence of instance + properties: + name: + type: string + description: Ceilometer metric type name to monitor. (The name ceilometer is using) + required: true + default: instance + status: SUPPORTED + description: + type: string + description: Description of the metric + required: false + status: SUPPORTED + unit: + type: string + description: Unit of the metric value + required: true + default: instance + status: SUPPORTED + type: + type: string + description: Type of the metric value, for an example, Cumulative, Delta, Gauge and etc. + required: true + default: Gauge + status: SUPPORTED + category: + type: string + description: Category of the metric, for an example, compute, disk, network, storage and etc. + required: false + default: compute + status: SUPPORTED + memory: + type: org.openecomp.capabilities.metric.Ceilometer + description: Volume of RAM allocated to the instance + properties: + name: + type: string + description: Ceilometer metric type name to monitor. (The name ceilometer is using) + required: true + default: memory + status: SUPPORTED + description: + type: string + description: Description of the metric + required: false + status: SUPPORTED + unit: + type: string + description: Unit of the metric value + required: true + default: MB + status: SUPPORTED + type: + type: string + description: Type of the metric value, for an example, Cumulative, Delta, Gauge and etc. + required: true + default: Gauge + status: SUPPORTED + category: + type: string + description: Category of the metric, for an example, compute, disk, network, storage and etc. + required: false + default: compute + status: SUPPORTED + cpu: + type: org.openecomp.capabilities.metric.Ceilometer + description: CPU time used + properties: + name: + type: string + description: Ceilometer metric type name to monitor. (The name ceilometer is using) + required: true + default: cpu + status: SUPPORTED + description: + type: string + description: Description of the metric + required: false + status: SUPPORTED + unit: + type: string + description: Unit of the metric value + required: true + default: ns + status: SUPPORTED + type: + type: string + description: Type of the metric value, for an example, Cumulative, Delta, Gauge and etc. + required: true + default: Cumulative + status: SUPPORTED + category: + type: string + description: Category of the metric, for an example, compute, disk, network, storage and etc. + required: false + default: compute + status: SUPPORTED +topology_template: + inputs: + Internal2_name: + label: Internal2_name + hidden: false + immutable: false + type: string + description: Internal2_name + Internal1_shared: + label: Internal1_shared + hidden: false + immutable: false + type: string + description: Internal1_shared + FSB1_volume_name: + label: FSB1_volume + hidden: false + immutable: false + type: string + description: FSB1_volume_1 + jsa_cidr: + label: jsa_cidr + hidden: false + immutable: false + type: string + description: jsa_cidr + default: 107.243.7.128/26 + availabilityzone_name: + label: availabilityzone_name + hidden: false + immutable: false + type: string + description: availabilityzone_name + fsb1-name: + label: FSB1_name + hidden: false + immutable: false + type: string + description: FSB1_name + pcm_image_name: + label: pcm_image_name + hidden: false + immutable: false + type: string + description: pcm_image_name + Internal2_external: + label: Internal2_external + hidden: false + immutable: false + type: string + description: Internal2_external + Internal2_forwarding_mode: + label: Internal2_forwarding_mode + hidden: false + immutable: false + type: string + description: Internal2_forwarding_mode + pcrf_psm_flavor_name: + label: pcrf_psm_flavor_name + hidden: false + immutable: false + type: string + description: pcrf_psm_flavor_name + pcrf_psm_image_name: + label: pcrf_psm_image_name + hidden: false + immutable: false + type: string + description: pcrf_psm_image_name + FSB_1_image: + label: MME_FSB1 + hidden: false + immutable: false + type: string + description: MME_FSB1_15B-CP04-r5a01 + volume_size: + label: volume size + hidden: false + immutable: false + type: float + description: my volume size 320GB + fsb1-Internal1-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + Internal2_shared: + label: Internal2_shared + hidden: false + immutable: false + type: string + description: Internal2_shared + pcm_server_name: + label: pcm_server_name + hidden: false + immutable: false + type: string + description: pcm_server_name + Internal1_net_name: + label: Internal1_net_name + hidden: false + immutable: false + type: string + description: Internal1_net_name + oam_net_name: + label: oam_net_name + hidden: false + immutable: false + type: string + description: oam_net_name + fsb1-flavor: + label: FSB1_flavor + hidden: false + immutable: false + type: string + description: FSB1_flavor + fsb1-Internal2-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + volume_type: + label: volume type + hidden: false + immutable: false + type: string + description: volume type Gold + fsb1-zone: + label: FSB1_zone + hidden: false + immutable: false + type: string + description: FSB1_zone + fsb_zone: + label: FSB1_zone + hidden: false + immutable: false + type: string + description: FSB1_zone + security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + jsa_net_name: + label: jsa_net_name + hidden: false + immutable: false + type: string + description: jsa_net_name + default: jsa_log_net_0 + pcrf_psm_server_name: + label: pcrf_psm_server_name + hidden: false + immutable: false + type: string + description: pcrf_psm_server_name + pcm_flavor_name: + label: pcm_flavor_name + hidden: false + immutable: false + type: string + description: pcm_flavor_name + oam_net_id: + label: oam_net_id + hidden: false + immutable: false + type: string + description: oam_net_id + fsb2-Internal1-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + Internal1_forwarding_mode: + label: Internal1_forwarding_mode + hidden: false + immutable: false + type: string + description: Internal1_forwarding_mode + pcrf_cps_net_name: + label: pcrf_cps_net_name + hidden: false + immutable: false + type: string + description: pcrf_cps_net_name + cps_net_name: + label: cps_net_name + hidden: false + immutable: false + type: string + description: cps_net_name + pcrf_security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + Internal1_external: + label: Internal1_external + hidden: false + immutable: false + type: string + description: Internal1_external + node_templates: + nova_local_type_pcm1: + type: org.openecomp.resource.vfc.nodes.heat.pcm + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + user_data: UNSUPPORTED_RESOURCE_server_init + nova_local_type_pcm2: + type: org.openecomp.resource.vfc.nodes.heat.pcm + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + user_data: UNSUPPORTED_RESOURCE_server_init + nova_local_type_pcrf_psm: + type: org.openecomp.resource.vfc.nodes.heat.pcrf_psm + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + user_data: UNSUPPORTED_RESOURCE_server_init + nova_global_type1: + type: org.openecomp.resource.vfc.nodes.heat.nova.Server + properties: + flavor: + get_input: fsb1-flavor + availability_zone: + get_input: fsb_zone + name: + get_input: fsb1-name + nova_global_type2: + type: org.openecomp.resource.vfc.nodes.heat.nova.Server + properties: + flavor: + get_input: fsb1-flavor + availability_zone: + get_input: fsb_zone + metadata: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: '0644' + content: + str_replace: + template: + get_artifact: + - SELF + - nimbus-ethernet + params: + $dev: eth0 + $netmask: + get_input: cps_net_mask + $ip: + get_input: cps_net_ip + - path: /etc/sysconfig/network-scripts/ifcfg-eth1 + permissions: '0644' + content: + str_replace: + template: + get_artifact: + - SELF + - nimbus-ethernet-gw + params: + $dev: eth1 + $netmask: + get_input: oam_net_mask + $gateway: + get_input: oam_net_gw + $ip: + get_input: oam_net_ip + name: + get_input: fsb1-name + artifacts: + nimbus-ethernet-gw: + type: tosca.artifacts.Deployment + file: ../Artifacts/nimbus-ethernet-gw + nimbus-ethernet: + type: tosca.artifacts.Deployment + file: ../Artifacts/nimbus-ethernet + groups: + ep-jsa_net: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/ep-jsa_net.yaml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - nova_local_type_pcm1 + - nova_local_type_pcm2 + - nova_local_type_pcrf_psm + - nova_global_type1 + - nova_global_type2 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/all/expectedOutput/VariouseST.yaml b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/all/expectedOutput/VariouseST.yaml new file mode 100644 index 0000000000..1f39bfb314 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/all/expectedOutput/VariouseST.yaml @@ -0,0 +1,363 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.pcrf_psm: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.pcm: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + Internal2_name: + label: Internal2_name + hidden: false + immutable: false + type: string + description: Internal2_name + Internal1_shared: + label: Internal1_shared + hidden: false + immutable: false + type: string + description: Internal1_shared + FSB1_volume_name: + label: FSB1_volume + hidden: false + immutable: false + type: string + description: FSB1_volume_1 + jsa_cidr: + label: jsa_cidr + hidden: false + immutable: false + type: string + description: jsa_cidr + default: 107.243.7.128/26 + availabilityzone_name: + label: availabilityzone_name + hidden: false + immutable: false + type: string + description: availabilityzone_name + fsb1-name: + label: FSB1_name + hidden: false + immutable: false + type: string + description: FSB1_name + pcm_image_name: + label: pcm_image_name + hidden: false + immutable: false + type: string + description: pcm_image_name + Internal2_external: + label: Internal2_external + hidden: false + immutable: false + type: string + description: Internal2_external + Internal2_forwarding_mode: + label: Internal2_forwarding_mode + hidden: false + immutable: false + type: string + description: Internal2_forwarding_mode + pcrf_psm_flavor_name: + label: pcrf_psm_flavor_name + hidden: false + immutable: false + type: string + description: pcrf_psm_flavor_name + pcrf_psm_image_name: + label: pcrf_psm_image_name + hidden: false + immutable: false + type: string + description: pcrf_psm_image_name + FSB_1_image: + label: MME_FSB1 + hidden: false + immutable: false + type: string + description: MME_FSB1_15B-CP04-r5a01 + volume_size: + label: volume size + hidden: false + immutable: false + type: float + description: my volume size 320GB + fsb1-Internal1-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + Internal2_shared: + label: Internal2_shared + hidden: false + immutable: false + type: string + description: Internal2_shared + pcm_server_name: + label: pcm_server_name + hidden: false + immutable: false + type: string + description: pcm_server_name + Internal1_net_name: + label: Internal1_net_name + hidden: false + immutable: false + type: string + description: Internal1_net_name + oam_net_name: + label: oam_net_name + hidden: false + immutable: false + type: string + description: oam_net_name + fsb1-flavor: + label: FSB1_flavor + hidden: false + immutable: false + type: string + description: FSB1_flavor + fsb1-Internal2-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + volume_type: + label: volume type + hidden: false + immutable: false + type: string + description: volume type Gold + fsb1-zone: + label: FSB1_zone + hidden: false + immutable: false + type: string + description: FSB1_zone + fsb_zone: + label: FSB1_zone + hidden: false + immutable: false + type: string + description: FSB1_zone + security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + jsa_net_name: + label: jsa_net_name + hidden: false + immutable: false + type: string + description: jsa_net_name + default: jsa_log_net_0 + pcrf_psm_server_name: + label: pcrf_psm_server_name + hidden: false + immutable: false + type: string + description: pcrf_psm_server_name + pcm_flavor_name: + label: pcm_flavor_name + hidden: false + immutable: false + type: string + description: pcm_flavor_name + oam_net_id: + label: oam_net_id + hidden: false + immutable: false + type: string + description: oam_net_id + fsb2-Internal1-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + Internal1_forwarding_mode: + label: Internal1_forwarding_mode + hidden: false + immutable: false + type: string + description: Internal1_forwarding_mode + pcrf_cps_net_name: + label: pcrf_cps_net_name + hidden: false + immutable: false + type: string + description: pcrf_cps_net_name + cps_net_name: + label: cps_net_name + hidden: false + immutable: false + type: string + description: cps_net_name + pcrf_security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + Internal1_external: + label: Internal1_external + hidden: false + immutable: false + type: string + description: Internal1_external + node_templates: + + jsa_net: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + shared: true + network_name: + get_input: jsa_net_name + jsa_net1: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + shared: true + network_name: + get_input: jsa_net_name + nova_local_type_pcm1: + type: org.openecomp.resource.vfc.nodes.heat.pcm + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + user_data: UNSUPPORTED_RESOURCE_server_init + nova_local_type_pcm2: + type: org.openecomp.resource.vfc.nodes.heat.pcm + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + user_data: UNSUPPORTED_RESOURCE_server_init + nova_local_type_pcrf_psm: + type: org.openecomp.resource.vfc.nodes.heat.pcrf_psm + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + user_data: UNSUPPORTED_RESOURCE_server_init + nova_global_type1: + type: org.openecomp.resource.vfc.nodes.heat.nova.Server + properties: + flavor: + get_input: fsb1-flavor + availability_zone: + get_input: fsb_zone + name: + get_input: fsb1-name + nova_global_type2: + type: org.openecomp.resource.vfc.nodes.heat.nova.Server + properties: + flavor: + get_input: fsb1-flavor + availability_zone: + get_input: fsb_zone + metadata: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: '0644' + content: + str_replace: + template: + get_artifact: + - SELF + - nimbus-ethernet + params: + $dev: eth0 + $netmask: + get_input: cps_net_mask + $ip: + get_input: cps_net_ip + - path: /etc/sysconfig/network-scripts/ifcfg-eth1 + permissions: '0644' + content: + str_replace: + template: + get_artifact: + - SELF + - nimbus-ethernet-gw + params: + $dev: eth1 + $netmask: + get_input: oam_net_mask + $gateway: + get_input: oam_net_gw + $ip: + get_input: oam_net_ip + name: + get_input: fsb1-name + artifacts: + nimbus-ethernet-gw: + type: tosca.artifacts.Deployment + file: ../Artifacts/nimbus-ethernet-gw + nimbus-ethernet: + type: tosca.artifacts.Deployment + file: ../Artifacts/nimbus-ethernet + groups: + ep-jsa_net: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/ep-jsa_net.yaml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - nova_local_type_pcm1 + - nova_local_type_pcm2 + - nova_local_type_pcrf_psm + - nova_global_type1 + - nova_global_type2 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/onlyComponents/OnlyComponentsST.yaml b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/onlyComponents/OnlyComponentsST.yaml new file mode 100644 index 0000000000..54f39e4219 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/onlyComponents/OnlyComponentsST.yaml @@ -0,0 +1,350 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.pcrf_psm: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.pcm: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + Internal2_name: + label: Internal2_name + hidden: false + immutable: false + type: string + description: Internal2_name + Internal1_shared: + label: Internal1_shared + hidden: false + immutable: false + type: string + description: Internal1_shared + FSB1_volume_name: + label: FSB1_volume + hidden: false + immutable: false + type: string + description: FSB1_volume_1 + jsa_cidr: + label: jsa_cidr + hidden: false + immutable: false + type: string + description: jsa_cidr + default: 107.243.7.128/26 + availabilityzone_name: + label: availabilityzone_name + hidden: false + immutable: false + type: string + description: availabilityzone_name + fsb1-name: + label: FSB1_name + hidden: false + immutable: false + type: string + description: FSB1_name + pcm_image_name: + label: pcm_image_name + hidden: false + immutable: false + type: string + description: pcm_image_name + Internal2_external: + label: Internal2_external + hidden: false + immutable: false + type: string + description: Internal2_external + Internal2_forwarding_mode: + label: Internal2_forwarding_mode + hidden: false + immutable: false + type: string + description: Internal2_forwarding_mode + pcrf_psm_flavor_name: + label: pcrf_psm_flavor_name + hidden: false + immutable: false + type: string + description: pcrf_psm_flavor_name + pcrf_psm_image_name: + label: pcrf_psm_image_name + hidden: false + immutable: false + type: string + description: pcrf_psm_image_name + FSB_1_image: + label: MME_FSB1 + hidden: false + immutable: false + type: string + description: MME_FSB1_15B-CP04-r5a01 + volume_size: + label: volume size + hidden: false + immutable: false + type: float + description: my volume size 320GB + fsb1-Internal1-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + Internal2_shared: + label: Internal2_shared + hidden: false + immutable: false + type: string + description: Internal2_shared + pcm_server_name: + label: pcm_server_name + hidden: false + immutable: false + type: string + description: pcm_server_name + Internal1_net_name: + label: Internal1_net_name + hidden: false + immutable: false + type: string + description: Internal1_net_name + oam_net_name: + label: oam_net_name + hidden: false + immutable: false + type: string + description: oam_net_name + fsb1-flavor: + label: FSB1_flavor + hidden: false + immutable: false + type: string + description: FSB1_flavor + fsb1-Internal2-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + volume_type: + label: volume type + hidden: false + immutable: false + type: string + description: volume type Gold + fsb1-zone: + label: FSB1_zone + hidden: false + immutable: false + type: string + description: FSB1_zone + fsb_zone: + label: FSB1_zone + hidden: false + immutable: false + type: string + description: FSB1_zone + security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + jsa_net_name: + label: jsa_net_name + hidden: false + immutable: false + type: string + description: jsa_net_name + default: jsa_log_net_0 + pcrf_psm_server_name: + label: pcrf_psm_server_name + hidden: false + immutable: false + type: string + description: pcrf_psm_server_name + pcm_flavor_name: + label: pcm_flavor_name + hidden: false + immutable: false + type: string + description: pcm_flavor_name + oam_net_id: + label: oam_net_id + hidden: false + immutable: false + type: string + description: oam_net_id + fsb2-Internal1-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + Internal1_forwarding_mode: + label: Internal1_forwarding_mode + hidden: false + immutable: false + type: string + description: Internal1_forwarding_mode + pcrf_cps_net_name: + label: pcrf_cps_net_name + hidden: false + immutable: false + type: string + description: pcrf_cps_net_name + cps_net_name: + label: cps_net_name + hidden: false + immutable: false + type: string + description: cps_net_name + pcrf_security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + Internal1_external: + label: Internal1_external + hidden: false + immutable: false + type: string + description: Internal1_external + node_templates: + nova_local_type_pcm1: + type: org.openecomp.resource.vfc.nodes.heat.pcm + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + user_data: UNSUPPORTED_RESOURCE_server_init + nova_local_type_pcm2: + type: org.openecomp.resource.vfc.nodes.heat.pcm + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + user_data: UNSUPPORTED_RESOURCE_server_init + nova_local_type_pcrf_psm: + type: org.openecomp.resource.vfc.nodes.heat.pcrf_psm + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + user_data: UNSUPPORTED_RESOURCE_server_init + nova_global_type1: + type: org.openecomp.resource.vfc.nodes.heat.nova.Server + properties: + flavor: + get_input: fsb1-flavor + availability_zone: + get_input: fsb_zone + name: + get_input: fsb1-name + nova_global_type2: + type: org.openecomp.resource.vfc.nodes.heat.nova.Server + properties: + flavor: + get_input: fsb1-flavor + availability_zone: + get_input: fsb_zone + metadata: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: '0644' + content: + str_replace: + template: + get_artifact: + - SELF + - nimbus-ethernet + params: + $dev: eth0 + $netmask: + get_input: cps_net_mask + $ip: + get_input: cps_net_ip + - path: /etc/sysconfig/network-scripts/ifcfg-eth1 + permissions: '0644' + content: + str_replace: + template: + get_artifact: + - SELF + - nimbus-ethernet-gw + params: + $dev: eth1 + $netmask: + get_input: oam_net_mask + $gateway: + get_input: oam_net_gw + $ip: + get_input: oam_net_ip + name: + get_input: fsb1-name + artifacts: + nimbus-ethernet-gw: + type: tosca.artifacts.Deployment + file: ../Artifacts/nimbus-ethernet-gw + nimbus-ethernet: + type: tosca.artifacts.Deployment + file: ../Artifacts/nimbus-ethernet + groups: + ep-jsa_net: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/ep-jsa_net.yaml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - nova_local_type_pcm1 + - nova_local_type_pcm2 + - nova_local_type_pcrf_psm + - nova_global_type1 + - nova_global_type2 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/onlyComponents/OnlyComponentsST_01.yaml b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/onlyComponents/OnlyComponentsST_01.yaml new file mode 100644 index 0000000000..54f39e4219 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/onlyComponents/OnlyComponentsST_01.yaml @@ -0,0 +1,350 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.pcrf_psm: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.pcm: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + Internal2_name: + label: Internal2_name + hidden: false + immutable: false + type: string + description: Internal2_name + Internal1_shared: + label: Internal1_shared + hidden: false + immutable: false + type: string + description: Internal1_shared + FSB1_volume_name: + label: FSB1_volume + hidden: false + immutable: false + type: string + description: FSB1_volume_1 + jsa_cidr: + label: jsa_cidr + hidden: false + immutable: false + type: string + description: jsa_cidr + default: 107.243.7.128/26 + availabilityzone_name: + label: availabilityzone_name + hidden: false + immutable: false + type: string + description: availabilityzone_name + fsb1-name: + label: FSB1_name + hidden: false + immutable: false + type: string + description: FSB1_name + pcm_image_name: + label: pcm_image_name + hidden: false + immutable: false + type: string + description: pcm_image_name + Internal2_external: + label: Internal2_external + hidden: false + immutable: false + type: string + description: Internal2_external + Internal2_forwarding_mode: + label: Internal2_forwarding_mode + hidden: false + immutable: false + type: string + description: Internal2_forwarding_mode + pcrf_psm_flavor_name: + label: pcrf_psm_flavor_name + hidden: false + immutable: false + type: string + description: pcrf_psm_flavor_name + pcrf_psm_image_name: + label: pcrf_psm_image_name + hidden: false + immutable: false + type: string + description: pcrf_psm_image_name + FSB_1_image: + label: MME_FSB1 + hidden: false + immutable: false + type: string + description: MME_FSB1_15B-CP04-r5a01 + volume_size: + label: volume size + hidden: false + immutable: false + type: float + description: my volume size 320GB + fsb1-Internal1-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + Internal2_shared: + label: Internal2_shared + hidden: false + immutable: false + type: string + description: Internal2_shared + pcm_server_name: + label: pcm_server_name + hidden: false + immutable: false + type: string + description: pcm_server_name + Internal1_net_name: + label: Internal1_net_name + hidden: false + immutable: false + type: string + description: Internal1_net_name + oam_net_name: + label: oam_net_name + hidden: false + immutable: false + type: string + description: oam_net_name + fsb1-flavor: + label: FSB1_flavor + hidden: false + immutable: false + type: string + description: FSB1_flavor + fsb1-Internal2-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + volume_type: + label: volume type + hidden: false + immutable: false + type: string + description: volume type Gold + fsb1-zone: + label: FSB1_zone + hidden: false + immutable: false + type: string + description: FSB1_zone + fsb_zone: + label: FSB1_zone + hidden: false + immutable: false + type: string + description: FSB1_zone + security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + jsa_net_name: + label: jsa_net_name + hidden: false + immutable: false + type: string + description: jsa_net_name + default: jsa_log_net_0 + pcrf_psm_server_name: + label: pcrf_psm_server_name + hidden: false + immutable: false + type: string + description: pcrf_psm_server_name + pcm_flavor_name: + label: pcm_flavor_name + hidden: false + immutable: false + type: string + description: pcm_flavor_name + oam_net_id: + label: oam_net_id + hidden: false + immutable: false + type: string + description: oam_net_id + fsb2-Internal1-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + Internal1_forwarding_mode: + label: Internal1_forwarding_mode + hidden: false + immutable: false + type: string + description: Internal1_forwarding_mode + pcrf_cps_net_name: + label: pcrf_cps_net_name + hidden: false + immutable: false + type: string + description: pcrf_cps_net_name + cps_net_name: + label: cps_net_name + hidden: false + immutable: false + type: string + description: cps_net_name + pcrf_security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + Internal1_external: + label: Internal1_external + hidden: false + immutable: false + type: string + description: Internal1_external + node_templates: + nova_local_type_pcm1: + type: org.openecomp.resource.vfc.nodes.heat.pcm + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + user_data: UNSUPPORTED_RESOURCE_server_init + nova_local_type_pcm2: + type: org.openecomp.resource.vfc.nodes.heat.pcm + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + user_data: UNSUPPORTED_RESOURCE_server_init + nova_local_type_pcrf_psm: + type: org.openecomp.resource.vfc.nodes.heat.pcrf_psm + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + user_data: UNSUPPORTED_RESOURCE_server_init + nova_global_type1: + type: org.openecomp.resource.vfc.nodes.heat.nova.Server + properties: + flavor: + get_input: fsb1-flavor + availability_zone: + get_input: fsb_zone + name: + get_input: fsb1-name + nova_global_type2: + type: org.openecomp.resource.vfc.nodes.heat.nova.Server + properties: + flavor: + get_input: fsb1-flavor + availability_zone: + get_input: fsb_zone + metadata: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: '0644' + content: + str_replace: + template: + get_artifact: + - SELF + - nimbus-ethernet + params: + $dev: eth0 + $netmask: + get_input: cps_net_mask + $ip: + get_input: cps_net_ip + - path: /etc/sysconfig/network-scripts/ifcfg-eth1 + permissions: '0644' + content: + str_replace: + template: + get_artifact: + - SELF + - nimbus-ethernet-gw + params: + $dev: eth1 + $netmask: + get_input: oam_net_mask + $gateway: + get_input: oam_net_gw + $ip: + get_input: oam_net_ip + name: + get_input: fsb1-name + artifacts: + nimbus-ethernet-gw: + type: tosca.artifacts.Deployment + file: ../Artifacts/nimbus-ethernet-gw + nimbus-ethernet: + type: tosca.artifacts.Deployment + file: ../Artifacts/nimbus-ethernet + groups: + ep-jsa_net: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/ep-jsa_net.yaml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - nova_local_type_pcm1 + - nova_local_type_pcm2 + - nova_local_type_pcrf_psm + - nova_global_type1 + - nova_global_type2 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/onlyComponents/expectedOutput/OnlyComponentsST.yaml b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/onlyComponents/expectedOutput/OnlyComponentsST.yaml new file mode 100644 index 0000000000..9ec1aa2a8d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/onlyComponents/expectedOutput/OnlyComponentsST.yaml @@ -0,0 +1,550 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.pcrf_psm: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + capabilities: + instance: + type: org.openecomp.capabilities.metric.Ceilometer + description: Existence of instance + properties: + name: + type: string + description: Ceilometer metric type name to monitor. (The name ceilometer is using) + required: true + default: instance + status: SUPPORTED + description: + type: string + description: Description of the metric + required: false + status: SUPPORTED + unit: + type: string + description: Unit of the metric value + required: true + default: instance + status: SUPPORTED + type: + type: string + description: Type of the metric value, for an example, Cumulative, Delta, Gauge and etc. + required: true + default: Gauge + status: SUPPORTED + category: + type: string + description: Category of the metric, for an example, compute, disk, network, storage and etc. + required: false + default: compute + status: SUPPORTED + memory: + type: org.openecomp.capabilities.metric.Ceilometer + description: Volume of RAM allocated to the instance + properties: + name: + type: string + description: Ceilometer metric type name to monitor. (The name ceilometer is using) + required: true + default: memory + status: SUPPORTED + description: + type: string + description: Description of the metric + required: false + status: SUPPORTED + unit: + type: string + description: Unit of the metric value + required: true + default: MB + status: SUPPORTED + type: + type: string + description: Type of the metric value, for an example, Cumulative, Delta, Gauge and etc. + required: true + default: Gauge + status: SUPPORTED + category: + type: string + description: Category of the metric, for an example, compute, disk, network, storage and etc. + required: false + default: compute + status: SUPPORTED + cpu: + type: org.openecomp.capabilities.metric.Ceilometer + description: CPU time used + properties: + name: + type: string + description: Ceilometer metric type name to monitor. (The name ceilometer is using) + required: true + default: cpu + status: SUPPORTED + description: + type: string + description: Description of the metric + required: false + status: SUPPORTED + unit: + type: string + description: Unit of the metric value + required: true + default: ns + status: SUPPORTED + type: + type: string + description: Type of the metric value, for an example, Cumulative, Delta, Gauge and etc. + required: true + default: Cumulative + status: SUPPORTED + category: + type: string + description: Category of the metric, for an example, compute, disk, network, storage and etc. + required: false + default: compute + status: SUPPORTED + org.openecomp.resource.vfc.nodes.heat.pcm: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + capabilities: + instance: + type: org.openecomp.capabilities.metric.Ceilometer + description: Existence of instance + properties: + name: + type: string + description: Ceilometer metric type name to monitor. (The name ceilometer is using) + required: true + default: instance + status: SUPPORTED + description: + type: string + description: Description of the metric + required: false + status: SUPPORTED + unit: + type: string + description: Unit of the metric value + required: true + default: instance + status: SUPPORTED + type: + type: string + description: Type of the metric value, for an example, Cumulative, Delta, Gauge and etc. + required: true + default: Gauge + status: SUPPORTED + category: + type: string + description: Category of the metric, for an example, compute, disk, network, storage and etc. + required: false + default: compute + status: SUPPORTED + memory: + type: org.openecomp.capabilities.metric.Ceilometer + description: Volume of RAM allocated to the instance + properties: + name: + type: string + description: Ceilometer metric type name to monitor. (The name ceilometer is using) + required: true + default: memory + status: SUPPORTED + description: + type: string + description: Description of the metric + required: false + status: SUPPORTED + unit: + type: string + description: Unit of the metric value + required: true + default: MB + status: SUPPORTED + type: + type: string + description: Type of the metric value, for an example, Cumulative, Delta, Gauge and etc. + required: true + default: Gauge + status: SUPPORTED + category: + type: string + description: Category of the metric, for an example, compute, disk, network, storage and etc. + required: false + default: compute + status: SUPPORTED + cpu: + type: org.openecomp.capabilities.metric.Ceilometer + description: CPU time used + properties: + name: + type: string + description: Ceilometer metric type name to monitor. (The name ceilometer is using) + required: true + default: cpu + status: SUPPORTED + description: + type: string + description: Description of the metric + required: false + status: SUPPORTED + unit: + type: string + description: Unit of the metric value + required: true + default: ns + status: SUPPORTED + type: + type: string + description: Type of the metric value, for an example, Cumulative, Delta, Gauge and etc. + required: true + default: Cumulative + status: SUPPORTED + category: + type: string + description: Category of the metric, for an example, compute, disk, network, storage and etc. + required: false + default: compute + status: SUPPORTED +topology_template: + inputs: + Internal2_name: + label: Internal2_name + hidden: false + immutable: false + type: string + description: Internal2_name + Internal1_shared: + label: Internal1_shared + hidden: false + immutable: false + type: string + description: Internal1_shared + FSB1_volume_name: + label: FSB1_volume + hidden: false + immutable: false + type: string + description: FSB1_volume_1 + jsa_cidr: + label: jsa_cidr + hidden: false + immutable: false + type: string + description: jsa_cidr + default: 107.243.7.128/26 + availabilityzone_name: + label: availabilityzone_name + hidden: false + immutable: false + type: string + description: availabilityzone_name + fsb1-name: + label: FSB1_name + hidden: false + immutable: false + type: string + description: FSB1_name + pcm_image_name: + label: pcm_image_name + hidden: false + immutable: false + type: string + description: pcm_image_name + Internal2_external: + label: Internal2_external + hidden: false + immutable: false + type: string + description: Internal2_external + Internal2_forwarding_mode: + label: Internal2_forwarding_mode + hidden: false + immutable: false + type: string + description: Internal2_forwarding_mode + pcrf_psm_flavor_name: + label: pcrf_psm_flavor_name + hidden: false + immutable: false + type: string + description: pcrf_psm_flavor_name + pcrf_psm_image_name: + label: pcrf_psm_image_name + hidden: false + immutable: false + type: string + description: pcrf_psm_image_name + FSB_1_image: + label: MME_FSB1 + hidden: false + immutable: false + type: string + description: MME_FSB1_15B-CP04-r5a01 + volume_size: + label: volume size + hidden: false + immutable: false + type: float + description: my volume size 320GB + fsb1-Internal1-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + Internal2_shared: + label: Internal2_shared + hidden: false + immutable: false + type: string + description: Internal2_shared + pcm_server_name: + label: pcm_server_name + hidden: false + immutable: false + type: string + description: pcm_server_name + Internal1_net_name: + label: Internal1_net_name + hidden: false + immutable: false + type: string + description: Internal1_net_name + oam_net_name: + label: oam_net_name + hidden: false + immutable: false + type: string + description: oam_net_name + fsb1-flavor: + label: FSB1_flavor + hidden: false + immutable: false + type: string + description: FSB1_flavor + fsb1-Internal2-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + volume_type: + label: volume type + hidden: false + immutable: false + type: string + description: volume type Gold + fsb1-zone: + label: FSB1_zone + hidden: false + immutable: false + type: string + description: FSB1_zone + fsb_zone: + label: FSB1_zone + hidden: false + immutable: false + type: string + description: FSB1_zone + security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + jsa_net_name: + label: jsa_net_name + hidden: false + immutable: false + type: string + description: jsa_net_name + default: jsa_log_net_0 + pcrf_psm_server_name: + label: pcrf_psm_server_name + hidden: false + immutable: false + type: string + description: pcrf_psm_server_name + pcm_flavor_name: + label: pcm_flavor_name + hidden: false + immutable: false + type: string + description: pcm_flavor_name + oam_net_id: + label: oam_net_id + hidden: false + immutable: false + type: string + description: oam_net_id + fsb2-Internal1-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + Internal1_forwarding_mode: + label: Internal1_forwarding_mode + hidden: false + immutable: false + type: string + description: Internal1_forwarding_mode + pcrf_cps_net_name: + label: pcrf_cps_net_name + hidden: false + immutable: false + type: string + description: pcrf_cps_net_name + cps_net_name: + label: cps_net_name + hidden: false + immutable: false + type: string + description: cps_net_name + pcrf_security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + Internal1_external: + label: Internal1_external + hidden: false + immutable: false + type: string + description: Internal1_external + node_templates: + nova_local_type_pcm1: + type: org.openecomp.resource.vfc.nodes.heat.pcm + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + user_data: UNSUPPORTED_RESOURCE_server_init + nova_local_type_pcm2: + type: org.openecomp.resource.vfc.nodes.heat.pcm + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + user_data: UNSUPPORTED_RESOURCE_server_init + nova_local_type_pcrf_psm: + type: org.openecomp.resource.vfc.nodes.heat.pcrf_psm + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + user_data: UNSUPPORTED_RESOURCE_server_init + nova_global_type1: + type: org.openecomp.resource.vfc.nodes.heat.nova.Server + properties: + flavor: + get_input: fsb1-flavor + availability_zone: + get_input: fsb_zone + name: + get_input: fsb1-name + nova_global_type2: + type: org.openecomp.resource.vfc.nodes.heat.nova.Server + properties: + flavor: + get_input: fsb1-flavor + availability_zone: + get_input: fsb_zone + metadata: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: '0644' + content: + str_replace: + template: + get_artifact: + - SELF + - nimbus-ethernet + params: + $dev: eth0 + $netmask: + get_input: cps_net_mask + $ip: + get_input: cps_net_ip + - path: /etc/sysconfig/network-scripts/ifcfg-eth1 + permissions: '0644' + content: + str_replace: + template: + get_artifact: + - SELF + - nimbus-ethernet-gw + params: + $dev: eth1 + $netmask: + get_input: oam_net_mask + $gateway: + get_input: oam_net_gw + $ip: + get_input: oam_net_ip + name: + get_input: fsb1-name + artifacts: + nimbus-ethernet-gw: + type: tosca.artifacts.Deployment + file: ../Artifacts/nimbus-ethernet-gw + nimbus-ethernet: + type: tosca.artifacts.Deployment + file: ../Artifacts/nimbus-ethernet + groups: + ep-jsa_net: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/ep-jsa_net.yaml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - nova_local_type_pcm1 + - nova_local_type_pcm2 + - nova_local_type_pcrf_psm + - nova_global_type1 + - nova_global_type2 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/onlyComponents/expectedOutput/OnlyComponentsST_01.yaml b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/onlyComponents/expectedOutput/OnlyComponentsST_01.yaml new file mode 100644 index 0000000000..9ec1aa2a8d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/onlyComponents/expectedOutput/OnlyComponentsST_01.yaml @@ -0,0 +1,550 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.pcrf_psm: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + capabilities: + instance: + type: org.openecomp.capabilities.metric.Ceilometer + description: Existence of instance + properties: + name: + type: string + description: Ceilometer metric type name to monitor. (The name ceilometer is using) + required: true + default: instance + status: SUPPORTED + description: + type: string + description: Description of the metric + required: false + status: SUPPORTED + unit: + type: string + description: Unit of the metric value + required: true + default: instance + status: SUPPORTED + type: + type: string + description: Type of the metric value, for an example, Cumulative, Delta, Gauge and etc. + required: true + default: Gauge + status: SUPPORTED + category: + type: string + description: Category of the metric, for an example, compute, disk, network, storage and etc. + required: false + default: compute + status: SUPPORTED + memory: + type: org.openecomp.capabilities.metric.Ceilometer + description: Volume of RAM allocated to the instance + properties: + name: + type: string + description: Ceilometer metric type name to monitor. (The name ceilometer is using) + required: true + default: memory + status: SUPPORTED + description: + type: string + description: Description of the metric + required: false + status: SUPPORTED + unit: + type: string + description: Unit of the metric value + required: true + default: MB + status: SUPPORTED + type: + type: string + description: Type of the metric value, for an example, Cumulative, Delta, Gauge and etc. + required: true + default: Gauge + status: SUPPORTED + category: + type: string + description: Category of the metric, for an example, compute, disk, network, storage and etc. + required: false + default: compute + status: SUPPORTED + cpu: + type: org.openecomp.capabilities.metric.Ceilometer + description: CPU time used + properties: + name: + type: string + description: Ceilometer metric type name to monitor. (The name ceilometer is using) + required: true + default: cpu + status: SUPPORTED + description: + type: string + description: Description of the metric + required: false + status: SUPPORTED + unit: + type: string + description: Unit of the metric value + required: true + default: ns + status: SUPPORTED + type: + type: string + description: Type of the metric value, for an example, Cumulative, Delta, Gauge and etc. + required: true + default: Cumulative + status: SUPPORTED + category: + type: string + description: Category of the metric, for an example, compute, disk, network, storage and etc. + required: false + default: compute + status: SUPPORTED + org.openecomp.resource.vfc.nodes.heat.pcm: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + capabilities: + instance: + type: org.openecomp.capabilities.metric.Ceilometer + description: Existence of instance + properties: + name: + type: string + description: Ceilometer metric type name to monitor. (The name ceilometer is using) + required: true + default: instance + status: SUPPORTED + description: + type: string + description: Description of the metric + required: false + status: SUPPORTED + unit: + type: string + description: Unit of the metric value + required: true + default: instance + status: SUPPORTED + type: + type: string + description: Type of the metric value, for an example, Cumulative, Delta, Gauge and etc. + required: true + default: Gauge + status: SUPPORTED + category: + type: string + description: Category of the metric, for an example, compute, disk, network, storage and etc. + required: false + default: compute + status: SUPPORTED + memory: + type: org.openecomp.capabilities.metric.Ceilometer + description: Volume of RAM allocated to the instance + properties: + name: + type: string + description: Ceilometer metric type name to monitor. (The name ceilometer is using) + required: true + default: memory + status: SUPPORTED + description: + type: string + description: Description of the metric + required: false + status: SUPPORTED + unit: + type: string + description: Unit of the metric value + required: true + default: MB + status: SUPPORTED + type: + type: string + description: Type of the metric value, for an example, Cumulative, Delta, Gauge and etc. + required: true + default: Gauge + status: SUPPORTED + category: + type: string + description: Category of the metric, for an example, compute, disk, network, storage and etc. + required: false + default: compute + status: SUPPORTED + cpu: + type: org.openecomp.capabilities.metric.Ceilometer + description: CPU time used + properties: + name: + type: string + description: Ceilometer metric type name to monitor. (The name ceilometer is using) + required: true + default: cpu + status: SUPPORTED + description: + type: string + description: Description of the metric + required: false + status: SUPPORTED + unit: + type: string + description: Unit of the metric value + required: true + default: ns + status: SUPPORTED + type: + type: string + description: Type of the metric value, for an example, Cumulative, Delta, Gauge and etc. + required: true + default: Cumulative + status: SUPPORTED + category: + type: string + description: Category of the metric, for an example, compute, disk, network, storage and etc. + required: false + default: compute + status: SUPPORTED +topology_template: + inputs: + Internal2_name: + label: Internal2_name + hidden: false + immutable: false + type: string + description: Internal2_name + Internal1_shared: + label: Internal1_shared + hidden: false + immutable: false + type: string + description: Internal1_shared + FSB1_volume_name: + label: FSB1_volume + hidden: false + immutable: false + type: string + description: FSB1_volume_1 + jsa_cidr: + label: jsa_cidr + hidden: false + immutable: false + type: string + description: jsa_cidr + default: 107.243.7.128/26 + availabilityzone_name: + label: availabilityzone_name + hidden: false + immutable: false + type: string + description: availabilityzone_name + fsb1-name: + label: FSB1_name + hidden: false + immutable: false + type: string + description: FSB1_name + pcm_image_name: + label: pcm_image_name + hidden: false + immutable: false + type: string + description: pcm_image_name + Internal2_external: + label: Internal2_external + hidden: false + immutable: false + type: string + description: Internal2_external + Internal2_forwarding_mode: + label: Internal2_forwarding_mode + hidden: false + immutable: false + type: string + description: Internal2_forwarding_mode + pcrf_psm_flavor_name: + label: pcrf_psm_flavor_name + hidden: false + immutable: false + type: string + description: pcrf_psm_flavor_name + pcrf_psm_image_name: + label: pcrf_psm_image_name + hidden: false + immutable: false + type: string + description: pcrf_psm_image_name + FSB_1_image: + label: MME_FSB1 + hidden: false + immutable: false + type: string + description: MME_FSB1_15B-CP04-r5a01 + volume_size: + label: volume size + hidden: false + immutable: false + type: float + description: my volume size 320GB + fsb1-Internal1-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + Internal2_shared: + label: Internal2_shared + hidden: false + immutable: false + type: string + description: Internal2_shared + pcm_server_name: + label: pcm_server_name + hidden: false + immutable: false + type: string + description: pcm_server_name + Internal1_net_name: + label: Internal1_net_name + hidden: false + immutable: false + type: string + description: Internal1_net_name + oam_net_name: + label: oam_net_name + hidden: false + immutable: false + type: string + description: oam_net_name + fsb1-flavor: + label: FSB1_flavor + hidden: false + immutable: false + type: string + description: FSB1_flavor + fsb1-Internal2-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + volume_type: + label: volume type + hidden: false + immutable: false + type: string + description: volume type Gold + fsb1-zone: + label: FSB1_zone + hidden: false + immutable: false + type: string + description: FSB1_zone + fsb_zone: + label: FSB1_zone + hidden: false + immutable: false + type: string + description: FSB1_zone + security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + jsa_net_name: + label: jsa_net_name + hidden: false + immutable: false + type: string + description: jsa_net_name + default: jsa_log_net_0 + pcrf_psm_server_name: + label: pcrf_psm_server_name + hidden: false + immutable: false + type: string + description: pcrf_psm_server_name + pcm_flavor_name: + label: pcm_flavor_name + hidden: false + immutable: false + type: string + description: pcm_flavor_name + oam_net_id: + label: oam_net_id + hidden: false + immutable: false + type: string + description: oam_net_id + fsb2-Internal1-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + Internal1_forwarding_mode: + label: Internal1_forwarding_mode + hidden: false + immutable: false + type: string + description: Internal1_forwarding_mode + pcrf_cps_net_name: + label: pcrf_cps_net_name + hidden: false + immutable: false + type: string + description: pcrf_cps_net_name + cps_net_name: + label: cps_net_name + hidden: false + immutable: false + type: string + description: cps_net_name + pcrf_security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + Internal1_external: + label: Internal1_external + hidden: false + immutable: false + type: string + description: Internal1_external + node_templates: + nova_local_type_pcm1: + type: org.openecomp.resource.vfc.nodes.heat.pcm + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + user_data: UNSUPPORTED_RESOURCE_server_init + nova_local_type_pcm2: + type: org.openecomp.resource.vfc.nodes.heat.pcm + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + user_data: UNSUPPORTED_RESOURCE_server_init + nova_local_type_pcrf_psm: + type: org.openecomp.resource.vfc.nodes.heat.pcrf_psm + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + user_data: UNSUPPORTED_RESOURCE_server_init + nova_global_type1: + type: org.openecomp.resource.vfc.nodes.heat.nova.Server + properties: + flavor: + get_input: fsb1-flavor + availability_zone: + get_input: fsb_zone + name: + get_input: fsb1-name + nova_global_type2: + type: org.openecomp.resource.vfc.nodes.heat.nova.Server + properties: + flavor: + get_input: fsb1-flavor + availability_zone: + get_input: fsb_zone + metadata: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: '0644' + content: + str_replace: + template: + get_artifact: + - SELF + - nimbus-ethernet + params: + $dev: eth0 + $netmask: + get_input: cps_net_mask + $ip: + get_input: cps_net_ip + - path: /etc/sysconfig/network-scripts/ifcfg-eth1 + permissions: '0644' + content: + str_replace: + template: + get_artifact: + - SELF + - nimbus-ethernet-gw + params: + $dev: eth1 + $netmask: + get_input: oam_net_mask + $gateway: + get_input: oam_net_gw + $ip: + get_input: oam_net_ip + name: + get_input: fsb1-name + artifacts: + nimbus-ethernet-gw: + type: tosca.artifacts.Deployment + file: ../Artifacts/nimbus-ethernet-gw + nimbus-ethernet: + type: tosca.artifacts.Deployment + file: ../Artifacts/nimbus-ethernet + groups: + ep-jsa_net: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/ep-jsa_net.yaml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - nova_local_type_pcm1 + - nova_local_type_pcm2 + - nova_local_type_pcrf_psm + - nova_global_type1 + - nova_global_type2 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/AbstractSubstituteGlobalTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/AbstractSubstituteGlobalTypesServiceTemplate.yaml new file mode 100644 index 0000000000..8813b0abf6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/AbstractSubstituteGlobalTypesServiceTemplate.yaml @@ -0,0 +1,47 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: AbstractSubstituteGlobalTypes + template_version: 1.0.0 +description: Abstract Substitute Global Types +imports: + common_definitions: + file: CommonGlobalTypesServiceTemplate.yaml +data_types: + org.openecomp.datatypes.heat.substitution.SubstitutionFilter: + derived_from: tosca.datatypes.Root + description: Substitution Filter + properties: + substitute_service_template: + type: string + description: Substitute Service Template + required: true + status: SUPPORTED + index_variable: + type: string + description: Index variable + required: false + default: '%index%' + status: SUPPORTED + constraints: + - min_length: 3 + count: + type: string + description: Count + required: false + default: 1 + status: SUPPORTED + mandatory: + type: boolean + description: Mandatory + required: false + default: true + status: SUPPORTED +node_types: + org.openecomp.resource.abstract.nodes.AbstractSubstitute: + derived_from: tosca.nodes.Root + properties: + service_template_filter: + type: org.openecomp.datatypes.heat.substitution.SubstitutionFilter + description: Substitution Filter + required: true + status: SUPPORTED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/CinderVolumeGlobalTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/CinderVolumeGlobalTypesServiceTemplate.yaml new file mode 100644 index 0000000000..3ef94f22e7 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/CinderVolumeGlobalTypesServiceTemplate.yaml @@ -0,0 +1,176 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: CinderVolumeGlobalTypes + template_version: 1.0.0 +description: Cinder Volume TOSCA Global Types +relationship_types: + org.openecomp.relationships.heat.cinder.VolumeAttachesTo: + derived_from: tosca.relationships.AttachesTo + description: This type represents an attachment relationship for associating volume + properties: + volume_id: + type: string + description: The ID of the volume to be attached + required: true + status: SUPPORTED + location: + type: string + description: The location where the volume is exposed on the instance, mountpoint + required: false + status: SUPPORTED + instance_uuid: + type: string + description: The ID of the server to which the volume attaches + required: true + status: SUPPORTED + attributes: + show: + type: string + description: Detailed information about resource + status: SUPPORTED +node_types: + org.openecomp.resource.vfc.nodes.heat.cinder.Volume: + derived_from: tosca.nodes.BlockStorage + properties: + availability_zone: + type: string + description: The availability zone in which the volume will be created + required: false + status: SUPPORTED + image: + type: string + description: If specified, the name or ID of the image to create the volume from + required: false + status: SUPPORTED + metadata: + type: map + description: Key/value pairs to associate with the volume + required: false + status: SUPPORTED + entry_schema: + type: string + volume_type: + type: string + description: If specified, the type of volume to use, mapping to a specific backend + required: false + status: SUPPORTED + description: + type: string + description: A description of the volume + required: false + status: SUPPORTED + device_type: + type: string + description: Device type + required: false + status: SUPPORTED + constraints: + - valid_values: + - cdrom + - disk + disk_bus: + type: string + description: 'Bus of the device: hypervisor driver chooses a suitable default + if omitted' + required: false + status: SUPPORTED + constraints: + - valid_values: + - ide + - lame_bus + - scsi + - usb + - virtio + backup_id: + type: string + description: If specified, the backup to create the volume from + required: false + status: SUPPORTED + source_volid: + type: string + description: If specified, the volume to use as source + required: false + status: SUPPORTED + boot_index: + type: integer + description: Integer used for ordering the boot disks + required: false + status: SUPPORTED + size: + type: scalar-unit.size + description: The requested storage size (default unit is MB) + required: false + status: SUPPORTED + constraints: + - greater_or_equal: 1 GB + read_only: + type: boolean + description: Enables or disables read-only access mode of volume + required: false + status: SUPPORTED + name: + type: string + description: A name used to distinguish the volume + required: false + status: SUPPORTED + scheduler_hints: + type: map + description: Arbitrary key-value pairs specified by the client to help the Cinder scheduler creating a volume + required: false + status: SUPPORTED + entry_schema: + type: string + swap_size: + type: scalar-unit.size + description: The size of the swap, in MB + required: false + status: SUPPORTED + delete_on_termination: + type: boolean + description: Indicate whether the volume should be deleted when the server is terminated + required: false + status: SUPPORTED + multiattach: + type: boolean + description: Whether allow the volume to be attached more than once + required: false + status: SUPPORTED + attributes: + display_description: + type: string + description: Description of the volume + status: SUPPORTED + attachments: + type: string + description: The list of attachments of the volume + status: SUPPORTED + entry_schema: + type: string + encrypted: + type: boolean + description: Boolean indicating if the volume is encrypted or not + status: SUPPORTED + show: + type: string + description: Detailed information about resource + status: SUPPORTED + created_at: + type: timestamp + description: The timestamp indicating volume creation + status: SUPPORTED + display_name: + type: string + description: Name of the volume + status: SUPPORTED + metadata_values: + type: map + description: Key/value pairs associated with the volume in raw dict form + status: SUPPORTED + bootable: + type: boolean + description: Boolean indicating if the volume can be booted or not + status: SUPPORTED + status: + type: string + description: The current status of the volume + status: SUPPORTED diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/CommonGlobalTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/CommonGlobalTypesServiceTemplate.yaml new file mode 100644 index 0000000000..3388d5a89b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/CommonGlobalTypesServiceTemplate.yaml @@ -0,0 +1,213 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: CommonGlobalTypes + template_version: 1.0.0 +description: TOSCA Global Types +imports: + NativeTypesServiceTemplate: + file: NativeTypesServiceTemplateServiceTemplate.yaml +data_types: + org.openecomp.datatypes.heat.network.AddressPair: + derived_from: tosca.datatypes.Root + description: MAC/IP address pairs + properties: + mac_address: + type: string + description: MAC address + required: false + status: SUPPORTED + ip_address: + type: string + description: IP address + required: false + status: SUPPORTED + org.openecomp.datatypes.heat.network.subnet.HostRoute: + derived_from: tosca.datatypes.Root + description: Host route info for the subnet + properties: + destination: + type: string + description: The destination for static route + required: false + status: SUPPORTED + nexthop: + type: string + description: The next hop for the destination + required: false + status: SUPPORTED + org.openecomp.datatypes.heat.network.neutron.Subnet: + derived_from: tosca.datatypes.Root + description: A subnet represents an IP address block that can be used for assigning IP addresses to virtual instances + properties: + tenant_id: + type: string + description: The ID of the tenant who owns the network + required: false + status: SUPPORTED + enable_dhcp: + type: boolean + description: Set to true if DHCP is enabled and false if DHCP is disabled + required: false + default: true + status: SUPPORTED + ipv6_address_mode: + type: string + description: IPv6 address mode + required: false + status: SUPPORTED + constraints: + - valid_values: + - dhcpv6-stateful + - dhcpv6-stateless + - slaac + ipv6_ra_mode: + type: string + description: IPv6 RA (Router Advertisement) mode + required: false + status: SUPPORTED + constraints: + - valid_values: + - dhcpv6-stateful + - dhcpv6-stateless + - slaac + value_specs: + type: map + description: Extra parameters to include in the request + required: false + default: { + } + status: SUPPORTED + entry_schema: + type: string + allocation_pools: + type: list + description: The start and end addresses for the allocation pools + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.AllocationPool + subnetpool: + type: string + description: The name or ID of the subnet pool + required: false + status: SUPPORTED + dns_nameservers: + type: list + description: A specified set of DNS name servers to be used + required: false + default: [ + ] + status: SUPPORTED + entry_schema: + type: string + host_routes: + type: list + description: The gateway IP address + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.subnet.HostRoute + ip_version: + type: integer + description: The gateway IP address + required: false + default: 4 + status: SUPPORTED + constraints: + - valid_values: + - '4' + - '6' + name: + type: string + description: The name of the subnet + required: false + status: SUPPORTED + prefixlen: + type: integer + description: Prefix length for subnet allocation from subnet pool + required: false + status: SUPPORTED + constraints: + - greater_or_equal: 0 + cidr: + type: string + description: The CIDR + required: false + status: SUPPORTED + gateway_ip: + type: string + description: The gateway IP address + required: false + status: SUPPORTED + org.openecomp.datatypes.heat.network.AllocationPool: + derived_from: tosca.datatypes.Root + description: The start and end addresses for the allocation pool + properties: + start: + type: string + description: Start address for the allocation pool + required: false + status: SUPPORTED + end: + type: string + description: End address for the allocation pool + required: false + status: SUPPORTED +relationship_types: + org.openecomp.relationships.AttachesTo: + derived_from: tosca.relationships.Root + description: This type represents an attachment relationship +group_types: + org.openecomp.groups.heat.HeatStack: + derived_from: tosca.groups.Root + description: Grouped all heat resources which are in the same heat stack + properties: + heat_file: + type: string + description: Heat file which associate to this group/heat stack + required: true + status: SUPPORTED + description: + type: string + description: Heat file description + required: false + status: SUPPORTED +policy_types: + org.openecomp.policies.placement.Colocate: + derived_from: tosca.policy.placement + description: Keep associated nodes (groups of nodes) based upon affinity value + properties: + name: + type: string + description: The name of the policy + required: false + status: SUPPORTED + affinity: + type: string + description: affinity + required: true + status: SUPPORTED + constraints: + - valid_values: + - host + - region + - compute + org.openecomp.policies.placement.Antilocate: + derived_from: tosca.policy.placement + description: My placement policy for separation based upon container type value + properties: + name: + type: string + description: The name of the policy + required: false + status: SUPPORTED + container_type: + type: string + description: container type + required: false + status: SUPPORTED + constraints: + - valid_values: + - host + - region + - compute diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/ContrailNetworkRuleGlobalTypeServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/ContrailNetworkRuleGlobalTypeServiceTemplate.yaml new file mode 100644 index 0000000000..98317310fa --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/ContrailNetworkRuleGlobalTypeServiceTemplate.yaml @@ -0,0 +1,117 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: ContrailNetworkRuleGlobalType + template_version: 1.0.0 +description: Contrail Network Rule Global Types +imports: + common_definitions: + file: CommonGlobalTypesServiceTemplate.yaml +data_types: + org.openecomp.datatypes.heat.contrail.network.rule.PortPairs: + derived_from: tosca.datatypes.Root + description: source and destination port pairs + properties: + start_port: + type: string + description: Start port + required: false + status: SUPPORTED + end_port: + type: string + description: End port + required: false + status: SUPPORTED + org.openecomp.datatypes.heat.contrail.network.rule.Rule: + derived_from: tosca.datatypes.Root + description: policy rule + properties: + src_ports: + type: list + description: Source ports + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.contrail.network.rule.PortPairs + protocol: + type: string + description: Protocol + required: false + status: SUPPORTED + dst_addresses: + type: list + description: Destination addresses + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.contrail.network.rule.VirtualNetwork + apply_service: + type: string + description: Service to apply + required: false + status: SUPPORTED + dst_ports: + type: list + description: Destination ports + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.contrail.network.rule.PortPairs + src_addresses: + type: list + description: Source addresses + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.contrail.network.rule.VirtualNetwork + direction: + type: string + description: Direction + required: false + status: SUPPORTED + org.openecomp.datatypes.heat.contrail.network.rule.RuleList: + derived_from: tosca.datatypes.Root + description: list of policy rules + properties: + policy_rule: + type: list + description: Contrail network rule + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.contrail.network.rule.Rule + org.openecomp.datatypes.heat.contrail.network.rule.VirtualNetwork: + derived_from: tosca.datatypes.Root + description: source and destination addresses + properties: + virtual_network: + type: string + description: Virtual network + required: false + status: SUPPORTED +node_types: + org.openecomp.resource.nodes.heat.network.contrail.NetworkRules: + derived_from: tosca.nodes.Root + properties: + entries: + type: org.openecomp.datatypes.heat.contrail.network.rule.RuleList + description: A symbolic name for this contrail network rule + required: false + status: SUPPORTED + name: + type: string + description: A symbolic name for this contrail network rule + required: false + status: SUPPORTED + attributes: + fq_name: + type: string + description: fq_name + status: SUPPORTED + requirements: + - network: + capability: tosca.capabilities.Attachment + node: tosca.nodes.network.Network + relationship: org.openecomp.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml new file mode 100644 index 0000000000..0927e3dd0e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml @@ -0,0 +1,71 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: ContrailVirtualNetworkGlobalType + template_version: 1.0.0 +description: Contrail Virtual Network Global Types +imports: + common_definitions: + file: CommonGlobalTypesServiceTemplate.yaml +node_types: + org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork: + derived_from: tosca.nodes.network.Network + properties: + shared: + type: string + description: Is virtual network shared + required: false + status: SUPPORTED + forwarding_mode: + type: string + description: forwarding mode of the virtual network + required: false + status: SUPPORTED + external: + type: string + description: Is virtual network external + required: false + status: SUPPORTED + flood_unknown_unicast: + type: string + description: flood L2 packets on network + required: false + status: SUPPORTED + route_targets: + type: list + description: route targets associated with the virtual network + required: false + status: SUPPORTED + entry_schema: + type: string + subnets: + type: map + description: Network related subnets + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.neutron.Subnet + attributes: + subnets_name: + type: list + description: Subnets name of this network + status: SUPPORTED + entry_schema: + type: string + subnets_show: + type: map + description: Detailed information about each subnet + status: SUPPORTED + entry_schema: + type: string + subnets: + type: map + description: Network related subnets + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.neutron.Subnet + capabilities: + attachment: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..08c47bc646 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,93 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.nested: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + cmaui_names: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + p1: + type: string + description: UID of OAM network + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + security_group_name: + description: not impotrtant + availability_zone_0: + type: string + description: availabilityzone name + requirements: + - local_storage_server_cmaui: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_cmaui_port_0: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + host_server_cmaui: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + os_server_cmaui: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + endpoint_server_cmaui: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + binding_server_cmaui: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + scalable_server_cmaui: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_0: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NativeTypesServiceTemplateServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NativeTypesServiceTemplateServiceTemplate.yaml new file mode 100644 index 0000000000..e7dfd49ed9 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NativeTypesServiceTemplateServiceTemplate.yaml @@ -0,0 +1,194 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: NativeTypesServiceTemplate + template_version: 1.0.0 +description: TOSCA Native Node Types +node_types: + tosca.nodes.Compute: + derived_from: tosca.nodes.Root + attributes: + private_address: + type: string + description: private address + status: SUPPORTED + public_address: + type: string + description: public_address + status: SUPPORTED + networks: + type: map + description: networks + status: SUPPORTED + entry_schema: + type: tosca.datatypes.network.NetworkInfo + ports: + type: map + description: ports + status: SUPPORTED + entry_schema: + type: tosca.datatypes.network.PortInfo + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + capabilities: + scalable: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + endpoint: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + os: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + host: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + binding: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + tosca.nodes.network.Port: + derived_from: tosca.nodes.Root + properties: + ip_range_end: + type: string + required: false + status: SUPPORTED + ip_range_start: + type: string + required: false + status: SUPPORTED + ip_address: + type: string + required: false + status: SUPPORTED + is_default: + type: boolean + required: false + default: false + status: SUPPORTED + order: + type: integer + required: true + default: 0 + status: SUPPORTED + constraints: + - greater_or_equal: 0 + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: tosca.nodes.Root + relationship: tosca.relationships.network.BindsTo + tosca.nodes.Root: + attributes: + tosca_name: + type: string + description: tosca name + status: SUPPORTED + state: + type: string + description: state + status: SUPPORTED + tosca_id: + type: string + description: tosca id + status: SUPPORTED + interfaces: { + } + tosca.nodes.network.Network: + derived_from: tosca.nodes.Root + properties: + physical_network: + type: string + required: false + status: SUPPORTED + segmentation_id: + type: string + required: false + status: SUPPORTED + network_id: + type: string + required: false + status: SUPPORTED + ip_version: + type: integer + required: false + default: 4 + status: SUPPORTED + constraints: + - valid_values: + - 4 + - 6 + start_ip: + type: string + required: false + status: SUPPORTED + network_name: + type: string + required: false + status: SUPPORTED + cidr: + type: string + required: false + status: SUPPORTED + gateway_ip: + type: string + required: false + status: SUPPORTED + network_type: + type: string + required: false + status: SUPPORTED + end_ip: + type: string + required: false + status: SUPPORTED + capabilities: + link: + type: tosca.capabilities.network.Linkable + occurrences: + - 1 + - UNBOUNDED + tosca.nodes.BlockStorage: + derived_from: tosca.nodes.Root + properties: + size: + type: scalar-unit.size + required: false + status: SUPPORTED + constraints: + - greater_or_equal: 1 MB + volume_id: + type: string + required: false + status: SUPPORTED + snapshot_id: + type: string + required: false + status: SUPPORTED + capabilities: + attachment: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NeutronNetGlobalTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NeutronNetGlobalTypesServiceTemplate.yaml new file mode 100644 index 0000000000..e80e2727c7 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NeutronNetGlobalTypesServiceTemplate.yaml @@ -0,0 +1,97 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: NeutronNetGlobalTypes + template_version: 1.0.0 +description: Neutron Network TOSCA Global Types +imports: + common_definitions: + file: CommonGlobalTypesServiceTemplate.yaml +node_types: + org.openecomp.resource.vl.nodes.heat.network.neutron.Net: + derived_from: tosca.nodes.network.Network + properties: + dhcp_agent_ids: + type: list + description: The IDs of the DHCP agent to schedule the network + required: false + status: SUPPORTED + entry_schema: + type: string + tenant_id: + type: string + description: The ID of the tenant which will own the network + required: false + status: SUPPORTED + port_security_enabled: + type: boolean + description: Flag to enable/disable port security on the network + required: false + status: SUPPORTED + shared: + type: boolean + description: Whether this network should be shared across all tenants + required: false + default: false + status: SUPPORTED + admin_state_up: + type: boolean + description: A boolean value specifying the administrative status of the network + required: false + default: true + status: SUPPORTED + qos_policy: + type: string + description: The name or ID of QoS policy to attach to this network + required: false + status: SUPPORTED + subnets: + type: map + description: Network related subnets + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.neutron.Subnet + value_specs: + type: map + description: Extra parameters to include in the request + required: false + default: { + } + status: SUPPORTED + entry_schema: + type: string + attributes: + qos_policy_id: + type: string + description: The QoS policy ID attached to this network + status: SUPPORTED + show: + type: string + description: Detailed information about resource + status: SUPPORTED + subnets_name: + type: list + description: Subnets name of this network + status: SUPPORTED + entry_schema: + type: string + subnets: + type: map + description: Network related subnets + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.neutron.Subnet + mtu: + type: scalar-unit.size + description: The maximum transmission unit size(in bytes) for the network + status: SUPPORTED + status: + type: string + description: The status of the network + status: SUPPORTED + capabilities: + attachment: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NeutronPortGlobalTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NeutronPortGlobalTypesServiceTemplate.yaml new file mode 100644 index 0000000000..a337d6ed18 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NeutronPortGlobalTypesServiceTemplate.yaml @@ -0,0 +1,151 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: NeutronPortGlobalTypes + template_version: 1.0.0 +description: Neutron Port TOSCA Global Types +imports: + common_definitions: + file: CommonGlobalTypesServiceTemplate.yaml +data_types: + org.openecomp.datatypes.heat.neutron.port.FixedIps: + derived_from: tosca.datatypes.Root + description: subnet/ip_address + properties: + subnet: + type: string + description: Subnet in which to allocate the IP address for this port + required: false + status: SUPPORTED + ip_address: + type: string + description: IP address desired in the subnet for this port + required: false + status: SUPPORTED +node_types: + org.openecomp.resource.cp.nodes.heat.network.neutron.Port: + derived_from: tosca.nodes.network.Port + properties: + port_security_enabled: + type: boolean + description: Flag to enable/disable port security on the network + required: false + status: SUPPORTED + device_id: + type: string + description: Device ID of this port + required: false + status: SUPPORTED + qos_policy: + type: string + description: The name or ID of QoS policy to attach to this network + required: false + status: SUPPORTED + allowed_address_pairs: + type: list + description: Additional MAC/IP address pairs allowed to pass through the port + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.AddressPair + binding:vnic_type: + type: string + description: The vnic type to be bound on the neutron port + required: false + status: SUPPORTED + constraints: + - valid_values: + - macvtap + - direct + - normal + value_specs: + type: map + description: Extra parameters to include in the request + required: false + default: { + } + status: SUPPORTED + entry_schema: + type: string + device_owner: + type: string + description: Name of the network owning the port + required: false + status: SUPPORTED + network: + type: string + description: Network this port belongs to + required: false + status: SUPPORTED + replacement_policy: + type: string + description: Policy on how to respond to a stack-update for this resource + required: false + default: AUTO + status: SUPPORTED + constraints: + - valid_values: + - REPLACE_ALWAYS + - AUTO + security_groups: + type: list + description: List of security group names or IDs + required: false + status: SUPPORTED + entry_schema: + type: string + fixed_ips: + type: list + description: Desired IPs for this port + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.neutron.port.FixedIps + mac_address: + type: string + description: MAC address to give to this port + required: false + status: SUPPORTED + admin_state_up: + type: boolean + description: A boolean value specifying the administrative status of the network + required: false + default: true + status: SUPPORTED + name: + type: string + description: A symbolic name for this port + required: false + status: SUPPORTED + attributes: + tenant_id: + type: string + description: Tenant owning the port + status: SUPPORTED + network_id: + type: string + description: Unique identifier for the network owning the port + status: SUPPORTED + qos_policy_id: + type: string + description: The QoS policy ID attached to this network + status: SUPPORTED + show: + type: string + description: Detailed information about resource + status: SUPPORTED + subnets: + type: list + description: Subnets of this network + status: SUPPORTED + entry_schema: + type: string + status: + type: string + description: The status of the network + status: SUPPORTED + capabilities: + attachment: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NeutronSecurityRulesGlobalTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NeutronSecurityRulesGlobalTypesServiceTemplate.yaml new file mode 100644 index 0000000000..49c9a102c8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NeutronSecurityRulesGlobalTypesServiceTemplate.yaml @@ -0,0 +1,116 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: NeutronSecurityRulesGlobalTypes + template_version: 1.0.0 +description: Neutron Security Rules TOSCA Global Types +imports: + common_definitions: + file: CommonGlobalTypesServiceTemplate.yaml +data_types: + org.openecomp.datatypes.heat.network.neutron.SecurityRules.Rule: + derived_from: tosca.datatypes.Root + description: Rules Pairs + properties: + remote_group_id: + type: string + description: The remote group ID to be associated with this security group rule + required: false + status: SUPPORTED + protocol: + type: string + description: The protocol that is matched by the security group rule + required: false + status: SUPPORTED + constraints: + - valid_values: + - tcp + - udp + - icmp + ethertype: + type: string + description: Ethertype of the traffic + required: false + default: IPv4 + status: SUPPORTED + constraints: + - valid_values: + - IPv4 + - IPv6 + port_range_max: + type: integer + description: 'The maximum port number in the range that is matched by the + security group rule. ' + required: false + status: SUPPORTED + constraints: + - in_range: + - 0 + - 65535 + remote_ip_prefix: + type: string + description: The remote IP prefix (CIDR) to be associated with this security group rule + required: false + status: SUPPORTED + remote_mode: + type: string + description: Whether to specify a remote group or a remote IP prefix + required: false + default: remote_ip_prefix + status: SUPPORTED + constraints: + - valid_values: + - remote_ip_prefix + - remote_group_id + direction: + type: string + description: The direction in which the security group rule is applied + required: false + default: ingress + status: SUPPORTED + constraints: + - valid_values: + - egress + - ingress + port_range_min: + type: integer + description: The minimum port number in the range that is matched by the security group rule. + required: false + status: SUPPORTED + constraints: + - in_range: + - 0 + - 65535 +node_types: + org.openecomp.resource.nodes.heat.network.neutron.SecurityRules: + derived_from: tosca.nodes.Root + properties: + description: + type: string + description: Description of the security group + required: false + status: SUPPORTED + name: + type: string + description: A symbolic name for this security group, which is not required to be unique. + required: false + status: SUPPORTED + rules: + type: list + description: List of security group rules + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.neutron.SecurityRules.Rule + attributes: + show: + type: string + description: Detailed information about resource + status: SUPPORTED + requirements: + - port: + capability: tosca.capabilities.Attachment + node: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + relationship: org.openecomp.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NovaServerGlobalTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NovaServerGlobalTypesServiceTemplate.yaml new file mode 100644 index 0000000000..2253a1e4af --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-core/src/test/resources/extractServiceComposition/toscaGlobalServiceTemplates/NovaServerGlobalTypesServiceTemplate.yaml @@ -0,0 +1,249 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: NovaServerGlobalTypes + template_version: 1.0.0 +description: Nova Server TOSCA Global Types +imports: + common_definitions: + file: CommonGlobalTypesServiceTemplate.yaml +data_types: + org.openecomp.datatypes.heat.novaServer.network.PortExtraProperties: + derived_from: tosca.datatypes.Root + description: Nova server network expand properties for port + properties: + port_security_enabled: + type: boolean + description: Flag to enable/disable port security on the port + required: false + status: SUPPORTED + mac_address: + type: string + description: MAC address to give to this port + required: false + status: SUPPORTED + admin_state_up: + type: boolean + description: The administrative state of this port + required: false + default: true + status: SUPPORTED + qos_policy: + type: string + description: The name or ID of QoS policy to attach to this port + required: false + status: SUPPORTED + allowed_address_pairs: + type: list + description: Additional MAC/IP address pairs allowed to pass through the port + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.AddressPair + binding:vnic_type: + type: string + description: The vnic type to be bound on the neutron port + required: false + status: SUPPORTED + constraints: + - valid_values: + - macvtap + - direct + - normal + value_specs: + type: map + description: Extra parameters to include in the request + required: false + default: { + } + status: SUPPORTED + entry_schema: + type: string + org.openecomp.datatypes.heat.novaServer.network.AddressInfo: + derived_from: tosca.datatypes.network.NetworkInfo + description: Network addresses with corresponding port id + properties: + port_id: + type: string + description: Port id + required: false + status: SUPPORTED +node_types: + org.openecomp.resource.vfc.nodes.heat.nova.Server: + derived_from: tosca.nodes.Compute + properties: + admin_pass: + type: string + description: The administrator password for the server + required: false + status: SUPPORTED + availability_zone: + type: string + description: Availability zone to create servers in + required: false + status: SUPPORTED + image: + type: string + description: The ID or name of the image to boot with + required: false + status: SUPPORTED + image_update_policy: + type: string + description: Policy on how to apply an image-id update + required: false + default: REBUILD + status: SUPPORTED + constraints: + - valid_values: + - REBUILD_PRESERVE_EPHEMERAL + - REPLACE + - REBUILD + metadata: + type: map + description: Arbitrary key/value metadata to store for this server + required: false + status: SUPPORTED + constraints: + - max_length: 255 + entry_schema: + type: string + constraints: + - max_length: 255 + user_data_update_policy: + type: string + description: Policy on how to apply a user_data update + required: false + default: REPLACE + status: SUPPORTED + constraints: + - valid_values: + - REPLACE + - IGNORE + flavor_update_policy: + type: string + description: Policy on how to apply a flavor update + required: false + default: RESIZE + status: SUPPORTED + constraints: + - valid_values: + - RESIZE + - REPLACE + user_data: + type: string + description: User data script to be executed by cloud-init + required: false + default: '' + status: SUPPORTED + flavor: + type: string + description: The ID or name of the flavor to boot onto + required: true + status: SUPPORTED + key_name: + type: string + description: Name of keypair to inject into the server + required: false + status: SUPPORTED + reservation_id: + type: string + description: A UUID for the set of servers being requested + required: false + status: SUPPORTED + security_groups: + type: list + description: List of security group names or IDs + required: false + default: [ + ] + status: SUPPORTED + entry_schema: + type: string + config_drive: + type: boolean + description: enable config drive on the server + required: false + status: SUPPORTED + personality: + type: map + description: A map of files to create/overwrite on the server upon boot + required: false + default: { + } + status: SUPPORTED + entry_schema: + type: string + software_config_transport: + type: string + description: How the server should receive the metadata required for software configuration + required: false + default: POLL_SERVER_CFN + status: SUPPORTED + constraints: + - valid_values: + - POLL_SERVER_CFN + - POLL_SERVER_HEAT + - POLL_TEMP_URL + - ZAQAR_MESSAGE + user_data_format: + type: string + description: How the user_data should be formatted for the server + required: false + default: HEAT_CFNTOOLS + status: SUPPORTED + constraints: + - valid_values: + - SOFTWARE_CONFIG + - RAW + - HEAT_CFNTOOLS + diskConfig: + type: string + description: Control how the disk is partitioned when the server is created + required: false + status: SUPPORTED + constraints: + - valid_values: + - AUTO + - MANUAL + name: + type: string + description: Server name + required: false + status: SUPPORTED + scheduler_hints: + type: map + description: Arbitrary key-value pairs specified by the client to help boot a server + required: false + status: SUPPORTED + entry_schema: + type: string + attributes: + accessIPv4: + type: string + description: The manually assigned alternative public IPv4 address of the server + status: SUPPORTED + addresses: + type: map + description: A dict of all network addresses with corresponding port_id + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.novaServer.network.AddressInfo + accessIPv6: + type: string + description: The manually assigned alternative public IPv6 address of the server + status: SUPPORTED + instance_name: + type: string + description: AWS compatible instance name + status: SUPPORTED + name: + type: string + description: Name of the server + status: SUPPORTED + show: + type: string + description: Detailed information about resource + status: SUPPORTED + console_urls: + type: string + description: URLs of servers consoles + status: SUPPORTED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/pom.xml b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/pom.xml new file mode 100644 index 0000000000..8f82967e74 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/pom.xml @@ -0,0 +1,102 @@ + + 4.0.0 + + + + + + org.openecomp.sdc + openecomp-sdc-lib + 1.0.0-SNAPSHOT + ../.. + + + openecomp-sdc-enrichment-impl + openecomp-sdc-enrichment-impl + + + + org.slf4j + slf4j-api + 1.7.10 + + + + ch.qos.logback + logback-classic + 1.1.2 + + + + + org.testng + testng + test + 6.8.5 + + + snakeyaml + org.yaml + + + + + junit + junit + RELEASE + test + + + org.openecomp.core + openecomp-utilities-lib + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-enrichment-api + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-model-core + ${project.version} + + + org.openecomp.core + openecomp-common-lib + ${project.version} + + + org.mockito + mockito-all + test + 1.10.19 + + + com.google.guava + guava + 19.0 + + + + org.openecomp.core + openecomp-heat-lib + ${project.version} + + + org.openecomp.core + openecomp-tosca-lib + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-translator-core + ${project.version} + + + + + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/EnrichmentInfo.java b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/EnrichmentInfo.java new file mode 100644 index 0000000000..17c4091a28 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/EnrichmentInfo.java @@ -0,0 +1,63 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.enrichment; + +import org.openecomp.core.enrichment.types.EntityInfo; +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +public class EnrichmentInfo { + Map> additionalInfo = new HashMap<>(); + Map entityInfo = new HashMap<>(); //componentName,EntityInfo + String key; + Version version; + + public Map> getAdditionalInfo() { + return additionalInfo; + } + + public Map getEntityInfo() { + return entityInfo; + } + + public void addEntityInfo(String type, EntityInfo entityInfo) { + this.entityInfo.put(type, entityInfo); + } + + public String getKey() { + return key; + } + + public void setKey(String key) { + this.key = key; + } + + public Version getVersion() { + return version; + } + + public void setVersion(Version version) { + this.version = version; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/factory/EnricherHandlerFactory.java b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/factory/EnricherHandlerFactory.java new file mode 100644 index 0000000000..47821f6670 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/factory/EnricherHandlerFactory.java @@ -0,0 +1,32 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.enrichment.factory; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; +import org.openecomp.sdc.enrichment.inter.EnricherHandler; + +public abstract class EnricherHandlerFactory extends AbstractComponentFactory { + + public static EnricherHandlerFactory getInstance() { + return AbstractFactory.getInstance(EnricherHandlerFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/EnricherHandlerFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/EnricherHandlerFactoryImpl.java new file mode 100644 index 0000000000..00f5c91661 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/EnricherHandlerFactoryImpl.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.enrichment.impl; + + +import org.openecomp.sdc.enrichment.factory.EnricherHandlerFactory; +import org.openecomp.sdc.enrichment.inter.EnricherHandler; + +public class EnricherHandlerFactoryImpl extends EnricherHandlerFactory { + + @Override + public EnricherHandler createInterface() { + return new EnricherHandlerImpl(); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/EnricherHandlerImpl.java b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/EnricherHandlerImpl.java new file mode 100644 index 0000000000..e2e5b47d2a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/EnricherHandlerImpl.java @@ -0,0 +1,89 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.enrichment.impl; + +import org.openecomp.core.enrichment.types.EntityInfo; +import org.openecomp.sdc.datatypes.error.ErrorMessage; +import org.openecomp.sdc.datatypes.model.AsdcModel; +import org.openecomp.sdc.enrichment.EnrichmentInfo; +import org.openecomp.sdc.enrichment.impl.external.artifact.ExternalArtifactEnricher; +import org.openecomp.sdc.enrichment.impl.tosca.ToscaEnricher; +import org.openecomp.sdc.enrichment.inter.Enricher; +import org.openecomp.sdc.enrichment.inter.EnricherHandler; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +/** + * The type Enricher handler. + */ +public class EnricherHandlerImpl implements EnricherHandler { + + private static Logger logger = LoggerFactory.getLogger(EnricherHandlerImpl.class); + private EnrichmentInfo input; + private AsdcModel model; + + @Override + public List getEnrichers() { + List enricherList = new ArrayList<>(); + enricherList.add(new ToscaEnricher()); + enricherList.add(new ExternalArtifactEnricher()); + return enricherList; + } + + @Override + public Map> enrich() { + Map> errors = new HashMap<>(); + Map> enricherResponse; + for (Enricher enricher : getEnrichers()) { + enricher.setInput(this.input); + enricher.setModel(this.model); + enricherResponse = enricher.enrich(); + errors.putAll(enricherResponse); + } + return errors; + } + + /** + * Adds additional input. + * + * @param key key + * @param input input + */ + public void addAdditionalInput(String key, Object input) { + if (!this.input.getAdditionalInfo().containsKey(key)) { + this.input.getAdditionalInfo().put(key, new ArrayList<>()); + } + this.input.getAdditionalInfo().get(key).add(input); + } + + public void addEntityInfo(String entityId, EntityInfo entityInfo) { + this.input.getEntityInfo().put(entityId, entityInfo); + } + + public void setModel(AsdcModel model) { + this.model = model; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/external/artifact/ExternalArtifactEnricher.java b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/external/artifact/ExternalArtifactEnricher.java new file mode 100644 index 0000000000..a276cfba7d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/external/artifact/ExternalArtifactEnricher.java @@ -0,0 +1,106 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.enrichment.impl.external.artifact; + +import org.openecomp.core.enrichment.types.ComponentArtifactType; +import org.openecomp.core.enrichment.types.MibInfo; +import org.openecomp.core.model.dao.EnrichedServiceModelDao; +import org.openecomp.core.model.dao.EnrichedServiceModelDaoFactory; +import org.openecomp.core.model.types.ServiceArtifact; +import org.openecomp.core.utilities.file.FileContentHandler; +import org.openecomp.core.utilities.file.FileUtils; +import org.openecomp.core.validation.errors.Messages; +import org.openecomp.sdc.datatypes.error.ErrorLevel; +import org.openecomp.sdc.datatypes.error.ErrorMessage; +import org.openecomp.sdc.enrichment.impl.tosca.ComponentInfo; +import org.openecomp.sdc.enrichment.inter.Enricher; +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.io.File; +import java.io.IOException; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.Set; + +public class ExternalArtifactEnricher extends Enricher { + + private static EnrichedServiceModelDao enrichedServiceModelDao = + EnrichedServiceModelDaoFactory.getInstance().createInterface(); + + + @Override + public Map> enrich() { + + Map> errors = new HashMap<>(); + input.getEntityInfo().entrySet().stream().forEach( + entry -> enrichComponentMib(entry.getKey(), (ComponentInfo) entry.getValue(), errors)); + + + return errors; + } + + + private void enrichComponentMib(String componentName, ComponentInfo componentInfo, + Map> errors) { + + String vspId = input.getKey(); + Version version = input.getVersion(); + ServiceArtifact mibServiceArtifact = new ServiceArtifact(); + mibServiceArtifact.setVspId(vspId); + mibServiceArtifact.setVersion(version); + enrichMibFiles(mibServiceArtifact, componentInfo, errors); + } + + private void enrichMibFiles(ServiceArtifact mibServiceArtifact, ComponentInfo componentInfo, + Map> errors) { + if (componentInfo.getMibInfo() == null) { + return; + } + enrichMibByType(componentInfo.getMibInfo().getSnmpTrap(), ComponentArtifactType.SNMP_TRAP, + mibServiceArtifact, errors); + enrichMibByType(componentInfo.getMibInfo().getSnmpPoll(), ComponentArtifactType.SNMP_POLL, + mibServiceArtifact, errors); + } + + private void enrichMibByType(MibInfo mibInfo, ComponentArtifactType type, + ServiceArtifact mibServiceArtifact, + Map> errors) { + if (mibInfo == null) { + return; + } + FileContentHandler mibs; + try { + mibs = FileUtils.getFileContentMapFromZip(FileUtils.toByteArray(mibInfo.getContent())); + } catch (IOException ioException) { + ErrorMessage.ErrorMessageUtil + .addMessage(mibServiceArtifact.getName() + "." + type.name(), errors) + .add(new ErrorMessage(ErrorLevel.ERROR, Messages.INVALID_ZIP_FILE.getErrorMessage())); + return; + } + Set fileList = mibs.getFileList(); + for (String fileName : fileList) { + mibServiceArtifact.setContentData(FileUtils.toByteArray(mibs.getFileContent(fileName))); + mibServiceArtifact.setName(mibInfo.getName() + File.separator + fileName); + enrichedServiceModelDao.storeExternalArtifact(mibServiceArtifact); + } + } +} diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/tosca/CeilometerEnricher.java b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/tosca/CeilometerEnricher.java new file mode 100644 index 0000000000..eb79787b59 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/tosca/CeilometerEnricher.java @@ -0,0 +1,112 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.enrichment.impl.tosca; + +import org.apache.commons.collections4.MapUtils; +import org.openecomp.core.enrichment.types.CeilometerInfo; +import org.openecomp.sdc.datatypes.error.ErrorMessage; +import org.openecomp.sdc.enrichment.EnrichmentInfo; +import org.openecomp.sdc.tosca.datatypes.ToscaCapabilityType; +import org.openecomp.sdc.tosca.datatypes.ToscaElementTypes; +import org.openecomp.sdc.tosca.datatypes.ToscaServiceModel; +import org.openecomp.sdc.tosca.datatypes.model.CapabilityDefinition; +import org.openecomp.sdc.tosca.datatypes.model.CapabilityType; +import org.openecomp.sdc.tosca.datatypes.model.NodeType; +import org.openecomp.sdc.tosca.services.ToscaAnalyzerService; +import org.openecomp.sdc.tosca.services.ToscaUtil; +import org.openecomp.sdc.tosca.services.impl.ToscaAnalyzerServiceImpl; +import org.openecomp.sdc.translator.services.heattotosca.globaltypes.CommonGlobalTypes; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +public class CeilometerEnricher { + /** + * Enrich map. + * + * @param toscaModel the tosca model + * @param modelNodeType the model node type + * @param input the input + * @return the map + */ + public static Map> enrich(ToscaServiceModel toscaModel, + Map> modelNodeType, + EnrichmentInfo input) { + Map> errors = new HashMap<>(); + input.getEntityInfo().entrySet().stream().forEach( + entry -> enrichNodeType(toscaModel, (ComponentInfo) entry.getValue(), + modelNodeType.get(entry.getKey()))); + + return errors; + } + + private static void enrichNodeType(ToscaServiceModel toscaModel, ComponentInfo componentInfo, + List nodeTypes) { + + for (CeilometerInfo ceilometerInfo : componentInfo.getCeilometerInfo() + .getCeilometerInfoList()) { + String capabilityId = ceilometerInfo.getName(); + + Map properties = getCeilometerProperties(ceilometerInfo); + + //CapabilityType capabilityType = CommonGlobalTypes.createServiceTemplate() + // .getCapability_types(). + // get(ToscaCapabilityType.METRIC_CEILOMETER.getDisplayName()); + //CapabilityType metricCapabilityType = CommonGlobalTypes.createServiceTemplate(). + // getCapability_types().get(ToscaCapabilityType.METRIC.getDisplayName()); + ToscaAnalyzerService toscaAnalyzerService = new ToscaAnalyzerServiceImpl(); + CapabilityType capabilityType = (CapabilityType) toscaAnalyzerService + .getFlatEntity(ToscaElementTypes.CAPABILITY_TYPE, + ToscaCapabilityType.METRIC_CEILOMETER.getDisplayName(), + CommonGlobalTypes.createServiceTemplate(), toscaModel); + + + nodeTypes.stream().forEach(nodeType -> + addCapability(nodeType, capabilityId, ToscaUtil + .convertTypeToDefinition(ToscaCapabilityType.METRIC_CEILOMETER.getDisplayName(), + capabilityType, properties, ceilometerInfo.getDescription()))); + } + } + + private static Map getCeilometerProperties(CeilometerInfo ceilometerInfo) { + Map properties = new HashMap<>(); + properties.put("name", ceilometerInfo.getName()); + properties.put("type", ceilometerInfo.getType()); + properties.put("unit", ceilometerInfo.getUnit()); + if (ceilometerInfo.getCategory() != null) { + properties.put("category", ceilometerInfo.getCategory()); + } + return properties; + } + + private static void addCapability(NodeType nodeType, String capabilityId, + CapabilityDefinition capabilityDefinition) { + if (MapUtils.isEmpty(nodeType.getCapabilities())) { + nodeType.setCapabilities(new HashMap<>()); + } + //clean unnecessary info + capabilityDefinition.setAttributes(null); + capabilityDefinition.setOccurrences(null); + + nodeType.getCapabilities().put(capabilityId, capabilityDefinition); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/tosca/ComponentInfo.java b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/tosca/ComponentInfo.java new file mode 100644 index 0000000000..0a1f3d36ff --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/tosca/ComponentInfo.java @@ -0,0 +1,47 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.enrichment.impl.tosca; + +import org.openecomp.core.enrichment.types.ComponentCeilometerInfo; +import org.openecomp.core.enrichment.types.ComponentMibInfo; +import org.openecomp.core.enrichment.types.EntityInfo; + +public class ComponentInfo implements EntityInfo { + + private ComponentCeilometerInfo ceilometerInfo; + private ComponentMibInfo mibInfo; + + public ComponentCeilometerInfo getCeilometerInfo() { + return ceilometerInfo; + } + + public void setCeilometerInfo(ComponentCeilometerInfo ceilometerInfo) { + this.ceilometerInfo = ceilometerInfo; + } + + public ComponentMibInfo getMibInfo() { + return mibInfo; + } + + public void setMibInfo(ComponentMibInfo mibInfo) { + this.mibInfo = mibInfo; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/tosca/SnmpEnricher.java b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/tosca/SnmpEnricher.java new file mode 100644 index 0000000000..42cbcdd50b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/tosca/SnmpEnricher.java @@ -0,0 +1,38 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.enrichment.impl.tosca; + +import org.openecomp.sdc.datatypes.error.ErrorMessage; + +import org.openecomp.sdc.enrichment.EnrichmentInfo; +import org.openecomp.sdc.tosca.datatypes.model.NodeType; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +public class SnmpEnricher { + public static Map> enrich(Map> modelNodeType, + EnrichmentInfo input) { + return new HashMap<>(); + + } +} diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/tosca/ToscaEnricher.java b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/tosca/ToscaEnricher.java new file mode 100644 index 0000000000..2c0f03480f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/tosca/ToscaEnricher.java @@ -0,0 +1,73 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.enrichment.impl.tosca; + +import org.openecomp.sdc.datatypes.error.ErrorMessage; +import org.openecomp.sdc.enrichment.inter.Enricher; +import org.openecomp.sdc.tosca.datatypes.ToscaServiceModel; +import org.openecomp.sdc.tosca.datatypes.model.NodeType; +import org.openecomp.sdc.tosca.services.ToscaUtil; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +public class ToscaEnricher extends Enricher { + + Map> componentTypNodeTypeMap; + + @Override + public Map> enrich() { + Map> errors = new HashMap<>(); + Map> enrichResponse; + enrichResponse = enrichCilometer(); + errors.putAll(enrichResponse); + enrichResponse = enrichSnmp(); + errors.putAll(enrichResponse); + + + return errors; + } + + private Map> enrichCilometer() { + Map> enrichResponse; + + ToscaServiceModel toscaModel = (ToscaServiceModel) model; + + componentTypNodeTypeMap = + ToscaUtil.normalizeComponentNameNodeType(toscaModel, input.getEntityInfo().keySet()); + + enrichResponse = CeilometerEnricher.enrich(toscaModel, componentTypNodeTypeMap, this.input); + + return enrichResponse; + } + + + private Map> enrichSnmp() { + Map> enrichResponse; + + enrichResponse = SnmpEnricher.enrich(componentTypNodeTypeMap, this.input); + + return enrichResponse; + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/inter/Enricher.java b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/inter/Enricher.java new file mode 100644 index 0000000000..1d6867d1f3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/inter/Enricher.java @@ -0,0 +1,45 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.enrichment.inter; + +import org.openecomp.sdc.datatypes.error.ErrorMessage; +import org.openecomp.sdc.datatypes.model.AsdcModel; +import org.openecomp.sdc.enrichment.EnrichmentInfo; + +import java.util.List; +import java.util.Map; + +public abstract class Enricher { + + + protected EnrichmentInfo input; + protected AsdcModel model; + + public void setInput(EnrichmentInfo input) { + this.input = input; + } + + public void setModel(AsdcModel model) { + this.model = model; + } + + public abstract Map> enrich(); +} diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/inter/EnricherHandler.java b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/inter/EnricherHandler.java new file mode 100644 index 0000000000..717bbc8313 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/inter/EnricherHandler.java @@ -0,0 +1,41 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.enrichment.inter; + +import org.openecomp.sdc.datatypes.error.ErrorMessage; +import org.openecomp.sdc.datatypes.model.AsdcModel; + +import java.util.List; +import java.util.Map; + +public interface EnricherHandler { + + + List getEnrichers(); + + Map> enrich(); + + void addAdditionalInput(String key, Object input); + + void setModel(AsdcModel model); + + +} diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/resources/factoryConfiguration.json b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/resources/factoryConfiguration.json new file mode 100644 index 0000000000..56510be13c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/resources/factoryConfiguration.json @@ -0,0 +1,3 @@ +{ + "org.openecomp.sdc.enrichment.factory.EnricherHandlerFactory": "org.openecomp.sdc.enrichment.impl.EnricherHandlerFactoryImpl" +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/pom.xml b/openecomp-be/lib/openecomp-sdc-enrichment-lib/pom.xml new file mode 100644 index 0000000000..314dac2447 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/pom.xml @@ -0,0 +1,41 @@ + + 4.0.0 + + + + + openecomp-sdc-lib + org.openecomp.sdc + 1.0.0-SNAPSHOT + + + openecomp-sdc-enrichment-lib + openecomp-sdc-enrichment-lib + pom + + + + openecomp-sdc-enrichment-api + openecomp-sdc-enrichment-core + openecomp-sdc-enrichment-impl + + + + + org.openecomp.sdc + openecomp-sdc-enrichment-api + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-enrichment-core + ${project.version} + + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/pom.xml b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/pom.xml new file mode 100644 index 0000000000..81016a413b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/pom.xml @@ -0,0 +1,49 @@ + + 4.0.0 + + + org.openecomp.sdc + openecomp-sdc-lib + 1.0.0-SNAPSHOT + ../.. + + + openecomp-sdc-model-api + openecomp-sdc-model-api + + + + org.openecomp.core + openecomp-facade-core + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-validation-api + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-versioning-core + ${project.version} + + + io.swagger + swagger-annotations + 1.5.3 + + + org.openecomp.core + openecomp-heat-lib + ${project.version} + + + org.openecomp.core + openecomp-tosca-lib + ${project.version} + + + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/EnrichedServiceArtifactDao.java b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/EnrichedServiceArtifactDao.java new file mode 100644 index 0000000000..e25845d319 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/EnrichedServiceArtifactDao.java @@ -0,0 +1,28 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.model.dao; + +import org.openecomp.core.model.types.ServiceArtifact; +import org.openecomp.sdc.versioning.dao.types.Version; + +public interface EnrichedServiceArtifactDao extends ServiceArtifactDaoInter { + ServiceArtifact getArtifactInfo(String vspId, Version version, String name); +} diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/EnrichedServiceArtifactDaoFactory.java b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/EnrichedServiceArtifactDaoFactory.java new file mode 100644 index 0000000000..3852e983e5 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/EnrichedServiceArtifactDaoFactory.java @@ -0,0 +1,32 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.model.dao; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; + +public abstract class EnrichedServiceArtifactDaoFactory + extends AbstractComponentFactory { + + public static EnrichedServiceArtifactDaoFactory getInstance() { + return AbstractFactory.getInstance(EnrichedServiceArtifactDaoFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/EnrichedServiceModelDao.java b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/EnrichedServiceModelDao.java new file mode 100644 index 0000000000..d547316ebf --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/EnrichedServiceModelDao.java @@ -0,0 +1,42 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.model.dao; + +import org.openecomp.core.model.types.ServiceArtifact; +import org.openecomp.sdc.versioning.dao.VersionableDao; +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.util.List; + +public interface EnrichedServiceModelDao extends VersionableDao { + + M getServiceModel(String vspId, Version version); + + void storeServiceModel(String vspId, Version version, M serviceModel); + + void storeExternalArtifact(ServiceArtifact serviceArtifact); + + List getExternalArtifacts(String vspId, Version version); + + E getServiceModelInfo(String vspId, Version version, String name); + + List getServiceModelContentNames(); +} diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/EnrichedServiceModelDaoFactory.java b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/EnrichedServiceModelDaoFactory.java new file mode 100644 index 0000000000..9d18d6c9cf --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/EnrichedServiceModelDaoFactory.java @@ -0,0 +1,32 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.model.dao; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; + +public abstract class EnrichedServiceModelDaoFactory + extends AbstractComponentFactory { + + public static EnrichedServiceModelDaoFactory getInstance() { + return AbstractFactory.getInstance(EnrichedServiceModelDaoFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/EnrichedServiceTemplateDao.java b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/EnrichedServiceTemplateDao.java new file mode 100644 index 0000000000..5ea2de7fd9 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/EnrichedServiceTemplateDao.java @@ -0,0 +1,26 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.model.dao; + + +public interface EnrichedServiceTemplateDao extends ServiceTemplateDaoInter { + +} diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/EnrichedServiceTemplateDaoFactory.java b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/EnrichedServiceTemplateDaoFactory.java new file mode 100644 index 0000000000..cab3ca6247 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/EnrichedServiceTemplateDaoFactory.java @@ -0,0 +1,32 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.model.dao; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; + +public abstract class EnrichedServiceTemplateDaoFactory + extends AbstractComponentFactory { + + public static EnrichedServiceTemplateDaoFactory getInstance() { + return AbstractFactory.getInstance(EnrichedServiceTemplateDaoFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/ServiceArtifactDao.java b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/ServiceArtifactDao.java new file mode 100644 index 0000000000..48f59d06ae --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/ServiceArtifactDao.java @@ -0,0 +1,44 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.model.dao; + +import org.openecomp.core.model.types.ServiceArtifact; +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.util.Collection; + +public interface ServiceArtifactDao extends ServiceArtifactDaoInter { + + Collection list(String vspId, Version version); + + void create(ServiceArtifact entity); + + void update(ServiceArtifact entity); + + ServiceArtifact get(String vspId, Version version); + + void delete(String vspId, Version version); + + Object[] getKeys(String vspId, Version version); + + ServiceArtifact getArtifactInfo(String vspId, Version version, String name); + +} diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/ServiceArtifactDaoFactory.java b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/ServiceArtifactDaoFactory.java new file mode 100644 index 0000000000..07c2191a7c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/ServiceArtifactDaoFactory.java @@ -0,0 +1,32 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.model.dao; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; + +public abstract class ServiceArtifactDaoFactory + extends AbstractComponentFactory { + + public static ServiceArtifactDaoFactory getInstance() { + return AbstractFactory.getInstance(ServiceArtifactDaoFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/ServiceArtifactDaoInter.java b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/ServiceArtifactDaoInter.java new file mode 100644 index 0000000000..20d0c56c1b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/ServiceArtifactDaoInter.java @@ -0,0 +1,44 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.model.dao; + +import org.openecomp.core.model.types.ServiceArtifact; +import org.openecomp.sdc.versioning.dao.VersionableDao; +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.util.Collection; + +public interface ServiceArtifactDaoInter extends VersionableDao { + + Collection list(String vspId, Version version); + + void create(ServiceArtifact entity); + + void update(ServiceArtifact entity); + + ServiceArtifact get(String vspId, Version version); + + void delete(String vspId, Version version); + + Object[] getKeys(String vspId, Version version); + + ServiceArtifact getArtifactInfo(String vspId, Version version, String name); +} diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/ServiceModelDao.java b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/ServiceModelDao.java new file mode 100644 index 0000000000..30bb79c100 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/ServiceModelDao.java @@ -0,0 +1,40 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.model.dao; + +import org.openecomp.core.model.types.ServiceArtifact; +import org.openecomp.sdc.versioning.dao.VersionableDao; +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.util.List; + +public interface ServiceModelDao extends VersionableDao { + + M getServiceModel(String vspId, Version version); + + void storeServiceModel(String vspId, Version version, M serviceModel); + + E getServiceModelInfo(String vspId, Version version, String name); + + void storeExternalArtifact(ServiceArtifact serviceArtifact); + + List getServiceModelContentNames(); +} diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/ServiceModelDaoFactory.java b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/ServiceModelDaoFactory.java new file mode 100644 index 0000000000..19f6cb5c8c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/ServiceModelDaoFactory.java @@ -0,0 +1,31 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.model.dao; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; + +public abstract class ServiceModelDaoFactory extends AbstractComponentFactory { + + public static ServiceModelDaoFactory getInstance() { + return AbstractFactory.getInstance(ServiceModelDaoFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/ServiceTemplateDao.java b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/ServiceTemplateDao.java new file mode 100644 index 0000000000..c0c919b8a0 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/ServiceTemplateDao.java @@ -0,0 +1,44 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.model.dao; + +import org.openecomp.core.model.types.ServiceTemplate; +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.util.Collection; + +public interface ServiceTemplateDao extends ServiceTemplateDaoInter { + void create(ServiceTemplate entity); + + void update(ServiceTemplate entity); + + ServiceTemplate get(String vspId, Version version); + + void delete(String vspId, Version version); + + Object[] getKeys(String vspId, Version version); + + ServiceTemplate getTemplateInfo(String vspId, Version version, String name); + + Collection list(String vspId, Version version); + + String getBase(String vspId, Version version); +} diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/ServiceTemplateDaoFactory.java b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/ServiceTemplateDaoFactory.java new file mode 100644 index 0000000000..65aad1bb97 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/ServiceTemplateDaoFactory.java @@ -0,0 +1,32 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.model.dao; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; + +public abstract class ServiceTemplateDaoFactory + extends AbstractComponentFactory { + + public static ServiceTemplateDaoFactory getInstance() { + return AbstractFactory.getInstance(ServiceTemplateDaoFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/ServiceTemplateDaoInter.java b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/ServiceTemplateDaoInter.java new file mode 100644 index 0000000000..c4c4cb19b7 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/dao/ServiceTemplateDaoInter.java @@ -0,0 +1,46 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.model.dao; + +import org.openecomp.core.model.types.ServiceTemplate; +import org.openecomp.sdc.versioning.dao.VersionableDao; +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.util.Collection; + +public interface ServiceTemplateDaoInter extends VersionableDao { + void create(ServiceTemplate entity); + + void update(ServiceTemplate entity); + + ServiceTemplate get(String vspId, Version version); + + void delete(String vspId, Version version); + + Object[] getKeys(String vspId, Version version); + + ServiceTemplate getTemplateInfo(String vspId, Version version, String name); + + Collection list(String vspId, Version version); + + String getBase(String vspId, Version version); + +} diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/types/EnrichedServiceArtifactEntity.java b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/types/EnrichedServiceArtifactEntity.java new file mode 100644 index 0000000000..87e25613fc --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/types/EnrichedServiceArtifactEntity.java @@ -0,0 +1,136 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.model.types; + +import com.google.common.io.ByteStreams; + +import com.datastax.driver.mapping.annotations.ClusteringColumn; +import com.datastax.driver.mapping.annotations.Column; +import com.datastax.driver.mapping.annotations.Frozen; +import com.datastax.driver.mapping.annotations.PartitionKey; +import com.datastax.driver.mapping.annotations.Table; +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.io.IOException; +import java.nio.ByteBuffer; + +@Table(keyspace = "dox", name = "vsp_enriched_service_artifact") +public class EnrichedServiceArtifactEntity implements ServiceElementEntity { + private static final String ENTITY_TYPE; + + static { + ENTITY_TYPE = "Vendor Software Product Service artifact"; + } + + @PartitionKey + @Column(name = "vsp_id") + public String id; + + @PartitionKey(value = 1) + @Frozen + public Version version; + + @ClusteringColumn + @Column(name = "name") + public String name; + + @Column(name = "content_data") + public ByteBuffer contentData; + + public EnrichedServiceArtifactEntity() { + } + + /** + * Instantiates a new Enriched service artifact entity. + * + * @param entity the entity + */ + public EnrichedServiceArtifactEntity(ServiceArtifact entity) { + this.id = entity.getVspId(); + this.version = entity.getVersion(); + this.name = entity.getName(); + + try { + this.contentData = ByteBuffer.wrap(ByteStreams.toByteArray(entity.getContent())); + } catch (IOException ioException) { + throw new RuntimeException(ioException); + } + + } + + @Override + public String getEntityType() { + return ENTITY_TYPE; + } + + @Override + public String getFirstClassCitizenId() { + return getId(); + } + + public String getId() { + return id; + } + + public void setId(String id) { + this.id = id; + } + + @Override + public Version getVersion() { + return version; + } + + @Override + public void setVersion(Version version) { + this.version = version; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public ByteBuffer getContentData() { + return contentData; + } + + public void setContentData(ByteBuffer contentData) { + this.contentData = contentData; + } + + /** + * Gets service artifact. + * + * @return the service artifact + */ + public ServiceArtifact getServiceArtifact() { + ServiceArtifact serviceArtifact = new ServiceArtifact(); + serviceArtifact.setName(this.getName()); + serviceArtifact.setVersion(this.getVersion()); + serviceArtifact.setContentData(this.getContentData().array()); + serviceArtifact.setVspId(this.getId()); + return serviceArtifact; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/types/EnrichedServiceTemplateEntity.java b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/types/EnrichedServiceTemplateEntity.java new file mode 100644 index 0000000000..526a901e47 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/types/EnrichedServiceTemplateEntity.java @@ -0,0 +1,154 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.model.types; + +import com.google.common.io.ByteStreams; + +import com.datastax.driver.mapping.annotations.ClusteringColumn; +import com.datastax.driver.mapping.annotations.Column; +import com.datastax.driver.mapping.annotations.Frozen; +import com.datastax.driver.mapping.annotations.PartitionKey; +import com.datastax.driver.mapping.annotations.Table; +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.io.IOException; +import java.nio.ByteBuffer; + +@Table(keyspace = "dox", name = "vsp_enriched_service_template") +public class EnrichedServiceTemplateEntity implements ServiceElementEntity { + + private static final String ENTITY_TYPE; + + static { + ENTITY_TYPE = "Vendor Software Product Service model"; + } + + @PartitionKey + @Column(name = "vsp_id") + public String id; + + @PartitionKey(value = 1) + @Frozen + public Version version; + + @ClusteringColumn + @Column(name = "name") + public String name; + + @Column(name = "content_data") + public ByteBuffer contentData; + + + @Column(name = "base_name") + private String baseName; + + public EnrichedServiceTemplateEntity() { + } + + /** + * Instantiates a new Enriched service template entity. + * + * @param entity the entity + */ + public EnrichedServiceTemplateEntity(ServiceTemplate entity) { + this.id = entity.getVspId(); + this.version = entity.getVersion(); + this.name = entity.getName(); + this.setBaseName(entity.getBaseName()); + try { + this.contentData = ByteBuffer.wrap(ByteStreams.toByteArray(entity.getContent())); + } catch (IOException ioException) { + throw new RuntimeException(ioException); + } + + } + + + public String getBaseName() { + return baseName; + } + + public void setBaseName(String baseName) { + this.baseName = baseName; + } + + + @Override + public String getEntityType() { + return ENTITY_TYPE; + } + + @Override + public String getFirstClassCitizenId() { + return getId(); + } + + public String getId() { + return id; + } + + public void setId(String id) { + this.id = id; + } + + @Override + public Version getVersion() { + return version; + } + + @Override + public void setVersion(Version version) { + this.version = version; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public ByteBuffer getContentData() { + return contentData; + } + + public void setContentData(ByteBuffer contentData) { + this.contentData = contentData; + } + + + /** + * Gets service template. + * + * @return the service template + */ + public ServiceTemplate getServiceTemplate() { + ServiceTemplate serviceTemplate = new ServiceTemplate(); + serviceTemplate.setName(this.getName()); + serviceTemplate.setVersion(this.getVersion()); + serviceTemplate.setContentData(this.getContentData().array()); + serviceTemplate.setVspId(this.getId()); + serviceTemplate.setBaseName(this.getBaseName()); + return serviceTemplate; + + } +} diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/types/ServiceArtifact.java b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/types/ServiceArtifact.java new file mode 100644 index 0000000000..fad3e604d6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/types/ServiceArtifact.java @@ -0,0 +1,29 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.model.types; + +public class ServiceArtifact extends ServiceElement { + + + public ServiceArtifact() { + super(); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/types/ServiceArtifactEntity.java b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/types/ServiceArtifactEntity.java new file mode 100644 index 0000000000..c5dfeced8a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/types/ServiceArtifactEntity.java @@ -0,0 +1,136 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.model.types; + +import com.google.common.io.ByteStreams; + +import com.datastax.driver.mapping.annotations.ClusteringColumn; +import com.datastax.driver.mapping.annotations.Column; +import com.datastax.driver.mapping.annotations.Frozen; +import com.datastax.driver.mapping.annotations.PartitionKey; +import com.datastax.driver.mapping.annotations.Table; +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.io.IOException; +import java.nio.ByteBuffer; + +@Table(keyspace = "dox", name = "vsp_service_artifact") +public class ServiceArtifactEntity implements ServiceElementEntity { + private static final String ENTITY_TYPE; + + static { + ENTITY_TYPE = "Vendor Software Product Service artifact"; + } + + @PartitionKey + @Column(name = "vsp_id") + public String id; + + @PartitionKey(value = 1) + @Frozen + public Version version; + + @ClusteringColumn + @Column(name = "name") + public String name; + + @Column(name = "content_data") + public ByteBuffer contentData; + + public ServiceArtifactEntity() { + } + + /** + * Instantiates a new Service artifact entity. + * + * @param entity the entity + */ + public ServiceArtifactEntity(ServiceArtifact entity) { + this.id = entity.getVspId(); + this.version = entity.getVersion(); + this.name = entity.getName(); + + try { + this.contentData = ByteBuffer.wrap(ByteStreams.toByteArray(entity.getContent())); + } catch (IOException ioException) { + throw new RuntimeException(ioException); + } + + } + + @Override + public String getEntityType() { + return ENTITY_TYPE; + } + + @Override + public String getFirstClassCitizenId() { + return getId(); + } + + public String getId() { + return id; + } + + public void setId(String id) { + this.id = id; + } + + @Override + public Version getVersion() { + return version; + } + + @Override + public void setVersion(Version version) { + this.version = version; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public ByteBuffer getContentData() { + return contentData; + } + + public void setContentData(ByteBuffer contentData) { + this.contentData = contentData; + } + + /** + * Gets service artifact. + * + * @return the service artifact + */ + public ServiceArtifact getServiceArtifact() { + ServiceArtifact serviceArtifact = new ServiceArtifact(); + serviceArtifact.setName(this.getName()); + serviceArtifact.setVersion(this.getVersion()); + serviceArtifact.setContentData(this.getContentData().array()); + serviceArtifact.setVspId(this.getId()); + return serviceArtifact; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/types/ServiceElement.java b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/types/ServiceElement.java new file mode 100644 index 0000000000..114cf03a39 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/types/ServiceElement.java @@ -0,0 +1,77 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.model.types; + +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.io.ByteArrayInputStream; +import java.io.InputStream; + +public class ServiceElement { + + private String vspId; + private Version version; + private String name; + private byte[] contentData; + + public ServiceElement() { + } + + public String getVspId() { + return vspId; + } + + public void setVspId(String vspId) { + this.vspId = vspId; + } + + public Version getVersion() { + return version; + } + + public void setVersion(Version version) { + this.version = version; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + /** + * Gets content. + * + * @return the content + */ + public InputStream getContent() { + if (this.contentData == null) { + return null; + } + return new ByteArrayInputStream(contentData); + } + + public void setContentData(byte[] contentData) { + this.contentData = contentData; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/types/ServiceElementEntity.java b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/types/ServiceElementEntity.java new file mode 100644 index 0000000000..02249039f8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/types/ServiceElementEntity.java @@ -0,0 +1,31 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.model.types; + +import org.openecomp.sdc.versioning.dao.types.VersionableEntity; + +import java.nio.ByteBuffer; + +public interface ServiceElementEntity extends VersionableEntity { + String getName(); + + ByteBuffer getContentData(); +} diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/types/ServiceTemplate.java b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/types/ServiceTemplate.java new file mode 100644 index 0000000000..aa0285d6a9 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/types/ServiceTemplate.java @@ -0,0 +1,38 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.model.types; + +public class ServiceTemplate extends ServiceElement { + private String baseName; + + public ServiceTemplate() { + } + + + public String getBaseName() { + return baseName; + } + + + public void setBaseName(String baseName) { + this.baseName = baseName; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/types/ServiceTemplateEntity.java b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/types/ServiceTemplateEntity.java new file mode 100644 index 0000000000..f29334678f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/java/org/openecomp/core/model/types/ServiceTemplateEntity.java @@ -0,0 +1,154 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.model.types; + +import com.google.common.io.ByteStreams; + +import com.datastax.driver.mapping.annotations.ClusteringColumn; +import com.datastax.driver.mapping.annotations.Column; +import com.datastax.driver.mapping.annotations.Frozen; +import com.datastax.driver.mapping.annotations.PartitionKey; +import com.datastax.driver.mapping.annotations.Table; +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.io.IOException; +import java.nio.ByteBuffer; + +@Table(keyspace = "dox", name = "vsp_service_template") +public class ServiceTemplateEntity implements ServiceElementEntity { + + private static final String ENTITY_TYPE; + + static { + ENTITY_TYPE = "Vendor Software Product Service model"; + } + + @PartitionKey + @Column(name = "vsp_id") + public String id; + + @PartitionKey(value = 1) + @Frozen + public Version version; + + @ClusteringColumn + @Column(name = "name") + public String name; + + @Column(name = "content_data") + public ByteBuffer contentData; + + + @Column(name = "base_name") + private String baseName; + + public ServiceTemplateEntity() { + } + + /** + * Instantiates a new Service template entity. + * + * @param entity the entity + */ + public ServiceTemplateEntity(ServiceTemplate entity) { + this.id = entity.getVspId(); + this.version = entity.getVersion(); + this.name = entity.getName(); + this.setBaseName(entity.getBaseName()); + try { + this.contentData = ByteBuffer.wrap(ByteStreams.toByteArray(entity.getContent())); + } catch (IOException ioException) { + throw new RuntimeException(ioException); + } + + } + + + public String getBaseName() { + return baseName; + } + + public void setBaseName(String baseName) { + this.baseName = baseName; + } + + + @Override + public String getEntityType() { + return ENTITY_TYPE; + } + + @Override + public String getFirstClassCitizenId() { + return getId(); + } + + public String getId() { + return id; + } + + public void setId(String id) { + this.id = id; + } + + @Override + public Version getVersion() { + return version; + } + + @Override + public void setVersion(Version version) { + this.version = version; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public ByteBuffer getContentData() { + return contentData; + } + + public void setContentData(ByteBuffer contentData) { + this.contentData = contentData; + } + + + /** + * Gets service template. + * + * @return the service template + */ + public ServiceTemplate getServiceTemplate() { + ServiceTemplate serviceTemplate = new ServiceTemplate(); + serviceTemplate.setName(this.getName()); + serviceTemplate.setVersion(this.getVersion()); + serviceTemplate.setContentData(this.getContentData().array()); + serviceTemplate.setVspId(this.getId()); + serviceTemplate.setBaseName(this.getBaseName()); + return serviceTemplate; + + } +} diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/resources/factoryConfiguration.json b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/resources/factoryConfiguration.json new file mode 100644 index 0000000000..c228b29c57 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-api/src/main/resources/factoryConfiguration.json @@ -0,0 +1,8 @@ +{ + "org.openecomp.core.model.dao.ServiceModelDaoFactory":"org.openecomp.sdc.model.impl.ServiceModelDaoFactoryImpl", + "org.openecomp.core.model.dao.ServiceTemplateDaoFactory":"org.openecomp.sdc.model.impl.ServiceTemplateDaoCassandraFactoryImpl", + "org.openecomp.core.model.dao.ServiceArtifactDaoFactory":"org.openecomp.sdc.model.impl.ServiceArtifactDaoCassandraFactoryImpl", + "org.openecomp.core.model.dao.EnrichedServiceModelDaoFactory":"org.openecomp.sdc.model.impl.EnrichedServiceModelDaoFactoryImpl", + "org.openecomp.core.model.dao.EnrichedServiceTemplateDaoFactory":"org.openecomp.sdc.model.impl.EnrichedServiceTemplateDaoCassandraFactoryImpl", + "org.openecomp.core.model.dao.EnrichedServiceArtifactDaoFactory":"org.openecomp.sdc.model.impl.EnrichedServiceArtifactDaoCassandraFactoryImpl" +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-core/pom.xml b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-core/pom.xml new file mode 100644 index 0000000000..ba4d404ae7 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-core/pom.xml @@ -0,0 +1,65 @@ + + 4.0.0 + + + org.openecomp.sdc + openecomp-sdc-lib + 1.0.0-SNAPSHOT + ../.. + + + openecomp-sdc-model-core + openecomp-sdc-model-core + + + + org.slf4j + slf4j-api + 1.7.10 + + + + ch.qos.logback + logback-classic + 1.1.2 + + + + + + org.openecomp.core + openecomp-utilities-lib + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-model-api + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-versioning-core + ${project.version} + + + + org.openecomp.sdc + openecomp-sdc-datatypes-lib + ${project.version} + + + org.mockito + mockito-all + test + 1.10.19 + + + com.google.guava + guava + 19.0 + + + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-core/src/main/java/org/openecomp/sdc/model/impl/AbstractServiceModelDao.java b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-core/src/main/java/org/openecomp/sdc/model/impl/AbstractServiceModelDao.java new file mode 100644 index 0000000000..eb993f6fb1 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-core/src/main/java/org/openecomp/sdc/model/impl/AbstractServiceModelDao.java @@ -0,0 +1,191 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.model.impl; + +import org.openecomp.core.model.dao.ServiceArtifactDaoInter; +import org.openecomp.core.model.dao.ServiceTemplateDaoInter; +import org.openecomp.core.model.types.ServiceArtifact; +import org.openecomp.core.model.types.ServiceElement; +import org.openecomp.core.model.types.ServiceTemplate; +import org.openecomp.core.utilities.file.FileContentHandler; +import org.openecomp.core.utilities.file.FileUtils; +import org.openecomp.sdc.tosca.datatypes.ToscaServiceModel; +import org.openecomp.sdc.tosca.services.yamlutil.ToscaExtensionYamlUtil; +import org.openecomp.sdc.versioning.dao.VersionableDao; +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.io.InputStream; +import java.util.Collection; +import java.util.List; +import java.util.Map; +import java.util.stream.Collectors; + +public class AbstractServiceModelDao implements VersionableDao { + + protected ServiceTemplateDaoInter templateDao; + protected ServiceArtifactDaoInter artifactDao; + + @Override + public void registerVersioning(String versionableEntityType) { + templateDao.registerVersioning(versionableEntityType); + artifactDao.registerVersioning(versionableEntityType); + } + + + /** + * Gets service model. + * + * @param vspId the vsp id + * @param version the version + * @return the service model + */ + public ToscaServiceModel getServiceModel(String vspId, Version version) { + if (vspId == null || version == null) { + //throw new CoreException() + throw new RuntimeException("missing service model key"); + } + + + FileContentHandler artifactFiles = getArtifacts(vspId, version); + Map serviceTemplates = + getTemplates(vspId, version); + String entryDefinitionServiceTemplate = getServiceBase(vspId, version); + return new ToscaServiceModel(artifactFiles, serviceTemplates, entryDefinitionServiceTemplate); + } + + + public void storeExternalArtifact(ServiceArtifact serviceArtifact) { + artifactDao.create(serviceArtifact); + //TODO: update last modification time + } + + + /** + * Store service model. + * + * @param vspId the vsp id + * @param version the version + * @param toscaServiceModel the tosca service model + */ + public void storeServiceModel(String vspId, Version version, + ToscaServiceModel toscaServiceModel) { + ServiceArtifact entityArt; + + for (String fileName : toscaServiceModel.getArtifactFiles().getFileList()) { + entityArt = new ServiceArtifact(); + entityArt.setContentData( + FileUtils.toByteArray(toscaServiceModel.getArtifactFiles().getFileContent(fileName))); + entityArt.setVspId(vspId); + entityArt.setVersion(version); + entityArt.setName(fileName); + + artifactDao.create(entityArt); + } + + ServiceTemplate entityTmp; + String yaml; + for (Map.Entry + entryTemplate : toscaServiceModel + .getServiceTemplates().entrySet()) { + entityTmp = new ServiceTemplate(); + + yaml = new ToscaExtensionYamlUtil().objectToYaml(entryTemplate.getValue()); + entityTmp.setContentData(yaml.getBytes()); + entityTmp.setVspId(vspId); + entityTmp.setVersion(version); + entityTmp.setName(entryTemplate.getKey()); + entityTmp.setBaseName(toscaServiceModel.getEntryDefinitionServiceTemplate()); + + templateDao.create(entityTmp); + } + + //TODO: update last modification time + } + + + /** + * Gets service model info. + * + * @param vspId the vsp id + * @param version the version + * @param name the name + * @return the service model info + */ + public ServiceElement getServiceModelInfo(String vspId, Version version, String name) { + ServiceElement element = templateDao.getTemplateInfo(vspId, version, name); + if (element != null) { + return element; + } + + element = artifactDao.getArtifactInfo(vspId, version, name); + if (element != null) { + return element; + } + return null; + } + + + /** + * Gets service model content names. + * + * @return the service model content names + */ + public List getServiceModelContentNames() { + + + return null; + } + + + private String getServiceBase(String vspId, Version version) { + return templateDao.getBase(vspId, version); + } + + private Map getTemplates( + String vspId, Version version) { + + Collection templates = templateDao.list(vspId, version); + if (templates == null) { + return null; + } + return templates.stream().collect(Collectors.toMap(template -> template.getName(), + template -> getServiceTemplate(template.getContent()))); + } + + private org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate getServiceTemplate( + InputStream content) { + return new ToscaExtensionYamlUtil() + .yamlToObject(content, org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate.class); + } + + private FileContentHandler getArtifacts(String vspId, Version version) { + Collection templates = artifactDao.list(vspId, version); + if (templates == null) { + return null; + } + + FileContentHandler fileContentHandler = new FileContentHandler(); + templates.stream().forEach(serviceArtifact -> fileContentHandler + .addFile(serviceArtifact.getName(), serviceArtifact.getContent())); + + return fileContentHandler; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/pom.xml b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/pom.xml new file mode 100644 index 0000000000..ff376f1e7d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/pom.xml @@ -0,0 +1,61 @@ + + 4.0.0 + + + org.openecomp.sdc + openecomp-sdc-lib + 1.0.0-SNAPSHOT + ../.. + + + openecomp-sdc-model-impl + openecomp-sdc-model-impl + + + + org.slf4j + slf4j-api + 1.7.10 + + + + ch.qos.logback + logback-classic + 1.1.2 + + + + + + org.openecomp.core + openecomp-utilities-lib + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-model-core + ${project.version} + + + + + org.openecomp.sdc + openecomp-sdc-datatypes-lib + ${project.version} + + + org.mockito + mockito-all + test + 1.10.19 + + + com.google.guava + guava + 19.0 + + + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/EnrichedServiceArtifactDaoCassandraFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/EnrichedServiceArtifactDaoCassandraFactoryImpl.java new file mode 100644 index 0000000000..13e351c257 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/EnrichedServiceArtifactDaoCassandraFactoryImpl.java @@ -0,0 +1,36 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.model.impl; + + +import org.openecomp.core.model.dao.EnrichedServiceArtifactDao; +import org.openecomp.core.model.dao.EnrichedServiceArtifactDaoFactory; + +public class EnrichedServiceArtifactDaoCassandraFactoryImpl + extends EnrichedServiceArtifactDaoFactory { + private static final EnrichedServiceArtifactDao INSTANCE = + new EnrichedServiceArtifactDaoCassandraImpl(); + + @Override + public EnrichedServiceArtifactDao createInterface() { + return INSTANCE; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/EnrichedServiceArtifactDaoCassandraImpl.java b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/EnrichedServiceArtifactDaoCassandraImpl.java new file mode 100644 index 0000000000..d9ebe849e3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/EnrichedServiceArtifactDaoCassandraImpl.java @@ -0,0 +1,137 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.model.impl; + +import com.datastax.driver.core.ResultSet; +import com.datastax.driver.core.UDTValue; +import com.datastax.driver.mapping.Mapper; +import com.datastax.driver.mapping.Result; +import com.datastax.driver.mapping.UDTMapper; +import com.datastax.driver.mapping.annotations.Accessor; +import com.datastax.driver.mapping.annotations.Query; +import org.openecomp.core.model.dao.EnrichedServiceArtifactDao; +import org.openecomp.core.model.types.EnrichedServiceArtifactEntity; +import org.openecomp.core.model.types.ServiceArtifact; +import org.openecomp.core.nosqldb.api.NoSqlDb; +import org.openecomp.core.nosqldb.factory.NoSqlDbFactory; +import org.openecomp.sdc.versioning.VersioningManagerFactory; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.types.VersionableEntityMetadata; + +import java.util.Collection; +import java.util.List; +import java.util.stream.Collectors; + +public class EnrichedServiceArtifactDaoCassandraImpl implements EnrichedServiceArtifactDao { + + private static final NoSqlDb noSqlDb = NoSqlDbFactory.getInstance().createInterface(); + private static final Mapper mapper = + noSqlDb.getMappingManager().mapper(EnrichedServiceArtifactEntity.class); + private static final VspServiceArtifactAccessor accessor = + noSqlDb.getMappingManager().createAccessor(VspServiceArtifactAccessor.class); + private static final UDTMapper versionMapper = + noSqlDb.getMappingManager().udtMapper(Version.class); + + @Override + public void registerVersioning(String versionableEntityType) { + VersioningManagerFactory.getInstance().createInterface() + .register(versionableEntityType, new VersionableEntityMetadata( + mapper.getTableMetadata().getName(), + mapper.getTableMetadata().getPartitionKey().get(0).getName(), + mapper.getTableMetadata().getPartitionKey().get(1).getName())); + } + + @Override + public Collection list(String vspId, Version version) { + List entityList; + if (vspId != null && version != null) { + entityList = accessor.list(vspId, versionMapper.toUDT(version)).all(); + } else { + entityList = accessor.listAll().all(); + } + + return entityList.stream().map(entity -> entity.getServiceArtifact()) + .collect(Collectors.toList()); + } + + @Override + public void create(ServiceArtifact entity) { + EnrichedServiceArtifactEntity vspEnrichedServiceArtifactEntity = + new EnrichedServiceArtifactEntity(entity); + mapper.save(vspEnrichedServiceArtifactEntity); + } + + @Override + public void update(ServiceArtifact entity) { + EnrichedServiceArtifactEntity vspEnrichedServiceArtifactEntity = + new EnrichedServiceArtifactEntity(entity); + mapper.save(vspEnrichedServiceArtifactEntity); + } + + @Override + public ServiceArtifact get(String vspId, Version version) { + return mapper.get(getKeys(vspId, version)).getServiceArtifact(); + } + + @Override + public void delete(String vspId, Version version) { + accessor.delete(vspId, versionMapper.toUDT(version)); + } + + @Override + public Object[] getKeys(String vspId, Version version) { + return new Object[]{vspId, versionMapper.toUDT(version)}; + } + + @Override + public ServiceArtifact getArtifactInfo(String vspId, Version version, String name) { + EnrichedServiceArtifactEntity enrichedServiceArtifactEntity = + accessor.getArtifactInfo(vspId, versionMapper.toUDT(version), name).one(); + if (enrichedServiceArtifactEntity == null) { + return null; + } + + return enrichedServiceArtifactEntity.getServiceArtifact(); + } + + + @Accessor + interface VspServiceArtifactAccessor { + + @Query("SELECT vsp_id, version, name ,content_data FROM vsp_enriched_service_artifact") + Result listAll(); + + @Query( + "SELECT vsp_id, version, name ,content_data FROM vsp_enriched_service_artifact " + + "where vsp_id=? and version=? ") + Result list(String vspId, UDTValue version); + + + @Query( + "SELECT vsp_id,version,name,content_data FROM vsp_enriched_service_artifact " + + "where vsp_id=? and version=? and name=?") + Result getArtifactInfo(String vspId, UDTValue version, + String name); + + @Query("DELETE from vsp_enriched_service_artifact where vsp_id=? and version=?") + ResultSet delete(String vspId, UDTValue version); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/EnrichedServiceModelDaoFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/EnrichedServiceModelDaoFactoryImpl.java new file mode 100644 index 0000000000..326e5e78fc --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/EnrichedServiceModelDaoFactoryImpl.java @@ -0,0 +1,34 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.model.impl; + + +import org.openecomp.core.model.dao.EnrichedServiceModelDao; +import org.openecomp.core.model.dao.EnrichedServiceModelDaoFactory; + +public class EnrichedServiceModelDaoFactoryImpl extends EnrichedServiceModelDaoFactory { + private static final EnrichedServiceModelDao INSTANCE = new EnrichedServiceModelDaoImpl(); + + @Override + public EnrichedServiceModelDao createInterface() { + return INSTANCE; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/EnrichedServiceModelDaoImpl.java b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/EnrichedServiceModelDaoImpl.java new file mode 100644 index 0000000000..9e784c7fef --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/EnrichedServiceModelDaoImpl.java @@ -0,0 +1,44 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.model.impl; + +import org.openecomp.core.model.dao.EnrichedServiceArtifactDaoFactory; +import org.openecomp.core.model.dao.EnrichedServiceModelDao; +import org.openecomp.core.model.dao.EnrichedServiceTemplateDaoFactory; +import org.openecomp.core.model.types.ServiceArtifact; +import org.openecomp.core.model.types.ServiceElement; +import org.openecomp.sdc.tosca.datatypes.ToscaServiceModel; +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.util.List; + +public class EnrichedServiceModelDaoImpl extends AbstractServiceModelDao + implements EnrichedServiceModelDao { + public EnrichedServiceModelDaoImpl() { + templateDao = EnrichedServiceTemplateDaoFactory.getInstance().createInterface(); + artifactDao = EnrichedServiceArtifactDaoFactory.getInstance().createInterface(); + } + + @Override + public List getExternalArtifacts(String vspId, Version version) { + return (List) artifactDao.list(vspId, version); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/EnrichedServiceTemplateDaoCassandraFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/EnrichedServiceTemplateDaoCassandraFactoryImpl.java new file mode 100644 index 0000000000..8103b2cea6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/EnrichedServiceTemplateDaoCassandraFactoryImpl.java @@ -0,0 +1,36 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.model.impl; + + +import org.openecomp.core.model.dao.EnrichedServiceTemplateDao; +import org.openecomp.core.model.dao.EnrichedServiceTemplateDaoFactory; + +public class EnrichedServiceTemplateDaoCassandraFactoryImpl + extends EnrichedServiceTemplateDaoFactory { + private static final EnrichedServiceTemplateDao INSTANCE = + new EnrichedServiceTemplateDaoCassandraImpl(); + + @Override + public EnrichedServiceTemplateDao createInterface() { + return INSTANCE; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/EnrichedServiceTemplateDaoCassandraImpl.java b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/EnrichedServiceTemplateDaoCassandraImpl.java new file mode 100644 index 0000000000..f0d4b56204 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/EnrichedServiceTemplateDaoCassandraImpl.java @@ -0,0 +1,147 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.model.impl; + +import com.datastax.driver.core.UDTValue; +import com.datastax.driver.mapping.Mapper; +import com.datastax.driver.mapping.Result; +import com.datastax.driver.mapping.UDTMapper; +import com.datastax.driver.mapping.annotations.Accessor; +import com.datastax.driver.mapping.annotations.Query; +import org.openecomp.core.model.dao.EnrichedServiceTemplateDao; +import org.openecomp.core.model.types.EnrichedServiceTemplateEntity; +import org.openecomp.core.model.types.ServiceTemplate; +import org.openecomp.core.nosqldb.api.NoSqlDb; +import org.openecomp.core.nosqldb.factory.NoSqlDbFactory; +import org.openecomp.sdc.versioning.VersioningManagerFactory; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.types.VersionableEntityMetadata; + +import java.util.Collection; +import java.util.List; +import java.util.stream.Collectors; + +public class EnrichedServiceTemplateDaoCassandraImpl implements EnrichedServiceTemplateDao { + + private static final NoSqlDb noSqlDb = NoSqlDbFactory.getInstance().createInterface(); + private static final Mapper mapper = + noSqlDb.getMappingManager().mapper(EnrichedServiceTemplateEntity.class); + private static final VspServiceTemplateAccessor accessor = + noSqlDb.getMappingManager().createAccessor(VspServiceTemplateAccessor.class); + private static final UDTMapper versionMapper = + noSqlDb.getMappingManager().udtMapper(Version.class); + + @Override + public void registerVersioning(String versionableEntityType) { + VersioningManagerFactory.getInstance().createInterface() + .register(versionableEntityType, new VersionableEntityMetadata( + mapper.getTableMetadata().getName(), + mapper.getTableMetadata().getPartitionKey().get(0).getName(), + mapper.getTableMetadata().getPartitionKey().get(1).getName())); + } + + @Override + public Collection list(String vspId, Version version) { + + List entityList = accessor.list(vspId, version).all(); + return entityList.stream().map(entity -> entity.getServiceTemplate()) + .collect(Collectors.toList()); + } + + @Override + public void create(ServiceTemplate entity) { + EnrichedServiceTemplateEntity vspEnrichedServiceTemplateEntity = + new EnrichedServiceTemplateEntity(entity); + mapper.save(vspEnrichedServiceTemplateEntity); + } + + @Override + public void update(ServiceTemplate entity) { + EnrichedServiceTemplateEntity vspEnrichedServiceTemplateEntity = + new EnrichedServiceTemplateEntity(entity); + mapper.save(vspEnrichedServiceTemplateEntity); + } + + @Override + public ServiceTemplate get(String vspId, Version version) { + return (mapper.get(getKeys(vspId, version))).getServiceTemplate(); + } + + @Override + public void delete(String vspId, Version version) { + mapper.delete(vspId, version); + } + + + @Override + public Object[] getKeys(String vspId, Version version) { + return new Object[]{vspId, versionMapper.toUDT(version)}; + } + + @Override + public ServiceTemplate getTemplateInfo(String vspId, Version version, String name) { + EnrichedServiceTemplateEntity enrichedServiceTemplateEntity = + accessor.getTemplateInfo(vspId, versionMapper.toUDT(version), name).one(); + if (enrichedServiceTemplateEntity == null) { + return null; + } + return enrichedServiceTemplateEntity.getServiceTemplate(); + } + + @Override + public String getBase(String vspId, Version version) { + Result element = + accessor.getBase(vspId, versionMapper.toUDT(version)); + if (element != null) { + EnrichedServiceTemplateEntity vspEnrichedServiceTemplateEntity = element.one(); + if (vspEnrichedServiceTemplateEntity != null) { + return element.one().getBaseName(); + } + } + return null; + } + + + @Accessor + interface VspServiceTemplateAccessor { + + @Query( + "SELECT vsp_id, version, name, base_name ,content_data FROM vsp_enriched_service_template") + Result listAll(); + + @Query( + "SELECT vsp_id, version, name, base_name ,content_data FROM vsp_enriched_service_template " + + "where vsp_id=? and version=?") + Result list(String vspId, Version version); + + + @Query( + "SELECT vsp_id, version, name, base_name ,content_data FROM vsp_enriched_service_template " + + "where vsp_id=? and version=? and name=?") + Result getTemplateInfo(String vspId, UDTValue version, + String name); + + @Query( + "SELECT vsp_id, version, name, base_name FROM vsp_enriched_service_template " + + "where vsp_id=? and version=?") + Result getBase(String vspId, UDTValue version); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/ServiceArtifactDaoCassandraFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/ServiceArtifactDaoCassandraFactoryImpl.java new file mode 100644 index 0000000000..f24fb1b475 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/ServiceArtifactDaoCassandraFactoryImpl.java @@ -0,0 +1,34 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.model.impl; + + +import org.openecomp.core.model.dao.ServiceArtifactDao; +import org.openecomp.core.model.dao.ServiceArtifactDaoFactory; + +public class ServiceArtifactDaoCassandraFactoryImpl extends ServiceArtifactDaoFactory { + private static final ServiceArtifactDao INSTANCE = new ServiceArtifactDaoCassandraImpl(); + + @Override + public ServiceArtifactDao createInterface() { + return INSTANCE; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/ServiceArtifactDaoCassandraImpl.java b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/ServiceArtifactDaoCassandraImpl.java new file mode 100644 index 0000000000..c7851c0fd9 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/ServiceArtifactDaoCassandraImpl.java @@ -0,0 +1,139 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.model.impl; + +import com.datastax.driver.core.ResultSet; +import com.datastax.driver.core.UDTValue; +import com.datastax.driver.mapping.Mapper; +import com.datastax.driver.mapping.Result; +import com.datastax.driver.mapping.UDTMapper; +import com.datastax.driver.mapping.annotations.Accessor; +import com.datastax.driver.mapping.annotations.Query; +import org.openecomp.core.model.dao.ServiceArtifactDao; +import org.openecomp.core.model.types.ServiceArtifact; +import org.openecomp.core.model.types.ServiceArtifactEntity; +import org.openecomp.core.nosqldb.api.NoSqlDb; +import org.openecomp.core.nosqldb.factory.NoSqlDbFactory; +import org.openecomp.sdc.versioning.VersioningManagerFactory; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.types.VersionableEntityMetadata; + +import java.util.Collection; +import java.util.List; +import java.util.stream.Collectors; + +public class ServiceArtifactDaoCassandraImpl implements ServiceArtifactDao { + + private static final NoSqlDb noSqlDb = NoSqlDbFactory.getInstance().createInterface(); + private static final Mapper mapper = + noSqlDb.getMappingManager().mapper(ServiceArtifactEntity.class); + private static final VspServiceArtifactAccessor accessor = + noSqlDb.getMappingManager().createAccessor(VspServiceArtifactAccessor.class); + private static final UDTMapper versionMapper = + noSqlDb.getMappingManager().udtMapper(Version.class); + + @Override + public void registerVersioning(String versionableEntityType) { + VersioningManagerFactory.getInstance().createInterface() + .register(versionableEntityType, new VersionableEntityMetadata( + mapper.getTableMetadata().getName(), + mapper.getTableMetadata().getPartitionKey().get(0).getName(), + mapper.getTableMetadata().getPartitionKey().get(1).getName())); + } + + @Override + public Collection list(String vspId, Version version) { + List entityList; + if (vspId != null && version != null) { + entityList = accessor.list(vspId, versionMapper.toUDT(version)).all(); + } else { + entityList = accessor.listAll().all(); + } + + return entityList.stream().map(entity -> entity.getServiceArtifact()) + .collect(Collectors.toList()); + } + + @Override + public void create(ServiceArtifact entity) { + ServiceArtifactEntity vspServiceArtifactEntity = new ServiceArtifactEntity(entity); + mapper.save(vspServiceArtifactEntity); + } + + @Override + public void update(ServiceArtifact entity) { + ServiceArtifactEntity vspServiceArtifactEntity = new ServiceArtifactEntity(entity); + mapper.save(vspServiceArtifactEntity); + } + + @Override + public ServiceArtifact get(String vspId, Version version) { + return mapper.get(getKeys(vspId, version)).getServiceArtifact(); + } + + @Override + public void delete(String vspId, Version version) { + accessor.delete(vspId, versionMapper.toUDT(version)); + } + + // @Override + // public void deleteArtifacts(String vspId, Version version){ + // accessor.delete(vspId, versionMapper.toUDT(version)); + // } + + @Override + public Object[] getKeys(String vspId, Version version) { + return new Object[]{vspId, versionMapper.toUDT(version)}; + } + + @Override + public ServiceArtifact getArtifactInfo(String vspId, Version version, String name) { + ServiceArtifactEntity serviceArtifactEntity = + accessor.getArtifactInfo(vspId, versionMapper.toUDT(version), name).one(); + if (serviceArtifactEntity == null) { + return null; + } + + return serviceArtifactEntity.getServiceArtifact(); + } + + + @Accessor + interface VspServiceArtifactAccessor { + + @Query("SELECT vsp_id, version, name ,content_data FROM vsp_service_artifact") + Result listAll(); + + @Query( + "SELECT vsp_id, version, name ,content_data " + + "FROM vsp_service_artifact where vsp_id=? and version=? ") + Result list(String vspId, UDTValue version); + + @Query( + "SELECT vsp_id,version,name,content_data FROM " + + "vsp_service_artifact where vsp_id=? and version=? and name=?") + Result getArtifactInfo(String vspId, UDTValue version, String name); + + @Query("DELETE from vsp_service_artifact where vsp_id=? and version=?") + ResultSet delete(String vspId, UDTValue version); + } + +} diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/ServiceModelDaoFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/ServiceModelDaoFactoryImpl.java new file mode 100644 index 0000000000..1347636bf1 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/ServiceModelDaoFactoryImpl.java @@ -0,0 +1,34 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.model.impl; + + +import org.openecomp.core.model.dao.ServiceModelDao; +import org.openecomp.core.model.dao.ServiceModelDaoFactory; + +public class ServiceModelDaoFactoryImpl extends ServiceModelDaoFactory { + private static final ServiceModelDao INSTANCE = new ServiceModelDaoImpl(); + + @Override + public ServiceModelDao createInterface() { + return INSTANCE; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/ServiceModelDaoImpl.java b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/ServiceModelDaoImpl.java new file mode 100644 index 0000000000..c397aec61d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/ServiceModelDaoImpl.java @@ -0,0 +1,38 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.model.impl; + +import org.openecomp.core.model.dao.ServiceArtifactDaoFactory; +import org.openecomp.core.model.dao.ServiceModelDao; +import org.openecomp.core.model.dao.ServiceTemplateDaoFactory; +import org.openecomp.core.model.types.ServiceElement; +import org.openecomp.sdc.tosca.datatypes.ToscaServiceModel; + +public class ServiceModelDaoImpl extends AbstractServiceModelDao + implements ServiceModelDao { + + + public ServiceModelDaoImpl() { + templateDao = ServiceTemplateDaoFactory.getInstance().createInterface(); + artifactDao = ServiceArtifactDaoFactory.getInstance().createInterface(); + } + +} diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/ServiceTemplateDaoCassandraFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/ServiceTemplateDaoCassandraFactoryImpl.java new file mode 100644 index 0000000000..23c43b76d3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/ServiceTemplateDaoCassandraFactoryImpl.java @@ -0,0 +1,34 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.model.impl; + + +import org.openecomp.core.model.dao.ServiceTemplateDao; +import org.openecomp.core.model.dao.ServiceTemplateDaoFactory; + +public class ServiceTemplateDaoCassandraFactoryImpl extends ServiceTemplateDaoFactory { + private static final ServiceTemplateDao INSTANCE = new ServiceTemplateDaoCassandraImpl(); + + @Override + public ServiceTemplateDao createInterface() { + return INSTANCE; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/ServiceTemplateDaoCassandraImpl.java b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/ServiceTemplateDaoCassandraImpl.java new file mode 100644 index 0000000000..ffc9a24677 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/openecomp-sdc-model-impl/src/main/java/org/openecomp/sdc/model/impl/ServiceTemplateDaoCassandraImpl.java @@ -0,0 +1,145 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.model.impl; + +import com.datastax.driver.core.UDTValue; +import com.datastax.driver.mapping.Mapper; +import com.datastax.driver.mapping.Result; +import com.datastax.driver.mapping.UDTMapper; +import com.datastax.driver.mapping.annotations.Accessor; +import com.datastax.driver.mapping.annotations.Query; +import org.openecomp.core.model.dao.ServiceTemplateDao; +import org.openecomp.core.model.types.ServiceTemplate; +import org.openecomp.core.model.types.ServiceTemplateEntity; +import org.openecomp.core.nosqldb.api.NoSqlDb; +import org.openecomp.core.nosqldb.factory.NoSqlDbFactory; +import org.openecomp.sdc.versioning.VersioningManagerFactory; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.types.VersionableEntityMetadata; + +import java.util.Collection; +import java.util.List; +import java.util.stream.Collectors; + +public class ServiceTemplateDaoCassandraImpl implements ServiceTemplateDao { + + + private static final NoSqlDb noSqlDb = NoSqlDbFactory.getInstance().createInterface(); + private static final Mapper mapper = + noSqlDb.getMappingManager().mapper(ServiceTemplateEntity.class); + private static final VspServiceTemplateAccessor accessor = + noSqlDb.getMappingManager().createAccessor(VspServiceTemplateAccessor.class); + private static final UDTMapper versionMapper = + noSqlDb.getMappingManager().udtMapper(Version.class); + + @Override + public void registerVersioning(String versionableEntityType) { + VersioningManagerFactory.getInstance().createInterface() + .register(versionableEntityType, new VersionableEntityMetadata( + mapper.getTableMetadata().getName(), + mapper.getTableMetadata().getPartitionKey().get(0).getName(), + mapper.getTableMetadata().getPartitionKey().get(1).getName())); + } + + @Override + public Collection list(String vspId, Version version) { + + List entityList = accessor.list(vspId, version).all(); + return entityList.stream().map(entity -> entity.getServiceTemplate()) + .collect(Collectors.toList()); + } + + @Override + public void create(ServiceTemplate entity) { + ServiceTemplateEntity vspServiceTemplateEntity = new ServiceTemplateEntity(entity); + mapper.save(vspServiceTemplateEntity); + } + + @Override + public void update(ServiceTemplate entity) { + ServiceTemplateEntity vspServiceTemplateEntity = new ServiceTemplateEntity(entity); + mapper.save(vspServiceTemplateEntity); + } + + @Override + public ServiceTemplate get(String vspId, Version version) { + return (mapper.get(getKeys(vspId, version))).getServiceTemplate(); + } + + @Override + public void delete(String vspId, Version version) { + mapper.delete(vspId, version); + } + + + @Override + public Object[] getKeys(String vspId, Version version) { + return new Object[]{vspId, versionMapper.toUDT(version)}; + } + + @Override + public ServiceTemplate getTemplateInfo(String vspId, Version version, String name) { + ServiceTemplateEntity serviceTemplateEntity = + accessor.getTemplateInfo(vspId, versionMapper.toUDT(version), name).one(); + if (serviceTemplateEntity == null) { + return null; + } + return serviceTemplateEntity.getServiceTemplate(); + } + + @Override + public String getBase(String vspId, Version version) { + Result element = accessor.getBase(vspId, versionMapper.toUDT(version)); + if (element != null) { + ServiceTemplateEntity vspServiceTemplateEntity = element.one(); + if (vspServiceTemplateEntity != null) { + return element.one().getBaseName(); + } + } + return null; + } + + + @Accessor + interface VspServiceTemplateAccessor { + + @Query("SELECT vsp_id, version, name, base_name ,content_data FROM vsp_service_template") + Result listAll(); + + @Query( + "SELECT vsp_id, version, name, base_name ,content_data" + + " FROM vsp_service_template where vsp_id=? and version=?") + Result list(String vspId, Version version); + + + @Query( + "SELECT vsp_id, version, name, base_name ,content_data " + + "FROM vsp_service_template where vsp_id=? and version=? and name=?") + Result getTemplateInfo(String vspId, UDTValue version, String name); + + @Query( + "SELECT vsp_id, version, name, base_name " + + "FROM vsp_service_template where vsp_id=? and version=?") + Result getBase(String vspId, UDTValue version); + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-model-lib/pom.xml b/openecomp-be/lib/openecomp-sdc-model-lib/pom.xml new file mode 100644 index 0000000000..e8b51d8a49 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-model-lib/pom.xml @@ -0,0 +1,43 @@ + + 4.0.0 + + pom + + openecomp-sdc-lib + org.openecomp.sdc + 1.0.0-SNAPSHOT + + + openecomp-sdc-model-lib + openecomp-sdc-model-lib + + + openecomp-sdc-model-api + openecomp-sdc-model-core + openecomp-sdc-model-impl + + + + + org.openecomp.sdc + openecomp-sdc-model-api + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-model-core + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-model-impl + ${project.version} + + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-api/pom.xml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-api/pom.xml new file mode 100644 index 0000000000..e6eca41134 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-api/pom.xml @@ -0,0 +1,43 @@ + + 4.0.0 + + + org.openecomp.sdc + openecomp-sdc-lib + 1.0.0-SNAPSHOT + ../.. + + + openecomp-sdc-translator-api + openecomp-sdc-translator-api + + + + org.openecomp.core + openecomp-facade-core + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-validation-api + ${project.version} + + + io.swagger + swagger-annotations + 1.5.3 + + + org.openecomp.core + openecomp-heat-lib + ${project.version} + + + org.openecomp.core + openecomp-tosca-lib + ${project.version} + + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-api/src/main/java/org/openecomp/core/translator/api/HeatToToscaTranslator.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-api/src/main/java/org/openecomp/core/translator/api/HeatToToscaTranslator.java new file mode 100644 index 0000000000..62c098d146 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-api/src/main/java/org/openecomp/core/translator/api/HeatToToscaTranslator.java @@ -0,0 +1,48 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.translator.api; + +import org.openecomp.core.translator.datatypes.TranslatorOutput; +import org.openecomp.sdc.datatypes.error.ErrorMessage; + +import java.io.InputStream; +import java.util.List; +import java.util.Map; + +public interface HeatToToscaTranslator { + + void addManifest(String name, byte[] content); + + void addFile(String name, byte[] content); + + void addFile(String name, InputStream content); + + // return Map, key - file name which has error + // value - the error code + Map> validate(); + + TranslatorOutput translate(); + + void addExternalArtifacts(String name, byte[] content); + + void addExternalArtifacts(String name, InputStream content); + +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-api/src/main/java/org/openecomp/core/translator/datatypes/TranslatorOutput.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-api/src/main/java/org/openecomp/core/translator/datatypes/TranslatorOutput.java new file mode 100644 index 0000000000..ec36625ced --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-api/src/main/java/org/openecomp/core/translator/datatypes/TranslatorOutput.java @@ -0,0 +1,48 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.translator.datatypes; + +import org.openecomp.sdc.datatypes.error.ErrorMessage; +import org.openecomp.sdc.tosca.datatypes.ToscaServiceModel; + +import java.util.List; +import java.util.Map; + +public class TranslatorOutput { + private Map> errorMessages; + private ToscaServiceModel toscaServiceModel; + + public Map> getErrorMessages() { + return errorMessages; + } + + public void setErrorMessages(Map> errorMessages) { + this.errorMessages = errorMessages; + } + + public ToscaServiceModel getToscaServiceModel() { + return toscaServiceModel; + } + + public void setToscaServiceModel(ToscaServiceModel toscaServiceModel) { + this.toscaServiceModel = toscaServiceModel; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-api/src/main/java/org/openecomp/core/translator/factory/HeatToToscaTranslatorFactory.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-api/src/main/java/org/openecomp/core/translator/factory/HeatToToscaTranslatorFactory.java new file mode 100644 index 0000000000..b9234cd87a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-api/src/main/java/org/openecomp/core/translator/factory/HeatToToscaTranslatorFactory.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.translator.factory; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; +import org.openecomp.core.translator.api.HeatToToscaTranslator; + +public abstract class HeatToToscaTranslatorFactory + extends AbstractComponentFactory { + + public static HeatToToscaTranslatorFactory getInstance() { + return AbstractFactory.getInstance(HeatToToscaTranslatorFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-api/src/main/resources/factoryConfiguration.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-api/src/main/resources/factoryConfiguration.json new file mode 100644 index 0000000000..4e4e2c23f9 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-api/src/main/resources/factoryConfiguration.json @@ -0,0 +1,3 @@ +{ + "org.openecomp.core.translator.factory.HeatToToscaTranslatorFactory": "org.openecomp.sdc.translator.impl.heattotosca.HeatToToscaTranslatorFactoryImpl" +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/pom.xml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/pom.xml new file mode 100644 index 0000000000..2bfa7dfd31 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/pom.xml @@ -0,0 +1,89 @@ + + 4.0.0 + + + org.openecomp.sdc + openecomp-sdc-lib + 1.0.0-SNAPSHOT + ../.. + + + openecomp-sdc-translator-core + openecomp-sdc-translator-core + + + + com.google.code.gson + gson + 2.3.1 + test + + + org.yaml + snakeyaml + 1.14 + test + + + org.slf4j + slf4j-api + 1.7.10 + + + + ch.qos.logback + logback-classic + 1.1.2 + + + + + junit + junit + RELEASE + test + + + org.openecomp.core + openecomp-utilities-lib + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-translator-api + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-validation-api + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-datatypes-lib + ${project.version} + + + org.mockito + mockito-all + test + 1.10.19 + + + com.google.guava + guava + 19.0 + + + org.openecomp.sdc + openecomp-sdc-validation-core + ${project.version} + + + org.openecomp.core + openecomp-heat-lib + ${project.version} + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/datatypes/heattotosca/AttachedResourceId.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/datatypes/heattotosca/AttachedResourceId.java new file mode 100644 index 0000000000..4286666392 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/datatypes/heattotosca/AttachedResourceId.java @@ -0,0 +1,65 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.datatypes.heattotosca; + +public class AttachedResourceId { + private Object translatedId; + private Object entityId; + private ResourceReferenceType resourceReferenceType; + + /** + * Instantiates a new Attached resource id. + * + * @param translatedId the translated id + * @param entityId the entity id + * @param resourceReferenceType the resource reference type + */ + public AttachedResourceId(Object translatedId, Object entityId, + ResourceReferenceType resourceReferenceType) { + this.translatedId = translatedId; + this.resourceReferenceType = resourceReferenceType; + this.entityId = entityId; + } + + public Object getEntityId() { + return entityId; + } + + public Object getTranslatedId() { + return translatedId; + } + + public ResourceReferenceType getResourceReferenceType() { + return resourceReferenceType; + } + + public boolean isGetResource() { + return resourceReferenceType == ResourceReferenceType.GET_RESOURCE; + } + + public boolean isGetParam() { + return resourceReferenceType == ResourceReferenceType.GET_PARAM; + } + + public boolean isGetAttr() { + return resourceReferenceType == ResourceReferenceType.GET_ATTR; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/datatypes/heattotosca/ResourceReferenceType.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/datatypes/heattotosca/ResourceReferenceType.java new file mode 100644 index 0000000000..81ccd69a66 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/datatypes/heattotosca/ResourceReferenceType.java @@ -0,0 +1,25 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.datatypes.heattotosca; + +public enum ResourceReferenceType { + GET_RESOURCE, GET_PARAM, GET_ATTR, OTHER +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/datatypes/heattotosca/to/FileDataCollection.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/datatypes/heattotosca/to/FileDataCollection.java new file mode 100644 index 0000000000..a9147b838f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/datatypes/heattotosca/to/FileDataCollection.java @@ -0,0 +1,123 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.datatypes.heattotosca.to; + + +import org.openecomp.sdc.heat.datatypes.manifest.FileData; + +import java.util.ArrayList; +import java.util.Collection; + +public class FileDataCollection { + + Collection baseFiles; + Collection addOnFiles; + Collection nestedFiles; + Collection artifactFiles; + + public Collection getBaseFile() { + return baseFiles; + } + + public void setBaseFile(Collection baseFiles) { + this.baseFiles = baseFiles; + } + + public Collection getAddOnFiles() { + return addOnFiles; + } + + public void setAddOnFiles(Collection addOnFiles) { + this.addOnFiles = addOnFiles; + } + + public Collection getNestedFiles() { + return nestedFiles; + } + + public void setNestedFiles(Collection nestedFiles) { + this.nestedFiles = nestedFiles; + } + + public Collection getBaseFiles() { + return baseFiles; + } + + public void setBaseFiles(Collection baseFiles) { + this.baseFiles = baseFiles; + } + + public Collection getArtifactFiles() { + return artifactFiles; + } + + public void setArtifactFiles(Collection artifactFiles) { + this.artifactFiles = artifactFiles; + } + + /** + * Add add on files. + * + * @param addonFile the addon file + */ + public void addAddOnFiles(FileData addonFile) { + if (this.addOnFiles == null) { + this.addOnFiles = new ArrayList<>(); + } + this.addOnFiles.add(addonFile); + } + + /** + * Add nested files. + * + * @param nestedFile the nested file + */ + public void addNestedFiles(FileData nestedFile) { + if (this.nestedFiles == null) { + this.nestedFiles = new ArrayList<>(); + } + this.nestedFiles.add(nestedFile); + } + + /** + * Add base files. + * + * @param baseFile the base file + */ + public void addBaseFiles(FileData baseFile) { + if (this.baseFiles == null) { + this.baseFiles = new ArrayList<>(); + } + this.baseFiles.add(baseFile); + } + + /** + * Add artifact files. + * + * @param artifactFile the artifact file + */ + public void addArtifactFiles(FileData artifactFile) { + if (this.artifactFiles == null) { + this.artifactFiles = new ArrayList<>(); + } + this.artifactFiles.add(artifactFile); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/datatypes/heattotosca/to/ResourceFileDataAndIDs.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/datatypes/heattotosca/to/ResourceFileDataAndIDs.java new file mode 100644 index 0000000000..b8349444d7 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/datatypes/heattotosca/to/ResourceFileDataAndIDs.java @@ -0,0 +1,70 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.datatypes.heattotosca.to; + + +import org.openecomp.sdc.heat.datatypes.manifest.FileData; + +public class ResourceFileDataAndIDs { + private String resourceId; + private String translatedResourceId; + private FileData fileData; + + public ResourceFileDataAndIDs() { + } + + /** + * Instantiates a new Resource file data and i ds. + * + * @param resourceId the resource id + * @param translatedResourceId the translated resource id + * @param fileData the file data + */ + public ResourceFileDataAndIDs(String resourceId, String translatedResourceId, FileData fileData) { + this.resourceId = resourceId; + this.translatedResourceId = translatedResourceId; + this.fileData = fileData; + } + + public String getResourceId() { + return resourceId; + } + + public void setResourceId(String resourceId) { + this.resourceId = resourceId; + } + + public String getTranslatedResourceId() { + return translatedResourceId; + } + + public void setTranslatedResourceId(String translatedResourceId) { + this.translatedResourceId = translatedResourceId; + } + + public FileData getFileData() { + return fileData; + } + + public void setFileData(FileData fileData) { + this.fileData = fileData; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/datatypes/heattotosca/to/TranslateTo.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/datatypes/heattotosca/to/TranslateTo.java new file mode 100644 index 0000000000..6c56715f79 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/datatypes/heattotosca/to/TranslateTo.java @@ -0,0 +1,132 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.datatypes.heattotosca.to; + + +import org.openecomp.sdc.heat.datatypes.model.HeatOrchestrationTemplate; +import org.openecomp.sdc.heat.datatypes.model.Resource; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.translator.services.heattotosca.TranslationContext; + +public class TranslateTo { + private String heatFileName; + private ServiceTemplate serviceTemplate; + private HeatOrchestrationTemplate heatOrchestrationTemplate; + private Resource resource; + private String resourceId; + private String translatedId; + private TranslationContext context; + + public TranslateTo() { + } + + /** + * Instantiates a new Translate to. + * + * @param heatFileName the heat file name + * @param serviceTemplate the service template + * @param heatOrchestrationTemplate the heat orchestration template + * @param resource the resource + * @param resourceId the resource id + * @param translatedId the translated id + * @param context the context + */ + public TranslateTo(String heatFileName, ServiceTemplate serviceTemplate, + HeatOrchestrationTemplate heatOrchestrationTemplate, Resource resource, + String resourceId, String translatedId, TranslationContext context) { + this.heatFileName = heatFileName; + this.serviceTemplate = serviceTemplate; + this.heatOrchestrationTemplate = heatOrchestrationTemplate; + this.resource = resource; + this.resourceId = resourceId; + this.translatedId = translatedId; + this.context = context; + } + + public String getHeatFileName() { + return heatFileName; + } + + public void setHeatFileName(String heatFileName) { + this.heatFileName = heatFileName; + } + + public ServiceTemplate getServiceTemplate() { + return serviceTemplate; + } + + public void setServiceTemplate(ServiceTemplate serviceTemplate) { + this.serviceTemplate = serviceTemplate; + } + + public HeatOrchestrationTemplate getHeatOrchestrationTemplate() { + return heatOrchestrationTemplate; + } + + public void setHeatOrchestrationTemplate(HeatOrchestrationTemplate heatOrchestrationTemplate) { + this.heatOrchestrationTemplate = heatOrchestrationTemplate; + } + + public Resource getResource() { + return resource; + } + + public void setResource(Resource resource) { + this.resource = resource; + } + + public String getResourceId() { + return resourceId; + } + + public void setResourceId(String resourceId) { + this.resourceId = resourceId; + } + + public String getTranslatedId() { + return translatedId; + } + + public void setTranslatedId(String translatedId) { + this.translatedId = translatedId; + } + + public TranslationContext getContext() { + return context; + } + + public void setContext(TranslationContext context) { + this.context = context; + } + + @Override + public String toString() { + return "TranslateTo{" + + "heatFileName='" + heatFileName + '\'' + + ", serviceTemplate=" + serviceTemplate + + ", heatOrchestrationTemplate=" + heatOrchestrationTemplate + + ", resource=" + resource + + ", resourceId='" + resourceId + '\'' + + ", translatedId='" + translatedId + '\'' + + ", context=" + context + + '}'; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/datatypes/heattotosca/to/TranslatedHeatResource.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/datatypes/heattotosca/to/TranslatedHeatResource.java new file mode 100644 index 0000000000..da46e56018 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/datatypes/heattotosca/to/TranslatedHeatResource.java @@ -0,0 +1,49 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.datatypes.heattotosca.to; + +import org.openecomp.sdc.heat.datatypes.model.Resource; + +public class TranslatedHeatResource { + private String translatedId; + private Resource heatResource; + + public TranslatedHeatResource(String translatedId, Resource heatResource) { + this.translatedId = translatedId; + this.heatResource = heatResource; + } + + public String getTranslatedId() { + return translatedId; + } + + public void setTranslatedId(String translatedId) { + this.translatedId = translatedId; + } + + public Resource getHeatResource() { + return heatResource; + } + + public void setHeatResource(Resource heatResource) { + this.heatResource = heatResource; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/impl/heattotosca/HeatToToscaTranslatorFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/impl/heattotosca/HeatToToscaTranslatorFactoryImpl.java new file mode 100644 index 0000000000..57f753f103 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/impl/heattotosca/HeatToToscaTranslatorFactoryImpl.java @@ -0,0 +1,34 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.impl.heattotosca; + +import org.openecomp.core.translator.api.HeatToToscaTranslator; +import org.openecomp.core.translator.factory.HeatToToscaTranslatorFactory; + +public class HeatToToscaTranslatorFactoryImpl extends HeatToToscaTranslatorFactory { + + private static HeatToToscaTranslator INSTANCE = new HeatToToscaTranslatorImpl(); + + @Override + public HeatToToscaTranslator createInterface() { + return new HeatToToscaTranslatorImpl(); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/impl/heattotosca/HeatToToscaTranslatorImpl.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/impl/heattotosca/HeatToToscaTranslatorImpl.java new file mode 100644 index 0000000000..0a6986816c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/impl/heattotosca/HeatToToscaTranslatorImpl.java @@ -0,0 +1,134 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.impl.heattotosca; + +import org.apache.commons.collections4.MapUtils; +import org.openecomp.core.translator.api.HeatToToscaTranslator; +import org.openecomp.core.translator.datatypes.TranslatorOutput; +import org.openecomp.core.utilities.file.FileUtils; +import org.openecomp.core.utilities.json.JsonUtil; +import org.openecomp.core.validation.api.ValidationManager; +import org.openecomp.core.validation.errors.Messages; +import org.openecomp.core.validation.factory.ValidationManagerFactory; +import org.openecomp.core.validation.types.MessageContainerUtil; +import org.openecomp.sdc.common.utils.AsdcCommon; +import org.openecomp.sdc.datatypes.error.ErrorLevel; +import org.openecomp.sdc.datatypes.error.ErrorMessage; +import org.openecomp.sdc.heat.datatypes.manifest.FileData; +import org.openecomp.sdc.heat.datatypes.manifest.ManifestContent; +import org.openecomp.sdc.heat.datatypes.manifest.ManifestFile; +import org.openecomp.sdc.translator.services.heattotosca.TranslationContext; +import org.openecomp.sdc.translator.services.heattotosca.TranslationService; + +import java.io.InputStream; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +public class HeatToToscaTranslatorImpl implements HeatToToscaTranslator { + + private TranslationContext translationContext = new TranslationContext(); + private ValidationManager validationManager = + ValidationManagerFactory.getInstance().createInterface(); + private boolean isValid = false; + + + @Override + public void addManifest(String name, byte[] content) { + ManifestContent manifestData = JsonUtil.json2Object(new String(content), ManifestContent.class); + ManifestFile manifest = new ManifestFile(); + manifest.setName(name); + manifest.setContent(manifestData); + translationContext.setManifest(manifest); + translationContext.addFile(name, content); + validationManager.addFile(AsdcCommon.MANIFEST_NAME, content); + addFilesFromManifestToTranslationContextManifestFilesMap(manifestData.getData()); + isValid = false; + } + + @Override + public void addFile(String name, byte[] content) { + translationContext.addFile(name, content); + validationManager.addFile(name, content); + isValid = false; + } + + @Override + public void addFile(String name, InputStream content) { + addFile(name, FileUtils.toByteArray(content)); + } + + + @Override + public Map> validate() { + + Map> errors = new HashMap<>(); + if (translationContext.getManifest() == null) { + ErrorMessage.ErrorMessageUtil.addMessage(AsdcCommon.MANIFEST_NAME, errors) + .add(new ErrorMessage(ErrorLevel.ERROR, Messages.MANIFEST_NOT_EXIST.getErrorMessage())); + return errors; + } + + if (MapUtils.isEmpty(errors)) { + errors = validationManager.validate(); + } + if (MapUtils.isEmpty(errors)) { + isValid = true; + } + return errors; + } + + @Override + public TranslatorOutput translate() { + TranslationService translationService = new TranslationService(); + TranslatorOutput translatorOutput = new TranslatorOutput(); + if (!isValid) { + Map> errors = validate(); + + if (MapUtils.isNotEmpty(MessageContainerUtil.getMessageByLevel(ErrorLevel.ERROR, errors))) { + translatorOutput.setErrorMessages(errors); + return translatorOutput; + } + } + + translatorOutput = translationService.translateHeatFiles(translationContext); + return translatorOutput; + } + + @Override + public void addExternalArtifacts(String name, byte[] content) { + translationContext.addExternalArtifacts(name, content); + } + + @Override + public void addExternalArtifacts(String name, InputStream content) { + addExternalArtifacts(name, FileUtils.toByteArray(content)); + } + + private void addFilesFromManifestToTranslationContextManifestFilesMap( + List fileDataListFromManifest) { + for (FileData fileFromManfiest : fileDataListFromManifest) { + translationContext.addManifestFile(fileFromManfiest.getFile(), fileFromManfiest.getType()); + } + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/Constants.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/Constants.java new file mode 100644 index 0000000000..abd6c27a21 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/Constants.java @@ -0,0 +1,60 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca; + +public class Constants { + //Service Template - Template Names + public static final String COMMON_GLOBAL_TEMPLATE_NAME = "CommonGlobalTypes"; + public static final String CINDER_VOLUME_TEMPLATE_NAME = "CinderVolumeGlobalTypes"; + public static final String CONTRAIL_VIRTUAL_NETWORK_TEMPLATE_NAME = + "ContrailVirtualNetworkGlobalType"; + public static final String CONTRAIL_NETWORK_RULE_TEMPLATE_NAME = "ContrailNetworkRuleGlobalType"; + public static final String CONTRAILV2_VIRTUAL_NETWORK_TEMPLATE_NAME = + "ContrailV2VirtualNetworkGlobalType"; + public static final String CONTRAILV2_NETWORK_RULE_TEMPLATE_NAME = + "ContrailV2NetworkRuleGlobalType"; + public static final String CONTRAILV2_VIRTUAL_MACHINE_INTERFACE_TEMPLATE_NAME = + "ContrailV2VirtualMachineInterfaceGlobalType"; + public static final String NEUTRON_NET_TEMPLATE_NAME = "NeutronNetGlobalTypes"; + public static final String NEUTRON_PORT_TEMPLATE_NAME = "NeutronPortGlobalTypes"; + public static final String NEUTRON_SECURITY_RULES_TEMPLATE_NAME = + "NeutronSecurityRulesGlobalTypes"; + public static final String NOVA_SERVER_TEMPLATE_NAME = "NovaServerGlobalTypes"; + public static final String ABSTRACT_SUBSTITUTE_TEMPLATE_NAME = "AbstractSubstituteGlobalTypes"; + public static final String GLOBAL_SUBSTITUTION_TYPES_TEMPLATE_NAME = "GlobalSubstitutionTypes"; + public static final String CONTRAIL_COMPUTE_TEMPLATE_NAME = "ContrailComputeGlobalTypes"; + public static final String CONTRAIL_PORT_TEMPLATE_NAME = "ContrailPortGlobalTypes"; + public static final String CONTRAIL_ABSTRACT_SUBSTITUTE_TEMPLATE_NAME = + "ContrailAbstractSubstituteGlobalTypes"; + //properties + public static final String MAX_INSTANCES_PROPERTY_NAME = "max_instances"; + public static final String DESCRIPTION_PROPERTY_NAME = "description"; + public static final String NAME_PROPERTY_NAME = "name"; + public static final String RULES_PROPERTY_NAME = "rules"; + public static final String SECURITY_GROUPS_PROPERTY_NAME = "security_groups"; + public static final String PORT_PROPERTY_NAME = "port"; + //General + public static final String PROP = "properties"; + public static final String ATTR = "attributes"; + + private Constants() { + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/HeatToToscaUtil.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/HeatToToscaUtil.java new file mode 100644 index 0000000000..f245a6dee6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/HeatToToscaUtil.java @@ -0,0 +1,503 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca; + +import org.apache.commons.collections4.CollectionUtils; +import org.openecomp.core.utilities.yaml.YamlUtil; +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.heat.datatypes.HeatBoolean; +import org.openecomp.sdc.heat.datatypes.manifest.FileData; +import org.openecomp.sdc.heat.datatypes.model.HeatOrchestrationTemplate; +import org.openecomp.sdc.heat.datatypes.model.HeatResourcesTypes; +import org.openecomp.sdc.heat.datatypes.model.Resource; +import org.openecomp.sdc.heat.services.HeatConstants; +import org.openecomp.sdc.tosca.datatypes.ToscaServiceModel; +import org.openecomp.sdc.tosca.datatypes.model.NodeTemplate; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.services.ToscaUtil; +import org.openecomp.sdc.translator.datatypes.heattotosca.AttachedResourceId; +import org.openecomp.sdc.translator.datatypes.heattotosca.ResourceReferenceType; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.FileDataCollection; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslateTo; +import org.openecomp.sdc.translator.services.heattotosca.errors.ResourceNotFoundInHeatFileErrorBuilder; +import org.openecomp.sdc.translator.services.heattotosca.mapping.TranslatorHeatToToscaFunctionConverter; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; +import java.util.stream.Collectors; + +public class HeatToToscaUtil { + + protected static Logger logger = LoggerFactory.getLogger(HeatToToscaUtil.class); + + + /** + * Build list of files to search optional. + * + * @param heatFileName the heat file name + * @param filesDataList the files data list + * @param types the types + * @return the optional + */ + public static Optional> buildListOfFilesToSearch(String heatFileName, + List filesDataList, + FileData.Type... types) { + List list = new ArrayList<>(filesDataList); + Optional resourceFileData = HeatToToscaUtil.getFileData(heatFileName, filesDataList); + if (resourceFileData.isPresent() && Objects.nonNull(resourceFileData.get().getData())) { + list.addAll(resourceFileData.get().getData()); + } + return Optional.ofNullable(HeatToToscaUtil.getFilteredListOfFileDataByTypes(list, types)); + } + + public static List getFilteredListOfFileDataByTypes(List filesToSearch, + FileData.Type... types) { + return filesToSearch.stream().filter(FileData.buildFileDataPredicateByType(types)) + .collect(Collectors.toList()); + } + + /** + * Gets file data. + * + * @param heatFileName the heat file name + * @param fileDataList the file data list + * @return the file data + */ + public static Optional getFileData(String heatFileName, + Collection fileDataList) { + for (FileData file : fileDataList) { + if (file.getFile().equals(heatFileName)) { + return Optional.of(file); + } + } + return Optional.empty(); + } + + static FileDataCollection getFileCollectionsByFilter(List fileDataList, + Set typeFilter, + TranslationContext translationContext) { + FileDataCollection fileDataCollection = new FileDataCollection(); + Map filteredFiles = filterFileDataListByType(fileDataList, typeFilter); + Set referenced = new HashSet<>(); + List filenames = extractFilenamesFromFileDataList(filteredFiles.values()); + + for (FileData fileData : filteredFiles.values()) { + String fileName = fileData.getFile(); + + if (FileData.isHeatFile(fileData.getType())) { + if (fileData.getBase() != null && fileData.getBase().equals(true)) { + fileDataCollection.addBaseFiles(fileData); + } + HeatOrchestrationTemplate heatOrchestrationTemplate = new YamlUtil() + .yamlToObject(translationContext.getFileContent(fileName), + HeatOrchestrationTemplate.class); + for (Resource resource : heatOrchestrationTemplate.getResources().values()) { + if (filenames.contains(resource.getType())) { + handleNestedFile(translationContext, fileDataCollection, filteredFiles, referenced, + resource.getType()); + } else if (resource.getType() + .equals(HeatResourcesTypes.RESOURCE_GROUP_RESOURCE_TYPE.getHeatResource())) { + Object resourceDef = + resource.getProperties().get(HeatConstants.RESOURCE_DEF_PROPERTY_NAME); + Object innerTypeDef = ((Map) resourceDef).get("type"); + if (innerTypeDef instanceof String) { + String internalResourceType = (String) innerTypeDef; + if (filenames.contains(internalResourceType)) { + handleNestedFile(translationContext, fileDataCollection, filteredFiles, referenced, + internalResourceType); + } + } + } + } + + } else { + fileDataCollection.addArtifactFiles(fileData); + filteredFiles.remove(fileData.getFile()); + } + } + + referenced.forEach(filteredFiles::remove); + if (!CollectionUtils.isEmpty(fileDataCollection.getBaseFile())) { + for (FileData fileData : fileDataCollection.getBaseFile()) { + filteredFiles.remove(fileData.getFile()); + } + } + fileDataCollection.setAddOnFiles(filteredFiles.values()); + return fileDataCollection; + } + + private static void handleNestedFile(TranslationContext translationContext, + FileDataCollection fileDataCollection, + Map filteredFiles, Set referenced, + String nestedFileName) { + referenced.add(nestedFileName); + fileDataCollection.addNestedFiles(filteredFiles.get(nestedFileName)); + translationContext.getNestedHeatsFiles().add(nestedFileName); + } + + private static Map filterFileDataListByType(List fileDataList, + Set typesToGet) { + Map filtered = new HashMap<>(); + fileDataList.stream().filter(file -> typesToGet.contains(file.getType())) + .forEach(file -> filtered.put(file.getFile(), file)); + return filtered; + } + + private static List extractFilenamesFromFileDataList(Collection fileDataList) { + return fileDataList.stream().map(FileData::getFile).collect(Collectors.toList()); + } + + /** + * Extract attached resource id optional. + * + * @param translateTo the translate to + * @param propertyName the property name + * @return the optional + */ + public static Optional extractAttachedResourceId(TranslateTo translateTo, + String propertyName) { + Object propertyValue = translateTo.getResource().getProperties().get(propertyName); + if (propertyValue == null) { + return Optional.empty(); + } + return extractAttachedResourceId(translateTo.getHeatFileName(), + translateTo.getHeatOrchestrationTemplate(), translateTo.getContext(), propertyValue); + } + + /** + * Extract attached resource id optional. + * + * @param heatFileName the heat file name + * @param heatOrchestrationTemplate the heat orchestration template + * @param context the context + * @param propertyValue the property value + * @return the optional + */ + public static Optional extractAttachedResourceId(String heatFileName, + HeatOrchestrationTemplate heatOrchestrationTemplate, + TranslationContext context, + Object propertyValue) { + + Object entity; + Object translatedId; + + if (Objects.isNull(propertyValue)) { + return Optional.empty(); + } + + ResourceReferenceType referenceType = ResourceReferenceType.OTHER; + if (propertyValue instanceof Map && !((Map) propertyValue).isEmpty()) { + Map propMap = (Map) propertyValue; + Map.Entry entry = propMap.entrySet().iterator().next(); + entity = entry.getValue(); + String key = entry.getKey(); + switch (key) { + case "get_resource": + referenceType = ResourceReferenceType.GET_RESOURCE; + break; + case "get_param": + referenceType = ResourceReferenceType.GET_PARAM; + break; + case "get_attr": + referenceType = ResourceReferenceType.GET_ATTR; + break; + default: + } + translatedId = TranslatorHeatToToscaFunctionConverter + .getToscaFunction(entry.getKey(), entry.getValue(), heatFileName, + heatOrchestrationTemplate, null, context); + if (translatedId instanceof String + && !TranslatorHeatToToscaFunctionConverter.isResourceSupported((String) translatedId)) { + translatedId = null; + } + + } else { + translatedId = propertyValue; + entity = propertyValue; + } + + return Optional.of(new AttachedResourceId(translatedId, entity, referenceType)); + } + + /** + * Gets contrail attached heat resource id. + * + * @param attachedResource the attached resource + * @return the contrail attached heat resource id + */ + public static Optional getContrailAttachedHeatResourceId( + AttachedResourceId attachedResource) { + if (attachedResource == null) { + return Optional.empty(); + } + + if (attachedResource.isGetResource()) { + return Optional.of((String) attachedResource.getEntityId()); + } + if (attachedResource.isGetAttr() && (attachedResource.getEntityId() instanceof List) + && ((List) attachedResource.getEntityId()).size() > 1 + && ((List) attachedResource.getEntityId()).get(1).equals("fq_name")) { + return Optional.of((String) ((List) attachedResource.getEntityId()).get(0)); + } + + return Optional.empty(); + } + + /** + * Extract property optional. + * + * @param propertyValue the property value + * @return the optional + */ + public static Optional extractProperty(Object propertyValue) { + + Object entity; + if (Objects.isNull(propertyValue)) { + return Optional.empty(); + } + + ResourceReferenceType referenceType = ResourceReferenceType.OTHER; + if (propertyValue instanceof Map && !((Map) propertyValue).isEmpty()) { + Map propMap = (Map) propertyValue; + Map.Entry entry = propMap.entrySet().iterator().next(); + entity = entry.getValue(); + String key = entry.getKey(); + switch (key) { + case "get_resource": + referenceType = ResourceReferenceType.GET_RESOURCE; + break; + case "get_param": + referenceType = ResourceReferenceType.GET_PARAM; + break; + case "get_attr": + referenceType = ResourceReferenceType.GET_ATTR; + break; + default: + } + + } else { + entity = propertyValue; + } + + return Optional.of(new AttachedResourceId(null, entity, referenceType)); + } + + /** + * Map boolean. + * + * @param nodeTemplate the node template + * @param propertyKey the property key + */ + public static void mapBoolean(NodeTemplate nodeTemplate, String propertyKey) { + Object value = nodeTemplate.getProperties().get(propertyKey); + if (value != null && !(value instanceof Map)) { + nodeTemplate.getProperties().put(propertyKey, HeatBoolean.eval(value)); + } + } + + /** + * Map boolean list. + * + * @param nodeTemplate the node template + * @param propertyListKey the property list key + */ + public static void mapBooleanList(NodeTemplate nodeTemplate, String propertyListKey) { + Object listValue = nodeTemplate.getProperties().get(propertyListKey); + if (listValue instanceof List) { + List booleanList = ((List) listValue); + for (int i = 0; i < booleanList.size(); i++) { + Object value = booleanList.get(i); + if (value != null && !(value instanceof Map)) { + booleanList.set(i, HeatBoolean.eval(value)); + } + } + } + } + + + public static boolean isYmlFileType(String filename) { + return (filename.indexOf("yaml") > 0 || filename.indexOf("yml") > 0); + } + + /** + * Is nested resource boolean. + * + * @param resource the resource + * @return the boolean + */ + public static boolean isNestedResource(Resource resource) { + String resourceType = resource.getType(); + + if (resourceType.equals(HeatResourcesTypes.RESOURCE_GROUP_RESOURCE_TYPE.getHeatResource())) { + Object resourceDef = resource.getProperties().get(HeatConstants.RESOURCE_DEF_PROPERTY_NAME); + String internalResourceType = (String) ((Map) resourceDef).get("type"); + if (isYamlFile(internalResourceType)) { + return true; + } + } else if (isYamlFile(resourceType)) { + return true; + } + return false; + } + + /** + * Gets nested file. + * + * @param resource the resource + * @return the nested file + */ + public static Optional getNestedFile(Resource resource) { + if (!isNestedResource(resource)) { + return Optional.empty(); + } + String resourceType = resource.getType(); + if (resourceType.equals(HeatResourcesTypes.RESOURCE_GROUP_RESOURCE_TYPE.getHeatResource())) { + Object resourceDef = resource.getProperties().get(HeatConstants.RESOURCE_DEF_PROPERTY_NAME); + String internalResourceType = (String) ((Map) resourceDef).get("type"); + return Optional.of(internalResourceType); + } else { + return Optional.of(resourceType); + } + } + + private static boolean isYamlFile(String fileName) { + return fileName.endsWith(".yaml") || fileName.endsWith(".yml"); + } + + /** + * Gets resource. + * + * @param heatOrchestrationTemplate the heat orchestration template + * @param resourceId the resource id + * @param heatFileName the heat file name + * @return the resource + */ + public static Resource getResource(HeatOrchestrationTemplate heatOrchestrationTemplate, + String resourceId, String heatFileName) { + Resource resource = heatOrchestrationTemplate.getResources().get(resourceId); + if (resource == null) { + throw new CoreException( + new ResourceNotFoundInHeatFileErrorBuilder(resourceId, heatFileName).build()); + } + return resource; + } + + public static boolean isHeatFileNested(TranslateTo translateTo, String heatFileName) { + return translateTo.getContext().getNestedHeatsFiles().contains(heatFileName); + } + + /** + * Extract contrail get resource attached heat resource id string. + * + * @param propertyValue the property value + * @return the string + */ + public static String extractContrailGetResourceAttachedHeatResourceId(Object propertyValue) { + if (propertyValue == null) { + return null; + } + + Object value; + if (propertyValue instanceof Map) { + if (((Map) propertyValue).containsKey("get_attr")) { + value = ((Map) propertyValue).get("get_attr"); + if (value instanceof List) { + if (((List) value).size() == 2 && ((List) value).get(1).equals("fq_name")) { + if (((List) value).get(0) instanceof String) { + return (String) ((List) value).get(0); + } else { + logger.warn("invalid format of 'get_attr' function - " + propertyValue.toString()); + } + } + } + } else if (((Map) propertyValue).containsKey("get_resource")) { + value = ((Map) propertyValue).get("get_resource"); + if (value instanceof String) { + return (String) value; + } else { + logger.warn("invalid format of 'get_resource' function - " + propertyValue.toString()); + } + } else { + Collection valCollection = ((Map) propertyValue).values(); + for (Object entryValue : valCollection) { + String ret = extractContrailGetResourceAttachedHeatResourceId(entryValue); + if (ret != null) { + return ret; + } + + } + } + } else if (propertyValue instanceof List) { + for (Object prop : (List) propertyValue) { + String ret = extractContrailGetResourceAttachedHeatResourceId(prop); + if (ret != null) { + return ret; + } + } + } + return null; + } + + /** + * Gets tosca service model. + * + * @param translateTo the translate to + * @return the tosca service model + */ + public static ToscaServiceModel getToscaServiceModel(TranslateTo translateTo) { + Map serviceTemplates = + new HashMap<>(translateTo.getContext().getGlobalServiceTemplates()); + Collection tmpServiceTemplates = + translateTo.getContext().getTranslatedServiceTemplates().values(); + for (ServiceTemplate serviceTemplate : tmpServiceTemplates) { + ToscaUtil.addServiceTemplateToMapWithKeyFileName(serviceTemplates, serviceTemplate); + } + return new ToscaServiceModel(null, serviceTemplates, + ToscaUtil.getServiceTemplateFileName(translateTo.getResource().getType())); + } + + /** + * Gets service template from context. + * + * @param serviceTemplateFileName the service template file name + * @param context the context + * @return the service template from context + */ + public static Optional getServiceTemplateFromContext( + String serviceTemplateFileName, TranslationContext context) { + for (ServiceTemplate serviceTemplate : context.getTranslatedServiceTemplates().values()) { + if (ToscaUtil.getServiceTemplateFileName(serviceTemplate).equals(serviceTemplateFileName)) { + return Optional.of(serviceTemplate); + } + } + + return Optional.empty(); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/ResourceTranslation.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/ResourceTranslation.java new file mode 100644 index 0000000000..231eb42c03 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/ResourceTranslation.java @@ -0,0 +1,37 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca; + + +import org.openecomp.sdc.heat.datatypes.model.HeatOrchestrationTemplate; +import org.openecomp.sdc.heat.datatypes.model.Resource; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; + +import java.util.Optional; + +public interface ResourceTranslation { + + //return the Id of translated object (NodeTemplate, RelationshipTemplate and etc) + Optional translateResource(String heatFileName, ServiceTemplate serviceTemplate, + HeatOrchestrationTemplate heatOrchestrationTemplate, + Resource resource, String resourceId, + TranslationContext context); +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/ResourceTranslationFactory.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/ResourceTranslationFactory.java new file mode 100644 index 0000000000..730c2ddd7a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/ResourceTranslationFactory.java @@ -0,0 +1,107 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca; + + +import org.openecomp.sdc.heat.datatypes.model.HeatResourcesTypes; +import org.openecomp.sdc.heat.datatypes.model.Resource; + +import org.openecomp.sdc.translator.services.heattotosca.impl.ResourceTranslationBase; +import org.openecomp.sdc.translator.services.heattotosca.impl.ResourceTranslationCinderVolumeAttachmentImpl; +import org.openecomp.sdc.translator.services.heattotosca.impl.ResourceTranslationCinderVolumeImpl; +import org.openecomp.sdc.translator.services.heattotosca.impl.ResourceTranslationContrailAttachPolicyImpl; +import org.openecomp.sdc.translator.services.heattotosca.impl.ResourceTranslationContrailNetworkPolicyImpl; +import org.openecomp.sdc.translator.services.heattotosca.impl.ResourceTranslationContrailServiceInstanceImpl; +import org.openecomp.sdc.translator.services.heattotosca.impl.ResourceTranslationContrailServiceTemplateImpl; +import org.openecomp.sdc.translator.services.heattotosca.impl.ResourceTranslationContrailV2NetworkPolicyImpl; +import org.openecomp.sdc.translator.services.heattotosca.impl.ResourceTranslationContrailV2VirtualNetworkImpl; +import org.openecomp.sdc.translator.services.heattotosca.impl.ResourceTranslationContrailV2VmInterfaceImpl; +import org.openecomp.sdc.translator.services.heattotosca.impl.ResourceTranslationContrailVirtualNetworkImpl; +import org.openecomp.sdc.translator.services.heattotosca.impl.ResourceTranslationDefaultImpl; +import org.openecomp.sdc.translator.services.heattotosca.impl.ResourceTranslationNestedImpl; +import org.openecomp.sdc.translator.services.heattotosca.impl.ResourceTranslationNeutronNetImpl; +import org.openecomp.sdc.translator.services.heattotosca.impl.ResourceTranslationNeutronPortImpl; +import org.openecomp.sdc.translator.services.heattotosca.impl.ResourceTranslationNeutronSecurityGroupImpl; +import org.openecomp.sdc.translator.services.heattotosca.impl.ResourceTranslationNeutronSubnetImpl; +import org.openecomp.sdc.translator.services.heattotosca.impl.ResourceTranslationNovaServerGroupsImpl; +import org.openecomp.sdc.translator.services.heattotosca.impl.ResourceTranslationNovaServerImpl; +import org.openecomp.sdc.translator.services.heattotosca.impl.ResourceTranslationResourceGroupImpl; + +import java.util.Objects; + +public class ResourceTranslationFactory { + + /** + * Gets instance. + * + * @param resource the resource + * @return the instance + */ + public static ResourceTranslationBase getInstance(Resource resource) { + HeatResourcesTypes heatResource = HeatResourcesTypes.findByHeatResource(resource.getType()); + if (Objects.isNull(heatResource)) { + if (HeatToToscaUtil.isYmlFileType(resource.getType())) { + return new ResourceTranslationNestedImpl(); + } + return new ResourceTranslationDefaultImpl(); + } + switch (heatResource) { + case NOVA_SERVER_RESOURCE_TYPE: + return new ResourceTranslationNovaServerImpl(); + case NOVA_SERVER_GROUP_RESOURCE_TYPE: + return new ResourceTranslationNovaServerGroupsImpl(); + case NEUTRON_SECURITY_GROUP_RESOURCE_TYPE: + return new ResourceTranslationNeutronSecurityGroupImpl(); + case NEUTRON_PORT_RESOURCE_TYPE: + return new ResourceTranslationNeutronPortImpl(); + case CONTRAIL_VIRTUAL_NETWORK_RESOURCE_TYPE: + return new ResourceTranslationContrailVirtualNetworkImpl(); + case CONTRAIL_V2_VIRTUAL_NETWORK_RESOURCE_TYPE: + return new ResourceTranslationContrailV2VirtualNetworkImpl(); + case CONTRAIL_V2_VIRTUAL_MACHINE_INTERFACE_RESOURCE_TYPE: + return new ResourceTranslationContrailV2VmInterfaceImpl(); + case CINDER_VOLUME_RESOURCE_TYPE: + return new ResourceTranslationCinderVolumeImpl(); + case CINDER_VOLUME_ATTACHMENT_RESOURCE_TYPE: + return new ResourceTranslationCinderVolumeAttachmentImpl(); + case NEUTRON_NET_RESOURCE_TYPE: + return new ResourceTranslationNeutronNetImpl(); + case NEUTRON_SUBNET_RESOURCE_TYPE: + return new ResourceTranslationNeutronSubnetImpl(); + case CONTRAIL_NETWORK_RULE_RESOURCE_TYPE: + return new ResourceTranslationContrailNetworkPolicyImpl(); + case CONTRAIL_V2_NETWORK_RULE_RESOURCE_TYPE: + return new ResourceTranslationContrailV2NetworkPolicyImpl(); + case CONTRAIL_NETWORK_ATTACH_RULE_RESOURCE_TYPE: + return new ResourceTranslationContrailAttachPolicyImpl(); + case RESOURCE_GROUP_RESOURCE_TYPE: + return new ResourceTranslationResourceGroupImpl(); + case CONTRAIL_SERVICE_TEMPLATE: + return new ResourceTranslationContrailServiceTemplateImpl(); + case CONTRAIL_SERVICE_INSTANCE: + return new ResourceTranslationContrailServiceInstanceImpl(); + default: + return new ResourceTranslationDefaultImpl(); + } + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/TranslationContext.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/TranslationContext.java new file mode 100644 index 0000000000..a242eda3f0 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/TranslationContext.java @@ -0,0 +1,172 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca; + +import org.openecomp.core.utilities.file.FileContentHandler; +import org.openecomp.core.utilities.file.FileUtils; +import org.openecomp.core.utilities.json.JsonUtil; +import org.openecomp.sdc.common.utils.AsdcCommon; +import org.openecomp.sdc.heat.datatypes.manifest.FileData; +import org.openecomp.sdc.heat.datatypes.manifest.ManifestFile; +import org.openecomp.sdc.heat.datatypes.model.Resource; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslatedHeatResource; +import org.openecomp.sdc.translator.services.heattotosca.globaltypes.GlobalTypesGenerator; + +import java.io.InputStream; +import java.util.HashMap; +import java.util.HashSet; +import java.util.Map; +import java.util.Set; + + +public class TranslationContext { + + + private static Map>> translationMapping; + private static Map globalServiceTemplates; + + static { + + String propertyFileName = AsdcCommon.HEAT_TO_TOSCA_MAPPING_CONF; + InputStream is = FileUtils.getFileInputStream(propertyFileName); + translationMapping = JsonUtil.json2Object(is, Map.class); + globalServiceTemplates = GlobalTypesGenerator.getGlobalTypesServiceTemplate(); + } + + private ManifestFile manifest; + + private FileContentHandler files = new FileContentHandler(); + + private Map manifestFiles = new HashMap<>(); + //Key - file name, value - file type + private Set nestedHeatsFiles = new HashSet<>(); + private FileContentHandler externalArtifacts = new FileContentHandler(); + + private Map> translatedResources = new HashMap<>(); + // Key - heat file name,value - set of heat resource ids which were translated + private Map> heatStackGroupMembers = new HashMap<>(); + // Key - heat file name, value - translated Node template id + private Map> translatedIds = new HashMap<>(); + // Key - heat file name, value - Map with Key - heat resource Id, Value - tosca entity template id + private Map translatedServiceTemplates = new HashMap<>(); + // key - service template type, value - translated service templates + private Map heatSharedResourcesByParam = new HashMap<>(); + //key - heat param name, value - shared resource data + + public void addManifestFile(String fileName, FileData.Type fileType) { + this.manifestFiles.put(fileName, fileType); + } + + public Set getNestedHeatsFiles() { + return nestedHeatsFiles; + } + + public Map> getHeatStackGroupMembers() { + return heatStackGroupMembers; + } + + public FileContentHandler getFiles() { + return files; + } + + public void setFiles(Map files) { + this.files.putAll(files); + } + + public InputStream getFileContent(String fileName) { + return files.getFileContent(fileName); + } + + public void addFile(String name, byte[] content) { + files.addFile(name, content); + } + + public ManifestFile getManifest() { + return manifest; + } + + public void setManifest(ManifestFile manifest) { + this.manifest = manifest; + } + + public Map> getTranslatedResources() { + return translatedResources; + } + + public Map> getTranslatedIds() { + return translatedIds; + } + + // get tosca name from mapping configuration file + //element type - parameter/attribute + // element name - heat parameter/attribute name + //return value - tosca parameter/attribute name + public String getElementMapping(String resourceType, String elementType, String elementName) { + return translationMapping.get(resourceType).get(elementType).get(elementName); + } + + public Map getElementMapping(String resourceType, String elementType) { + return translationMapping.get(resourceType).get(elementType); + } + + public Set getElementSet(String resourceType, String elementType) { + return translationMapping.get(resourceType).get(elementType).keySet(); + } + + public Map getTranslatedServiceTemplates() { + return translatedServiceTemplates; + } + + public ServiceTemplate getGlobalSubstitutionServiceTemplate() { + return getTranslatedServiceTemplates().get(Constants.GLOBAL_SUBSTITUTION_TYPES_TEMPLATE_NAME); + } + + public FileContentHandler getExternalArtifacts() { + return externalArtifacts; + } + + public void addExternalArtifacts(String name, byte[] content) { + this.externalArtifacts.addFile(name, content); + } + + + public Map getHeatSharedResourcesByParam() { + return heatSharedResourcesByParam; + } + + public void addHeatSharedResourcesByParam(String parameterName, String resourceId, + Resource resource) { + this.addHeatSharedResourcesByParam(parameterName, + new TranslatedHeatResource(resourceId, resource)); + } + + public void addHeatSharedResourcesByParam(String parameterName, + TranslatedHeatResource translatedHeatResource) { + this.heatSharedResourcesByParam.put(parameterName, translatedHeatResource); + } + + public Map getGlobalServiceTemplates() { + return globalServiceTemplates; + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/TranslationService.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/TranslationService.java new file mode 100644 index 0000000000..1d90d8b2af --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/TranslationService.java @@ -0,0 +1,344 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca; + +import org.openecomp.core.translator.datatypes.TranslatorOutput; +import org.openecomp.core.utilities.file.FileContentHandler; +import org.openecomp.core.utilities.file.FileUtils; +import org.openecomp.core.utilities.yaml.YamlUtil; +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.heat.datatypes.manifest.FileData; +import org.openecomp.sdc.heat.datatypes.model.Environment; +import org.openecomp.sdc.heat.datatypes.model.HeatOrchestrationTemplate; +import org.openecomp.sdc.heat.datatypes.model.Output; +import org.openecomp.sdc.heat.datatypes.model.Resource; +import org.openecomp.sdc.heat.datatypes.structure.ValidationStructureList; +import org.openecomp.sdc.heat.services.tree.HeatTreeManager; +import org.openecomp.sdc.heat.services.tree.HeatTreeManagerUtil; +import org.openecomp.sdc.tosca.datatypes.ToscaGroupType; +import org.openecomp.sdc.tosca.datatypes.ToscaServiceModel; +import org.openecomp.sdc.tosca.datatypes.model.GroupDefinition; +import org.openecomp.sdc.tosca.datatypes.model.Metadata; +import org.openecomp.sdc.tosca.datatypes.model.ParameterDefinition; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.datatypes.model.TopologyTemplate; +import org.openecomp.sdc.tosca.services.ToscaConstants; +import org.openecomp.sdc.tosca.services.ToscaFileOutputService; +import org.openecomp.sdc.tosca.services.ToscaUtil; +import org.openecomp.sdc.tosca.services.impl.ToscaFileOutputServiceCsarImpl; +import org.openecomp.sdc.translator.datatypes.heattotosca.AttachedResourceId; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.FileDataCollection; +import org.openecomp.sdc.translator.services.heattotosca.errors.ResourceNotFoundInHeatFileErrorBuilder; +import org.openecomp.sdc.translator.services.heattotosca.globaltypes.GlobalTypesGenerator; +import org.openecomp.sdc.translator.services.heattotosca.mapping.TranslatorHeatToToscaParameterConverter; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; + + +public class TranslationService { + + protected static Logger logger = LoggerFactory.getLogger(TranslationService.class); + + /** + * Gets types to process by translator. + * + * @return the types to process by translator + */ + public static Set getTypesToProcessByTranslator() { + Set types = new HashSet<>(); + types.add(FileData.Type.HEAT); + types.add(FileData.Type.HEAT_VOL); + return types; + } + + /** + * Translate heat files translator output. + * + * @param translationContext the translation context + * @return the translator output + */ + public TranslatorOutput translateHeatFiles(TranslationContext translationContext) { + ServiceTemplate mainServiceTemplate = createMainServiceTemplate(translationContext); + List fileDataList = translationContext.getManifest().getContent().getData(); + FileDataCollection fileDataCollection = HeatToToscaUtil.getFileCollectionsByFilter(fileDataList, + TranslationService.getTypesToProcessByTranslator(), translationContext); + + if (fileDataCollection.getBaseFile() != null) { + for (FileData fileData : fileDataCollection.getBaseFile()) { + translateHeatFile(mainServiceTemplate, fileData, translationContext); + } + } + if (fileDataCollection.getAddOnFiles() != null) { + for (FileData fileData : fileDataCollection.getAddOnFiles()) { + translateHeatFile(mainServiceTemplate, fileData, translationContext); + } + } + + ToscaServiceModel toscaServiceModel = + createToscaServiceModel(mainServiceTemplate, translationContext); + + TranslatorOutput translatorOutput = new TranslatorOutput(); + translatorOutput.setToscaServiceModel(toscaServiceModel); + return translatorOutput; + } + + private ToscaServiceModel createToscaServiceModel(ServiceTemplate entryDefinitionServiceTemplate, + TranslationContext translationContext) { + return new ToscaServiceModel(getCsarArtifactFiles(translationContext), + getServiceTemplates(translationContext), + ToscaUtil.getServiceTemplateFileName(entryDefinitionServiceTemplate)); + } + + private Map getServiceTemplates(TranslationContext translationContext) { + List serviceTemplates = new ArrayList<>(); + serviceTemplates.addAll(GlobalTypesGenerator.getGlobalTypesServiceTemplate().values()); + serviceTemplates.addAll(translationContext.getTranslatedServiceTemplates().values()); + Map serviceTemplatesMap = new HashMap<>(); + + for (ServiceTemplate template : serviceTemplates) { + serviceTemplatesMap.put(ToscaUtil.getServiceTemplateFileName(template), template); + } + return serviceTemplatesMap; + } + + private FileContentHandler getCsarArtifactFiles(TranslationContext translationContext) { + FileContentHandler artifactFiles = new FileContentHandler(); + artifactFiles.setFiles(translationContext.getFiles()); + artifactFiles.setFiles(translationContext.getExternalArtifacts()); + + HeatTreeManager heatTreeManager = + HeatTreeManagerUtil.initHeatTreeManager(translationContext.getFiles()); + heatTreeManager.createTree(); + ValidationStructureList validationStructureList = + new ValidationStructureList(heatTreeManager.getTree()); + byte[] validationStructureFile = + FileUtils.convertToBytes(validationStructureList, FileUtils.FileExtension.JSON); + artifactFiles.addFile("HEAT.meta", validationStructureFile); + + return artifactFiles; + } + + private ServiceTemplate createMainServiceTemplate(TranslationContext translationContext) { + ServiceTemplate mainServiceTemplate = new ServiceTemplate(); + translationContext.getTranslatedServiceTemplates().put("Main", mainServiceTemplate); + Metadata templateMetadata = new Metadata(); + templateMetadata.setTemplate_name("Main"); + mainServiceTemplate.setTosca_definitions_version(ToscaConstants.TOSCA_DEFINITIONS_VERSION); + mainServiceTemplate.setMetadata(templateMetadata); + mainServiceTemplate.setTopology_template(new TopologyTemplate()); + mainServiceTemplate.setImports(GlobalTypesGenerator.getGlobalTypesImportList()); + + return mainServiceTemplate; + } + + /** + * Translate heat file. + * + * @param serviceTemplate the service template + * @param heatFileData the heat file data + * @param context the context + */ + public void translateHeatFile(ServiceTemplate serviceTemplate, FileData heatFileData, + TranslationContext context) { + String heatFileName = heatFileData.getFile(); + HeatOrchestrationTemplate heatOrchestrationTemplate = new YamlUtil() + .yamlToObject(context.getFileContent(heatFileName), HeatOrchestrationTemplate.class); + + translateInputParameters(serviceTemplate, heatOrchestrationTemplate, heatFileData, context, + heatFileName); + translateResources(heatFileName, serviceTemplate, heatOrchestrationTemplate, context); + translateOutputParameters(serviceTemplate, heatOrchestrationTemplate, heatFileData, + heatFileName, context); + createHeatStackGroup(serviceTemplate, heatFileData, heatOrchestrationTemplate, context); + + if (Objects.nonNull(heatFileData.getData())) { + heatFileData.getData().stream().filter(data -> data.getType() == FileData.Type.HEAT_VOL) + .forEach(data -> translateHeatFile(serviceTemplate, data, context)); + } + } + + private void createHeatStackGroup(ServiceTemplate serviceTemplate, FileData heatFileData, + HeatOrchestrationTemplate heatOrchestrationTemplate, + TranslationContext context) { + ToscaFileOutputService toscaFileOutputService = new ToscaFileOutputServiceCsarImpl(); + String fileName = heatFileData.getFile(); + final String fileNameWoExtension = + FileUtils.getFileWithoutExtention(fileName);//.heatFileData.getFile().split("\\.")[0]; + + GroupDefinition groupDefinition = new GroupDefinition(); + groupDefinition.setType(ToscaGroupType.HEAT_STACK.getDisplayName()); + groupDefinition.setProperties(new HashMap<>()); + groupDefinition.getProperties() + .put("heat_file", "../" + toscaFileOutputService.getArtifactsFolderName() + "/" + fileName); + String hotDescription = heatOrchestrationTemplate.getDescription(); + if (hotDescription != null && !hotDescription.isEmpty()) { + groupDefinition.getProperties().put(Constants.DESCRIPTION_PROPERTY_NAME, hotDescription); + } + groupDefinition.setMembers(new ArrayList<>()); + Map> heatStackGroupMembers = context.getHeatStackGroupMembers(); + if (heatStackGroupMembers.get(fileName) == null) { + return; //not creating a group when no resources are present in the heat input + } + groupDefinition.getMembers().addAll(heatStackGroupMembers.get(fileName)); + if (serviceTemplate.getTopology_template().getGroups() == null) { + Map groups = new HashMap<>(); + serviceTemplate.getTopology_template().setGroups(groups); + } + serviceTemplate.getTopology_template().getGroups().put(fileNameWoExtension, groupDefinition); + } + + private void translateInputParameters(ServiceTemplate serviceTemplate, + HeatOrchestrationTemplate heatOrchestrationTemplate, + FileData heatFileData, TranslationContext context, + String heatFileName) { + + if (heatOrchestrationTemplate.getParameters() == null) { + return; + } + + Map parameterDefinitionMap = + TranslatorHeatToToscaParameterConverter + .parameterConverter(heatOrchestrationTemplate.getParameters(), + heatOrchestrationTemplate, heatFileName, context); + Environment heatEnvFile = getHeatEnvFile(heatFileData, context); + Map parameters = heatEnvFile.getParameters(); + Object parameterValue; + if (parameters != null) { + for (Map.Entry entry : parameterDefinitionMap.entrySet()) { + String paramName = entry.getKey(); + parameterValue = parameters.get(paramName); + if (parameterValue != null) { + entry.getValue().set_default(TranslatorHeatToToscaParameterConverter + .getToscaParameterDefaultValue(parameterValue, entry.getValue().getType(), + heatFileName, heatOrchestrationTemplate, context)); + } + } + } + + Map inputs = serviceTemplate.getTopology_template().getInputs(); + if (Objects.isNull(inputs)) { + serviceTemplate.getTopology_template().setInputs(parameterDefinitionMap); + } else { + inputs.putAll(parameterDefinitionMap); + } + } + + private void translateOutputParameters(ServiceTemplate serviceTemplate, + HeatOrchestrationTemplate heatOrchestrationTemplate, + FileData heatFileData, String heatFileName, + TranslationContext context) { + if (heatOrchestrationTemplate.getOutputs() == null) { + return; + } + Map parameterDefinitionMap = + TranslatorHeatToToscaParameterConverter + .parameterOutputConverter(heatOrchestrationTemplate.getOutputs(), + heatOrchestrationTemplate, heatFileName, context); + if (serviceTemplate.getTopology_template().getOutputs() != null) { + serviceTemplate.getTopology_template().getOutputs().putAll(parameterDefinitionMap); + } else { + serviceTemplate.getTopology_template().setOutputs(parameterDefinitionMap); + } + + if (heatFileData.getBase() != null && heatFileData.getBase().equals(true)) { + updateSharedResources(serviceTemplate, heatFileName, heatOrchestrationTemplate, + heatOrchestrationTemplate.getOutputs(), context); + } + } + + private void updateSharedResources(ServiceTemplate serviceTemplate, String heatFileName, + HeatOrchestrationTemplate heatOrchestrationTemplate, + Map outputs, TranslationContext context) { + for (Map.Entry paramName : outputs.entrySet()) { + Optional attachedSharedResourceId = HeatToToscaUtil + .extractAttachedResourceId(heatFileName, heatOrchestrationTemplate, context, + paramName.getValue().getValue()); + if (attachedSharedResourceId.isPresent() && attachedSharedResourceId.get().isGetResource() + && attachedSharedResourceId.get().getTranslatedId() != null) { + String sharedTranslatedResourceId = + attachedSharedResourceId.get().getTranslatedId().toString(); + updateSharedResource(serviceTemplate, context, paramName, sharedTranslatedResourceId, + heatOrchestrationTemplate.getResources() + .get(attachedSharedResourceId.get().getEntityId())); + } else { + String contrailSharedResourceId = HeatToToscaUtil + .extractContrailGetResourceAttachedHeatResourceId(paramName.getValue().getValue()); + if (contrailSharedResourceId != null + && context.getTranslatedIds().get(heatFileName).get(contrailSharedResourceId) != null) { + updateSharedResource(serviceTemplate, context, paramName, + context.getTranslatedIds().get(heatFileName).get(contrailSharedResourceId), + heatOrchestrationTemplate.getResources().get(contrailSharedResourceId)); + } + } + } + if (serviceTemplate.getTopology_template().getOutputs() != null + && serviceTemplate.getTopology_template().getOutputs().size() == 0) { + serviceTemplate.getTopology_template().setOutputs(null); + } + } + + private void updateSharedResource(ServiceTemplate serviceTemplate, TranslationContext context, + Map.Entry paramName, + String sharedTranslatedResourceId, Resource resource) { + context.addHeatSharedResourcesByParam(paramName.getKey(), sharedTranslatedResourceId, resource); + serviceTemplate.getTopology_template().getOutputs().remove(paramName.getKey()); + } + + private void translateResources(String heatFileName, ServiceTemplate serviceTemplate, + HeatOrchestrationTemplate heatOrchestrationTemplate, + TranslationContext context) { + for (String resourceId : heatOrchestrationTemplate.getResources().keySet()) { + Resource resource = heatOrchestrationTemplate.getResources().get(resourceId); + if (resource == null) { + throw new CoreException( + new ResourceNotFoundInHeatFileErrorBuilder(resourceId, heatFileName).build()); + } + ResourceTranslationFactory.getInstance(resource) + .translateResource(heatFileName, serviceTemplate, heatOrchestrationTemplate, resource, + resourceId, context); + } + } + + private Environment getHeatEnvFile(FileData heatFileData, TranslationContext context) { + List fileRelatedDataList = heatFileData.getData(); + if (fileRelatedDataList == null) { + return new Environment(); + } + for (FileData fileRelatedData : fileRelatedDataList) { + if (fileRelatedData.getType().equals(FileData.Type.HEAT_ENV)) { + return new YamlUtil().yamlToObject(context.getFileContent(fileRelatedData.getFile()), + Environment.class); + } + } + return new Environment(); + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/errors/IncorrectResourceReferenceErrorBuilder.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/errors/IncorrectResourceReferenceErrorBuilder.java new file mode 100644 index 0000000000..c713855f60 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/errors/IncorrectResourceReferenceErrorBuilder.java @@ -0,0 +1,51 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.errors; + +import org.openecomp.sdc.common.errors.BaseErrorBuilder; +import org.openecomp.sdc.common.errors.ErrorCategory; + +public class IncorrectResourceReferenceErrorBuilder extends BaseErrorBuilder { + + private static final String INCORRECT_RESOURCE_REFERENCE_MSG = + "resource id '%s' with type '%s' has reference to resource '%s' with" + + " type '%s' in property '%s'. Invalid type, resource type should be type of '%s'."; + + /** + * Instantiates a new Incorrect resource reference error builder. + * + * @param sourceResourceId the source resource id + * @param sourceResourceType the source resource type + * @param targetResourceId the target resource id + * @param targetResourceType the target resource type + * @param property the property + * @param validType the valid type + */ + public IncorrectResourceReferenceErrorBuilder(String sourceResourceId, String sourceResourceType, + String targetResourceId, String targetResourceType, + String property, String validType) { + getErrorCodeBuilder().withId(TranslatorErrorCodes.INCORRECT_RESOURCE_REFERENCE); + getErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION); + getErrorCodeBuilder().withMessage(String + .format(INCORRECT_RESOURCE_REFERENCE_MSG, sourceResourceId, sourceResourceType, + targetResourceId, targetResourceType, property, validType)); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/errors/InvalidPropertyValueErrorBuilder.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/errors/InvalidPropertyValueErrorBuilder.java new file mode 100644 index 0000000000..a16c341545 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/errors/InvalidPropertyValueErrorBuilder.java @@ -0,0 +1,47 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.errors; + +import org.openecomp.sdc.common.errors.BaseErrorBuilder; +import org.openecomp.sdc.common.errors.ErrorCategory; + + +public class InvalidPropertyValueErrorBuilder extends BaseErrorBuilder { + + private static final String INVALID_FILED_VALUE_MSG = + "'%s' property has invalid value. Actual value is '%s' while '%s' value expected."; + + /** + * Instantiates a new Invalid property value error builder. + * + * @param propertyName the property name + * @param actualValue the actual value + * @param expectedValue the expected value + */ + public InvalidPropertyValueErrorBuilder(String propertyName, String actualValue, + String expectedValue) { + getErrorCodeBuilder().withId(TranslatorErrorCodes.INVALID_PROPERTY_VALUE); + getErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION); + getErrorCodeBuilder().withMessage( + String.format(INVALID_FILED_VALUE_MSG, propertyName, actualValue, expectedValue)); + } + +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/errors/MissingMandatoryPropertyErrorBuilder.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/errors/MissingMandatoryPropertyErrorBuilder.java new file mode 100644 index 0000000000..6e06fef930 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/errors/MissingMandatoryPropertyErrorBuilder.java @@ -0,0 +1,43 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.errors; + +import org.openecomp.sdc.common.errors.BaseErrorBuilder; +import org.openecomp.sdc.common.errors.ErrorCategory; + + +public class MissingMandatoryPropertyErrorBuilder extends BaseErrorBuilder { + + private static final String MANDATORY_PROPERTY_IS_MISSING_MSG = + "Mandatory property '%s' is missing"; + + /** + * Instantiates a new Missing mandatory property error builder. + * + * @param propertyName the property name + */ + public MissingMandatoryPropertyErrorBuilder(String propertyName) { + getErrorCodeBuilder().withId(TranslatorErrorCodes.MISSING_MANDATORY_PROPERTY); + getErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION); + getErrorCodeBuilder() + .withMessage(String.format(MANDATORY_PROPERTY_IS_MISSING_MSG, propertyName)); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/errors/NotInSyncNumberOfInterfacesErrorBuilder.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/errors/NotInSyncNumberOfInterfacesErrorBuilder.java new file mode 100644 index 0000000000..810c09880e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/errors/NotInSyncNumberOfInterfacesErrorBuilder.java @@ -0,0 +1,44 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.errors; + +import org.openecomp.sdc.common.errors.BaseErrorBuilder; +import org.openecomp.sdc.common.errors.ErrorCategory; + + +public class NotInSyncNumberOfInterfacesErrorBuilder extends BaseErrorBuilder { + + private static final String NOT_IN_SYNC_NUMBER_OF_INTERFACES_MSG = + "More than one ServiceInstance pointing to the same " + + "ServiceTemplate '%s', with different number of interfaces."; + + /** + * Instantiates a new Not in sync number of interfaces error builder. + * + * @param serviceTemplateResourceId the service template resource id + */ + public NotInSyncNumberOfInterfacesErrorBuilder(String serviceTemplateResourceId) { + getErrorCodeBuilder().withId(TranslatorErrorCodes.NOT_IN_SYNC_NUMBER_OF_INTERFACES); + getErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION); + getErrorCodeBuilder().withMessage( + String.format(NOT_IN_SYNC_NUMBER_OF_INTERFACES_MSG, serviceTemplateResourceId)); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/errors/ReferenceToUnsupportedResourceErrorBuilder.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/errors/ReferenceToUnsupportedResourceErrorBuilder.java new file mode 100644 index 0000000000..5b48cb2c59 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/errors/ReferenceToUnsupportedResourceErrorBuilder.java @@ -0,0 +1,52 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.errors; + +import org.openecomp.sdc.common.errors.BaseErrorBuilder; +import org.openecomp.sdc.common.errors.ErrorCategory; + + +public class ReferenceToUnsupportedResourceErrorBuilder extends BaseErrorBuilder { + + private static final String REFERENCE_TO_UNSUPPORTED_RESOURCE_MSG = + "Resource id '%s' with type '%s' has reference to" + + " unsupported resource '%s' with type '%s' in property '%s'"; + + /** + * Instantiates a new Reference to unsupported resource error builder. + * + * @param sourceResourceId the source resource id + * @param sourceResourceType the source resource type + * @param targetResourceId the target resource id + * @param targetResourceType the target resource type + * @param property the property + */ + public ReferenceToUnsupportedResourceErrorBuilder(String sourceResourceId, + String sourceResourceType, + String targetResourceId, + String targetResourceType, String property) { + getErrorCodeBuilder().withId(TranslatorErrorCodes.REFERENCE_TO_UNSUPPORTED_RESOURCE); + getErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION); + getErrorCodeBuilder().withMessage(String + .format(REFERENCE_TO_UNSUPPORTED_RESOURCE_MSG, sourceResourceId, sourceResourceType, + targetResourceId, targetResourceType, property)); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/errors/ResourceNotFoundInHeatFileErrorBuilder.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/errors/ResourceNotFoundInHeatFileErrorBuilder.java new file mode 100644 index 0000000000..7fac501e76 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/errors/ResourceNotFoundInHeatFileErrorBuilder.java @@ -0,0 +1,52 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.errors; + +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; + +public class ResourceNotFoundInHeatFileErrorBuilder { + + private static final String RESOURCE_NOT_FOUND_IN_FILE_ERR_ID = + "RESOURCE_NOT_FOUND_IN_FILE_ERR_ID"; + private static final String RESOURCE_NOT_FOUND_IN_FILE_ERR_MSG = + "resource with id = %s was not found in heat file = %s."; + + private final ErrorCode.ErrorCodeBuilder builder = new ErrorCode.ErrorCodeBuilder(); + + /** + * Instantiates a new Resource not found in heat file error builder. + * + * @param resourceId the resource id + * @param heatfileName the heatfile name + */ + public ResourceNotFoundInHeatFileErrorBuilder(String resourceId, String heatfileName) { + builder.withId(RESOURCE_NOT_FOUND_IN_FILE_ERR_ID); + builder.withCategory(ErrorCategory.APPLICATION); + builder + .withMessage(String.format(RESOURCE_NOT_FOUND_IN_FILE_ERR_MSG, resourceId, heatfileName)); + } + + public ErrorCode build() { + return builder.build(); + } + +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/errors/TranslatorErrorCodes.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/errors/TranslatorErrorCodes.java new file mode 100644 index 0000000000..f9b873adca --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/errors/TranslatorErrorCodes.java @@ -0,0 +1,31 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.errors; + +public class TranslatorErrorCodes { + public static final String MISSING_MANDATORY_PROPERTY = "MISSING_MANDATORY_PROPERTY"; + public static final String HEAT_TO_TOSCA_MAPPING_COLLISION = "HEAT_TO_TOSCA_MAPPING_COLLISION"; + public static final String INCORRECT_RESOURCE_REFERENCE = "INCORRECT_RESOURCE_REFERENCE"; + public static final String REFERENCE_TO_UNSUPPORTED_RESOURCE = + "REFERENCE_TO_UNSUPPORTED_RESOURCE"; + public static final String NOT_IN_SYNC_NUMBER_OF_INTERFACES = "NOT_IN_SYNC_NUMBER_OF_INTERFACES"; + public static final String INVALID_PROPERTY_VALUE = "INVALID_PROPERTY_VALUE"; +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/AbstractSubstituteGlobalType.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/AbstractSubstituteGlobalType.java new file mode 100644 index 0000000000..221a9e522b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/AbstractSubstituteGlobalType.java @@ -0,0 +1,167 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.globaltypes; + +import org.openecomp.sdc.tosca.datatypes.ToscaDataType; +import org.openecomp.sdc.tosca.datatypes.ToscaNodeType; +import org.openecomp.sdc.tosca.datatypes.model.Constraint; +import org.openecomp.sdc.tosca.datatypes.model.DataType; +import org.openecomp.sdc.tosca.datatypes.model.NodeType; +import org.openecomp.sdc.tosca.datatypes.model.PropertyDefinition; +import org.openecomp.sdc.tosca.datatypes.model.PropertyType; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.tosca.services.ToscaConstants; +import org.openecomp.sdc.translator.services.heattotosca.Constants; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + + +public class AbstractSubstituteGlobalType { + + private AbstractSubstituteGlobalType() { + } + + /** + * Create service template service template. + * + * @return the service template + */ + public static ServiceTemplate createServiceTemplate() { + ServiceTemplate serviceTemplate = new ServiceTemplate(); + serviceTemplate.setTosca_definitions_version(ToscaConstants.TOSCA_DEFINITIONS_VERSION); + serviceTemplate.setMetadata( + DataModelUtil.createMetadata(Constants.ABSTRACT_SUBSTITUTE_TEMPLATE_NAME, "1.0.0", null)); + serviceTemplate.setImports(GlobalTypesUtil.createCommonImportList()); + serviceTemplate.setDescription("Abstract Substitute Global Types"); + serviceTemplate.setData_types(createGlobalDataTypes()); + serviceTemplate.setNode_types(createGlobalNodeTypes()); + return serviceTemplate; + } + + private static Map createGlobalNodeTypes() { + Map globalNodeTypes = new HashMap<>(); + globalNodeTypes.put(ToscaNodeType.ABSTRACT_SUBSTITUTE.getDisplayName(), + createAbstractSubstituteNodeType()); + return globalNodeTypes; + } + + private static NodeType createAbstractSubstituteNodeType() { + NodeType nodeType = new NodeType(); + nodeType.setDerived_from(ToscaNodeType.ROOT.getDisplayName()); + nodeType.setProperties(createAbstractSubstituteProperties()); + return nodeType; + } + + private static Map createAbstractSubstituteProperties() { + Map props = new HashMap<>(); + props.put(ToscaConstants.SERVICE_TEMPLATE_FILTER_PROPERTY_NAME, DataModelUtil + .createPropertyDefinition(ToscaDataType.SUBSTITUTION_FILTERING.getDisplayName(), + "Substitution Filter", true, null, null, null, null)); + + return props; + } + + + private static Map createGlobalDataTypes() { + Map globalDataTypes = new HashMap<>(); + globalDataTypes.put(ToscaDataType.SUBSTITUTION_FILTER.getDisplayName(), + createSubstitutionFilterDataType()); + globalDataTypes.put(ToscaDataType.SUBSTITUTION_FILTERING.getDisplayName(), + createSubstitutionFilteringDataType()); + return globalDataTypes; + } + + private static DataType createSubstitutionFilterDataType() { + DataType dataType = new DataType(); + dataType.setDerived_from(ToscaDataType.ROOT.getDisplayName()); + dataType.setDescription("Substitution Filter"); + Map properties = new HashMap<>(); + properties.put(ToscaConstants.COUNT_PROPERTY_NAME, DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Count", false, null, null, + null, 1)); + properties.put(ToscaConstants.SCALING_ENABLED_PROPERTY_NAME, DataModelUtil + .createPropertyDefinition(PropertyType.BOOLEAN.getDisplayName(), + "Indicates whether service scaling is enabled", false, null, null, null, true)); + properties.put(ToscaConstants.SUBSTITUTE_SERVICE_TEMPLATE_PROPERTY_NAME, DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "Substitute Service Template", true, null, null, null, null)); + properties.put("mandatory", DataModelUtil + .createPropertyDefinition(PropertyType.BOOLEAN.getDisplayName(), "Mandatory", false, null, + null, null, true)); + properties.put("index_variable", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Index variable", false, + createMinLengthConstraint(), null, null, "%index%")); + + dataType.setProperties(properties); + return dataType; + } + + private static List createMinLengthConstraint() { + List constraints; + constraints = new ArrayList<>(); + Constraint constraint = new Constraint(); + constraint.setMin_length(3); + constraints.add(constraint); + return constraints; + } + + private static DataType createSubstitutionFilteringDataType() { + DataType dataType = new DataType(); + dataType.setDerived_from(ToscaDataType.ROOT.getDisplayName()); + dataType.setDescription("Substitution Filter"); + Map properties = new HashMap<>(); + properties.put(ToscaConstants.COUNT_PROPERTY_NAME, DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Count", false, null, null, + null, 1)); + properties.put(ToscaConstants.INDEX_VALUE_PROPERTY_NAME, DataModelUtil + .createPropertyDefinition(PropertyType.INTEGER.getDisplayName(), + "Index value of the substitution service template runtime instance", false, + createIndexValueConstraint(), null, null, 0)); + properties.put(ToscaConstants.SCALING_ENABLED_PROPERTY_NAME, DataModelUtil + .createPropertyDefinition(PropertyType.BOOLEAN.getDisplayName(), + "Indicates whether service scaling is enabled", false, null, null, null, true)); + properties.put(ToscaConstants.SUBSTITUTE_SERVICE_TEMPLATE_PROPERTY_NAME, DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "Substitute Service Template", true, null, null, null, null)); + properties.put("mandatory", DataModelUtil + .createPropertyDefinition(PropertyType.BOOLEAN.getDisplayName(), "Mandatory", false, null, + null, null, true)); + + + dataType.setProperties(properties); + return dataType; + } + + private static List createIndexValueConstraint() { + List constraints; + constraints = new ArrayList<>(); + Constraint constraint = new Constraint(); + constraint.setGreater_or_equal(0); + constraints.add(constraint); + return constraints; + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/CinderVolumeGlobalType.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/CinderVolumeGlobalType.java new file mode 100644 index 0000000000..72f3043225 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/CinderVolumeGlobalType.java @@ -0,0 +1,242 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.globaltypes; + +import org.openecomp.sdc.tosca.datatypes.ToscaNodeType; +import org.openecomp.sdc.tosca.datatypes.ToscaRelationshipType; +import org.openecomp.sdc.tosca.datatypes.model.AttributeDefinition; +import org.openecomp.sdc.tosca.datatypes.model.Constraint; +import org.openecomp.sdc.tosca.datatypes.model.NodeType; +import org.openecomp.sdc.tosca.datatypes.model.PropertyDefinition; +import org.openecomp.sdc.tosca.datatypes.model.PropertyType; +import org.openecomp.sdc.tosca.datatypes.model.RelationshipType; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.tosca.services.ToscaConstants; +import org.openecomp.sdc.translator.services.heattotosca.Constants; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +public class CinderVolumeGlobalType { + + /** + * Create service template service template. + * + * @return the service template + */ + public static ServiceTemplate createServiceTemplate() { + ServiceTemplate cinderVolumeServiceTemplate = new ServiceTemplate(); + cinderVolumeServiceTemplate + .setTosca_definitions_version(ToscaConstants.TOSCA_DEFINITIONS_VERSION); + cinderVolumeServiceTemplate.setMetadata( + DataModelUtil.createMetadata(Constants.CINDER_VOLUME_TEMPLATE_NAME, "1.0.0", null)); + cinderVolumeServiceTemplate.setDescription("Cinder Volume TOSCA Global Types"); + cinderVolumeServiceTemplate.setRelationship_types(createGlobalRelationshipTypes()); + cinderVolumeServiceTemplate.setNode_types(createGlobalNodeTypes()); + return cinderVolumeServiceTemplate; + } + + private static Map createGlobalNodeTypes() { + Map globalNodeTypes = new HashMap<>(); + globalNodeTypes.put(ToscaNodeType.CINDER_VOLUME.getDisplayName(), createCinderVolumeNodeType()); + return globalNodeTypes; + } + + private static NodeType createCinderVolumeNodeType() { + NodeType cinderVolumeNodeType = new NodeType(); + cinderVolumeNodeType.setDerived_from(ToscaNodeType.BLOCK_STORAGE.getDisplayName()); + cinderVolumeNodeType.setProperties(createCinderVolumeProperties()); + cinderVolumeNodeType.setAttributes(createCinderVolumeAttributes()); + return cinderVolumeNodeType; + } + + private static Map createGlobalRelationshipTypes() { + Map globalRelationshipTypes = new HashMap<>(); + globalRelationshipTypes.put(ToscaRelationshipType.CINDER_VOLUME_ATTACHES_TO.getDisplayName(), + createCinderVolumeAttachesToRelationshipType()); + return globalRelationshipTypes; + } + + private static RelationshipType createCinderVolumeAttachesToRelationshipType() { + RelationshipType cinderVolumeAttachesToRelationType = new RelationshipType(); + cinderVolumeAttachesToRelationType + .setDerived_from(ToscaRelationshipType.NATIVE_ATTACHES_TO.getDisplayName()); + cinderVolumeAttachesToRelationType + .setDescription("This type represents an attachment relationship for associating volume"); + + Map cinderVolumeAttachesToProps = new HashMap<>(); + cinderVolumeAttachesToProps.put("location", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "The location where the volume is exposed on the instance, mountpoint", false, null, + null, null, null)); //overridden location prop from attachesTo + cinderVolumeAttachesToProps.put("instance_uuid", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "The ID of the server to which the volume attaches", true, null, null, null, null)); + cinderVolumeAttachesToProps.put("volume_id", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "The ID of the volume to be attached", true, null, null, null, null)); + cinderVolumeAttachesToRelationType.setProperties(cinderVolumeAttachesToProps); + + Map cinderVolumeAttachesToAttributes = new HashMap<>(); + cinderVolumeAttachesToAttributes.put("show", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), + "Detailed information about resource", null, null, null)); + cinderVolumeAttachesToRelationType.setAttributes(cinderVolumeAttachesToAttributes); + + return cinderVolumeAttachesToRelationType; + } + + private static Map createCinderVolumeProperties() { + Map cinderVolumePropertyDefMap = new HashMap<>(); + cinderVolumePropertyDefMap.put("availability_zone", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "The availability zone in which the volume will be created", false, null, null, null, + null)); + cinderVolumePropertyDefMap.put("backup_id", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "If specified, the backup to create the volume from", false, null, null, null, null)); + cinderVolumePropertyDefMap.put(Constants.DESCRIPTION_PROPERTY_NAME, DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "A description of the volume", false, null, null, null, null)); + cinderVolumePropertyDefMap.put("image", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "If specified, the name or ID of the image to create the volume from", false, null, + null, null, null)); + cinderVolumePropertyDefMap.put("metadata", DataModelUtil + .createPropertyDefinition(PropertyType.MAP.getDisplayName(), + "Key/value pairs to associate with the volume", false, null, null, + DataModelUtil.createEntrySchema(PropertyType.STRING.getDisplayName(), null, null), + null)); + cinderVolumePropertyDefMap.put("multiattach", DataModelUtil + .createPropertyDefinition(PropertyType.BOOLEAN.getDisplayName(), + "Whether allow the volume to be attached more than once", false, null, null, null, + null)); + cinderVolumePropertyDefMap.put(Constants.NAME_PROPERTY_NAME, DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "A name used to distinguish the volume", false, null, null, null, null)); + cinderVolumePropertyDefMap.put("read_only", DataModelUtil + .createPropertyDefinition(PropertyType.BOOLEAN.getDisplayName(), + "Enables or disables read-only access mode of volume", false, null, null, null, null)); + cinderVolumePropertyDefMap.put("scheduler_hints", DataModelUtil + .createPropertyDefinition(PropertyType.MAP.getDisplayName(), + "Arbitrary key-value pairs specified by the client " + + "to help the Cinder scheduler creating a volume", + false, null, null, + DataModelUtil.createEntrySchema(PropertyType.STRING.getDisplayName(), null, null), + null)); + cinderVolumePropertyDefMap.put("size", DataModelUtil + .createPropertyDefinition(PropertyType.SCALAR_UNIT_SIZE.getDisplayName(), + "The requested storage size (default unit is MB)", false, getSizeConstraints(), null, + null, null)); + cinderVolumePropertyDefMap.put("source_volid", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "If specified, the volume to use as source", false, null, null, null, null)); + cinderVolumePropertyDefMap.put("volume_type", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "If specified, the type of volume to use, mapping to a specific backend", false, null, + null, null, null)); + cinderVolumePropertyDefMap.put("delete_on_termination", DataModelUtil + .createPropertyDefinition(PropertyType.BOOLEAN.getDisplayName(), + "Indicate whether the volume should be deleted when the server is terminated", false, + null, null, null, null)); + cinderVolumePropertyDefMap.put("boot_index", DataModelUtil + .createPropertyDefinition(PropertyType.INTEGER.getDisplayName(), + "Integer used for ordering the boot disks", false, null, null, null, null)); + cinderVolumePropertyDefMap.put("device_type", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Device type", false, + getDeviceTypeConstraints(), null, null, null)); + cinderVolumePropertyDefMap.put("disk_bus", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "Bus of the device: hypervisor driver chooses a suitable default if omitted", false, + getDiskBusConstraints(), null, null, null)); + cinderVolumePropertyDefMap.put("swap_size", DataModelUtil + .createPropertyDefinition(PropertyType.SCALAR_UNIT_SIZE.getDisplayName(), + "The size of the swap, in MB", false, null, null, null, null)); + + return cinderVolumePropertyDefMap; + } + + private static Map createCinderVolumeAttributes() { + Map cinderVolumeAttributesDefMap = new HashMap<>(); + cinderVolumeAttributesDefMap.put("attachments", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), + "The list of attachments of the volume", null, + DataModelUtil.createEntrySchema(PropertyType.STRING.getDisplayName(), null, null), + null)); + cinderVolumeAttributesDefMap.put("bootable", DataModelUtil + .createAttributeDefinition(PropertyType.BOOLEAN.getDisplayName(), + "Boolean indicating if the volume can be booted or not", null, null, null)); + cinderVolumeAttributesDefMap.put("created_at", DataModelUtil + .createAttributeDefinition(PropertyType.TIMESTAMP.getDisplayName(), + "The timestamp indicating volume creation", null, null, null)); + cinderVolumeAttributesDefMap.put("display_description", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), + "Description of the volume", null, null, null)); + cinderVolumeAttributesDefMap.put("display_name", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), "Name of the volume", null, + null, null)); + cinderVolumeAttributesDefMap.put("encrypted", DataModelUtil + .createAttributeDefinition(PropertyType.BOOLEAN.getDisplayName(), + "Boolean indicating if the volume is encrypted or not", null, null, null)); + cinderVolumeAttributesDefMap.put("metadata_values", DataModelUtil + .createAttributeDefinition(PropertyType.MAP.getDisplayName(), + "Key/value pairs associated with the volume in raw dict form", null, + DataModelUtil.createEntrySchema(PropertyType.STRING.getDisplayName(), null, null), + null)); + cinderVolumeAttributesDefMap.put("show", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), + "Detailed information about resource", null, null, null)); + cinderVolumeAttributesDefMap.put("status", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), + "The current status of the volume", null, null, null)); + return cinderVolumeAttributesDefMap; + } + + private static List getDeviceTypeConstraints() { + Constraint validValues; + List constraints = new ArrayList<>(); + validValues = DataModelUtil.createValidValuesConstraint("cdrom", "disk"); + constraints.add(validValues); + return constraints; + } + + private static List getDiskBusConstraints() { + Constraint validValues; + List constraints = new ArrayList<>(); + validValues = + DataModelUtil.createValidValuesConstraint("ide", "lame_bus", "scsi", "usb", "virtio"); + constraints.add(validValues); + return constraints; + } + + + private static List getSizeConstraints() { + List constraints; + constraints = new ArrayList<>(); + Constraint constraint = new Constraint(); + constraint.setGreater_or_equal("1 GB"); + constraints.add(constraint); + return constraints; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/CommonGlobalTypes.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/CommonGlobalTypes.java new file mode 100644 index 0000000000..43a4782149 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/CommonGlobalTypes.java @@ -0,0 +1,500 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.globaltypes; + + +import org.openecomp.sdc.tosca.datatypes.ToscaCapabilityType; +import org.openecomp.sdc.tosca.datatypes.ToscaDataType; +import org.openecomp.sdc.tosca.datatypes.ToscaGroupType; +import org.openecomp.sdc.tosca.datatypes.ToscaPolicyType; +import org.openecomp.sdc.tosca.datatypes.ToscaRelationshipType; +import org.openecomp.sdc.tosca.datatypes.model.AttributeDefinition; +import org.openecomp.sdc.tosca.datatypes.model.CapabilityType; +import org.openecomp.sdc.tosca.datatypes.model.Constraint; +import org.openecomp.sdc.tosca.datatypes.model.DataType; +import org.openecomp.sdc.tosca.datatypes.model.GroupType; +import org.openecomp.sdc.tosca.datatypes.model.Import; +import org.openecomp.sdc.tosca.datatypes.model.PolicyType; +import org.openecomp.sdc.tosca.datatypes.model.PropertyDefinition; +import org.openecomp.sdc.tosca.datatypes.model.PropertyType; +import org.openecomp.sdc.tosca.datatypes.model.RelationshipType; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.tosca.services.ToscaConstants; +import org.openecomp.sdc.tosca.services.ToscaUtil; +import org.openecomp.sdc.translator.services.heattotosca.Constants; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +public class CommonGlobalTypes { + + /** + * Create service template service template. + * + * @return the service template + */ + public static ServiceTemplate createServiceTemplate() { + ServiceTemplate serviceTemplate = new ServiceTemplate(); + serviceTemplate.setTosca_definitions_version(ToscaConstants.TOSCA_DEFINITIONS_VERSION); + serviceTemplate.setMetadata( + DataModelUtil.createMetadata(Constants.COMMON_GLOBAL_TEMPLATE_NAME, "1.0.0", null)); + serviceTemplate.setDescription("TOSCA Global Types"); + serviceTemplate.setData_types(createGlobalDataTypes()); + serviceTemplate.setGroup_types(createGroupTypes()); + serviceTemplate.setPolicy_types(createPolicyTypes()); + serviceTemplate.setRelationship_types(createRelationTypes()); + serviceTemplate.setCapability_types(createCapabilityTypes()); + serviceTemplate.setImports(createImportList()); + return serviceTemplate; + } + + private static Map createCapabilityTypes() { + Map capabilityMap = new HashMap<>(); + capabilityMap.put(ToscaCapabilityType.METRIC.getDisplayName(), createMetricCapabilityType()); + capabilityMap + .put(ToscaCapabilityType.METRIC_CEILOMETER.getDisplayName(), createMetricCeilometerType()); + capabilityMap.put(ToscaCapabilityType.METRIC_SNMP_TRAP.getDisplayName(), createMetricSnmpType( + "A node type that includes the Metric capability" + + " indicates that it can be monitored using snmp trap.")); + capabilityMap.put(ToscaCapabilityType.METRIC_SNMP_POLLING.getDisplayName(), + createMetricSnmpType( + "A node type that includes the Metric capability indicates" + + " that it can be monitored using snmp polling.")); + return capabilityMap; + } + + + private static CapabilityType createMetricSnmpType(String description) { + CapabilityType capabilityType = new CapabilityType(); + capabilityType.setDerived_from(ToscaCapabilityType.METRIC.getDisplayName()); + capabilityType.setDescription(description); + capabilityType.setProperties(createCapabilityMetricSnmpProperties()); + + return capabilityType; + } + + + private static Map createCapabilityMetricSnmpProperties() { + Map propertyDefinitionMap = new HashMap<>(); + propertyDefinitionMap.put("oid", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Object Id of the metric", + true, null, null, null, null)); + return propertyDefinitionMap; + } + + private static CapabilityType createMetricCeilometerType() { + CapabilityType capabilityType = new CapabilityType(); + capabilityType.setDerived_from(ToscaCapabilityType.METRIC.getDisplayName()); + capabilityType.setDescription( + "A node type that includes the Metric capability" + + " indicates that it can be monitored using ceilometer."); + capabilityType.setProperties(createCapabilityMetricCeilometerProperties()); + return capabilityType; + } + + + private static Map createCapabilityMetricCeilometerProperties() { + Map propertyDefinitionMap = new HashMap<>(); + propertyDefinitionMap.put(Constants.NAME_PROPERTY_NAME, DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "Ceilometer metric type name to monitor. (The name ceilometer is using)", true, null, + null, null, null)); + return propertyDefinitionMap; + } + + private static Map createImportList() { + Map importsMap = new HashMap<>(); + importsMap.put(ToscaConstants.NATIVE_TYPES_SERVICE_TEMPLATE_NAME, GlobalTypesUtil + .createServiceTemplateImport(ToscaConstants.NATIVE_TYPES_SERVICE_TEMPLATE_NAME)); + return importsMap; + } + + /** + * Create metric capability type capability type. + * + * @return the capability type + */ + public static CapabilityType createMetricCapabilityType() { + CapabilityType capabilityType = new CapabilityType(); + capabilityType.setDerived_from(ToscaCapabilityType.NFV_METRIC.getDisplayName()); + capabilityType.setDescription( + "A node type that includes the Metric capability indicates that it can be monitored."); + capabilityType.setProperties(createCapabilityMetricProperties()); + capabilityType.setAttributes(createCapabilityMetricAttributes()); + return capabilityType; + } + + private static Map createCapabilityMetricAttributes() { + Map attributeDefinitionMap = new HashMap<>(); + + attributeDefinitionMap.put("value", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), "Runtime monitored value", + null, null, null)); + return attributeDefinitionMap; + } + + private static Map createCapabilityMetricProperties() { + Map propertyDefinitionMap = new HashMap<>(); + propertyDefinitionMap.put("type", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "Type of the metric value, for an example, Cumulative, Delta, Gauge and etc.", true, + null, null, null, null)); + propertyDefinitionMap.put("unit", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Unit of the metric value", + true, null, null, null, null)); + propertyDefinitionMap.put("category", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "Category of the metric, for an example, compute, disk, network, storage and etc.", + false, null, null, null, null)); + propertyDefinitionMap.put(Constants.DESCRIPTION_PROPERTY_NAME, DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Description of the metric", + false, null, null, null, null)); + return propertyDefinitionMap; + } + + private static Map createRelationTypes() { + Map globalRelationshipTypes = new HashMap<>(); + globalRelationshipTypes.put(ToscaRelationshipType.ATTACHES_TO.getDisplayName(), + createAttachesToRelationshipType()); + return globalRelationshipTypes; + } + + private static RelationshipType createAttachesToRelationshipType() { + RelationshipType attachesToRelationType = new RelationshipType(); + attachesToRelationType.setDerived_from(ToscaRelationshipType.ROOT.getDisplayName()); + attachesToRelationType.setDescription("This type represents an attachment relationship"); + return attachesToRelationType; + } + + private static Map createPolicyTypes() { + Map globalPolicyTypes = new HashMap<>(); + globalPolicyTypes + .put(ToscaPolicyType.PLACEMENT_ANTILOCATE.getDisplayName(), createAntilocatePolicyType()); + globalPolicyTypes + .put(ToscaPolicyType.PLACEMENT_COLOCATE.getDisplayName(), createColocatePolicyType()); + globalPolicyTypes.put(ToscaPolicyType.PLACEMENT_VALET_AFFINITY.getDisplayName(), + createValetAffinityPolicyType()); + globalPolicyTypes.put(ToscaPolicyType.PLACEMENT_VALET_DIVERSITY.getDisplayName(), + createValetDiversityPolicyType()); + globalPolicyTypes.put(ToscaPolicyType.PLACEMENT_VALET_EXCLUSIVITY.getDisplayName(), + createValetExclusivityPolicyType()); + return globalPolicyTypes; + } + + private static PolicyType createValetDiversityPolicyType() { + PolicyType policyType = new PolicyType(); + policyType.setDerived_from(ToscaPolicyType.PLACEMENT.getDisplayName()); + policyType.setDescription("Valet Diversity"); + policyType.setProperties(new HashMap<>()); + policyType.getProperties().put("level", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "diversity", false, + DataModelUtil.createValidValuesConstraintsList("host", "rack"), null, null, "host")); + + return policyType; + } + + private static PolicyType createValetExclusivityPolicyType() { + PolicyType policyType = new PolicyType(); + policyType.setDerived_from(ToscaPolicyType.PLACEMENT.getDisplayName()); + policyType.setDescription("Valet Exclusivity"); + policyType.setProperties(addNamePropertyToPolicyType()); + policyType.setProperties(new HashMap<>()); + policyType.getProperties().put("level", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "exclusivity", false, + DataModelUtil.createValidValuesConstraintsList("host", "rack"), null, null, "host")); + return policyType; + } + + private static PolicyType createValetAffinityPolicyType() { + PolicyType policyType = new PolicyType(); + policyType.setDerived_from(ToscaPolicyType.PLACEMENT.getDisplayName()); + policyType.setDescription("Valet Affinity"); + policyType.setProperties(new HashMap<>()); + policyType.getProperties().put("level", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "affinity", false, + DataModelUtil.createValidValuesConstraintsList("host", "rack"), null, null, "host")); + + return policyType; + } + + + private static PolicyType createColocatePolicyType() { + PolicyType policyType = new PolicyType(); + policyType.setDerived_from(ToscaPolicyType.PLACEMENT.getDisplayName()); + policyType.setDescription("Keep associated nodes (groups of nodes) based upon affinity value"); + policyType.setProperties(addNamePropertyToPolicyType()); + policyType.getProperties().put("affinity", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "affinity", true, + DataModelUtil.createValidValuesConstraintsList("host", "region", "compute"), null, null, + null)); + + return policyType; + } + + private static PolicyType createAntilocatePolicyType() { + PolicyType policyType = new PolicyType(); + policyType.setDerived_from(ToscaPolicyType.PLACEMENT.getDisplayName()); + policyType.setDescription("My placement policy for separation based upon container type value"); + policyType.setProperties(addNamePropertyToPolicyType()); + policyType.getProperties().put("container_type", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "container type", false, + DataModelUtil.createValidValuesConstraintsList("host", "region", "compute"), null, null, + null)); + return policyType; + } + + private static Map addNamePropertyToPolicyType() { + Map policyTypeProperties = new HashMap<>(); + policyTypeProperties.put(Constants.NAME_PROPERTY_NAME, DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "The name of the policy", + false, null, null, null, null)); + return policyTypeProperties; + } + + private static Map createGroupTypes() { + Map globalGroupTypes = new HashMap<>(); + globalGroupTypes.put(ToscaGroupType.HEAT_STACK.getDisplayName(), createHeatStackGroupType()); + return globalGroupTypes; + } + + private static GroupType createHeatStackGroupType() { + GroupType heatStackGroupType = new GroupType(); + heatStackGroupType.setDerived_from(ToscaGroupType.ROOT.getDisplayName()); + heatStackGroupType + .setDescription("Grouped all heat resources which are in the same heat stack"); + heatStackGroupType.setProperties(createHeatStackGroupProperties()); + + return heatStackGroupType; + } + + private static Map createHeatStackGroupProperties() { + Map propertiesDef = new HashMap<>(); + propertiesDef.put("heat_file", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "Heat file which associate to this group/heat stack", true, null, null, null, null)); + propertiesDef.put(Constants.DESCRIPTION_PROPERTY_NAME, DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Heat file description", + false, null, null, null, null)); + return propertiesDef; + } + + + /** + * Create common service template import import. + * + * @return the import + */ + public static Import createCommonServiceTemplateImport() { + Import commonServiceTemplateImport = new Import(); + commonServiceTemplateImport + .setFile(ToscaUtil.getServiceTemplateFileName(Constants.COMMON_GLOBAL_TEMPLATE_NAME)); + return commonServiceTemplateImport; + } + + private static Map createGlobalDataTypes() { + Map globalDataTypes = new HashMap<>(); + globalDataTypes.put(ToscaDataType.NETWORK_ALLOCATION_POOL.getDisplayName(), + createAllocationPoolDataType()); + globalDataTypes + .put(ToscaDataType.NETWORK_HOST_ROUTE.getDisplayName(), createHostRouteDataType()); + globalDataTypes.put(ToscaDataType.NEUTRON_SUBNET.getDisplayName(), createSubnetDataType()); + globalDataTypes + .put(ToscaDataType.NETWORK_ADDRESS_PAIR.getDisplayName(), createAddressPairDataType()); + globalDataTypes.put(ToscaDataType.CONTRAIL_STATIC_ROUTE.getDisplayName(), + createContrailStaticRouteDataType()); + globalDataTypes.put(ToscaDataType.CONTRAIL_ADDRESS_PAIR.getDisplayName(), + createContrailAddressPairDataType()); + return globalDataTypes; + } + + private static DataType createContrailStaticRouteDataType() { + DataType dataType = new DataType(); + dataType.setDerived_from(ToscaDataType.ROOT.getDisplayName()); + dataType.setDescription("static route"); + Map prop = new HashMap<>(); + + prop.put("prefix", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Route prefix", false, null, + null, null, null)); + prop.put("next_hop", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Next hop", false, null, + null, null, null)); + prop.put("next_hop_type", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Next hop type", false, + null, null, null, null)); + + dataType.setProperties(prop); + return dataType; + } + + private static DataType createContrailAddressPairDataType() { + DataType dataType = new DataType(); + dataType.setDerived_from(ToscaDataType.ROOT.getDisplayName()); + dataType.setDescription("Address Pair"); + Map prop = new HashMap<>(); + + prop.put("prefix", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "IP address prefix", false, + null, null, null, null)); + prop.put("mac_address", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Mac address", false, null, + null, null, null)); + prop.put("address_mode", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "Address mode active-active or active-standy", false, + DataModelUtil.createValidValuesConstraintsList("active-active", "active-standby"), null, + null, null)); + + dataType.setProperties(prop); + return dataType; + } + + private static DataType createAddressPairDataType() { + DataType addressPairDataType = new DataType(); + addressPairDataType.setDerived_from(ToscaDataType.ROOT.getDisplayName()); + addressPairDataType.setDescription("MAC/IP address pairs"); + Map addressPairProp = new HashMap<>(); + + addressPairProp.put("ip_address", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "IP address", false, null, + null, null, null)); + addressPairProp.put("mac_address", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "MAC address", false, null, + null, null, null)); + addressPairDataType.setProperties(addressPairProp); + + return addressPairDataType; + } + + private static DataType createHostRouteDataType() { + DataType hostRouteDataType = new DataType(); + hostRouteDataType.setDerived_from(ToscaDataType.ROOT.getDisplayName()); + hostRouteDataType.setDescription("Host route info for the subnet"); + + Map hostRoutePoolProp = new HashMap<>(); + hostRoutePoolProp.put("destination", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "The destination for static route", false, null, null, null, null)); + hostRoutePoolProp.put("nexthop", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "The next hop for the destination", false, null, null, null, null)); + hostRouteDataType.setProperties(hostRoutePoolProp); + + return hostRouteDataType; + } + + private static DataType createAllocationPoolDataType() { + DataType allocationPoolDataType = new DataType(); + allocationPoolDataType.setDerived_from(ToscaDataType.ROOT.getDisplayName()); + allocationPoolDataType.setDescription("The start and end addresses for the allocation pool"); + + Map allocationPoolProp = new HashMap<>(); + allocationPoolProp.put("start", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "Start address for the allocation pool", false, null, null, null, null)); + allocationPoolProp.put("end", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "End address for the allocation pool", false, null, null, null, null)); + allocationPoolDataType.setProperties(allocationPoolProp); + + return allocationPoolDataType; + } + + private static DataType createSubnetDataType() { + DataType subnetDataType = new DataType(); + subnetDataType.setDerived_from(ToscaDataType.ROOT.getDisplayName()); + subnetDataType.setDescription( + "A subnet represents an IP address block that can " + + "be used for assigning IP addresses to virtual instances"); + + Map subnetProp = new HashMap<>(); + subnetProp.put("allocation_pools", DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), + "The start and end addresses for the allocation pools", false, null, null, DataModelUtil + .createEntrySchema(ToscaDataType.NETWORK_ALLOCATION_POOL.getDisplayName(), null, + null), null)); + subnetProp.put("cidr", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "The CIDR", false, null, + null, null, null)); + subnetProp.put("dns_nameservers", DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), + "A specified set of DNS name servers to be used", false, null, null, + DataModelUtil.createEntrySchema(PropertyType.STRING.getDisplayName(), null, null), + new ArrayList())); + subnetProp.put("enable_dhcp", DataModelUtil + .createPropertyDefinition(PropertyType.BOOLEAN.getDisplayName(), + "Set to true if DHCP is enabled and false if DHCP is disabled", false, null, null, null, + true)); + subnetProp.put("gateway_ip", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "The gateway IP address", + false, null, null, null, null)); + subnetProp.put("host_routes", DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), "The gateway IP address", + false, null, null, DataModelUtil + .createEntrySchema(ToscaDataType.NETWORK_HOST_ROUTE.getDisplayName(), null, null), + null)); + subnetProp.put("ip_version", DataModelUtil + .createPropertyDefinition(PropertyType.INTEGER.getDisplayName(), "The gateway IP address", + false, DataModelUtil.createValidValuesConstraintsList("4", "6"), null, null, 4)); + subnetProp.put("ipv6_address_mode", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "IPv6 address mode", false, + DataModelUtil + .createValidValuesConstraintsList("dhcpv6-stateful", "dhcpv6-stateless", "slaac"), + null, null, null)); + subnetProp.put("ipv6_ra_mode", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "IPv6 RA (Router Advertisement) mode", false, DataModelUtil + .createValidValuesConstraintsList("dhcpv6-stateful", "dhcpv6-stateless", "slaac"), + null, null, null)); + subnetProp.put(Constants.NAME_PROPERTY_NAME, DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "The name of the subnet", + false, null, null, null, null)); + subnetProp.put("prefixlen", DataModelUtil + .createPropertyDefinition(PropertyType.INTEGER.getDisplayName(), + "Prefix length for subnet allocation from subnet pool", false, + createPrefixlenConstraint(), null, null, null)); + subnetProp.put("subnetpool", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "The name or ID of the subnet pool", false, null, null, null, null)); + subnetProp.put("tenant_id", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "The ID of the tenant who owns the network", false, null, null, null, null)); + subnetProp.put("value_specs", DataModelUtil + .createPropertyDefinition(PropertyType.MAP.getDisplayName(), + "Extra parameters to include in the request", false, null, null, + DataModelUtil.createEntrySchema(PropertyType.STRING.getDisplayName(), null, null), + new HashMap<>())); + subnetDataType.setProperties(subnetProp); + + return subnetDataType; + } + + private static List createPrefixlenConstraint() { + List constraints = new ArrayList<>(); + Constraint constraint = new Constraint(); + constraint.setGreater_or_equal(0); + constraints.add(constraint); + return constraints; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/ContrailAbstractSubstituteGlobalType.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/ContrailAbstractSubstituteGlobalType.java new file mode 100644 index 0000000000..7b0b810b61 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/ContrailAbstractSubstituteGlobalType.java @@ -0,0 +1,196 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.globaltypes; + +import org.openecomp.sdc.tosca.datatypes.ToscaDataType; +import org.openecomp.sdc.tosca.datatypes.ToscaNodeType; +import org.openecomp.sdc.tosca.datatypes.model.AttributeDefinition; +import org.openecomp.sdc.tosca.datatypes.model.DataType; +import org.openecomp.sdc.tosca.datatypes.model.NodeType; +import org.openecomp.sdc.tosca.datatypes.model.PropertyDefinition; +import org.openecomp.sdc.tosca.datatypes.model.PropertyType; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.tosca.services.ToscaConstants; +import org.openecomp.sdc.translator.services.heattotosca.Constants; + +import java.util.HashMap; +import java.util.Map; + + +public class ContrailAbstractSubstituteGlobalType { + + /** + * Create service template service template. + * + * @return the service template + */ + public static ServiceTemplate createServiceTemplate() { + ServiceTemplate serviceTemplate = new ServiceTemplate(); + serviceTemplate.setTosca_definitions_version(ToscaConstants.TOSCA_DEFINITIONS_VERSION); + serviceTemplate.setMetadata( + DataModelUtil.createMetadata(Constants + .CONTRAIL_ABSTRACT_SUBSTITUTE_TEMPLATE_NAME, "1.0.0", null)); + serviceTemplate.setImports(GlobalTypesUtil.createCommonImportList()); + serviceTemplate.setDescription("Contrail Abstract Substitute Global Types"); + serviceTemplate.setData_types(createGlobalDataTypes()); + serviceTemplate.setNode_types(createGlobalNodeTypes()); + return serviceTemplate; + } + + private static Map createGlobalNodeTypes() { + Map globalNodeTypes = new HashMap<>(); + globalNodeTypes.put(ToscaNodeType.CONTRAIL_ABSTRACT_SUBSTITUTE.getDisplayName(), + createContrailAbstractSubstituteNodeType()); + return globalNodeTypes; + } + + private static NodeType createContrailAbstractSubstituteNodeType() { + NodeType nodeType = new NodeType(); + nodeType.setDerived_from(ToscaNodeType.ABSTRACT_SUBSTITUTE.getDisplayName()); + nodeType.setProperties(createContrailAbstractSubstituteProperties()); + nodeType.setAttributes(createContrailAbstractSubstituteAttributes()); + + return nodeType; + } + + private static Map createContrailAbstractSubstituteAttributes() { + Map attributesDefMap = new HashMap<>(); + attributesDefMap.put("service_instance_name", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), + "The name of the service instance", null, null, null)); + attributesDefMap.put("fq_name", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), + "The FQ name of the service instance", null, null, null)); + attributesDefMap.put("status", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), + "Status of the service instance", null, null, null)); + attributesDefMap.put("service_template_name", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), + "Service Template of the Service Instance", null, null, null)); + attributesDefMap.put("virtual_machines", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), + "Service VMs for the Service Instance", null, null, null)); + attributesDefMap.put("active_vms", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), + "Number of service VMs active for this Service Instance", null, null, null)); + attributesDefMap.put("tenant_id", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), + "Tenant id of the Service Instance", null, null, null)); + attributesDefMap.put("show", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), "All attributes", null, + null, null)); + + return attributesDefMap; + } + + private static Map createContrailAbstractSubstituteProperties() { + Map props = new HashMap<>(); + props.put("service_template_name", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Service template name", + false, null, null, null, null)); + props.put("service_mode", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Service mode", true, + DataModelUtil + .createValidValuesConstraintsList("transparent", "in-network", "in-network-nat"), + null, null, null)); + props.put("service_type", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Service type", true, + DataModelUtil.createValidValuesConstraintsList("firewall", "analyzer", "source-nat", + "loadbalancer"), null, null, null)); + props.put("image_name", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Image name", true, null, + null, null, null)); + props.put("flavor", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "flavor", false, null, null, + null, null)); + props.put("service_interface_type_list", DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), "List of interface types", + true, null, null, DataModelUtil + .createEntrySchema(PropertyType.STRING.getDisplayName(), null, DataModelUtil + .createValidValuesConstraintsList("management", "left", "right", "other")), + null)); + props.put("shared_ip_list", DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), "Shared ips enabled", false, + null, null, + DataModelUtil.createEntrySchema(PropertyType.BOOLEAN.getDisplayName(), null, null), + null)); + props.put("static_routes_list", DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), "Static routes enabled", + false, null, null, + DataModelUtil.createEntrySchema(PropertyType.BOOLEAN.getDisplayName(), null, null), + null)); + props.put("ordered_interfaces", DataModelUtil + .createPropertyDefinition(PropertyType.BOOLEAN.getDisplayName(), + "Indicates if service interface are ordered", false, null, null, null, false)); + props.put("availability_zone_enable", DataModelUtil + .createPropertyDefinition(PropertyType.BOOLEAN.getDisplayName(), + "Indicates availability zone is enabled", false, null, null, null, false)); + props.put("availability_zone", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "Availability zone to create servers in", false, null, null, null, null)); + props.put("service_instance_name", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Service instance name", + true, null, null, null, null)); + props.put("interface_list", DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), "List of interfaces", false, + null, null, DataModelUtil + .createEntrySchema(ToscaDataType.CONTRAIL_INTERFACE_DATA.getDisplayName(), null, + null), null)); + return props; + } + + + private static Map createGlobalDataTypes() { + Map globalDataTypes = new HashMap<>(); + globalDataTypes + .put(ToscaDataType.CONTRAIL_INTERFACE_DATA.getDisplayName(), createInterfaceDataType()); + return globalDataTypes; + } + + private static DataType createInterfaceDataType() { + DataType dataType = new DataType(); + dataType.setDerived_from(ToscaDataType.ROOT.getDisplayName()); + dataType.setDescription("Interface Data"); + Map propertyDefMap = new HashMap<>(); + propertyDefMap.put("virtual_network", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "Virtual Network for this interface", true, null, null, null, null)); + propertyDefMap.put("ip_address", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "IP for this interface", + false, null, null, null, null)); + propertyDefMap.put("static_routes", DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), + "An ordered list of static routes to be added to this interface", false, null, null, + DataModelUtil + .createEntrySchema(ToscaDataType.CONTRAIL_STATIC_ROUTE.getDisplayName(), null, + null), null)); + propertyDefMap.put("allowed_address_pairs", DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), + "List of allowed address pair for this interface", false, null, null, DataModelUtil + .createEntrySchema(ToscaDataType.CONTRAIL_ADDRESS_PAIR.getDisplayName(), null, + null), null)); + dataType.setProperties(propertyDefMap); + return dataType; + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/ContrailComputeGlobalType.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/ContrailComputeGlobalType.java new file mode 100644 index 0000000000..50faec0c69 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/ContrailComputeGlobalType.java @@ -0,0 +1,128 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.globaltypes; + +import org.openecomp.sdc.tosca.datatypes.ToscaNodeType; +import org.openecomp.sdc.tosca.datatypes.model.AttributeDefinition; +import org.openecomp.sdc.tosca.datatypes.model.NodeType; +import org.openecomp.sdc.tosca.datatypes.model.PropertyDefinition; +import org.openecomp.sdc.tosca.datatypes.model.PropertyType; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.tosca.services.ToscaConstants; +import org.openecomp.sdc.translator.services.heattotosca.Constants; + +import java.util.HashMap; +import java.util.Map; + +public class ContrailComputeGlobalType { + + /** + * Create service template service template. + * + * @return the service template + */ + public static ServiceTemplate createServiceTemplate() { + ServiceTemplate serviceTemplate = new ServiceTemplate(); + serviceTemplate.setTosca_definitions_version(ToscaConstants.TOSCA_DEFINITIONS_VERSION); + serviceTemplate.setMetadata( + DataModelUtil.createMetadata(Constants.CONTRAIL_COMPUTE_TEMPLATE_NAME, "1.0.0", null)); + serviceTemplate.setDescription("Contrail Compute TOSCA Global Types"); + serviceTemplate.setImports(GlobalTypesUtil.createCommonImportList()); + serviceTemplate.setNode_types(createGlobalNodeTypes()); + return serviceTemplate; + } + + + private static Map createGlobalNodeTypes() { + Map globalNodeTypes = new HashMap<>(); + globalNodeTypes + .put(ToscaNodeType.CONTRAIL_COMPUTE.getDisplayName(), createContrailComputeNodeType()); + return globalNodeTypes; + } + + private static NodeType createContrailComputeNodeType() { + NodeType nodeType = new NodeType(); + nodeType.setDerived_from(ToscaNodeType.COMPUTE.getDisplayName()); + nodeType.setProperties(createContrailComputeProperties()); + nodeType.setAttributes(createContrailComputeAttributes()); + return nodeType; + } + + + private static Map createContrailComputeProperties() { + Map propertyDefMap = new HashMap<>(); + propertyDefMap.put("service_instance_name", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Service instance name", + true, null, null, null, null)); + propertyDefMap.put("service_template_name", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Service template name", + false, null, null, null, null)); + propertyDefMap.put("image_name", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Image name", true, null, + null, null, null)); + propertyDefMap.put("service_mode", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Service mode", true, + DataModelUtil + .createValidValuesConstraintsList("transparent", "in-network", "in-network-nat"), + null, null, null)); + propertyDefMap.put("service_type", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Service type", true, + DataModelUtil.createValidValuesConstraintsList("firewall", "analyzer", "source-nat", + "loadbalancer"), null, null, null)); + propertyDefMap.put("image_name", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Image name", true, null, + null, null, null)); + propertyDefMap.put("flavor", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "flavor", false, null, null, + null, null)); + propertyDefMap.put("availability_zone_enable", DataModelUtil + .createPropertyDefinition(PropertyType.BOOLEAN.getDisplayName(), + "Indicates availability zone is enabled", false, null, null, null, false)); + propertyDefMap.put("availability_zone", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "Availability zone to create servers in", false, null, null, null, null)); + return propertyDefMap; + } + + private static Map createContrailComputeAttributes() { + Map attributesDefMap = new HashMap<>(); + attributesDefMap.put("fq_name", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), "fq_name", null, null, + null)); + attributesDefMap.put("status", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), "status of the compute", + null, null, null)); + attributesDefMap.put("virtual_machines", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), "VMs of this compute", + null, null, null)); + attributesDefMap.put("active_vms", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), "Number of active VMs", + null, null, null)); + attributesDefMap.put("tenant_id", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), "Tenant id of the VM", + null, null, null)); + attributesDefMap.put("show", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), "All attributes", null, + null, null)); + return attributesDefMap; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/ContrailNetworkRuleGlobalType.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/ContrailNetworkRuleGlobalType.java new file mode 100644 index 0000000000..0081ad5a78 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/ContrailNetworkRuleGlobalType.java @@ -0,0 +1,227 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.globaltypes; + +import org.openecomp.sdc.tosca.datatypes.ToscaCapabilityType; +import org.openecomp.sdc.tosca.datatypes.ToscaDataType; +import org.openecomp.sdc.tosca.datatypes.ToscaNodeType; +import org.openecomp.sdc.tosca.datatypes.ToscaRelationshipType; +import org.openecomp.sdc.tosca.datatypes.model.AttributeDefinition; +import org.openecomp.sdc.tosca.datatypes.model.DataType; +import org.openecomp.sdc.tosca.datatypes.model.NodeType; +import org.openecomp.sdc.tosca.datatypes.model.PropertyDefinition; +import org.openecomp.sdc.tosca.datatypes.model.PropertyType; +import org.openecomp.sdc.tosca.datatypes.model.RequirementDefinition; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.tosca.services.ToscaConstants; +import org.openecomp.sdc.translator.services.heattotosca.Constants; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +public class ContrailNetworkRuleGlobalType { + /** + * Create service template service template. + * + * @return the service template + */ + public static ServiceTemplate createServiceTemplate() { + ServiceTemplate contrailNetworkRuleServiceTemplate = new ServiceTemplate(); + contrailNetworkRuleServiceTemplate + .setTosca_definitions_version(ToscaConstants.TOSCA_DEFINITIONS_VERSION); + contrailNetworkRuleServiceTemplate.setMetadata( + DataModelUtil.createMetadata(Constants.CONTRAIL_NETWORK_RULE_TEMPLATE_NAME, "1.0.0", null)); + contrailNetworkRuleServiceTemplate.setImports(GlobalTypesUtil.createCommonImportList()); + contrailNetworkRuleServiceTemplate.setDescription("Contrail Network Rule Global Types"); + contrailNetworkRuleServiceTemplate.setData_types(createGlobalDataTypes()); + contrailNetworkRuleServiceTemplate.setNode_types(createGlobalNodeTypes()); + return contrailNetworkRuleServiceTemplate; + } + + + private static Map createGlobalDataTypes() { + Map globalDataTypes = new HashMap<>(); + globalDataTypes.put(ToscaDataType.CONTRAIL_NETWORK_RULE_PORT_PAIRS.getDisplayName(), + createRulePortPairsDataType()); + globalDataTypes.put(ToscaDataType.CONTRAIL_NETWORK_RULE.getDisplayName(), createRuleDataType()); + globalDataTypes.put(ToscaDataType.CONTRAIL_NETWORK_RULE_VIRTUAL_NETWORK.getDisplayName(), + createRuleVirtualNetworkDataType()); + globalDataTypes.put(ToscaDataType.CONTRAIL_NETWORK_RULE_LIST.getDisplayName(), + createPolicyRulesListDataType()); + return globalDataTypes; + } + + private static DataType createRuleDataType() { + DataType dataType = new DataType(); + dataType.setDerived_from(ToscaDataType.ROOT.getDisplayName()); + dataType.setDescription("policy rule"); + Map properties = new HashMap<>(); + properties.put("direction", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Direction", false, null, + null, null, null)); + properties.put("protocol", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Protocol", false, null, + null, null, null)); + properties.put("src_ports", DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), "Source ports", false, null, + null, DataModelUtil + .createEntrySchema(ToscaDataType.CONTRAIL_NETWORK_RULE_PORT_PAIRS.getDisplayName(), + null, null), null)); + properties.put("dst_ports", DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), "Destination ports", false, + null, null, DataModelUtil + .createEntrySchema(ToscaDataType.CONTRAIL_NETWORK_RULE_PORT_PAIRS.getDisplayName(), + null, null), null)); + properties.put("dst_addresses", DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), "Destination addresses", + false, null, null, DataModelUtil.createEntrySchema( + ToscaDataType.CONTRAIL_NETWORK_RULE_VIRTUAL_NETWORK.getDisplayName(), null, null), + null)); + properties.put("apply_service", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Service to apply", false, + null, null, null, null)); + properties.put("src_addresses", DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), "Source addresses", false, + null, null, DataModelUtil.createEntrySchema( + ToscaDataType.CONTRAIL_NETWORK_RULE_VIRTUAL_NETWORK.getDisplayName(), null, null), + null)); + + dataType.setProperties(properties); + return dataType; + + } + + + private static DataType createRuleVirtualNetworkDataType() { + DataType dataType = new DataType(); + dataType.setDerived_from(ToscaDataType.ROOT.getDisplayName()); + dataType.setDescription("source and destination addresses"); + Map properties = new HashMap<>(); + + properties.put("virtual_network", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Virtual network", false, + null, null, null, null)); + + dataType.setProperties(properties); + return dataType; + } + + private static DataType createPolicyRulesListDataType() { + DataType dataType = new DataType(); + dataType.setDerived_from(ToscaDataType.ROOT.getDisplayName()); + dataType.setDescription("list of policy rules"); + Map properties = new HashMap<>(); + + properties.put("policy_rule", DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), "Contrail network rule", + false, null, null, DataModelUtil + .createEntrySchema(ToscaDataType.CONTRAIL_NETWORK_RULE.getDisplayName(), null, + null), null)); + + dataType.setProperties(properties); + return dataType; + } + + + private static DataType createRulePortPairsDataType() { + DataType dataType = new DataType(); + dataType.setDerived_from(ToscaDataType.ROOT.getDisplayName()); + dataType.setDescription("source and destination port pairs"); + Map properties = new HashMap<>(); + + properties.put("start_port", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Start port", false, null, + null, null, null)); + properties.put("end_port", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "End port", false, null, + null, null, null)); + + dataType.setProperties(properties); + return dataType; + } + + private static Map createGlobalNodeTypes() { + Map globalNodeTypes = new HashMap<>(); + globalNodeTypes.put(ToscaNodeType.CONTRAIL_NETWORK_RULE.getDisplayName(), + createContrailNetworkRuleNodeType()); + return globalNodeTypes; + } + + private static NodeType createContrailNetworkRuleNodeType() { + NodeType contrailNetworkRuleNodeType = new NodeType(); + contrailNetworkRuleNodeType.setDerived_from(ToscaNodeType.ROOT.getDisplayName()); + contrailNetworkRuleNodeType.setProperties(createContrailNetworkRuleProperties()); + contrailNetworkRuleNodeType.setAttributes(createContrailNetworkRuleAttributes()); + contrailNetworkRuleNodeType.setRequirements(createContrailNetworkRuleRequirements()); + return contrailNetworkRuleNodeType; + } + + + private static Map createContrailNetworkRuleProperties() { + Map contrailNetworkRulePropertyDefMap = new HashMap<>(); + contrailNetworkRulePropertyDefMap.put(Constants.NAME_PROPERTY_NAME, DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "A symbolic name for this contrail network rule", false, null, null, null, null)); + contrailNetworkRulePropertyDefMap.put("entries", DataModelUtil + .createPropertyDefinition(ToscaDataType.CONTRAIL_NETWORK_RULE_LIST.getDisplayName(), + "A symbolic name for this contrail network rule", false, null, null, null, null)); + + return contrailNetworkRulePropertyDefMap; + } + + + private static Map createContrailNetworkRuleAttributes() { + Map contrailNetworkRuleAttributesDefMap = new HashMap<>(); + contrailNetworkRuleAttributesDefMap.put("fq_name", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), "fq_name", null, null, + null)); + contrailNetworkRuleAttributesDefMap.put("tenant_id", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), "tenant_id", null, null, + null)); + contrailNetworkRuleAttributesDefMap.put("rules", DataModelUtil + .createAttributeDefinition(PropertyType.LIST.getDisplayName(), "List of rules", null, + DataModelUtil.createEntrySchema(PropertyType.STRING.getDisplayName(), null, null), + null)); + contrailNetworkRuleAttributesDefMap.put("show", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), "All attributes.", null, + null, null)); + + return contrailNetworkRuleAttributesDefMap; + } + + private static List> createContrailNetworkRuleRequirements() { + final List> requirements = new ArrayList<>(); + final Map + contrailNetworkRuleRequirementsDefMap = new HashMap<>(); + RequirementDefinition req = new RequirementDefinition(); + req.setCapability(ToscaCapabilityType.ATTACHMENT.getDisplayName()); + req.setOccurrences(new Object[]{0, ToscaConstants.UNBOUNDED}); + req.setNode(ToscaNodeType.NETWORK.getDisplayName()); + req.setRelationship(ToscaRelationshipType.ATTACHES_TO.getDisplayName()); + contrailNetworkRuleRequirementsDefMap.put("network", req); + requirements.add(contrailNetworkRuleRequirementsDefMap); + + return requirements; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/ContrailPortGlobalType.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/ContrailPortGlobalType.java new file mode 100644 index 0000000000..1590372813 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/ContrailPortGlobalType.java @@ -0,0 +1,107 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.globaltypes; + +import org.openecomp.sdc.tosca.datatypes.ToscaDataType; +import org.openecomp.sdc.tosca.datatypes.ToscaNodeType; +import org.openecomp.sdc.tosca.datatypes.model.AttributeDefinition; +import org.openecomp.sdc.tosca.datatypes.model.NodeType; +import org.openecomp.sdc.tosca.datatypes.model.PropertyDefinition; +import org.openecomp.sdc.tosca.datatypes.model.PropertyType; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.tosca.services.ToscaConstants; +import org.openecomp.sdc.translator.services.heattotosca.Constants; + +import java.util.HashMap; +import java.util.Map; + +public class ContrailPortGlobalType { + /** + * Create service template service template. + * + * @return the service template + */ + public static ServiceTemplate createServiceTemplate() { + ServiceTemplate serviceTemplate = new ServiceTemplate(); + serviceTemplate.setTosca_definitions_version(ToscaConstants.TOSCA_DEFINITIONS_VERSION); + serviceTemplate.setMetadata( + DataModelUtil.createMetadata(Constants.CONTRAIL_PORT_TEMPLATE_NAME, "1.0.0", null)); + serviceTemplate.setImports(GlobalTypesUtil.createCommonImportList()); + serviceTemplate.setDescription("Contrail Port TOSCA Global Types"); + serviceTemplate.setNode_types(createGlobalNodeTypes()); + return serviceTemplate; + } + + private static Map createGlobalNodeTypes() { + Map globalNodeTypes = new HashMap<>(); + globalNodeTypes.put(ToscaNodeType.CONTRAIL_PORT.getDisplayName(), createContrailPortNodeType()); + return globalNodeTypes; + } + + private static NodeType createContrailPortNodeType() { + NodeType nodeType = new NodeType(); + nodeType.setDerived_from(ToscaNodeType.NETWORK_PORT.getDisplayName()); + nodeType.setProperties(createContrailPortProperties()); + nodeType.setAttributes(createContrailPortAttributes()); + return nodeType; + } + + private static Map createContrailPortProperties() { + Map propertyDefMap = new HashMap<>(); + propertyDefMap.put("interface_type", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Interface type", true, + DataModelUtil.createValidValuesConstraintsList("management", "left", "right", "other"), + null, null, null)); + propertyDefMap.put("shared_ip", DataModelUtil + .createPropertyDefinition(PropertyType.BOOLEAN.getDisplayName(), "Shared ip enabled", false, + null, null, null, false)); + propertyDefMap.put("static_route", DataModelUtil + .createPropertyDefinition(PropertyType.BOOLEAN.getDisplayName(), "Static route enabled", + false, null, null, null, false)); + propertyDefMap.put("virtual_network", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "Virtual Network for this interface", true, null, null, null, null)); + propertyDefMap.put("static_routes", DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), + "An ordered list of static routes to be added to this interface", false, null, null, + DataModelUtil + .createEntrySchema(ToscaDataType.CONTRAIL_STATIC_ROUTE.getDisplayName(), null, + null), null)); + propertyDefMap.put("allowed_address_pairs", DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), + "List of allowed address pair for this interface", false, null, null, DataModelUtil + .createEntrySchema(ToscaDataType.CONTRAIL_ADDRESS_PAIR.getDisplayName(), null, + null), null)); + propertyDefMap.put("ip_address", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "IP for this interface", + false, null, null, null, null)); + return propertyDefMap; + } + + private static Map createContrailPortAttributes() { + Map attributesDefMap = new HashMap<>(); + attributesDefMap.put("fq_name", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), "fq_name", null, null, + null)); + return attributesDefMap; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/ContrailV2NetworkRuleGlobalType.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/ContrailV2NetworkRuleGlobalType.java new file mode 100644 index 0000000000..4141aa7f0a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/ContrailV2NetworkRuleGlobalType.java @@ -0,0 +1,274 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.globaltypes; + +import org.openecomp.sdc.tosca.datatypes.ToscaCapabilityType; +import org.openecomp.sdc.tosca.datatypes.ToscaDataType; +import org.openecomp.sdc.tosca.datatypes.ToscaNodeType; +import org.openecomp.sdc.tosca.datatypes.ToscaRelationshipType; +import org.openecomp.sdc.tosca.datatypes.model.AttributeDefinition; +import org.openecomp.sdc.tosca.datatypes.model.DataType; +import org.openecomp.sdc.tosca.datatypes.model.NodeType; +import org.openecomp.sdc.tosca.datatypes.model.PropertyDefinition; +import org.openecomp.sdc.tosca.datatypes.model.PropertyType; +import org.openecomp.sdc.tosca.datatypes.model.RequirementDefinition; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.tosca.services.ToscaConstants; +import org.openecomp.sdc.translator.services.heattotosca.Constants; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +public class ContrailV2NetworkRuleGlobalType { + /** + * Create service template service template. + * + * @return the service template + */ + public static ServiceTemplate createServiceTemplate() { + ServiceTemplate contrailNetworkRuleServiceTemplate = new ServiceTemplate(); + contrailNetworkRuleServiceTemplate + .setTosca_definitions_version(ToscaConstants.TOSCA_DEFINITIONS_VERSION); + contrailNetworkRuleServiceTemplate.setMetadata( + DataModelUtil.createMetadata(Constants + .CONTRAILV2_NETWORK_RULE_TEMPLATE_NAME, "1.0.0", null)); + contrailNetworkRuleServiceTemplate.setImports(GlobalTypesUtil.createCommonImportList()); + contrailNetworkRuleServiceTemplate.setDescription("Contrail V2 Network Rule Global Types"); + contrailNetworkRuleServiceTemplate.setData_types(createGlobalDataTypes()); + contrailNetworkRuleServiceTemplate.setNode_types(createGlobalNodeTypes()); + return contrailNetworkRuleServiceTemplate; + } + + + private static Map createGlobalDataTypes() { + Map globalDataTypes = new HashMap<>(); + globalDataTypes.put(ToscaDataType.CONTRAILV2_NETWORK_RULE_SRC_PORT_PAIRS.getDisplayName(), + createRuleSrcPortPairsDataType()); + globalDataTypes.put(ToscaDataType.CONTRAILV2_NETWORK_RULE_DST_PORT_PAIRS.getDisplayName(), + createRuleDstPortPairsDataType()); + globalDataTypes + .put(ToscaDataType.CONTRAILV2_NETWORK_RULE.getDisplayName(), createRuleDataType()); + globalDataTypes.put(ToscaDataType.CONTRAILV2_NETWORK_RULE_DST_VIRTUAL_NETWORK.getDisplayName(), + createRuleDstVirtualNetworkDataType()); + globalDataTypes.put(ToscaDataType.CONTRAILV2_NETWORK_RULE_SRC_VIRTUAL_NETWORK.getDisplayName(), + createRuleSrcVirtualNetworkDataType()); + globalDataTypes.put(ToscaDataType.CONTRAILV2_NETWORK_RULE_LIST.getDisplayName(), + createPolicyRulesListDataType()); + globalDataTypes.put(ToscaDataType.CONTRAILV2_NETWORK_RULE_ACTION_LIST.getDisplayName(), + createRuleActionListDataType()); + return globalDataTypes; + } + + private static DataType createRuleDataType() { + DataType dataType = new DataType(); + dataType.setDerived_from(ToscaDataType.ROOT.getDisplayName()); + dataType.setDescription("policy rule"); + Map properties = new HashMap<>(); + properties.put("network_policy_entries_policy_rule_direction", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Direction", false, null, + null, null, null)); + properties.put("network_policy_entries_policy_rule_protocol", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Protocol", false, null, + null, null, null)); + properties.put("network_policy_entries_policy_rule_src_ports", DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), "Source ports", false, null, + null, DataModelUtil.createEntrySchema( + ToscaDataType.CONTRAILV2_NETWORK_RULE_SRC_PORT_PAIRS.getDisplayName(), null, null), + null)); + properties.put("network_policy_entries_policy_rule_dst_ports", DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), "Destination ports", false, + null, null, DataModelUtil.createEntrySchema( + ToscaDataType.CONTRAILV2_NETWORK_RULE_DST_PORT_PAIRS.getDisplayName(), null, null), + null)); + properties.put("network_policy_entries_policy_rule_dst_addresses", DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), "Destination addresses", + false, null, null, DataModelUtil.createEntrySchema( + ToscaDataType.CONTRAILV2_NETWORK_RULE_DST_VIRTUAL_NETWORK.getDisplayName(), null, + null), null)); + properties.put("network_policy_entries_policy_rule_src_addresses", DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), "Source addresses", false, + null, null, DataModelUtil.createEntrySchema( + ToscaDataType.CONTRAILV2_NETWORK_RULE_SRC_VIRTUAL_NETWORK.getDisplayName(), null, + null), null)); + properties.put("network_policy_entries_policy_rule_action_list", DataModelUtil + .createPropertyDefinition( + ToscaDataType.CONTRAILV2_NETWORK_RULE_ACTION_LIST.getDisplayName(), "Action list", + false, null, null, null, null)); + + dataType.setProperties(properties); + return dataType; + + } + + + private static DataType createRuleDstVirtualNetworkDataType() { + DataType dataType = new DataType(); + dataType.setDerived_from(ToscaDataType.ROOT.getDisplayName()); + dataType.setDescription("destination addresses"); + Map properties = new HashMap<>(); + + properties.put("network_policy_entries_policy_rule_dst_addresses_virtual_network", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "Destination addresses Virtual network", false, null, null, null, null)); + + dataType.setProperties(properties); + return dataType; + } + + private static DataType createRuleSrcVirtualNetworkDataType() { + DataType dataType = new DataType(); + dataType.setDerived_from(ToscaDataType.ROOT.getDisplayName()); + dataType.setDescription("source addresses"); + Map properties = new HashMap<>(); + + properties.put("network_policy_entries_policy_rule_src_addresses_virtual_network", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "Source addresses Virtual network", false, null, null, null, null)); + + dataType.setProperties(properties); + return dataType; + } + + private static DataType createPolicyRulesListDataType() { + DataType dataType = new DataType(); + dataType.setDerived_from(ToscaDataType.ROOT.getDisplayName()); + dataType.setDescription("list of policy rules"); + Map properties = new HashMap<>(); + + properties.put("network_policy_entries_policy_rule", DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), "Contrail network rule", + false, null, null, DataModelUtil + .createEntrySchema(ToscaDataType.CONTRAILV2_NETWORK_RULE.getDisplayName(), null, + null), null)); + + dataType.setProperties(properties); + return dataType; + } + + private static DataType createRuleActionListDataType() { + DataType dataType = new DataType(); + dataType.setDerived_from(ToscaDataType.ROOT.getDisplayName()); + dataType.setDescription("Action List"); + Map properties = new HashMap<>(); + + properties.put("network_policy_entries_policy_rule_action_list_simple_action", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Simple Action", false, + null, null, null, null)); + properties.put("network_policy_entries_policy_rule_action_list_apply_service", DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), "Apply Service", false, null, + null, DataModelUtil.createEntrySchema(PropertyType.STRING.getDisplayName(), null, null), + null)); + + dataType.setProperties(properties); + return dataType; + } + + private static DataType createRuleDstPortPairsDataType() { + DataType dataType = new DataType(); + dataType.setDerived_from(ToscaDataType.ROOT.getDisplayName()); + dataType.setDescription("destination port pairs"); + Map properties = new HashMap<>(); + + properties.put("network_policy_entries_policy_rule_dst_ports_start_port", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Start port", false, null, + null, null, null)); + properties.put("network_policy_entries_policy_rule_dst_ports_end_port", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "End port", false, null, + null, null, null)); + + dataType.setProperties(properties); + return dataType; + } + + private static DataType createRuleSrcPortPairsDataType() { + DataType dataType = new DataType(); + dataType.setDerived_from(ToscaDataType.ROOT.getDisplayName()); + dataType.setDescription("source port pairs"); + Map properties = new HashMap<>(); + + properties.put("network_policy_entries_policy_rule_src_ports_start_port", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Start port", false, null, + null, null, null)); + properties.put("network_policy_entries_policy_rule_src_ports_end_port", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "End port", false, null, + null, null, null)); + + dataType.setProperties(properties); + return dataType; + } + + private static Map createGlobalNodeTypes() { + Map globalNodeTypes = new HashMap<>(); + globalNodeTypes.put(ToscaNodeType.CONTRAILV2_NETWORK_RULE.getDisplayName(), + createContrailV2NetworkRuleNodeType()); + return globalNodeTypes; + } + + private static NodeType createContrailV2NetworkRuleNodeType() { + NodeType contrailNetworkRuleNodeType = new NodeType(); + contrailNetworkRuleNodeType.setDerived_from(ToscaNodeType.ROOT.getDisplayName()); + contrailNetworkRuleNodeType.setProperties(createContrailNetworkRuleProperties()); + contrailNetworkRuleNodeType.setAttributes(createContrailNetworkRuleAttributes()); + contrailNetworkRuleNodeType.setRequirements(createContrailNetworkRuleRequirements()); + return contrailNetworkRuleNodeType; + } + + + private static Map createContrailNetworkRuleProperties() { + Map contrailNetworkRulePropertyDefMap = new HashMap<>(); + contrailNetworkRulePropertyDefMap.put(Constants.NAME_PROPERTY_NAME, DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "A symbolic name for this contrail v2 network rule", false, null, null, null, null)); + contrailNetworkRulePropertyDefMap.put("network_policy_entries", DataModelUtil + .createPropertyDefinition(ToscaDataType.CONTRAILV2_NETWORK_RULE_LIST.getDisplayName(), + "A symbolic name for this contrail v2 network rule", false, null, null, null, null)); + + return contrailNetworkRulePropertyDefMap; + } + + + private static Map createContrailNetworkRuleAttributes() { + Map contrailNetworkRuleAttributesDefMap = new HashMap<>(); + contrailNetworkRuleAttributesDefMap.put("fq_name", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), "fq_name", null, null, + null)); + + return contrailNetworkRuleAttributesDefMap; + } + + private static List> createContrailNetworkRuleRequirements() { + final List> requirements = new ArrayList<>(); + final Map + contrailNetworkRuleRequirementsDefMap = new HashMap<>(); + RequirementDefinition req = new RequirementDefinition(); + req.setCapability(ToscaCapabilityType.ATTACHMENT.getDisplayName()); + req.setOccurrences(new Object[]{0, ToscaConstants.UNBOUNDED}); + req.setNode(ToscaNodeType.NETWORK.getDisplayName()); + req.setRelationship(ToscaRelationshipType.ATTACHES_TO.getDisplayName()); + contrailNetworkRuleRequirementsDefMap.put("network", req); + requirements.add(contrailNetworkRuleRequirementsDefMap); + + return requirements; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/ContrailV2VirtualMachineInterfaceGlobalType.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/ContrailV2VirtualMachineInterfaceGlobalType.java new file mode 100644 index 0000000000..75501cb8d4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/ContrailV2VirtualMachineInterfaceGlobalType.java @@ -0,0 +1,136 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.globaltypes; + +import org.openecomp.sdc.tosca.datatypes.ToscaDataType; +import org.openecomp.sdc.tosca.datatypes.ToscaNodeType; +import org.openecomp.sdc.tosca.datatypes.model.AttributeDefinition; +import org.openecomp.sdc.tosca.datatypes.model.DataType; +import org.openecomp.sdc.tosca.datatypes.model.NodeType; +import org.openecomp.sdc.tosca.datatypes.model.PropertyDefinition; +import org.openecomp.sdc.tosca.datatypes.model.PropertyType; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.tosca.services.ToscaConstants; +import org.openecomp.sdc.translator.services.heattotosca.Constants; + +import java.util.HashMap; +import java.util.Map; + +class ContrailV2VirtualMachineInterfaceGlobalType { + private ContrailV2VirtualMachineInterfaceGlobalType() { + } + + public static ServiceTemplate createServiceTemplate() { + ServiceTemplate contrailVirtualMachineInterface = new ServiceTemplate(); + contrailVirtualMachineInterface + .setTosca_definitions_version(ToscaConstants.TOSCA_DEFINITIONS_VERSION); + contrailVirtualMachineInterface.setMetadata(DataModelUtil + .createMetadata(Constants.CONTRAILV2_VIRTUAL_MACHINE_INTERFACE_TEMPLATE_NAME, "1.0.0", + null)); + contrailVirtualMachineInterface.setImports(GlobalTypesUtil.createCommonImportList()); + contrailVirtualMachineInterface + .setDescription("Contrail Virtual Machine Interface TOSCA Global Types"); + contrailVirtualMachineInterface.setNode_types(createGlobalNodeTypes()); + contrailVirtualMachineInterface.setData_types(createGlobalDataTypes()); + return contrailVirtualMachineInterface; + } + + private static Map createGlobalDataTypes() { + Map globalDataTypes = new HashMap<>(); + globalDataTypes + .put(ToscaDataType.CONTRAILV2_VIRTUAL_MACHINE_INTERFACE_PROPERTIES.getDisplayName(), + createVmiPropertiesDataType()); + return globalDataTypes; + } + + private static DataType createVmiPropertiesDataType() { + DataType dataType = new DataType(); + dataType.setDerived_from(ToscaDataType.ROOT.getDisplayName()); + dataType.setDescription("Virtual Machine Interface Properties."); + Map properties = new HashMap<>(); + + properties.put("virtual_machine_interface_properties_service_interface_type", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Service Interface Type.", + false, null, null, null, null)); + dataType.setProperties(properties); + return dataType; + } + + private static Map createGlobalNodeTypes() { + Map globalNodeTypes = new HashMap<>(); + globalNodeTypes.put(ToscaNodeType.CONTRAILV2_VIRTUAL_MACHINE_INTERFACE.getDisplayName(), + createVmiNodeType()); + return globalNodeTypes; + } + + private static NodeType createVmiNodeType() { + NodeType nodeType = new NodeType(); + nodeType.setDerived_from(ToscaNodeType.NETWORK_PORT.getDisplayName()); + nodeType.setProperties(createVmiProperties()); + nodeType.setAttributes(createVmiAttributes()); + return nodeType; + } + + private static Map createVmiAttributes() { + Map vmiAttributesDefMap = new HashMap<>(); + vmiAttributesDefMap.put("fq_name", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), + "The FQ name of the Virtual Network.", null, null, null)); + vmiAttributesDefMap.put("show", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), "All attributes.", null, + null, null)); + return vmiAttributesDefMap; + } + + private static Map createVmiProperties() { + Map virtualMachineInterfacePropertyDefMap = new HashMap<>(); + virtualMachineInterfacePropertyDefMap.put(Constants.NAME_PROPERTY_NAME, DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "Virtual Machine Interface name", false, null, null, null, null)); + virtualMachineInterfacePropertyDefMap.put("virtual_machine_intefrace_mac_addresses", + DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), "List of mac addresses.", + false, null, null, + DataModelUtil.createEntrySchema(PropertyType.STRING.getDisplayName(), null, null), + null)); + virtualMachineInterfacePropertyDefMap.put("virtual_network_refs", DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), "List of virtual networks.", + false, null, null, + DataModelUtil.createEntrySchema(PropertyType.STRING.getDisplayName(), null, null), + null)); + virtualMachineInterfacePropertyDefMap.put("port_tuple_refs", DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), "List of port tuples.", false, + null, null, + DataModelUtil.createEntrySchema(PropertyType.STRING.getDisplayName(), null, null), + null)); + virtualMachineInterfacePropertyDefMap.put("security_group_refs", DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), "List of security groups.", + false, null, null, + DataModelUtil.createEntrySchema(PropertyType.STRING.getDisplayName(), null, null), + null)); + virtualMachineInterfacePropertyDefMap.put("virtual_machine_interface_properties", DataModelUtil + .createPropertyDefinition( + ToscaDataType.CONTRAILV2_VIRTUAL_MACHINE_INTERFACE_PROPERTIES.getDisplayName(), + "virtual machine interface properties.", false, null, null, null, null)); + return virtualMachineInterfacePropertyDefMap; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/ContrailV2VirtualNetworkGlobalType.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/ContrailV2VirtualNetworkGlobalType.java new file mode 100644 index 0000000000..728b9f6149 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/ContrailV2VirtualNetworkGlobalType.java @@ -0,0 +1,239 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.globaltypes; + +import org.openecomp.sdc.tosca.datatypes.ToscaDataType; +import org.openecomp.sdc.tosca.datatypes.ToscaNodeType; +import org.openecomp.sdc.tosca.datatypes.model.AttributeDefinition; +import org.openecomp.sdc.tosca.datatypes.model.CapabilityDefinition; +import org.openecomp.sdc.tosca.datatypes.model.DataType; +import org.openecomp.sdc.tosca.datatypes.model.NodeType; +import org.openecomp.sdc.tosca.datatypes.model.PropertyDefinition; +import org.openecomp.sdc.tosca.datatypes.model.PropertyType; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.tosca.services.ToscaConstants; +import org.openecomp.sdc.translator.services.heattotosca.Constants; + +import java.util.HashMap; +import java.util.Map; + +public class ContrailV2VirtualNetworkGlobalType { + + /** + * Create service template service template. + * + * @return the service template + */ + public static ServiceTemplate createServiceTemplate() { + ServiceTemplate contrailVirtualNetworkServiceTemplate = new ServiceTemplate(); + contrailVirtualNetworkServiceTemplate + .setTosca_definitions_version(ToscaConstants.TOSCA_DEFINITIONS_VERSION); + contrailVirtualNetworkServiceTemplate.setMetadata(DataModelUtil + .createMetadata(Constants.CONTRAILV2_VIRTUAL_NETWORK_TEMPLATE_NAME, "1.0.0", null)); + contrailVirtualNetworkServiceTemplate + .setDescription("Contrail V2 Virtual Network Global Types"); + contrailVirtualNetworkServiceTemplate.setImports(GlobalTypesUtil.createCommonImportList()); + contrailVirtualNetworkServiceTemplate.setNode_types(createGlobalNodeTypes()); + contrailVirtualNetworkServiceTemplate.setData_types(createGlobalDataTypes()); + return contrailVirtualNetworkServiceTemplate; + } + + private static Map createGlobalNodeTypes() { + Map globalNodeTypes = new HashMap<>(); + globalNodeTypes.put(ToscaNodeType.CONTRAILV2_VIRTUAL_NETWORK.getDisplayName(), + createContrailVirtualNetworkNodeType()); + return globalNodeTypes; + } + + private static NodeType createContrailVirtualNetworkNodeType() { + NodeType contrailV2VirtualNetworkNodeType = new NodeType(); + contrailV2VirtualNetworkNodeType.setDerived_from(ToscaNodeType.NETWORK.getDisplayName()); + contrailV2VirtualNetworkNodeType.setProperties(createContrailVirtualNetworkProperties()); + contrailV2VirtualNetworkNodeType.setAttributes(createContrailVirtualNetworkAttributes()); + contrailV2VirtualNetworkNodeType.setCapabilities(createContrailVirtualNetworkCapabilities()); + return contrailV2VirtualNetworkNodeType; + } + + private static Map createContrailVirtualNetworkCapabilities() { + Map capabilities = new HashMap<>(); + capabilities.put("attachment", GlobalTypesUtil.createAttachmentCapability()); + return capabilities; + } + + private static Map createContrailVirtualNetworkProperties() { + Map contrailVirtualNetworkPropertyDefMap = new HashMap<>(); + //contrailVirtualNetworkPropertyDefMap.put("name", DataModelUtil. + // createPropertyDefinition(PropertyType.STRING.getDisplayName() + // , "Name", false, null, null, null, null)); + contrailVirtualNetworkPropertyDefMap.put("network_ipam_refs", DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), "IPAM references", false, + null, null, + DataModelUtil.createEntrySchema(PropertyType.STRING.getDisplayName(), null, null), + null)); + contrailVirtualNetworkPropertyDefMap.put("network_ipam_refs_data", DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), "IPAM references Data", false, + null, null, DataModelUtil.createEntrySchema( + ToscaDataType.CONTRAILV2_VIRTUAL_NETWORK_IPAM_REF_DATA.getDisplayName(), null, + null), null)); + contrailVirtualNetworkPropertyDefMap.put("network_policy_refs", DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), "Policy references", false, + null, null, + DataModelUtil.createEntrySchema(PropertyType.STRING.getDisplayName(), null, null), + null)); + contrailVirtualNetworkPropertyDefMap.put("network_policy_refs_data", DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), "Policy references data", + false, null, null, DataModelUtil.createEntrySchema( + ToscaDataType.CONTRAILV2_VIRTUAL_NETWORK_POLICY_REF_DATA.getDisplayName(), null, + null), null)); + contrailVirtualNetworkPropertyDefMap.put("subnets", DataModelUtil + .createPropertyDefinition(PropertyType.MAP.getDisplayName(), "Network related subnets", + false, null, null, DataModelUtil + .createEntrySchema(ToscaDataType.NEUTRON_SUBNET.getDisplayName(), null, null), + null)); + return contrailVirtualNetworkPropertyDefMap; + } + + private static Map createGlobalDataTypes() { + Map globalDataTypes = new HashMap<>(); + globalDataTypes.put(ToscaDataType.CONTRAILV2_VIRTUAL_NETWORK_IPAM_REF_DATA.getDisplayName(), + createVirtualNetworkIpamRefDataDataType()); + globalDataTypes.put( + ToscaDataType.CONTRAILV2_VIRTUAL_NETWORK_IPAM_REF_DATA_IPAM_SUBNET_LIST.getDisplayName(), + createVirtualNetworkIpamRefDataIpanSubnetListDataType()); + globalDataTypes + .put(ToscaDataType.CONTRAILV2_VIRTUAL_NETWORK_IPAM_REF_DATA_IPAM_SUBNET.getDisplayName(), + createVirtualNetworkIpamRefDataIpanSubnetDataType()); + globalDataTypes.put(ToscaDataType.CONTRAILV2_VIRTUAL_NETWORK_POLICY_REF_DATA.getDisplayName(), + createVirtualNetworkPolicyRefDataDataType()); + globalDataTypes + .put(ToscaDataType.CONTRAILV2_VIRTUAL_NETWORK_POLICY_REF_DATA_SEQUENCE.getDisplayName(), + createVirtualNetworkPolicyRefSequenceDataDataType()); + return globalDataTypes; + } + + private static DataType createVirtualNetworkIpamRefDataDataType() { + DataType dataType = new DataType(); + dataType.setDerived_from(ToscaDataType.ROOT.getDisplayName()); + dataType.setDescription("Network Ipam Ref Data"); + Map properties = new HashMap<>(); + + properties.put("network_ipam_refs_data_ipam_subnets", DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), + "Network ipam refs data ipam subnets", false, null, null, DataModelUtil + .createEntrySchema( + ToscaDataType.CONTRAILV2_VIRTUAL_NETWORK_IPAM_REF_DATA_IPAM_SUBNET_LIST + .getDisplayName(), null, null), null)); + dataType.setProperties(properties); + return dataType; + } + + private static DataType createVirtualNetworkIpamRefDataIpanSubnetListDataType() { + DataType dataType = new DataType(); + dataType.setDerived_from(ToscaDataType.ROOT.getDisplayName()); + dataType.setDescription("Network Ipam Ref Data Subnet List"); + Map properties = new HashMap<>(); + + properties.put("network_ipam_refs_data_ipam_subnets_subnet", DataModelUtil + .createPropertyDefinition( + ToscaDataType.CONTRAILV2_VIRTUAL_NETWORK_IPAM_REF_DATA_IPAM_SUBNET.getDisplayName(), + "Network ipam refs data ipam subnets", false, null, null, null, null)); + properties.put("network_ipam_refs_data_ipam_subnets_addr_from_start", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "Network ipam refs data ipam subnets addr from start", false, null, null, null, null)); + + dataType.setProperties(properties); + return dataType; + } + + private static DataType createVirtualNetworkIpamRefDataIpanSubnetDataType() { + DataType dataType = new DataType(); + dataType.setDerived_from(ToscaDataType.ROOT.getDisplayName()); + dataType.setDescription("Network Ipam Ref Data Subnet"); + Map properties = new HashMap<>(); + + properties.put("network_ipam_refs_data_ipam_subnets_subnet_ip_prefix", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "Network ipam refs data ipam subnets ip prefix", false, null, null, null, null)); + properties.put("network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "Network ipam refs data ipam subnets ip prefix len", false, null, null, null, null)); + dataType.setProperties(properties); + return dataType; + } + + + private static DataType createVirtualNetworkPolicyRefDataDataType() { + DataType dataType = new DataType(); + dataType.setDerived_from(ToscaDataType.ROOT.getDisplayName()); + dataType.setDescription("network policy refs data"); + Map properties = new HashMap<>(); + + properties.put("network_policy_refs_data_sequence", DataModelUtil.createPropertyDefinition( + ToscaDataType.CONTRAILV2_VIRTUAL_NETWORK_POLICY_REF_DATA_SEQUENCE.getDisplayName(), + "Network Policy ref data sequence", false, null, null, null, null)); + + + dataType.setProperties(properties); + return dataType; + } + + + private static DataType createVirtualNetworkPolicyRefSequenceDataDataType() { + DataType dataType = new DataType(); + dataType.setDerived_from(ToscaDataType.ROOT.getDisplayName()); + dataType.setDescription("network policy refs data sequence"); + Map properties = new HashMap<>(); + + properties.put("network_policy_refs_data_sequence_major", DataModelUtil + .createPropertyDefinition(PropertyType.INTEGER.getDisplayName(), + "Network Policy ref data sequence Major", false, null, null, null, null)); + properties.put("network_policy_refs_data_sequence_minor", DataModelUtil + .createPropertyDefinition(PropertyType.INTEGER.getDisplayName(), + "Network Policy ref data sequence Minor", false, null, null, null, null)); + + dataType.setProperties(properties); + return dataType; + } + + private static Map createContrailVirtualNetworkAttributes() { + Map contrailVirtualNetworkAttributesDefMap = new HashMap<>(); + contrailVirtualNetworkAttributesDefMap.put("subnets_name", DataModelUtil + .createAttributeDefinition(PropertyType.LIST.getDisplayName(), + "Subnets name of this network", null, + DataModelUtil.createEntrySchema(PropertyType.STRING.getDisplayName(), null, null), + null)); + contrailVirtualNetworkAttributesDefMap.put("subnets", DataModelUtil + .createAttributeDefinition(PropertyType.MAP.getDisplayName(), "Network related subnets", + null, DataModelUtil + .createEntrySchema(ToscaDataType.NEUTRON_SUBNET.getDisplayName(), null, null), + null)); + contrailVirtualNetworkAttributesDefMap.put("subnets_show", DataModelUtil + .createAttributeDefinition(PropertyType.MAP.getDisplayName(), + "Detailed information about each subnet", null, + DataModelUtil.createEntrySchema(PropertyType.STRING.getDisplayName(), null, null), + null)); + contrailVirtualNetworkAttributesDefMap.put("fq_name", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), "fq_name", null, null, + null)); + return contrailVirtualNetworkAttributesDefMap; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/ContrailVirtualNetworkGlobalType.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/ContrailVirtualNetworkGlobalType.java new file mode 100644 index 0000000000..1014757a2c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/ContrailVirtualNetworkGlobalType.java @@ -0,0 +1,134 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.globaltypes; + +import org.openecomp.sdc.tosca.datatypes.ToscaDataType; +import org.openecomp.sdc.tosca.datatypes.ToscaNodeType; +import org.openecomp.sdc.tosca.datatypes.model.AttributeDefinition; +import org.openecomp.sdc.tosca.datatypes.model.CapabilityDefinition; +import org.openecomp.sdc.tosca.datatypes.model.NodeType; +import org.openecomp.sdc.tosca.datatypes.model.PropertyDefinition; +import org.openecomp.sdc.tosca.datatypes.model.PropertyType; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.tosca.services.ToscaConstants; +import org.openecomp.sdc.translator.services.heattotosca.Constants; + +import java.util.HashMap; +import java.util.Map; + +public class ContrailVirtualNetworkGlobalType { + + /** + * Create service template service template. + * + * @return the service template + */ + public static ServiceTemplate createServiceTemplate() { + ServiceTemplate contrailVirtualNetworkServiceTemplate = new ServiceTemplate(); + contrailVirtualNetworkServiceTemplate + .setTosca_definitions_version(ToscaConstants.TOSCA_DEFINITIONS_VERSION); + contrailVirtualNetworkServiceTemplate.setMetadata(DataModelUtil + .createMetadata(Constants.CONTRAIL_VIRTUAL_NETWORK_TEMPLATE_NAME, "1.0.0", null)); + contrailVirtualNetworkServiceTemplate.setDescription("Contrail Virtual Network Global Types"); + contrailVirtualNetworkServiceTemplate.setImports(GlobalTypesUtil.createCommonImportList()); + contrailVirtualNetworkServiceTemplate.setNode_types(createGlobalNodeTypes()); + return contrailVirtualNetworkServiceTemplate; + } + + private static Map createGlobalNodeTypes() { + Map globalNodeTypes = new HashMap<>(); + globalNodeTypes.put(ToscaNodeType.CONTRAIL_VIRTUAL_NETWORK.getDisplayName(), + createContrailVirtualNetworkNodeType()); + return globalNodeTypes; + } + + private static NodeType createContrailVirtualNetworkNodeType() { + NodeType contrailVirtualNetworkNodeType = new NodeType(); + contrailVirtualNetworkNodeType.setDerived_from(ToscaNodeType.NETWORK.getDisplayName()); + contrailVirtualNetworkNodeType.setProperties(createContrailVirtualNetworkProperties()); + contrailVirtualNetworkNodeType.setAttributes(createContrailVirtualNetworkAttributes()); + contrailVirtualNetworkNodeType.setCapabilities(createContrailVirtualNetworkCapabilities()); + return contrailVirtualNetworkNodeType; + } + + private static Map createContrailVirtualNetworkCapabilities() { + Map capabilities = new HashMap<>(); + capabilities.put("attachment", GlobalTypesUtil.createAttachmentCapability()); + return capabilities; + } + + private static Map createContrailVirtualNetworkProperties() { + Map contrailVirtualNetworkPropertyDefMap = new HashMap<>(); + contrailVirtualNetworkPropertyDefMap.put("shared", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Is virtual network shared", + false, null, null, null, null)); + contrailVirtualNetworkPropertyDefMap.put("external", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "Is virtual network external", false, null, null, null, null)); + contrailVirtualNetworkPropertyDefMap.put("allow_transit", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "Whether this network should be transitive.", false, null, null, null, null)); + contrailVirtualNetworkPropertyDefMap.put("route_targets", DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), + "route targets associated with the virtual network", false, null, null, + DataModelUtil.createEntrySchema(PropertyType.STRING.getDisplayName(), null, null), + null)); + contrailVirtualNetworkPropertyDefMap.put("forwarding_mode", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "forwarding mode of the virtual network", false, null, null, null, null)); + contrailVirtualNetworkPropertyDefMap.put("flood_unknown_unicast", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "flood L2 packets on network", false, null, null, null, null)); + contrailVirtualNetworkPropertyDefMap.put("subnets", DataModelUtil + .createPropertyDefinition(PropertyType.MAP.getDisplayName(), "Network related subnets", + false, null, null, DataModelUtil + .createEntrySchema(ToscaDataType.NEUTRON_SUBNET.getDisplayName(), null, null), + null)); + return contrailVirtualNetworkPropertyDefMap; + } + + private static Map createContrailVirtualNetworkAttributes() { + Map contrailVirtualNetworkAttributesDefMap = new HashMap<>(); + contrailVirtualNetworkAttributesDefMap.put("subnets_name", DataModelUtil + .createAttributeDefinition(PropertyType.LIST.getDisplayName(), + "Subnets name of this network", null, + DataModelUtil.createEntrySchema(PropertyType.STRING.getDisplayName(), null, null), + null)); + contrailVirtualNetworkAttributesDefMap.put("subnets", DataModelUtil + .createAttributeDefinition(PropertyType.MAP.getDisplayName(), "Network related subnets", + null, DataModelUtil + .createEntrySchema(ToscaDataType.NEUTRON_SUBNET.getDisplayName(), null, null), + null)); + contrailVirtualNetworkAttributesDefMap.put("subnets_show", DataModelUtil + .createAttributeDefinition(PropertyType.MAP.getDisplayName(), + "Detailed information about each subnet", null, + DataModelUtil.createEntrySchema(PropertyType.STRING.getDisplayName(), null, null), + null)); + contrailVirtualNetworkAttributesDefMap.put("fq_name", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), "fq_name", null, null, + null)); + contrailVirtualNetworkAttributesDefMap.put("show", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), "All attributes.", null, + null, null)); + return contrailVirtualNetworkAttributesDefMap; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/GlobalTypesGenerator.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/GlobalTypesGenerator.java new file mode 100644 index 0000000000..a4ec764e14 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/GlobalTypesGenerator.java @@ -0,0 +1,128 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.globaltypes; + +import org.openecomp.sdc.tosca.datatypes.model.Import; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.services.ToscaNativeTypesServiceTemplate; +import org.openecomp.sdc.tosca.services.ToscaUtil; +import org.openecomp.sdc.translator.services.heattotosca.Constants; + +import java.util.HashMap; +import java.util.Map; + +public class GlobalTypesGenerator { + + private GlobalTypesGenerator() { + } + + /** + * Gets global types service template. + * + * @return the global types service template + */ + public static Map getGlobalTypesServiceTemplate() { + Map serviceTemplates = new HashMap<>(); + + ToscaUtil.addServiceTemplateToMapWithKeyFileName(serviceTemplates, + CommonGlobalTypes.createServiceTemplate()); + ToscaUtil.addServiceTemplateToMapWithKeyFileName(serviceTemplates, + NovaServerGlobalType.createServiceTemplate()); + ToscaUtil.addServiceTemplateToMapWithKeyFileName(serviceTemplates, + CinderVolumeGlobalType.createServiceTemplate()); + ToscaUtil.addServiceTemplateToMapWithKeyFileName(serviceTemplates, + ContrailVirtualNetworkGlobalType.createServiceTemplate()); + ToscaUtil.addServiceTemplateToMapWithKeyFileName(serviceTemplates, + ContrailV2VirtualNetworkGlobalType.createServiceTemplate()); + ToscaUtil.addServiceTemplateToMapWithKeyFileName(serviceTemplates, + ContrailV2VirtualMachineInterfaceGlobalType.createServiceTemplate()); + ToscaUtil.addServiceTemplateToMapWithKeyFileName(serviceTemplates, + NeutronNetGlobalType.createServiceTemplate()); + ToscaUtil.addServiceTemplateToMapWithKeyFileName(serviceTemplates, + NeutronPortGlobalType.createServiceTemplate()); + ToscaUtil.addServiceTemplateToMapWithKeyFileName(serviceTemplates, + ContrailNetworkRuleGlobalType.createServiceTemplate()); + ToscaUtil.addServiceTemplateToMapWithKeyFileName(serviceTemplates, + ContrailV2NetworkRuleGlobalType.createServiceTemplate()); + ToscaUtil.addServiceTemplateToMapWithKeyFileName(serviceTemplates, + NeutronSecurityRulesGlobalType.createServiceTemplate()); + ToscaUtil.addServiceTemplateToMapWithKeyFileName(serviceTemplates, + AbstractSubstituteGlobalType.createServiceTemplate()); + ToscaUtil.addServiceTemplateToMapWithKeyFileName(serviceTemplates, + ToscaNativeTypesServiceTemplate.createServiceTemplate()); + ToscaUtil.addServiceTemplateToMapWithKeyFileName(serviceTemplates, + ContrailComputeGlobalType.createServiceTemplate()); + ToscaUtil.addServiceTemplateToMapWithKeyFileName(serviceTemplates, + ContrailPortGlobalType.createServiceTemplate()); + ToscaUtil.addServiceTemplateToMapWithKeyFileName(serviceTemplates, + ContrailV2NetworkRuleGlobalType.createServiceTemplate()); + ToscaUtil.addServiceTemplateToMapWithKeyFileName(serviceTemplates, + ContrailV2VirtualNetworkGlobalType.createServiceTemplate()); + ToscaUtil.addServiceTemplateToMapWithKeyFileName(serviceTemplates, + ContrailAbstractSubstituteGlobalType.createServiceTemplate()); + return serviceTemplates; + } + + private static void addGlobalServiceTemplate(Map serviceTemplates, + ServiceTemplate commonServiceTemplate) { + serviceTemplates + .put(ToscaUtil.getServiceTemplateFileName(commonServiceTemplate), commonServiceTemplate); + } + + /** + * Gets global types import list. + * + * @return the global types import list + */ + public static Map getGlobalTypesImportList() { + Map globalImportMap = new HashMap<>(); + globalImportMap.put(Constants.COMMON_GLOBAL_TEMPLATE_NAME, + GlobalTypesUtil.createServiceTemplateImport(Constants.COMMON_GLOBAL_TEMPLATE_NAME)); + globalImportMap.put(Constants.NOVA_SERVER_TEMPLATE_NAME, + GlobalTypesUtil.createServiceTemplateImport(Constants.NOVA_SERVER_TEMPLATE_NAME)); + globalImportMap.put(Constants.NEUTRON_PORT_TEMPLATE_NAME, + GlobalTypesUtil.createServiceTemplateImport(Constants.NEUTRON_PORT_TEMPLATE_NAME)); + globalImportMap.put(Constants.NEUTRON_SECURITY_RULES_TEMPLATE_NAME, GlobalTypesUtil + .createServiceTemplateImport(Constants.NEUTRON_SECURITY_RULES_TEMPLATE_NAME)); + globalImportMap.put(Constants.NEUTRON_NET_TEMPLATE_NAME, + GlobalTypesUtil.createServiceTemplateImport(Constants.NEUTRON_NET_TEMPLATE_NAME)); + globalImportMap.put(Constants.CINDER_VOLUME_TEMPLATE_NAME, + GlobalTypesUtil.createServiceTemplateImport(Constants.CINDER_VOLUME_TEMPLATE_NAME)); + globalImportMap.put(Constants.CONTRAIL_VIRTUAL_NETWORK_TEMPLATE_NAME, GlobalTypesUtil + .createServiceTemplateImport(Constants.CONTRAIL_VIRTUAL_NETWORK_TEMPLATE_NAME)); + globalImportMap.put(Constants.CONTRAIL_NETWORK_RULE_TEMPLATE_NAME, + GlobalTypesUtil.createServiceTemplateImport(Constants.CONTRAIL_NETWORK_RULE_TEMPLATE_NAME)); + globalImportMap.put(Constants.ABSTRACT_SUBSTITUTE_TEMPLATE_NAME, + GlobalTypesUtil.createServiceTemplateImport(Constants.ABSTRACT_SUBSTITUTE_TEMPLATE_NAME)); + globalImportMap.put(Constants.CONTRAILV2_VIRTUAL_MACHINE_INTERFACE_TEMPLATE_NAME, + GlobalTypesUtil.createServiceTemplateImport( + Constants.CONTRAILV2_VIRTUAL_MACHINE_INTERFACE_TEMPLATE_NAME)); + globalImportMap.put(Constants.CONTRAIL_COMPUTE_TEMPLATE_NAME, + GlobalTypesUtil.createServiceTemplateImport(Constants.CONTRAIL_COMPUTE_TEMPLATE_NAME)); + globalImportMap.put(Constants.CONTRAIL_PORT_TEMPLATE_NAME, + GlobalTypesUtil.createServiceTemplateImport(Constants.CONTRAIL_PORT_TEMPLATE_NAME)); + globalImportMap.put(Constants.CONTRAIL_ABSTRACT_SUBSTITUTE_TEMPLATE_NAME, GlobalTypesUtil + .createServiceTemplateImport(Constants.CONTRAIL_ABSTRACT_SUBSTITUTE_TEMPLATE_NAME)); + return globalImportMap; + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/GlobalTypesUtil.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/GlobalTypesUtil.java new file mode 100644 index 0000000000..9566dec581 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/GlobalTypesUtil.java @@ -0,0 +1,69 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.globaltypes; + + +import org.openecomp.sdc.tosca.datatypes.ToscaCapabilityType; +import org.openecomp.sdc.tosca.datatypes.model.CapabilityDefinition; +import org.openecomp.sdc.tosca.datatypes.model.Import; +import org.openecomp.sdc.tosca.services.ToscaUtil; + +import java.util.HashMap; +import java.util.Map; + +public class GlobalTypesUtil { + + + /** + * Create common import list map. + * + * @return the map + */ + public static Map createCommonImportList() { + Map importsMap = new HashMap<>(); + importsMap.put("common_definitions", CommonGlobalTypes.createCommonServiceTemplateImport()); + return importsMap; + } + + /** + * Create attachment capability capability definition. + * + * @return the capability definition + */ + public static CapabilityDefinition createAttachmentCapability() { + CapabilityDefinition capability = new CapabilityDefinition(); + capability.setType(ToscaCapabilityType.ATTACHMENT.getDisplayName()); + + return capability; + } + + /** + * Create service template import import. + * + * @param serviceTemplateName the service template name + * @return the import + */ + public static Import createServiceTemplateImport(String serviceTemplateName) { + Import serviceTemplateImport = new Import(); + serviceTemplateImport.setFile(ToscaUtil.getServiceTemplateFileName(serviceTemplateName)); + return serviceTemplateImport; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/NeutronNetGlobalType.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/NeutronNetGlobalType.java new file mode 100644 index 0000000000..2532f87cf5 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/NeutronNetGlobalType.java @@ -0,0 +1,143 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.globaltypes; + +import org.openecomp.sdc.tosca.datatypes.ToscaDataType; +import org.openecomp.sdc.tosca.datatypes.ToscaNodeType; +import org.openecomp.sdc.tosca.datatypes.model.AttributeDefinition; +import org.openecomp.sdc.tosca.datatypes.model.CapabilityDefinition; +import org.openecomp.sdc.tosca.datatypes.model.NodeType; +import org.openecomp.sdc.tosca.datatypes.model.PropertyDefinition; +import org.openecomp.sdc.tosca.datatypes.model.PropertyType; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.tosca.services.ToscaConstants; +import org.openecomp.sdc.translator.services.heattotosca.Constants; + +import java.util.HashMap; +import java.util.Map; + +public class NeutronNetGlobalType { + /** + * Create service template service template. + * + * @return the service template + */ + public static ServiceTemplate createServiceTemplate() { + ServiceTemplate neutronNetServiceTemplate = new ServiceTemplate(); + neutronNetServiceTemplate + .setTosca_definitions_version(ToscaConstants.TOSCA_DEFINITIONS_VERSION); + neutronNetServiceTemplate.setMetadata( + DataModelUtil.createMetadata(Constants.NEUTRON_NET_TEMPLATE_NAME, "1.0.0", null)); + neutronNetServiceTemplate.setDescription("Neutron Network TOSCA Global Types"); + neutronNetServiceTemplate.setImports(GlobalTypesUtil.createCommonImportList()); + neutronNetServiceTemplate.setNode_types(createGlobalNodeTypes()); + return neutronNetServiceTemplate; + } + + + private static Map createGlobalNodeTypes() { + Map globalNodeTypes = new HashMap<>(); + globalNodeTypes.put(ToscaNodeType.NEUTRON_NET.getDisplayName(), createNeutronNetworkNodeType()); + return globalNodeTypes; + } + + private static NodeType createNeutronNetworkNodeType() { + NodeType neutronNetworkNode = new NodeType(); + neutronNetworkNode.setDerived_from(ToscaNodeType.NETWORK.getDisplayName()); + neutronNetworkNode.setProperties(createNeutronNetworkProperties()); + neutronNetworkNode.setAttributes(createNeutronNetworkAttributes()); + neutronNetworkNode.setCapabilities(createNeutronNetworkCapabilities()); + + return neutronNetworkNode; + } + + private static Map createNeutronNetworkCapabilities() { + Map capabilities = new HashMap<>(); + capabilities.put("attachment", GlobalTypesUtil.createAttachmentCapability()); + return capabilities; + } + + private static Map createNeutronNetworkProperties() { + Map neutronNetworkPropertyDefMap = new HashMap<>(); + neutronNetworkPropertyDefMap.put("admin_state_up", DataModelUtil + .createPropertyDefinition(PropertyType.BOOLEAN.getDisplayName(), + "A boolean value specifying the administrative status of the network", false, null, + null, null, true)); + neutronNetworkPropertyDefMap.put("dhcp_agent_ids", DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), + "The IDs of the DHCP agent to schedule the network", false, null, null, + DataModelUtil.createEntrySchema(PropertyType.STRING.getDisplayName(), null, null), + null)); + neutronNetworkPropertyDefMap.put("port_security_enabled", DataModelUtil + .createPropertyDefinition(PropertyType.BOOLEAN.getDisplayName(), + "Flag to enable/disable port security on the network", false, null, null, null, null)); + neutronNetworkPropertyDefMap.put("qos_policy", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "The name or ID of QoS policy to attach to this network", false, null, null, null, + null)); + neutronNetworkPropertyDefMap.put("shared", DataModelUtil + .createPropertyDefinition(PropertyType.BOOLEAN.getDisplayName(), + "Whether this network should be shared across all tenants", false, null, null, null, + false)); + neutronNetworkPropertyDefMap.put("tenant_id", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "The ID of the tenant which will own the network", false, null, null, null, null)); + neutronNetworkPropertyDefMap.put("value_specs", DataModelUtil + .createPropertyDefinition(PropertyType.MAP.getDisplayName(), + "Extra parameters to include in the request", false, null, null, + DataModelUtil.createEntrySchema(PropertyType.STRING.getDisplayName(), null, null), + new HashMap())); + neutronNetworkPropertyDefMap.put("subnets", DataModelUtil + .createPropertyDefinition(PropertyType.MAP.getDisplayName(), "Network related subnets", + false, null, null, DataModelUtil + .createEntrySchema(ToscaDataType.NEUTRON_SUBNET.getDisplayName(), null, null), + null)); + return neutronNetworkPropertyDefMap; + } + + private static Map createNeutronNetworkAttributes() { + Map neutronNetworkAttributesDefMap = new HashMap<>(); + neutronNetworkAttributesDefMap.put("mtu", DataModelUtil + .createAttributeDefinition(PropertyType.SCALAR_UNIT_SIZE.getDisplayName(), + "The maximum transmission unit size(in bytes) for the network", null, null, null)); + neutronNetworkAttributesDefMap.put("qos_policy_id", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), + "The QoS policy ID attached to this network", null, null, null)); + neutronNetworkAttributesDefMap.put("show", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), + "Detailed information about resource", null, null, null)); + neutronNetworkAttributesDefMap.put("status", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), + "The status of the network", null, null, null)); + neutronNetworkAttributesDefMap.put("subnets_name", DataModelUtil + .createAttributeDefinition(PropertyType.LIST.getDisplayName(), + "Subnets name of this network", null, + DataModelUtil.createEntrySchema(PropertyType.STRING.getDisplayName(), null, null), + null)); + neutronNetworkAttributesDefMap.put("subnets", DataModelUtil + .createAttributeDefinition(PropertyType.MAP.getDisplayName(), "Network related subnets", + null, DataModelUtil + .createEntrySchema(ToscaDataType.NEUTRON_SUBNET.getDisplayName(), null, null), + null)); + return neutronNetworkAttributesDefMap; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/NeutronPortGlobalType.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/NeutronPortGlobalType.java new file mode 100644 index 0000000000..2106b9b3bc --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/NeutronPortGlobalType.java @@ -0,0 +1,203 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.globaltypes; + +import org.openecomp.sdc.tosca.datatypes.ToscaDataType; +import org.openecomp.sdc.tosca.datatypes.ToscaNodeType; +import org.openecomp.sdc.tosca.datatypes.model.AttributeDefinition; +import org.openecomp.sdc.tosca.datatypes.model.CapabilityDefinition; +import org.openecomp.sdc.tosca.datatypes.model.Constraint; +import org.openecomp.sdc.tosca.datatypes.model.DataType; +import org.openecomp.sdc.tosca.datatypes.model.NodeType; +import org.openecomp.sdc.tosca.datatypes.model.PropertyDefinition; +import org.openecomp.sdc.tosca.datatypes.model.PropertyType; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.tosca.services.ToscaConstants; +import org.openecomp.sdc.translator.services.heattotosca.Constants; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +public class NeutronPortGlobalType { + /** + * Create service template service template. + * + * @return the service template + */ + public static ServiceTemplate createServiceTemplate() { + ServiceTemplate neutronPortServiceTemplate = new ServiceTemplate(); + neutronPortServiceTemplate + .setTosca_definitions_version(ToscaConstants.TOSCA_DEFINITIONS_VERSION); + neutronPortServiceTemplate.setMetadata( + DataModelUtil.createMetadata(Constants.NEUTRON_PORT_TEMPLATE_NAME, "1.0.0", null)); + neutronPortServiceTemplate.setImports(GlobalTypesUtil.createCommonImportList()); + neutronPortServiceTemplate.setDescription("Neutron Port TOSCA Global Types"); + neutronPortServiceTemplate.setData_types(createGlobalDataTypes()); + neutronPortServiceTemplate.setNode_types(createGlobalNodeTypes()); + return neutronPortServiceTemplate; + } + + private static Map createGlobalDataTypes() { + Map globalDataTypes = new HashMap<>(); + globalDataTypes + .put(ToscaDataType.NEUTRON_PORT_FIXED_IPS.getDisplayName(), createFixedIpsDataType()); + return globalDataTypes; + } + + private static DataType createFixedIpsDataType() { + DataType dataType = new DataType(); + dataType.setDerived_from(ToscaDataType.ROOT.getDisplayName()); + dataType.setDescription("subnet/ip_address"); + Map prop = new HashMap<>(); + + prop.put("subnet", DataModelUtil.createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "Subnet in which to allocate the IP address for this port", false, null, null, null, null)); + prop.put("ip_address", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "IP address desired in the subnet for this port", false, null, null, null, null)); + + dataType.setProperties(prop); + return dataType; + } + + private static Map createGlobalNodeTypes() { + Map globalNodeTypes = new HashMap<>(); + globalNodeTypes.put(ToscaNodeType.NEUTRON_PORT.getDisplayName(), createNeutronPortNodeType()); + return globalNodeTypes; + } + + private static NodeType createNeutronPortNodeType() { + NodeType nodeType = new NodeType(); + nodeType.setDerived_from(ToscaNodeType.NETWORK_PORT.getDisplayName()); + nodeType.setProperties(createNeutronPortProperties()); + nodeType.setAttributes(createNeutronPortAttributes()); + nodeType.setCapabilities(createNeutronPortCapabilities()); + return nodeType; + } + + private static Map createNeutronPortCapabilities() { + Map capabilities = new HashMap<>(); + capabilities.put("attachment", GlobalTypesUtil.createAttachmentCapability()); + return capabilities; + } + + private static Map createNeutronPortProperties() { + Map neutronPortPropertyDefMap = new HashMap<>(); + neutronPortPropertyDefMap.put("admin_state_up", DataModelUtil + .createPropertyDefinition(PropertyType.BOOLEAN.getDisplayName(), + "A boolean value specifying the administrative status of the network", false, null, + null, null, true)); + neutronPortPropertyDefMap.put("allowed_address_pairs", DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), + "Additional MAC/IP address pairs allowed to pass through the port", false, null, null, + DataModelUtil + .createEntrySchema(ToscaDataType.NETWORK_ADDRESS_PAIR.getDisplayName(), null, null), + null)); + neutronPortPropertyDefMap.put("binding:vnic_type", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "The vnic type to be bound on the neutron port", false, createBindingConstraint(), null, + null, null)); + neutronPortPropertyDefMap.put("device_id", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Device ID of this port", + false, null, null, null, null)); + neutronPortPropertyDefMap.put("device_owner", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "Name of the network owning the port", false, null, null, null, null)); + neutronPortPropertyDefMap.put("fixed_ips", DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), "Desired IPs for this port", + false, null, null, DataModelUtil + .createEntrySchema(ToscaDataType.NEUTRON_PORT_FIXED_IPS.getDisplayName(), null, + null), null)); + neutronPortPropertyDefMap.put("mac_address", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "MAC address to give to this port", false, null, null, null, null)); + neutronPortPropertyDefMap.put(Constants.NAME_PROPERTY_NAME, DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "A symbolic name for this port", false, null, null, null, null)); + neutronPortPropertyDefMap.put("port_security_enabled", DataModelUtil + .createPropertyDefinition(PropertyType.BOOLEAN.getDisplayName(), + "Flag to enable/disable port security on the network", false, null, null, null, null)); + neutronPortPropertyDefMap.put("qos_policy", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "The name or ID of QoS policy to attach to this network", false, null, null, null, + null)); + neutronPortPropertyDefMap.put(Constants.SECURITY_GROUPS_PROPERTY_NAME, DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), + "List of security group names or IDs", false, null, null, + DataModelUtil.createEntrySchema(PropertyType.STRING.getDisplayName(), null, null), + null)); + neutronPortPropertyDefMap.put("value_specs", DataModelUtil + .createPropertyDefinition(PropertyType.MAP.getDisplayName(), + "Extra parameters to include in the request", false, null, null, + DataModelUtil.createEntrySchema(PropertyType.STRING.getDisplayName(), null, null), + new HashMap())); + neutronPortPropertyDefMap.put("replacement_policy", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "Policy on how to respond to a stack-update for this resource", false, + createReplacementPolicyConstrain(), null, null, "AUTO")); + neutronPortPropertyDefMap.put("network", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "Network this port belongs to", false, null, null, null, null)); + return neutronPortPropertyDefMap; + } + + private static List createBindingConstraint() { + List constraints = new ArrayList<>(); + Constraint validValues = + DataModelUtil.createValidValuesConstraint("macvtap", "direct", "normal"); + constraints.add(validValues); + return constraints; + } + + private static List createReplacementPolicyConstrain() { + List constraints = new ArrayList<>(); + Constraint validValues = DataModelUtil.createValidValuesConstraint("REPLACE_ALWAYS", "AUTO"); + constraints.add(validValues); + return constraints; + } + + private static Map createNeutronPortAttributes() { + Map neutronPortAttributesDefMap = new HashMap<>(); + neutronPortAttributesDefMap.put("network_id", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), + "Unique identifier for the network owning the port", null, null, null)); + neutronPortAttributesDefMap.put("qos_policy_id", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), + "The QoS policy ID attached to this network", null, null, null)); + neutronPortAttributesDefMap.put("show", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), + "Detailed information about resource", null, null, null)); + neutronPortAttributesDefMap.put("status", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), + "The status of the network", null, null, null)); + neutronPortAttributesDefMap.put("subnets", DataModelUtil + .createAttributeDefinition(PropertyType.LIST.getDisplayName(), "Subnets of this network", + null, DataModelUtil.createEntrySchema(PropertyType.STRING.getDisplayName(), null, null), + null)); + neutronPortAttributesDefMap.put("tenant_id", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), "Tenant owning the port", + null, null, null)); + return neutronPortAttributesDefMap; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/NeutronSecurityRulesGlobalType.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/NeutronSecurityRulesGlobalType.java new file mode 100644 index 0000000000..4c5b033e0e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/NeutronSecurityRulesGlobalType.java @@ -0,0 +1,175 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.globaltypes; + +import org.openecomp.sdc.tosca.datatypes.ToscaCapabilityType; +import org.openecomp.sdc.tosca.datatypes.ToscaDataType; +import org.openecomp.sdc.tosca.datatypes.ToscaNodeType; +import org.openecomp.sdc.tosca.datatypes.ToscaRelationshipType; +import org.openecomp.sdc.tosca.datatypes.model.AttributeDefinition; +import org.openecomp.sdc.tosca.datatypes.model.Constraint; +import org.openecomp.sdc.tosca.datatypes.model.DataType; +import org.openecomp.sdc.tosca.datatypes.model.NodeType; +import org.openecomp.sdc.tosca.datatypes.model.PropertyDefinition; +import org.openecomp.sdc.tosca.datatypes.model.PropertyType; +import org.openecomp.sdc.tosca.datatypes.model.RequirementDefinition; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.tosca.services.ToscaConstants; +import org.openecomp.sdc.translator.services.heattotosca.Constants; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +public class NeutronSecurityRulesGlobalType { + /** + * Create service template service template. + * + * @return the service template + */ + public static ServiceTemplate createServiceTemplate() { + ServiceTemplate neutronSecurityRulesServiceTemplate = new ServiceTemplate(); + neutronSecurityRulesServiceTemplate + .setTosca_definitions_version(ToscaConstants.TOSCA_DEFINITIONS_VERSION); + neutronSecurityRulesServiceTemplate.setMetadata(DataModelUtil + .createMetadata(Constants.NEUTRON_SECURITY_RULES_TEMPLATE_NAME, "1.0.0", null)); + neutronSecurityRulesServiceTemplate.setImports(GlobalTypesUtil.createCommonImportList()); + neutronSecurityRulesServiceTemplate.setDescription("Neutron Security Rules TOSCA Global Types"); + neutronSecurityRulesServiceTemplate.setData_types(createGlobalDataTypes()); + neutronSecurityRulesServiceTemplate.setNode_types(createGlobalNodeTypes()); + return neutronSecurityRulesServiceTemplate; + } + + + private static Map createGlobalDataTypes() { + Map globalDataTypes = new HashMap<>(); + globalDataTypes.put(ToscaDataType.NEUTRON_SECURITY_RULES_RULE.getDisplayName(), + createSecurityRulesDataType()); + return globalDataTypes; + } + + private static DataType createSecurityRulesDataType() { + DataType addressPairDataType = new DataType(); + addressPairDataType.setDerived_from(ToscaDataType.ROOT.getDisplayName()); + addressPairDataType.setDescription("Rules Pairs"); + Map addressPairProp = new HashMap<>(); + + addressPairProp.put("direction", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "The direction in which the security group rule is applied", false, + DataModelUtil.createValidValuesConstraintsList("egress", "ingress"), null, null, + "ingress")); + addressPairProp.put("ethertype", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Ethertype of the traffic", + false, DataModelUtil.createValidValuesConstraintsList("IPv4", "IPv6"), null, null, + "IPv4")); + Constraint portRangeMaxConstraint = new Constraint(); + portRangeMaxConstraint.setIn_range(new Integer[]{0, 65535}); + addressPairProp.put("port_range_max", DataModelUtil + .createPropertyDefinition(PropertyType.INTEGER.getDisplayName(), + "The maximum port number in the range that is matched by the security group rule. ", + false, DataModelUtil.getConstrainList(portRangeMaxConstraint), null, null, null)); + Constraint portRangeMinConstraint = new Constraint(); + portRangeMinConstraint.setIn_range(new Integer[]{0, 65535}); + addressPairProp.put("port_range_min", DataModelUtil + .createPropertyDefinition(PropertyType.INTEGER.getDisplayName(), + "The minimum port number in the range that is matched by the security group rule.", + false, DataModelUtil.getConstrainList(portRangeMinConstraint), null, null, null)); + addressPairProp.put("protocol", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "The protocol that is matched by the security group rule", false, + DataModelUtil.createValidValuesConstraintsList("tcp", "udp", "icmp"), null, null, + null)); + addressPairProp.put("remote_group_id", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "The remote group ID to be associated with this security group rule", false, null, null, + null, null)); + addressPairProp.put("remote_ip_prefix", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "The remote IP prefix (CIDR) to be associated with this security group rule", false, + null, null, null, null)); + addressPairProp.put("remote_mode", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "Whether to specify a remote group or a remote IP prefix", false, + DataModelUtil.createValidValuesConstraintsList("remote_ip_prefix", "remote_group_id"), + null, null, "remote_ip_prefix")); + addressPairDataType.setProperties(addressPairProp); + + return addressPairDataType; + } + + private static Map createGlobalNodeTypes() { + Map globalNodeTypes = new HashMap<>(); + globalNodeTypes.put(ToscaNodeType.NEUTRON_SECURITY_RULES.getDisplayName(), + createNeutronSecurityRulesNodeType()); + return globalNodeTypes; + } + + private static NodeType createNeutronSecurityRulesNodeType() { + NodeType novaServerNodeType = new NodeType(); + novaServerNodeType.setDerived_from(ToscaNodeType.ROOT.getDisplayName()); + novaServerNodeType.setProperties(createNeutronSecurityRulesProperties()); + novaServerNodeType.setAttributes(createNeutronSecurityRulesAttributes()); + novaServerNodeType.setRequirements(createNeutronSecurityRequirements()); + return novaServerNodeType; + } + + private static List> createNeutronSecurityRequirements() { + final List> requirements = new ArrayList<>(); + final Map portRequirement = new HashMap<>(); + RequirementDefinition requirementDefinition = new RequirementDefinition(); + requirementDefinition.setCapability(ToscaCapabilityType.ATTACHMENT.getDisplayName()); + requirementDefinition.setNode(ToscaNodeType.NEUTRON_PORT.getDisplayName()); + requirementDefinition.setRelationship(ToscaRelationshipType.ATTACHES_TO.getDisplayName()); + requirementDefinition.setOccurrences(new Object[]{0, ToscaConstants.UNBOUNDED}); + portRequirement.put(ToscaConstants.PORT_REQUIREMENT_ID, requirementDefinition); + requirements.add(portRequirement); + + return requirements; + } + + private static Map createNeutronSecurityRulesProperties() { + Map neutronSecurityRulesPropertyDefMap = new HashMap<>(); + neutronSecurityRulesPropertyDefMap.put(Constants.NAME_PROPERTY_NAME, DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "A symbolic name for this security group, which is not required to be unique.", false, + null, null, null, null)); + neutronSecurityRulesPropertyDefMap.put(Constants.DESCRIPTION_PROPERTY_NAME, DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "Description of the security group", false, null, null, null, null)); + neutronSecurityRulesPropertyDefMap.put(Constants.RULES_PROPERTY_NAME, DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), + "List of security group rules", false, null, null, DataModelUtil + .createEntrySchema(ToscaDataType.NEUTRON_SECURITY_RULES_RULE.getDisplayName(), null, + null), null)); + return neutronSecurityRulesPropertyDefMap; + } + + private static Map createNeutronSecurityRulesAttributes() { + Map neutronSecurityRulesAttributesDefMap = new HashMap<>(); + neutronSecurityRulesAttributesDefMap.put("show", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), + "Detailed information about resource", null, null, null)); + return neutronSecurityRulesAttributesDefMap; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/NovaServerGlobalType.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/NovaServerGlobalType.java new file mode 100644 index 0000000000..d38d70a4f7 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/globaltypes/NovaServerGlobalType.java @@ -0,0 +1,307 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.globaltypes; + +import org.openecomp.sdc.tosca.datatypes.ToscaDataType; +import org.openecomp.sdc.tosca.datatypes.ToscaNodeType; +import org.openecomp.sdc.tosca.datatypes.model.AttributeDefinition; +import org.openecomp.sdc.tosca.datatypes.model.Constraint; +import org.openecomp.sdc.tosca.datatypes.model.DataType; +import org.openecomp.sdc.tosca.datatypes.model.NodeType; +import org.openecomp.sdc.tosca.datatypes.model.PropertyDefinition; +import org.openecomp.sdc.tosca.datatypes.model.PropertyType; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.datatypes.model.heatextend.PropertyTypeExt; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.tosca.services.ToscaConstants; +import org.openecomp.sdc.translator.services.heattotosca.Constants; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +public class NovaServerGlobalType { + + /** + * Create service template service template. + * + * @return the service template + */ + public static ServiceTemplate createServiceTemplate() { + ServiceTemplate novaeServerServiceTemplate = new ServiceTemplate(); + novaeServerServiceTemplate + .setTosca_definitions_version(ToscaConstants.TOSCA_DEFINITIONS_VERSION); + novaeServerServiceTemplate.setMetadata( + DataModelUtil.createMetadata(Constants.NOVA_SERVER_TEMPLATE_NAME, "1.0.0", null)); + novaeServerServiceTemplate.setDescription("Nova Server TOSCA Global Types"); + novaeServerServiceTemplate.setImports(GlobalTypesUtil.createCommonImportList()); + novaeServerServiceTemplate.setData_types(createGlobalDataTypes()); + novaeServerServiceTemplate.setNode_types(createGlobalNodeTypes()); + return novaeServerServiceTemplate; + } + + + private static Map createGlobalNodeTypes() { + Map globalNodeTypes = new HashMap<>(); + globalNodeTypes.put(ToscaNodeType.NOVA_SERVER.getDisplayName(), createNovaServerNodeType()); + return globalNodeTypes; + } + + private static NodeType createNovaServerNodeType() { + NodeType novaServerNodeType = new NodeType(); + novaServerNodeType.setDerived_from(ToscaNodeType.COMPUTE.getDisplayName()); + novaServerNodeType.setProperties(createNovaServerProperties()); + novaServerNodeType.setAttributes(createNovaServerAttributes()); + return novaServerNodeType; + } + + + private static Map createNovaServerProperties() { + Map novaServerPropertyDefMap = new HashMap<>(); + novaServerPropertyDefMap.put("flavor", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "The ID or name of the flavor to boot onto", true, null, null, null, null)); + novaServerPropertyDefMap.put("admin_pass", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "The administrator password for the server", false, null, null, null, null)); + novaServerPropertyDefMap.put("availability_zone", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "Availability zone to create servers in", false, null, null, null, null)); + novaServerPropertyDefMap.put("config_drive", DataModelUtil + .createPropertyDefinition(PropertyType.BOOLEAN.getDisplayName(), + "enable config drive on the server", false, null, null, null, null)); + novaServerPropertyDefMap.put("contrail_service_instance_ind", DataModelUtil + .createPropertyDefinition(PropertyType.BOOLEAN.getDisplayName(), + "Nova server related to service instance indicator", false, null, null, null, false)); + novaServerPropertyDefMap.put("diskConfig", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "Control how the disk is partitioned when the server is created", false, + getDiskConfigConstraints(), null, null, null)); + novaServerPropertyDefMap.put("flavor_update_policy", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "Policy on how to apply a flavor update", false, getFlavorUpdatePolicyConstraints(), + null, null, "RESIZE")); + novaServerPropertyDefMap.put("image", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "The ID or name of the image to boot with", false, null, null, null, null)); + novaServerPropertyDefMap.put("image_update_policy", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "Policy on how to apply an image-id update", false, getImageUpdatePolicyConstraints(), + null, null, "REBUILD")); + novaServerPropertyDefMap.put("key_name", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "Name of keypair to inject into the server", false, null, null, null, null)); + novaServerPropertyDefMap.put("metadata", DataModelUtil + .createPropertyDefinition(PropertyTypeExt.JSON.getDisplayName(), + "Arbitrary JSON metadata to store for this server", false, null, null, null, null)); + novaServerPropertyDefMap.put(Constants.NAME_PROPERTY_NAME, DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Server name", false, null, + null, null, null)); + novaServerPropertyDefMap.put("personality", DataModelUtil + .createPropertyDefinition(PropertyType.MAP.getDisplayName(), + "A map of files to create/overwrite on the server upon boot", false, null, null, + DataModelUtil.createEntrySchema(PropertyType.STRING.getDisplayName(), null, null), + new HashMap())); + novaServerPropertyDefMap.put("reservation_id", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "A UUID for the set of servers being requested", false, null, null, null, null)); + novaServerPropertyDefMap.put("scheduler_hints", DataModelUtil + .createPropertyDefinition(PropertyType.MAP.getDisplayName(), + "Arbitrary key-value pairs specified by the client to help boot a server", false, null, + null, DataModelUtil.createEntrySchema(PropertyType.STRING.getDisplayName(), null, null), + null)); + novaServerPropertyDefMap.put(Constants.SECURITY_GROUPS_PROPERTY_NAME, DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), + "List of security group names or IDs", false, null, null, + DataModelUtil.createEntrySchema(PropertyType.STRING.getDisplayName(), null, null), + new ArrayList<>())); + novaServerPropertyDefMap.put("software_config_transport", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "How the server should receive the metadata required for software configuration", false, + getSoftwareConfigTransportConstraints(), null, null, "POLL_SERVER_CFN")); + novaServerPropertyDefMap.put("user_data", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "User data script to be executed by cloud-init", false, null, null, null, "")); + novaServerPropertyDefMap.put("user_data_format", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "How the user_data should be formatted for the server", false, + getUserDataFormatConstraint(), null, null, "HEAT_CFNTOOLS")); + novaServerPropertyDefMap.put("user_data_update_policy", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "Policy on how to apply a user_data update", false, + getUserDataUpdatePolicyConstraints(), null, null, "REPLACE")); + return novaServerPropertyDefMap; + } + + private static Map createNovaServerAttributes() { + Map novaServerAttributesDefMap = new HashMap<>(); + novaServerAttributesDefMap.put("accessIPv4", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), + "The manually assigned alternative public IPv4 address of the server", null, null, + null)); + novaServerAttributesDefMap.put("accessIPv6", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), + "The manually assigned alternative public IPv6 address of the server", null, null, + null)); + novaServerAttributesDefMap.put("addresses", DataModelUtil + .createAttributeDefinition(PropertyType.MAP.getDisplayName(), + "A dict of all network addresses with corresponding port_id", null, DataModelUtil + .createEntrySchema(ToscaDataType.NOVA_SERVER_NETWORK_ADDRESS_INFO.getDisplayName(), + null, null), null)); + novaServerAttributesDefMap.put("console_urls", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), "URLs of servers consoles", + null, null, null)); + novaServerAttributesDefMap.put("instance_name", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), + "AWS compatible instance name", null, null, null)); + novaServerAttributesDefMap.put(Constants.NAME_PROPERTY_NAME, DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), "Name of the server", null, + null, null)); + novaServerAttributesDefMap.put("show", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), + "Detailed information about resource", null, null, null)); + return novaServerAttributesDefMap; + } + + private static List getUserDataFormatConstraint() { + List constraints; + Constraint validValues; + constraints = new ArrayList<>(); + validValues = + DataModelUtil.createValidValuesConstraint("SOFTWARE_CONFIG", "RAW", "HEAT_CFNTOOLS"); + constraints.add(validValues); + return constraints; + } + + private static List getUserDataUpdatePolicyConstraints() { + List constraints; + Constraint validValues; + constraints = new ArrayList<>(); + validValues = DataModelUtil.createValidValuesConstraint("REPLACE", "IGNORE"); + constraints.add(validValues); + return constraints; + } + + private static List getSoftwareConfigTransportConstraints() { + List constraints; + Constraint validValues; + constraints = new ArrayList<>(); + validValues = DataModelUtil + .createValidValuesConstraint("POLL_SERVER_CFN", "POLL_SERVER_HEAT", "POLL_TEMP_URL", + "ZAQAR_MESSAGE"); + constraints.add(validValues); + return constraints; + } + + private static List getImageUpdatePolicyConstraints() { + List constraints; + Constraint validValues; + constraints = new ArrayList<>(); + validValues = DataModelUtil + .createValidValuesConstraint("REBUILD_PRESERVE_EPHEMERAL", "REPLACE", "REBUILD"); + constraints.add(validValues); + return constraints; + } + + private static List getFlavorUpdatePolicyConstraints() { + Constraint validValues; + List constraints = new ArrayList<>(); + validValues = DataModelUtil.createValidValuesConstraint("RESIZE", "REPLACE"); + constraints.add(validValues); + return constraints; + } + + private static List getDiskConfigConstraints() { + List constraints = new ArrayList<>(); + Constraint validValues = DataModelUtil.createValidValuesConstraint("AUTO", "MANUAL"); + constraints.add(validValues); + return constraints; + } + + private static Map createGlobalDataTypes() { + Map globalDataTypes = new HashMap<>(); + globalDataTypes.put(ToscaDataType.NOVA_SERVER_PORT_EXTRA_PROPERTIES.getDisplayName(), + createPortExtraDataDataType()); + globalDataTypes.put(ToscaDataType.NOVA_SERVER_NETWORK_ADDRESS_INFO.getDisplayName(), + createAddressInfoDataType()); + return globalDataTypes; + } + + private static DataType createAddressInfoDataType() { + DataType addressInfoDataType = new DataType(); + addressInfoDataType.setDerived_from(ToscaDataType.NETWORK_NETWORK_INFO.getDisplayName()); + addressInfoDataType.setDescription("Network addresses with corresponding port id"); + + Map addressInfoProp = new HashMap<>(); + addressInfoProp.put("port_id", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), "Port id", false, null, + null, null, null)); + addressInfoDataType.setProperties(addressInfoProp); + + return addressInfoDataType; + } + + + private static DataType createPortExtraDataDataType() { + DataType portExtraDataType = new DataType(); + portExtraDataType.setDerived_from(ToscaDataType.ROOT.getDisplayName()); + portExtraDataType.setDescription("Nova server network expand properties for port"); + Map portExtraPropMap = new HashMap<>(); + + portExtraPropMap.put("admin_state_up", DataModelUtil + .createPropertyDefinition(PropertyType.BOOLEAN.getDisplayName(), + "The administrative state of this port", false, null, null, null, true)); + portExtraPropMap.put("allowed_address_pairs", DataModelUtil + .createPropertyDefinition(PropertyType.LIST.getDisplayName(), + "Additional MAC/IP address pairs allowed to pass through the port", false, null, null, + DataModelUtil + .createEntrySchema(ToscaDataType.NETWORK_ADDRESS_PAIR.getDisplayName(), null, null), + null)); + + List bindingVnicConstraints = new ArrayList<>(); + Constraint validValues = + DataModelUtil.createValidValuesConstraint("macvtap", "direct", "normal"); + bindingVnicConstraints.add(validValues); + portExtraPropMap.put("binding:vnic_type", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "The vnic type to be bound on the neutron port", false, bindingVnicConstraints, null, + null, null)); + + portExtraPropMap.put("mac_address", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "MAC address to give to this port", false, null, null, null, null)); + portExtraPropMap.put("port_security_enabled", DataModelUtil + .createPropertyDefinition(PropertyType.BOOLEAN.getDisplayName(), + "Flag to enable/disable port security on the port", false, null, null, null, null)); + portExtraPropMap.put("qos_policy", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), + "The name or ID of QoS policy to attach to this port", false, null, null, null, null)); + portExtraPropMap.put("value_specs", DataModelUtil + .createPropertyDefinition(PropertyType.MAP.getDisplayName(), + "Extra parameters to include in the request", false, null, null, + DataModelUtil.createEntrySchema(PropertyType.STRING.getDisplayName(), null, null), + new HashMap())); + portExtraDataType.setProperties(portExtraPropMap); + return portExtraDataType; + } + +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/helper/ContrailTranslationHelper.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/helper/ContrailTranslationHelper.java new file mode 100644 index 0000000000..2e1aa9e372 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/helper/ContrailTranslationHelper.java @@ -0,0 +1,65 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.helper; + +import org.openecomp.sdc.heat.datatypes.model.Resource; +import org.openecomp.sdc.tosca.services.ToscaConstants; +import org.openecomp.sdc.translator.services.heattotosca.helper.impl.NameExtractorServiceImpl; + +import java.util.ArrayList; +import java.util.Collections; +import java.util.List; +import java.util.Optional; + +public class ContrailTranslationHelper { + /** + * Gets compute node type id. + * + * @param serviceTemplateTranslatedId the service template translated id + * @param serviceTemplateResource the service template resource + * @return the compute node type id + */ + public String getComputeNodeTypeId(String serviceTemplateTranslatedId, + Resource serviceTemplateResource) { + NameExtractorService nodeTypeNameExtractor = new NameExtractorServiceImpl(); + List propertyRegexMatchers = + getPropertiesAndRegexMatchers(nodeTypeNameExtractor); + Optional extractedNodeTypeName = nodeTypeNameExtractor + .extractNodeTypeNameByPropertiesPriority(serviceTemplateResource.getProperties(), + propertyRegexMatchers); + + return ToscaConstants.NODES_PREFIX + + (extractedNodeTypeName.isPresent() ? extractedNodeTypeName.get() + : "compute_" + serviceTemplateTranslatedId); + } + + private List getPropertiesAndRegexMatchers( + NameExtractorService nodeTypeNameExtractor) { + List propertyRegexMatchers = new ArrayList<>(); + propertyRegexMatchers.add(nodeTypeNameExtractor + .getPropertyRegexMatcher("image_name", Collections.singletonList(".+_image_name$"), + "_image_name")); + propertyRegexMatchers.add(nodeTypeNameExtractor + .getPropertyRegexMatcher("flavor", Collections.singletonList(".+_flavor_name$"), + "_flavor_name")); + return propertyRegexMatchers; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/helper/NameExtractorService.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/helper/NameExtractorService.java new file mode 100644 index 0000000000..ed338e2bf5 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/helper/NameExtractorService.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.helper; + +import java.util.List; +import java.util.Map; +import java.util.Optional; + +public interface NameExtractorService { + Optional extractNodeTypeNameByPropertiesPriority( + Map properties,List propertiesRegexMatchers); + + PropertyRegexMatcher getPropertyRegexMatcher(String propertyName, List regexMatchers, + String propertyValueSearchTerm); +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/helper/PropertyRegexMatcher.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/helper/PropertyRegexMatcher.java new file mode 100644 index 0000000000..b04234b413 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/helper/PropertyRegexMatcher.java @@ -0,0 +1,69 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.helper; + +import org.apache.commons.collections.CollectionUtils; + +import java.util.ArrayList; +import java.util.List; +import java.util.regex.Pattern; + +public class PropertyRegexMatcher { + private String propertyName; + private List regexPatterns; + private String stringToSearchForPropertyValue; + + public String getPropertyName() { + return propertyName; + } + + public void setPropertyName(String propertyName) { + this.propertyName = propertyName; + } + + /** + * Sets regex. + * + * @param regexPatterns the regex patterns + */ + public void setRegex(List regexPatterns) { + if (CollectionUtils.isEmpty(this.regexPatterns)) { + this.regexPatterns = new ArrayList<>(); + } + + for (String regexPattern : regexPatterns) { + this.regexPatterns.add(Pattern.compile(regexPattern)); + } + } + + public List getRegexPatterns() { + return regexPatterns; + } + + public String getStringToSearchForPropertyValue() { + return stringToSearchForPropertyValue; + } + + public void setStringToSearchForPropertyValue(String stringToSearchForPropertyValue) { + this.stringToSearchForPropertyValue = stringToSearchForPropertyValue; + } + +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/helper/VolumeTranslationHelper.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/helper/VolumeTranslationHelper.java new file mode 100644 index 0000000000..ebd38c89d2 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/helper/VolumeTranslationHelper.java @@ -0,0 +1,172 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.helper; + +import org.apache.commons.collections4.CollectionUtils; +import org.openecomp.core.utilities.yaml.YamlUtil; +import org.openecomp.sdc.heat.datatypes.manifest.FileData; +import org.openecomp.sdc.heat.datatypes.model.HeatOrchestrationTemplate; +import org.openecomp.sdc.heat.datatypes.model.HeatResourcesTypes; +import org.openecomp.sdc.heat.datatypes.model.Output; +import org.openecomp.sdc.heat.datatypes.model.Resource; +import org.openecomp.sdc.translator.datatypes.heattotosca.AttachedResourceId; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.ResourceFileDataAndIDs; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslateTo; +import org.openecomp.sdc.translator.services.heattotosca.HeatToToscaUtil; +import org.openecomp.sdc.translator.services.heattotosca.TranslationContext; +import org.openecomp.sdc.translator.services.heattotosca.impl.ResourceTranslationBase; +import org.slf4j.Logger; + +import java.util.ArrayList; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; +import java.util.function.Predicate; +import java.util.stream.Collectors; + +public class VolumeTranslationHelper { + private final Logger logger; + + public VolumeTranslationHelper(Logger logger) { + this.logger = logger; + } + + /** + * Gets file data containing volume. + * + * @param filesToSearch the files to search + * @param resourceId the resource id + * @param translateTo the translate to + * @param types the types + * @return the file data containing volume + */ + public Optional getFileDataContainingVolume(List filesToSearch, + String resourceId, + TranslateTo translateTo, + FileData.Type... types) { + if (CollectionUtils.isEmpty(filesToSearch)) { + return Optional.empty(); + } + + List fileDatas = Objects.isNull(types) ? filesToSearch + : HeatToToscaUtil.getFilteredListOfFileDataByTypes(filesToSearch, types); + Optional fileDataAndIDs = + getResourceFileDataAndIDsForVolumeConnection(resourceId, translateTo, fileDatas); + if (fileDataAndIDs.isPresent()) { + return fileDataAndIDs; + } + return Optional.empty(); + } + + private Optional getResourceFileDataAndIDsForVolumeConnection( + String resourceId, TranslateTo translateTo, List fileDatas) { + for (FileData data : fileDatas) { + HeatOrchestrationTemplate heatOrchestrationTemplate = new YamlUtil() + .yamlToObject(translateTo.getContext().getFiles().getFileContent(data.getFile()), + HeatOrchestrationTemplate.class); + Map outputs = heatOrchestrationTemplate.getOutputs(); + if (Objects.isNull(outputs)) { + continue; + } + Output output = outputs.get(resourceId); + if (Objects.nonNull(output)) { + Optional attachedOutputId = HeatToToscaUtil + .extractAttachedResourceId(data.getFile(), heatOrchestrationTemplate, + translateTo.getContext(), output.getValue()); + if (attachedOutputId.isPresent()) { + AttachedResourceId attachedResourceId = attachedOutputId.get(); + if (!isOutputIsGetResource(resourceId, data, attachedResourceId)) { + continue; + } + String translatedId = (String) attachedResourceId.getTranslatedId(); + if (isOutputOfTypeCinderVolume(translateTo, data, heatOrchestrationTemplate, + translatedId)) { + ResourceFileDataAndIDs fileDataAndIDs = + new ResourceFileDataAndIDs((String) attachedResourceId.getEntityId(), + translatedId, + data); + return Optional.of(fileDataAndIDs); + } else { + logger.warn( + "output: '" + resourceId + "' in file '" + data.getFile() + "' is not of type '" + + HeatResourcesTypes.CINDER_VOLUME_RESOURCE_TYPE.getHeatResource() + "'"); + } + } + } else { + logger.warn("output: '" + resourceId + "' in file '" + data.getFile() + "' is not found"); + } + } + return Optional.empty(); + } + + private boolean isOutputOfTypeCinderVolume(TranslateTo translateTo, FileData data, + HeatOrchestrationTemplate heatOrchestrationTemplate, + String translatedId) { + return getResourceByTranslatedResourceId(data.getFile(), heatOrchestrationTemplate, + translatedId, translateTo, + HeatResourcesTypes.CINDER_VOLUME_RESOURCE_TYPE.getHeatResource()) + .isPresent(); + } + + private Optional>> getResourceByTranslatedResourceId( + String fileName, HeatOrchestrationTemplate heatOrchestrationTemplate, + String translatedResourceId, TranslateTo translateTo, String heatResourceType) { + List> list = heatOrchestrationTemplate.getResources().entrySet() + .stream() + .filter( + entry -> getPredicatesForTranslatedIdToResourceId(fileName, heatOrchestrationTemplate, + translatedResourceId, translateTo.getContext(), heatResourceType) + .stream() + .allMatch(p -> p.test(entry))) + .collect(Collectors.toList()); + if (CollectionUtils.isEmpty(list)) { + return Optional.empty(); + } else { + return Optional.of(list); + } + } + + private List>> getPredicatesForTranslatedIdToResourceId( + String fileName, HeatOrchestrationTemplate heatOrchestrationTemplate, + String translatedResourceId, TranslationContext context, String heatResourceType) { + List>> list = new ArrayList<>(); + list.add(entry -> entry.getValue().getType().equals(heatResourceType)); + list.add(entry -> { + Optional resourceTranslatedId = ResourceTranslationBase + .getResourceTranslatedId(fileName, heatOrchestrationTemplate, entry.getKey(), context); + return resourceTranslatedId.isPresent() + && resourceTranslatedId.get().equals(translatedResourceId); + }); + return list; + } + + private boolean isOutputIsGetResource(String resourceId, FileData data, + AttachedResourceId attachedResourceId) { + if (attachedResourceId.isGetResource()) { + return true; + } else { + logger.warn("output: '" + resourceId + "' in file '" + data.getFile() + + "' is not defined as get_resource and therefor not supported."); + return false; + } + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/helper/impl/NameExtractorServiceImpl.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/helper/impl/NameExtractorServiceImpl.java new file mode 100644 index 0000000000..9bd3494698 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/helper/impl/NameExtractorServiceImpl.java @@ -0,0 +1,95 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.helper.impl; + +import org.openecomp.sdc.translator.datatypes.heattotosca.AttachedResourceId; +import org.openecomp.sdc.translator.services.heattotosca.HeatToToscaUtil; +import org.openecomp.sdc.translator.services.heattotosca.helper.NameExtractorService; +import org.openecomp.sdc.translator.services.heattotosca.helper.PropertyRegexMatcher; + +import java.util.List; +import java.util.Map; +import java.util.Optional; +import java.util.regex.Pattern; + +public class NameExtractorServiceImpl implements NameExtractorService { + + @Override + public Optional extractNodeTypeNameByPropertiesPriority( + Map properties,List propertiesRegexMatchers) { + for (PropertyRegexMatcher propertyRegexMatcher : propertiesRegexMatchers) { + Optional parameterNameValue = + getPropertyParameterNameValue(properties, propertyRegexMatcher.getPropertyName()); + if (parameterNameValue.isPresent()) { + if (isPropertyValueMatchNamingConvention(propertyRegexMatcher, parameterNameValue.get())) { + return Optional.of(parameterNameValue.get().substring(0, parameterNameValue.get() + .lastIndexOf(propertyRegexMatcher.getStringToSearchForPropertyValue()))); + } + } + } + + return Optional.empty(); + } + + private boolean isPropertyValueMatchNamingConvention(PropertyRegexMatcher propertyRegexMatcher, + String propertyValue) { + for (Pattern pattern : propertyRegexMatcher.getRegexPatterns()) { + if (pattern.matcher(propertyValue).matches()) { + return true; + } + } + return false; + } + + private Optional getPropertyParameterNameValue(Map properties, + String prop) { + Object propObj = properties.get(prop); + Optional property = HeatToToscaUtil.extractProperty(propObj); + if (property.isPresent()) { + AttachedResourceId extractedProperty = property.get(); + return getParameterName(extractedProperty); + } + return Optional.empty(); + } + + private Optional getParameterName(AttachedResourceId extractedProperty) { + if (!extractedProperty.isGetParam()) { + return Optional.empty(); + } + Object entityId = extractedProperty.getEntityId(); + if (entityId instanceof String) { + return Optional.of((String) entityId); + } else { + return Optional.of((String) ((List) entityId).get(0)); + } + } + + @Override + public PropertyRegexMatcher getPropertyRegexMatcher(String propertyName, + List regexMatchers, + String propertyValueSearchTerm) { + PropertyRegexMatcher propertyRegexMatcher = new PropertyRegexMatcher(); + propertyRegexMatcher.setPropertyName(propertyName); + propertyRegexMatcher.setRegex(regexMatchers); + propertyRegexMatcher.setStringToSearchForPropertyValue(propertyValueSearchTerm); + return propertyRegexMatcher; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/BaseResourceConnection.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/BaseResourceConnection.java new file mode 100644 index 0000000000..d901ae9c98 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/BaseResourceConnection.java @@ -0,0 +1,174 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.apache.commons.collections4.MapUtils; +import org.openecomp.core.utilities.yaml.YamlUtil; +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; +import org.openecomp.sdc.heat.datatypes.manifest.FileData; +import org.openecomp.sdc.heat.datatypes.model.HeatOrchestrationTemplate; +import org.openecomp.sdc.heat.datatypes.model.Resource; +import org.openecomp.sdc.tosca.datatypes.model.NodeTemplate; +import org.openecomp.sdc.tosca.datatypes.model.NodeType; +import org.openecomp.sdc.tosca.datatypes.model.RequirementAssignment; +import org.openecomp.sdc.tosca.datatypes.model.RequirementDefinition; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslateTo; +import org.openecomp.sdc.translator.services.heattotosca.errors.TranslatorErrorCodes; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; +import java.util.function.Predicate; + +abstract class BaseResourceConnection { + protected static Logger logger = + LoggerFactory.getLogger(ResourceTranslationCinderVolumeAttachmentImpl.class); + protected TranslateTo translateTo; + FileData nestedFileData; + NodeTemplate substitutionNodeTemplate; + NodeType nodeType; + ResourceTranslationBase resourceTranslationBase; + + BaseResourceConnection(ResourceTranslationBase resourceTranslationBase, TranslateTo translateTo, + FileData nestedFileData, NodeTemplate substitutionNodeTemplate, + NodeType nodeType) { + this.translateTo = translateTo; + this.nestedFileData = nestedFileData; + this.substitutionNodeTemplate = substitutionNodeTemplate; + this.nodeType = nodeType; + this.resourceTranslationBase = resourceTranslationBase; + } + + abstract boolean isDesiredNodeTemplateType(NodeTemplate nodeTemplate); + + abstract List> getPredicatesListForConnectionPoints(); + + abstract Optional> getConnectorParamName(String heatResourceId, + Resource heatResource, + HeatOrchestrationTemplate + nestedHeatOrchestrationTemplate); + + abstract String getDesiredResourceType(); + + abstract String getTranslatedResourceIdFromSubstitutionMapping( + ServiceTemplate nestedServiceTemplate, Map.Entry entry); + + abstract void addRequirementToConnectResources(Map.Entry entry, + List paramNames); + + abstract List> getAllConnectionPoints(); + + void connect() { + ServiceTemplate nestedServiceTemplate = translateTo.getContext().getTranslatedServiceTemplates() + .get(translateTo.getResource().getType()); + List paramNames = null; + HeatOrchestrationTemplate nestedHeatOrchestrationTemplate = new YamlUtil() + .yamlToObject(translateTo.getContext().getFileContent(nestedFileData.getFile()), + HeatOrchestrationTemplate.class); + List> exposedConnectionPoints = getAllConnectionPoints(); + for (Map connectionPointsMap : exposedConnectionPoints) { + for (Map.Entry entry : connectionPointsMap.entrySet()) { + String translatedResourceId = + getTranslatedResourceIdFromSubstitutionMapping(nestedServiceTemplate, entry); + NodeTemplate nodeTemplate = nestedServiceTemplate.getTopology_template().getNode_templates() + .get(translatedResourceId); + if (!isDesiredNodeTemplateType(nodeTemplate)) { + continue; + } + paramNames = createResourcesConnection(translatedResourceId, paramNames, + nestedHeatOrchestrationTemplate, entry); + } + } + } + + private List createResourcesConnection(String translatedResourceId, + List paramNames, + HeatOrchestrationTemplate + nestedHeatOrchestrationTemplate, + Map.Entry entry) { + List params = paramNames; + Optional>> heatResources = + getResourceByTranslatedResourceId(translatedResourceId, nestedHeatOrchestrationTemplate); + if (heatResources.isPresent()) { + params = + addRequirementAndGetConnectorParamsFromResourceProperties(nestedHeatOrchestrationTemplate, + entry, params, heatResources.get()); + } + return params; + } + + private List addRequirementAndGetConnectorParamsFromResourceProperties( + HeatOrchestrationTemplate nestedHeatOrchestrationTemplate, Map.Entry entry, + List params, List> heatResources) { + Resource heatResource; + for (Map.Entry resourceEntry : heatResources) { + heatResource = resourceEntry.getValue(); + if (!MapUtils.isEmpty(heatResource.getProperties())) { + Optional> connectorParamName = + getConnectorParamName(resourceEntry.getKey(), heatResource, + nestedHeatOrchestrationTemplate); + if (!connectorParamName.isPresent()) { + break; + } else { + params = connectorParamName.get(); + } + } + Objects.requireNonNull(params); + addRequirementToConnectResources(entry, params); + } + return params; + } + + protected Optional>> getResourceByTranslatedResourceId( + String translatedResourceId, HeatOrchestrationTemplate nestedHeatOrchestrationTemplate) { + Optional>> resourceByTranslatedResourceId = + resourceTranslationBase.getResourceByTranslatedResourceId(nestedFileData.getFile(), + nestedHeatOrchestrationTemplate, translatedResourceId, translateTo, + getDesiredResourceType()); + if (!resourceByTranslatedResourceId.isPresent()) { + throw new CoreException((new ErrorCode.ErrorCodeBuilder()).withMessage( + "Failed to get original resource from heat for translate resource id '" + + translatedResourceId + "'") + .withId(TranslatorErrorCodes.HEAT_TO_TOSCA_MAPPING_COLLISION) + .withCategory(ErrorCategory.APPLICATION).build()); + } + return resourceByTranslatedResourceId; + } + + void createRequirementAssignment(Map.Entry entry, String node, + NodeTemplate nodeTemplate) { + if (Objects.nonNull(node)) { + RequirementAssignment requirementAssignment; + requirementAssignment = new RequirementAssignment(); + requirementAssignment.setRelationship(entry.getValue().getRelationship()); + requirementAssignment.setCapability(entry.getValue().getCapability()); + requirementAssignment.setNode(node); + DataModelUtil.addRequirementAssignment(nodeTemplate, entry.getKey(), requirementAssignment); + } + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ContrailV2VmInterfaceToNetResourceConnection.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ContrailV2VmInterfaceToNetResourceConnection.java new file mode 100644 index 0000000000..890d2a76af --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ContrailV2VmInterfaceToNetResourceConnection.java @@ -0,0 +1,139 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.openecomp.sdc.heat.datatypes.manifest.FileData; +import org.openecomp.sdc.heat.datatypes.model.HeatOrchestrationTemplate; +import org.openecomp.sdc.heat.datatypes.model.HeatResourcesTypes; +import org.openecomp.sdc.heat.datatypes.model.Resource; +import org.openecomp.sdc.tosca.datatypes.ToscaCapabilityType; +import org.openecomp.sdc.tosca.datatypes.ToscaNodeType; +import org.openecomp.sdc.tosca.datatypes.ToscaRelationshipType; +import org.openecomp.sdc.tosca.datatypes.model.NodeTemplate; +import org.openecomp.sdc.tosca.datatypes.model.NodeType; +import org.openecomp.sdc.tosca.datatypes.model.RequirementDefinition; +import org.openecomp.sdc.translator.datatypes.heattotosca.AttachedResourceId; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslateTo; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslatedHeatResource; +import org.openecomp.sdc.translator.services.heattotosca.HeatToToscaUtil; + +import java.util.ArrayList; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; +import java.util.function.Predicate; + +public class ContrailV2VmInterfaceToNetResourceConnection extends PortToNetResourceConnection { + + public ContrailV2VmInterfaceToNetResourceConnection( + ResourceTranslationBase resourceTranslationBase, TranslateTo translateTo, + FileData nestedFileData, NodeTemplate substitutionNodeTemplate, NodeType nodeType) { + super(resourceTranslationBase, translateTo, nestedFileData, substitutionNodeTemplate, nodeType); + } + + @Override + protected boolean isDesiredNodeTemplateType(NodeTemplate nodeTemplate) { + return nodeTemplate.getType() + .equals(ToscaNodeType.CONTRAILV2_VIRTUAL_MACHINE_INTERFACE.getDisplayName()); + } + + @Override + protected Optional> getConnectorParamName(String heatResourceId, + Resource heatResource, + HeatOrchestrationTemplate nestedHeatOrchestrationTemplate) { + List networks = new ArrayList<>(); + Object virtualNetworkRefs = heatResource.getProperties().get("virtual_network_refs"); + if (Objects.isNull(virtualNetworkRefs) || !(virtualNetworkRefs instanceof List) + || ((List) virtualNetworkRefs).size() == 0) { + return Optional.empty(); + } + if (((List) virtualNetworkRefs).size() > 1) { + logger.warn("Heat resource: '" + translateTo.getResourceId() + "' with nested heat file: '" + + translateTo.getResource().getType() + + "' has resource '" + heatResourceId + "' with type '" + + HeatResourcesTypes.CONTRAIL_V2_VIRTUAL_MACHINE_INTERFACE_RESOURCE_TYPE.getHeatResource() + + "' which include 'virtual_network_refs' property with more than one network values, " + + "only the first network will be translated, all rest will be ignored in TOSCA " + + "translation."); + } + Object virtualNetworkRef = ((List) virtualNetworkRefs).get(0); + Optional network = HeatToToscaUtil + .extractAttachedResourceId(nestedFileData.getFile(), nestedHeatOrchestrationTemplate, + translateTo.getContext(), virtualNetworkRef); + if (network.isPresent() && network.get().isGetParam()) { + networks.add((String) network.get().getEntityId()); + } + return Optional.of(networks); + } + + @Override + protected String getDesiredResourceType() { + return HeatResourcesTypes.CONTRAIL_V2_VIRTUAL_MACHINE_INTERFACE_RESOURCE_TYPE.getHeatResource(); + } + + @Override + protected void addRequirementToConnectResources(Map.Entry entry, + List paramNames) { + for (String paramName : paramNames) { + Object paramValue = translateTo.getResource().getProperties().get(paramName); + String contrailAttachedResourceId = + HeatToToscaUtil.extractContrailGetResourceAttachedHeatResourceId(paramValue); + Optional node; + if (contrailAttachedResourceId != null) { // contrail get resource + node = ResourceTranslationBase.getResourceTranslatedId(translateTo.getHeatFileName(), + translateTo.getHeatOrchestrationTemplate(), contrailAttachedResourceId, + translateTo.getContext()); + if (node.isPresent()) { + createRequirementAssignment(entry, node.get(), substitutionNodeTemplate); + } + } else { + Optional attachedResourceId = + HeatToToscaUtil.extractAttachedResourceId(translateTo, paramName); + if (!attachedResourceId.isPresent()) { + return; + } + AttachedResourceId resourceId = attachedResourceId.get(); + if (resourceId.isGetParam()) { + TranslatedHeatResource shareResource = + translateTo.getContext().getHeatSharedResourcesByParam() + .get(resourceId.getEntityId()); + if (Objects.nonNull(shareResource) + && !HeatToToscaUtil.isHeatFileNested(translateTo, translateTo.getHeatFileName())) { + createRequirementAssignment(entry, shareResource.getTranslatedId(), + substitutionNodeTemplate); + } + } + } + } + } + + @Override + protected List> getPredicatesListForConnectionPoints() { + ArrayList> predicates = new ArrayList<>(); + predicates.add( + req -> req.getCapability().equals(ToscaCapabilityType.NETWORK_LINKABLE.getDisplayName()) + && req.getNode().equals(ToscaNodeType.ROOT.getDisplayName()) + && req.getRelationship().equals(ToscaRelationshipType.NETWORK_LINK_TO.getDisplayName()) + ); + return predicates; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/NovaAndPortResourceConnectionHelper.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/NovaAndPortResourceConnectionHelper.java new file mode 100644 index 0000000000..bc60a24223 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/NovaAndPortResourceConnectionHelper.java @@ -0,0 +1,106 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.openecomp.sdc.heat.datatypes.manifest.FileData; +import org.openecomp.sdc.heat.datatypes.model.HeatOrchestrationTemplate; +import org.openecomp.sdc.heat.datatypes.model.Resource; +import org.openecomp.sdc.tosca.datatypes.model.NodeTemplate; +import org.openecomp.sdc.tosca.datatypes.model.NodeType; +import org.openecomp.sdc.tosca.datatypes.model.RequirementDefinition; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslateTo; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.Optional; +import java.util.function.Predicate; + +public class NovaAndPortResourceConnectionHelper + extends BaseResourceConnection { + public NovaAndPortResourceConnectionHelper(ResourceTranslationBase resourceTranslationBase, + TranslateTo translateTo, FileData nestedFileData, + NodeTemplate substitutionNodeTemplate, + NodeType nodeType) { + super(resourceTranslationBase, translateTo, nestedFileData, substitutionNodeTemplate, nodeType); + } + + @Override + boolean isDesiredNodeTemplateType(NodeTemplate nodeTemplate) { + return false; + } + + @Override + List> getPredicatesListForConnectionPoints() { + return null; + } + + @Override + Optional> getConnectorParamName(String heatResourceId, + Resource heatResource, + HeatOrchestrationTemplate + nestedHeatOrchestrationTemplate) { + return null; + } + + @Override + String getDesiredResourceType() { + return null; + } + + @Override + String getTranslatedResourceIdFromSubstitutionMapping( + ServiceTemplate nestedServiceTemplate,Map.Entry entry) { + return null; + } + + @Override + void addRequirementToConnectResources(Map.Entry entry, + List paramNames) { + + } + + @Override + List> getAllConnectionPoints() { + List> exposedRequirementsList = new ArrayList<>(); + List> predicates = getPredicatesListForConnectionPoints(); + List> requirements = this.nodeType.getRequirements(); + if (requirements == null) { + return exposedRequirementsList; + } + requirements.stream() + .map(Map::entrySet) + .forEach(x -> x.stream() + .filter(entry -> predicates + .stream() + .anyMatch(p -> p.test(entry.getValue()))) + .forEach(entry -> { + Map exposedRequirementsMap = new HashMap<>(); + exposedRequirementsMap.put(entry.getKey(), entry.getValue()); + exposedRequirementsList.add(exposedRequirementsMap); + })); + + return exposedRequirementsList; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/NovaToVolResourceConnection.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/NovaToVolResourceConnection.java new file mode 100644 index 0000000000..8bab0dbc50 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/NovaToVolResourceConnection.java @@ -0,0 +1,228 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.apache.commons.collections4.CollectionUtils; +import org.apache.commons.lang3.StringUtils; +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.heat.datatypes.manifest.FileData; +import org.openecomp.sdc.heat.datatypes.model.HeatOrchestrationTemplate; +import org.openecomp.sdc.heat.datatypes.model.HeatResourcesTypes; +import org.openecomp.sdc.heat.datatypes.model.Resource; +import org.openecomp.sdc.tosca.datatypes.ToscaCapabilityType; +import org.openecomp.sdc.tosca.datatypes.ToscaNodeType; +import org.openecomp.sdc.tosca.datatypes.ToscaRelationshipType; +import org.openecomp.sdc.tosca.datatypes.ToscaServiceModel; +import org.openecomp.sdc.tosca.datatypes.model.NodeTemplate; +import org.openecomp.sdc.tosca.datatypes.model.NodeType; +import org.openecomp.sdc.tosca.datatypes.model.RequirementDefinition; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.services.ToscaAnalyzerService; +import org.openecomp.sdc.tosca.services.impl.ToscaAnalyzerServiceImpl; +import org.openecomp.sdc.translator.datatypes.heattotosca.AttachedResourceId; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.ResourceFileDataAndIDs; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslateTo; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslatedHeatResource; +import org.openecomp.sdc.translator.services.heattotosca.HeatToToscaUtil; +import org.openecomp.sdc.translator.services.heattotosca.TranslationContext; +import org.openecomp.sdc.translator.services.heattotosca.errors.MissingMandatoryPropertyErrorBuilder; +import org.openecomp.sdc.translator.services.heattotosca.helper.VolumeTranslationHelper; + +import java.util.ArrayList; +import java.util.Collections; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; +import java.util.function.Predicate; +import java.util.stream.Collectors; + +class NovaToVolResourceConnection extends NovaAndPortResourceConnectionHelper { + + public NovaToVolResourceConnection(ResourceTranslationBase resourceTranslationBase, + TranslateTo translateTo, FileData nestedFileData, + NodeTemplate substitutionNodeTemplate, NodeType nodeType) { + super(resourceTranslationBase, translateTo, nestedFileData, substitutionNodeTemplate, nodeType); + } + + @Override + boolean isDesiredNodeTemplateType(NodeTemplate nodeTemplate) { + ToscaAnalyzerService toscaAnalyzerService = new ToscaAnalyzerServiceImpl(); + ToscaServiceModel toscaServiceModel = HeatToToscaUtil.getToscaServiceModel(translateTo); + return toscaAnalyzerService.isTypeOf(nodeTemplate, ToscaNodeType.NOVA_SERVER.getDisplayName(), + translateTo.getContext().getTranslatedServiceTemplates() + .get(translateTo.getResource().getType()), toscaServiceModel); + } + + @Override + List> getPredicatesListForConnectionPoints() { + ArrayList> predicates = new ArrayList<>(); + predicates + .add(req -> req.getCapability().equals(ToscaCapabilityType.ATTACHMENT.getDisplayName()) + && req.getNode().equals(ToscaNodeType.BLOCK_STORAGE.getDisplayName()) + && req.getRelationship() + .equals(ToscaRelationshipType.NATIVE_ATTACHES_TO.getDisplayName())); + return predicates; + } + + @Override + Optional> getConnectorParamName( + String heatResourceId, Resource heatResource, + HeatOrchestrationTemplate nestedHeatOrchestrationTemplate) { + Optional volumeId = HeatToToscaUtil + .extractAttachedResourceId(nestedFileData.getFile(), nestedHeatOrchestrationTemplate, + translateTo.getContext(), heatResource.getProperties().get("volume_id")); + if (volumeId.isPresent() && volumeId.get().isGetParam()) { + return Optional.of(Collections.singletonList((String) volumeId.get().getEntityId())); + } else { + return Optional.empty(); + } + } + + @Override + String getDesiredResourceType() { + return HeatResourcesTypes.CINDER_VOLUME_ATTACHMENT_RESOURCE_TYPE.getHeatResource(); + } + + @Override + protected Optional>> getResourceByTranslatedResourceId( + String translatedResourceId, HeatOrchestrationTemplate nestedHeatOrchestrationTemplate) { + + List>> predicates = + buildPredicates(nestedFileData.getFile(), nestedHeatOrchestrationTemplate, + translatedResourceId); + List> list = + nestedHeatOrchestrationTemplate.getResources().entrySet() + .stream() + .filter(entry -> predicates + .stream() + .allMatch(p -> p.test(entry))) + .collect(Collectors.toList()); + if (CollectionUtils.isEmpty(list)) { + return Optional.empty(); + } else { + return Optional.of(list); + } + } + + private List>> buildPredicates(String fileName, + HeatOrchestrationTemplate + heatOrchestrationTemplate, + String + novaTranslatedResourceId) { + List>> list = new ArrayList<>(); + list.add(entry -> entry.getValue().getType().equals(getDesiredResourceType())); + list.add(entry -> { + Object instanceUuidProp = entry.getValue().getProperties().get("instance_uuid"); + TranslationContext context = translateTo.getContext(); + Optional instanceUuid = HeatToToscaUtil + .extractAttachedResourceId(fileName, heatOrchestrationTemplate, context, + instanceUuidProp); + if (instanceUuid.isPresent()) { + Optional resourceTranslatedId = ResourceTranslationBase + .getResourceTranslatedId(fileName, heatOrchestrationTemplate, + (String) instanceUuid.get().getTranslatedId(), context); + return resourceTranslatedId.isPresent() + && resourceTranslatedId.get().equals(novaTranslatedResourceId); + + } else { + throw new CoreException(new MissingMandatoryPropertyErrorBuilder("instance_uuid").build()); + } + }); + return list; + } + + @Override + String getTranslatedResourceIdFromSubstitutionMapping(ServiceTemplate nestedServiceTemplate, + Map.Entry entry) { + List substitutionMapping = + nestedServiceTemplate.getTopology_template().getSubstitution_mappings().getRequirements() + .get(entry.getKey()); + return substitutionMapping.get(0); + } + + @Override + void addRequirementToConnectResources(Map.Entry entry, + List paramNames) { + String paramName = paramNames.get(0); + Optional attachedResourceId = + HeatToToscaUtil.extractAttachedResourceId(translateTo, paramName); + String node; + if (!attachedResourceId.isPresent()) { + return; + } + AttachedResourceId attachedResource = attachedResourceId.get(); + if (attachedResource.isGetResource()) { + String volTranslatedId = (String) attachedResource.getTranslatedId(); + Resource volServerResource = HeatToToscaUtil + .getResource(translateTo.getHeatOrchestrationTemplate(), volTranslatedId, + translateTo.getHeatFileName()); + if (!StringUtils.equals(HeatResourcesTypes.CINDER_VOLUME_RESOURCE_TYPE.getHeatResource(), + volServerResource.getType())) { + logger.warn("Volume attachment used from nested resource " + translateTo.getResourceId() + + " is pointing to incorrect resource type(" + volServerResource.getType() + + ") for relation through the parameter '" + paramName + "." + + " The connection to the volume is ignored. " + + "Supported types are: " + + HeatResourcesTypes.CINDER_VOLUME_RESOURCE_TYPE.getHeatResource()); + return; + } + node = volTranslatedId; + createRequirementAssignment(entry, node, substitutionNodeTemplate); + } else if (attachedResource.isGetParam()) { + TranslatedHeatResource shareResource = + translateTo.getContext().getHeatSharedResourcesByParam() + .get(attachedResource.getEntityId()); + if (Objects.nonNull(shareResource) + && !HeatToToscaUtil.isHeatFileNested(translateTo, translateTo.getHeatFileName())) { + if (!StringUtils.equals(HeatResourcesTypes.CINDER_VOLUME_RESOURCE_TYPE.getHeatResource(), + shareResource.getHeatResource().getType())) { + logger.warn("Volume attachment used from nested resource " + translateTo.getResourceId() + + " is pointing to incorrect resource type(" + + shareResource.getHeatResource().getType() + ") for relation through the parameter '" + + paramName + "." + + " The connection to the volume is ignored. " + + "Supported types are: " + + HeatResourcesTypes.CINDER_VOLUME_RESOURCE_TYPE.getHeatResource()); + return; + } + node = shareResource.getTranslatedId(); + createRequirementAssignment(entry, node, substitutionNodeTemplate); + } else if (Objects.isNull(shareResource)) { + List allFilesData = translateTo.getContext().getManifest().getContent().getData(); + Optional fileData = + HeatToToscaUtil.getFileData(translateTo.getHeatFileName(), allFilesData); + if (fileData.isPresent()) { + Optional fileDataContainingResource = + new VolumeTranslationHelper(logger) + .getFileDataContainingVolume(fileData.get().getData(), + (String) attachedResource.getEntityId(), translateTo, FileData.Type.HEAT_VOL); + if (fileDataContainingResource.isPresent()) { + createRequirementAssignment(entry, + fileDataContainingResource.get().getTranslatedResourceId(), + substitutionNodeTemplate); + } + } + } + } + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/PortToNetResourceConnection.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/PortToNetResourceConnection.java new file mode 100644 index 0000000000..8adfca305e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/PortToNetResourceConnection.java @@ -0,0 +1,200 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.openecomp.sdc.heat.datatypes.manifest.FileData; +import org.openecomp.sdc.heat.datatypes.model.HeatOrchestrationTemplate; +import org.openecomp.sdc.heat.datatypes.model.HeatResourcesTypes; +import org.openecomp.sdc.heat.datatypes.model.Resource; +import org.openecomp.sdc.tosca.datatypes.ToscaCapabilityType; +import org.openecomp.sdc.tosca.datatypes.ToscaNodeType; +import org.openecomp.sdc.tosca.datatypes.ToscaRelationshipType; +import org.openecomp.sdc.tosca.datatypes.model.NodeTemplate; +import org.openecomp.sdc.tosca.datatypes.model.NodeType; +import org.openecomp.sdc.tosca.datatypes.model.RequirementDefinition; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.translator.datatypes.heattotosca.AttachedResourceId; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslateTo; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslatedHeatResource; +import org.openecomp.sdc.translator.services.heattotosca.HeatToToscaUtil; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.Collections; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; +import java.util.function.Predicate; + +public class PortToNetResourceConnection extends NovaAndPortResourceConnectionHelper { + + public PortToNetResourceConnection(ResourceTranslationBase resourceTranslationBase, + TranslateTo translateTo, FileData nestedFileData, + NodeTemplate substitutionNodeTemplate, NodeType nodeType) { + super(resourceTranslationBase, translateTo, nestedFileData, substitutionNodeTemplate, nodeType); + } + + @Override + protected boolean isDesiredNodeTemplateType(NodeTemplate nodeTemplate) { + return nodeTemplate.getType().equals(ToscaNodeType.NEUTRON_PORT.getDisplayName()); + } + + @Override + protected List> getPredicatesListForConnectionPoints() { + ArrayList> predicates = new ArrayList<>(); + predicates.add( + req -> req.getCapability().equals(ToscaCapabilityType.NETWORK_LINKABLE.getDisplayName()) + && req.getNode().equals(ToscaNodeType.ROOT.getDisplayName()) + && req.getRelationship().equals( + ToscaRelationshipType.NETWORK_LINK_TO.getDisplayName())); + return predicates; + } + + @Override + protected Optional> getConnectorParamName(String heatResourceId, + Resource heatResource, + HeatOrchestrationTemplate + nestedHeatOrchestrationTemplate) { + Optional network = HeatToToscaUtil + .extractAttachedResourceId(nestedFileData.getFile(), nestedHeatOrchestrationTemplate, + translateTo.getContext(), heatResource.getProperties().get("network")); + if (network.isPresent() && network.get().isGetParam()) { + return Optional.of(Collections.singletonList((String) network.get().getEntityId())); + } else { + network = HeatToToscaUtil + .extractAttachedResourceId(nestedFileData.getFile(), nestedHeatOrchestrationTemplate, + translateTo.getContext(), heatResource.getProperties().get("network_id")); + if (network.isPresent() && network.get().isGetParam()) { + return Optional.of(Collections.singletonList((String) network.get().getEntityId())); + } else { + return Optional.empty(); + } + } + } + + @Override + protected String getDesiredResourceType() { + return HeatResourcesTypes.NEUTRON_PORT_RESOURCE_TYPE.getHeatResource(); + } + + @Override + protected String getTranslatedResourceIdFromSubstitutionMapping( + ServiceTemplate nestedServiceTemplate, Map.Entry entry) { + List substitutionMapping = + nestedServiceTemplate.getTopology_template().getSubstitution_mappings().getRequirements() + .get(entry.getKey()); + return substitutionMapping.get(0); + } + + @Override + protected void addRequirementToConnectResources(Map.Entry entry, + List paramNames) { + String paramName = paramNames.get( + 0); // port can connect to one network only and + // we are expecting to have only one param(unlike security rules to port) + Object paramValue = translateTo.getResource().getProperties().get(paramName); + if (paramValue == null) { + logger.warn( + "Nested resource '" + translateTo.getResourceId() + "' is not including property '" + + paramName + "' with value for the nested heat file, therefore, '" + entry.getKey() + + "' TOSCA requirement will not be connected."); + return; + } + List supportedNetworkTypes = + Arrays.asList(HeatResourcesTypes.NEUTRON_NET_RESOURCE_TYPE.getHeatResource(), + HeatResourcesTypes.CONTRAIL_VIRTUAL_NETWORK_RESOURCE_TYPE.getHeatResource(), + HeatResourcesTypes.CONTRAIL_V2_VIRTUAL_NETWORK_RESOURCE_TYPE.getHeatResource()); + + Optional targetTranslatedNodeId = + getConnectionTargetNodeUsingGetResourceFunc(entry, paramName, paramValue, + supportedNetworkTypes); + if (targetTranslatedNodeId.isPresent()) { + createRequirementAssignment(entry, targetTranslatedNodeId.get(), substitutionNodeTemplate); + } else { + targetTranslatedNodeId = + getConnectionTargetNodeUsingGetParam(entry, paramName, supportedNetworkTypes); + if (targetTranslatedNodeId.isPresent()) { + createRequirementAssignment(entry, targetTranslatedNodeId.get(), substitutionNodeTemplate); + } + } + } + + private boolean validateResourceTypeSupportedForReqCreation(String sourceResourceId, + final String sourcePropertyName, + String sourceReqId, + Resource targetResource, + List supportedTypes) { + if (!resourceTranslationBase.isResourceTypeSupported(targetResource, supportedTypes)) { + logger.warn("Nested resource '" + sourceResourceId + "' property '" + sourcePropertyName + + "' is pointing to a resource with type '" + targetResource.getType() + + "' which is not supported for requirement '" + sourceReqId + + "' that connect port to network. \nSupported types are: '" + supportedTypes.toString() + + "', therefore, this TOSCA requirement will not be connected."); + return false; + } + return true; + } + + private Optional getConnectionTargetNodeUsingGetParam( + Map.Entry requirementDefinitionEntry, String paramName, + List supportedTargetNodeTypes) { + Optional attachedResourceId = + HeatToToscaUtil.extractAttachedResourceId(translateTo, paramName); + if (!attachedResourceId.isPresent()) { + return Optional.empty(); + } + AttachedResourceId resourceId = attachedResourceId.get(); + if (resourceId.isGetParam()) { + TranslatedHeatResource shareResource = + translateTo.getContext().getHeatSharedResourcesByParam().get(resourceId.getEntityId()); + if (Objects.nonNull(shareResource) + && !HeatToToscaUtil.isHeatFileNested(translateTo, translateTo.getHeatFileName())) { + if (validateResourceTypeSupportedForReqCreation(translateTo.getResourceId(), paramName, + requirementDefinitionEntry.getKey(), shareResource.getHeatResource(), + supportedTargetNodeTypes)) { + return Optional.of(shareResource.getTranslatedId()); + } + } + } + + return Optional.empty(); + } + + private Optional getConnectionTargetNodeUsingGetResourceFunc( + Map.Entry requirementDefinitionEntry, String paramName, + Object paramValue, List supportedTargetNodeTypes) { + String getResourceAttachedResourceId = + HeatToToscaUtil.extractContrailGetResourceAttachedHeatResourceId(paramValue); + if (getResourceAttachedResourceId != null) { // get resource + Resource resource = translateTo.getHeatOrchestrationTemplate().getResources() + .get(getResourceAttachedResourceId); + if (validateResourceTypeSupportedForReqCreation(translateTo.getResourceId(), paramName, + requirementDefinitionEntry.getKey(), resource, supportedTargetNodeTypes)) { + return ResourceTranslationBase.getResourceTranslatedId(translateTo.getHeatFileName(), + translateTo.getHeatOrchestrationTemplate(), getResourceAttachedResourceId, + translateTo.getContext()); + } + } + + return Optional.empty(); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationBase.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationBase.java new file mode 100644 index 0000000000..45e3830f6f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationBase.java @@ -0,0 +1,456 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.apache.commons.collections4.CollectionUtils; +import org.apache.commons.collections4.MapUtils; +import org.apache.commons.lang3.StringUtils; +import org.openecomp.core.utilities.yaml.YamlUtil; +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.heat.datatypes.manifest.FileData; +import org.openecomp.sdc.heat.datatypes.model.HeatOrchestrationTemplate; +import org.openecomp.sdc.heat.datatypes.model.Output; +import org.openecomp.sdc.heat.datatypes.model.Resource; +import org.openecomp.sdc.tosca.datatypes.ToscaCapabilityType; +import org.openecomp.sdc.tosca.datatypes.ToscaRelationshipType; +import org.openecomp.sdc.tosca.datatypes.model.ArtifactDefinition; +import org.openecomp.sdc.tosca.datatypes.model.AttributeDefinition; +import org.openecomp.sdc.tosca.datatypes.model.CapabilityDefinition; +import org.openecomp.sdc.tosca.datatypes.model.Import; +import org.openecomp.sdc.tosca.datatypes.model.InterfaceDefinition; +import org.openecomp.sdc.tosca.datatypes.model.NodeTemplate; +import org.openecomp.sdc.tosca.datatypes.model.NodeType; +import org.openecomp.sdc.tosca.datatypes.model.PropertyDefinition; +import org.openecomp.sdc.tosca.datatypes.model.RequirementAssignment; +import org.openecomp.sdc.tosca.datatypes.model.RequirementDefinition; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.tosca.services.ToscaConstants; +import org.openecomp.sdc.tosca.services.ToscaNativeTypesServiceTemplate; +import org.openecomp.sdc.translator.datatypes.heattotosca.AttachedResourceId; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.ResourceFileDataAndIDs; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslateTo; +import org.openecomp.sdc.translator.services.heattotosca.HeatToToscaUtil; +import org.openecomp.sdc.translator.services.heattotosca.ResourceTranslation; +import org.openecomp.sdc.translator.services.heattotosca.ResourceTranslationFactory; +import org.openecomp.sdc.translator.services.heattotosca.TranslationContext; +import org.openecomp.sdc.translator.services.heattotosca.TranslationService; +import org.openecomp.sdc.translator.services.heattotosca.errors.ResourceNotFoundInHeatFileErrorBuilder; +import org.openecomp.sdc.translator.services.heattotosca.globaltypes.GlobalTypesGenerator; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; +import java.util.function.Predicate; +import java.util.stream.Collectors; + +public abstract class ResourceTranslationBase implements ResourceTranslation { + + protected static Logger logger = LoggerFactory.getLogger(ResourceTranslationBase.class); + + static Optional getFileDataContainingResource( + List filesToSearch, String resourceId, TranslationContext context, + FileData.Type... types) { + if (CollectionUtils.isEmpty(filesToSearch)) { + return Optional.empty(); + } + + List fileDatas = Objects.isNull(types) ? filesToSearch + : HeatToToscaUtil.getFilteredListOfFileDataByTypes(filesToSearch, types); + for (FileData data : fileDatas) { + HeatOrchestrationTemplate heatOrchestrationTemplate = new YamlUtil() + .yamlToObject(context.getFiles().getFileContent(data.getFile()), + HeatOrchestrationTemplate.class); + Map outputs = heatOrchestrationTemplate.getOutputs(); + if (Objects.isNull(outputs)) { + continue; + } + Output output = outputs.get(resourceId); + if (Objects.nonNull(output)) { + Optional attachedOutputId = HeatToToscaUtil + .extractAttachedResourceId(data.getFile(), heatOrchestrationTemplate, context, + output.getValue()); + if (attachedOutputId.isPresent()) { + AttachedResourceId attachedResourceId = attachedOutputId.get(); + if (!attachedResourceId.isGetResource()) { + logger.warn("output: '" + resourceId + "' in file '" + data.getFile() + + "' is not defined as get_resource and therefor not supported."); + continue; + } + ResourceFileDataAndIDs fileDataAndIDs = + new ResourceFileDataAndIDs((String) attachedResourceId.getEntityId(), + (String) attachedResourceId.getTranslatedId(), + data); + return Optional.of(fileDataAndIDs); + } + } + } + return Optional.empty(); + } + + /** + * Gets resource translated id. + * + * @param heatFileName the heat file name + * @param heatOrchestrationTemplate the heat orchestration template + * @param resourceId the resource id + * @param context the context + * @return the resource translated id + */ + public static Optional getResourceTranslatedId(String heatFileName, + HeatOrchestrationTemplate + heatOrchestrationTemplate, + String resourceId, + TranslationContext context) { + if (!context.getTranslatedIds().containsKey(heatFileName)) { + context.getTranslatedIds().put(heatFileName, new HashMap<>()); + } + + Map translatedIdsPerFile = context.getTranslatedIds().get(heatFileName); + String translatedId = translatedIdsPerFile.get(resourceId); + if (translatedId != null) { + return Optional.of(translatedId); + } + + Resource resource = heatOrchestrationTemplate.getResources().get(resourceId); + if (resource == null) { + throw new CoreException( + new ResourceNotFoundInHeatFileErrorBuilder(resourceId, heatFileName).build()); + } + TranslateTo translateTo = + generateTranslationTo(heatFileName, null, heatOrchestrationTemplate, resource, resourceId, + null, context); + translatedId = + ResourceTranslationFactory.getInstance(resource).generateTranslatedId(translateTo); + if (translatedId != null) { + context.getTranslatedIds().get(heatFileName).put(resourceId, translatedId); + } + return Optional.ofNullable(translatedId); + } + + private static TranslateTo generateTranslationTo(String heatFileName, + ServiceTemplate serviceTemplate, + HeatOrchestrationTemplate + heatOrchestrationTemplate, + Resource resource, String resourceId, + String translatedId, + TranslationContext context) { + TranslateTo to = new TranslateTo(); + to.setHeatFileName(heatFileName); + to.setServiceTemplate(serviceTemplate); + to.setHeatOrchestrationTemplate(heatOrchestrationTemplate); + to.setResource(resource); + to.setResourceId(resourceId); + to.setTranslatedId(translatedId); + to.setContext(context); + return to; + } + + protected abstract void translate(TranslateTo translateTo); + + protected String generateTranslatedId(TranslateTo translateTo) { + isEssentialRequirementsValid(translateTo); + return translateTo.getResourceId(); + } + + protected boolean isEssentialRequirementsValid(TranslateTo translateTo) { + return true; + } + + @Override + public Optional translateResource(String heatFileName, ServiceTemplate serviceTemplate, + HeatOrchestrationTemplate heatOrchestrationTemplate, + Resource resource, String resourceId, + TranslationContext context) { + Optional translatedId = + getResourceTranslatedId(heatFileName, heatOrchestrationTemplate, resourceId, context); + context.getTranslatedResources().putIfAbsent(heatFileName, new HashSet<>()); + if (context.getTranslatedResources().get(heatFileName).contains(resourceId)) { + return translatedId; + } + if (!translatedId.isPresent()) { + return Optional.empty(); + } + logger.debug("Translate- file:" + heatFileName + " resource Id:" + resourceId + + " translated resource id:" + translatedId.get()); + translate(new TranslateTo(heatFileName, serviceTemplate, heatOrchestrationTemplate, resource, + resourceId, translatedId.get(), context)); + context.getTranslatedResources().get(heatFileName).add(resourceId); + + if (isNodeTemplate(translatedId.get(), serviceTemplate)) { + if (!context.getHeatStackGroupMembers().containsKey(heatFileName)) { + context.getHeatStackGroupMembers().put(heatFileName, new HashSet<>()); + } + context.getHeatStackGroupMembers().get(heatFileName).add(translatedId.get()); + updateResourceDependency(heatFileName, resource, heatOrchestrationTemplate, + translatedId.get(), serviceTemplate, context); + } + + return translatedId; + } + + private void updateResourceDependency(String heatFileName, Resource resource, + HeatOrchestrationTemplate heatOrchestrationTemplate, + String translatedId, ServiceTemplate serviceTemplate, + TranslationContext context) { + if (resource.getDepends_on() == null) { + return; + } + + if (resource.getDepends_on() instanceof List) { + List dependsOnList = (List) resource.getDepends_on(); + for (String dependsOnResourceId : dependsOnList) { + addDependOnRequirement(dependsOnResourceId, translatedId, serviceTemplate, heatFileName, + heatOrchestrationTemplate, context); + } + } else { + String dependsOnResourceId = (String) resource.getDepends_on(); + addDependOnRequirement(dependsOnResourceId, translatedId, serviceTemplate, heatFileName, + heatOrchestrationTemplate, context); + } + + } + + private void addDependOnRequirement(String dependsOnResourceId, String nodeTemplateId, + ServiceTemplate serviceTemplate, String heatFileName, + HeatOrchestrationTemplate heatOrchestrationTemplate, + TranslationContext context) { + RequirementAssignment requirementAssignment = new RequirementAssignment(); + Optional resourceTranslatedId = + getResourceTranslatedId(heatFileName, heatOrchestrationTemplate, dependsOnResourceId, + context); + + if (resourceTranslatedId.isPresent() + && isNodeTemplate(resourceTranslatedId.get(), serviceTemplate)) { + requirementAssignment.setNode(resourceTranslatedId.get()); + requirementAssignment.setCapability(ToscaCapabilityType.NODE.getDisplayName()); + requirementAssignment.setRelationship(ToscaRelationshipType.DEPENDS_ON.getDisplayName()); + DataModelUtil.addRequirementAssignment( + serviceTemplate.getTopology_template().getNode_templates().get(nodeTemplateId), + ToscaConstants.DEPENDS_ON_REQUIREMENT_ID, requirementAssignment); + } + } + + private boolean isNodeTemplate(String entryId, ServiceTemplate serviceTemplate) { + return serviceTemplate.getTopology_template().getNode_templates() != null + && serviceTemplate.getTopology_template().getNode_templates().get(entryId) != null; + } + + FileData getFileData(String fileName, TranslationContext context) { + + List fileDataList = context.getManifest().getContent().getData(); + for (FileData fileData : fileDataList) { + if (TranslationService.getTypesToProcessByTranslator().contains(fileData.getType()) + && fileData.getFile().equals(fileName)) { + return fileData; + } + } + return null; + } + + NodeType getNodeTypeWithFlatHierarchy(String nodeTypeId, ServiceTemplate serviceTemplate, + TranslationContext context) { + NodeType nodeType; + if (serviceTemplate != null && serviceTemplate.getNode_types() != null) { + nodeType = serviceTemplate.getNode_types().get(nodeTypeId); + + if (nodeType != null) { + return enrichNodeType(nodeType, serviceTemplate, context); + } + } + Map> globalNodeTypesMap = new HashMap<>(); + Collection globalNodeTypes = + GlobalTypesGenerator.getGlobalTypesServiceTemplate().values(); + ServiceTemplate nativeNodeTypeServiceTemplate = + ToscaNativeTypesServiceTemplate.createServiceTemplate(); + for (ServiceTemplate globalNodeType : globalNodeTypes) { + globalNodeTypesMap + .put(globalNodeType.getMetadata().getTemplate_name(), globalNodeType.getNode_types()); + } + if (Objects.nonNull(serviceTemplate) && MapUtils.isNotEmpty(serviceTemplate.getImports())) { + for (Map.Entry entry : serviceTemplate.getImports().entrySet()) { + if (globalNodeTypesMap.containsKey(entry.getKey())) { + Map nodeTypes = globalNodeTypesMap.get(entry.getKey()); + if (nodeTypes != null && nodeTypes.containsKey(nodeTypeId)) { + return enrichNodeType(nodeTypes.get(nodeTypeId), serviceTemplate, context); + } + } + if (context.getGlobalSubstitutionServiceTemplate() != null + && context.getGlobalSubstitutionServiceTemplate().getNode_types() != null + && context.getGlobalSubstitutionServiceTemplate().getNode_types() + .containsKey(nodeTypeId)) { + return enrichNodeType( + context.getGlobalSubstitutionServiceTemplate().getNode_types().get(nodeTypeId), + serviceTemplate, context); + } + if (nativeNodeTypeServiceTemplate.getNode_types().containsKey(nodeTypeId)) { + return enrichNodeType(nativeNodeTypeServiceTemplate.getNode_types().get(nodeTypeId), + serviceTemplate, context); + } + } + } + return new NodeType(); + + } + + private NodeType enrichNodeType(NodeType nodeType, ServiceTemplate serviceTemplate, + TranslationContext context) { + NodeType clonedNodeType; + + if (StringUtils.isEmpty(nodeType.getDerived_from())) { + return nodeType.clone(); + } + + clonedNodeType = enrichNodeType( + getNodeTypeWithFlatHierarchy(nodeType.getDerived_from(), serviceTemplate, context), + serviceTemplate, context); + mergeNodeTypes(clonedNodeType, nodeType); + return clonedNodeType; + + } + + private void mergeNodeTypes(NodeType target, NodeType source) { + target.setDerived_from(source.getDerived_from()); + target.setDescription(source.getDescription()); + target.setVersion(source.getVersion()); + target.setProperties( + mergeMaps(target.getProperties(), source.getProperties(), PropertyDefinition.class)); + target.setInterfaces( + mergeMaps(target.getInterfaces(), source.getInterfaces(), InterfaceDefinition.class)); + target.setArtifacts( + mergeMaps(target.getArtifacts(), source.getArtifacts(), ArtifactDefinition.class)); + target.setAttributes( + mergeMaps(target.getAttributes(), source.getAttributes(), AttributeDefinition.class)); + target.setCapabilities( + mergeMaps(target.getCapabilities(), source.getCapabilities(), CapabilityDefinition.class)); + target.setRequirements(mergeLists(target.getRequirements(), source.getRequirements(), + RequirementDefinition.class)); + } + + private List> mergeLists(List> target, List> source, + Class value) { + List> retList = new ArrayList<>(); + if (Objects.nonNull(target)) { + retList.addAll(target); + } + + if (Objects.nonNull(source)) { + for (Map sourceMap : source) { + for (Map.Entry entry : sourceMap.entrySet()) { + mergeEntryInList(entry.getKey(), entry.getValue(), retList); + } + } + } + return retList; + } + + void mergeEntryInList(T key, S value, List> target) { + boolean found = false; + for (Map map : target) { + if (map.containsKey(key)) { + map.put(key, value); + found = true; + } + } + + if (!found) { + Map newMap = new HashMap<>(); + newMap.put(key, value); + target.add(newMap); + } + } + + + private Map mergeMaps(Map target, Map source, Class value) { + Map retMap = new HashMap<>(); + if (MapUtils.isNotEmpty(target)) { + retMap.putAll(target); + } + + if (MapUtils.isNotEmpty(source)) { + retMap.putAll(source); + } + return retMap; + } + + Optional>> getResourceByTranslatedResourceId( + String fileName, + HeatOrchestrationTemplate heatOrchestrationTemplate, + String translatedResourceId,TranslateTo translateTo,String heatResourceType) { + List> list = heatOrchestrationTemplate.getResources().entrySet() + .stream() + .filter( + entry -> getPredicatesForTranslatedIdToResourceId(fileName, heatOrchestrationTemplate, + translatedResourceId, translateTo.getContext(), heatResourceType) + .stream() + .allMatch(p -> p.test(entry))) + .collect(Collectors.toList()); + if (CollectionUtils.isEmpty(list)) { + return Optional.empty(); + } else { + return Optional.of(list); + } + } + + private List>> getPredicatesForTranslatedIdToResourceId( + String fileName, HeatOrchestrationTemplate heatOrchestrationTemplate, + String translatedResourceId, TranslationContext context, String heatResourceType) { + List>> list = new ArrayList<>(); + list.add(entry -> + entry.getValue().getType().equals(heatResourceType)); + list.add(entry -> { + Optional resourceTranslatedId = + getResourceTranslatedId(fileName, heatOrchestrationTemplate, entry.getKey(), context); + return resourceTranslatedId.isPresent() + && resourceTranslatedId.get().equals(translatedResourceId); + }); + return list; + } + + void addBindingReqFromPortToCompute(String computeNodeTemplateId, NodeTemplate portNodeTemplate) { + RequirementAssignment requirementAssignment = new RequirementAssignment(); + requirementAssignment.setCapability(ToscaCapabilityType.NETWORK_BINDABLE.getDisplayName()); + requirementAssignment.setRelationship(ToscaRelationshipType.NETWORK_BINDS_TO.getDisplayName()); + requirementAssignment.setNode(computeNodeTemplateId); + DataModelUtil.addRequirementAssignment(portNodeTemplate, ToscaConstants.BINDING_REQUIREMENT_ID, + requirementAssignment); + } + + void addLinkReqFromPortToNetwork(NodeTemplate nodeTemplate, String translatedId) { + RequirementAssignment requirement = new RequirementAssignment(); + requirement.setCapability(ToscaCapabilityType.NETWORK_LINKABLE.getDisplayName()); + requirement.setRelationship(ToscaRelationshipType.NETWORK_LINK_TO.getDisplayName()); + requirement.setNode(translatedId); + DataModelUtil + .addRequirementAssignment(nodeTemplate, ToscaConstants.LINK_REQUIREMENT_ID, requirement); + } + + boolean isResourceTypeSupported(Resource resource, List supportedTypes) { + return Objects.nonNull(resource) && supportedTypes.contains(resource.getType()); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationCinderVolumeAttachmentImpl.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationCinderVolumeAttachmentImpl.java new file mode 100644 index 0000000000..cbad52a95d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationCinderVolumeAttachmentImpl.java @@ -0,0 +1,202 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import static org.openecomp.sdc.translator.services.heattotosca.HeatToToscaUtil.getResource; + +import org.apache.commons.lang3.StringUtils; +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.heat.datatypes.manifest.FileData; +import org.openecomp.sdc.heat.datatypes.model.HeatResourcesTypes; +import org.openecomp.sdc.heat.datatypes.model.Resource; +import org.openecomp.sdc.tosca.datatypes.ToscaRelationshipType; +import org.openecomp.sdc.tosca.datatypes.model.NodeTemplate; +import org.openecomp.sdc.tosca.datatypes.model.RelationshipTemplate; +import org.openecomp.sdc.tosca.datatypes.model.RequirementAssignment; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.translator.datatypes.heattotosca.AttachedResourceId; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.ResourceFileDataAndIDs; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslateTo; +import org.openecomp.sdc.translator.services.heattotosca.HeatToToscaUtil; +import org.openecomp.sdc.translator.services.heattotosca.ResourceTranslationFactory; +import org.openecomp.sdc.translator.services.heattotosca.errors.MissingMandatoryPropertyErrorBuilder; +import org.openecomp.sdc.translator.services.heattotosca.helper.VolumeTranslationHelper; +import org.openecomp.sdc.translator.services.heattotosca.mapping.TranslatorHeatToToscaPropertyConverter; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import java.util.List; +import java.util.Optional; + +public class ResourceTranslationCinderVolumeAttachmentImpl extends ResourceTranslationBase { + protected static Logger logger = + LoggerFactory.getLogger(ResourceTranslationCinderVolumeAttachmentImpl.class); + + @Override + protected void translate(TranslateTo translateTo) { + String volumeIdPropertyName = "volume_id"; + RelationshipTemplate relationTemplate = new RelationshipTemplate(); + relationTemplate.setType(ToscaRelationshipType.CINDER_VOLUME_ATTACHES_TO.getDisplayName()); + String relationshipTemplateId = translateTo.getTranslatedId(); + String heatFileName = translateTo.getHeatFileName(); + relationTemplate.setProperties(TranslatorHeatToToscaPropertyConverter + .getToscaPropertiesSimpleConversion(translateTo.getResource().getProperties(), + relationTemplate.getProperties(), heatFileName, + translateTo.getHeatOrchestrationTemplate(), translateTo.getResource().getType(), + relationTemplate, translateTo.getContext())); + + AttachedResourceId attachedVolumeId = getAttachedResourceId(translateTo, volumeIdPropertyName); + String instanceUuid = "instance_uuid"; + AttachedResourceId attachedNovaServerId = getAttachedResourceId(translateTo, instanceUuid); + + if (attachedNovaServerId.isGetResource()) { + handleNovaGetResource(translateTo, relationTemplate, relationshipTemplateId, heatFileName, + attachedVolumeId, (String) attachedNovaServerId.getEntityId()); + } else { + logger.warn("Heat resource: '" + translateTo.getResourceId() + "' with type: '" + + translateTo.getResource().getType() + + "' include 'instance_uuid' property without 'get_resource' function, therefore this " + + "resource will be ignored in TOSCA translation."); + } + } + + private AttachedResourceId getAttachedResourceId(TranslateTo translateTo, String propertyName) { + Optional attachedResourceId = + HeatToToscaUtil.extractAttachedResourceId(translateTo, propertyName); + if (!attachedResourceId.isPresent()) { + throw new CoreException(new MissingMandatoryPropertyErrorBuilder(propertyName).build()); + } + + return attachedResourceId.get(); + } + + private void handleNovaGetResource(TranslateTo translateTo, RelationshipTemplate relationTemplate, + String relationshipTemplateId, String heatFileName, + AttachedResourceId volResourceId, String novaResourceId) { + String toscaCapabilityAttachment = "tosca.capabilities.Attachment"; + RequirementAssignment requirement = new RequirementAssignment(); + requirement.setCapability(toscaCapabilityAttachment); + if (volResourceId.isGetResource()) { + Resource volServerResource = getResource(translateTo.getHeatOrchestrationTemplate(), + (String) volResourceId.getTranslatedId(), heatFileName); + if (!StringUtils.equals(HeatResourcesTypes.CINDER_VOLUME_RESOURCE_TYPE.getHeatResource(), + volServerResource.getType())) { + logger.warn("Volume attachment with id '" + translateTo.getResourceId() + + "' is pointing to unsupported resource type(" + volServerResource.getType() + + ") through the property 'volume_id'." + + " The connection to the volume is ignored. " + + "Supported types are: " + + HeatResourcesTypes.CINDER_VOLUME_RESOURCE_TYPE.getHeatResource()); + return; + } + requirement.setNode((String) volResourceId.getTranslatedId()); + requirement.setRelationship(relationshipTemplateId); + DataModelUtil + .addRelationshipTemplate(translateTo.getServiceTemplate(), relationshipTemplateId, + relationTemplate); + } else if (volResourceId.isGetParam()) { + String volumeResourceIdParamName = (String) volResourceId.getEntityId(); + if (translateTo.getContext().getHeatSharedResourcesByParam() + .containsKey(volumeResourceIdParamName) && !isHeatFileNested(translateTo, heatFileName)) { + Resource volServerResource = + translateTo.getContext().getHeatSharedResourcesByParam().get(volumeResourceIdParamName) + .getHeatResource(); + if (!StringUtils.equals(HeatResourcesTypes.CINDER_VOLUME_RESOURCE_TYPE.getHeatResource(), + volServerResource.getType())) { + logger.warn("Volume attachment with id '" + translateTo.getResourceId() + + "' is pointing to unsupported resource type(" + volServerResource.getType() + + ") through the property 'volume_id'." + + " The connection to the volume is ignored. " + + "Supported types are: " + + HeatResourcesTypes.CINDER_VOLUME_RESOURCE_TYPE.getHeatResource()); + return; + } + requirement.setNode( + translateTo.getContext().getHeatSharedResourcesByParam().get(volumeResourceIdParamName) + .getTranslatedId()); + requirement.setRelationship(relationshipTemplateId); + DataModelUtil + .addRelationshipTemplate(translateTo.getServiceTemplate(), relationshipTemplateId, + relationTemplate); + } else { + handleUnsharedVolume(translateTo, relationTemplate, relationshipTemplateId, heatFileName, + requirement, volumeResourceIdParamName); + } + } + Resource novaServerResource = + getResource(translateTo.getHeatOrchestrationTemplate(), novaResourceId, heatFileName); + if (!StringUtils.equals(HeatResourcesTypes.NOVA_SERVER_RESOURCE_TYPE.getHeatResource(), + novaServerResource.getType())) { + logger.warn("Volume attachment with id '" + translateTo.getResourceId() + + "' is pointing to unsupported resource type(" + novaServerResource.getType() + + ") through the property 'instance_uuid'." + + " The connection to the nova server is ignored. " + + "Supported types are: " + HeatResourcesTypes.NOVA_SERVER_RESOURCE_TYPE + .getHeatResource()); + return; + } + Optional translatedNovaServerId = + ResourceTranslationFactory.getInstance(novaServerResource) + .translateResource(heatFileName, translateTo.getServiceTemplate(), + translateTo.getHeatOrchestrationTemplate(), novaServerResource, novaResourceId, + translateTo.getContext()); + + if (translatedNovaServerId.isPresent() && StringUtils.isNotEmpty(requirement.getNode())) { + NodeTemplate novaServerNodeTemplate = DataModelUtil + .getNodeTemplate(translateTo.getServiceTemplate(), translatedNovaServerId.get()); + DataModelUtil.addRequirementAssignment(novaServerNodeTemplate, "local_storage", requirement); + } + } + + private void handleUnsharedVolume(TranslateTo translateTo, RelationshipTemplate relationTemplate, + String relationshipTemplateId, String heatFileName, + RequirementAssignment requirement, String volumeResourceId) { + List allFilesData = translateTo.getContext().getManifest().getContent().getData(); + Optional fileData = HeatToToscaUtil.getFileData(heatFileName, allFilesData); + if (fileData.isPresent()) { + Optional fileDataContainingResource = + new VolumeTranslationHelper(logger) + .getFileDataContainingVolume(fileData.get().getData(), volumeResourceId, translateTo, + FileData.Type.HEAT_VOL); + if (fileDataContainingResource.isPresent()) { + addRelationshipToServiceTemplate(translateTo, relationTemplate, relationshipTemplateId, + requirement, fileDataContainingResource.get()); + } + } + } + + private boolean isHeatFileNested(TranslateTo translateTo, String heatFileName) { + return translateTo.getContext().getNestedHeatsFiles().contains(heatFileName); + } + + private void addRelationshipToServiceTemplate(TranslateTo translateTo, + RelationshipTemplate relationTemplate, + String relationshipTemplateId, + RequirementAssignment requirement, + ResourceFileDataAndIDs resourceFileDataAndIDs) { + String translatedId = resourceFileDataAndIDs.getTranslatedResourceId(); + relationTemplate.getProperties().put("volume_id", translatedId); + requirement.setNode(translatedId); + requirement.setRelationship(relationshipTemplateId); + DataModelUtil.addRelationshipTemplate(translateTo.getServiceTemplate(), relationshipTemplateId, + relationTemplate); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationCinderVolumeImpl.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationCinderVolumeImpl.java new file mode 100644 index 0000000000..c1e5fe3900 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationCinderVolumeImpl.java @@ -0,0 +1,77 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.openecomp.sdc.heat.datatypes.HeatBoolean; +import org.openecomp.sdc.tosca.datatypes.ToscaNodeType; +import org.openecomp.sdc.tosca.datatypes.model.NodeTemplate; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslateTo; +import org.openecomp.sdc.translator.services.heattotosca.mapping.TranslatorHeatToToscaPropertyConverter; + +import java.util.Map; +import java.util.Optional; + +public class ResourceTranslationCinderVolumeImpl extends ResourceTranslationBase { + + @Override + public void translate(TranslateTo translateTo) { + NodeTemplate nodeTemplate = new NodeTemplate(); + nodeTemplate.setType(ToscaNodeType.CINDER_VOLUME.getDisplayName()); + + nodeTemplate.setProperties(TranslatorHeatToToscaPropertyConverter + .getToscaPropertiesSimpleConversion(translateTo.getResource().getProperties(), + nodeTemplate.getProperties(), translateTo.getHeatFileName(), + translateTo.getHeatOrchestrationTemplate(), translateTo.getResource().getType(), + nodeTemplate, translateTo.getContext())); + handleSizeProperty(nodeTemplate.getProperties()); + Object readOnly = nodeTemplate.getProperties().get("read_only"); + if (readOnly != null && !(readOnly instanceof Map)) { + nodeTemplate.getProperties().put("read_only", HeatBoolean.eval(readOnly)); + } + Optional resourceTranslatedId = getResourceTranslatedId(translateTo.getHeatFileName(), + translateTo.getHeatOrchestrationTemplate(), translateTo.getResourceId(), + translateTo.getContext()); + if (resourceTranslatedId.isPresent()) { + DataModelUtil.addNodeTemplate(translateTo.getServiceTemplate(), resourceTranslatedId.get(), + nodeTemplate); + } + } + + private void handleSizeProperty(Map nodeTemplateProperties) { + Object size = nodeTemplateProperties.get("size"); + if (size == null) { + return; + } + + if (size instanceof Map) { + Map propMap = (Map) size; + if (propMap.entrySet().iterator().hasNext()) { + Map.Entry entry = propMap.entrySet().iterator().next(); + String val = "(" + entry.getKey() + " : " + entry.getValue() + ") * 1024"; + nodeTemplateProperties.put("size", val); + return; + } + } else { + nodeTemplateProperties.put("size", size + "*1024"); + } + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailAttachPolicyImpl.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailAttachPolicyImpl.java new file mode 100644 index 0000000000..307e407119 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailAttachPolicyImpl.java @@ -0,0 +1,141 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.heat.datatypes.model.Resource; +import org.openecomp.sdc.tosca.datatypes.ToscaCapabilityType; +import org.openecomp.sdc.tosca.datatypes.ToscaRelationshipType; +import org.openecomp.sdc.tosca.datatypes.model.NodeTemplate; +import org.openecomp.sdc.tosca.datatypes.model.RequirementAssignment; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.tosca.services.ToscaConstants; +import org.openecomp.sdc.translator.datatypes.heattotosca.AttachedResourceId; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslateTo; +import org.openecomp.sdc.translator.services.heattotosca.HeatToToscaUtil; +import org.openecomp.sdc.translator.services.heattotosca.ResourceTranslationFactory; +import org.openecomp.sdc.translator.services.heattotosca.errors.MissingMandatoryPropertyErrorBuilder; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import java.util.Optional; + +public class ResourceTranslationContrailAttachPolicyImpl extends ResourceTranslationBase { + protected static Logger logger = + LoggerFactory.getLogger(ResourceTranslationContrailAttachPolicyImpl.class); + + @Override + protected void translate(TranslateTo translateTo) { + String heatFileName = translateTo.getHeatFileName(); + String translatedNetworkResourceId = getTranslatedNetworkResourceId(translateTo); + if (translatedNetworkResourceId == null) { + return; + } + + NodeTemplate policyNodeTemplate = getTranslatedPolicyNodeTemplate(translateTo, heatFileName); + if (policyNodeTemplate != null) { + DataModelUtil + .addRequirementAssignment(policyNodeTemplate, ToscaConstants.NETWORK_REQUIREMENT_ID, + createRequirementAssignment(translatedNetworkResourceId)); + } + } + + private NodeTemplate getTranslatedPolicyNodeTemplate(TranslateTo translateTo, + String heatFileName) { + Optional attachedPolicyResourceId = + extractAttachedResourceIdHandleMissing(translateTo, "policy"); + NodeTemplate policyNodeTemplate = new NodeTemplate(); + Optional policyResourceId = + HeatToToscaUtil.getContrailAttachedHeatResourceId(attachedPolicyResourceId.get()); + if (policyResourceId.isPresent()) { + policyNodeTemplate = getPolicyNodeTemplate(translateTo, heatFileName, policyResourceId.get()); + } else { + logger.warn("Heat resource: '" + translateTo.getResourceId() + "' with type: '" + + translateTo.getResource().getType() + + "' include 'policy' property without 'get_attr' of 'fq_name'/'get_resource'" + + " function, therefore this resource will be ignored in TOSCA translation."); + } + return policyNodeTemplate; + } + + private NodeTemplate getPolicyNodeTemplate(TranslateTo translateTo, String heatFileName, + String policyResourceId) { + Resource policyResource = HeatToToscaUtil + .getResource(translateTo.getHeatOrchestrationTemplate(), policyResourceId, heatFileName); + Optional translatedPolicyResourceId = + ResourceTranslationFactory.getInstance(policyResource) + .translateResource(heatFileName, translateTo.getServiceTemplate(), + translateTo.getHeatOrchestrationTemplate(), policyResource, policyResourceId, + translateTo.getContext()); + if (!translatedPolicyResourceId.isPresent()) { + logger.warn("Heat resource: '" + translateTo.getResourceId() + "' with type: '" + + translateTo.getResource().getType() + + "' include unsupported policy resource, therefore this " + + "resource will be ignored in TOSCA translation. "); + return null; + } + return DataModelUtil + .getNodeTemplate(translateTo.getServiceTemplate(), + translatedPolicyResourceId.get()); + } + + private String getTranslatedNetworkResourceId(TranslateTo translateTo) { + Optional attachedNetworkResourceId = + extractAttachedResourceIdHandleMissing(translateTo, "network"); + + String translatedNetworkResourceId = null; + if (attachedNetworkResourceId.get().isGetResource()) { + translatedNetworkResourceId = (String) attachedNetworkResourceId.get().getTranslatedId(); + } else { + logger.warn("Heat resource: '" + translateTo.getResourceId() + "' with type: '" + + translateTo.getResource().getType() + + "' include 'network' property without 'get_resource' function, " + + "therefore this resource will be ignored in TOSCA translation."); + } + return translatedNetworkResourceId; + } + + private RequirementAssignment createRequirementAssignment(String translatedNetworkResourceId) { + RequirementAssignment requirement = new RequirementAssignment(); + requirement.setCapability(ToscaCapabilityType.ATTACHMENT.getDisplayName()); + requirement.setNode(translatedNetworkResourceId); + requirement.setRelationship(ToscaRelationshipType.ATTACHES_TO.getDisplayName()); + return requirement; + } + + private Optional extractAttachedResourceIdHandleMissing( + TranslateTo translateTo, String propertyName) { + Optional attachedResourceId = + HeatToToscaUtil.extractAttachedResourceId(translateTo, propertyName); + + if (!attachedResourceId.isPresent()) { + throw new CoreException(new MissingMandatoryPropertyErrorBuilder(propertyName).build()); + } + return attachedResourceId; + } + + + @Override + protected String generateTranslatedId(TranslateTo translateTo) { + return extractAttachedResourceIdHandleMissing(translateTo, "network").get().getEntityId() + .toString(); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailNetworkPolicyImpl.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailNetworkPolicyImpl.java new file mode 100644 index 0000000000..8084433fd5 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailNetworkPolicyImpl.java @@ -0,0 +1,53 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.openecomp.sdc.tosca.datatypes.ToscaNodeType; +import org.openecomp.sdc.tosca.datatypes.model.NodeTemplate; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslateTo; +import org.openecomp.sdc.translator.services.heattotosca.mapping.TranslatorHeatToToscaPropertyConverter; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +public class ResourceTranslationContrailNetworkPolicyImpl extends ResourceTranslationBase { + + protected static Logger logger = + LoggerFactory.getLogger(ResourceTranslationContrailNetworkPolicyImpl.class); + + @Override + protected void translate(TranslateTo translateTo) { + + NodeTemplate nodeTemplate = new NodeTemplate(); + nodeTemplate.setType(ToscaNodeType.CONTRAIL_NETWORK_RULE.getDisplayName()); + + nodeTemplate.setProperties(TranslatorHeatToToscaPropertyConverter + .getToscaPropertiesSimpleConversion(translateTo.getResource().getProperties(), + nodeTemplate.getProperties(), translateTo.getHeatFileName(), + translateTo.getHeatOrchestrationTemplate(), translateTo.getResource().getType(), + nodeTemplate, translateTo.getContext())); + + DataModelUtil.addNodeTemplate(translateTo.getServiceTemplate(), translateTo.getTranslatedId(), + nodeTemplate); + + + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailServiceInstanceImpl.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailServiceInstanceImpl.java new file mode 100644 index 0000000000..b2475f28a9 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailServiceInstanceImpl.java @@ -0,0 +1,663 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.heat.datatypes.HeatBoolean; +import org.openecomp.sdc.heat.datatypes.model.HeatResourcesTypes; +import org.openecomp.sdc.heat.datatypes.model.Resource; +import org.openecomp.sdc.heat.services.HeatConstants; +import org.openecomp.sdc.tosca.datatypes.ToscaCapabilityType; +import org.openecomp.sdc.tosca.datatypes.ToscaFunctions; +import org.openecomp.sdc.tosca.datatypes.ToscaGroupType; +import org.openecomp.sdc.tosca.datatypes.ToscaNodeType; +import org.openecomp.sdc.tosca.datatypes.ToscaRelationshipType; +import org.openecomp.sdc.tosca.datatypes.model.AttributeDefinition; +import org.openecomp.sdc.tosca.datatypes.model.GroupDefinition; +import org.openecomp.sdc.tosca.datatypes.model.Metadata; +import org.openecomp.sdc.tosca.datatypes.model.NodeTemplate; +import org.openecomp.sdc.tosca.datatypes.model.NodeType; +import org.openecomp.sdc.tosca.datatypes.model.ParameterDefinition; +import org.openecomp.sdc.tosca.datatypes.model.PropertyDefinition; +import org.openecomp.sdc.tosca.datatypes.model.RequirementAssignment; +import org.openecomp.sdc.tosca.datatypes.model.RequirementDefinition; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.datatypes.model.SubstitutionMapping; +import org.openecomp.sdc.tosca.datatypes.model.TopologyTemplate; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.tosca.services.ToscaConstants; +import org.openecomp.sdc.tosca.services.ToscaUtil; +import org.openecomp.sdc.tosca.services.impl.ToscaFileOutputServiceCsarImpl; +import org.openecomp.sdc.translator.datatypes.heattotosca.AttachedResourceId; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslateTo; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslatedHeatResource; +import org.openecomp.sdc.translator.services.heattotosca.Constants; +import org.openecomp.sdc.translator.services.heattotosca.HeatToToscaUtil; +import org.openecomp.sdc.translator.services.heattotosca.ResourceTranslationFactory; +import org.openecomp.sdc.translator.services.heattotosca.errors.MissingMandatoryPropertyErrorBuilder; +import org.openecomp.sdc.translator.services.heattotosca.globaltypes.ContrailAbstractSubstituteGlobalType; +import org.openecomp.sdc.translator.services.heattotosca.globaltypes.ContrailComputeGlobalType; +import org.openecomp.sdc.translator.services.heattotosca.globaltypes.GlobalTypesGenerator; +import org.openecomp.sdc.translator.services.heattotosca.globaltypes.GlobalTypesUtil; +import org.openecomp.sdc.translator.services.heattotosca.helper.ContrailTranslationHelper; +import org.openecomp.sdc.translator.services.heattotosca.mapping.TranslatorHeatToToscaFunctionConverter; +import org.openecomp.sdc.translator.services.heattotosca.mapping.TranslatorHeatToToscaPropertyConverter; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; + +public class ResourceTranslationContrailServiceInstanceImpl extends ResourceTranslationBase { + protected static Logger logger = + LoggerFactory.getLogger(ResourceTranslationContrailServiceInstanceImpl.class); + + @Override + public void translate(TranslateTo translateTo) { + Resource serviceInstanceResource = translateTo.getResource(); + AttachedResourceId contrailServiceTemplateAttached = + getServiceTemplateAttachedId(translateTo, serviceInstanceResource); + if (contrailServiceTemplateAttached.isGetResource()) { + String contrailServiceTemplateResourceId = + (String) contrailServiceTemplateAttached.getEntityId(); + Resource contrailServiceTemplateResource = HeatToToscaUtil + .getResource(translateTo.getHeatOrchestrationTemplate(), + contrailServiceTemplateResourceId, translateTo.getHeatFileName()); + if (!contrailServiceTemplateResource.getType() + .equals(HeatResourcesTypes.CONTRAIL_SERVICE_TEMPLATE.getHeatResource())) { + logger.warn("resource id '" + translateTo.getResourceId() + "' with type '" + + translateTo.getResource().getType() + + "+ has reference to resource '" + contrailServiceTemplateResourceId + "' with type " + + "'" + + contrailServiceTemplateResource.getType() + + "' in property service_template. Invalid type, resource type should be type of '" + + HeatResourcesTypes.CONTRAIL_SERVICE_TEMPLATE.getHeatResource() + + "', therefore this resource will be ignored in TOSCA translation."); + return; + } + Optional contrailServiceTemplateTranslatedId = + ResourceTranslationFactory.getInstance(contrailServiceTemplateResource) + .translateResource(translateTo.getHeatFileName(), translateTo.getServiceTemplate(), + translateTo.getHeatOrchestrationTemplate(), contrailServiceTemplateResource, + contrailServiceTemplateResourceId, translateTo.getContext()); + if (!contrailServiceTemplateTranslatedId.isPresent()) { + logger.warn("Resource id '" + translateTo.getResourceId() + "' with type '" + + translateTo.getResource().getType() + + "' has reference to unsupported resource '" + contrailServiceTemplateResourceId + + "' with type '" + contrailServiceTemplateResource.getType() + + "' in property 'service_template'" + + ", therefore this resource will be ignored in TOSCA translation."); + return; + } + + ServiceTemplate globalSubstitutionServiceTemplate = + translateTo.getContext().getTranslatedServiceTemplates() + .get(Constants.GLOBAL_SUBSTITUTION_TYPES_TEMPLATE_NAME); + String contrailStId = ResourceTranslationContrailServiceTemplateImpl + .getContrailSubstitutedNodeTypeId(contrailServiceTemplateTranslatedId.get()); + NodeType substitutedNodeType = + DataModelUtil.getNodeType(globalSubstitutionServiceTemplate, contrailStId); + + int numberOfPorts = getServiceInstanceNumberOfPorts(serviceInstanceResource); + if (substitutedNodeType.getRequirements() != null + && substitutedNodeType.getRequirements().size() != numberOfPorts) { + logger.warn("More than one ServiceInstance pointing to the same ServiceTemplate '" + + contrailServiceTemplateResourceId + " ' with different number of interfaces." + + ", therefore this resource will be ignored in TOSCA translation."); + return; + } + + addNetworkLinkRequirements(substitutedNodeType, numberOfPorts); + NodeTemplate substitutedNodeTemplate = + createSubstitutedNodeTemplate(translateTo, contrailServiceTemplateResource, contrailStId, + numberOfPorts); + + String computeNodeTypeId = new ContrailTranslationHelper() + .getComputeNodeTypeId(contrailServiceTemplateTranslatedId.get(), + contrailServiceTemplateResource); + boolean orderedInterfaces = getOrderedInterfaces(contrailServiceTemplateResource); + ServiceTemplate nestedServiceTemplate = + createNestedServiceTemplate(translateTo, computeNodeTypeId, contrailStId, + substitutedNodeTemplate, orderedInterfaces); + addAbstractSubstitutionProperty(translateTo, substitutedNodeTemplate.getProperties(), + nestedServiceTemplate, contrailServiceTemplateResource); + translateTo.getContext().getTranslatedServiceTemplates() + .put(translateTo.getTranslatedId(), nestedServiceTemplate); + + } else { + logger.warn("Heat resource: '" + translateTo.getResourceId() + "' with type: '" + + translateTo.getResource().getType() + + "' include 'service_template' property without 'get_resource' function, currently not " + + "supported, therefore this resource will be ignored in TOSCA translation."); + } + + } + + private void addAbstractSubstitutionProperty(TranslateTo translateTo, + Map substitutionProperties, + ServiceTemplate nestedServiceTemplate, + Resource contrailServiceTemplateResource) { + Map innerProps = new HashMap<>(); + innerProps.put(ToscaConstants.SUBSTITUTE_SERVICE_TEMPLATE_PROPERTY_NAME, + ToscaUtil.getServiceTemplateFileName(nestedServiceTemplate)); + + Object countValue = handleScaleOutProperty(translateTo, innerProps); + handleServiceScalingProperty(translateTo, innerProps, contrailServiceTemplateResource); + + boolean mandatory = false; + if (countValue instanceof Integer && (Integer) countValue > 0) { + mandatory = true; + } + if (countValue == null) { + mandatory = true; + } + innerProps.put("mandatory", mandatory); + substitutionProperties.put(ToscaConstants.SERVICE_TEMPLATE_FILTER_PROPERTY_NAME, innerProps); + } + + private Object handleScaleOutProperty(TranslateTo translateTo, Map innerProps) { + Object scaleOutPropertyValue = + translateTo.getResource().getProperties().get(HeatConstants.SCALE_OUT_PROPERTY_NAME); + Object countValue = null; + if (scaleOutPropertyValue != null && scaleOutPropertyValue instanceof Map) { + countValue = TranslatorHeatToToscaPropertyConverter + .getToscaPropertyValue(Constants.MAX_INSTANCES_PROPERTY_NAME, + ((Map) scaleOutPropertyValue).get(Constants.MAX_INSTANCES_PROPERTY_NAME), null, + translateTo.getHeatFileName(), translateTo.getHeatOrchestrationTemplate(), null, + translateTo.getContext()); + if (countValue != null) { + innerProps.put(ToscaConstants.COUNT_PROPERTY_NAME, countValue); + } else { + innerProps.put(ToscaConstants.COUNT_PROPERTY_NAME, 1); + } + } else { + innerProps.put(ToscaConstants.COUNT_PROPERTY_NAME, 1); + } + return countValue; + } + + private void handleServiceScalingProperty(TranslateTo translateTo, Map innerProps, + Resource contrailServiceTemplateResource) { + Object serviceScalingPropertyValue = contrailServiceTemplateResource.getProperties() + .get(HeatConstants.SERVICE_SCALING_PROPERTY_NAME); + Object serviceScalingValue = null; + if (serviceScalingPropertyValue != null) { + serviceScalingValue = TranslatorHeatToToscaPropertyConverter + .getToscaPropertyValue(HeatConstants.SERVICE_SCALING_PROPERTY_NAME, + serviceScalingPropertyValue, null, translateTo.getHeatFileName(), + translateTo.getHeatOrchestrationTemplate(), null, translateTo.getContext()); + if (serviceScalingValue != null) { + innerProps.put(ToscaConstants.SCALING_ENABLED_PROPERTY_NAME, + (HeatBoolean.isValueBoolean(serviceScalingValue)) ? HeatBoolean + .eval(serviceScalingValue) : serviceScalingValue); + } + } + } + + private boolean getOrderedInterfaces(Resource contrailServiceTemplate) { + Object orderedInterfaces = contrailServiceTemplate.getProperties().get("ordered_interfaces"); + if (orderedInterfaces == null) { + return false; + } + if (orderedInterfaces instanceof String) { + return HeatBoolean.eval(orderedInterfaces); + } + //if get_param, set default value to true + return true; + } + + private ServiceTemplate createNestedServiceTemplate(TranslateTo translateTo, + String computeNodeTypeId, + String substitutedNodeTypeId, + NodeTemplate substitutedNodeTemplate, + boolean orderedInterfaces) { + ServiceTemplate nestedSubstitutionServiceTemplate = new ServiceTemplate(); + setNestedServiceTemplateGeneralDetails(translateTo, nestedSubstitutionServiceTemplate); + String heatStackGroupKey = addHeatStackGroup(translateTo, nestedSubstitutionServiceTemplate); + addSubstitutionMappingEntry(nestedSubstitutionServiceTemplate, substitutedNodeTypeId); + + handleInputParameters(nestedSubstitutionServiceTemplate); + String computeNodeTemplateId = + handleComputeNodeTemplate(translateTo, computeNodeTypeId, nestedSubstitutionServiceTemplate, + heatStackGroupKey); + handleOutputParameters(nestedSubstitutionServiceTemplate, computeNodeTemplateId); + handleServiceInstanceInterfaces(translateTo, nestedSubstitutionServiceTemplate, + substitutedNodeTemplate, heatStackGroupKey, orderedInterfaces, computeNodeTemplateId); + + return nestedSubstitutionServiceTemplate; + } + + private void handleOutputParameters(ServiceTemplate nestedSubstitutionServiceTemplate, + String nodeTemplateId) { + if (nodeTemplateId == null) { + return; + } + NodeType contrailAbstractNodeType = + ContrailAbstractSubstituteGlobalType.createServiceTemplate().getNode_types() + .get(ToscaNodeType.CONTRAIL_ABSTRACT_SUBSTITUTE.getDisplayName()); + Map contrailAbstractAttributes = + contrailAbstractNodeType.getAttributes(); + Map nestedSubstitutionServiceTemplateOutputs = new HashMap<>(); + + if (contrailAbstractAttributes == null) { + return; + } + + for (String attributeKey : contrailAbstractAttributes.keySet()) { + AttributeDefinition abstractAttributeDef = contrailAbstractAttributes.get(attributeKey); + if (abstractAttributeDef != null) { + Map outputValue = new HashMap<>(); + List outputGetAttributeList = new ArrayList<>(); + outputGetAttributeList.add(nodeTemplateId); + outputGetAttributeList.add(attributeKey); + outputValue.put(ToscaFunctions.GET_ATTRIBUTE.getDisplayName(), outputGetAttributeList); + nestedSubstitutionServiceTemplateOutputs.put(attributeKey, + DataModelUtil.convertAttributeDefToParameterDef(abstractAttributeDef, outputValue)); + } + } + if (!nestedSubstitutionServiceTemplateOutputs.isEmpty()) { + nestedSubstitutionServiceTemplate.getTopology_template() + .setOutputs(nestedSubstitutionServiceTemplateOutputs); + } + } + + private void handleServiceInstanceInterfaces(TranslateTo translateTo, + ServiceTemplate nestedSubstitutionServiceTemplate, + NodeTemplate substitutedNodeTemplate, + String heatStackGroupKey, boolean orderedInterfaces, + String computeNodeTemplateId) { + Resource serviceInstanceResource = translateTo.getResource(); + Object interfaceListProperty = serviceInstanceResource.getProperties().get("interface_list"); + if (interfaceListProperty == null) { + return; + } + if (interfaceListProperty instanceof List) { + for (int index = 0; index < ((List) interfaceListProperty).size(); index++) { + Object interfaceEntry = ((List) interfaceListProperty).get(index); + handleInterface(translateTo, interfaceEntry, index, nestedSubstitutionServiceTemplate, + heatStackGroupKey, substitutedNodeTemplate, orderedInterfaces, computeNodeTemplateId); + } + } else if (interfaceListProperty instanceof Map) { + handleInterface(translateTo, interfaceListProperty, null, nestedSubstitutionServiceTemplate, + heatStackGroupKey, substitutedNodeTemplate, orderedInterfaces, computeNodeTemplateId); + } + } + + private void handleInterface(TranslateTo translateTo, Object interfacePropertyValue, + Integer index, + ServiceTemplate nestedSubstitutionServiceTemplate, + String heatStackGroupKey, NodeTemplate substitutedNodeTemplate, + boolean orderedInterfaces, String computeNodeTemplateId) { + if (index == null) { + index = new Integer(0); + } + NodeTemplate portNodeTemplate = + createPortNodeTemplate(index, orderedInterfaces, computeNodeTemplateId); + String portNodeTemplateId = "port_" + index; + String portReqMappingKey = "link_" + portNodeTemplateId; + + DataModelUtil + .addNodeTemplate(nestedSubstitutionServiceTemplate, portNodeTemplateId, portNodeTemplate); + updateSubstitutionMappingRequirement(nestedSubstitutionServiceTemplate, portReqMappingKey, + portNodeTemplateId); + updateHeatStackGroup(nestedSubstitutionServiceTemplate, heatStackGroupKey, portNodeTemplateId); + connectPortToNetwork(translateTo, interfacePropertyValue, substitutedNodeTemplate, + portReqMappingKey); + } + + private void connectPortToNetwork(TranslateTo translateTo, Object interfacePropertyValue, + NodeTemplate substitutedNodeTemplate, + String portReqMappingKey) { + List validNetworksForConnections = Arrays + .asList(HeatResourcesTypes.NEUTRON_NET_RESOURCE_TYPE.getHeatResource(), + HeatResourcesTypes.CONTRAIL_VIRTUAL_NETWORK_RESOURCE_TYPE.getHeatResource()); + + if (interfacePropertyValue instanceof Map) { + Object virtualNetworkValue = ((Map) interfacePropertyValue).get("virtual_network"); + if (virtualNetworkValue != null) { + Optional networkAttachedResourceId = HeatToToscaUtil + .extractAttachedResourceId(translateTo.getHeatFileName(), + translateTo.getHeatOrchestrationTemplate(), translateTo.getContext(), + virtualNetworkValue); + if (networkAttachedResourceId.isPresent()) { + Optional networkResourceId = + HeatToToscaUtil.getContrailAttachedHeatResourceId(networkAttachedResourceId.get()); + if (networkResourceId.isPresent()) { + Resource networkResource = HeatToToscaUtil + .getResource(translateTo.getHeatOrchestrationTemplate(), networkResourceId.get(), + translateTo.getHeatFileName()); + if (validNetworksForConnections.contains(networkResource.getType())) { + Optional networkTranslatedId = + getResourceTranslatedId(translateTo.getHeatFileName(), + translateTo.getHeatOrchestrationTemplate(), networkResourceId.get(), + translateTo.getContext()); + if (networkTranslatedId.isPresent()) { + addLinkToNetworkRequirementAssignment(substitutedNodeTemplate, + networkTranslatedId.get(), portReqMappingKey); + } + } else { + logger.warn("Heat resource " + translateTo.getResourceId() + " with type " + + translateTo.getResource().getType() + + " has connection to invalid/not supported network resource, therefore, this " + + "connection will be ignored in the translation."); + } + } else if (networkAttachedResourceId.get().isGetParam()) { + TranslatedHeatResource translatedSharedResourceId = + translateTo.getContext().getHeatSharedResourcesByParam() + .get(networkAttachedResourceId.get().getEntityId()); + if (Objects.nonNull(translatedSharedResourceId) + && !HeatToToscaUtil.isHeatFileNested(translateTo, translateTo.getHeatFileName())) { + addLinkToNetworkRequirementAssignment(substitutedNodeTemplate, + translatedSharedResourceId.getTranslatedId(), portReqMappingKey); + } + } else { + logger.warn("Heat resource: '" + translateTo.getResourceId() + "' with type: '" + + translateTo.getResource().getType() + + "' include 'virtual_network' property with value '" + + virtualNetworkValue.toString() + + "', the connection to this network wasn't found/not supported therefore this " + + "connection will be ignored in TOSCA translation for this property."); + } + } + } else { + logger.warn("Heat resource: '" + translateTo.getResourceId() + "' with type: '" + + translateTo.getResource().getType() + + "' missing 'virtual_network' property in 'interface_list' entry, therefore, no " + + "network connection is define for this entry."); + } + } + } + + private NodeTemplate createPortNodeTemplate(Integer index, boolean orderedInterfaces, + String computeNodeTemplateId) { + NodeTemplate portNodeTemplate = new NodeTemplate(); + portNodeTemplate.setType(ToscaNodeType.CONTRAIL_PORT.getDisplayName()); + Map portProperties = new HashMap<>(); + portProperties.put("static_routes", DataModelUtil + .createGetInputPropertyValueFromListParameter("interface_list", index, "static_routes")); + portProperties.put("virtual_network", DataModelUtil + .createGetInputPropertyValueFromListParameter("interface_list", index, "virtual_network")); + portProperties.put("allowed_address_pairs", DataModelUtil + .createGetInputPropertyValueFromListParameter("interface_list", index, + "allowed_address_pairs")); + portProperties.put("ip_address", DataModelUtil + .createGetInputPropertyValueFromListParameter("interface_list", index, "ip_address")); + portProperties.put("static_route", + DataModelUtil.createGetInputPropertyValueFromListParameter("static_routes_list", index)); + portProperties.put("shared_ip", + DataModelUtil.createGetInputPropertyValueFromListParameter("shared_ip_list", index)); + portProperties.put("interface_type", DataModelUtil + .createGetInputPropertyValueFromListParameter("service_interface_type_list", index)); + if (orderedInterfaces) { + portProperties.put("order", index); + } + portNodeTemplate.setProperties(portProperties); + addBindingReqFromPortToCompute(computeNodeTemplateId, portNodeTemplate); + return portNodeTemplate; + } + + + private void addLinkToNetworkRequirementAssignment(NodeTemplate nodeTemplate, + String connectedNodeTranslatedId, + String requirementId) { + if (nodeTemplate == null || connectedNodeTranslatedId == null) { + return; + } + + RequirementAssignment requirement = new RequirementAssignment(); + requirement.setCapability(ToscaCapabilityType.NETWORK_LINKABLE.getDisplayName()); + requirement.setRelationship(ToscaRelationshipType.NETWORK_LINK_TO.getDisplayName()); + requirement.setNode(connectedNodeTranslatedId); + DataModelUtil.addRequirementAssignment(nodeTemplate, requirementId, requirement); + } + + private void updateHeatStackGroup(ServiceTemplate serviceTemplate, String heatStackGroupKey, + String memberId) { + serviceTemplate.getTopology_template().getGroups().get(heatStackGroupKey).getMembers() + .add(memberId); + } + + private void updateSubstitutionMappingRequirement(ServiceTemplate serviceTemplate, + String portReqMappingKey, + String portNodeTemplateId) { + List portReqMappingValue = new ArrayList<>(); + portReqMappingValue.add(portNodeTemplateId); + portReqMappingValue.add(ToscaConstants.LINK_REQUIREMENT_ID); + DataModelUtil + .addSubstitutionMappingReq(serviceTemplate, portReqMappingKey, portReqMappingValue); + } + + private void addSubstitutionMappingEntry(ServiceTemplate nestedSubstitutionServiceTemplate, + String substitutedNodeTypeId) { + SubstitutionMapping substitutionMappings = new SubstitutionMapping(); + substitutionMappings.setNode_type(substitutedNodeTypeId); + DataModelUtil.addSubstitutionMapping(nestedSubstitutionServiceTemplate, substitutionMappings); + } + + private void handleInputParameters(ServiceTemplate nestedSubstitutionServiceTemplate) { + NodeType contrailAbstractNodeType = + ContrailAbstractSubstituteGlobalType.createServiceTemplate().getNode_types() + .get(ToscaNodeType.CONTRAIL_ABSTRACT_SUBSTITUTE.getDisplayName()); + Map contrailAbstractProperties = + contrailAbstractNodeType.getProperties(); + Map nestedSubstitutionServiceTemplateInputs = new HashMap<>(); + + for (String propertyKey : contrailAbstractProperties.keySet()) { + PropertyDefinition abstractPropertyDef = contrailAbstractProperties.get(propertyKey); + if (abstractPropertyDef != null) { + nestedSubstitutionServiceTemplateInputs + .put(propertyKey, DataModelUtil.convertPropertyDefToParameterDef(abstractPropertyDef)); + + } + } + if (!nestedSubstitutionServiceTemplateInputs.isEmpty()) { + nestedSubstitutionServiceTemplate.getTopology_template() + .setInputs(nestedSubstitutionServiceTemplateInputs); + } + } + + private String handleComputeNodeTemplate(TranslateTo translateTo, String computeNodeTypeId, + ServiceTemplate nestedSubstitutionServiceTemplate, + String heatStackGroupKey) { + NodeType contrailComputeNodeType = + ContrailComputeGlobalType.createServiceTemplate().getNode_types() + .get(ToscaNodeType.CONTRAIL_COMPUTE.getDisplayName()); + Map contrailComputeProperties = + contrailComputeNodeType.getProperties(); + Map computeNodeTemplateProperties = new HashMap<>(); + + if (contrailComputeProperties != null) { + for (String computePropertyKey : contrailComputeProperties.keySet()) { + Map getInputProperty = new HashMap<>(); + getInputProperty.put(ToscaFunctions.GET_INPUT.getDisplayName(), computePropertyKey); + computeNodeTemplateProperties.put(computePropertyKey, getInputProperty); + } + } + + NodeTemplate computeNodeTemplate = new NodeTemplate(); + computeNodeTemplate.setType(computeNodeTypeId); + if (!computeNodeTemplateProperties.isEmpty()) { + computeNodeTemplate.setProperties(computeNodeTemplateProperties); + } + String computeNodeTemplateId = translateTo.getTranslatedId(); + DataModelUtil.addNodeTemplate(nestedSubstitutionServiceTemplate, computeNodeTemplateId, + computeNodeTemplate); + nestedSubstitutionServiceTemplate.getTopology_template().getGroups().get(heatStackGroupKey) + .getMembers().add(computeNodeTemplateId); + + return computeNodeTemplateId; + } + + private String addHeatStackGroup(TranslateTo translateTo, ServiceTemplate serviceTemplate) { + GroupDefinition serviceInstanceGroupDefinition = new GroupDefinition(); + serviceInstanceGroupDefinition.setType(ToscaGroupType.HEAT_STACK.getDisplayName()); + Map groupProperties = new HashMap<>(); + groupProperties.put("heat_file", + "../" + (new ToscaFileOutputServiceCsarImpl()).getArtifactsFolderName() + "/" + + translateTo.getHeatFileName()); + serviceInstanceGroupDefinition.setProperties(groupProperties); + serviceInstanceGroupDefinition.setMembers(new ArrayList<>()); + String heatStackGroupKey = translateTo.getTranslatedId(); + DataModelUtil.addGroupDefinitionToTopologyTemplate(serviceTemplate, heatStackGroupKey, + serviceInstanceGroupDefinition); + + return heatStackGroupKey; + } + + + private void setNestedServiceTemplateGeneralDetails(TranslateTo translateTo, + ServiceTemplate nestedSubstitutionServiceTemplate) { + Metadata nestedTemplateMetadata = new Metadata(); + String nestedTemplateName = translateTo.getResourceId(); + nestedTemplateMetadata.setTemplate_name(nestedTemplateName); + nestedSubstitutionServiceTemplate.setMetadata(nestedTemplateMetadata); + nestedSubstitutionServiceTemplate + .setTosca_definitions_version(ToscaConstants.TOSCA_DEFINITIONS_VERSION); + nestedSubstitutionServiceTemplate.setTopology_template(new TopologyTemplate()); + nestedSubstitutionServiceTemplate.setImports(GlobalTypesGenerator.getGlobalTypesImportList()); + nestedSubstitutionServiceTemplate.getImports() + .put(Constants.GLOBAL_SUBSTITUTION_TYPES_TEMPLATE_NAME, GlobalTypesUtil + .createServiceTemplateImport(Constants.GLOBAL_SUBSTITUTION_TYPES_TEMPLATE_NAME)); + } + + private NodeTemplate createSubstitutedNodeTemplate(TranslateTo translateTo, + Resource contrailServiceTemplateResource, + String contrailServiceTemplateTranslatedId, + int numberOfPorts) { + + translateTo.getServiceTemplate().getImports() + .put(Constants.GLOBAL_SUBSTITUTION_TYPES_TEMPLATE_NAME, GlobalTypesUtil + .createServiceTemplateImport(Constants.GLOBAL_SUBSTITUTION_TYPES_TEMPLATE_NAME)); + NodeTemplate substitutesNodeTemplate = new NodeTemplate(); + substitutesNodeTemplate.setType(contrailServiceTemplateTranslatedId); + List directiveList = new ArrayList<>(); + directiveList.add(ToscaConstants.NODE_TEMPLATE_DIRECTIVE_SUBSTITUTABLE); + substitutesNodeTemplate.setDirectives(directiveList); + substitutesNodeTemplate.setProperties(TranslatorHeatToToscaPropertyConverter + .getToscaPropertiesSimpleConversion(translateTo.getResource().getProperties(), + substitutesNodeTemplate.getProperties(), translateTo.getHeatFileName(), + translateTo.getHeatOrchestrationTemplate(), + HeatResourcesTypes.CONTRAIL_SERVICE_INSTANCE.getHeatResource(), substitutesNodeTemplate, + translateTo.getContext())); + substitutesNodeTemplate.setProperties(TranslatorHeatToToscaPropertyConverter + .getToscaPropertiesSimpleConversion(contrailServiceTemplateResource.getProperties(), + substitutesNodeTemplate.getProperties(), translateTo.getHeatFileName(), + translateTo.getHeatOrchestrationTemplate(), + HeatResourcesTypes.CONTRAIL_SERVICE_TEMPLATE.getHeatResource(), substitutesNodeTemplate, + translateTo.getContext())); + HeatToToscaUtil.mapBoolean(substitutesNodeTemplate, "availability_zone_enable"); + HeatToToscaUtil.mapBoolean(substitutesNodeTemplate, "ordered_interfaces"); + + Object sharedIpListPropertyValue = + contrailServiceTemplateResource.getProperties().get("shared_ip_list"); + Optional>> sharedIpTranslatedSplitFun = + TranslatorHeatToToscaFunctionConverter + .translateFnSplitFunction(sharedIpListPropertyValue, numberOfPorts, true); + if (sharedIpTranslatedSplitFun.isPresent()) { + substitutesNodeTemplate.getProperties() + .put("shared_ip_list", sharedIpTranslatedSplitFun.get()); + } else { + HeatToToscaUtil.mapBooleanList(substitutesNodeTemplate, "shared_ip_list"); + } + + Object staticRouteListPropertyValue = + contrailServiceTemplateResource.getProperties().get("static_routes_list"); + Optional>> staticRouteTranslatedSplitFun = + TranslatorHeatToToscaFunctionConverter + .translateFnSplitFunction(staticRouteListPropertyValue, numberOfPorts, true); + if (staticRouteTranslatedSplitFun.isPresent()) { + substitutesNodeTemplate.getProperties() + .put("static_routes_list", staticRouteTranslatedSplitFun.get()); + } else { + HeatToToscaUtil.mapBooleanList(substitutesNodeTemplate, "static_routes_list"); + } + + Object serviceInterfaceTypeListPropertyValue = + contrailServiceTemplateResource.getProperties().get("service_interface_type_list"); + Optional>> serviceInterfaceTypeTranslatedSplitFun = + TranslatorHeatToToscaFunctionConverter + .translateFnSplitFunction(serviceInterfaceTypeListPropertyValue, numberOfPorts, false); + if (serviceInterfaceTypeTranslatedSplitFun.isPresent()) { + substitutesNodeTemplate.getProperties() + .put("service_interface_type_list", serviceInterfaceTypeTranslatedSplitFun.get()); + } + + String substitutedNodeTemplateId = translateTo.getTranslatedId(); + DataModelUtil.addNodeTemplate(translateTo.getServiceTemplate(), substitutedNodeTemplateId, + substitutesNodeTemplate); + return substitutesNodeTemplate; + } + + private void addNetworkLinkRequirements(NodeType nodeType, int numberOfPorts) { + if (nodeType.getRequirements() == null) { + List> requirementList = new ArrayList<>(); + for (int i = 0; i < numberOfPorts; i++) { + Map requirementDefinitionMap = new HashMap<>(); + requirementDefinitionMap.put(ToscaConstants.LINK_REQUIREMENT_ID + "_port_" + i, + DataModelUtil.createRequirement(ToscaCapabilityType.NETWORK_LINKABLE.getDisplayName(), + ToscaNodeType.ROOT.getDisplayName(), + ToscaRelationshipType.NETWORK_LINK_TO.getDisplayName(), null)); + requirementList.add(requirementDefinitionMap); + } + if (numberOfPorts > 0) { + nodeType.setRequirements(requirementList); + } + } + } + + private int getServiceInstanceNumberOfPorts(Resource serviceInstanceResource) { + int numberOfPorts; + Object interfaceTypeProperty = serviceInstanceResource.getProperties().get("interface_list"); + if (interfaceTypeProperty == null) { + numberOfPorts = 0; + } else if (interfaceTypeProperty instanceof List) { + numberOfPorts = ((List) interfaceTypeProperty).size(); + } else if (interfaceTypeProperty instanceof Map) { + numberOfPorts = 1; + } else { + numberOfPorts = 0; + } + + return numberOfPorts; + } + + private AttachedResourceId getServiceTemplateAttachedId(TranslateTo translateTo, + Resource serviceInstanceResource) { + Object serviceTemplateProperty = + serviceInstanceResource.getProperties().get("service_template"); + Optional serviceTemplateId = HeatToToscaUtil + .extractAttachedResourceId(translateTo.getHeatFileName(), + translateTo.getHeatOrchestrationTemplate(), translateTo.getContext(), + serviceTemplateProperty); + if (serviceTemplateId.isPresent()) { + return serviceTemplateId.get(); + } else { + throw new CoreException(new MissingMandatoryPropertyErrorBuilder("service_template").build()); + } + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailServiceTemplateImpl.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailServiceTemplateImpl.java new file mode 100644 index 0000000000..e0a3ed422f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailServiceTemplateImpl.java @@ -0,0 +1,100 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.tosca.datatypes.ToscaNodeType; +import org.openecomp.sdc.tosca.datatypes.model.Metadata; +import org.openecomp.sdc.tosca.datatypes.model.NodeType; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.tosca.services.ToscaConstants; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslateTo; +import org.openecomp.sdc.translator.services.heattotosca.Constants; +import org.openecomp.sdc.translator.services.heattotosca.errors.MissingMandatoryPropertyErrorBuilder; +import org.openecomp.sdc.translator.services.heattotosca.globaltypes.GlobalTypesGenerator; +import org.openecomp.sdc.translator.services.heattotosca.helper.ContrailTranslationHelper; + +import java.util.Map; +import java.util.Objects; + +public class ResourceTranslationContrailServiceTemplateImpl extends ResourceTranslationBase { + + static String getContrailSubstitutedNodeTypeId(String serviceTemplateTranslatedId) { + return ToscaConstants.NODES_SUBSTITUTION_PREFIX + serviceTemplateTranslatedId; + } + + @Override + protected boolean isEssentialRequirementsValid(TranslateTo translateTo) { + Map properties = translateTo.getResource().getProperties(); + if (Objects.isNull(properties) || Objects.isNull(properties.get("image_name"))) { + throw new CoreException(new MissingMandatoryPropertyErrorBuilder("image_name").build()); + } + return true; + } + + @Override + public void translate(TranslateTo translateTo) { + + ServiceTemplate globalSubstitutionServiceTemplate = + getGlobalSubstitutionTypesServiceTemplate(translateTo); + addSubstitutedNodeType(translateTo, globalSubstitutionServiceTemplate); + addComputeNodeType(translateTo, globalSubstitutionServiceTemplate); + } + + private void addComputeNodeType(TranslateTo translateTo, + ServiceTemplate globalSubstitutionServiceTemplate) { + NodeType computeNodeType = new NodeType(); + computeNodeType.setDerived_from(ToscaNodeType.CONTRAIL_COMPUTE.getDisplayName()); + String computeNodeTypeId = new ContrailTranslationHelper() + .getComputeNodeTypeId(translateTo.getTranslatedId(), translateTo.getResource()); + DataModelUtil + .addNodeType(globalSubstitutionServiceTemplate, computeNodeTypeId, computeNodeType); + } + + private void addSubstitutedNodeType(TranslateTo translateTo, + ServiceTemplate globalSubstitutionServiceTemplate) { + NodeType substitutedNodeType = new NodeType(); + substitutedNodeType + .setDerived_from(ToscaNodeType.CONTRAIL_ABSTRACT_SUBSTITUTE.getDisplayName()); + DataModelUtil.addNodeType(globalSubstitutionServiceTemplate, + getContrailSubstitutedNodeTypeId(translateTo.getTranslatedId()), substitutedNodeType); + } + + private ServiceTemplate getGlobalSubstitutionTypesServiceTemplate(TranslateTo translateTo) { + ServiceTemplate globalSubstitutionServiceTemplate = + translateTo.getContext().getTranslatedServiceTemplates() + .get(Constants.GLOBAL_SUBSTITUTION_TYPES_TEMPLATE_NAME); + if (globalSubstitutionServiceTemplate == null) { + globalSubstitutionServiceTemplate = new ServiceTemplate(); + Metadata templateMetadata = new Metadata(); + templateMetadata.setTemplate_name(Constants.GLOBAL_SUBSTITUTION_TYPES_TEMPLATE_NAME); + globalSubstitutionServiceTemplate.setMetadata(templateMetadata); + globalSubstitutionServiceTemplate.setImports(GlobalTypesGenerator.getGlobalTypesImportList()); + globalSubstitutionServiceTemplate + .setTosca_definitions_version(ToscaConstants.TOSCA_DEFINITIONS_VERSION); + translateTo.getContext().getTranslatedServiceTemplates() + .put(Constants.GLOBAL_SUBSTITUTION_TYPES_TEMPLATE_NAME, + globalSubstitutionServiceTemplate); + } + return globalSubstitutionServiceTemplate; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailV2NetworkPolicyImpl.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailV2NetworkPolicyImpl.java new file mode 100644 index 0000000000..72a25985a8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailV2NetworkPolicyImpl.java @@ -0,0 +1,49 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.openecomp.sdc.tosca.datatypes.ToscaNodeType; +import org.openecomp.sdc.tosca.datatypes.model.NodeTemplate; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslateTo; +import org.openecomp.sdc.translator.services.heattotosca.mapping.TranslatorHeatToToscaPropertyConverter; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +public class ResourceTranslationContrailV2NetworkPolicyImpl extends ResourceTranslationBase { + + protected static Logger logger = + LoggerFactory.getLogger(ResourceTranslationContrailV2NetworkPolicyImpl.class); + + @Override + protected void translate(TranslateTo translateTo) { + + NodeTemplate nodeTemplate = new NodeTemplate(); + nodeTemplate.setType(ToscaNodeType.CONTRAILV2_NETWORK_RULE.getDisplayName()); + nodeTemplate.setProperties(TranslatorHeatToToscaPropertyConverter + .getToscaPropertiesSimpleConversion(translateTo.getResource().getProperties(), + nodeTemplate.getProperties(), translateTo.getHeatFileName(), + translateTo.getHeatOrchestrationTemplate(), translateTo.getResource().getType(), + nodeTemplate, translateTo.getContext())); + DataModelUtil.addNodeTemplate(translateTo.getServiceTemplate(), translateTo.getTranslatedId(), + nodeTemplate); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailV2VirtualNetworkImpl.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailV2VirtualNetworkImpl.java new file mode 100644 index 0000000000..d81f3196a3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailV2VirtualNetworkImpl.java @@ -0,0 +1,209 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.apache.commons.collections.CollectionUtils; +import org.openecomp.sdc.heat.datatypes.model.HeatResourcesTypes; +import org.openecomp.sdc.heat.datatypes.model.Resource; +import org.openecomp.sdc.tosca.datatypes.ToscaCapabilityType; +import org.openecomp.sdc.tosca.datatypes.ToscaNodeType; +import org.openecomp.sdc.tosca.datatypes.ToscaRelationshipType; +import org.openecomp.sdc.tosca.datatypes.model.NodeTemplate; +import org.openecomp.sdc.tosca.datatypes.model.RequirementAssignment; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.tosca.services.ToscaConstants; +import org.openecomp.sdc.translator.datatypes.heattotosca.AttachedResourceId; +import org.openecomp.sdc.translator.datatypes.heattotosca.ResourceReferenceType; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslateTo; +import org.openecomp.sdc.translator.services.heattotosca.HeatToToscaUtil; +import org.openecomp.sdc.translator.services.heattotosca.ResourceTranslationFactory; +import org.openecomp.sdc.translator.services.heattotosca.mapping.TranslatorHeatToToscaPropertyConverter; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.List; +import java.util.Map; +import java.util.Optional; + +public class ResourceTranslationContrailV2VirtualNetworkImpl extends ResourceTranslationBase { + + protected static Logger logger = + LoggerFactory.getLogger(ResourceTranslationContrailV2VirtualNetworkImpl.class); + + @Override + public void translate(TranslateTo translateTo) { + + NodeTemplate nodeTemplate = new NodeTemplate(); + nodeTemplate.setType(ToscaNodeType.CONTRAILV2_VIRTUAL_NETWORK.getDisplayName()); + nodeTemplate.setProperties(TranslatorHeatToToscaPropertyConverter + .getToscaPropertiesSimpleConversion(translateTo.getResource().getProperties(), + nodeTemplate.getProperties(), translateTo.getHeatFileName(), + translateTo.getHeatOrchestrationTemplate(), translateTo.getResource().getType(), + nodeTemplate, translateTo.getContext())); + Optional resourceTranslatedId = getResourceTranslatedId(translateTo.getHeatFileName(), + translateTo.getHeatOrchestrationTemplate(), translateTo.getResourceId(), + translateTo.getContext()); + if (resourceTranslatedId.isPresent()) { + DataModelUtil.addNodeTemplate(translateTo.getServiceTemplate(), resourceTranslatedId.get(), + nodeTemplate); + } + linkToPolicyNodeTemplate(translateTo); + } + + private void linkToPolicyNodeTemplate(TranslateTo translateTo) { + List networkPolicyIdList = extractNetworkPolicyIdList(translateTo); + if (CollectionUtils.isEmpty(networkPolicyIdList)) { + return; + } + for (AttachedResourceId attachedResourceId : networkPolicyIdList) { + NodeTemplate policyNodeTemplate = DataModelUtil + .getNodeTemplate(translateTo.getServiceTemplate(), + (String) attachedResourceId.getTranslatedId()); + DataModelUtil + .addRequirementAssignment(policyNodeTemplate, ToscaConstants.NETWORK_REQUIREMENT_ID, + createRequirementAssignment(translateTo.getTranslatedId())); + } + } + + private List extractNetworkPolicyIdList(TranslateTo translateTo) { + + Object propertyValue = translateTo.getResource().getProperties().get("network_policy_refs"); + if (propertyValue != null) { + return extractNetworkPolicyId(propertyValue, translateTo); + } else { + return null; + } + } + + private List extractNetworkPolicyId(Object propertyValue, + TranslateTo translateTo) { + List attachedResourceIdList = new ArrayList<>(); + + if (propertyValue instanceof List) { + for (Object value : (List) propertyValue) { + attachedResourceIdList.addAll(extractNetworkPolicyId(value, translateTo)); + } + } else { + AttachedResourceId resourceId = parsNetworkPolicyId(propertyValue, translateTo); + if (resourceId != null) { + attachedResourceIdList.add(resourceId); + } + } + return attachedResourceIdList; + } + + private AttachedResourceId parsNetworkPolicyId(Object propertyValue, TranslateTo translateTo) { + + Optional translatedPolicyResourceId; + String policyResourceId = extractResourceId(propertyValue, translateTo); + if (policyResourceId == null) { + return null; + } + + Resource policyResource = HeatToToscaUtil + .getResource(translateTo.getHeatOrchestrationTemplate(), policyResourceId, + translateTo.getHeatFileName()); + if (!policyResource.getType() + .equals(HeatResourcesTypes.CONTRAIL_V2_NETWORK_RULE_RESOURCE_TYPE.getHeatResource())) { + return null; + } + translatedPolicyResourceId = ResourceTranslationFactory.getInstance(policyResource) + .translateResource(translateTo.getHeatFileName(), translateTo.getServiceTemplate(), + translateTo.getHeatOrchestrationTemplate(), policyResource, policyResourceId, + translateTo.getContext()); + if (!translatedPolicyResourceId.isPresent()) { + logger.warn("Heat resource: '" + translateTo.getResourceId() + "' with type: '" + + translateTo.getResource().getType() + + "' property network_policy_refs is referenced to an " + + "unsupported resource the connection will be ignored in TOSCA translation."); + return null; + } + return + new AttachedResourceId(translatedPolicyResourceId.get(), policyResourceId, + ResourceReferenceType.GET_ATTR); + } + + private String extractResourceId(Object propertyValue, TranslateTo translateTo) { + + Object value; + if (propertyValue instanceof Map) { + if (((Map) propertyValue).containsKey("get_attr")) { + value = ((Map) propertyValue).get("get_attr"); + if (value instanceof List) { + if (((List) value).size() == 2 && ((List) value).get(1).equals("fq_name")) { + if (((List) value).get(0) instanceof String) { + return (String) ((List) value).get(0); + } else { + logger.warn("Heat resource: '" + translateTo.getResourceId() + "' with type: '" + + translateTo.getResource().getType() + + "' has property with invalid format of 'get_attr' function " + + "with 'fq_name' value, therefore this property" + + " will be ignored in TOSCA translation."); + } + } + } + } else if (((Map) propertyValue).containsKey("get_resource")) { + value = ((Map) propertyValue).get("get_resource"); + if (value instanceof String) { + return (String) value; + } else { + logger.warn("Heat resource: '" + translateTo.getResourceId() + "' with type: '" + + translateTo.getResource().getType() + + "' has property invalid format of 'get_resource' function, therefore" + + " this property will be ignored in TOSCA translation."); + } + } else { + Collection valCollection = ((Map) propertyValue).values(); + for (Object entryValue : valCollection) { + String ret = extractResourceId(entryValue, translateTo); + if (ret != null) { + return ret; + } + + } + } + } else if (propertyValue instanceof List) { + for (Object prop : (List) propertyValue) { + String ret = extractResourceId(prop, translateTo); + if (ret != null) { + return ret; + } + } + } + logger.warn("Heat resource: '" + translateTo.getResourceId() + "' with type: '" + + translateTo.getResource().getType() + + "' invalid format of property value, therefore " + + "this resource will be ignored in TOSCA translation."); + return null; + } + + private RequirementAssignment createRequirementAssignment(String translatedNetworkResourceId) { + RequirementAssignment requirement = new RequirementAssignment(); + requirement.setCapability(ToscaCapabilityType.ATTACHMENT.getDisplayName()); + requirement.setNode(translatedNetworkResourceId); + requirement.setRelationship(ToscaRelationshipType.ATTACHES_TO.getDisplayName()); + return requirement; + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailV2VmInterfaceImpl.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailV2VmInterfaceImpl.java new file mode 100644 index 0000000000..14403df002 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailV2VmInterfaceImpl.java @@ -0,0 +1,126 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.openecomp.sdc.heat.datatypes.model.HeatResourcesTypes; +import org.openecomp.sdc.heat.datatypes.model.Resource; +import org.openecomp.sdc.tosca.datatypes.ToscaNodeType; +import org.openecomp.sdc.tosca.datatypes.model.NodeTemplate; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.translator.datatypes.heattotosca.AttachedResourceId; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslateTo; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslatedHeatResource; +import org.openecomp.sdc.translator.services.heattotosca.HeatToToscaUtil; +import org.openecomp.sdc.translator.services.heattotosca.mapping.TranslatorHeatToToscaPropertyConverter; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import java.util.Arrays; +import java.util.List; +import java.util.Objects; +import java.util.Optional; + + +public class ResourceTranslationContrailV2VmInterfaceImpl extends ResourceTranslationBase { + protected static Logger logger = + LoggerFactory.getLogger(ResourceTranslationContrailV2VmInterfaceImpl.class); + + @Override + protected void translate(TranslateTo translateTo) { + NodeTemplate nodeTemplate = new NodeTemplate(); + nodeTemplate.setType(ToscaNodeType.CONTRAILV2_VIRTUAL_MACHINE_INTERFACE.getDisplayName()); + + nodeTemplate.setProperties(TranslatorHeatToToscaPropertyConverter + .getToscaPropertiesSimpleConversion(translateTo.getResource().getProperties(), + nodeTemplate.getProperties(), translateTo.getHeatFileName(), + translateTo.getHeatOrchestrationTemplate(), translateTo.getResource().getType(), + nodeTemplate, translateTo.getContext())); + handleNetworkRequirement(translateTo, nodeTemplate); + Optional resourceTranslatedId = getResourceTranslatedId(translateTo.getHeatFileName(), + translateTo.getHeatOrchestrationTemplate(), translateTo.getResourceId(), + translateTo.getContext()); + if (resourceTranslatedId.isPresent()) { + DataModelUtil.addNodeTemplate(translateTo.getServiceTemplate(), resourceTranslatedId.get(), + nodeTemplate); + } + } + + private void handleNetworkRequirement(TranslateTo translateTo, NodeTemplate nodeTemplate) { + Object virtualNetworkRefs = + translateTo.getResource().getProperties().get("virtual_network_refs"); + if (Objects.isNull(virtualNetworkRefs) || !(virtualNetworkRefs instanceof List) + || ((List) virtualNetworkRefs).size() == 0) { + return; + } + List acceptableResourceTypes = Arrays + .asList(HeatResourcesTypes.NEUTRON_NET_RESOURCE_TYPE.getHeatResource(), + HeatResourcesTypes.CONTRAIL_V2_VIRTUAL_NETWORK_RESOURCE_TYPE.getHeatResource()); + List virtualNetworkRefList = (List) virtualNetworkRefs; + if (virtualNetworkRefList.size() > 1) { + logger.warn("Heat resource: '" + translateTo.getResourceId() + "' with type: '" + + translateTo.getResource().getType() + + "' include 'virtual_network_refs' property with more than one network values," + + " only the first network will be translated, " + + "all rest will be ignored in TOSCA translation."); + } + Object virtualNetworkRef = virtualNetworkRefList.get(0); + String networkResourceId = + HeatToToscaUtil.extractContrailGetResourceAttachedHeatResourceId(virtualNetworkRef); + if (Objects.nonNull(networkResourceId)) { // get_resource + Resource networkResource = HeatToToscaUtil + .getResource(translateTo.getHeatOrchestrationTemplate(), networkResourceId, + translateTo.getHeatFileName()); + if (acceptableResourceTypes.contains(networkResource.getType())) { + Optional resourceTranslatedId = + getResourceTranslatedId(translateTo.getHeatFileName(), + translateTo.getHeatOrchestrationTemplate(), networkResourceId, + translateTo.getContext()); + if (resourceTranslatedId.isPresent()) { + addLinkReqFromPortToNetwork(nodeTemplate, resourceTranslatedId.get()); + } + } else { + logger.warn("Heat resource: '" + translateTo.getResourceId() + "' with type: '" + + translateTo.getResource().getType() + + "' include 'virtual_network_refs' property which is connect" + + " to unsupported/incorrect resource with type '" + + networkResource.getType() + + "', therefore, this connection will be ignored in TOSCA translation."); + } + } else { + Optional attachedResourceId = HeatToToscaUtil + .extractAttachedResourceId(translateTo.getHeatFileName(), + translateTo.getHeatOrchestrationTemplate(), translateTo.getContext(), + virtualNetworkRef); + if (attachedResourceId.isPresent() && attachedResourceId.get().isGetParam()) { + TranslatedHeatResource translatedSharedResourceId = + translateTo.getContext().getHeatSharedResourcesByParam() + .get(attachedResourceId.get().getEntityId()); + if (Objects.nonNull(translatedSharedResourceId) + && !HeatToToscaUtil.isHeatFileNested(translateTo, translateTo.getHeatFileName())) { + addLinkReqFromPortToNetwork(nodeTemplate, translatedSharedResourceId.getTranslatedId()); + } + } + } + + + } + +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailVirtualNetworkImpl.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailVirtualNetworkImpl.java new file mode 100644 index 0000000000..3a3a532d59 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailVirtualNetworkImpl.java @@ -0,0 +1,51 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.openecomp.sdc.tosca.datatypes.ToscaNodeType; +import org.openecomp.sdc.tosca.datatypes.model.NodeTemplate; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslateTo; +import org.openecomp.sdc.translator.services.heattotosca.mapping.TranslatorHeatToToscaPropertyConverter; + +import java.util.Optional; + +public class ResourceTranslationContrailVirtualNetworkImpl extends ResourceTranslationBase { + + @Override + public void translate(TranslateTo translateTo) { + + NodeTemplate nodeTemplate = new NodeTemplate(); + nodeTemplate.setType(ToscaNodeType.CONTRAIL_VIRTUAL_NETWORK.getDisplayName()); + nodeTemplate.setProperties(TranslatorHeatToToscaPropertyConverter + .getToscaPropertiesSimpleConversion(translateTo.getResource().getProperties(), + nodeTemplate.getProperties(), translateTo.getHeatFileName(), + translateTo.getHeatOrchestrationTemplate(), translateTo.getResource().getType(), + nodeTemplate, translateTo.getContext())); + Optional resourceTranslatedId = getResourceTranslatedId(translateTo.getHeatFileName(), + translateTo.getHeatOrchestrationTemplate(), translateTo.getResourceId(), + translateTo.getContext()); + if (resourceTranslatedId.isPresent()) { + DataModelUtil.addNodeTemplate(translateTo.getServiceTemplate(), resourceTranslatedId.get(), + nodeTemplate); + } + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationDefaultImpl.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationDefaultImpl.java new file mode 100644 index 0000000000..1182b60a6a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationDefaultImpl.java @@ -0,0 +1,41 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslateTo; + +public class ResourceTranslationDefaultImpl extends ResourceTranslationBase { + + @Override + protected String generateTranslatedId(TranslateTo translateTo) { + return null; + } + + @Override + public void translate(TranslateTo translateTo) { + //no translation is needed, this default is used for unsupported resources + logger.warn("Heat resource: '" + translateTo.getResourceId() + "' with type: '" + + translateTo.getResource().getType() + + "' is not supported, will be ignored in TOSCA translation"); + + } + +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNestedImpl.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNestedImpl.java new file mode 100644 index 0000000000..2573b6849d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNestedImpl.java @@ -0,0 +1,781 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.apache.commons.collections4.CollectionUtils; +import org.apache.commons.collections4.MapUtils; +import org.openecomp.core.utilities.file.FileUtils; +import org.openecomp.sdc.heat.datatypes.manifest.FileData; +import org.openecomp.sdc.heat.datatypes.model.HeatOrchestrationTemplate; +import org.openecomp.sdc.heat.datatypes.model.HeatResourcesTypes; +import org.openecomp.sdc.heat.datatypes.model.Resource; +import org.openecomp.sdc.heat.services.HeatConstants; +import org.openecomp.sdc.tosca.datatypes.ToscaCapabilityType; +import org.openecomp.sdc.tosca.datatypes.ToscaNodeType; +import org.openecomp.sdc.tosca.datatypes.ToscaRelationshipType; +import org.openecomp.sdc.tosca.datatypes.model.AttributeDefinition; +import org.openecomp.sdc.tosca.datatypes.model.CapabilityDefinition; +import org.openecomp.sdc.tosca.datatypes.model.Metadata; +import org.openecomp.sdc.tosca.datatypes.model.NodeTemplate; +import org.openecomp.sdc.tosca.datatypes.model.NodeType; +import org.openecomp.sdc.tosca.datatypes.model.ParameterDefinition; +import org.openecomp.sdc.tosca.datatypes.model.PropertyDefinition; +import org.openecomp.sdc.tosca.datatypes.model.PropertyType; +import org.openecomp.sdc.tosca.datatypes.model.RequirementAssignment; +import org.openecomp.sdc.tosca.datatypes.model.RequirementDefinition; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.datatypes.model.SubstitutionMapping; +import org.openecomp.sdc.tosca.datatypes.model.Template; +import org.openecomp.sdc.tosca.datatypes.model.TopologyTemplate; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.tosca.services.ToscaConstants; +import org.openecomp.sdc.tosca.services.ToscaUtil; +import org.openecomp.sdc.translator.datatypes.heattotosca.AttachedResourceId; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.ResourceFileDataAndIDs; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslateTo; +import org.openecomp.sdc.translator.services.heattotosca.Constants; +import org.openecomp.sdc.translator.services.heattotosca.HeatToToscaUtil; +import org.openecomp.sdc.translator.services.heattotosca.TranslationContext; +import org.openecomp.sdc.translator.services.heattotosca.TranslationService; +import org.openecomp.sdc.translator.services.heattotosca.globaltypes.GlobalTypesGenerator; +import org.openecomp.sdc.translator.services.heattotosca.globaltypes.GlobalTypesUtil; +import org.openecomp.sdc.translator.services.heattotosca.mapping.TranslatorHeatToToscaPropertyConverter; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; + +public class ResourceTranslationNestedImpl extends ResourceTranslationBase { + + protected static Logger logger = LoggerFactory.getLogger(ResourceTranslationNestedImpl.class); + + @Override + public void translate(TranslateTo translateTo) { + FileData nestedFileData = + getFileData(translateTo.getResource().getType(), translateTo.getContext()); + String templateName = FileUtils.getFileWithoutExtention(translateTo.getResource().getType()); + String substitutionNodeTypeKey = ToscaConstants.NODES_SUBSTITUTION_PREFIX + templateName; + + if (!translateTo.getContext().getTranslatedServiceTemplates() + .containsKey(translateTo.getResource().getType())) { + + //substitution template + ServiceTemplate nestedSubstitutionServiceTemplate = new ServiceTemplate(); + Metadata templateMetadata = new Metadata(); + templateMetadata.setTemplate_name(templateName); + nestedSubstitutionServiceTemplate.setMetadata(templateMetadata); + nestedSubstitutionServiceTemplate + .setTosca_definitions_version(ToscaConstants.TOSCA_DEFINITIONS_VERSION); + nestedSubstitutionServiceTemplate.setTopology_template(new TopologyTemplate()); + nestedSubstitutionServiceTemplate.setImports(GlobalTypesGenerator.getGlobalTypesImportList()); + nestedSubstitutionServiceTemplate.getImports() + .put(Constants.GLOBAL_SUBSTITUTION_TYPES_TEMPLATE_NAME, GlobalTypesUtil + .createServiceTemplateImport(Constants.GLOBAL_SUBSTITUTION_TYPES_TEMPLATE_NAME)); + + TranslationService translationService = new TranslationService(); + + translationService.translateHeatFile(nestedSubstitutionServiceTemplate, nestedFileData, + translateTo.getContext()); + + //global substitution template + ServiceTemplate globalSubstitutionServiceTemplate; + globalSubstitutionServiceTemplate = translateTo.getContext().getTranslatedServiceTemplates() + .get(Constants.GLOBAL_SUBSTITUTION_TYPES_TEMPLATE_NAME); + if (globalSubstitutionServiceTemplate == null) { + globalSubstitutionServiceTemplate = new ServiceTemplate(); + templateMetadata = new Metadata(); + templateMetadata.setTemplate_name(Constants.GLOBAL_SUBSTITUTION_TYPES_TEMPLATE_NAME); + globalSubstitutionServiceTemplate.setMetadata(templateMetadata); + globalSubstitutionServiceTemplate + .setImports(GlobalTypesGenerator.getGlobalTypesImportList()); + globalSubstitutionServiceTemplate + .setTosca_definitions_version(ToscaConstants.TOSCA_DEFINITIONS_VERSION); + } + translateTo.getServiceTemplate().getImports() + .put(Constants.GLOBAL_SUBSTITUTION_TYPES_TEMPLATE_NAME, GlobalTypesUtil + .createServiceTemplateImport(Constants.GLOBAL_SUBSTITUTION_TYPES_TEMPLATE_NAME)); + + + //substitution node type + NodeType substitutionNodeType = new NodeType(); + substitutionNodeType.setDerived_from(ToscaNodeType.ABSTRACT_SUBSTITUTE.getDisplayName()); + substitutionNodeType.setDescription(nestedSubstitutionServiceTemplate.getDescription()); + substitutionNodeType + .setProperties(manageSubstitutionNodeTypeProperties(nestedSubstitutionServiceTemplate)); + substitutionNodeType + .setAttributes(manageSubstitutionNodeTypeAttributes(nestedSubstitutionServiceTemplate)); + DataModelUtil.addNodeType(globalSubstitutionServiceTemplate, substitutionNodeTypeKey, + substitutionNodeType); + Map>> substitutionMapping = + manageSubstitutionNodeTypeCapabilitiesAndRequirements(substitutionNodeType, + nestedSubstitutionServiceTemplate, translateTo); + //calculate substitution mapping after capability and requirement expose calculation + nestedSubstitutionServiceTemplate.getTopology_template().setSubstitution_mappings( + manageSubstitutionTemplateSubstitutionMapping(substitutionNodeTypeKey, + substitutionNodeType, substitutionMapping)); + + //add new service template + translateTo.getContext().getTranslatedServiceTemplates() + .put(Constants.GLOBAL_SUBSTITUTION_TYPES_TEMPLATE_NAME, + globalSubstitutionServiceTemplate); + translateTo.getContext().getTranslatedServiceTemplates() + .put(translateTo.getResource().getType(), nestedSubstitutionServiceTemplate); + } + + NodeTemplate substitutionNodeTemplate = new NodeTemplate(); + List directiveList = new ArrayList<>(); + directiveList.add(ToscaConstants.NODE_TEMPLATE_DIRECTIVE_SUBSTITUTABLE); + substitutionNodeTemplate.setDirectives(directiveList); + substitutionNodeTemplate.setType(substitutionNodeTypeKey); + substitutionNodeTemplate.setProperties( + managerSubstitutionNodeTemplateProperties(translateTo, substitutionNodeTemplate, + templateName)); + manageSubstitutionNodeTemplateConnectionPoint(translateTo, nestedFileData, + substitutionNodeTemplate); + DataModelUtil.addNodeTemplate(translateTo.getServiceTemplate(), translateTo.getTranslatedId(), + substitutionNodeTemplate); + } + + private void manageSubstitutionNodeTemplateConnectionPoint(TranslateTo translateTo, + FileData nestedFileData, + NodeTemplate substitutionNodeTemplate) { + ServiceTemplate globalSubstitutionTemplate = + translateTo.getContext().getTranslatedServiceTemplates() + .get(Constants.GLOBAL_SUBSTITUTION_TYPES_TEMPLATE_NAME); + NodeType nodeType = globalSubstitutionTemplate.getNode_types().get( + ToscaConstants.NODES_SUBSTITUTION_PREFIX + + FileUtils.getFileWithoutExtention(translateTo.getResource().getType())); + handlePortToNetConnections(translateTo, nestedFileData, substitutionNodeTemplate, nodeType); + handleSecurityRulesToPortConnections(translateTo, nestedFileData, substitutionNodeTemplate, + nodeType); + handleNovaToVolConnection(translateTo, nestedFileData, substitutionNodeTemplate, nodeType); + handleContrailV2VmInterfaceToNetworkConnection(translateTo, nestedFileData, + substitutionNodeTemplate, nodeType); + } + + private void handleContrailV2VmInterfaceToNetworkConnection(TranslateTo translateTo, + FileData nestedFileData, + NodeTemplate substitutionNodeTemplate, + NodeType nodeType) { + ContrailV2VmInterfaceToNetResourceConnection linker = + new ContrailV2VmInterfaceToNetResourceConnection(this, translateTo, nestedFileData, + substitutionNodeTemplate, nodeType); + linker.connect(); + } + + private void handleNovaToVolConnection(TranslateTo translateTo, FileData nestedFileData, + NodeTemplate substitutionNodeTemplate, NodeType nodeType) { + NovaToVolResourceConnection linker = + new NovaToVolResourceConnection(this, translateTo, nestedFileData, substitutionNodeTemplate, + nodeType); + linker.connect(); + } + + private void handleSecurityRulesToPortConnections(TranslateTo translateTo, + FileData nestedFileData, + NodeTemplate substitutionNodeTemplate, + NodeType nodeType) { + SecurityRulesToPortResourceConnection linker = + new SecurityRulesToPortResourceConnection(this, translateTo, nestedFileData, + substitutionNodeTemplate, nodeType); + linker.connect(); + } + + private void handlePortToNetConnections(TranslateTo translateTo, FileData nestedFileData, + NodeTemplate substitutionNodeTemplate, + NodeType nodeType) { + PortToNetResourceConnection linker = + new PortToNetResourceConnection(this, translateTo, nestedFileData, substitutionNodeTemplate, + nodeType); + linker.connect(); + } + + private List> getVolumeRequirements(NodeType nodeType) { + List> volumeRequirementsList = new ArrayList<>(); + List> requirementsList = nodeType.getRequirements(); + + for (int i = 0; requirementsList != null && i < requirementsList.size(); i++) { + RequirementDefinition req; + for (Map.Entry entry : requirementsList.get(i).entrySet()) { + req = entry.getValue(); + if (isVolumeRequirement(req, ToscaCapabilityType.ATTACHMENT.getDisplayName(), + ToscaNodeType.BLOCK_STORAGE.getDisplayName(), + ToscaRelationshipType.NATIVE_ATTACHES_TO.getDisplayName())) { + Map volumeRequirementsMap = new HashMap<>(); + volumeRequirementsMap.put(entry.getKey(), entry.getValue()); + volumeRequirementsList.add(volumeRequirementsMap); + } + + } + } + return volumeRequirementsList; + } + + private boolean isVolumeRequirement(RequirementDefinition req, String capability, String node, + String relationship) { + return req.getCapability().equals(capability) && req.getRelationship().equals(relationship) + && req.getNode().equals(node); + } + + private String getVolumeIdProperty(HeatOrchestrationTemplate heatOrchestrationTemplate, + String resourceId) { + + String novaResourceId; + String volumeId = null; + for (Resource resource : heatOrchestrationTemplate.getResources().values()) { + if (resource.getType() + .equals(HeatResourcesTypes.CINDER_VOLUME_ATTACHMENT_RESOURCE_TYPE.getHeatResource())) { + Optional optNovaResourceId = + getToscaPropertyValueSource(HeatConstants.INSTANCE_UUID_PROPERTY_NAME, resource, + "get_resource"); + if (optNovaResourceId.isPresent()) { + novaResourceId = optNovaResourceId.get(); + if (novaResourceId.equals(resourceId)) { + Optional optVolumeId = + getToscaPropertyValueSource(HeatConstants.VOLUME_ID_PROPERTY_NAME, resource, + "get_param"); + if (optVolumeId.isPresent()) { + volumeId = optVolumeId.get(); + } + } else { + logger.warn("property:" + HeatConstants.VOLUME_ID_PROPERTY_NAME + " of resource type:" + + resource.getType() + " should contain 'get_param' function"); + } + } + } + } + return volumeId; + } + + private String getTranslatedVolumeIdByVolumeIdProperty(String volumeId, TranslateTo translateTo) { + Optional volumeIdInfo = + HeatToToscaUtil.extractAttachedResourceId(translateTo, volumeId); + if (volumeIdInfo.isPresent()) { + if (volumeIdInfo.get().isGetResource()) { + return null;//(String) volumeIdInfo.get().getTranslatedId(); + } else if (volumeIdInfo.get().isGetParam()) { + List allFilesData = translateTo.getContext().getManifest().getContent().getData(); + Optional> fileDataList = HeatToToscaUtil + .buildListOfFilesToSearch(translateTo.getHeatFileName(), allFilesData, + FileData.Type.HEAT_VOL); + if (fileDataList.isPresent()) { + Optional resourceFileDataAndIDs = + getFileDataContainingResource(fileDataList.get(), + (String) volumeIdInfo.get().getEntityId(), translateTo.getContext(), + FileData.Type.HEAT_VOL); + if (resourceFileDataAndIDs.isPresent()) { + return resourceFileDataAndIDs.get().getTranslatedResourceId(); + } else { + logger.warn("The attached volume based on volume_id property: " + volumeId + " in " + + translateTo.getResourceId() + + " can't be found, searching for volume resource id - " + + volumeIdInfo.get().getEntityId()); + return null; + } + } else { + return null; + } + } else { + logger.warn("property:" + volumeId + " of resource :" + volumeIdInfo.get().getEntityId() + + " should contain 'get_param' or 'get_resource' function"); + return null; + } + } else { + logger.warn("property:" + volumeId + " of resource :" + translateTo.getResource().toString() + + " is not exist"); + return null; + } + } + + private Optional getToscaPropertyValueSource(String propertyName, Resource resource, + String key) { + Object propertyInstanceUuIdValue; + propertyInstanceUuIdValue = resource.getProperties().get(propertyName); + if (propertyInstanceUuIdValue instanceof Map) { + return Optional.ofNullable((String) ((Map) propertyInstanceUuIdValue).get(key)); + } else { + logger.warn("property:" + propertyName + " of resource type:" + resource.getType() + + " should have a value in key value format"); + + } + return Optional.empty(); + + } + + private Map>> + manageSubstitutionNodeTypeCapabilitiesAndRequirements( + NodeType substitutionNodeType, ServiceTemplate substitutionServiceTemplate, + TranslateTo translateTo) { + + Map nodeTemplates = + substitutionServiceTemplate.getTopology_template().getNode_templates(); + String templateName; + NodeTemplate template; + String type; + Map>> substitutionMapping = new HashMap<>(); + if (nodeTemplates == null) { + return substitutionMapping; + } + + Map> capabilitySubstitutionMapping = new HashMap<>(); + Map> requirementSubstitutionMapping = new HashMap<>(); + substitutionMapping.put("capability", capabilitySubstitutionMapping); + substitutionMapping.put("requirement", requirementSubstitutionMapping); + List> nodeTypeRequirementsDefinition; + Map nodeTemplateRequirementsAssignment; + List> exposedRequirementsDefinition; + Map> fullFilledRequirementsDefinition = + new HashMap<>(); + Map nodeTypeCapabilitiesDefinition = new HashMap<>(); + Map exposedCapabilitiesDefinition; + + for (Map.Entry entry : nodeTemplates.entrySet()) { + templateName = entry.getKey(); + template = entry.getValue(); + type = template.getType(); + + // get requirements + nodeTypeRequirementsDefinition = + getNodeTypeRequirements(type, templateName, substitutionServiceTemplate, + requirementSubstitutionMapping, translateTo.getContext()); + nodeTemplateRequirementsAssignment = getNodeTemplateRequirements(template); + fullFilledRequirementsDefinition.put(templateName, nodeTemplateRequirementsAssignment); + //set substitution node type requirements + exposedRequirementsDefinition = calculateExposedRequirements(nodeTypeRequirementsDefinition, + nodeTemplateRequirementsAssignment); + addSubstitutionNodeTypeRequirements(substitutionNodeType, exposedRequirementsDefinition, + templateName); + + //get capabilities + getNodeTypeCapabilities(nodeTypeCapabilitiesDefinition, capabilitySubstitutionMapping, type, + templateName, substitutionServiceTemplate, translateTo.getContext()); + + } + + exposedCapabilitiesDefinition = calculateExposedCapabilities(nodeTypeCapabilitiesDefinition, + fullFilledRequirementsDefinition); + addSubstitutionNodeTypeCapabilities(substitutionNodeType, exposedCapabilitiesDefinition); + return substitutionMapping; + } + + private Map calculateExposedCapabilities( + Map nodeTypeCapabilitiesDefinition, + Map> fullFilledRequirementsDefinitionMap) { + + String capabilityKey; + String capability; + String node; + CapabilityDefinition capabilityDefinition; + CapabilityDefinition clonedCapabilityDefinition; + for (Map.Entry> entry + : fullFilledRequirementsDefinitionMap.entrySet()) { + for (Map.Entry fullFilledEntry : entry.getValue().entrySet()) { + + capability = fullFilledEntry.getValue().getCapability(); + fullFilledEntry.getValue().getOccurrences(); + node = fullFilledEntry.getValue().getNode(); + capabilityKey = capability + "_" + node; + capabilityDefinition = nodeTypeCapabilitiesDefinition.get(capabilityKey); + if (capabilityDefinition != null) { + clonedCapabilityDefinition = capabilityDefinition.clone(); + nodeTypeCapabilitiesDefinition.put(capabilityKey, capabilityDefinition.clone()); + if (evaluateCapabilityFullFilament(clonedCapabilityDefinition)) { + nodeTypeCapabilitiesDefinition.remove(capabilityKey); + } else { + nodeTypeCapabilitiesDefinition.put(capabilityKey, clonedCapabilityDefinition); + } + } + } + } + + Map exposedCapabilitiesDefinition = new HashMap<>(); + for (Map.Entry entry : nodeTypeCapabilitiesDefinition + .entrySet()) { + exposedCapabilitiesDefinition.put(entry.getKey(), entry.getValue()); + } + return exposedCapabilitiesDefinition; + } + + private boolean evaluateCapabilityFullFilament(CapabilityDefinition capabilityDefinition) { + Object[] occurrences = capabilityDefinition.getOccurrences(); + if (occurrences == null) { + capabilityDefinition.setOccurrences(new Object[]{"0", ToscaConstants.UNBOUNDED}); + return false; + } + if (occurrences[1].equals(ToscaConstants.UNBOUNDED)) { + return false; + } + + if (occurrences[1].equals(1)) { + return true; + } + occurrences[1] = (Integer) occurrences[1] - 1; + return false; + } + + private boolean evaluateRequirementFullFilament(RequirementDefinition requirementDefinition) { + Object[] occurrences = requirementDefinition.getOccurrences(); + if (occurrences == null) { + requirementDefinition.setOccurrences(new Object[]{"0", ToscaConstants.UNBOUNDED}); + return false; + } + if (occurrences[1].equals(ToscaConstants.UNBOUNDED)) { + return false; + } + + if (occurrences[1].equals(1)) { + return true; + } + occurrences[1] = (Integer) occurrences[1] - 1; + return false; + } + + private void getNodeTypeCapabilities( + Map nodeTypeCapabilitiesDefinition, + Map> capabilitySubstitutionMapping, String type, String templateName, + ServiceTemplate serviceTemplate, TranslationContext context) { + NodeType nodeType = getNodeTypeWithFlatHierarchy(type, serviceTemplate, context); + String capabilityKey; + List capabilityMapping; + if (nodeType.getCapabilities() != null) { + for (Map.Entry capabilityNodeEntry : nodeType.getCapabilities() + .entrySet()) { + capabilityKey = capabilityNodeEntry.getKey() + "_" + templateName; + nodeTypeCapabilitiesDefinition.put(capabilityKey, capabilityNodeEntry.getValue().clone()); + capabilityMapping = new ArrayList<>(); + capabilityMapping.add(templateName); + capabilityMapping.add(capabilityNodeEntry.getKey()); + capabilitySubstitutionMapping.put(capabilityKey, capabilityMapping); + } + } + + String derivedFrom = nodeType.getDerived_from(); + if (derivedFrom != null) { + getNodeTypeCapabilities(nodeTypeCapabilitiesDefinition, capabilitySubstitutionMapping, + derivedFrom, templateName, serviceTemplate, context); + } + } + + private List> calculateExposedRequirements( + List> nodeTypeRequirementsDefinitionList, + Map nodeTemplateRequirementsAssignment) { + if (nodeTypeRequirementsDefinitionList == null) { + return null; + } + for (Map.Entry entry : nodeTemplateRequirementsAssignment + .entrySet()) { + if (entry.getValue().getNode() != null) { + RequirementDefinition requirementDefinition = + getRequirementDefinition(nodeTypeRequirementsDefinitionList, entry.getKey()); + RequirementDefinition cloneRequirementDefinition; + if (requirementDefinition != null) { + cloneRequirementDefinition = requirementDefinition.clone(); + if (!evaluateRequirementFullFilament(cloneRequirementDefinition)) { + this.mergeEntryInList(entry.getKey(), cloneRequirementDefinition, + nodeTypeRequirementsDefinitionList); + } else { + removeRequirementsDefinition(nodeTypeRequirementsDefinitionList, entry.getKey()); + } + } + } else { + for (Map nodeTypeRequirementsMap + : nodeTypeRequirementsDefinitionList) { + Object max = nodeTypeRequirementsMap.get(entry.getKey()).getOccurrences() != null + && nodeTypeRequirementsMap.get(entry.getKey()).getOccurrences().length > 0 + ? nodeTypeRequirementsMap.get(entry.getKey()).getOccurrences()[1] : 1; + Object min = nodeTypeRequirementsMap.get(entry.getKey()).getOccurrences() != null + && nodeTypeRequirementsMap.get(entry.getKey()).getOccurrences().length > 0 + ? nodeTypeRequirementsMap.get(entry.getKey()).getOccurrences()[0] : 1; + nodeTypeRequirementsMap.get(entry.getKey()).setOccurrences(new Object[]{min, max}); + } + } + } + return nodeTypeRequirementsDefinitionList; + } + + private void removeRequirementsDefinition( + List> nodeTypeRequirementsDefinitionList, + String requirementKey) { + for (Map reqMap : nodeTypeRequirementsDefinitionList) { + reqMap.remove(requirementKey); + } + } + + private RequirementDefinition getRequirementDefinition( + List> nodeTypeRequirementsDefinitionList, + String requirementKey) { + for (Map requirementMap : nodeTypeRequirementsDefinitionList) { + if (requirementMap.containsKey(requirementKey)) { + return requirementMap.get(requirementKey); + } + } + return null; + } + + private Map getNodeTemplateRequirements(NodeTemplate template) { + List> templateRequirements = template.getRequirements(); + + Map nodeTemplateRequirementsDefinition = new HashMap<>(); + if (CollectionUtils.isEmpty(templateRequirements)) { + return nodeTemplateRequirementsDefinition; + } + for (Map requirementAssignmentMap : templateRequirements) { + for (Map.Entry requirementEntry : requirementAssignmentMap + .entrySet()) { + nodeTemplateRequirementsDefinition + .put(requirementEntry.getKey(), requirementEntry.getValue()); + } + } + return nodeTemplateRequirementsDefinition; + } + + private List> getNodeTypeRequirements(String type, + String templateName, + ServiceTemplate serviceTemplate, + Map> requirementSubstitutionMapping, + TranslationContext context) { + List> requirementList = null; + NodeType nodeType = getNodeTypeWithFlatHierarchy(type, serviceTemplate, context); + String derivedFrom = nodeType.getDerived_from(); + List requirementMapping; + if (derivedFrom != null) { + requirementList = getNodeTypeRequirements(derivedFrom, templateName, serviceTemplate, + requirementSubstitutionMapping, context); + } + if (requirementList == null) { + requirementList = new ArrayList<>(); + } + + if (nodeType.getRequirements() != null) { + for (Map requirementMap : nodeType.getRequirements()) { + for (Map.Entry requirementNodeEntry : requirementMap + .entrySet()) { + if (requirementNodeEntry.getValue().getOccurrences() == null) { + requirementNodeEntry.getValue().setOccurrences(new Object[]{1, 1}); + } + Map requirementDef = new HashMap<>(); + requirementDef.put(requirementNodeEntry.getKey(), requirementNodeEntry.getValue()); + addRequirementToList(requirementList, requirementDef); + requirementMapping = new ArrayList<>(); + requirementMapping.add(templateName); + requirementMapping.add(requirementNodeEntry.getKey()); + requirementSubstitutionMapping + .put(requirementNodeEntry.getKey() + "_" + templateName, requirementMapping); + if (requirementNodeEntry.getValue().getNode() == null) { + requirementNodeEntry.getValue().setOccurrences(new Object[]{1, 1}); + } + } + } + } + + return requirementList; + } + + private void addRequirementToList(List> requirementList, + Map requirementDef) { + for (Map.Entry entry : requirementDef.entrySet()) { + this.mergeEntryInList(entry.getKey(), entry.getValue(), requirementList); + } + } + + private void addSubstitutionNodeTypeCapabilities(NodeType substitutionNodeType, + Map capabilities) { + if (capabilities == null || capabilities.entrySet().size() == 0) { + return; + } + + if (MapUtils.isEmpty(substitutionNodeType.getCapabilities())) { + substitutionNodeType.setCapabilities(new HashMap<>()); + } + if (capabilities.size() > 0) { + substitutionNodeType.setCapabilities(new HashMap<>()); + } + for (Map.Entry entry : capabilities.entrySet()) { + substitutionNodeType.getCapabilities().put(entry.getKey(), entry.getValue()); + } + } + + private void addSubstitutionNodeTypeRequirements(NodeType substitutionNodeType, + List> requirementsList, + String templateName) { + if (requirementsList == null || requirementsList.size() == 0) { + return; + } + + if (substitutionNodeType.getRequirements() == null) { + substitutionNodeType.setRequirements(new ArrayList<>()); + } + + for (Map requirementDef : requirementsList) { + for (Map.Entry entry : requirementDef.entrySet()) { + Map requirementMap = new HashMap<>(); + requirementMap.put(entry.getKey() + "_" + templateName, entry.getValue().clone()); + substitutionNodeType.getRequirements().add(requirementMap); + } + } + } + + + private SubstitutionMapping manageSubstitutionTemplateSubstitutionMapping(String nodeTypeKey, + NodeType substitutionNodeType, + Map>> mapping) { + SubstitutionMapping substitutionMapping = new SubstitutionMapping(); + substitutionMapping.setNode_type(nodeTypeKey); + substitutionMapping.setCapabilities( + manageCapabilityMapping(substitutionNodeType.getCapabilities(), mapping.get("capability"))); + substitutionMapping.setRequirements( + manageRequirementMapping(substitutionNodeType.getRequirements(), + mapping.get("requirement"))); + return substitutionMapping; + } + + private Map> manageCapabilityMapping( + Map capabilities, + Map> capabilitySubstitutionMapping) { + if (capabilities == null) { + return null; + } + + Map> capabilityMapping = new HashMap<>(); + String capabilityKey; + List capabilityMap; + for (Map.Entry entry : capabilities.entrySet()) { + capabilityKey = entry.getKey(); + capabilityMap = capabilitySubstitutionMapping.get(capabilityKey); + capabilityMapping.put(capabilityKey, capabilityMap); + } + return capabilityMapping; + } + + private Map> manageRequirementMapping( + List> requirementList, + Map> requirementSubstitutionMapping) { + if (requirementList == null) { + return null; + } + Map> requirementMapping = new HashMap<>(); + String requirementKey; + List requirementMap; + for (Map requirementDefMap : requirementList) { + for (Map.Entry entry : requirementDefMap.entrySet()) { + requirementKey = entry.getKey(); + requirementMap = requirementSubstitutionMapping.get(requirementKey); + requirementMapping.put(requirementKey, requirementMap); + } + } + return requirementMapping; + } + + + private Map manageSubstitutionNodeTypeAttributes( + ServiceTemplate substitutionServiceTemplate) { + + Map substitutionNodeTypeAttributes = new HashMap<>(); + Map attributes = + substitutionServiceTemplate.getTopology_template().getOutputs(); + if (attributes == null) { + return null; + } + AttributeDefinition attributeDefinition; + String toscaAttributeName; + + for (Map.Entry entry : attributes.entrySet()) { + attributeDefinition = new AttributeDefinition(); + toscaAttributeName = entry.getKey(); + ParameterDefinition parameterDefinition = + substitutionServiceTemplate.getTopology_template().getOutputs().get(toscaAttributeName); + if (parameterDefinition.getType() != null && !parameterDefinition.getType().isEmpty()) { + attributeDefinition.setType(parameterDefinition.getType()); + } else { + attributeDefinition.setType(PropertyType.STRING.getDisplayName()); + } + attributeDefinition.setDescription(parameterDefinition.getDescription()); + attributeDefinition.set_default(parameterDefinition.get_default()); + attributeDefinition.setEntry_schema(parameterDefinition.getEntry_schema()); + attributeDefinition.setStatus(parameterDefinition.getStatus()); + substitutionNodeTypeAttributes.put(toscaAttributeName, attributeDefinition); + } + return substitutionNodeTypeAttributes; + } + + private Map manageSubstitutionNodeTypeProperties( + ServiceTemplate substitutionServiceTemplate) { + Map substitutionNodeTypeProperties = new HashMap<>(); + Map properties = + substitutionServiceTemplate.getTopology_template().getInputs(); + if (properties == null) { + return null; + } + + PropertyDefinition propertyDefinition; + String toscaPropertyName; + for (Map.Entry entry : properties.entrySet()) { + toscaPropertyName = entry.getKey(); + propertyDefinition = new PropertyDefinition(); + ParameterDefinition parameterDefinition = + substitutionServiceTemplate.getTopology_template().getInputs().get(toscaPropertyName); + propertyDefinition.setType(parameterDefinition.getType()); + propertyDefinition.setDescription(parameterDefinition.getDescription()); + propertyDefinition.setRequired(parameterDefinition.getRequired()); + propertyDefinition.set_default(parameterDefinition.get_default()); + propertyDefinition.setConstraints(parameterDefinition.getConstraints()); + propertyDefinition.setEntry_schema(parameterDefinition.getEntry_schema()); + propertyDefinition.setStatus(parameterDefinition.getStatus()); + substitutionNodeTypeProperties.put(toscaPropertyName, propertyDefinition); + } + return substitutionNodeTypeProperties; + } + + private Map managerSubstitutionNodeTemplateProperties(TranslateTo translateTo, + Template template, + String templateName) { + Map substitutionProperties = new HashMap<>(); + Map heatProperties = translateTo.getResource().getProperties(); + if (Objects.nonNull(heatProperties)) { + for (Map.Entry entry : heatProperties.entrySet()) { + + Object property = TranslatorHeatToToscaPropertyConverter + .getToscaPropertyValue(entry.getKey(), entry.getValue(), null, + translateTo.getHeatFileName(), translateTo.getHeatOrchestrationTemplate(), template, + translateTo.getContext()); + substitutionProperties.put(entry.getKey(), property); + } + } + + return addAbstractSubstitutionProperty(templateName, substitutionProperties); + } + + private Map addAbstractSubstitutionProperty(String templateName, + Map substitutionProperties) { + Map innerProps = new HashMap<>(); + innerProps.put(ToscaConstants.SUBSTITUTE_SERVICE_TEMPLATE_PROPERTY_NAME, + ToscaUtil.getServiceTemplateFileName(templateName)); + substitutionProperties.put(ToscaConstants.SERVICE_TEMPLATE_FILTER_PROPERTY_NAME, innerProps); + return substitutionProperties; + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNeutronNetImpl.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNeutronNetImpl.java new file mode 100644 index 0000000000..0b4ed61753 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNeutronNetImpl.java @@ -0,0 +1,52 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.openecomp.sdc.tosca.datatypes.ToscaNodeType; +import org.openecomp.sdc.tosca.datatypes.model.NodeTemplate; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslateTo; +import org.openecomp.sdc.translator.services.heattotosca.HeatToToscaUtil; +import org.openecomp.sdc.translator.services.heattotosca.mapping.TranslatorHeatToToscaPropertyConverter; + +public class ResourceTranslationNeutronNetImpl extends ResourceTranslationBase { + + @Override + public void translate(TranslateTo translateTo) { + + NodeTemplate nodeTemplate = new NodeTemplate(); + nodeTemplate.setType(ToscaNodeType.NEUTRON_NET.getDisplayName()); + nodeTemplate.setProperties(TranslatorHeatToToscaPropertyConverter + .getToscaPropertiesSimpleConversion(translateTo.getResource().getProperties(), + nodeTemplate.getProperties(), translateTo.getHeatFileName(), + translateTo.getHeatOrchestrationTemplate(), translateTo.getResource().getType(), + nodeTemplate, translateTo.getContext())); + + HeatToToscaUtil.mapBoolean(nodeTemplate, "port_security_enabled"); + HeatToToscaUtil.mapBoolean(nodeTemplate, "shared"); + HeatToToscaUtil.mapBoolean(nodeTemplate, "admin_state_up"); + + DataModelUtil.addNodeTemplate(translateTo.getServiceTemplate(), translateTo.getTranslatedId(), + nodeTemplate); + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNeutronPortImpl.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNeutronPortImpl.java new file mode 100644 index 0000000000..343462d266 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNeutronPortImpl.java @@ -0,0 +1,233 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.openecomp.sdc.heat.datatypes.model.HeatResourcesTypes; +import org.openecomp.sdc.heat.datatypes.model.Resource; +import org.openecomp.sdc.tosca.datatypes.ToscaCapabilityType; +import org.openecomp.sdc.tosca.datatypes.ToscaNodeType; +import org.openecomp.sdc.tosca.datatypes.ToscaRelationshipType; +import org.openecomp.sdc.tosca.datatypes.model.NodeTemplate; +import org.openecomp.sdc.tosca.datatypes.model.RequirementAssignment; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.tosca.services.ToscaConstants; +import org.openecomp.sdc.translator.datatypes.heattotosca.AttachedResourceId; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslateTo; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslatedHeatResource; +import org.openecomp.sdc.translator.services.heattotosca.Constants; +import org.openecomp.sdc.translator.services.heattotosca.HeatToToscaUtil; +import org.openecomp.sdc.translator.services.heattotosca.ResourceTranslationFactory; +import org.openecomp.sdc.translator.services.heattotosca.mapping.TranslatorHeatToToscaPropertyConverter; + +import java.util.Arrays; +import java.util.Collections; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; + + +public class ResourceTranslationNeutronPortImpl extends ResourceTranslationBase { + + @Override + public void translate(TranslateTo translateTo) { + + NodeTemplate nodeTemplate = new NodeTemplate(); + nodeTemplate.setType(ToscaNodeType.NEUTRON_PORT.getDisplayName()); + + nodeTemplate.setProperties(TranslatorHeatToToscaPropertyConverter + .getToscaPropertiesSimpleConversion(translateTo.getResource().getProperties(), + nodeTemplate.getProperties(), translateTo.getHeatFileName(), + translateTo.getHeatOrchestrationTemplate(), translateTo.getResource().getType(), + nodeTemplate, translateTo.getContext())); + handleNetworkRequirement(translateTo, nodeTemplate); + String resourceTranslatedId = handleSecurityRulesRequirement(translateTo); + DataModelUtil + .addNodeTemplate(translateTo.getServiceTemplate(), resourceTranslatedId, nodeTemplate); + } + + private String handleSecurityRulesRequirement(TranslateTo translateTo) { + String resourceTranslatedId = translateTo.getTranslatedId(); + Map properties = translateTo.getResource().getProperties(); + Optional securityGroups = + Optional.ofNullable(properties.get(Constants.SECURITY_GROUPS_PROPERTY_NAME)); + if (securityGroups.isPresent() && securityGroups.get() instanceof List) { + List securityGroupsList = (List) securityGroups.get(); + securityGroupsList.forEach(resourceValue -> { + Optional securityGroupResourceId = HeatToToscaUtil + .extractAttachedResourceId(translateTo.getHeatFileName(), + translateTo.getHeatOrchestrationTemplate(), translateTo.getContext(), + resourceValue); + if (securityGroupResourceId.isPresent()) { + handleSecurityGroupResourceId(translateTo, resourceTranslatedId, + securityGroupResourceId.get()); + } + }); + } + return resourceTranslatedId; + } + + private void handleSecurityGroupResourceId(TranslateTo translateTo, String resourceTranslatedId, + AttachedResourceId securityGroupResourceId) { + List supportedSecurityGroupsTypes = Collections + .singletonList(HeatResourcesTypes.NEUTRON_SECURITY_GROUP_RESOURCE_TYPE.getHeatResource()); + if (securityGroupResourceId.isGetResource()) { + handleGetResource(translateTo, resourceTranslatedId, securityGroupResourceId, + supportedSecurityGroupsTypes); + } else if (securityGroupResourceId.isGetParam()) { + handleGetParam(translateTo, resourceTranslatedId, securityGroupResourceId, + supportedSecurityGroupsTypes); + } + } + + private void handleGetParam(TranslateTo translateTo, String resourceTranslatedId, + AttachedResourceId securityGroupResourceId, + List supportedSecurityGroupsTypes) { + TranslatedHeatResource translatedSharedResourceId = + translateTo.getContext().getHeatSharedResourcesByParam() + .get(securityGroupResourceId.getEntityId()); + if (Objects.nonNull(translatedSharedResourceId) + && !HeatToToscaUtil.isHeatFileNested(translateTo, translateTo.getHeatFileName())) { + if (validateResourceTypeSupportedForReqCreation(translateTo, supportedSecurityGroupsTypes, + translatedSharedResourceId.getHeatResource(), "security_groups")) { + return; + } + final NodeTemplate securityGroupNodeTemplate = DataModelUtil + .getNodeTemplate(translateTo.getServiceTemplate(), + translatedSharedResourceId.getTranslatedId()); + RequirementAssignment requirement = new RequirementAssignment(); + requirement.setCapability(ToscaCapabilityType.ATTACHMENT.getDisplayName()); + requirement.setNode(resourceTranslatedId); + requirement.setRelationship(ToscaRelationshipType.ATTACHES_TO.getDisplayName()); + DataModelUtil + .addRequirementAssignment(securityGroupNodeTemplate, ToscaConstants.PORT_REQUIREMENT_ID, + requirement); + } + } + + private void handleGetResource(TranslateTo translateTo, String resourceTranslatedId, + AttachedResourceId securityGroupResourceId, + List supportedSecurityGroupsTypes) { + String resourceId = (String) securityGroupResourceId.getEntityId(); + Resource securityGroupResource = HeatToToscaUtil + .getResource(translateTo.getHeatOrchestrationTemplate(), resourceId, + translateTo.getHeatFileName()); + Optional securityGroupTranslatedId = + ResourceTranslationFactory.getInstance(securityGroupResource) + .translateResource(translateTo.getHeatFileName(), translateTo.getServiceTemplate(), + translateTo.getHeatOrchestrationTemplate(), securityGroupResource, resourceId, + translateTo.getContext()); + if (securityGroupTranslatedId.isPresent()) { + if (validateResourceTypeSupportedForReqCreation(translateTo, supportedSecurityGroupsTypes, + securityGroupResource, "security_groups")) { + return; + } + final NodeTemplate securityGroupNodeTemplate = DataModelUtil + .getNodeTemplate(translateTo.getServiceTemplate(), securityGroupTranslatedId.get()); + RequirementAssignment requirement = new RequirementAssignment(); + requirement.setCapability(ToscaCapabilityType.ATTACHMENT.getDisplayName()); + requirement.setNode(resourceTranslatedId); + requirement.setRelationship(ToscaRelationshipType.ATTACHES_TO.getDisplayName()); + DataModelUtil + .addRequirementAssignment(securityGroupNodeTemplate, ToscaConstants.PORT_REQUIREMENT_ID, + requirement); + } + } + + private void handleNetworkRequirement(TranslateTo translateTo, NodeTemplate nodeTemplate) { + Optional networkResourceId = + HeatToToscaUtil.extractAttachedResourceId(translateTo, "network"); + if (networkResourceId.isPresent()) { + AttachedResourceId attachedResourceId = networkResourceId.get(); + addRequirementAssignmentForNetworkResource(translateTo, nodeTemplate, attachedResourceId); + } else { + networkResourceId = HeatToToscaUtil.extractAttachedResourceId(translateTo, "network_id"); + if (networkResourceId.isPresent()) { + AttachedResourceId attachedResourceId = networkResourceId.get(); + addRequirementAssignmentForNetworkResource(translateTo, nodeTemplate, attachedResourceId); + } + } + } + + private void addRequirementAssignmentForNetworkResource(TranslateTo translateTo, + NodeTemplate nodeTemplate, + AttachedResourceId attachedResourceId) { + String networkTranslatedId; + List supportedNetworkTypes = + Arrays.asList(HeatResourcesTypes.NEUTRON_NET_RESOURCE_TYPE.getHeatResource(), + HeatResourcesTypes.CONTRAIL_VIRTUAL_NETWORK_RESOURCE_TYPE.getHeatResource(), + HeatResourcesTypes.CONTRAIL_V2_VIRTUAL_NETWORK_RESOURCE_TYPE.getHeatResource()); + if (attachedResourceId.isGetResource()) { + Resource networkHeatResource = translateTo.getHeatOrchestrationTemplate().getResources() + .get(attachedResourceId.getEntityId()); + if (validateResourceTypeSupportedForReqCreation(translateTo, supportedNetworkTypes, + networkHeatResource, "network'\\'network_id")) { + return; + } + networkTranslatedId = (String) attachedResourceId.getTranslatedId(); + addRequirementAssignment(nodeTemplate, networkTranslatedId); + } else if (attachedResourceId.isGetParam()) { + TranslatedHeatResource translatedSharedResourceId = + translateTo.getContext().getHeatSharedResourcesByParam() + .get(attachedResourceId.getEntityId()); + if (Objects.nonNull(translatedSharedResourceId) + && !HeatToToscaUtil.isHeatFileNested(translateTo, translateTo.getHeatFileName())) { + if (validateResourceTypeSupportedForReqCreation(translateTo, supportedNetworkTypes, + translatedSharedResourceId.getHeatResource(), "network'\\'network_id")) { + return; + } + addRequirementAssignment(nodeTemplate, translatedSharedResourceId.getTranslatedId()); + } + } + } + + private void addRequirementAssignment(NodeTemplate nodeTemplate, String translatedId) { + RequirementAssignment requirement = new RequirementAssignment(); + requirement.setCapability(ToscaCapabilityType.NETWORK_LINKABLE.getDisplayName()); + requirement.setRelationship(ToscaRelationshipType.NETWORK_LINK_TO.getDisplayName()); + requirement.setNode(translatedId); + DataModelUtil + .addRequirementAssignment(nodeTemplate, ToscaConstants.LINK_REQUIREMENT_ID, requirement); + } + + + private boolean validateResourceTypeSupportedForReqCreation(TranslateTo translateTo, + List supportedTypes, + Resource heatResource, + final String propertyName) { + if (!isResourceTypeValidForRequirement(heatResource, supportedTypes)) { + logger.warn( + "'" + propertyName + "' property of port resource('" + translateTo.getResourceId() + + "') is pointing to a resource of type '" + heatResource.getType() + "' " + + "which is not supported for this requirement. " + + "Supported types are: " + supportedTypes.toString()); + return true; + } + return false; + } + + private boolean isResourceTypeValidForRequirement(Resource networkHeatResource, + List supportedNetworkTypes) { + return Objects.nonNull(networkHeatResource) + && supportedNetworkTypes.contains(networkHeatResource.getType()); + } + +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNeutronSecurityGroupImpl.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNeutronSecurityGroupImpl.java new file mode 100644 index 0000000000..cacaf4c5c7 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNeutronSecurityGroupImpl.java @@ -0,0 +1,47 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.openecomp.sdc.tosca.datatypes.ToscaNodeType; +import org.openecomp.sdc.tosca.datatypes.model.NodeTemplate; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslateTo; +import org.openecomp.sdc.translator.services.heattotosca.mapping.TranslatorHeatToToscaPropertyConverter; + +public class ResourceTranslationNeutronSecurityGroupImpl extends ResourceTranslationBase { + + @Override + public void translate(TranslateTo translateTo) { + + NodeTemplate nodeTemplate = new NodeTemplate(); + nodeTemplate.setType(ToscaNodeType.NEUTRON_SECURITY_RULES.getDisplayName()); + nodeTemplate.setProperties(TranslatorHeatToToscaPropertyConverter + .getToscaPropertiesSimpleConversion(translateTo.getResource().getProperties(), + nodeTemplate.getProperties(), translateTo.getHeatFileName(), + translateTo.getHeatOrchestrationTemplate(), translateTo.getResource().getType(), + nodeTemplate, translateTo.getContext())); + + DataModelUtil.addNodeTemplate(translateTo.getServiceTemplate(), translateTo.getTranslatedId(), + nodeTemplate); + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNeutronSubnetImpl.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNeutronSubnetImpl.java new file mode 100644 index 0000000000..8306f57146 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNeutronSubnetImpl.java @@ -0,0 +1,170 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.heat.datatypes.HeatBoolean; +import org.openecomp.sdc.heat.datatypes.model.Resource; +import org.openecomp.sdc.tosca.datatypes.ToscaFunctions; +import org.openecomp.sdc.tosca.datatypes.model.NodeTemplate; +import org.openecomp.sdc.tosca.datatypes.model.ParameterDefinition; +import org.openecomp.sdc.tosca.datatypes.model.PropertyType; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.tosca.services.ToscaConstants; +import org.openecomp.sdc.translator.datatypes.heattotosca.AttachedResourceId; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslateTo; + +import org.openecomp.sdc.translator.services.heattotosca.HeatToToscaUtil; +import org.openecomp.sdc.translator.services.heattotosca.ResourceTranslationFactory; +import org.openecomp.sdc.translator.services.heattotosca.errors.MissingMandatoryPropertyErrorBuilder; +import org.openecomp.sdc.translator.services.heattotosca.mapping.TranslatorHeatToToscaPropertyConverter; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import java.util.HashMap; +import java.util.Map; +import java.util.Optional; + +public class ResourceTranslationNeutronSubnetImpl extends ResourceTranslationBase { + protected static Logger logger = + LoggerFactory.getLogger(ResourceTranslationNeutronSubnetImpl.class); + + @Override + protected String generateTranslatedId(TranslateTo translateTo) { + Optional subnetNetwork = getAttachedNetworkResource(translateTo); + + if (!subnetNetwork.get().isGetResource()) { + logger.warn("Heat resource: '" + translateTo.getResourceId() + "' with type: '" + + translateTo.getResource().getType() + + "' include 'network_id/'network'' property without 'get_resource' function," + + " therefore this resource will be ignored in TOSCA translation."); + return null; + } + return (String) subnetNetwork.get().getTranslatedId(); + } + + @Override + public void translate(TranslateTo translateTo) { + + Optional subnetNetwork = getAttachedNetworkResource(translateTo); + + if (!subnetNetwork.get().isGetResource()) { + return; + } + + Resource networkResource = HeatToToscaUtil + .getResource(translateTo.getHeatOrchestrationTemplate(), + (String) subnetNetwork.get().getEntityId(), translateTo.getHeatFileName()); + Optional translatedNetworkId = ResourceTranslationFactory.getInstance(networkResource) + .translateResource(translateTo.getHeatFileName(), translateTo.getServiceTemplate(), + translateTo.getHeatOrchestrationTemplate(), networkResource, + (String) subnetNetwork.get().getEntityId(), translateTo.getContext()); + if (translatedNetworkId.isPresent()) { + NodeTemplate networkNodeTemplate = DataModelUtil + .getNodeTemplate(translateTo.getServiceTemplate(), translatedNetworkId.get()); + + Map> subNetMap = + (Map>) networkNodeTemplate.getProperties().get("subnets"); + if (subNetMap == null) { + subNetMap = new HashMap<>(); + networkNodeTemplate.getProperties().put("subnets", subNetMap); + TranslatorHeatToToscaPropertyConverter + .setSimpleProperty(translateTo.getResource().getProperties(), + translateTo.getHeatFileName(), translateTo.getResource().getType(), + translateTo.getHeatOrchestrationTemplate(), translateTo.getContext(), + networkNodeTemplate.getProperties(), "enable_dhcp", + ToscaConstants.DHCP_ENABLED_PROPERTY_NAME, networkNodeTemplate); //dhcp_enabled + TranslatorHeatToToscaPropertyConverter + .setSimpleProperty(translateTo.getResource().getProperties(), + translateTo.getHeatFileName(), translateTo.getResource().getType(), + translateTo.getHeatOrchestrationTemplate(), translateTo.getContext(), + networkNodeTemplate.getProperties(), "ip_version", null, networkNodeTemplate); + handleDhcpProperty(translateTo, networkNodeTemplate); + } + + Map properties; + properties = TranslatorHeatToToscaPropertyConverter + .getToscaPropertiesSimpleConversion(translateTo.getResource().getProperties(), null, + translateTo.getHeatFileName(), translateTo.getHeatOrchestrationTemplate(), + translateTo.getResource().getType(), networkNodeTemplate, translateTo.getContext()); + + subNetMap.put(translateTo.getResourceId(), properties); + } + } + + private void handleDhcpProperty(TranslateTo translateTo, NodeTemplate networkNodeTemplate) { + Object dhcpEnabled = + networkNodeTemplate.getProperties().get(ToscaConstants.DHCP_ENABLED_PROPERTY_NAME); + if (dhcpEnabled instanceof Map) { + Object dhcpEnabledParameterName = + ((Map) dhcpEnabled).get(ToscaFunctions.GET_INPUT.getDisplayName()); + if (dhcpEnabledParameterName != null) { + ParameterDefinition dhcpParameterDefinition = null; + if (translateTo.getServiceTemplate().getTopology_template().getInputs() != null) { + dhcpParameterDefinition = + translateTo.getServiceTemplate().getTopology_template().getInputs() + .get(dhcpEnabledParameterName); + } + if (dhcpParameterDefinition == null) { + logger.warn("Missing input parameter " + dhcpEnabledParameterName); + } else { + Object defaultVal = dhcpParameterDefinition.get_default(); + if (defaultVal != null) { + try { + Boolean booleanValue = HeatBoolean.eval(defaultVal); + dhcpParameterDefinition.set_default(booleanValue); + } catch (CoreException coreException) { + //if value is not valid value for boolean set with dhcp_enabled default value = true + dhcpParameterDefinition.set_default(true); + logger.warn("Parameter '" + dhcpEnabledParameterName + "' used for " + + ToscaConstants.DHCP_ENABLED_PROPERTY_NAME + + " boolean property, but it's value is not a valid boolean value, therefore " + + ToscaConstants.DHCP_ENABLED_PROPERTY_NAME + + " property will be set with default value of 'true'."); + } + dhcpParameterDefinition.setType(PropertyType.BOOLEAN.getDisplayName()); + } + } + } + } + } + + private Optional getAttachedNetworkResource(TranslateTo translateTo) { + Optional subnetNetwork = Optional.empty(); + Optional attachedNetworkId = + HeatToToscaUtil.extractAttachedResourceId(translateTo, "network_id"); + if (!attachedNetworkId.isPresent()) { + Optional attachedNetwork = + HeatToToscaUtil.extractAttachedResourceId(translateTo, "network"); + if (!attachedNetwork.isPresent()) { + throw new CoreException( + new MissingMandatoryPropertyErrorBuilder("network_id/'network'").build()); + } else { + subnetNetwork = attachedNetwork; + } + } else { + subnetNetwork = attachedNetworkId; + } + return subnetNetwork; + } +} + + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNovaServerGroupsImpl.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNovaServerGroupsImpl.java new file mode 100644 index 0000000000..7bc0a10957 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNovaServerGroupsImpl.java @@ -0,0 +1,119 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.apache.commons.collections4.CollectionUtils; +import org.openecomp.sdc.heat.datatypes.model.Resource; +import org.openecomp.sdc.tosca.datatypes.ToscaGroupType; +import org.openecomp.sdc.tosca.datatypes.ToscaPolicyType; +import org.openecomp.sdc.tosca.datatypes.model.GroupDefinition; +import org.openecomp.sdc.tosca.datatypes.model.PolicyDefinition; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslateTo; +import org.openecomp.sdc.translator.services.heattotosca.mapping.TranslatorHeatToToscaPropertyConverter; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; +import java.util.Map; +import java.util.Objects; + +public class ResourceTranslationNovaServerGroupsImpl extends ResourceTranslationBase { + private static final String AFFINITY = "affinity"; + private static final String ANTI_AFFINITY = "anti-affinity"; + private static List supportedPolicies = Arrays.asList(AFFINITY, ANTI_AFFINITY); + + @Override + protected void translate(TranslateTo translateTo) { + String resourceId = translateTo.getResourceId(); + List toscaPolicyTypes = getToscaPolicies(translateTo.getResource(), resourceId); + if (!CollectionUtils.isEmpty(toscaPolicyTypes)) { + addGroupToTopology(translateTo, resourceId); + addPoliciesToTopology(translateTo, resourceId, toscaPolicyTypes); + } + } + + private void addPoliciesToTopology(TranslateTo translateTo, String resourceId, + List toscaPolicyTypes) { + logger.info("******** Start creating policies for resource '%s' ********", resourceId); + for (int i = 0; i < toscaPolicyTypes.size(); i++) { + String policy = toscaPolicyTypes.get(i); + logger.info("******** Creating policy '%s' ********", policy); + PolicyDefinition policyDefinition = new PolicyDefinition(); + policyDefinition.setType(policy); + policyDefinition.setTargets(Arrays.asList(resourceId)); + policyDefinition.setProperties(TranslatorHeatToToscaPropertyConverter + .getToscaPropertiesSimpleConversion(translateTo.getResource().getProperties(), + policyDefinition.getProperties(), translateTo.getHeatFileName(), + translateTo.getHeatOrchestrationTemplate(), translateTo.getResource().getType(), + policyDefinition, translateTo.getContext())); + policyDefinition.getProperties().put( + policy.equals(ToscaPolicyType.PLACEMENT_ANTILOCATE.getDisplayName()) ? "container_type" + : AFFINITY, "host"); + String policyId = resourceId + (toscaPolicyTypes.size() > 1 ? i : ""); + DataModelUtil + .addPolicyDefinition(translateTo.getServiceTemplate(), policyId, policyDefinition); + logger.info("******** Policy '%s' created ********", policy); + } + + logger + .info("******** All policies for resource '%s' created successfully ********", resourceId); + } + + private void addGroupToTopology(TranslateTo translateTo, String resourceId) { + logger.info("******** Start creating group for resource '%s' ********", resourceId); + GroupDefinition group = new GroupDefinition(); + group.setMembers(new ArrayList<>()); + group.setType(ToscaGroupType.ROOT.getDisplayName()); + DataModelUtil + .addGroupDefinitionToTopologyTemplate(translateTo.getServiceTemplate(), resourceId, group); + logger.info("******** Creating group '%s' for resource '%s' ********", resourceId, resourceId); + } + + private List getToscaPolicies(Resource resource, String resourceId) { + + Map properties = resource.getProperties(); + if (Objects.isNull(properties) || Objects.isNull(properties.get("policies"))) { + return Arrays.asList(ToscaPolicyType.PLACEMENT_ANTILOCATE.getDisplayName()); + } + + List policies = (List) properties.get("policies"); + List retList = new ArrayList<>(); + policies.forEach(policy -> { + if (!supportedPolicies.contains(policy)) { + logger.warn("Resource '" + resourceId + "'(" + resource.getType() + + ") contains unsupported policy '" + policy.toString() + + "'. This resource is been ignored during the translation"); + } else { + retList.add(getToscaPolicyByHotPolicy((String) policy)); + } + }); + return retList; + } + + private String getToscaPolicyByHotPolicy(String name) { + if (Objects.equals(name, AFFINITY)) { + return ToscaPolicyType.PLACEMENT_COLOCATE.getDisplayName(); + } else { + return ToscaPolicyType.PLACEMENT_ANTILOCATE.getDisplayName(); + } + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNovaServerImpl.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNovaServerImpl.java new file mode 100644 index 0000000000..59e0691b2b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNovaServerImpl.java @@ -0,0 +1,419 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.apache.commons.collections4.CollectionUtils; +import org.apache.commons.collections4.MapUtils; +import org.openecomp.sdc.heat.datatypes.model.HeatOrchestrationTemplate; +import org.openecomp.sdc.heat.datatypes.model.HeatResourcesTypes; +import org.openecomp.sdc.heat.datatypes.model.Resource; +import org.openecomp.sdc.tosca.datatypes.ToscaCapabilityType; +import org.openecomp.sdc.tosca.datatypes.ToscaNodeType; +import org.openecomp.sdc.tosca.datatypes.ToscaRelationshipType; +import org.openecomp.sdc.tosca.datatypes.model.NodeTemplate; +import org.openecomp.sdc.tosca.datatypes.model.NodeType; +import org.openecomp.sdc.tosca.datatypes.model.RelationshipTemplate; +import org.openecomp.sdc.tosca.datatypes.model.RequirementAssignment; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.tosca.services.ToscaConstants; +import org.openecomp.sdc.translator.datatypes.heattotosca.AttachedResourceId; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslateTo; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslatedHeatResource; +import org.openecomp.sdc.translator.services.heattotosca.Constants; +import org.openecomp.sdc.translator.services.heattotosca.HeatToToscaUtil; +import org.openecomp.sdc.translator.services.heattotosca.ResourceTranslationFactory; +import org.openecomp.sdc.translator.services.heattotosca.TranslationContext; +import org.openecomp.sdc.translator.services.heattotosca.helper.NameExtractorService; +import org.openecomp.sdc.translator.services.heattotosca.helper.PropertyRegexMatcher; +import org.openecomp.sdc.translator.services.heattotosca.helper.impl.NameExtractorServiceImpl; +import org.openecomp.sdc.translator.services.heattotosca.mapping.TranslatorHeatToToscaPropertyConverter; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.Collections; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; + +public class ResourceTranslationNovaServerImpl extends ResourceTranslationBase { + protected static Logger logger = LoggerFactory.getLogger(ResourceTranslationNovaServerImpl.class); + + @Override + protected void translate(TranslateTo translateTo) { + TranslationContext context = translateTo.getContext(); + Map properties = translateTo.getResource().getProperties(); + String heatFileName = translateTo.getHeatFileName(); + + ServiceTemplate serviceTemplate = translateTo.getServiceTemplate(); + + String nodeTypeRef = + createLocalNodeType(serviceTemplate, translateTo.getResource().getProperties(), + translateTo.getTranslatedId()); + + NodeTemplate novaNodeTemplate = new NodeTemplate(); + novaNodeTemplate.setType(nodeTypeRef); + HeatOrchestrationTemplate heatOrchestrationTemplate = + translateTo.getHeatOrchestrationTemplate(); + novaNodeTemplate.setProperties(TranslatorHeatToToscaPropertyConverter + .getToscaPropertiesSimpleConversion(properties, novaNodeTemplate.getProperties(), + heatFileName, heatOrchestrationTemplate, translateTo.getResource().getType(), + novaNodeTemplate, context)); + + manageNovaServerNetwork(heatFileName, serviceTemplate, heatOrchestrationTemplate, + translateTo.getResource(), translateTo.getTranslatedId(), context, novaNodeTemplate); + manageNovaServerBlockDeviceMapping(heatFileName, serviceTemplate, novaNodeTemplate, + heatOrchestrationTemplate, translateTo.getResource(), translateTo.getResourceId(), + translateTo.getTranslatedId(), context); + + manageNovaServerGroupMapping(translateTo, context, properties, heatFileName, serviceTemplate, + heatOrchestrationTemplate); + DataModelUtil.addNodeTemplate(serviceTemplate, translateTo.getTranslatedId(), novaNodeTemplate); + } + + private void manageNovaServerGroupMapping(TranslateTo translateTo, TranslationContext context, + Map properties, String heatFileName, + ServiceTemplate serviceTemplate, + HeatOrchestrationTemplate heatOrchestrationTemplate) { + if (isSchedulerHintsPropExist(properties)) { + Object schedulerHints = properties.get("scheduler_hints"); + if (schedulerHints instanceof Map) { + addServerGroupHintsToPoliciesProups(translateTo, context, heatFileName, serviceTemplate, + heatOrchestrationTemplate, (Map) schedulerHints); + } else { + logger.warn("'scheduler_hints' property of resource '" + translateTo.getResourceId() + + "' is not valid. This property should be a map"); + } + } + } + + private void addServerGroupHintsToPoliciesProups(TranslateTo translateTo, + TranslationContext context, String heatFileName, + ServiceTemplate serviceTemplate, + HeatOrchestrationTemplate heatOrchestrationTemplate, + Map schedulerHints) { + for (Object hint : schedulerHints.values()) { + Optional attachedResourceId = HeatToToscaUtil + .extractAttachedResourceId(heatFileName, heatOrchestrationTemplate, context, hint); + if (attachedResourceId.isPresent()) { + AttachedResourceId serverGroupResourceId = attachedResourceId.get(); + Object serverGroupResourceToTranslate = serverGroupResourceId.getEntityId(); + if (serverGroupResourceId.isGetResource()) { + boolean isHintOfTypeNovaServerGroup = + isHintOfTypeNovaServerGroup(heatOrchestrationTemplate, + serverGroupResourceToTranslate); + if (isHintOfTypeNovaServerGroup) { + addNovaServerToPolicyGroup(translateTo, context, heatFileName, serviceTemplate, + heatOrchestrationTemplate, (String) serverGroupResourceToTranslate); + } + } else if (serverGroupResourceId.isGetParam()) { + TranslatedHeatResource translatedServerGroupResource = + context.getHeatSharedResourcesByParam().get(serverGroupResourceToTranslate); + if (Objects.nonNull(translatedServerGroupResource) + && !HeatToToscaUtil.isHeatFileNested(translateTo, translateTo.getHeatFileName())) { + serviceTemplate.getTopology_template().getGroups() + .get(translatedServerGroupResource.getTranslatedId()).getMembers() + .add(translateTo.getTranslatedId()); + } + } + } + } + } + + private boolean isHintOfTypeNovaServerGroup(HeatOrchestrationTemplate heatOrchestrationTemplate, + Object resourceToTranslate) { + return heatOrchestrationTemplate.getResources().get(resourceToTranslate).getType() + .equals(HeatResourcesTypes.NOVA_SERVER_GROUP_RESOURCE_TYPE.getHeatResource()); + } + + private void addNovaServerToPolicyGroup(TranslateTo translateTo, TranslationContext context, + String heatFileName, ServiceTemplate serviceTemplate, + HeatOrchestrationTemplate heatOrchestrationTemplate, + String resourceToTranslate) { + Resource serverGroup = + HeatToToscaUtil.getResource(heatOrchestrationTemplate, resourceToTranslate, heatFileName); + Optional serverGroupTranslatedId = ResourceTranslationFactory.getInstance(serverGroup) + .translateResource(heatFileName, serviceTemplate, heatOrchestrationTemplate, serverGroup, + resourceToTranslate, context); + if (serverGroupTranslatedId.isPresent()) { + serviceTemplate.getTopology_template().getGroups().get(serverGroupTranslatedId.get()) + .getMembers().add(translateTo.getTranslatedId()); + } + } + + private boolean isSchedulerHintsPropExist(Map properties) { + return !MapUtils.isEmpty(properties) && Objects.nonNull(properties.get("scheduler_hints")); + } + + private void manageNovaServerBlockDeviceMapping(String heatFileName, + ServiceTemplate serviceTemplate, + NodeTemplate novaNodeTemplate, + HeatOrchestrationTemplate heatOrchestrationTemplate, + Resource resource, String resourceId, + String novaServerTranslatedId, + TranslationContext context) { + + List> blockDeviceMappingList = getBlockDeviceMappingList(resource); + if (CollectionUtils.isEmpty(blockDeviceMappingList)) { + return; + } + + Object volumeIdObject; + Object snapshotIdObject; + String volumeResourceId; + int index = 0; + for (Map blockDeviceMapping : blockDeviceMappingList) { + volumeIdObject = blockDeviceMapping.get("volume_id"); + snapshotIdObject = blockDeviceMapping.get("snapshot_id"); + + if (volumeIdObject == null && snapshotIdObject == null) { + logger.warn("Resource '" + resourceId + + "' has block_device_mapping property with empty/missing volume_id and snapshot_id " + + "properties. Entry number " + + (index + 1) + ", this entry will be ignored in TOSCA translation."); + index++; + continue; + } + if (volumeIdObject == null) { + String deviceName = (String) blockDeviceMapping.get("device_name"); + String relationshipId = novaServerTranslatedId + "_" + index; + + Optional attachedSnapshotId = HeatToToscaUtil + .extractAttachedResourceId(heatFileName, heatOrchestrationTemplate, context, + snapshotIdObject); + volumeResourceId = novaServerTranslatedId + "_" + attachedSnapshotId.get().getEntityId(); + createVolumeAttachesToRelationship(serviceTemplate, deviceName, novaServerTranslatedId, + volumeResourceId, relationshipId); + createCinderVolumeNodeTemplate(serviceTemplate, volumeResourceId, heatFileName, + blockDeviceMapping, heatOrchestrationTemplate, context); + connectNovaServerToVolume(novaNodeTemplate, volumeResourceId, relationshipId); + } else { + Optional attachedVolumeId = HeatToToscaUtil + .extractAttachedResourceId(heatFileName, heatOrchestrationTemplate, context, + volumeIdObject); + if (attachedVolumeId.get().isGetResource()) { + connectNovaServerToVolume(novaNodeTemplate, + (String) attachedVolumeId.get().getTranslatedId(), null); + } + } + index++; + } + } + + private void connectNovaServerToVolume(NodeTemplate novaNodeTemplate, String volumeResourceId, + String relationshipId) { + RequirementAssignment requirementAssignment = new RequirementAssignment(); + requirementAssignment.setCapability(ToscaCapabilityType.ATTACHMENT.getDisplayName()); + requirementAssignment.setNode(volumeResourceId); + if (relationshipId != null) { + requirementAssignment.setRelationship(relationshipId); + } else { + requirementAssignment + .setRelationship(ToscaRelationshipType.NATIVE_ATTACHES_TO.getDisplayName()); + } + DataModelUtil + .addRequirementAssignment(novaNodeTemplate, ToscaConstants.LOCAL_STORAGE_REQUIREMENT_ID, + requirementAssignment); + } + + private void createCinderVolumeNodeTemplate(ServiceTemplate serviceTemplate, + String volumeResourceId, String heatFileName, + Map blockDeviceMapping, + HeatOrchestrationTemplate heatOrchestrationTemplate, + TranslationContext context) { + NodeTemplate cinderVolumeNodeTemplate = new NodeTemplate(); + cinderVolumeNodeTemplate.setType(ToscaNodeType.CINDER_VOLUME.getDisplayName()); + cinderVolumeNodeTemplate.setProperties(TranslatorHeatToToscaPropertyConverter + .getToscaPropertiesSimpleConversion(blockDeviceMapping, null, heatFileName, + heatOrchestrationTemplate, + HeatResourcesTypes.CINDER_VOLUME_RESOURCE_TYPE.getHeatResource(), + cinderVolumeNodeTemplate, context)); + DataModelUtil.addNodeTemplate(serviceTemplate, volumeResourceId, cinderVolumeNodeTemplate); + } + + private void createVolumeAttachesToRelationship(ServiceTemplate serviceTemplate, + String deviceName, String novaServerTranslatedId, + String volumeId, String relationshipId) { + RelationshipTemplate relationshipTemplate = new RelationshipTemplate(); + relationshipTemplate.setType(ToscaRelationshipType.CINDER_VOLUME_ATTACHES_TO.getDisplayName()); + Map properties = new HashMap<>(); + properties.put("instance_uuid", novaServerTranslatedId); + properties.put("volume_id", volumeId); + if (deviceName != null) { + properties.put("device", deviceName); + } + relationshipTemplate.setProperties(properties); + + DataModelUtil.addRelationshipTemplate(serviceTemplate, relationshipId, relationshipTemplate); + } + + private List> getBlockDeviceMappingList(Resource resource) { + + if (Objects.isNull(resource.getProperties())) { + return Collections.emptyList(); + } + List> blockDeviceMappingList = + (List>) resource.getProperties().get("block_device_mapping"); + List> blockDeviceMappingV2List = + (List>) resource.getProperties().get("block_device_mapping_v2"); + + if (blockDeviceMappingList != null && blockDeviceMappingV2List != null) { + blockDeviceMappingList.addAll(blockDeviceMappingV2List); + } else if (CollectionUtils.isEmpty(blockDeviceMappingList) + && CollectionUtils.isEmpty(blockDeviceMappingV2List)) { + return null; + + } else { + blockDeviceMappingList = + blockDeviceMappingList != null ? blockDeviceMappingList : blockDeviceMappingV2List; + } + return blockDeviceMappingList; + } + + private void manageNovaServerNetwork(String heatFileName, ServiceTemplate serviceTemplate, + HeatOrchestrationTemplate heatOrchestrationTemplate, + Resource resource, String translatedId, + TranslationContext context, NodeTemplate novaNodeTemplate) { + + if (resource.getProperties() == null) { + return; + } + List> heatNetworkList = + (List>) resource.getProperties().get("networks"); + + if (CollectionUtils.isEmpty(heatNetworkList)) { + return; + } + + for (Map heatNetwork : heatNetworkList) { + getOrTranslatePortTemplate(heatFileName, heatOrchestrationTemplate, + heatNetwork.get(Constants.PORT_PROPERTY_NAME), serviceTemplate, translatedId, context, + novaNodeTemplate); + } + + } + + private void getOrTranslatePortTemplate(String heatFileName, + HeatOrchestrationTemplate heatOrchestrationTemplate, + Object port, ServiceTemplate serviceTemplate, + String novaServerResourceId, TranslationContext context, + NodeTemplate novaNodeTemplate) { + Optional attachedPortId = HeatToToscaUtil + .extractAttachedResourceId(heatFileName, heatOrchestrationTemplate, context, port); + + if (!attachedPortId.isPresent()) { + return; + } + + if (attachedPortId.get().isGetResource()) { + String resourceId = (String) attachedPortId.get().getEntityId(); + Resource portResource = + HeatToToscaUtil.getResource(heatOrchestrationTemplate, resourceId, heatFileName); + if (!Arrays.asList(HeatResourcesTypes.NEUTRON_PORT_RESOURCE_TYPE.getHeatResource(), + HeatResourcesTypes.CONTRAIL_V2_VIRTUAL_MACHINE_INTERFACE_RESOURCE_TYPE.getHeatResource()) + .contains(portResource.getType())) { + logger.warn("NovaServer connect to port resource with id : " + resourceId + " and type : " + + portResource.getType() + + ". This resource type is not supported, therefore the connection to the port is " + + "ignored. " + + "Supported types are: " + + HeatResourcesTypes.NEUTRON_PORT_RESOURCE_TYPE.getHeatResource() + ", " + + HeatResourcesTypes.CONTRAIL_V2_VIRTUAL_MACHINE_INTERFACE_RESOURCE_TYPE + .getHeatResource()); + return; + } else if (HeatResourcesTypes.CONTRAIL_V2_VIRTUAL_MACHINE_INTERFACE_RESOURCE_TYPE + .getHeatResource().equals(portResource.getType())) { + Map properties = portResource.getProperties(); + if (!MapUtils.isEmpty(properties) && Objects.nonNull(properties.get("port_tuple_refs"))) { + novaNodeTemplate.getProperties().put("contrail_service_instance_ind", true); + } + } + Optional translatedPortId = ResourceTranslationFactory.getInstance(portResource) + .translateResource(heatFileName, serviceTemplate, heatOrchestrationTemplate, portResource, + resourceId, context); + if (translatedPortId.isPresent()) { + NodeTemplate portNodeTemplate = + DataModelUtil.getNodeTemplate(serviceTemplate, translatedPortId.get()); + addBindingReqFromPortToCompute(novaServerResourceId, portNodeTemplate); + } else { + logger.warn("NovaServer connect to port resource with id : " + resourceId + " and type : " + + portResource.getType() + + ". This resource type is not supported, therefore the connection to the port is " + + "ignored."); + } + } + } + + /** + * Create local node type string. + * + * @param serviceTemplate the service template + * @param properties the properties + * @param resourceTranslatedId the resource translated id + * @return the string + */ + public String createLocalNodeType(ServiceTemplate serviceTemplate, Map properties, + String resourceTranslatedId) { + NameExtractorService nodeTypeNameExtractor = new NameExtractorServiceImpl(); + List propertyRegexMatchers = + getPropertiesAndRegexMatchers(nodeTypeNameExtractor); + Optional extractedNodeTypeName = nodeTypeNameExtractor + .extractNodeTypeNameByPropertiesPriority(properties, propertyRegexMatchers); + + String nodeTypeName = ToscaConstants.NODES_PREFIX + + (extractedNodeTypeName.isPresent() ? extractedNodeTypeName.get() + : resourceTranslatedId.replace(".", "_")); + if (!isNodeTypeCreated(serviceTemplate, nodeTypeName)) { + DataModelUtil.addNodeType(serviceTemplate, nodeTypeName, createNodeType()); + } + return nodeTypeName; + } + + private List getPropertiesAndRegexMatchers( + NameExtractorService nodeTypeNameExtractor) { + List propertyRegexMatchers = new ArrayList<>(); + propertyRegexMatchers.add(nodeTypeNameExtractor + .getPropertyRegexMatcher(Constants.NAME_PROPERTY_NAME, + Arrays.asList(".+_name$", ".+_names$", ".+_name_[0-9]+"), "_name")); + propertyRegexMatchers.add(nodeTypeNameExtractor + .getPropertyRegexMatcher("image", Collections.singletonList(".+_image_name$"), + "_image_name")); + propertyRegexMatchers.add(nodeTypeNameExtractor + .getPropertyRegexMatcher("flavor", Collections.singletonList(".+_flavor_name$"), + "_flavor_name")); + return propertyRegexMatchers; + } + + private boolean isNodeTypeCreated(ServiceTemplate serviceTemplate, String nodeTypeName) { + return !MapUtils.isEmpty(serviceTemplate.getNode_types()) + && Objects.nonNull(serviceTemplate.getNode_types().get(nodeTypeName)); + } + + private NodeType createNodeType() { + NodeType nodeType = new NodeType(); + nodeType.setDerived_from(ToscaNodeType.NOVA_SERVER.getDisplayName()); + return nodeType; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationResourceGroupImpl.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationResourceGroupImpl.java new file mode 100644 index 0000000000..4665249351 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationResourceGroupImpl.java @@ -0,0 +1,202 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.heat.datatypes.model.HeatResourcesTypes; +import org.openecomp.sdc.heat.datatypes.model.Resource; +import org.openecomp.sdc.heat.services.HeatConstants; +import org.openecomp.sdc.tosca.datatypes.ToscaFunctions; +import org.openecomp.sdc.tosca.datatypes.model.NodeTemplate; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.tosca.services.ToscaConstants; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslateTo; +import org.openecomp.sdc.translator.services.heattotosca.HeatToToscaUtil; +import org.openecomp.sdc.translator.services.heattotosca.ResourceTranslationFactory; +import org.openecomp.sdc.translator.services.heattotosca.errors.InvalidPropertyValueErrorBuilder; +import org.openecomp.sdc.translator.services.heattotosca.mapping.TranslatorHeatToToscaPropertyConverter; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.Optional; + +public class ResourceTranslationResourceGroupImpl extends ResourceTranslationBase { + + @Override + protected void translate(TranslateTo translateTo) { + final String heatFileName = translateTo.getHeatFileName(); + Object resourceDef = + translateTo.getResource().getProperties().get(HeatConstants.RESOURCE_DEF_PROPERTY_NAME); + Resource nestedResource = new Resource(); + Object typeDefinition = ((Map) resourceDef).get("type"); + if (!(typeDefinition instanceof String)) { + logger.warn("Resource '" + translateTo.getResourceId() + "' of type'" + + HeatResourcesTypes.RESOURCE_GROUP_RESOURCE_TYPE.getHeatResource() + + "' with resourceDef which is not pointing to nested heat file " + + "is not supported and will be ignored in the translation "); + return; + } + String type = (String) typeDefinition; + if (!HeatToToscaUtil.isYmlFileType(type)) { + logger.warn("Resource '" + translateTo.getResourceId() + "' of type'" + + HeatResourcesTypes.RESOURCE_GROUP_RESOURCE_TYPE.getHeatResource() + + "' with resourceDef which is not pointing to nested heat " + + "file is not supported and will be ignored in the translation "); + return; + } + + nestedResource.setType(type); + nestedResource.setProperties((Map) ((Map) resourceDef).get("properties")); + nestedResource.setMetadata(((Map) resourceDef).get("metadata")); + + Optional substitutionNodeTemplateId = + ResourceTranslationFactory.getInstance(nestedResource) + .translateResource(heatFileName, translateTo.getServiceTemplate(), + translateTo.getHeatOrchestrationTemplate(), nestedResource, + translateTo.getResourceId(), translateTo.getContext()); + if (substitutionNodeTemplateId.isPresent()) { + NodeTemplate substitutionNodeTemplate = DataModelUtil + .getNodeTemplate(translateTo.getServiceTemplate(), substitutionNodeTemplateId.get()); + Map serviceTemplateFilter = (Map) substitutionNodeTemplate.getProperties() + .get(ToscaConstants.SERVICE_TEMPLATE_FILTER_PROPERTY_NAME); + + populateServiceTemplateFilterProperties(translateTo, substitutionNodeTemplate, + serviceTemplateFilter); + handlingIndexVar(translateTo, substitutionNodeTemplate); + DataModelUtil + .addNodeTemplate(translateTo.getServiceTemplate(), substitutionNodeTemplateId.get(), + substitutionNodeTemplate); + } + + } + + private void handlingIndexVar(TranslateTo translateTo, NodeTemplate substitutionNodeTemplate) { + String indexVarValue = getIndexVarValue(translateTo); + replacePropertiesIndexVarValue(indexVarValue, substitutionNodeTemplate.getProperties()); + } + + private Map getNewIndexVarValue() { + final Map newIndexVarValue = new HashMap<>(); + List indexVarValList = new ArrayList<>(); + indexVarValList.add(ToscaConstants.MODELABLE_ENTITY_NAME_SELF); + indexVarValList.add(ToscaConstants.SERVICE_TEMPLATE_FILTER_PROPERTY_NAME); + indexVarValList.add(ToscaConstants.INDEX_VALUE_PROPERTY_NAME); + newIndexVarValue.put(ToscaFunctions.GET_PROPERTY.getDisplayName(), indexVarValList); + return newIndexVarValue; + } + + private void replacePropertiesIndexVarValue(String indexVarValue, + Map properties) { + if (properties == null || properties.isEmpty()) { + return; + } + + for (Map.Entry propertyEntry : properties.entrySet()) { + Object propertyValue = propertyEntry.getValue(); + Object newPropertyValue = getUpdatedPropertyValueWithIndex(indexVarValue, propertyValue); + if (newPropertyValue != null) { + properties.put(propertyEntry.getKey(), newPropertyValue); + } + } + } + + private Object getUpdatedPropertyValueWithIndex(String indexVarValue, Object propertyValue) { + if (propertyValue instanceof String && propertyValue != null) { + if (propertyValue.equals(indexVarValue)) { + return getNewIndexVarValue(); + } + if (((String) propertyValue).contains(indexVarValue)) { + Map> concatMap = new HashMap<>(); + List concatList = new ArrayList<>(); + String value = (String) propertyValue; + + while (value.contains(indexVarValue)) { + if (value.indexOf(indexVarValue) == 0) { + concatList.add(getNewIndexVarValue()); + value = value.substring(indexVarValue.length()); + } else { + int end = value.indexOf(indexVarValue); + concatList.add(value.substring(0, end)); + value = value.substring(end); + } + } + if (!value.isEmpty()) { + concatList.add(value); + } + + concatMap.put(ToscaFunctions.CONCAT.getDisplayName(), concatList); + return concatMap; + } + return propertyValue; //no update is needed + } else if (propertyValue instanceof Map && !((Map) propertyValue).isEmpty()) { + replacePropertiesIndexVarValue(indexVarValue, (Map) propertyValue); + return propertyValue; + } else if (propertyValue instanceof List && !((List) propertyValue).isEmpty()) { + List newPropertyValueList = new ArrayList<>(); + for (Object entry : ((List) propertyValue)) { + newPropertyValueList.add(getUpdatedPropertyValueWithIndex(indexVarValue, entry)); + } + return newPropertyValueList; + } + return propertyValue; + } + + private String getIndexVarValue(TranslateTo translateTo) { + Object indexVar = + translateTo.getResource().getProperties().get(HeatConstants.INDEX_PROPERTY_NAME); + if (indexVar == null) { + return HeatConstants.RESOURCE_GROUP_INDEX_VAR_DEFAULT_VALUE; + } + + if (indexVar instanceof String) { + return (String) indexVar; + } else { + throw new CoreException( + new InvalidPropertyValueErrorBuilder("index_var", indexVar.toString(), "String").build()); + } + } + + private void populateServiceTemplateFilterProperties(TranslateTo translateTo, + NodeTemplate substitutionNodeTemplate, + Map serviceTemplateFilter) { + boolean mandatory = false; + Object countValue = TranslatorHeatToToscaPropertyConverter + .getToscaPropertyValue(ToscaConstants.COUNT_PROPERTY_NAME, + translateTo.getResource().getProperties().get(ToscaConstants.COUNT_PROPERTY_NAME), null, + translateTo.getHeatFileName(), translateTo.getHeatOrchestrationTemplate(), + substitutionNodeTemplate, translateTo.getContext()); + + if (countValue != null) { + serviceTemplateFilter.put(ToscaConstants.COUNT_PROPERTY_NAME, countValue); + } else { + serviceTemplateFilter.put(ToscaConstants.COUNT_PROPERTY_NAME, 1); + } + if (countValue instanceof Integer && (Integer) countValue > 0) { + mandatory = true; + } + if (countValue == null) { + mandatory = true; + } + serviceTemplateFilter.put("mandatory", mandatory); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/SecurityRulesToPortResourceConnection.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/SecurityRulesToPortResourceConnection.java new file mode 100644 index 0000000000..3c6fef7ffb --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/impl/SecurityRulesToPortResourceConnection.java @@ -0,0 +1,203 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.impl; + + +import org.openecomp.sdc.heat.datatypes.manifest.FileData; +import org.openecomp.sdc.heat.datatypes.model.HeatOrchestrationTemplate; +import org.openecomp.sdc.heat.datatypes.model.HeatResourcesTypes; +import org.openecomp.sdc.heat.datatypes.model.Resource; +import org.openecomp.sdc.tosca.datatypes.ToscaCapabilityType; +import org.openecomp.sdc.tosca.datatypes.ToscaNodeType; +import org.openecomp.sdc.tosca.datatypes.ToscaRelationshipType; +import org.openecomp.sdc.tosca.datatypes.model.CapabilityDefinition; +import org.openecomp.sdc.tosca.datatypes.model.NodeTemplate; +import org.openecomp.sdc.tosca.datatypes.model.NodeType; +import org.openecomp.sdc.tosca.datatypes.model.RequirementDefinition; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.tosca.services.ToscaConstants; +import org.openecomp.sdc.translator.datatypes.heattotosca.AttachedResourceId; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslateTo; +import org.openecomp.sdc.translator.datatypes.heattotosca.to.TranslatedHeatResource; +import org.openecomp.sdc.translator.services.heattotosca.Constants; +import org.openecomp.sdc.translator.services.heattotosca.HeatToToscaUtil; +import org.openecomp.sdc.translator.services.heattotosca.ResourceTranslationFactory; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; +import java.util.function.Predicate; + + +class SecurityRulesToPortResourceConnection extends BaseResourceConnection { + SecurityRulesToPortResourceConnection(ResourceTranslationNestedImpl resourceTranslationNested, + TranslateTo translateTo, FileData nestedFileData, + NodeTemplate substitutionNodeTemplate, NodeType nodeType) { + super(resourceTranslationNested, translateTo, nestedFileData, substitutionNodeTemplate, + nodeType); + } + + @Override + protected boolean isDesiredNodeTemplateType(NodeTemplate nodeTemplate) { + return nodeTemplate.getType().equals(ToscaNodeType.NEUTRON_PORT.getDisplayName()); + } + + @Override + protected List> getPredicatesListForConnectionPoints() { + ArrayList> predicates = new ArrayList<>(); + predicates.add(cap -> cap.getType().equals(ToscaCapabilityType.ATTACHMENT.getDisplayName())); + return predicates; + } + + @Override + protected Optional> getConnectorParamName( + String heatResourceId,Resource heatResource, + HeatOrchestrationTemplate nestedHeatOrchestrationTemplate) { + Object securityGroups = + heatResource.getProperties().get(Constants.SECURITY_GROUPS_PROPERTY_NAME); + List paramsList = new ArrayList<>(); + if (securityGroups instanceof List) { + ((List) securityGroups).forEach(group -> { + Optional attachedResourceId = HeatToToscaUtil + .extractAttachedResourceId(nestedFileData.getFile(), nestedHeatOrchestrationTemplate, + translateTo.getContext(), group); + if (attachedResourceId.isPresent()) { + paramsList.add((String) attachedResourceId.get().getEntityId()); + } + }); + return Optional.of(paramsList); + } + return Optional.empty(); + } + + @Override + protected String getDesiredResourceType() { + return HeatResourcesTypes.NEUTRON_PORT_RESOURCE_TYPE.getHeatResource(); + } + + @Override + protected List> getAllConnectionPoints() { + List> exposedRequirementsList = new ArrayList<>(); + List> predicates = getPredicatesListForConnectionPoints(); + Map capabilities = this.nodeType.getCapabilities(); + if (capabilities == null) { + return exposedRequirementsList; + } + capabilities.entrySet() + .stream() + .filter(entry -> predicates + .stream() + .anyMatch(p -> p.test(entry.getValue()))) + .forEach(entry -> { + Map exposedRequirementsMap = new HashMap<>(); + exposedRequirementsMap.put(entry.getKey(), entry.getValue()); + exposedRequirementsList.add(exposedRequirementsMap); + }); + + return exposedRequirementsList; + } + + @Override + void addRequirementToConnectResources(Map.Entry entry, + List paramNames) { + paramNames.forEach(p -> { + Optional attachedResourceId = + HeatToToscaUtil.extractAttachedResourceId(translateTo, p); + String securityRulesNodeId; + if (!attachedResourceId.isPresent()) { + return; + } + Map.Entry requirementDefinition = + createRequirementDefinition(entry.getKey()); + AttachedResourceId securityGroupAttachedId = attachedResourceId.get(); + if (securityGroupAttachedId.isGetResource()) { + String securityGroupResourceId = (String) attachedResourceId.get().getEntityId(); + Resource securityGroupResource = HeatToToscaUtil + .getResource(translateTo.getHeatOrchestrationTemplate(), securityGroupResourceId, + translateTo.getHeatFileName()); + Optional translatedSecurityRuleId = + ResourceTranslationFactory.getInstance(securityGroupResource) + .translateResource(translateTo.getHeatFileName(), translateTo.getServiceTemplate(), + translateTo.getHeatOrchestrationTemplate(), securityGroupResource, + securityGroupResourceId, translateTo.getContext()); + if (translatedSecurityRuleId.isPresent()) { + NodeTemplate securityRuleNodeTemplate = DataModelUtil + .getNodeTemplate(translateTo.getServiceTemplate(), translatedSecurityRuleId.get()); + createRequirementAssignment(requirementDefinition, translateTo.getTranslatedId(), + securityRuleNodeTemplate); + } else { + logger.warn( + securityGroupResource.getType() + "connection to " + securityGroupResource.getType() + + " is not supported/invalid, therefore this connection " + + "will be ignored in the TOSCA translation"); + } + } else if (securityGroupAttachedId.isGetParam()) { + TranslatedHeatResource shareResource = + translateTo.getContext().getHeatSharedResourcesByParam() + .get(securityGroupAttachedId.getEntityId()); + if (Objects.nonNull(shareResource) + && !HeatToToscaUtil.isHeatFileNested(translateTo, translateTo.getHeatFileName())) { + NodeTemplate sharedNodeTemplate = DataModelUtil + .getNodeTemplate(translateTo.getServiceTemplate(), shareResource.getTranslatedId()); + createRequirementAssignment(requirementDefinition, translateTo.getTranslatedId(), + sharedNodeTemplate); + } + } + }); + } + + @Override + protected String getTranslatedResourceIdFromSubstitutionMapping( + ServiceTemplate nestedServiceTemplate, Map.Entry entry) { + List substitutionMapping = + nestedServiceTemplate.getTopology_template().getSubstitution_mappings().getCapabilities() + .get(entry.getKey()); + return substitutionMapping.get(0); + } + + private Map.Entry createRequirementDefinition(String key) { + RequirementDefinition definition = new RequirementDefinition(); + definition.setCapability(key); + definition.setRelationship(ToscaRelationshipType.ATTACHES_TO.getDisplayName()); + return new Map.Entry() { + @Override + public String getKey() { + return ToscaConstants.PORT_REQUIREMENT_ID; + } + + @Override + public RequirementDefinition getValue() { + return definition; + } + + @Override + public RequirementDefinition setValue(RequirementDefinition value) { + return null; + } + }; + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/mapping/TranslatorHeatToToscaFunctionConverter.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/mapping/TranslatorHeatToToscaFunctionConverter.java new file mode 100644 index 0000000000..0aa5c5ff96 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/mapping/TranslatorHeatToToscaFunctionConverter.java @@ -0,0 +1,410 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.mapping; + +import org.openecomp.core.utilities.yaml.YamlUtil; +import org.openecomp.sdc.heat.datatypes.HeatBoolean; +import org.openecomp.sdc.heat.datatypes.model.HeatOrchestrationTemplate; +import org.openecomp.sdc.heat.datatypes.model.Resource; +import org.openecomp.sdc.heat.services.HeatConstants; +import org.openecomp.sdc.tosca.datatypes.ToscaArtifactType; +import org.openecomp.sdc.tosca.datatypes.ToscaFunctions; +import org.openecomp.sdc.tosca.datatypes.model.ArtifactDefinition; +import org.openecomp.sdc.tosca.datatypes.model.NodeTemplate; +import org.openecomp.sdc.tosca.datatypes.model.Template; +import org.openecomp.sdc.tosca.services.ToscaConstants; +import org.openecomp.sdc.tosca.services.ToscaFileOutputService; +import org.openecomp.sdc.tosca.services.impl.ToscaFileOutputServiceCsarImpl; +import org.openecomp.sdc.translator.services.heattotosca.Constants; +import org.openecomp.sdc.translator.services.heattotosca.HeatToToscaUtil; +import org.openecomp.sdc.translator.services.heattotosca.TranslationContext; +import org.openecomp.sdc.translator.services.heattotosca.impl.ResourceTranslationBase; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Optional; +import java.util.Set; +import java.util.stream.Collectors; + + +public class TranslatorHeatToToscaFunctionConverter { + private static final String UNSUPPORTED_RESOURCE = "UNSUPPORTED_RESOURCE_"; + private static final String UNSUPPORTED_ATTRIBUTE = "UNSUPPORTED_ATTRIBUTE_"; + + protected static Set functionNameSet; + + static { + functionNameSet = new HashSet<>(); + functionNameSet.add("get_param"); + functionNameSet.add("get_attr"); + functionNameSet.add("get_resource"); + functionNameSet.add("get_file"); + } + + /** + * Gets tosca function. + * + * @param functionName the function name + * @param function the function + * @param heatFileName the heat file name + * @param heatOrchestrationTemplate the heat orchestration template + * @param template the template + * @param context the context + * @return the tosca function + */ + public static Object getToscaFunction(String functionName, Object function, String heatFileName, + HeatOrchestrationTemplate heatOrchestrationTemplate, + Template template, TranslationContext context) { + Object returnValue = null; + if ("get_param".equals(functionName)) { + returnValue = + handleGetParamFunction(function, heatFileName, heatOrchestrationTemplate, context); + } else if ("get_attr".equals(functionName)) { + returnValue = + handleGetAttrFunction(function, heatFileName, heatOrchestrationTemplate, context); + } else if ("get_resource".equals(functionName)) { + returnValue = + handleGetResourceFunction(function, heatFileName, heatOrchestrationTemplate, context); + } else if ("get_file".equals(functionName)) { + returnValue = handleGetFileFunction(function, template); + } + return returnValue; + } + + private static Object handleGetFileFunction(Object function, Template template) { + String file = ((String) function).replace("file:///", ""); + Object returnValue; + final String artifactId = file.split("\\.")[0]; + + returnValue = new HashMap<>(); + List artifactParameters = new ArrayList(); + artifactParameters.add(0, ToscaConstants.MODELABLE_ENTITY_NAME_SELF); + ((Map) returnValue).put(ToscaFunctions.GET_ARTIFACT.getDisplayName(), artifactParameters); + artifactParameters.add(1, artifactId); + + ToscaFileOutputService toscaFileOutputService = new ToscaFileOutputServiceCsarImpl(); + if (template != null) { + if (template instanceof NodeTemplate) { + NodeTemplate nodeTemplate = (NodeTemplate) template; + ArtifactDefinition artifactDefinition = + createArtifactDefinition(file, toscaFileOutputService); + if (nodeTemplate.getArtifacts() == null) { + nodeTemplate.setArtifacts(new HashMap<>()); + } + nodeTemplate.getArtifacts().put(artifactId, artifactDefinition); + } + } + return returnValue; + } + + private static Object handleGetResourceFunction(Object function, String heatFileName, + HeatOrchestrationTemplate + heatOrchestrationTemplate, + TranslationContext context) { + Object returnValue; + Optional resourceTranslatedId = ResourceTranslationBase + .getResourceTranslatedId(heatFileName, heatOrchestrationTemplate, (String) function, + context); + if (resourceTranslatedId.isPresent()) { + returnValue = resourceTranslatedId.get(); + } else { + returnValue = UNSUPPORTED_RESOURCE + function; + } + return returnValue; + } + + private static Object handleGetAttrFunction(Object function, String heatFileName, + HeatOrchestrationTemplate heatOrchestrationTemplate, + TranslationContext context) { + Object returnValue = new HashMap<>(); + List attributeFunctionExpression = + translateGetAttributeFunctionExpression(function, heatFileName, heatOrchestrationTemplate, + context); + if (isResourceSupported(attributeFunctionExpression.get(0).toString()) + && isAttributeSupported(attributeFunctionExpression.get(0).toString())) { + ((Map) returnValue) + .put(ToscaFunctions.GET_ATTRIBUTE.getDisplayName(), attributeFunctionExpression); + } else { + returnValue = attributeFunctionExpression; + } + return returnValue; + } + + private static Object handleGetParamFunction(Object function, String heatFileName, + HeatOrchestrationTemplate heatOrchestrationTemplate, + TranslationContext context) { + Map returnValue = new HashMap<>(); + returnValue.put(ToscaFunctions.GET_INPUT.getDisplayName(), + translateGetParamFunctionExpression(function, heatFileName, heatOrchestrationTemplate, + context)); + return returnValue; + } + + private static ArtifactDefinition createArtifactDefinition(Object function, + ToscaFileOutputService + toscaFileOutputService) { + ArtifactDefinition artifactDefinition = new ArtifactDefinition(); + artifactDefinition.setType(ToscaArtifactType.DEPLOYMENT.getDisplayName()); + artifactDefinition + .setFile("../" + toscaFileOutputService.getArtifactsFolderName() + "/" + function); + return artifactDefinition; + } + + private static Object translateGetParamFunctionExpression(Object function, String heatFileName, + HeatOrchestrationTemplate + heatOrchestrationTemplate, + TranslationContext context) { + Object returnValue = null; + if (function instanceof String) { + returnValue = function; + } else { + if (function instanceof List) { + returnValue = new ArrayList<>(); + for (int i = 0; i < ((List) function).size(); i++) { + Object paramValue = ((List) function).get(i); + if ((paramValue instanceof Map && !((Map) paramValue).isEmpty())) { + Map paramMap = (Map) paramValue; + Map.Entry entry = paramMap.entrySet().iterator().next(); + ((List) returnValue).add( + getToscaFunction(entry.getKey(), entry.getValue(), heatFileName, + heatOrchestrationTemplate, null, context)); + } else { + ((List) returnValue).add(paramValue); + } + } + } + } + + return returnValue; + } + + private static List translateGetAttributeFunctionExpression( + Object function,String heatFileName, + HeatOrchestrationTemplate heatOrchestrationTemplate, + TranslationContext context) { + List attributeParamList = (List) function; + List toscaAttributeParamList = new ArrayList<>(); + + Optional resourceTranslatedId = + handleResourceName(attributeParamList.get(0), heatFileName, heatOrchestrationTemplate, + context); + if (!resourceTranslatedId.isPresent()) { + //unsupported resource + toscaAttributeParamList.add(UNSUPPORTED_RESOURCE + attributeParamList.get(0)); + return toscaAttributeParamList; + } else { + toscaAttributeParamList.add(resourceTranslatedId.get()); + } + + Optional> toscaAttList = + handleAttributeName(attributeParamList, heatOrchestrationTemplate, heatFileName, context); + if (!toscaAttList.isPresent()) { + //Unsupported attribute + toscaAttributeParamList.clear(); + toscaAttributeParamList + .add(UNSUPPORTED_ATTRIBUTE + attributeParamList.get(0) + "." + attributeParamList.get(1)); + return toscaAttributeParamList; + } else { + toscaAttributeParamList.addAll(toscaAttList.get()); + } + + Optional> toscaIndexOrKey = handleAttributeIndexOrKey(attributeParamList); + if (toscaIndexOrKey.isPresent()) { + toscaAttributeParamList.addAll(toscaIndexOrKey.get()); + } + + return toscaAttributeParamList; + } + + private static Optional> handleAttributeIndexOrKey(List attributeParamList) { + List attributeIndexOrKey = new ArrayList<>(); + if (attributeParamList.size() < 2) { + return Optional.empty(); + } + + for (int i = 2; i < attributeParamList.size(); i++) { + attributeIndexOrKey.add(attributeParamList.get(i)); + } + + return Optional.of(attributeIndexOrKey); + } + + private static Optional> handleAttributeName(List attributeParamList, + HeatOrchestrationTemplate + heatOrchestrationTemplate, + String heatFileName, + TranslationContext context) { + String resourceId = attributeParamList.get(0); + Resource resource = + HeatToToscaUtil.getResource(heatOrchestrationTemplate, resourceId, heatFileName); + + if (attributeParamList.size() == 1) { + return getResourceTranslatedAttributesList(resource, context); + } + + if (HeatToToscaUtil.isNestedResource(resource)) { + return getNestedResourceTranslatedAttribute(attributeParamList.get(1)); + } else { + return getResourceTranslatedAttribute(resource, attributeParamList.get(1), context); + } + } + + private static Optional> getResourceTranslatedAttribute(Resource resource, + String attributeName, + TranslationContext context) { + List translatedAttributesList = new ArrayList<>(); + String translatedAttribute = + context.getElementMapping(resource.getType(), Constants.ATTR, attributeName); + if (translatedAttribute != null) { + translatedAttributesList.add(translatedAttribute); + return Optional.of(translatedAttributesList); + } else { //unsupported attribute + return Optional.empty(); + } + } + + private static Optional> getNestedResourceTranslatedAttribute(String attributeName) { + List translatedAttributesList = new ArrayList<>(); + + if (attributeName.startsWith(HeatConstants.GET_ATT_FROM_RESOURCE_GROUP_PREFIX)) { + String[] attributeSplit = attributeName.split("\\."); + if (attributeSplit.length == 2) { + translatedAttributesList.add(attributeSplit[1]); + } else if (attributeSplit.length == 3) { + translatedAttributesList.add(attributeSplit[2]); + translatedAttributesList.add(Integer.valueOf(attributeSplit[1])); + } else { + return Optional.empty(); + } + } else { + translatedAttributesList.add(attributeName); + } + return Optional.of(translatedAttributesList); + } + + private static Optional> getResourceTranslatedAttributesList(Resource resource, + TranslationContext + context) { + List translatedAttributes = new ArrayList<>(); + if (HeatToToscaUtil.isNestedResource(resource)) { + Optional nestedFile = HeatToToscaUtil.getNestedFile(resource); + if (!nestedFile.isPresent()) { + return Optional.empty(); + } + HeatOrchestrationTemplate nestedHeatOrchestrationTemplate = new YamlUtil() + .yamlToObject(context.getFiles().getFileContent(nestedFile.get()), + HeatOrchestrationTemplate.class); + translatedAttributes.addAll(nestedHeatOrchestrationTemplate.getOutputs().keySet()); + return Optional.of(translatedAttributes); + + } else { + Map resourceMappingAttributes = + context.getElementMapping(resource.getType(), Constants.ATTR); + Set mappingAttributes = new HashSet<>(); + mappingAttributes + .addAll(resourceMappingAttributes.values().stream().collect(Collectors.toList())); + translatedAttributes.addAll(mappingAttributes); + return Optional.of(translatedAttributes); + } + } + + private static Optional handleResourceName(String resourceId, String heatFileName, + HeatOrchestrationTemplate + heatOrchestrationTemplate, + TranslationContext context) { + return ResourceTranslationBase + .getResourceTranslatedId(heatFileName, heatOrchestrationTemplate, resourceId, context); + } + + public static boolean isResourceSupported(String translatedResourceId) { + return !translatedResourceId.startsWith(UNSUPPORTED_RESOURCE); + } + + public static boolean isAttributeSupported(String translatedAttName) { + return !translatedAttName.startsWith(UNSUPPORTED_ATTRIBUTE); + } + + /** + * Translate fn split function optional. + * + * @param propertyValue the property value + * @param listSize the list size + * @param includeBooleanValue the include boolean value + * @return the optional + */ + public static Optional>> translateFnSplitFunction( + Object propertyValue,int listSize, + boolean includeBooleanValue) { + List> tokenPropertyValueList = new ArrayList<>(); + + if (propertyValue instanceof Map && !((Map) propertyValue).isEmpty()) { + Map propMap = (Map) propertyValue; + Map.Entry entry = propMap.entrySet().iterator().next(); + Object entity = entry.getValue(); + String key = entry.getKey(); + String tokenChar; + + if (key.equals("Fn::Split") && entity instanceof List) { + tokenChar = (String) ((List) entity).get(0); + Object refParameter = ((List) entity).get(1); + + for (int substringIndex = 0; substringIndex < listSize; substringIndex++) { + Map tokenPropertyValue = new HashMap<>(); + tokenPropertyValue.put("token", new ArrayList<>()); + + if (refParameter instanceof Map && ((Map) refParameter).get("Ref") != null) { + Map stringWithToken = new HashMap<>(); + ((Map) stringWithToken) + .put(ToscaFunctions.GET_INPUT.getDisplayName(), ((Map) refParameter).get("Ref")); + tokenPropertyValue.get("token").add(stringWithToken); + } else if (refParameter instanceof String) { + if (includeBooleanValue) { + StringBuffer booleanBuffer = new StringBuffer(); + String[] booleanValueList = ((String) refParameter).split(tokenChar); + for (int i = 0; i < booleanValueList.length; i++) { + if (i == 0) { + booleanBuffer.append(HeatBoolean.eval(booleanValueList[i])); + } else { + booleanBuffer.append(tokenChar); + booleanBuffer.append(HeatBoolean.eval(booleanValueList[i])); + } + } + tokenPropertyValue.get("token").add(booleanBuffer.toString()); + } else { + tokenPropertyValue.get("token").add(refParameter); + } + } + tokenPropertyValue.get("token").add(tokenChar); + tokenPropertyValue.get("token").add(substringIndex); + tokenPropertyValueList.add(tokenPropertyValue); + } + + return Optional.of(tokenPropertyValueList); + + } + } + + return Optional.empty(); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/mapping/TranslatorHeatToToscaParameterConverter.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/mapping/TranslatorHeatToToscaParameterConverter.java new file mode 100644 index 0000000000..07ab6d1542 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/mapping/TranslatorHeatToToscaParameterConverter.java @@ -0,0 +1,271 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.mapping; + +import org.openecomp.sdc.heat.datatypes.model.HeatOrchestrationTemplate; +import org.openecomp.sdc.heat.datatypes.model.Output; +import org.openecomp.sdc.heat.datatypes.model.Parameter; +import org.openecomp.sdc.tosca.datatypes.model.Constraint; +import org.openecomp.sdc.tosca.datatypes.model.EntrySchema; +import org.openecomp.sdc.tosca.datatypes.model.ParameterDefinition; +import org.openecomp.sdc.tosca.datatypes.model.heatextend.ParameterDefinitionExt; +import org.openecomp.sdc.translator.services.heattotosca.TranslationContext; + + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +public class TranslatorHeatToToscaParameterConverter { + + + private static Map parameterTypeMapping; + private static Map parameterEntrySchemaTypeMapping; + + static { + parameterEntrySchemaTypeMapping = new HashMap<>(); + parameterEntrySchemaTypeMapping.put("list", "string"); + } + + static { + parameterTypeMapping = new HashMap<>(); + parameterTypeMapping.put("string", "string"); + parameterTypeMapping.put("number", "float"); + parameterTypeMapping.put("comma_delimited_list", "list"); + parameterTypeMapping.put("json", "json"); + parameterTypeMapping.put("boolean", "boolean"); + } + + /** + * Parameter converter map. + * + * @param parameters the parameters + * @param heatOrchestrationTemplate the heat orchestration template + * @param heatFileName the heat file name + * @param context the context + * @return the map + */ + public static Map parameterConverter( + Map parameters, HeatOrchestrationTemplate heatOrchestrationTemplate, + String heatFileName, TranslationContext context) { + Map parameterDefinitionMap = new HashMap<>(); + for (Map.Entry entry : parameters.entrySet()) { + //parameterDefinitionMap.put(entry.getKey()+"_"+ FileUtils + // .getFileWithoutExtention(heatFileName),getToscaParameter(entry.getValue(), + // heatOrchestrationTemplate, heatFileName, context)); + parameterDefinitionMap.put(entry.getKey(), + getToscaParameter(entry.getValue(), heatOrchestrationTemplate, heatFileName, context)); + } + return parameterDefinitionMap; + } + + /** + * Parameter output converter map. + * + * @param parameters the parameters + * @param heatOrchestrationTemplate the heat orchestration template + * @param heatFileName the heat file name + * @param context the context + * @return the map + */ + public static Map parameterOutputConverter( + Map parameters, HeatOrchestrationTemplate heatOrchestrationTemplate, + String heatFileName, TranslationContext context) { + Map parameterDefinitionMap = new HashMap<>(); + for (Map.Entry entry : parameters.entrySet()) { + //parameterDefinitionMap.put(entry.getKey()+"_"+FileUtils + // .getFileWithoutExtention(heatFileName),getToscaOutputParameter(entry.getValue(), + // heatOrchestrationTemplate, heatFileName, context)); + parameterDefinitionMap.put(entry.getKey(), + getToscaOutputParameter(entry.getValue(), heatOrchestrationTemplate, heatFileName, + context)); + } + return parameterDefinitionMap; + } + + /** + * Gets tosca parameter. + * + * @param heatParameter the heat parameter + * @param heatOrchestrationTemplate the heat orchestration template + * @param heatFileName the heat file name + * @param context the context + * @return the tosca parameter + */ + public static ParameterDefinitionExt getToscaParameter(Parameter heatParameter, + HeatOrchestrationTemplate + heatOrchestrationTemplate, + String heatFileName, + TranslationContext context) { + + ParameterDefinitionExt toscaParameter = new ParameterDefinitionExt(); + toscaParameter.setType(getToscaParameterType(heatParameter.getType())); + toscaParameter.setEntry_schema(getToscaParameterEntrySchema(toscaParameter.getType())); + toscaParameter.setLabel(heatParameter.getLabel()); + toscaParameter.setDescription(heatParameter.getDescription()); + toscaParameter.set_default( + getToscaParameterDefaultValue(heatParameter.get_default(), toscaParameter.getType(), + heatFileName, heatOrchestrationTemplate, context)); + toscaParameter.setHidden(heatParameter.isHidden()); + toscaParameter.setImmutable(heatParameter.isImmutable()); + toscaParameter.setConstraints(getToscaConstrains(heatParameter.getConstraints())); + return toscaParameter; + } + + /** + * Gets tosca output parameter. + * + * @param heatOutputParameter the heat output parameter + * @param heatOrchestrationTemplate the heat orchestration template + * @param heatFileName the heat file name + * @param context the context + * @return the tosca output parameter + */ + public static ParameterDefinitionExt getToscaOutputParameter(Output heatOutputParameter, + HeatOrchestrationTemplate + heatOrchestrationTemplate, + String heatFileName, + TranslationContext context) { + + ParameterDefinitionExt toscaParameter = new ParameterDefinitionExt(); + toscaParameter.setDescription(heatOutputParameter.getDescription()); + toscaParameter.setValue( + getToscaParameterDefaultValue(heatOutputParameter.getValue(), toscaParameter.getType(), + heatFileName, heatOrchestrationTemplate, context)); + return toscaParameter; + } + + /** + * Gets tosca parameter default value. + * + * @param defaultObj the a default + * @param type the type + * @param heatFileName the heat file name + * @param heatOrchestrationTemplate the heat orchestration template + * @param context the context + * @return the tosca parameter default value + */ + public static Object getToscaParameterDefaultValue(Object defaultObj, String type, + String heatFileName, + HeatOrchestrationTemplate + heatOrchestrationTemplate, + TranslationContext context) { + + if (defaultObj == null) { + return null; + } + if ("list".equals(type)) { + if (defaultObj instanceof String) { + return Arrays.asList(((String) defaultObj).split(",")); + } else { + return defaultObj; + } + } + + return getToscaParameterValue(defaultObj, heatFileName, heatOrchestrationTemplate, + context); + } + + private static Object getToscaParameterValue(Object paramValue, String heatFileName, + HeatOrchestrationTemplate heatOrchestrationTemplate, + TranslationContext context) { + if (paramValue instanceof Map) { + Map.Entry functionMapEntry = + (Map.Entry) ((Map) paramValue).entrySet().iterator().next(); + if (TranslatorHeatToToscaFunctionConverter.functionNameSet + .contains(functionMapEntry.getKey())) { + return TranslatorHeatToToscaFunctionConverter + .getToscaFunction(functionMapEntry.getKey(), functionMapEntry.getValue(), heatFileName, + heatOrchestrationTemplate, null, context); + } + } + + return paramValue; + } + + private static List getToscaConstrains(List> constraints) { + if (constraints == null) { + return null; + } + + List constraintList = new ArrayList<>(); + + for (Map constraint : constraints) { + constraintList.addAll(getToscaParameterConstraint(constraint)); + } + + return constraintList; + } + + private static List getToscaParameterConstraint(Map constraint) { + List convertedConstraintList = new ArrayList<>(); + Constraint convertedConstraint; + + if (constraint.containsKey("range")) { + convertedConstraint = new Constraint(); + convertedConstraintList.add(convertedConstraint); + Integer min = (Integer) ((Map) constraint.get("range")).get("min"); + Integer max = (Integer) ((Map) constraint.get("range")).get("max"); + convertedConstraint.setIn_range(new Integer[]{min, max}); + + } else if (constraint.containsKey("length")) { + Integer min = (Integer) ((Map) constraint.get("length")).get("min"); + Integer max = (Integer) ((Map) constraint.get("length")).get("max"); + if (max != null) { + convertedConstraint = new Constraint(); + convertedConstraintList.add(convertedConstraint); + convertedConstraint.setMax_length(max); + } + if (min != null) { + convertedConstraint = new Constraint(); + convertedConstraintList.add(convertedConstraint); + convertedConstraint.setMin_length(min); + } + } else if (constraint.containsKey("allowed_values")) { + convertedConstraint = new Constraint(); + convertedConstraintList.add(convertedConstraint); + convertedConstraint.setValid_values((List) constraint.get("allowed_values")); + } else if (constraint.containsKey("allowed_pattern")) { + convertedConstraint = new Constraint(); + convertedConstraintList.add(convertedConstraint); + convertedConstraint.setPattern(constraint.get("allowed_pattern")); + } + + return convertedConstraintList; + } + + private static EntrySchema getToscaParameterEntrySchema(String type) { + + if (!parameterEntrySchemaTypeMapping.containsKey(type)) { + return null; + } + + EntrySchema entrySchema = new EntrySchema(); + entrySchema.setType(parameterEntrySchemaTypeMapping.get(type)); + return entrySchema; + } + + protected static String getToscaParameterType(String heatParameterType) { + return parameterTypeMapping.get(heatParameterType); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/mapping/TranslatorHeatToToscaPropertyConverter.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/mapping/TranslatorHeatToToscaPropertyConverter.java new file mode 100644 index 0000000000..d1079c2dc5 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/java/org/openecomp/sdc/translator/services/heattotosca/mapping/TranslatorHeatToToscaPropertyConverter.java @@ -0,0 +1,146 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.translator.services.heattotosca.mapping; + +import org.openecomp.sdc.heat.datatypes.model.HeatOrchestrationTemplate; +import org.openecomp.sdc.tosca.datatypes.model.Template; +import org.openecomp.sdc.translator.services.heattotosca.Constants; +import org.openecomp.sdc.translator.services.heattotosca.TranslationContext; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +public class TranslatorHeatToToscaPropertyConverter { + + /** + * Gets tosca properties simple conversion. + * + * @param heatProperties the heat properties + * @param toscaProperties the tosca properties + * @param heatFileName the heat file name + * @param heatOrchestrationTemplate the heat orchestration template + * @param resourceType the resource type + * @param template the template + * @param context the context + * @return the tosca properties simple conversion + */ + //Convert property assuming the property type in heat is same as the property type in tosca + public static Map getToscaPropertiesSimpleConversion( + Map heatProperties, Map toscaProperties, String heatFileName, + HeatOrchestrationTemplate heatOrchestrationTemplate, String resourceType, Template template, + TranslationContext context) { + + toscaProperties = toscaProperties != null ? toscaProperties : new HashMap<>(); + + for (String heatPropertyName : context.getElementSet(resourceType, Constants.PROP)) { + + setSimpleProperty(heatProperties, heatFileName, resourceType, heatOrchestrationTemplate, + context, toscaProperties, heatPropertyName, null, template); + } + return toscaProperties; + } + + /** + * Sets simple property. + * + * @param heatProperties the heat properties + * @param heatFileName the heat file name + * @param resourceType the resource type + * @param heatOrchestrationTemplate the heat orchestration template + * @param context the context + * @param toscaProperties the tosca properties + * @param heatPropertyName the heat property name + * @param toscaPropertyName the tosca property name + * @param template the template + */ + public static void setSimpleProperty(Map heatProperties, String heatFileName, + String resourceType, + HeatOrchestrationTemplate heatOrchestrationTemplate, + TranslationContext context, + Map toscaProperties, String heatPropertyName, + String toscaPropertyName, Template template) { + Object propertyValue = null; + if (heatProperties != null) { + propertyValue = heatProperties.get(heatPropertyName); + } + if (propertyValue == null) { + return; + } + + if (toscaPropertyName == null) { + toscaPropertyName = resourceType == null ? heatPropertyName + : context.getElementMapping(resourceType, Constants.PROP, heatPropertyName); + } + toscaProperties.put(toscaPropertyName, + getToscaPropertyValue(heatPropertyName, propertyValue, resourceType, heatFileName, + heatOrchestrationTemplate, template, context)); + } + + + /** + * Gets tosca property value. + * + * @param propertyName the property name + * @param propertyValue the property value + * @param resourceType the resource type + * @param heatFileName the heat file name + * @param heatOrchestrationTemplate the heat orchestration template + * @param template the template + * @param context the context + * @return the tosca property value + */ + public static Object getToscaPropertyValue(String propertyName, Object propertyValue, + String resourceType, String heatFileName, + HeatOrchestrationTemplate heatOrchestrationTemplate, + Template template, TranslationContext context) { + if (propertyValue instanceof Map && !((Map) propertyValue).isEmpty()) { + Map.Entry functionMapEntry = + (Map.Entry) ((Map) propertyValue).entrySet().iterator().next(); + if (TranslatorHeatToToscaFunctionConverter.functionNameSet + .contains(functionMapEntry.getKey())) { + return TranslatorHeatToToscaFunctionConverter + .getToscaFunction(functionMapEntry.getKey(), functionMapEntry.getValue(), heatFileName, + heatOrchestrationTemplate, template, context); + } + Map propertyValueMap = new HashMap<>(); + for (Map.Entry entry : ((Map) propertyValue).entrySet()) { + String toscaPropertyName = resourceType == null ? null : context + .getElementMapping(resourceType, Constants.PROP, propertyName + "." + entry.getKey()); + toscaPropertyName = toscaPropertyName != null ? toscaPropertyName : entry.getKey(); + propertyValueMap.put(toscaPropertyName, + getToscaPropertyValue(propertyName, entry.getValue(), resourceType, heatFileName, + heatOrchestrationTemplate, template, context)); + } + return propertyValueMap; + } else if (propertyValue instanceof List && !((List) propertyValue).isEmpty()) { + List propertyValueArray = new ArrayList<>(); + for (int i = 0; i < ((List) propertyValue).size(); i++) { + propertyValueArray.add( + getToscaPropertyValue(propertyName, ((List) propertyValue).get(i), resourceType, + heatFileName, heatOrchestrationTemplate, template, context)); + } + return propertyValueArray; + } + return propertyValue; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/resources/heatToToscaMapping.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/resources/heatToToscaMapping.json new file mode 100644 index 0000000000..ebe5df6b50 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/main/resources/heatToToscaMapping.json @@ -0,0 +1,298 @@ +{ + "OS::Contrail::VirtualNetwork": { + "properties": { + "name": "network_name", + "shared": "shared", + "external": "external", + "route_targets": "route_targets", + "forwarding_mode": "forwarding_mode", + "flood_unknown_unicast": "flood_unknown_unicast", + "allow_transit": "allow_transit" + }, + "attributes": { + "fq_name": "fq_name", + "name": "network_name", + "shared": "shared", + "external": "external", + "route_targets": "route_targets", + "forwarding_mode": "forwarding_mode", + "flood_unknown_unicast": "flood_unknown_unicast", + "allow_transit": "allow_transit" + } + }, + "OS::Contrail::NetworkPolicy": { + "properties": { + "name": "name", + "entries": "entries" + }, + "attributes": { + "fq_name": "fq_name", + "name": "name", + "entries": "entries", + "tenant_id": "tenant_id", + "rules": "rules", + "show": "show" + } + }, + + "OS::ContrailV2::VirtualNetwork": { + "properties": { + "name": "network_name", + "network_ipam_refs": "network_ipam_refs", + "network_ipam_refs_data": "network_ipam_refs_data", + "network_policy_refs": "network_policy_refs", + "network_policy_refs_data": "network_policy_refs_data" + }, + "attributes": { + "fq_name": "fq_name", + "name": "network_name", + "network_ipam_refs": "network_ipam_refs", + "network_ipam_refs_data": "network_ipam_refs_data", + "network_policy_refs": "network_policy_refs", + "network_policy_refs_data": "network_policy_refs_data" + } + }, + "OS::ContrailV2::VirtualMachineInterface": { + "properties": { + "name": "name", + "virtual_machine_intefrace_mac_addresses": "virtual_machine_intefrace_mac_addresses", + "virtual_network_refs": "virtual_network_refs", + "port_tuple_refs": "port_tuple_refs", + "security_group_refs": "security_group_refs", + "virtual_machine_interface_properties": "virtual_machine_interface_properties" + }, + "attributes": { + "name": "name", + "virtual_machine_intefrace_mac_addresses": "virtual_machine_intefrace_mac_addresses", + "virtual_network_refs": "virtual_network_refs", + "port_tuple_refs": "port_tuple_refs", + "virtual_machine_interface_properties": "virtual_machine_interface_properties", + "fq_name": "fq_name", + "show": "show" + } + }, + "OS::ContrailV2::NetworkPolicy": { + "properties": { + "name":"name", + "network_policy_entries":"network_policy_entries" + }, + "attributes": { + "fq_name": "fq_name", + "name":"name", + "network_policy_entries":"network_policy_entries" + } + }, + "OS::Cinder::Volume": { + "properties": { + "availability_zone": "availability_zone", + "backup_id": "backup_id", + "description": "description", + "image": "image", + "metadata": "metadata", + "multiattach": "multiattach", + "name": "name", + "read_only": "read_only", + "scheduler_hints": "scheduler_hints", + "size": "size", + "snapshot_id": "snapshot_id", + "source_volid": "source_volid", + "volume_id": "volume_id", + "volume_type": "volume_type", + "delete_on_termination": "delete_on_termination", + "volume_size": "size", + "device_type": "device_type", + "disk_bus": "disk_bus", + "swap_size": "swap_size", + "image_id": "image" + }, + "attributes": { + "attachments": "attachments", + "availability_zone": "availability_zone", + "created_at": "created_at", + "display_description": "display_description", + "display_name": "display_name", + "encrypted": "encrypted", + "metadata": "metadata", + "metadata_values": "metadata_values", + "multiattach": "multiattach", + "show": "show", + "size": "size", + "snapshot_id": "snapshot_id", + "source_volid": "source_volid", + "status": "status", + "volume_type": "volume_type" + } + }, + "OS::Cinder::VolumeAttachment": { + "properties": { + "instance_uuid": "instance_uuid", + "volume_id": "volume_id", + "mountpoint": "location" + }, + "attributes": { + "show": "show" + } + }, + "OS::Neutron::Net": { + "properties": { + "name": "network_name", + "dhcp_agent_ids": "dhcp_agent_ids", + "tenant_id": "tenant_id", + "port_security_enabled": "port_security_enabled", + "shared": "shared", + "admin_state_up": "admin_state_up", + "qos_policy": "qos_policy", + "value_specs": "value_specs" + }, + "attributes": { + "admin_state_up": "admin_state_up", + "mtu": "mtu", + "name": "network_name", + "port_security_enabled": "port_security_enabled", + "qos_policy_id": "qos_policy_id", + "show": "show", + "status": "status", + "subnets": "subnets", + "tenant_id": "tenant_id" + } + }, + "OS::Neutron::Subnet": { + "properties": { + "allocation_pools": "allocation_pools", + "cidr": "cidr", + "enable_dhcp": "enable_dhcp", + "gateway_ip": "gateway_ip", + "host_routes": "host_routes", + "ip_version": "ip_version", + "ipv6_address_mode": "ipv6_address_mode", + "ipv6_ra_mode": "ipv6_ra_mode", + "name": "name", + "prefixlen": "prefixlen", + "subnetpool": "subnetpool", + "tenant_id": "tenant_id", + "value_specs": "value_specs", + "dns_nameservers": "dns_nameservers" + } + }, + "OS::Nova::Server": { + "properties": { + "flavor": "flavor", + "admin_pass": "admin_pass", + "availability_zone": "availability_zone", + "config_drive": "config_drive", + "diskConfig": "diskConfig", + "flavor_update_policy": "flavor_update_policy", + "image": "image", + "image_update_policy": "image_update_policy", + "key_name": "key_name", + "metadata": "metadata", + "name": "name", + "personality": "personality", + "reservation_id": "reservation_id", + "scheduler_hints": "scheduler_hints", + "security_groups": "security_groups", + "software_config_transport": "software_config_transport", + "user_data_format": "user_data_format", + "user_data_update_policy": "user_data_update_policy" + }, + "attributes": { + "accessIPv4": "accessIPv4", + "accessIPv6": "accessIPv6", + "addresses": "addresses", + "console_urls": "console_urls", + "instance_name": "instance_name", + + "show": "show" + } + }, + "OS::Neutron::Port": { + "properties": { + "network": "network", + "network_id": "network", + "admin_state_up": "admin_state_up", + "allowed_address_pairs": "allowed_address_pairs", + "binding:vnic_type": "binding:vnic_type", + "device_id": "device_id", + "device_owner": "device_owner", + "fixed_ips": "fixed_ips", + "mac_address": "mac_address", + "name": "name", + "port_security_enabled": "port_security_enabled", + "qos_policy": "qos_policy", + "security_groups": "security_groups", + "value_specs": "value_specs", + "replacement_policy": "replacement_policy", + "fixed_ips.subnet":"subnet", + "fixed_ips.ip_address":"ip_address" + }, + "attributes": { + "admin_state_up": "admin_state_up", + "allowed_address_pairs": "allowed_address_pairs", + "device_id": "device_id", + "device_owner": "device_owner", + "fixed_ips": "fixed_ips", + "mac_address": "mac_address", + "name": "name", + "network_id": "network", + "network": "network", + "port_security_enabled": "port_security_enabled", + "qos_policy": "qos_policy", + "security_groups": "security_groups", + "show": "show", + "status": "status", + "subnets": "subnets", + "tenant_id": "tenant_id" + } + }, + "OS::Nova::ServerGroup": { + "properties": { + "name": "name" + }, + "attributes": { + "show": "show" + } + }, + "OS::Neutron::SecurityGroup": { + "properties": { + "description": "description", + "name": "name", + "rules": "rules" + }, + "attributes": { + "show": "show" + } + }, + "OS::Contrail::ServiceTemplate": { + "properties": { + "name": "service_template_name", + "service_mode": "service_mode", + "service_type": "service_type", + "image_name": "image_name", + "availability_zone_enable": "availability_zone_enable", + "flavor": "flavor", + "service_interface_type_list": "service_interface_type_list", + "shared_ip_list": "shared_ip_list", + "static_routes_list": "static_routes_list", + "ordered_interfaces": "ordered_interfaces" + }, + "attributes": { + } + }, + "OS::Contrail::ServiceInstance": { + "properties": { + "availability_zone": "availability_zone", + "interface_list": "interface_list", + "name": "service_instance_name" + }, + "attributes": { + "fq_name": "fq_name", + "name": "service_instance_name", + "status": "status", + "service_template": "service_template_name", + "virtual_machines": "virtual_machines", + "active_service_vms": "active_vms", + "tenant_id": "tenant_id", + "show": "show" + } + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/TestUtils.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/TestUtils.java new file mode 100644 index 0000000000..b52abfa927 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/TestUtils.java @@ -0,0 +1,43 @@ +package org.openecomp.sdc.translator; + +import org.openecomp.sdc.common.utils.AsdcCommon; +import org.openecomp.core.translator.api.HeatToToscaTranslator; +import org.openecomp.core.utilities.file.FileUtils; +import org.junit.Assert; + +import java.io.*; + +public class TestUtils { + private static final String MANIFEST_NAME = AsdcCommon.MANIFEST_NAME; + private static String zipFilename = "VSP.zip"; + private static String validationFilename = "validationOutput.json"; + + private TestUtils() { + } + + + public static void addFilesToTranslator(HeatToToscaTranslator heatToToscaTranslator, String path) + throws IOException { + File manifestFile = new File(path); + File[] files = manifestFile.listFiles(); + byte[] fileContent; + + Assert.assertNotNull("manifest files is empty", files); + + for (File file : files) { + + try (FileInputStream fis = new FileInputStream(file)) { + + fileContent = FileUtils.toByteArray(fis); + + if (file.getName().equals(MANIFEST_NAME)) { + heatToToscaTranslator.addManifest(MANIFEST_NAME, fileContent); + } else { + if (!file.getName().equals(zipFilename) && (!file.getName().equals(validationFilename))) { + heatToToscaTranslator.addFile(file.getName(), fileContent); + } + } + } + } + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/nested/multi/Translate_Heat_Nested_Multi.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/nested/multi/Translate_Heat_Nested_Multi.java new file mode 100644 index 0000000000..4be63258ae --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/nested/multi/Translate_Heat_Nested_Multi.java @@ -0,0 +1,17 @@ +package org.openecomp.sdc.translator.impl.heattotosca.nested.multi; + +import org.openecomp.sdc.translator.services.heattotosca.impl.BaseResourceTranslationTest; +import org.junit.Test; + +public class Translate_Heat_Nested_Multi extends BaseResourceTranslationTest { + + { + inputFilesPath = "/mock/heat/nested/multi/inputs"; + outputFilesPath = "/mock/heat/nested/multi/expectedoutputfiles"; + } + + @Test + public void testTranslate() throws Exception { + testTranslation(); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/nested/nestedvolumelocal/NestedVolumelocal.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/nested/nestedvolumelocal/NestedVolumelocal.java new file mode 100644 index 0000000000..4f2f3af33a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/nested/nestedvolumelocal/NestedVolumelocal.java @@ -0,0 +1,17 @@ +package org.openecomp.sdc.translator.impl.heattotosca.nested.nestedvolumelocal; + +import org.openecomp.sdc.translator.services.heattotosca.impl.BaseResourceTranslationTest; +import org.junit.Test; + +public class NestedVolumelocal extends BaseResourceTranslationTest { + + { + inputFilesPath = "/mock/heat/nested/nestedvolumelocal/inputs"; + outputFilesPath = "/mock/heat/nested/nestedvolumelocal/expectedoutputfiles"; + } + + @Test + public void testTranslate() throws Exception { + testTranslation(); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/nested/nestedvolumeseperatefile/NestedVolumeSeperateFile.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/nested/nestedvolumeseperatefile/NestedVolumeSeperateFile.java new file mode 100644 index 0000000000..02a8fb6ce4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/nested/nestedvolumeseperatefile/NestedVolumeSeperateFile.java @@ -0,0 +1,17 @@ +package org.openecomp.sdc.translator.impl.heattotosca.nested.nestedvolumeseperatefile; + +import org.openecomp.sdc.translator.services.heattotosca.impl.BaseResourceTranslationTest; +import org.junit.Test; + +public class NestedVolumeSeperateFile extends BaseResourceTranslationTest { + + { + inputFilesPath = "/mock/heat/nested/nestedvolumeseperatefile/inputs"; + outputFilesPath = "/mock/heat/nested/nestedvolumeseperatefile/expectedoutputfiles"; + } + + @Test + public void testTranslate() throws Exception { + testTranslation(); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/nested/recursive/TranslateHeatNestedRecursiveTest.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/nested/recursive/TranslateHeatNestedRecursiveTest.java new file mode 100644 index 0000000000..792f4f4bf5 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/nested/recursive/TranslateHeatNestedRecursiveTest.java @@ -0,0 +1,43 @@ +package org.openecomp.sdc.translator.impl.heattotosca.nested.recursive; + +import org.openecomp.sdc.translator.services.heattotosca.impl.BaseResourceTranslationTest; +import org.junit.Before; +import org.junit.Test; + +import java.io.IOException; + +public class TranslateHeatNestedRecursiveTest extends BaseResourceTranslationTest { + + + @Override + @Before + public void setUp() throws IOException { + // do not delete this function. it prevents the superclass setup from running + } + + @Test + public void testTranslateRecursive() throws Exception { + inputFilesPath = "/mock/heat/nested/recursive/inputs"; + outputFilesPath = "/mock/heat/nested/recursive/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + @Test + public void testTranslateExposedReq2Level() throws Exception { + inputFilesPath = "/mock/heat/nested/nested2levels/inputs"; + outputFilesPath = "/mock/heat/nested/nested2levels/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + @Test + public void testTranslateExposedReq3Level() throws Exception { + inputFilesPath = "/mock/heat/nested/nested3levels/inputs"; + outputFilesPath = "/mock/heat/nested/nested3levels/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/nested/reusenestedfrommultibase/Translate_Heat_Nested_From_Multi_Base.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/nested/reusenestedfrommultibase/Translate_Heat_Nested_From_Multi_Base.java new file mode 100644 index 0000000000..005bcd0db0 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/nested/reusenestedfrommultibase/Translate_Heat_Nested_From_Multi_Base.java @@ -0,0 +1,18 @@ +package org.openecomp.sdc.translator.impl.heattotosca.nested.reusenestedfrommultibase; + +import org.openecomp.sdc.translator.services.heattotosca.impl.BaseResourceTranslationTest; +import org.junit.Test; + +public class Translate_Heat_Nested_From_Multi_Base extends BaseResourceTranslationTest { + + { + inputFilesPath = "/mock/heat/nested/reusenestedfrommultibase/inputs"; + outputFilesPath = "/mock/heat/nested/reusenestedfrommultibase/expectedoutputfiles"; + } + + @Test + public void testTranslate() throws Exception { + testTranslation(); + } + +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/nested/separatevol/NestedAndSeparateVolTranslationTest.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/nested/separatevol/NestedAndSeparateVolTranslationTest.java new file mode 100644 index 0000000000..4269705923 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/nested/separatevol/NestedAndSeparateVolTranslationTest.java @@ -0,0 +1,22 @@ +package org.openecomp.sdc.translator.impl.heattotosca.nested.separatevol; + +import org.openecomp.sdc.translator.services.heattotosca.impl.BaseResourceTranslationTest; +import org.junit.Before; +import org.junit.Test; + +import java.io.IOException; + +public class NestedAndSeparateVolTranslationTest extends BaseResourceTranslationTest { + + @Before + public void setUp() throws IOException { + inputFilesPath = "/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles"; + outputFilesPath = "/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/out"; + super.setUp(); + } + + @Test + public void testTranslate() throws Exception { + testTranslation(); + } +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/nested/single/TranslateHeatNestedSingle.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/nested/single/TranslateHeatNestedSingle.java new file mode 100644 index 0000000000..1d80551f27 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/nested/single/TranslateHeatNestedSingle.java @@ -0,0 +1,17 @@ +package org.openecomp.sdc.translator.impl.heattotosca.nested.single; + +import org.openecomp.sdc.translator.services.heattotosca.impl.BaseResourceTranslationTest; +import org.junit.Test; + +public class TranslateHeatNestedSingle extends BaseResourceTranslationTest { + + { + inputFilesPath = "/mock/heat/nested/single/inputs"; + outputFilesPath = "/mock/heat/nested/single/expectedoutputfiles"; + } + + @Test + public void testTranslate() throws Exception { + testTranslation(); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/outputs/HeatOutputConversionTest.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/outputs/HeatOutputConversionTest.java new file mode 100644 index 0000000000..fd3543a051 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/outputs/HeatOutputConversionTest.java @@ -0,0 +1,50 @@ +package org.openecomp.sdc.translator.impl.heattotosca.outputs; + +import org.openecomp.sdc.translator.services.heattotosca.impl.BaseResourceTranslationTest; +import org.junit.Test; + +public class HeatOutputConversionTest extends BaseResourceTranslationTest { + + { + inputFilesPath = "/mock/heat/outputs/inputs"; + outputFilesPath = "/mock/heat/outputs/expectedoutputfiles"; + } + + @Test + public void testTranslate() throws Exception { + testTranslation(); + } + + + //private static final String MANIFEST_NAME = "MANIFEST.json"; + + /* @Test + public void testTranslate_outputs() throws IOException { + + HeatToToscaTranslator heatToToscaTranslator = HeatToToscaTranslatorFactory.getInstance().createInterface(); + URL url = this.getClass().getResource("/mock/heat/outputs"); + File manifestFile = new File(url.getPath()); + File[] files = manifestFile.listFiles(); + FileInputStream fis; + byte[] fileContent; + for (File file : files) { + fis = new FileInputStream(file); + fileContent = FileUtils.toByteArray(fis); + if (file.getName().equals(MANIFEST_NAME)) { + heatToToscaTranslator.addManifest(MANIFEST_NAME, new String(fileContent)); + } else { + heatToToscaTranslator.addFile(file.getName(), fileContent); + } + } + + TranslatorOutput translatorOutput = heatToToscaTranslator.translate(); + Assert.assertNotNull(translatorOutput); + File file = new File("Outputs.zip"); + FileOutputStream fos = new FileOutputStream(file); + fos.write(translatorOutput.getTranslationContent()); + fos.close(); + + }*/ + + +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/parameters/HeatParameterConversionTest.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/parameters/HeatParameterConversionTest.java new file mode 100644 index 0000000000..4feef0e094 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/parameters/HeatParameterConversionTest.java @@ -0,0 +1,54 @@ +package org.openecomp.sdc.translator.impl.heattotosca.parameters; + +import org.openecomp.sdc.translator.services.heattotosca.impl.BaseResourceTranslationTest; +import org.junit.Test; + +public class HeatParameterConversionTest extends BaseResourceTranslationTest { + + { + inputFilesPath = "/mock/heat/parameters/inputs"; + outputFilesPath = "/mock/heat/parameters/expectedoutputfiles"; + } + + @Test + public void testTranslate() throws Exception { + testTranslation(); + } + + + /* + + private static final String MANIFEST_NAME = "MANIFEST.json"; + + @Test + public void testTranslate_parameters() throws IOException { + + + + HeatToToscaTranslator heatToToscaTranslator = HeatToToscaTranslatorFactory.getInstance().createInterface(); + URL url = this.getClass().getResource("/mock/heat/parameters"); + File manifestFile = new File(url.getPath()); + File[] files = manifestFile.listFiles(); + FileInputStream fis; + byte[] fileContent; + for (File file : files) { + fis = new FileInputStream(file); + fileContent = FileUtils.toByteArray(fis); + if (file.getName().equals(MANIFEST_NAME)) { + heatToToscaTranslator.addManifest(MANIFEST_NAME, new String(fileContent)); + } else { + heatToToscaTranslator.addFile(file.getName(), fileContent); + } + } + + TranslatorOutput translatorOutput = heatToToscaTranslator.translate(); + Assert.assertNotNull(translatorOutput); + File file = new File("Parameters.zip"); + FileOutputStream fos = new FileOutputStream(file); + fos.write(translatorOutput.getTranslationContent()); + fos.close(); + + } + */ + +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/resources/ContrailNetworkRuleTest.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/resources/ContrailNetworkRuleTest.java new file mode 100644 index 0000000000..f8b3022155 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/resources/ContrailNetworkRuleTest.java @@ -0,0 +1,18 @@ +package org.openecomp.sdc.translator.impl.heattotosca.resources; + +import org.openecomp.sdc.translator.services.heattotosca.impl.BaseResourceTranslationTest; +import org.junit.Test; + + +public class ContrailNetworkRuleTest extends BaseResourceTranslationTest { + + { + inputFilesPath = "/mock/heat/resources/OS_Contrail_Network_Rule/inputs"; + outputFilesPath = "/mock/heat/resources/OS_Contrail_Network_Rule/expectedoutputfiles"; + } + + @Test + public void testTranslate() throws Exception { + testTranslation(); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/resources/OSContrailVirtualNetworkTest.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/resources/OSContrailVirtualNetworkTest.java new file mode 100644 index 0000000000..b1305c3b2c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/resources/OSContrailVirtualNetworkTest.java @@ -0,0 +1,18 @@ +package org.openecomp.sdc.translator.impl.heattotosca.resources; + +import org.openecomp.sdc.translator.services.heattotosca.impl.BaseResourceTranslationTest; +import org.junit.Test; + + +public class OSContrailVirtualNetworkTest extends BaseResourceTranslationTest { + + { + inputFilesPath = "/mock/heat/resources/OS_Contrail_VirtualNetwork/inputs"; + outputFilesPath = "/mock/heat/resources/OS_Contrail_VirtualNetwork/expectedoutputfiles"; + } + + @Test + public void testTranslate() throws Exception { + testTranslation(); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/resources/OSNeutronNetTest.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/resources/OSNeutronNetTest.java new file mode 100644 index 0000000000..3b312a804d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/resources/OSNeutronNetTest.java @@ -0,0 +1,17 @@ +package org.openecomp.sdc.translator.impl.heattotosca.resources; + +import org.openecomp.sdc.translator.services.heattotosca.impl.BaseResourceTranslationTest; +import org.junit.Test; + +public class OSNeutronNetTest extends BaseResourceTranslationTest { + + { + inputFilesPath = "/mock/heat/resources/OS_Neutron_Net/inputs"; + outputFilesPath = "/mock/heat/resources/OS_Neutron_Net/expectedoutputfiles"; + } + + @Test + public void testTranslate() throws Exception { + testTranslation(); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/resources/OSNovaServerTest.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/resources/OSNovaServerTest.java new file mode 100644 index 0000000000..6d194ea220 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/resources/OSNovaServerTest.java @@ -0,0 +1,17 @@ +package org.openecomp.sdc.translator.impl.heattotosca.resources; + +import org.openecomp.sdc.translator.services.heattotosca.impl.BaseResourceTranslationTest; +import org.junit.Test; + +public class OSNovaServerTest extends BaseResourceTranslationTest { + + { + inputFilesPath = "/mock/heat/resources/OS_Nova_Server/inputs"; + outputFilesPath = "/mock/heat/resources/OS_Nova_Server/expectedoutputfiles"; + } + + @Test + public void testTranslate() throws Exception { + testTranslation(); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/sharedresource/HeatSharedResourceTest.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/sharedresource/HeatSharedResourceTest.java new file mode 100644 index 0000000000..2395fa00db --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/impl/heattotosca/sharedresource/HeatSharedResourceTest.java @@ -0,0 +1,19 @@ +package org.openecomp.sdc.translator.impl.heattotosca.sharedresource; + +import org.openecomp.sdc.translator.services.heattotosca.impl.BaseResourceTranslationTest; +import org.junit.Test; + +public class HeatSharedResourceTest extends BaseResourceTranslationTest { + + { + inputFilesPath = "/mock/heat/sharedresources/inputs"; + outputFilesPath = "/mock/heat/sharedresources/expectedoutputfiles"; + } + + @Test + public void testTranslate() throws Exception { + testTranslation(); + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/GlobalTypesGeneratorTest.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/GlobalTypesGeneratorTest.java new file mode 100644 index 0000000000..6afa9c1ea2 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/GlobalTypesGeneratorTest.java @@ -0,0 +1,18 @@ +package org.openecomp.sdc.translator.services.heattotosca; + +import org.openecomp.sdc.translator.services.heattotosca.impl.BaseResourceTranslationTest; +import org.junit.Test; + +public class GlobalTypesGeneratorTest extends BaseResourceTranslationTest { + + { + inputFilesPath = "/mock/services/heattotosca/global_types/inputfiles"; + outputFilesPath = "/mock/services/heattotosca/global_types/expectedoutputfiles"; + } + + @Test + public void testTranslate() throws Exception { + testTranslation(); + } + +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/fullvfexample/hotmog/HotMogTranslationTest.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/fullvfexample/hotmog/HotMogTranslationTest.java new file mode 100644 index 0000000000..13be7235d9 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/fullvfexample/hotmog/HotMogTranslationTest.java @@ -0,0 +1,17 @@ +package org.openecomp.sdc.translator.services.heattotosca.fullvfexample.hotmog; + +import org.openecomp.sdc.translator.services.heattotosca.impl.BaseResourceTranslationTest; +import org.junit.Test; + +public class HotMogTranslationTest extends BaseResourceTranslationTest { + + { + inputFilesPath = "/mock/services/heattotosca/hot-mog-0108-bs1271/inputfiles"; + outputFilesPath = "/mock/services/heattotosca/hot-mog-0108-bs1271/expectedoutputfiles"; + } + + @Test + public void testTranslate() throws Exception { + testTranslation(); + } +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/fullvfexample/vmmesmall/VmmeSmallTranslationTest.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/fullvfexample/vmmesmall/VmmeSmallTranslationTest.java new file mode 100644 index 0000000000..4db0bdf339 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/fullvfexample/vmmesmall/VmmeSmallTranslationTest.java @@ -0,0 +1,17 @@ +package org.openecomp.sdc.translator.services.heattotosca.fullvfexample.vmmesmall; + +import org.openecomp.sdc.translator.services.heattotosca.impl.BaseResourceTranslationTest; +import org.junit.Test; + +public class VmmeSmallTranslationTest extends BaseResourceTranslationTest { + + { + inputFilesPath = "/mock/services/heattotosca/vmme_small/inputfiles"; + outputFilesPath = "/mock/services/heattotosca/vmme_small/expectedoutputfiles"; + } + + @Test + public void testTranslate() throws Exception { + testTranslation(); + } +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/helper/impl/NameExtractorServiceImplTest.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/helper/impl/NameExtractorServiceImplTest.java new file mode 100644 index 0000000000..1fb1b023e0 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/helper/impl/NameExtractorServiceImplTest.java @@ -0,0 +1,118 @@ +package org.openecomp.sdc.translator.services.heattotosca.helper.impl; + +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.translator.services.heattotosca.Constants; +import org.openecomp.sdc.translator.services.heattotosca.impl.ResourceTranslationNovaServerImpl; +import org.junit.Test; + +import java.util.Arrays; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +import static org.junit.Assert.assertTrue; + +/** + * @author Avrahamg + * @since August 04, 2016 + */ +public class NameExtractorServiceImplTest { + @Test + public void shouldReturnNamePrefixIfPropertyNameMatchWithIndex() throws Exception { + Map propertiesMap = new HashMap(); + propertiesMap.put("a", "sss"); + HashMap imageMap = new HashMap(); + String name = "avi_test_name_1"; + imageMap.put("get_param", name); + propertiesMap.put(Constants.NAME_PROPERTY_NAME, imageMap); + ResourceTranslationNovaServerImpl resourceTranslationNovaServer = + new ResourceTranslationNovaServerImpl(); + String localNodeType = resourceTranslationNovaServer + .createLocalNodeType(new ServiceTemplate(), propertiesMap, "Ignore"); + assertTrue(localNodeType.equals("org.openecomp.resource.vfc.nodes.heat.avi_test")); + } + + @Test + public void shouldReturnNamePrefixIfPropertyNameMatchWithListObjectInGetParamVal() + throws Exception { + Map propertiesMap = new HashMap(); + propertiesMap.put("a", "sss"); + HashMap imageMap = new HashMap(); + List val = Arrays.asList("virc_vm_names", "2"); + imageMap.put("get_param", val); + propertiesMap.put(Constants.NAME_PROPERTY_NAME, imageMap); + ResourceTranslationNovaServerImpl resourceTranslationNovaServer = + new ResourceTranslationNovaServerImpl(); + String localNodeType = resourceTranslationNovaServer + .createLocalNodeType(new ServiceTemplate(), propertiesMap, "Ignore"); + assertTrue(localNodeType.equals("org.openecomp.resource.vfc.nodes.heat.virc_vm")); + } + + @Test + public void shouldReturnNamePrefixIfPropertyNameMatchWithListObjectInGetParamValAndGetParamAsGetParamVal() + throws Exception { + Map propertiesMap = new HashMap(); + propertiesMap.put("a", "sss"); + HashMap nameMap = new HashMap(); + HashMap nameValMap = new HashMap(); + nameValMap.put("get_param", "anyParam"); + List val = Arrays.asList("virc_vm_names", nameValMap); + nameMap.put("get_param", val); + propertiesMap.put(Constants.NAME_PROPERTY_NAME, nameMap); + ResourceTranslationNovaServerImpl resourceTranslationNovaServer = + new ResourceTranslationNovaServerImpl(); + String localNodeType = resourceTranslationNovaServer + .createLocalNodeType(new ServiceTemplate(), propertiesMap, "Ignore"); + assertTrue(localNodeType.equals("org.openecomp.resource.vfc.nodes.heat.virc_vm")); + } + + + @Test + public void shouldReturnNamePrefixIfPropertyNameMatchWithoutIndex() throws Exception { + Map propertiesMap = new HashMap(); + propertiesMap.put("a", "sss"); + HashMap imageMap = new HashMap(); + String name = "avi_test_names"; + imageMap.put("get_param", name); + propertiesMap.put(Constants.NAME_PROPERTY_NAME, imageMap); + ResourceTranslationNovaServerImpl resourceTranslationNovaServer = + new ResourceTranslationNovaServerImpl(); + String localNodeType = resourceTranslationNovaServer + .createLocalNodeType(new ServiceTemplate(), propertiesMap, "Ignore"); + assertTrue(localNodeType.equals("org.openecomp.resource.vfc.nodes.heat.avi_test")); + } + + @Test + public void shouldReturnPrefixByPropertyOrder() throws Exception { + Map propertiesMap = new HashMap(); + propertiesMap.put("a", "sss"); + HashMap imageMap = new HashMap(); + String name = "avi_test1_namesw"; + imageMap.put("get_param", name); + propertiesMap.put(Constants.NAME_PROPERTY_NAME, imageMap); + String flavor = "avi_test2_flavor_name"; + imageMap = new HashMap(); + imageMap.put("get_param", flavor); + propertiesMap.put("flavor", imageMap); + ResourceTranslationNovaServerImpl resourceTranslationNovaServer = + new ResourceTranslationNovaServerImpl(); + String localNodeType = resourceTranslationNovaServer + .createLocalNodeType(new ServiceTemplate(), propertiesMap, "Ignore"); + assertTrue(localNodeType.equals("org.openecomp.resource.vfc.nodes.heat.avi_test2")); + } + + @Test + public void shouldReturnEmptyIfPropertiesAreNotAsNamingConvention() throws Exception { + Map propertiesMap = new HashMap(); + propertiesMap.put("a", "sss"); + HashMap imageMap = new HashMap(); + String name = "avi_test_namesw"; + imageMap.put("get_param", name); + propertiesMap.put(Constants.NAME_PROPERTY_NAME, imageMap); + ResourceTranslationNovaServerImpl resourceTranslationNovaServer = + new ResourceTranslationNovaServerImpl(); + String localNodeType = resourceTranslationNovaServer + .createLocalNodeType(new ServiceTemplate(), propertiesMap, "this.is.test.resource"); + assertTrue(localNodeType.equals("org.openecomp.resource.vfc.nodes.heat.this_is_test_resource")); + } +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/BaseResourceTranslationTest.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/BaseResourceTranslationTest.java new file mode 100644 index 0000000000..9282d4e4eb --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/BaseResourceTranslationTest.java @@ -0,0 +1,130 @@ +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; +import org.openecomp.sdc.tosca.services.ToscaFileOutputService; +import org.openecomp.sdc.tosca.services.impl.ToscaFileOutputServiceCsarImpl; +import org.openecomp.sdc.translator.TestUtils; +import org.openecomp.core.translator.api.HeatToToscaTranslator; +import org.openecomp.core.translator.datatypes.TranslatorOutput; +import org.openecomp.core.translator.factory.HeatToToscaTranslatorFactory; +import org.openecomp.core.utilities.file.FileUtils; +import org.openecomp.core.validation.types.MessageContainerUtil; +import org.apache.commons.collections4.MapUtils; +import org.junit.Assert; +import org.junit.Before; + +import java.io.*; +import java.net.URL; +import java.util.*; +import java.util.zip.ZipEntry; +import java.util.zip.ZipInputStream; + +import static org.junit.Assert.assertEquals; + +public class BaseResourceTranslationTest { + + protected String inputFilesPath; + protected String outputFilesPath; + private HeatToToscaTranslator heatToToscaTranslator; + private File translatedZipFile; + + private Map expectedResultMap = new HashMap<>(); + private Set expectedResultFileNameSet = new HashSet<>(); + + @Before + public void setUp() throws IOException { + initTranslatorAndTranslate(); + } + + protected void initTranslatorAndTranslate() throws IOException { + heatToToscaTranslator = HeatToToscaTranslatorFactory.getInstance().createInterface(); + translatedZipFile = translateZipFile(); + } + + protected void testTranslation() throws IOException { + + URL url = BaseResourceTranslationTest.class.getResource(outputFilesPath); + + String path = url.getPath(); + File pathFile = new File(path); + File[] files = pathFile.listFiles(); + Assert.assertNotNull("manifest files is empty", files); + for (File expectedFile : files) { + expectedResultFileNameSet.add(expectedFile.getName()); + try (FileInputStream input = new FileInputStream(expectedFile)) { + expectedResultMap.put(expectedFile.getName(), FileUtils.toByteArray(input)); + } + } + + try (FileInputStream fis = new FileInputStream(translatedZipFile); + ZipInputStream zis = new ZipInputStream(new BufferedInputStream(fis))) { + ZipEntry entry; + String name; + String expected; + String actual; + + while ((entry = zis.getNextEntry()) != null) { + + name = entry.getName() + .substring(entry.getName().lastIndexOf(File.separator) + 1, entry.getName().length()); + if (expectedResultFileNameSet.contains(name)) { + expected = new String(expectedResultMap.get(name)).trim().replace("\r", ""); + actual = new String(FileUtils.toByteArray(zis)).trim().replace("\r", ""); + assertEquals("difference in file: " + name, expected, actual); + + expectedResultFileNameSet.remove(name); + } + } + if (expectedResultFileNameSet.isEmpty()) { + expectedResultFileNameSet.forEach(System.out::println); + } + } + assertEquals(0, expectedResultFileNameSet.size()); + } + + private File translateZipFile() throws IOException { + String zipFilename = "VSP.zip"; + URL inputFilesUrl = this.getClass().getResource(inputFilesPath); + String path = inputFilesUrl.getPath(); + TestUtils.addFilesToTranslator(heatToToscaTranslator, path); + TranslatorOutput translatorOutput = heatToToscaTranslator.translate(); + Assert.assertNotNull(translatorOutput); + if (MapUtils.isNotEmpty(translatorOutput.getErrorMessages()) && MapUtils.isNotEmpty( + MessageContainerUtil + .getMessageByLevel(org.openecomp.sdc.datatypes.error.ErrorLevel.ERROR, translatorOutput.getErrorMessages()))) { + throw new CoreException((new ErrorCode.ErrorCodeBuilder()).withMessage( + "Error in validation " + getErrorAsString(translatorOutput.getErrorMessages())) + .withId("Validation Error").withCategory(ErrorCategory.APPLICATION).build()); + } + File file = new File(path + "/" + zipFilename); + file.createNewFile(); + + try (FileOutputStream fos = new FileOutputStream(file)) { + ToscaFileOutputService toscaFileOutputService = new ToscaFileOutputServiceCsarImpl(); + fos.write( + toscaFileOutputService.createOutputFile(translatorOutput.getToscaServiceModel(), null)); + } + + return file; + } + + private String getErrorAsString(Map> errorMessages) { + StringBuilder sb = new StringBuilder(); + errorMessages.entrySet().forEach( + entry -> sb.append("File:").append(entry.getKey()).append(System.lineSeparator()) + .append(getErrorList(entry.getValue()))); + + return sb.toString(); + } + + private String getErrorList(List errors) { + StringBuilder sb = new StringBuilder(); + errors.stream().forEach( + error -> sb.append(error.getMessage()).append("[").append(error.getLevel()).append("]") + .append(System.lineSeparator())); + return sb.toString(); + } + +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ContrailV2VMInterfaceToNetResourceConnectionTest.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ContrailV2VMInterfaceToNetResourceConnectionTest.java new file mode 100644 index 0000000000..1dce2c8d70 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ContrailV2VMInterfaceToNetResourceConnectionTest.java @@ -0,0 +1,46 @@ +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.junit.Before; +import org.junit.Test; + +import java.io.IOException; + +/** + * @author Avrahamg + * @since August 10, 2016 + */ +public class ContrailV2VMInterfaceToNetResourceConnectionTest extends BaseResourceTranslationTest { + @Override + @Before + public void setUp() throws IOException { + // do not delete this function. it prevents the superclass setup from running + } + + @Test + public void testTranslateVMIToNetNestedConnection() throws Exception { + inputFilesPath = "/mock/services/heattotosca/VMInterfaceToNettworkConnection/nested/inputfiles"; + outputFilesPath = + "/mock/services/heattotosca/VMInterfaceToNettworkConnection/nested/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + @Test + public void testTranslateVMIToSharedNetNestedConnection() throws Exception { + inputFilesPath = "/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/inputfiles"; + outputFilesPath = + "/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + @Test + public void testTranslateVMIToNetMultiConnection() throws Exception { + inputFilesPath = "/mock/services/heattotosca/VMInterfaceToNettworkConnection/multi/inputfiles"; + outputFilesPath = + "/mock/services/heattotosca/VMInterfaceToNettworkConnection/multi/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/DependsOnResourceBaseTranslationlTest.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/DependsOnResourceBaseTranslationlTest.java new file mode 100644 index 0000000000..2ba2d936e8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/DependsOnResourceBaseTranslationlTest.java @@ -0,0 +1,15 @@ +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.junit.Test; + +public class DependsOnResourceBaseTranslationlTest extends BaseResourceTranslationTest { + public DependsOnResourceBaseTranslationlTest() { + inputFilesPath = "/mock/services/heattotosca/baseResourceTranslation/inputfiles"; + outputFilesPath = "/mock/services/heattotosca/baseResourceTranslation/expectedoutputfiles"; + } + + @Test + public void testTranslate() throws Exception { + testTranslation(); + } +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/MultipleHeatTranslationTest.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/MultipleHeatTranslationTest.java new file mode 100644 index 0000000000..caec80c11b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/MultipleHeatTranslationTest.java @@ -0,0 +1,31 @@ +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.junit.Before; +import org.junit.Test; + +import java.io.IOException; + +public class MultipleHeatTranslationTest extends BaseResourceTranslationTest { + + @Override + @Before + public void setUp() throws IOException { + // do not delete this function. it prevents the superclass setup from running + } + + @Test + public void testTranslateBaseHeats() throws Exception { + inputFilesPath = "/mock/multiHeat/allHeatsAreBase/inputs"; + outputFilesPath = "/mock/multiHeat/allHeatsAreBase/expectedOutput/"; + initTranslatorAndTranslate(); + testTranslation(); + } + + @Test + public void testTranslateOneOutOfFourFilesIsNotBase() throws Exception { + inputFilesPath = "/mock/multiHeat/referencedHeatResources/inputs"; + outputFilesPath = "/mock/multiHeat/referencedHeatResources/expectedOutput/"; + initTranslatorAndTranslate(); + testTranslation(); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/NovaToVolResourceConnectionTest.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/NovaToVolResourceConnectionTest.java new file mode 100644 index 0000000000..93a8668a2f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/NovaToVolResourceConnectionTest.java @@ -0,0 +1,91 @@ +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.junit.Before; +import org.junit.Test; + +import java.io.IOException; + +/** + * @author avrahamg + * @since July 26, 2016 + */ +public class NovaToVolResourceConnectionTest extends BaseResourceTranslationTest { + @Override + @Before + public void setUp() throws IOException { + // do not delete this function. it prevents the superclass setup from running + } + + @Test + public void testNovaToVolumeConnectionMultiConnection() throws Exception { + inputFilesPath = "/mock/services/heattotosca/novatovolumeconnection/multiconnection/inputfiles"; + outputFilesPath = + "/mock/services/heattotosca/novatovolumeconnection/multiconnection/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + @Test + public void testNovaToVolumeConnectionMultiNotCreatedIfVolPorpertyInVolAttacheIsNotAReferenceToVolume() + throws Exception { + inputFilesPath = + "/mock/services/heattotosca/novatovolumeconnection/multinotconnected/inputfiles"; + outputFilesPath = + "/mock/services/heattotosca/novatovolumeconnection/multinotconnected/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + @Test + public void testNovaToVolumeConnectionNestedNotCreatedIfVolPorpertyInVolAttacheIsNotAReferenceToVolume() + throws Exception { + inputFilesPath = + "/mock/services/heattotosca/novatovolumeconnection/nestednotconnected/inputfiles"; + outputFilesPath = + "/mock/services/heattotosca/novatovolumeconnection/nestednotconnected/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + @Test + public void testTranslateNovaToVolumeNestedConnection() throws Exception { + inputFilesPath = + "/mock/services/heattotosca/novatovolumeconnection/nestedconnection/inputfiles"; + outputFilesPath = + "/mock/services/heattotosca/novatovolumeconnection/nestedconnection/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + @Test + public void testTranslateNovaToVolumeSharedNestedConnection() throws Exception { + inputFilesPath = + "/mock/services/heattotosca/novatovolumeconnection/sharednestedconnection/inputfiles"; + outputFilesPath = + "/mock/services/heattotosca/novatovolumeconnection/sharednestedconnection/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + @Test + public void testTranslateNovaToVolumeSharedNestedNotCreatedIfVolPorpertyInVolAttacheIsNotAReferenceToVolume() + throws Exception { + inputFilesPath = + "/mock/services/heattotosca/novatovolumeconnection/sharednestednotconnected/inputfiles"; + outputFilesPath = + "/mock/services/heattotosca/novatovolumeconnection/sharednestednotconnected/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + @Test + public void testTranslateNovaToVolumeInnerNestedConnection() throws Exception { + inputFilesPath = + "/mock/services/heattotosca/novatovolumeconnection/innernestedconnection/inputfiles"; + outputFilesPath = + "/mock/services/heattotosca/novatovolumeconnection/innernestedconnection/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/PortToContrailV2VirtualNetworkResourceConnectionTest.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/PortToContrailV2VirtualNetworkResourceConnectionTest.java new file mode 100644 index 0000000000..156008edb9 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/PortToContrailV2VirtualNetworkResourceConnectionTest.java @@ -0,0 +1,45 @@ +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.junit.Before; +import org.junit.Test; + +import java.io.IOException; + +public class PortToContrailV2VirtualNetworkResourceConnectionTest + extends BaseResourceTranslationTest { + @Override + @Before + public void setUp() throws IOException { + // do not delete this function. it prevents the superclass setup from running + } + + @Test + public void testPortToNetNestedConnection() throws Exception { + inputFilesPath = + "/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/nested/inputfiles"; + outputFilesPath = + "/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/nested/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + @Test + public void testPortToSharedNetNestedConnection() throws Exception { + inputFilesPath = + "/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/inputfiles"; + outputFilesPath = + "/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + @Test + public void testPortToNetMultiConnection() throws Exception { + inputFilesPath = + "/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/multi/inputfiles"; + outputFilesPath = + "/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/multi/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/PortToNetResourceConnectionTest.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/PortToNetResourceConnectionTest.java new file mode 100644 index 0000000000..6411d4759e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/PortToNetResourceConnectionTest.java @@ -0,0 +1,38 @@ +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.junit.Before; +import org.junit.Test; + +import java.io.IOException; + +public class PortToNetResourceConnectionTest extends BaseResourceTranslationTest { + @Override + @Before + public void setUp() throws IOException { + // do not delete this function. it prevents the superclass setup from running + } + + @Test + public void testTranslatePortToNetNestedConnection() throws Exception { + inputFilesPath = "/mock/services/heattotosca/porttonetconnection/nested/inputfiles"; + outputFilesPath = "/mock/services/heattotosca/porttonetconnection/nested/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + @Test + public void testTranslatePortToSharedNetNestedConnection() throws Exception { + inputFilesPath = "/mock/services/heattotosca/porttonetconnection/shared/inputfiles"; + outputFilesPath = "/mock/services/heattotosca/porttonetconnection/shared/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + @Test + public void testTranslatePortToNetMultiConnection() throws Exception { + inputFilesPath = "/mock/services/heattotosca/porttonetconnection/multi/inputfiles"; + outputFilesPath = "/mock/services/heattotosca/porttonetconnection/multi/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationCinderVolumeAttachmentImplTest.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationCinderVolumeAttachmentImplTest.java new file mode 100644 index 0000000000..54c06dd0d0 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationCinderVolumeAttachmentImplTest.java @@ -0,0 +1,52 @@ +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.junit.Before; +import org.junit.Test; + +import java.io.IOException; + +public class ResourceTranslationCinderVolumeAttachmentImplTest extends BaseResourceTranslationTest { + + @Override + @Before + public void setUp() throws IOException { + // do not delete this function. it prevents the superclass setup from running + } + + @Test + public void testTranslateAllResourcesInOneFile() throws Exception { + inputFilesPath = "/mock/services/heattotosca/vol_att/volume_and_attach_one_file/inputfiles"; + outputFilesPath = + "/mock/services/heattotosca/vol_att/volume_and_attach_one_file/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + @Test + public void testVolFileIsNestedInMainHeatFile() throws Exception { + inputFilesPath = + "/mock/services/heattotosca/vol_att/volume_file_nested_in_main_file_in_manifest/inputfiles"; + outputFilesPath = + "/mock/services/heattotosca/vol_att/volume_file_nested_in_main_file_in_manifest/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + @Test + public void testVolFileAsDataOfNested() throws Exception { + inputFilesPath = "/mock/services/heattotosca/vol_att/nested_with_inner_vol/inputfiles"; + outputFilesPath = "/mock/services/heattotosca/vol_att/nested_with_inner_vol/out"; + initTranslatorAndTranslate(); + testTranslation(); + } + + @Test + public void testVolFileIsParallelToMainHeatFile() throws Exception { + inputFilesPath = + "/mock/services/heattotosca/vol_att/volume_file_parallel_to_main_file/inputfiles"; + outputFilesPath = + "/mock/services/heattotosca/vol_att/volume_file_parallel_to_main_file/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationCinderVolumeImplTest.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationCinderVolumeImplTest.java new file mode 100644 index 0000000000..30ccbdd53d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationCinderVolumeImplTest.java @@ -0,0 +1,15 @@ +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.junit.Test; + +public class ResourceTranslationCinderVolumeImplTest extends BaseResourceTranslationTest { + public ResourceTranslationCinderVolumeImplTest() { + inputFilesPath = "/mock/services/heattotosca/cinder_volume_translation/inputfiles"; + outputFilesPath = "/mock/services/heattotosca/cinder_volume_translation/expectedoutputfiles"; + } + + @Test + public void testTranslate() throws Exception { + testTranslation(); + } +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailServiceInstanceImplTest.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailServiceInstanceImplTest.java new file mode 100644 index 0000000000..40f5eb1200 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailServiceInstanceImplTest.java @@ -0,0 +1,72 @@ +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.junit.Before; +import org.junit.Test; + +import java.io.IOException; + +/** + * @author shiria + * @since August 07, 2016. + */ +public class ResourceTranslationContrailServiceInstanceImplTest + extends BaseResourceTranslationTest { + + @Override + @Before + public void setUp() throws IOException { + // do not delete this function. it prevents the superclass setup from running + } + + @Test + public void testTranslateOneServiceInstance() throws Exception { + inputFilesPath = + "/mock/services/heattotosca/contrail2serviceinstance/oneServiceInstance/inputfiles"; + outputFilesPath = + "/mock/services/heattotosca/contrail2serviceinstance/oneServiceInstance/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + @Test + public void testTranslateDiffServiceTemplate() throws Exception { + inputFilesPath = + "/mock/services/heattotosca/contrail2serviceinstance/diffServiceTemplate/inputfiles"; + outputFilesPath = + "/mock/services/heattotosca/contrail2serviceinstance/diffServiceTemplate/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + @Test + public void testTranslateSharedNetworkMulti() throws Exception { + inputFilesPath = + "/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkMulti/inputfiles"; + outputFilesPath = + "/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkMulti/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + @Test + public void testTranslateSameServiceTemplate() throws Exception { + inputFilesPath = + "/mock/services/heattotosca/contrail2serviceinstance/sameServiceTemplate/inputfiles"; + outputFilesPath = + "/mock/services/heattotosca/contrail2serviceinstance/sameServiceTemplate/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + + /* + //TODO -- need to be tested once the 2 level nested For shared resources bug will be fixed - ATTASDC-1065 + @Test + public void testTranslateSharedNetworkNested() throws Exception { + inputFilesPath = "/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkNested/inputfiles"; + outputFilesPath = "/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkNested/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + */ +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailServiceTemplateImplTest.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailServiceTemplateImplTest.java new file mode 100644 index 0000000000..42b6db0e71 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailServiceTemplateImplTest.java @@ -0,0 +1,55 @@ +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.openecomp.sdc.heat.datatypes.model.Resource; +import org.openecomp.sdc.translator.services.heattotosca.helper.ContrailTranslationHelper; +import org.junit.Assert; +import org.junit.Rule; +import org.junit.Test; +import org.junit.rules.ExpectedException; + +import java.util.HashMap; +import java.util.Map; + +/** + * @author shiria + * @since August 09, 2016. + */ +public class ResourceTranslationContrailServiceTemplateImplTest { + + @Rule + public ExpectedException thrown = ExpectedException.none(); + + @Test + public void testStaticGetComputeNodeTypeId() throws Exception { + Resource serviceTemplate = new Resource(); + serviceTemplate.setProperties(new HashMap<>()); + serviceTemplate.getProperties().put("image_name", "aaaa"); + String computeNodeTypeId = + new ContrailTranslationHelper().getComputeNodeTypeId("123", serviceTemplate); + Assert.assertEquals("org.openecomp.resource.vfc.nodes.heat.compute_123", computeNodeTypeId); + } + + @Test + public void testNamingConventionGetComputeNodeTypeId() throws Exception { + Resource serviceTemplate = new Resource(); + serviceTemplate.setProperties(new HashMap<>()); + Map image = new HashMap<>(); + image.put("get_param", "bbb_image_name"); + serviceTemplate.getProperties().put("image_name", image); + String computeNodeTypeId = + new ContrailTranslationHelper().getComputeNodeTypeId("123", serviceTemplate); + Assert.assertEquals(computeNodeTypeId, "org.openecomp.resource.vfc.nodes.heat.bbb"); + } + + @Test + public void testNoNamingConventionGetComputeNodeTypeId() throws Exception { + Resource serviceTemplate = new Resource(); + serviceTemplate.setProperties(new HashMap<>()); + Map image = new HashMap<>(); + image.put("get_file", "bbb_image"); + serviceTemplate.getProperties().put("image_name", image); + String computeNodeTypeId = + new ContrailTranslationHelper().getComputeNodeTypeId("123", serviceTemplate); + Assert.assertEquals(computeNodeTypeId, "org.openecomp.resource.vfc.nodes.heat.compute_123"); + } +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailV2Test.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailV2Test.java new file mode 100644 index 0000000000..e4e1ad9216 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailV2Test.java @@ -0,0 +1,56 @@ +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.junit.Before; +import org.junit.Test; + +import java.io.IOException; + +public class ResourceTranslationContrailV2Test extends BaseResourceTranslationTest { + + @Override + @Before + public void setUp() throws IOException { + // do not delete this function. it prevents the superclass setup from running + } + + @Test + public void testTranslate() throws Exception { + inputFilesPath = "/mock/services/heattotosca/ContrailV2_translation/simple/inputfiles"; + outputFilesPath = + "/mock/services/heattotosca/ContrailV2_translation/simple/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + @Test + public void testMultiPolicySingleNetTranslate() throws Exception { + inputFilesPath = + "/mock/services/heattotosca/ContrailV2_translation/ContrailV2_MultiPolicy_single_net_translation/inputfiles"; + outputFilesPath = + "/mock/services/heattotosca/ContrailV2_translation/ContrailV2_MultiPolicy_single_net_translation/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + @Test + public void testMultiNetSinglePolicyTranslate() throws Exception { + inputFilesPath = + "/mock/services/heattotosca/ContrailV2_translation/ContrailV2_Multi_net_single_policy_translation/inputfiles"; + outputFilesPath = + "/mock/services/heattotosca/ContrailV2_translation/ContrailV2_Multi_net_single_policy_translation/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + @Test + public void testInvalidPolicyResourceTypeTranslate() throws Exception { + inputFilesPath = + "/mock/services/heattotosca/ContrailV2_translation/invalid_policy_resource_type/inputfiles"; + outputFilesPath = + "/mock/services/heattotosca/ContrailV2_translation/invalid_policy_resource_type/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailV2VMInterfaceImplTest.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailV2VMInterfaceImplTest.java new file mode 100644 index 0000000000..95757e7cf9 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationContrailV2VMInterfaceImplTest.java @@ -0,0 +1,36 @@ +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.junit.Before; +import org.junit.Test; + +import java.io.IOException; + +/** + * @author Avrahamg + * @since August 10, 2016 + */ +public class ResourceTranslationContrailV2VMInterfaceImplTest extends BaseResourceTranslationTest { + + @Override + @Before + public void setUp() throws IOException { + // do not delete this function. it prevents the superclass setup from running + } + + @Test + public void testTranslateVMIWithGetResource() throws Exception { + inputFilesPath = "/mock/services/heattotosca/contrailv2VMinterface/oneNet/inputfiles"; + outputFilesPath = "/mock/services/heattotosca/contrailv2VMinterface/oneNet/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + @Test + public void testTranslateVMIWithListOfNetworks() throws Exception { + inputFilesPath = "/mock/services/heattotosca/contrailv2VMinterface/listNet/inputfiles"; + outputFilesPath = + "/mock/services/heattotosca/contrailv2VMinterface/listNet/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNeutronPortImplTest.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNeutronPortImplTest.java new file mode 100644 index 0000000000..6e2c298346 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNeutronPortImplTest.java @@ -0,0 +1,17 @@ +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.junit.Test; + +public class ResourceTranslationNeutronPortImplTest extends BaseResourceTranslationTest { + + { + inputFilesPath = "/mock/services/heattotosca/neutron_port_translation/inputfiles"; + outputFilesPath = "/mock/services/heattotosca/neutron_port_translation/expectedoutputfiles"; + } + + @Test + public void testTranslate() throws Exception { + testTranslation(); + } + +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNeutronSecurityGroupImplTest.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNeutronSecurityGroupImplTest.java new file mode 100644 index 0000000000..1791f10b1c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNeutronSecurityGroupImplTest.java @@ -0,0 +1,19 @@ +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.junit.Test; + +public class ResourceTranslationNeutronSecurityGroupImplTest extends BaseResourceTranslationTest { + + { + inputFilesPath = "/mock/services/heattotosca/neutron_security_group_translation/inputfiles"; + outputFilesPath = + "/mock/services/heattotosca/neutron_security_group_translation/expectedoutputfiles"; + } + + @Test + public void testTranslate() throws Exception { + testTranslation(); + } + + +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNovaServerGroupsImplTest.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNovaServerGroupsImplTest.java new file mode 100644 index 0000000000..aabee8f56f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationNovaServerGroupsImplTest.java @@ -0,0 +1,16 @@ +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.junit.Test; + +public class ResourceTranslationNovaServerGroupsImplTest extends BaseResourceTranslationTest { + { + inputFilesPath = "/mock/services/heattotosca/novaservergroups/inputfiles"; + outputFilesPath = "/mock/services/heattotosca/novaservergroups/expectedoutputfiles"; + } + + @Test + public void testTranslate() throws Exception { + testTranslation(); + } + +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationResourceGroupImplTest.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationResourceGroupImplTest.java new file mode 100644 index 0000000000..de1b0bfe29 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/ResourceTranslationResourceGroupImplTest.java @@ -0,0 +1,110 @@ +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.openecomp.sdc.common.errors.CoreException; +import org.junit.Before; +import org.junit.Rule; +import org.junit.Test; +import org.junit.rules.ExpectedException; +import org.junit.runner.RunWith; +import org.mockito.runners.MockitoJUnitRunner; + +import java.io.IOException; + +/** + * @author shiria + * @since July 21, 2016. + */ +@RunWith(MockitoJUnitRunner.class) +public class ResourceTranslationResourceGroupImplTest extends BaseResourceTranslationTest { + @Rule + public ExpectedException thrown = ExpectedException.none(); + + @Override + @Before + public void setUp() throws IOException { + // do not delete this function. it prevents the superclass setup from running + } + + @Test + public void testTranslateResourceGroup() throws Exception { + inputFilesPath = "/mock/heat/nested/resource_group/inputs"; + outputFilesPath = "/mock/heat/nested/resource_group/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + @Test + public void testTranslateMultiResourceGroup() throws Exception { + inputFilesPath = "/mock/heat/nested/multiple_resource_groups/inputs"; + outputFilesPath = "/mock/heat/nested/multiple_resource_groups/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + @Test + public void testTranslateResourceGroupDynamicCount() throws Exception { + inputFilesPath = "/mock/heat/nested/resource_group_with_dynamic_count/inputs"; + outputFilesPath = "/mock/heat/nested/resource_group_with_dynamic_count/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + + @Test + public void testTranslatePortToNetNestedByResourceGroupConnection() throws Exception { + inputFilesPath = "/mock/services/heattotosca/porttonetresourcegroupconnection/inputfiles"; + outputFilesPath = + "/mock/services/heattotosca/porttonetresourcegroupconnection/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + @Test + public void testTranslatePortToNetSharedConnection() throws Exception { + inputFilesPath = "/mock/services/heattotosca/porttosharednetresourcegrouplinking/inputfiles"; + outputFilesPath = + "/mock/services/heattotosca/porttosharednetresourcegrouplinking/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + @Test + public void testTranslateSecurityGroupToSharedPortConnection() throws Exception { + inputFilesPath = + "/mock/services/heattotosca/securityruletosharedportresourcegrouplinking/inputfiles"; + outputFilesPath = + "/mock/services/heattotosca/securityruletosharedportresourcegrouplinking/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + @Test + public void testTranslateResourceGroupIndexVar() throws Exception { + inputFilesPath = "/mock/heat/nested/resourceGroupIndexVar/inputs"; + outputFilesPath = "/mock/heat/nested/resourceGroupIndexVar/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + @Test + public void testTranslateResourceGroupInvalidIndexVar() throws Exception { + thrown.expect(CoreException.class); + thrown.expectMessage( + "'index_var' property has invalid value. Actual value is '{get_param=index_parameter}' while 'String' value expected."); + + inputFilesPath = "/mock/heat/nested/resourceGroupInvalid/inputs"; + outputFilesPath = "/mock/heat/nested/resourceGroupInvalid/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + @Test + public void testTranslateMDNS() throws Exception { + inputFilesPath = "/mock/heat/nested/resourceGroupMDNS/inputs"; + outputFilesPath = "/mock/heat/nested/resourceGroupMDNS/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/SecurityGroupToNovaResourceConnectionTest.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/SecurityGroupToNovaResourceConnectionTest.java new file mode 100644 index 0000000000..ce55800d3a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/SecurityGroupToNovaResourceConnectionTest.java @@ -0,0 +1,24 @@ +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.junit.Before; +import org.junit.Test; + +import java.io.IOException; + +public class SecurityGroupToNovaResourceConnectionTest extends BaseResourceTranslationTest { + @Override + @Before + public void setUp() throws IOException { + // do not delete this function. it prevents the superclass setup from running + } + + @Test + public void testSecurityGroupToPortConnectionMultiConnection() throws Exception { + inputFilesPath = "/mock/services/heattotosca/securitygrouptonovaconnectionmulti/inputfiles"; + outputFilesPath = + "/mock/services/heattotosca/securitygrouptonovaconnectionmulti/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/SecurityRulesToPortResourceConnectionTest.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/SecurityRulesToPortResourceConnectionTest.java new file mode 100644 index 0000000000..a75e0133d9 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/impl/SecurityRulesToPortResourceConnectionTest.java @@ -0,0 +1,55 @@ +package org.openecomp.sdc.translator.services.heattotosca.impl; + +import org.junit.Before; +import org.junit.Test; + +import java.io.IOException; + +public class SecurityRulesToPortResourceConnectionTest extends BaseResourceTranslationTest { + @Override + @Before + public void setUp() throws IOException { + // do not delete this function. it prevents the superclass setup from running + } + + @Test + public void testTranslateSecurityRuleToPortNestedConnection() throws Exception { + inputFilesPath = + "/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportnestedconnection/inputfiles"; + outputFilesPath = + "/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportnestedconnection/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + @Test + public void testTranslateSecurityRuleToPortSharedPortNestedConnection() throws Exception { + inputFilesPath = + "/mock/services/heattotosca/securityrulestoportconnection/securityruletosharedportlinking/inputfiles"; + outputFilesPath = + "/mock/services/heattotosca/securityrulestoportconnection/securityruletosharedportlinking/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + @Test + public void testSecurityRuleToPortConnectionMultiConnection() throws Exception { + inputFilesPath = + "/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectionmulti/inputfiles"; + outputFilesPath = + "/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectionmulti/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + + @Test + public void testSecurityRuleToPortConnectionNestedGetResource() throws Exception { + inputFilesPath = + "/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles"; + outputFilesPath = + "/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/expectedoutputfiles"; + initTranslatorAndTranslate(); + testTranslation(); + } + +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/mapping/TranslatorHeatToToscaFunctionConverterTest.java b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/mapping/TranslatorHeatToToscaFunctionConverterTest.java new file mode 100644 index 0000000000..7fccd6c080 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/java/org/openecomp/sdc/translator/services/heattotosca/mapping/TranslatorHeatToToscaFunctionConverterTest.java @@ -0,0 +1,68 @@ +package org.openecomp.sdc.translator.services.heattotosca.mapping; + +import org.openecomp.sdc.heat.datatypes.model.HeatOrchestrationTemplate; +import org.openecomp.sdc.tosca.datatypes.model.NodeTemplate; +import org.openecomp.sdc.tosca.services.ToscaConstants; +import org.openecomp.sdc.tosca.services.ToscaFileOutputService; +import org.openecomp.sdc.tosca.services.impl.ToscaFileOutputServiceCsarImpl; +import org.openecomp.sdc.translator.services.heattotosca.TranslationContext; +import org.openecomp.core.utilities.file.FileUtils; +import org.junit.Assert; +import org.junit.Test; + +import java.util.HashMap; +import java.util.List; + +public class TranslatorHeatToToscaFunctionConverterTest { + + @Test + public void testGetFileWithExtensionFunction() { + String functionName = "get_file"; + Object function = "scripFileName.sh"; + String heatFileName = "heatFileName"; + HeatOrchestrationTemplate heatOrchestrationTemplate = new HeatOrchestrationTemplate(); + NodeTemplate nodeTemplate = new NodeTemplate(); + TranslationContext context = new TranslationContext(); + + testGetToscaFunctionForGetFile(functionName, function, heatFileName, heatOrchestrationTemplate, + nodeTemplate, context); + } + + @Test + public void testGetFileWithoutExtensionFunction() { + String functionName = "get_file"; + Object function = "scripFileName"; + String heatFileName = "heatFileName"; + HeatOrchestrationTemplate heatOrchestrationTemplate = new HeatOrchestrationTemplate(); + NodeTemplate nodeTemplate = new NodeTemplate(); + TranslationContext context = new TranslationContext(); + + //# route_targets: { "Fn::Split" : [ ",", Ref: route_targets ] } + testGetToscaFunctionForGetFile(functionName, function, heatFileName, heatOrchestrationTemplate, + nodeTemplate, context); + } + + private void testGetToscaFunctionForGetFile(String functionName, Object function, + String heatFileName, + HeatOrchestrationTemplate heatOrchestrationTemplate, + NodeTemplate nodeTemplate, + TranslationContext context) { + Object result = TranslatorHeatToToscaFunctionConverter + .getToscaFunction(functionName, function, heatFileName, heatOrchestrationTemplate, + nodeTemplate, context); + Assert.assertNotNull(((HashMap) result).get("get_artifact")); + List artifactParameters = (List) ((HashMap) result).get("get_artifact"); + Assert.assertNotNull(artifactParameters); + Assert.assertEquals(artifactParameters.size(), 2); + Assert.assertEquals(artifactParameters.get(0), ToscaConstants.MODELABLE_ENTITY_NAME_SELF); + Assert.assertEquals(artifactParameters.get(1), ((String) function).split("\\.")[0]); + + Assert.assertNotNull(nodeTemplate.getArtifacts()); + Assert.assertNotNull( + nodeTemplate.getArtifacts().get(FileUtils.getFileWithoutExtention((String) function))); + ToscaFileOutputService toscaFileOutputService = new ToscaFileOutputServiceCsarImpl(); + Assert.assertEquals( + nodeTemplate.getArtifacts().get(FileUtils.getFileWithoutExtention((String) function)) + .getFile(), "../" + toscaFileOutputService.getArtifactsFolderName() + "/" + function); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/ep-jsa-si/ep-jsa-si.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/ep-jsa-si/ep-jsa-si.env new file mode 100644 index 0000000000..d1d7d9625f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/ep-jsa-si/ep-jsa-si.env @@ -0,0 +1,14 @@ +parameters: + service_instance_name: ZRDM1LOGS01JSA + st_name: JSA-EP-Template + st_mode: in-network + st_type: firewall + st_image: MNS_JSA_2014R5.1-LATEST + st_flavor: lc.3xlarge + st_service_interface_type_list: management,left + st_shared_ip_list: False,True + st_static_routes_list: True,True + st_scaling: "True" + max_num_fw_instances: 24 + mgmt_net: 'default-domain:MNS-25180-L-01Shared:oam_direct_net_0' + jsa_net: 'default-domain:MNS-25180-L-01Shared:jsa_log_net_0' \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/ep-jsa-si/ep-jsa-si.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/ep-jsa-si/ep-jsa-si.yaml new file mode 100644 index 0000000000..d9f9e5b944 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/ep-jsa-si/ep-jsa-si.yaml @@ -0,0 +1,76 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + mgmt_net: + type: string + description: network name of OAM network + jsa_net: + type: string + description: network name of jsa log network + st_name: + type: string + description: service template name or ID + st_type: + type: string + description: service type + st_image: + type: string + description: Name of the image + st_flavor: + type: string + description: Flavor + st_service_interface_type_list: + type: string + description: List of interface types + st_shared_ip_list: + type: string + description: List of shared ip enabled-disabled + st_static_routes_list: + type: string + description: List of static routes enabled-disabled + st_scaling: + type: string + description: Indicates whether service scaling is enabled + st_mode: + type: string + description: service mode + max_num_fw_instances: + type: number + description: maximum number of firewall instances for scaling + service_instance_name: + type: string + description: service instance name + +resources: + service_template: + type: OS::Contrail::ServiceTemplate + properties: + name: { get_param: st_name } + service_mode: { get_param: st_mode } + service_type: { get_param: st_type } + image_name: { get_param: st_image } + flavor: { get_param: st_flavor } + service_interface_type_list: { "Fn::Split" : [ ",", Ref: st_service_interface_type_list ] } + shared_ip_list: { "Fn::Split" : [ ",", Ref: st_shared_ip_list ] } + static_routes_list: { "Fn::Split" : [ ",", Ref: st_static_routes_list ]} + service_scaling: { get_param: st_scaling } + + service_instance: + type: OS::Contrail::ServiceInstance + properties: + name: { get_param: service_instance_name } + service_template: { get_resource: service_template } + scale_out: + max_instances: { get_param: max_num_fw_instances } + interface_list: [ + { + virtual_network: {get_param: mgmt_net} + }, + { + virtual_network: {get_param: jsa_net} + }, + ] + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/ep-jsa-si/ep-jsa_net.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/ep-jsa-si/ep-jsa_net.env new file mode 100644 index 0000000000..9dd1cd441f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/ep-jsa-si/ep-jsa_net.env @@ -0,0 +1,4 @@ +parameters: + jsa_net_name: jsa_log_net_0 + jsa_cidr: 107.243.7.128/26 + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/ep-jsa-si/ep-jsa_net.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/ep-jsa-si/ep-jsa_net.yaml new file mode 100644 index 0000000000..1f7aec90fa --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/ep-jsa-si/ep-jsa_net.yaml @@ -0,0 +1,26 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + jsa_net_name: + type: string + description: network name of jsa log network + jsa_cidr: + type: string + description: CIDR of jsa log network + +resources: + jsa_net: + type: OS::Neutron::Net + properties: + name: {get_param: jsa_net_name} + shared: True + + jsa_subnet: + type: OS::Neutron::Subnet + properties: + network_id: {get_resource: jsa_net} + cidr: {get_param: jsa_cidr} + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/ep-jsa-si/master-jsa.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/ep-jsa-si/master-jsa.env new file mode 100644 index 0000000000..9170b98627 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/ep-jsa-si/master-jsa.env @@ -0,0 +1,6 @@ +parameters: + oam_net_name: oam_direct_net_0 + security_group_name: jsa_security_group + MASTER_names: ZRDM1LOGS01CSL001 + MASTER_image_name: MNS_JSA_2014R5.1-LATEST + MASTER_flavor_name: lc.4xlarge4 diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/ep-jsa-si/master-jsa.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/ep-jsa-si/master-jsa.yaml new file mode 100644 index 0000000000..6c6f52a681 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/ep-jsa-si/master-jsa.yaml @@ -0,0 +1,57 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-11-2016 (Authors: John Doe, user PROD) + +parameters: + oam_net_name: + type: string + description: network name of OAM network + security_group_name: + type: string + description: security group name of JSA + MASTER_names: + type: string + description: JSA MASTER instance name + MASTER_image_name: + type: string + description: JSA MASTER instance image name + MASTER_flavor_name: + type: string + description: the flavor name of JSA MASTER instance + +resources: + jsa_security_group: + type: OS::Neutron::SecurityGroup + properties: + description: ems security group + name: {get_param: security_group_name} + rules: [{"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": "::/0"}, + {"direction": egress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": "::/0"}, + {"direction": egress, "ethertype": IPv6, "protocol": icmp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv6, "protocol": icmp, "remote_ip_prefix": "::/0"} + ] + + + MASTER_instance: + type: OS::Nova::Server + properties: + name: {get_param: MASTER_names} + image: {get_param: MASTER_image_name} + flavor: {get_param: MASTER_flavor_name} + networks: + - port: {get_resource: MASTER_mgmt_port} + + MASTER_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + security_groups: [{get_resource: jsa_security_group}] diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..9e0e6efecd --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,236 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.nested-pcm_v0.1_2: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + pcm_flavor_name: + type: string + description: flavor name of PCRF CM instance + availabilityzone_name: + type: string + description: availabilityzone name + pcm_image_name: + type: string + description: PCRF CM image name + pcm_vol: + type: string + description: CPS Cluman Cinder Volume + security_group_name: + type: string + description: the name of security group + cps_net_ip: + type: string + description: CPS network ip + pcm_server_name: + type: string + description: PCRF CM server name + cps_net_name: + type: string + description: CPS network name + cps_net_mask: + type: string + description: CPS network mask + oam_net_ip: + type: string + oam_net_name: + type: string + description: OAM network name + attributes: + server_pcm_id: + type: string + description: the pcm nova service id + requirements: + - link_pcm_port_1: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - local_storage_server_pcm: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_pcm_port_0: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + endpoint_server_pcm: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + os_server_pcm: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + host_server_pcm: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + scalable_server_pcm: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + binding_server_pcm: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + attachment_pcm_port_0: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + attachment_pcm_port_1: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + org.openecomp.resource.abstract.nodes.heat.nested-pcm_v0.1: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + availabilityzone_name: + type: string + description: availabilityzone name + oam_net_gw: + type: string + description: CPS network gateway + pcm_image_name: + type: string + description: PCRF CM image name + security_group_name: + type: string + description: the name of security group + cps_net_ip: + type: string + description: CPS network ip + pcm_flavor_name: + type: string + description: flavor name of PCRF CM instance + pcm_vol: + type: string + description: CPS Cluman Cinder Volume + pcm_server_name: + type: string + description: PCRF CM server name + cps_net_name: + type: string + description: CPS network name + cps_net_mask: + type: string + description: CPS network mask + oam_net_ip: + type: string + description: OAM network ip + oam_net_mask: + type: string + description: CPS network mask + oam_net_name: + type: string + description: OAM network name + attributes: + server_pcm_id: + type: string + description: the pcm nova service id + requirements: + - link_pcm_port_1: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - local_storage_server_pcm: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_pcm_port_0: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + endpoint_server_pcm: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + os_server_pcm: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + host_server_pcm: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + scalable_server_pcm: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + binding_server_pcm: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + attachment_pcm_port_0: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + attachment_pcm_port_1: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..a0063b174e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,240 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + oam_net_ips: + label: OAM network ips + hidden: false + immutable: false + type: list + description: OAM network ips + entry_schema: + type: string + availabilityzone_name: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + oam_net_gw: + label: CPS network gateway + hidden: false + immutable: false + type: string + description: CPS network gateway + pcm_server_names: + label: PCRF CM server names + hidden: false + immutable: false + type: list + description: name of the PCRF CM instance + entry_schema: + type: string + pcm_image_name: + label: PCRF CM image name + hidden: false + immutable: false + type: string + description: PCRF CM image name + cps_net_ips: + label: CPS network ips + hidden: false + immutable: false + type: list + description: CPS network ips + entry_schema: + type: string + security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + pcm_volumes: + label: CPS Cluman Cinder Volume + hidden: false + immutable: false + type: list + description: CPS Cluman Cinder Volume + entry_schema: + type: string + pcm_flavor_name: + label: PCRF CM flavor name + hidden: false + immutable: false + type: string + description: flavor name of PCRF CM instance + cps_net_name: + label: CPS network name + hidden: false + immutable: false + type: string + description: CPS network name + cps_net_mask: + label: CPS network mask + hidden: false + immutable: false + type: string + description: CPS network mask + oam_net_mask: + label: CPS network mask + hidden: false + immutable: false + type: string + description: CPS network mask + oam_net_name: + label: OAM network name + hidden: false + immutable: false + type: string + description: OAM network name + node_templates: + server_pcm_002: + type: org.openecomp.resource.abstract.nodes.heat.nested-pcm_v0.1 + directives: + - substitutable + properties: + pcm_flavor_name: + get_input: pcm_flavor_name + service_template_filter: + substitute_service_template: nested-pcm_v0.1ServiceTemplate.yaml + availabilityzone_name: + get_input: availabilityzone_name + pcm_image_name: + get_input: pcm_image_name + pcm_vol: + get_input: + - pcm_volumes + - 0 + security_group_name: + get_input: security_group_name + pcm_server_name: + get_input: + - pcm_server_names + - 0 + server_pcm_001: + type: org.openecomp.resource.abstract.nodes.heat.nested-pcm_v0.1 + directives: + - substitutable + properties: + service_template_filter: + substitute_service_template: nested-pcm_v0.1ServiceTemplate.yaml + availabilityzone_name: + get_input: availabilityzone_name + oam_net_gw: + get_input: oam_net_gw + pcm_vol: + get_input: + - pcm_volumes + - 0 + security_group_name: + get_input: security_group_name + cps_net_ip: + get_input: + - cps_net_ips + - 0 + cps_net_name: + get_input: cps_net_name + cps_net_mask: + get_input: cps_net_mask + oam_net_ip: + get_input: + - oam_net_ips + - 0 + oam_net_mask: + get_input: oam_net_mask + oam_net_name: + get_input: oam_net_name + server_pcm_004: + type: org.openecomp.resource.abstract.nodes.heat.nested-pcm_v0.1_2 + directives: + - substitutable + properties: + service_template_filter: + substitute_service_template: nested-pcm_v0.1_2ServiceTemplate.yaml + availabilityzone_name: + get_input: availabilityzone_name + pcm_vol: + get_input: + - pcm_volumes + - 0 + security_group_name: + get_input: security_group_name + cps_net_ip: + get_input: + - cps_net_ips + - 0 + cps_net_name: + get_input: cps_net_name + cps_net_mask: + get_input: cps_net_mask + server_pcm_003: + type: org.openecomp.resource.abstract.nodes.heat.nested-pcm_v0.1 + directives: + - substitutable + properties: + service_template_filter: + substitute_service_template: nested-pcm_v0.1ServiceTemplate.yaml + availabilityzone_name: + get_input: availabilityzone_name + pcm_vol: + get_input: + - pcm_volumes + - 0 + security_group_name: + get_input: security_group_name + cps_net_ip: + get_input: + - cps_net_ips + - 0 + cps_net_name: + get_input: cps_net_name + cps_net_mask: + get_input: cps_net_mask + groups: + hot-nimbus-pcm_v0.4_2: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/hot-nimbus-pcm_v0.4_2.yaml + description: heat template that creates PCRF Cluman stack + members: + - server_pcm_004 + - server_pcm_003 + hot-nimbus-pcm_v0.4: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/hot-nimbus-pcm_v0.4.yaml + description: heat template that creates PCRF Cluman stack + members: + - server_pcm_002 + - server_pcm_001 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/expectedoutputfiles/nested-pcm_v0.1ServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/expectedoutputfiles/nested-pcm_v0.1ServiceTemplate.yaml new file mode 100644 index 0000000000..1b03021742 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/expectedoutputfiles/nested-pcm_v0.1ServiceTemplate.yaml @@ -0,0 +1,207 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested-pcm_v0.1 +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.pcm_server: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + availabilityzone_name: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + oam_net_gw: + label: CPS network gateway + hidden: false + immutable: false + type: string + description: CPS network gateway + pcm_image_name: + label: image name + hidden: false + immutable: false + type: string + description: PCRF CM image name + security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + cps_net_ip: + label: CPS network ip + hidden: false + immutable: false + type: string + description: CPS network ip + pcm_flavor_name: + label: PCRF CM flavor name + hidden: false + immutable: false + type: string + description: flavor name of PCRF CM instance + pcm_vol: + label: CPS Cluman Cinder Volume + hidden: false + immutable: false + type: string + description: CPS Cluman Cinder Volume + pcm_server_name: + label: PCRF CM server name + hidden: false + immutable: false + type: string + description: PCRF CM server name + cps_net_name: + label: CPS network name + hidden: false + immutable: false + type: string + description: CPS network name + cps_net_mask: + label: CPS network mask + hidden: false + immutable: false + type: string + description: CPS network mask + oam_net_ip: + label: OAM network ip + hidden: false + immutable: false + type: string + description: OAM network ip + oam_net_mask: + label: CPS network mask + hidden: false + immutable: false + type: string + description: CPS network mask + oam_net_name: + label: OAM network name + hidden: false + immutable: false + type: string + description: OAM network name + node_templates: + pcm_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: oam_net_ip + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_pcm + relationship: tosca.relationships.network.BindsTo + server_pcm: + type: org.openecomp.resource.vfc.nodes.heat.pcm_server + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + pcm_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: cps_net_ip + network: + get_input: cps_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_pcm + relationship: tosca.relationships.network.BindsTo + groups: + nested-pcm_v0.1: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested-pcm_v0.1.yaml + description: heat template that creates PCRF Cluman stack + members: + - pcm_port_1 + - server_pcm + - pcm_port_0 + outputs: + server_pcm_id: + description: the pcm nova service id + value: server_pcm + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested-pcm_v0.1 + capabilities: + endpoint_server_pcm: + - server_pcm + - endpoint + os_server_pcm: + - server_pcm + - os + host_server_pcm: + - server_pcm + - host + scalable_server_pcm: + - server_pcm + - scalable + binding_server_pcm: + - server_pcm + - binding + attachment_pcm_port_0: + - pcm_port_0 + - attachment + attachment_pcm_port_1: + - pcm_port_1 + - attachment + requirements: + link_pcm_port_0: + - pcm_port_0 + - link + link_pcm_port_1: + - pcm_port_1 + - link + local_storage_server_pcm: + - server_pcm + - local_storage \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/expectedoutputfiles/nested-pcm_v0.1_2ServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/expectedoutputfiles/nested-pcm_v0.1_2ServiceTemplate.yaml new file mode 100644 index 0000000000..34d0c6d899 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/expectedoutputfiles/nested-pcm_v0.1_2ServiceTemplate.yaml @@ -0,0 +1,193 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested-pcm_v0.1_2 +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.pcm_server: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + pcm_flavor_name: + label: PCRF CM flavor name + hidden: false + immutable: false + type: string + description: flavor name of PCRF CM instance + availabilityzone_name: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + pcm_image_name: + label: image name + hidden: false + immutable: false + type: string + description: PCRF CM image name + pcm_vol: + label: CPS Cluman Cinder Volume + hidden: false + immutable: false + type: string + description: CPS Cluman Cinder Volume + security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + cps_net_ip: + label: CPS network ip + hidden: false + immutable: false + type: string + description: CPS network ip + pcm_server_name: + label: PCRF CM server name + hidden: false + immutable: false + type: string + description: PCRF CM server name + cps_net_name: + label: CPS network name + hidden: false + immutable: false + type: string + description: CPS network name + cps_net_mask: + label: CPS network mask + hidden: false + immutable: false + type: string + description: CPS network mask + oam_net_ip: + hidden: false + immutable: false + type: string + oam_net_name: + label: OAM network name + hidden: false + immutable: false + type: string + description: OAM network name + node_templates: + pcm_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: oam_net_ip + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_pcm + relationship: tosca.relationships.network.BindsTo + server_pcm: + type: org.openecomp.resource.vfc.nodes.heat.pcm_server + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + pcm_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: cps_net_ip + network: + get_input: cps_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_pcm + relationship: tosca.relationships.network.BindsTo + groups: + nested-pcm_v0.1_2: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested-pcm_v0.1_2.yaml + description: heat template that creates PCRF Cluman stack + members: + - pcm_port_1 + - server_pcm + - pcm_port_0 + outputs: + server_pcm_id: + description: the pcm nova service id + value: server_pcm + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested-pcm_v0.1_2 + capabilities: + endpoint_server_pcm: + - server_pcm + - endpoint + os_server_pcm: + - server_pcm + - os + host_server_pcm: + - server_pcm + - host + scalable_server_pcm: + - server_pcm + - scalable + binding_server_pcm: + - server_pcm + - binding + attachment_pcm_port_0: + - pcm_port_0 + - attachment + attachment_pcm_port_1: + - pcm_port_1 + - attachment + requirements: + link_pcm_port_0: + - pcm_port_0 + - link + link_pcm_port_1: + - pcm_port_1 + - link + local_storage_server_pcm: + - server_pcm + - local_storage \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/inputs/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/inputs/MANIFEST.json new file mode 100644 index 0000000000..b32b92ca11 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/inputs/MANIFEST.json @@ -0,0 +1,30 @@ +{ + "name": "vEP_JSA_Net", + "description": "Version 2.0 02-09-2016 (Authors: John Doe, user PROD)", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pcm_v0.4.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pcm_v0.4.env", + "type": "HEAT_ENV" + } + ] + },{ + "file": "nested-pcm_v0.1.yaml", + "type": "HEAT" + },{ + "file": "hot-nimbus-pcm_v0.4_2.yaml", + "type": "HEAT" + },{ + "file": "nested-pcm_v0.1_2.yaml", + "type": "HEAT" + }, + { + "file": "nimbus-ethernet", + "type": "OTHER" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/inputs/hot-nimbus-pcm_v0.4.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/inputs/hot-nimbus-pcm_v0.4.env new file mode 100644 index 0000000000..78cc03e2ea --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/inputs/hot-nimbus-pcm_v0.4.env @@ -0,0 +1,14 @@ +parameters: + pcm_server_names: ZRDM1PCRF01PCM001 + pcm_image_name: rhel2 + pcm_flavor_name: cps + availabilityzone_name: nova + cps_net_name: int_pcrf_net_0 + cps_net_ips: 172.26.16.113 + cps_net_mask: 255.255.255.0 + oam_net_name: oam_protected_net_0 + oam_net_ips: 107.239.64.121 + oam_net_gw: 107.239.64.1 + oam_net_mask: 255.255.255.0 + pcm_volumes: 249cb355-8fdf-4382-9c3c-a2ebe767d45b + security_group_name: nimbus_security_group diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/inputs/hot-nimbus-pcm_v0.4.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/inputs/hot-nimbus-pcm_v0.4.yaml new file mode 100644 index 0000000000..f7d050790f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/inputs/hot-nimbus-pcm_v0.4.yaml @@ -0,0 +1,82 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Cluman stack + +parameters: + pcm_server_names: + type: comma_delimited_list + label: PCRF CM server names + description: name of the PCRF CM instance + pcm_image_name: + type: string + label: PCRF CM image name + description: PCRF CM image name + pcm_flavor_name: + type: string + label: PCRF CM flavor name + description: flavor name of PCRF CM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + cps_net_name: + type: string + label: CPS network name + description: CPS network name + cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + oam_net_name: + type: string + label: OAM network name + description: OAM network name + oam_net_ips: + type: comma_delimited_list + label: OAM network ips + description: OAM network ips + oam_net_gw: + type: string + label: CPS network gateway + description: CPS network gateway + oam_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcm_volumes: + type: comma_delimited_list + label: CPS Cluman Cinder Volume + description: CPS Cluman Cinder Volume + security_group_name: + type: string + label: security group name + description: the name of security group + +resources: + server_pcm_001: + type: nested-pcm_v0.1.yaml + properties: + availabilityzone_name: { get_param: availabilityzone_name } + security_group_name: { get_param: security_group_name } + pcm_vol: { get_param: [pcm_volumes, 0] } + cps_net_name: { get_param: cps_net_name } + cps_net_ip: { get_param: [cps_net_ips, 0] } + cps_net_mask: { get_param: cps_net_mask } + oam_net_name: { get_param: oam_net_name } + oam_net_ip: { get_param: [oam_net_ips, 0] } + oam_net_mask: { get_param: oam_net_mask } + oam_net_gw: { get_param: oam_net_gw } + + server_pcm_002: + type: nested-pcm_v0.1.yaml + properties: + pcm_server_name: { get_param: [pcm_server_names, 0] } + pcm_image_name: { get_param: pcm_image_name } + pcm_flavor_name: { get_param: pcm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + security_group_name: { get_param: security_group_name } + pcm_vol: { get_param: [pcm_volumes, 0] } diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/inputs/hot-nimbus-pcm_v0.4_2.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/inputs/hot-nimbus-pcm_v0.4_2.yaml new file mode 100644 index 0000000000..b59df84764 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/inputs/hot-nimbus-pcm_v0.4_2.yaml @@ -0,0 +1,79 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Cluman stack + +parameters: + pcm_server_names: + type: comma_delimited_list + label: PCRF CM server names + description: name of the PCRF CM instance + pcm_image_name: + type: string + label: PCRF CM image name + description: PCRF CM image name + pcm_flavor_name: + type: string + label: PCRF CM flavor name + description: flavor name of PCRF CM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + cps_net_name: + type: string + label: CPS network name + description: CPS network name + cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + oam_net_name: + type: string + label: OAM network name + description: OAM network name + oam_net_ips: + type: comma_delimited_list + label: OAM network ips + description: OAM network ips + oam_net_gw: + type: string + label: CPS network gateway + description: CPS network gateway + oam_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcm_volumes: + type: comma_delimited_list + label: CPS Cluman Cinder Volume + description: CPS Cluman Cinder Volume + security_group_name: + type: string + label: security group name + description: the name of security group + +resources: + server_pcm_003: + type: nested-pcm_v0.1.yaml + properties: + availabilityzone_name: { get_param: availabilityzone_name } + security_group_name: { get_param: security_group_name } + pcm_vol: { get_param: [pcm_volumes, 0] } + cps_net_name: { get_param: cps_net_name } + cps_net_ip: { get_param: [cps_net_ips, 0] } + cps_net_mask: { get_param: cps_net_mask } + + server_pcm_004: + type: nested-pcm_v0.1_2.yaml + properties: + availabilityzone_name: { get_param: availabilityzone_name } + security_group_name: { get_param: security_group_name } + pcm_vol: { get_param: [pcm_volumes, 0] } + cps_net_name: { get_param: cps_net_name } + cps_net_ip: { get_param: [cps_net_ips, 0] } + cps_net_mask: { get_param: cps_net_mask } + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/inputs/nested-pcm_v0.1.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/inputs/nested-pcm_v0.1.yaml new file mode 100644 index 0000000000..109bf86d24 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/inputs/nested-pcm_v0.1.yaml @@ -0,0 +1,114 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Cluman stack + +parameters: + pcm_server_name: + type: string + label: PCRF CM server name + description: PCRF CM server name + pcm_image_name: + type: string + label: image name + description: PCRF CM image name + pcm_flavor_name: + type: string + label: PCRF CM flavor name + description: flavor name of PCRF CM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + cps_net_name: + type: string + label: CPS network name + description: CPS network name + cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + oam_net_name: + type: string + label: OAM network name + description: OAM network name + oam_net_ip: + type: string + label: OAM network ip + description: OAM network ip + oam_net_gw: + type: string + label: CPS network gateway + description: CPS network gateway + oam_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcm_vol: + type: string + label: CPS Cluman Cinder Volume + description: CPS Cluman Cinder Volume + security_group_name: + type: string + label: security group name + description: the name of security group + +resources: + network: + type: net + script_init: + type: OS:INIT + server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + server_pcm: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcm_server_name } + image: { get_param: pcm_image_name } + flavor: { get_param: pcm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcm_port_0} + - port: { get_resource: pcm_port_1} + block_device_mapping: + - device_name: vdb + volume_id: { get_param: pcm_vol} + user_data_format: RAW + user_data: + get_resource: server_init + + pcm_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: cps_net_name } + fixed_ips: + - ip_address: { get_param: cps_net_ip } + security_groups: [{ get_param: security_group_name }] + + pcm_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: + - ip_address: { get_param: oam_net_ip } + security_groups: [{ get_param: security_group_name }] + + #pcm_vol_attachment: + # type: OS:: Cinder::VolumeAttachment + # properties: + # volume_id: { get_param: pcm_vol } + # mountpoint: /dev/vdb + # instance_uuid: { get_resource: server_pcm } +outputs: + server_pcm_id: + description: the pcm nova service id + value: { get_resource: server_pcm } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/inputs/nested-pcm_v0.1_2.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/inputs/nested-pcm_v0.1_2.yaml new file mode 100644 index 0000000000..3f117a8410 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/inputs/nested-pcm_v0.1_2.yaml @@ -0,0 +1,120 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Cluman stack + +parameters: + pcm_server_name: + type: string + label: PCRF CM server name + description: PCRF CM server name + pcm_image_name: + type: string + label: image name + description: PCRF CM image name + pcm_flavor_name: + type: string + label: PCRF CM flavor name + description: flavor name of PCRF CM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + cps_net_name: + type: string + label: CPS network name + description: CPS network name + cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcm_vol: + type: string + label: CPS Cluman Cinder Volume + description: CPS Cluman Cinder Volume + security_group_name: + type: string + label: security group name + description: the name of security group + oam_net_name: + type: string + label: OAM network name + description: OAM network name + oam_net_ip: + type: string +resources: + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + template: { get_file: "file:///nimbus-ethernet" } + params: + $dev: eth0 + $ip: { get_param: cps_net_ip } + $netmask: { get_param: cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + - ifdown eth1 && ifup eth1 + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + server_pcm: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcm_server_name } + image: { get_param: pcm_image_name } + flavor: { get_param: pcm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcm_port_0} + - port: { get_resource: pcm_port_1} + block_device_mapping: + - device_name: vdb + volume_id: { get_param: pcm_vol} + user_data_format: RAW + user_data: + get_resource: server_init + + pcm_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: cps_net_name } + fixed_ips: + - ip_address: { get_param: cps_net_ip } + security_groups: [{ get_param: security_group_name }] + + pcm_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: + - ip_address: { get_param: oam_net_ip } + security_groups: [{ get_param: security_group_name }] + + #pcm_vol_attachment: + # type: OS:: Cinder::VolumeAttachment + # properties: + # volume_id: { get_param: pcm_vol } + # mountpoint: /dev/vdb + # instance_uuid: { get_resource: server_pcm } +outputs: + server_pcm_id: + description: the pcm nova service id + value: { get_resource: server_pcm } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/inputs/nimbus-ethernet b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multi/inputs/nimbus-ethernet new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multiple_resource_groups/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multiple_resource_groups/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..1b1c4dd621 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multiple_resource_groups/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,166 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.mvs.nested.heat: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + vf_module_id: + type: string + description: Unique ID for this VF_MODULE instance + vf_name: + type: string + description: The VF Name; defaults to VMVM for the virtual MVM VNF. + constraints: + - pattern: '[a-zA-Z0-9]+' + - max_length: 4 + - min_length: 4 + cloud_zone_id: + type: string + description: The cloud zone for this VF instance + vf_instance_num: + type: string + description: The number for this VF instance + constraints: + - pattern: '[0-9]+' + - max_length: 2 + - min_length: 2 + virtual_mgmt_ip_0: + type: string + description: Virtual management network ip address + indx: + type: float + description: Index of the current instance + mvs_mgmt_ip_0: + type: list + description: List of Management network IP addresses for IPv4 + entry_schema: + type: string + flavor: + type: string + description: Server flavor + constraints: [ + ] + key_name: + type: string + description: SSH key name + constraints: [ + ] + vnf_id: + type: string + description: Unique ID for this VF instance + availability_zone_0: + type: list + description: List of Availability Zone IDs or Names + entry_schema: + type: string + mgmt_net_id: + type: string + description: Neutron UUID for the Management network + constraints: [ + ] + vm_instance_num: + type: list + description: VM instance number list must be a list of three-digit numeric value + entry_schema: + type: string + bootimage: + type: string + description: Master bootimage volume id + sec_groups: + type: list + description: Security groups + entry_schema: + type: string + vf_component: + type: string + description: The component that this VF instance is running + constraints: + - pattern: '[a-zA-Z0-9]+' + - max_length: 3 + - min_length: 3 + requirements: + - local_storage_vnfci: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_mgmt_port: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + os_vnfci: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + attachment_mgmt_port: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + endpoint_vnfci: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + host_vnfci: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + binding_vnfci: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + attachment_boot_volume: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + scalable_vnfci: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + attachment_data_volume: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multiple_resource_groups/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multiple_resource_groups/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..ffddcce43c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multiple_resource_groups/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,240 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + vf_module_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VF_MODULE instance + vf_name: + hidden: false + immutable: false + type: string + description: The VF Name; defaults to VMVM for the virtual MVM VNF. + constraints: + - pattern: '[a-zA-Z0-9]+' + - max_length: 4 + - min_length: 4 + cloud_zone_id: + hidden: false + immutable: false + type: string + description: The cloud zone for this VF instance + vf_instance_num: + hidden: false + immutable: false + type: string + description: The number for this VF instance + constraints: + - pattern: '[0-9]+' + - max_length: 2 + - min_length: 2 + virtual_mgmt_ip_0: + hidden: false + immutable: false + type: string + description: Virtual management network ip address + mvs_mgmt_ip_0: + hidden: false + immutable: false + type: list + description: List of Management network IP addresses for IPv4 + entry_schema: + type: string + flavor: + hidden: false + immutable: false + type: string + description: Server flavor + constraints: [ + ] + key_name: + hidden: false + immutable: false + type: string + description: SSH key name + constraints: [ + ] + vnf_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VF instance + availability_zone_0: + hidden: false + immutable: false + type: list + description: List of Availability Zone IDs or Names + entry_schema: + type: string + mgmt_net_id: + hidden: false + immutable: false + type: string + description: Neutron UUID for the Management network + constraints: [ + ] + vm_instance_num: + hidden: false + immutable: false + type: list + description: VM instance number list must be a list of three-digit numeric value + entry_schema: + type: string + bootimage: + hidden: false + immutable: false + type: string + description: Master bootimage volume id + sec_groups: + hidden: false + immutable: false + type: list + description: Security groups + entry_schema: + type: string + vf_component: + hidden: false + immutable: false + type: string + description: The component that this VF instance is running + constraints: + - pattern: '[a-zA-Z0-9]+' + - max_length: 3 + - min_length: 3 + num_instances: + hidden: false + immutable: false + type: float + description: number of instance of the VF_module + node_templates: + mvs_modules: + type: org.openecomp.resource.abstract.nodes.heat.mvs.nested.heat + directives: + - substitutable + properties: + vf_module_id: + get_input: vf_module_id + vf_name: + get_input: vf_name + cloud_zone_id: + get_input: cloud_zone_id + vf_instance_num: + get_input: vf_instance_num + virtual_mgmt_ip_0: + get_input: virtual_mgmt_ip_0 + indx: + get_property: + - SELF + - service_template_filter + - index_value + mvs_mgmt_ip_0: + get_input: mvs_mgmt_ip_0 + flavor: + get_input: flavor + key_name: + get_input: key_name + service_template_filter: + substitute_service_template: mvs.nested.heatServiceTemplate.yaml + count: + get_input: num_instances + mandatory: false + vnf_id: + get_input: vnf_id + availability_zone_0: + get_input: availability_zone_0 + mgmt_net_id: + get_input: mgmt_net_id + vm_instance_num: + get_input: vm_instance_num + bootimage: + get_input: bootimage + sec_groups: + get_input: sec_groups + vf_component: + get_input: vf_component + mvs_modules_same_nested_heat_file_no_count: + type: org.openecomp.resource.abstract.nodes.heat.mvs.nested.heat + directives: + - substitutable + properties: + vf_module_id: + get_input: vf_module_id + vf_name: + get_input: vf_name + cloud_zone_id: + get_input: cloud_zone_id + vf_instance_num: + get_input: vf_instance_num + virtual_mgmt_ip_0: + get_input: virtual_mgmt_ip_0 + indx: + get_property: + - SELF + - service_template_filter + - index_value + mvs_mgmt_ip_0: + get_input: mvs_mgmt_ip_0 + flavor: + get_input: flavor + key_name: + get_input: key_name + service_template_filter: + substitute_service_template: mvs.nested.heatServiceTemplate.yaml + count: 1 + mandatory: true + vnf_id: + get_input: vnf_id + availability_zone_0: + get_input: availability_zone_0 + mgmt_net_id: + get_input: mgmt_net_id + vm_instance_num: + get_input: vm_instance_num + bootimage: + get_input: bootimage + sec_groups: + get_input: sec_groups + vf_component: + get_input: vf_component + groups: + mvs.vfmodule.heat: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/mvs.vfmodule.heat.yaml + description: | + Metaswitch MVS (Metaview Server) + members: + - mvs_modules + - mvs_modules_same_nested_heat_file_no_count \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multiple_resource_groups/expectedoutputfiles/mvs.nested.heatServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multiple_resource_groups/expectedoutputfiles/mvs.nested.heatServiceTemplate.yaml new file mode 100644 index 0000000000..315318d4f6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multiple_resource_groups/expectedoutputfiles/mvs.nested.heatServiceTemplate.yaml @@ -0,0 +1,320 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: mvs.nested.heat +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.vnfci: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + vf_module_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VF_MODULE instance + vf_name: + hidden: false + immutable: false + type: string + description: The VF Name; defaults to VMVM for the virtual MVM VNF. + constraints: + - pattern: '[a-zA-Z0-9]+' + - max_length: 4 + - min_length: 4 + cloud_zone_id: + hidden: false + immutable: false + type: string + description: The cloud zone for this VF instance + vf_instance_num: + hidden: false + immutable: false + type: string + description: The number for this VF instance + constraints: + - pattern: '[0-9]+' + - max_length: 2 + - min_length: 2 + virtual_mgmt_ip_0: + hidden: false + immutable: false + type: string + description: Virtual management network ip address + indx: + hidden: false + immutable: false + type: float + description: Index of the current instance + mvs_mgmt_ip_0: + hidden: false + immutable: false + type: list + description: List of Management network IP addresses for IPv4 + entry_schema: + type: string + flavor: + hidden: false + immutable: false + type: string + description: Server flavor + constraints: [ + ] + key_name: + hidden: false + immutable: false + type: string + description: SSH key name + constraints: [ + ] + vnf_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VF instance + availability_zone_0: + hidden: false + immutable: false + type: list + description: List of Availability Zone IDs or Names + entry_schema: + type: string + mgmt_net_id: + hidden: false + immutable: false + type: string + description: Neutron UUID for the Management network + constraints: [ + ] + vm_instance_num: + hidden: false + immutable: false + type: list + description: VM instance number list must be a list of three-digit numeric value + entry_schema: + type: string + bootimage: + hidden: false + immutable: false + type: string + description: Master bootimage volume id + sec_groups: + hidden: false + immutable: false + type: list + description: Security groups + entry_schema: + type: string + vf_component: + hidden: false + immutable: false + type: string + description: The component that this VF instance is running + constraints: + - pattern: '[a-zA-Z0-9]+' + - max_length: 3 + - min_length: 3 + node_templates: + boot_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + availability_zone: + Fn::Select: + - get_input: indx + - get_input: + - availability_zone_0 + image: + get_input: bootimage + size: 35*1024 + name: + str_replace: + template: Z$CLOUD_ZONE_ID$VF_NAME$VF_INSTANCE_NUM$VF_COMPONENT$VM_INSTANCE_NUM-boot-volume + params: + $VF_NAME: + get_input: vf_name + $CLOUD_ZONE_ID: + get_input: cloud_zone_id + $VM_INSTANCE_NUM: + Fn::Select: + - get_input: indx + - get_input: + - vm_instance_num + $VF_COMPONENT: + get_input: vf_component + $VF_INSTANCE_NUM: + get_input: vf_instance_num + vnfci: + type: org.openecomp.resource.vfc.nodes.heat.vnfci + properties: + flavor: + get_input: flavor + key_name: + get_input: key_name + availability_zone: + Fn::Select: + - get_input: indx + - get_input: + - availability_zone_0 + name: + str_replace: + template: Z$CLOUD_ZONE_ID$VF_NAME$VF_INSTANCE_NUM$VF_COMPONENT$VM_INSTANCE_NUM + params: + $VF_NAME: + get_input: vf_name + $CLOUD_ZONE_ID: + get_input: cloud_zone_id + $VM_INSTANCE_NUM: + Fn::Select: + - get_input: indx + - get_input: + - vm_instance_num + $VF_COMPONENT: + get_input: vf_component + $VF_INSTANCE_NUM: + get_input: vf_instance_num + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: boot_volume + relationship: tosca.relationships.AttachesTo + - local_storage: + capability: tosca.capabilities.Attachment + node: data_volume + relationship: tosca.relationships.AttachesTo + data_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + availability_zone: + Fn::Select: + - get_input: indx + - get_input: + - availability_zone_0 + size: 265*1024 + name: + str_replace: + template: Z$CLOUD_ZONE_ID$VF_NAME$VF_INSTANCE_NUM$VF_COMPONENT$VM_INSTANCE_NUM-data-volume + params: + $VF_NAME: + get_input: vf_name + $CLOUD_ZONE_ID: + get_input: cloud_zone_id + $VM_INSTANCE_NUM: + Fn::Select: + - get_input: indx + - get_input: + - vm_instance_num + $VF_COMPONENT: + get_input: vf_component + $VF_INSTANCE_NUM: + get_input: vf_instance_num + mgmt_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: sec_groups + fixed_ips: + - ip_address: + Fn::Select: + - get_input: indx + - get_input: + - get_input: mvs_mgmt_ip_0 + allowed_address_pairs: + - ip_address: + get_input: virtual_mgmt_ip_0 + name: + str_replace: + template: Z$CLOUD_ZONE_ID$VF_NAME$VF_INSTANCE_NUM$VF_COMPONENT$VM_INSTANCE_NUM-mgmt-port + params: + $VF_NAME: + get_input: vf_name + $CLOUD_ZONE_ID: + get_input: cloud_zone_id + $VM_INSTANCE_NUM: + Fn::Select: + - get_input: indx + - get_input: + - vm_instance_num + $VF_COMPONENT: + get_input: vf_component + $VF_INSTANCE_NUM: + get_input: vf_instance_num + network: + get_input: mgmt_net_id + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: vnfci + relationship: tosca.relationships.network.BindsTo + groups: + mvs.nested.heat: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/mvs.nested.heat.yaml + description: | + Metaswitch MVS (Metaview Server) + members: + - boot_volume + - vnfci + - data_volume + - mgmt_port + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.mvs.nested.heat + capabilities: + os_vnfci: + - vnfci + - os + attachment_mgmt_port: + - mgmt_port + - attachment + endpoint_vnfci: + - vnfci + - endpoint + host_vnfci: + - vnfci + - host + binding_vnfci: + - vnfci + - binding + attachment_boot_volume: + - boot_volume + - attachment + scalable_vnfci: + - vnfci + - scalable + attachment_data_volume: + - data_volume + - attachment + requirements: + local_storage_vnfci: + - vnfci + - local_storage + link_mgmt_port: + - mgmt_port + - link \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multiple_resource_groups/inputs/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multiple_resource_groups/inputs/MANIFEST.json new file mode 100644 index 0000000000..c7729c8653 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multiple_resource_groups/inputs/MANIFEST.json @@ -0,0 +1,19 @@ +{ + "name": "mvs.vfmodule.heat.yaml", + "description": "Metaswitch MVS (Metaview Server)", + "version": "2013-05-23", + "data": [ + { + "file": "mvs.vfmodule.heat.yaml", + "type": "HEAT", + "data": [ + ] + }, + { + "file": "mvs.nested.heat.yaml", + "type": "HEAT", + "data": [ + ] + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multiple_resource_groups/inputs/mvs.nested.heat.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multiple_resource_groups/inputs/mvs.nested.heat.yaml new file mode 100644 index 0000000000..8ddc5c6488 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multiple_resource_groups/inputs/mvs.nested.heat.yaml @@ -0,0 +1,165 @@ +heat_template_version: 2013-05-23 + +description: > + Metaswitch MVS (Metaview Server) + +parameters: + cloud_zone_id: + type: string + description: The cloud zone for this VF instance + vf_name: + type: string + description: The VF Name; defaults to VMVM for the virtual MVM VNF. + constraints: + - allowed_pattern: "[a-zA-Z0-9]+" + - length: { min: 4, max: 4 } + description: Each VF will have a 4-character alphanumeric identifier + vf_instance_num: + type: string + description: The number for this VF instance + constraints: + - allowed_pattern: "[0-9]+" + - length: { min: 2, max: 2 } + description: VF instance number must be a two-digit numeric value + vf_component: + type: string + description: The component that this VF instance is running + constraints: + - allowed_pattern: "[a-zA-Z0-9]+" + - length: { min: 3, max: 3 } + description: Each VF component will have a 3-character alphanumeric identifier + vm_instance_num: + type: comma_delimited_list + description: VM instance number list must be a list of three-digit numeric value + vnf_id: + type: string + description: Unique ID for this VF instance + vf_module_id: + type: string + description: Unique ID for this VF_MODULE instance + bootimage: + type: string + description: Master bootimage volume id + flavor: + type: string + description: Server flavor + constraints: + - custom_constraint: nova.flavor + key_name: + type: string + description: SSH key name + constraints: + - custom_constraint: nova.keypair + + availability_zone_0: + type: comma_delimited_list + description: List of Availability Zone IDs or Names + + sec_groups: + type: comma_delimited_list + description: Security groups + mgmt_net_id: + type: string + description: Neutron UUID for the Management network + constraints: + - custom_constraint: neutron.network + virtual_mgmt_ip_0: + type: string + description: Virtual management network ip address + + mvs_mgmt_ip_0: + type: comma_delimited_list + description: List of Management network IP addresses for IPv4 + + indx: + type: number + description: Index of the current instance + +resources: + mgmt_port: + type: OS::Neutron::Port + properties: + name: + str_replace: + template: Z$CLOUD_ZONE_ID$VF_NAME$VF_INSTANCE_NUM$VF_COMPONENT$VM_INSTANCE_NUM-mgmt-port + params: + $CLOUD_ZONE_ID: { get_param: cloud_zone_id } + $VF_NAME: { get_param: vf_name } + $VF_INSTANCE_NUM: { get_param: vf_instance_num } + $VF_COMPONENT: { get_param: vf_component } + $VM_INSTANCE_NUM: { "Fn::Select" : [ { get_param: indx }, { get_param: [vm_instance_num] } ] } + network_id: { get_param: mgmt_net_id } + security_groups: [{ get_param: sec_groups }] + + fixed_ips: + - ip_address: { "Fn::Select" : [ { get_param: indx }, { get_param: [{ get_param: mvs_mgmt_ip_0 }] } ] } + + allowed_address_pairs: + - ip_address: { get_param: virtual_mgmt_ip_0 } + + boot_volume: + type: OS::Cinder::Volume + properties: + size: 35 + name: + str_replace: + template: Z$CLOUD_ZONE_ID$VF_NAME$VF_INSTANCE_NUM$VF_COMPONENT$VM_INSTANCE_NUM-boot-volume + params: + $CLOUD_ZONE_ID: { get_param: cloud_zone_id } + $VF_NAME: { get_param: vf_name } + $VF_INSTANCE_NUM: { get_param: vf_instance_num } + $VF_COMPONENT: { get_param: vf_component } + $VM_INSTANCE_NUM: { "Fn::Select" : [ { get_param: indx }, { get_param: [vm_instance_num] } ] } + + image: { get_param: bootimage } + + + availability_zone: { "Fn::Select" : [ { get_param: indx }, { get_param: [availability_zone_0] } ] } + + + data_volume: + type: OS::Cinder::Volume + properties: + size: 265 + name: + str_replace: + template: Z$CLOUD_ZONE_ID$VF_NAME$VF_INSTANCE_NUM$VF_COMPONENT$VM_INSTANCE_NUM-data-volume + params: + $CLOUD_ZONE_ID: { get_param: cloud_zone_id } + $VF_NAME: { get_param: vf_name } + $VF_INSTANCE_NUM: { get_param: vf_instance_num } + $VF_COMPONENT: { get_param: vf_component } + $VM_INSTANCE_NUM: { "Fn::Select" : [ { get_param: indx }, { get_param: [vm_instance_num] } ] } + + availability_zone: { "Fn::Select" : [ { get_param: indx }, { get_param: [availability_zone_0] } ] } + + + vnfci: + type: OS::Nova::Server + properties: + name: + str_replace: + template: Z$CLOUD_ZONE_ID$VF_NAME$VF_INSTANCE_NUM$VF_COMPONENT$VM_INSTANCE_NUM + params: + $CLOUD_ZONE_ID: { get_param: cloud_zone_id } + $VF_NAME: { get_param: vf_name } + $VF_INSTANCE_NUM: { get_param: vf_instance_num } + $VF_COMPONENT: { get_param: vf_component } + $VM_INSTANCE_NUM: { "Fn::Select" : [ { get_param: indx }, { get_param: [vm_instance_num] } ] } + block_device_mapping: + - device_name: vda + volume_id: { get_resource: boot_volume } + delete_on_termination: false + - device_name: vdb + volume_id: { get_resource: data_volume } + delete_on_termination: false + flavor: { get_param: flavor } + key_name: { get_param: key_name } + networks: + - port: { get_resource: mgmt_port } + + availability_zone: { "Fn::Select" : [ { get_param: indx }, { get_param: [availability_zone_0] } ] } + + metadata: + vnf_id: { get_param: vnf_id } + vf_module_id: { get_param: vf_module_id } diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multiple_resource_groups/inputs/mvs.vfmodule.heat.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multiple_resource_groups/inputs/mvs.vfmodule.heat.yaml new file mode 100644 index 0000000000..55c98053a4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/multiple_resource_groups/inputs/mvs.vfmodule.heat.yaml @@ -0,0 +1,158 @@ +heat_template_version: 2013-05-23 + +description: > + Metaswitch MVS (Metaview Server) + +parameters: + cloud_zone_id: + type: string + description: The cloud zone for this VF instance + vf_name: + type: string + description: The VF Name; defaults to VMVM for the virtual MVM VNF. + constraints: + - allowed_pattern: "[a-zA-Z0-9]+" + - length: { min: 4, max: 4 } + description: Each VF will have a 4-character alphanumeric identifier + vf_instance_num: + type: string + description: The number for this VF instance + constraints: + - allowed_pattern: "[0-9]+" + - length: { min: 2, max: 2 } + description: VF instance number must be a two-digit numeric value + vf_component: + type: string + description: The component that this VF instance is running + constraints: + - allowed_pattern: "[a-zA-Z0-9]+" + - length: { min: 3, max: 3 } + description: Each VF component will have a 3-character alphanumeric identifier + vm_instance_num: + type: comma_delimited_list + description: VM instance number list must be a list of three-digit numeric value + vnf_id: + type: string + description: Unique ID for this VF instance + vf_module_id: + type: string + description: Unique ID for this VF_MODULE instance + bootimage: + type: string + description: Master bootimage volume id + flavor: + type: string + description: Server flavor + constraints: + - custom_constraint: nova.flavor + key_name: + type: string + description: SSH key name + constraints: + - custom_constraint: nova.keypair + + availability_zone_0: + type: comma_delimited_list + description: List of Availability Zone IDs or Names + + sec_groups: + type: comma_delimited_list + description: Security groups + mgmt_net_id: + type: string + description: Neutron UUID for the Management network + constraints: + - custom_constraint: neutron.network + virtual_mgmt_ip_0: + type: string + description: Virtual management network ip address + + mvs_mgmt_ip_0: + type: comma_delimited_list + description: List of Management network IP addresses for IPv4 + + num_instances: + type: number + description: number of instance of the VF_module + +resources: + mvs_modules: + type: OS::Heat::ResourceGroup + properties: + count: { get_param: num_instances } + resource_def: + type: mvs.nested.heat.yaml + properties: + cloud_zone_id: { get_param: cloud_zone_id } + vf_name: { get_param: vf_name } + vf_instance_num: { get_param: vf_instance_num } + vf_component: { get_param: vf_component } + vm_instance_num: { get_param: vm_instance_num } + vnf_id: { get_param: vnf_id } + vf_module_id: { get_param: vf_module_id } + bootimage: { get_param: bootimage } + flavor: { get_param: flavor } + key_name: { get_param: key_name } + + availability_zone_0: { get_param: availability_zone_0 } + + sec_groups: { get_param: sec_groups } + mgmt_net_id: { get_param: mgmt_net_id } + virtual_mgmt_ip_0: { get_param: virtual_mgmt_ip_0 } + + mvs_mgmt_ip_0: { get_param: mvs_mgmt_ip_0 } + + indx: "%index%" + mvs_modules_same_nested_heat_file_no_count: + type: OS::Heat::ResourceGroup + properties: + resource_def: + type: mvs.nested.heat.yaml + properties: + cloud_zone_id: { get_param: cloud_zone_id } + vf_name: { get_param: vf_name } + vf_instance_num: { get_param: vf_instance_num } + vf_component: { get_param: vf_component } + vm_instance_num: { get_param: vm_instance_num } + vnf_id: { get_param: vnf_id } + vf_module_id: { get_param: vf_module_id } + bootimage: { get_param: bootimage } + flavor: { get_param: flavor } + key_name: { get_param: key_name } + + availability_zone_0: { get_param: availability_zone_0 } + + sec_groups: { get_param: sec_groups } + mgmt_net_id: { get_param: mgmt_net_id } + virtual_mgmt_ip_0: { get_param: virtual_mgmt_ip_0 } + + mvs_mgmt_ip_0: { get_param: mvs_mgmt_ip_0 } + + indx: "%index%" + shouldnt_get_translated: + type: OS::Heat::ResourceGroup + properties: + count: { get_param: num_instances } + resource_def: + type: OS::Nova::Server + properties: + cloud_zone_id: { get_param: cloud_zone_id } + vf_name: { get_param: vf_name } + vf_instance_num: { get_param: vf_instance_num } + vf_component: { get_param: vf_component } + vm_instance_num: { get_param: vm_instance_num } + vnf_id: { get_param: vnf_id } + vf_module_id: { get_param: vf_module_id } + bootimage: { get_param: bootimage } + flavor: { get_param: flavor } + key_name: { get_param: key_name } + + availability_zone_0: { get_param: availability_zone_0 } + + sec_groups: { get_param: sec_groups } + mgmt_net_id: { get_param: mgmt_net_id } + virtual_mgmt_ip_0: { get_param: virtual_mgmt_ip_0 } + + mvs_mgmt_ip_0: { get_param: mvs_mgmt_ip_0 } + + indx: "%index%" \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..e5cffd7233 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,267 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.nested: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + cmaui_names: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p2: + type: string + description: UID of OAM network + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + availability_zone_0: + type: string + description: availabilityzone name + cmaui_oam_ips: + type: string + description: cmaui_port_1 + net: + type: string + description: UID of OAM network + shared_security_group_id1: + type: string + description: UID of OAM network + requirements: + - link_cmaui_port_2: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_cmaui_port_11_test_nested2: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_cmaui_port_22_test_nested2: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - local_storage_server_cmaui_test_nested2: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - local_storage_server_cmaui: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_cmaui_port_1: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + os_server_cmaui: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + scalable_server_cmaui: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + host_server_cmaui: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + endpoint_server_cmaui: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_11_test_nested2: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + binding_server_cmaui: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_2: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + endpoint_server_cmaui_test_nested2: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + host_server_cmaui_test_nested2: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + binding_server_cmaui_test_nested2: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + scalable_server_cmaui_test_nested2: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + os_server_cmaui_test_nested2: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_22_test_nested2: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_1: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + org.openecomp.resource.abstract.nodes.heat.nested2level: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + cmaui_names: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p2: + type: string + description: UID of OAM network + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + availability_zone_0: + type: string + description: availabilityzone name + cmaui_oam_ips: + type: string + description: cmaui_port_1 + net: + type: string + description: UID of OAM network + shared_security_group_id1: + type: string + description: UID of OAM network + requirements: + - link_cmaui_port_11: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_cmaui_port_22: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - local_storage_server_cmaui: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + capabilities: + host_server_cmaui: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + os_server_cmaui: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_11: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_22: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + endpoint_server_cmaui: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + binding_server_cmaui: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + scalable_server_cmaui: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..b619c99256 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,241 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + shared_security_group_id2: + hidden: false + immutable: false + type: string + description: network name of jsa log network + jsa_net_name: + hidden: false + immutable: false + type: string + description: network name of jsa log network + shared_security_group_id1: + hidden: false + immutable: false + type: string + description: network name of jsa log network + node_templates: + jsa_security_group1: + type: org.openecomp.resource.vfc.rules.nodes.heat.network.neutron.SecurityRules + properties: + name: + get_input: security_group_name + description: ems security group + rules: + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + - protocol: tcp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv6 + remote_ip_prefix: ::/0 + direction: egress + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + - protocol: tcp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv6 + remote_ip_prefix: ::/0 + direction: ingress + requirements: + - port: + capability: attachment_cmaui_port_2 + node: test_nested + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: attachment_cmaui_port_1 + node: test_nested + relationship: org.openecomp.relationships.AttachesTo + jsa_security_group2: + type: org.openecomp.resource.vfc.rules.nodes.heat.network.neutron.SecurityRules + properties: + name: + get_input: security_group_name + description: ems security group + rules: + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + - protocol: tcp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv6 + remote_ip_prefix: ::/0 + direction: egress + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + - protocol: tcp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv6 + remote_ip_prefix: ::/0 + direction: ingress + requirements: + - port: + capability: attachment_cmaui_port_1 + node: test_nested + relationship: org.openecomp.relationships.AttachesTo + test_nested: + type: org.openecomp.resource.abstract.nodes.heat.nested + directives: + - substitutable + properties: + service_template_filter: + substitute_service_template: nestedServiceTemplate.yaml + p2: + get_input: shared_security_group_id2 + shared_security_group_id1: + get_input: shared_security_group_id1 + groups: + addOn: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/addOn.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - test_nested + base: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/base.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - jsa_security_group1 + - jsa_security_group2 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/expectedoutputfiles/nested2levelServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/expectedoutputfiles/nested2levelServiceTemplate.yaml new file mode 100644 index 0000000000..e26b5c6c18 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/expectedoutputfiles/nested2levelServiceTemplate.yaml @@ -0,0 +1,175 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested2level +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p2: + hidden: false + immutable: false + type: string + description: UID of OAM network + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + cmaui_oam_ips: + hidden: false + immutable: false + type: string + description: cmaui_port_1 + net: + hidden: false + immutable: false + type: string + description: UID of OAM network + shared_security_group_id1: + hidden: false + immutable: false + type: string + description: UID of OAM network + node_templates: + cmaui_port_11: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: shared_security_group_id1 + - get_input: p2 + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: net + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + cmaui_port_22: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: shared_security_group_id1 + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: net + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + name: + get_input: + - cmaui_names + - 0 + groups: + nested2level: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested2level.yml + description: cmaui server template for vMMSC + members: + - cmaui_port_11 + - cmaui_port_22 + - server_cmaui + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested2level + capabilities: + host_server_cmaui: + - server_cmaui + - host + os_server_cmaui: + - server_cmaui + - os + attachment_cmaui_port_11: + - cmaui_port_11 + - attachment + attachment_cmaui_port_22: + - cmaui_port_22 + - attachment + endpoint_server_cmaui: + - server_cmaui + - endpoint + binding_server_cmaui: + - server_cmaui + - binding + scalable_server_cmaui: + - server_cmaui + - scalable + requirements: + local_storage_server_cmaui: + - server_cmaui + - local_storage + link_cmaui_port_11: + - cmaui_port_11 + - link + link_cmaui_port_22: + - cmaui_port_22 + - link \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/expectedoutputfiles/nestedServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/expectedoutputfiles/nestedServiceTemplate.yaml new file mode 100644 index 0000000000..8001ba9d7d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/expectedoutputfiles/nestedServiceTemplate.yaml @@ -0,0 +1,217 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p2: + hidden: false + immutable: false + type: string + description: UID of OAM network + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + cmaui_oam_ips: + hidden: false + immutable: false + type: string + description: cmaui_port_1 + net: + hidden: false + immutable: false + type: string + description: UID of OAM network + shared_security_group_id1: + hidden: false + immutable: false + type: string + description: UID of OAM network + node_templates: + cmaui_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: shared_security_group_id1 + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: net + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + test_nested2: + type: org.openecomp.resource.abstract.nodes.heat.nested2level + directives: + - substitutable + properties: + service_template_filter: + substitute_service_template: nested2levelServiceTemplate.yaml + p2: + get_input: p2 + shared_security_group_id1: + get_input: shared_security_group_id1 + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + name: + get_input: + - cmaui_names + - 0 + cmaui_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: shared_security_group_id1 + - get_input: p2 + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: net + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + groups: + nested: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested.yml + description: cmaui server template for vMMSC + members: + - cmaui_port_2 + - test_nested2 + - server_cmaui + - cmaui_port_1 + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested + capabilities: + os_server_cmaui: + - server_cmaui + - os + scalable_server_cmaui: + - server_cmaui + - scalable + host_server_cmaui: + - server_cmaui + - host + endpoint_server_cmaui: + - server_cmaui + - endpoint + attachment_cmaui_port_11_test_nested2: + - test_nested2 + - attachment_cmaui_port_11 + binding_server_cmaui: + - server_cmaui + - binding + attachment_cmaui_port_2: + - cmaui_port_2 + - attachment + endpoint_server_cmaui_test_nested2: + - test_nested2 + - endpoint_server_cmaui + host_server_cmaui_test_nested2: + - test_nested2 + - host_server_cmaui + binding_server_cmaui_test_nested2: + - test_nested2 + - binding_server_cmaui + scalable_server_cmaui_test_nested2: + - test_nested2 + - scalable_server_cmaui + os_server_cmaui_test_nested2: + - test_nested2 + - os_server_cmaui + attachment_cmaui_port_22_test_nested2: + - test_nested2 + - attachment_cmaui_port_22 + attachment_cmaui_port_1: + - cmaui_port_1 + - attachment + requirements: + local_storage_server_cmaui_test_nested2: + - test_nested2 + - local_storage_server_cmaui + local_storage_server_cmaui: + - server_cmaui + - local_storage + link_cmaui_port_22_test_nested2: + - test_nested2 + - link_cmaui_port_22 + link_cmaui_port_2: + - cmaui_port_2 + - link + link_cmaui_port_11_test_nested2: + - test_nested2 + - link_cmaui_port_11 + link_cmaui_port_1: + - cmaui_port_1 + - link \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/inputs/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/inputs/MANIFEST.json new file mode 100644 index 0000000000..992097af43 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/inputs/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "base.yml", + "type": "HEAT", + "isBase": "true" + }, + { + "file": "nested.yml", + "type": "HEAT", + "isBase": "false" + }, + { + "file": "nested2level.yml", + "type": "HEAT", + "isBase": "false" + }, + { + "file": "addOn.yml", + "type": "HEAT", + "isBase": "false" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/inputs/addOn.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/inputs/addOn.yml new file mode 100644 index 0000000000..0e7619a478 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/inputs/addOn.yml @@ -0,0 +1,26 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + shared_security_group_id1: + type: string + description: network name of jsa log network + shared_security_group_id2: + type: string + description: network name of jsa log network + jsa_net_name: + type: string + description: network name of jsa log network + security_group_name: + type: string + label: security group name + description: the name of security group + +resources: + test_nested: + type: nested.yml + properties: + shared_security_group_id1: { get_param: shared_security_group_id1} + p2: { get_param: shared_security_group_id2} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/inputs/base.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/inputs/base.yml new file mode 100644 index 0000000000..9167ffbafd --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/inputs/base.yml @@ -0,0 +1,58 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + jsa_net_name: + type: string + description: network name of jsa log network + security_group_name: + type: string + label: security group name + description: the name of security group + +resources: + jsa_security_group1: + type: OS::Neutron::SecurityGroup + properties: + description: ems security group + name: {get_param: security_group_name} + rules: [{"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": "::/0"}, + {"direction": egress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": "::/0"}, + {"direction": egress, "ethertype": IPv6, "protocol": icmp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv6, "protocol": icmp, "remote_ip_prefix": "::/0"} + ] + + jsa_security_group2: + type: OS::Neutron::SecurityGroup + properties: + description: ems security group + name: {get_param: security_group_name} + rules: [{"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": "::/0"}, + {"direction": egress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": "::/0"}, + {"direction": egress, "ethertype": IPv6, "protocol": icmp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv6, "protocol": icmp, "remote_ip_prefix": "::/0"} + ] +outputs: + shared_security_group_id1: + value: {get_resource: jsa_security_group1} + + shared_security_group_id2: + value: {get_resource: jsa_security_group2} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/inputs/nested.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/inputs/nested.yml new file mode 100644 index 0000000000..b202fef7b0 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/inputs/nested.yml @@ -0,0 +1,65 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + shared_security_group_id1: + type: string + description: UID of OAM network + p2: + type: string + description: UID of OAM network + net: + type: string + description: UID of OAM network + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_oam_ips: + type: string + description: cmaui_port_1 + +resources: + + cmaui_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: net } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: shared_security_group_id1}, {get_param: p2}] + replacement_policy: AUTO + + cmaui_port_2: + type: OS::Neutron::Port + properties: + network: { get_param: net } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: shared_security_group_id1}] + replacement_policy: AUTO + + server_cmaui: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_1 } + - port: { get_resource: cmaui_port_2 } + + test_nested2: + type: nested2level.yml + properties: + shared_security_group_id1: { get_param: shared_security_group_id1} + p2: { get_param: p2} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/inputs/nested2level.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/inputs/nested2level.yml new file mode 100644 index 0000000000..6a123d1641 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested2levels/inputs/nested2level.yml @@ -0,0 +1,59 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + shared_security_group_id1: + type: string + description: UID of OAM network + p2: + type: string + description: UID of OAM network + net: + type: string + description: UID of OAM network + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_oam_ips: + type: string + description: cmaui_port_1 + +resources: + + cmaui_port_11: + type: OS::Neutron::Port + properties: + network: { get_param: net } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: shared_security_group_id1}, {get_param: p2}] + replacement_policy: AUTO + + cmaui_port_22: + type: OS::Neutron::Port + properties: + network: { get_param: net } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: shared_security_group_id1}] + replacement_policy: AUTO + + server_cmaui: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_11 } + - port: { get_resource: cmaui_port_22 } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..9aaa8caf18 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,472 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.nested: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + cmaui_names: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p2: + type: string + description: UID of OAM network + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + availability_zone_0: + type: string + description: availabilityzone name + cmaui_oam_ips: + type: string + description: cmaui_port_1 + net: + type: string + description: UID of OAM network + shared_security_group_id1: + type: string + description: UID of OAM network + requirements: + - link_cmaui_port_2: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_cmaui_port_11_test_nested2: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_cmaui_port_22_test_nested2: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_cmaui_port_11_test_nested3_test_nested2: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_cmaui_port_22_test_nested3_test_nested2: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - local_storage_server_cmaui_test_nested3_test_nested2: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - local_storage_server_cmaui_test_nested2: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - local_storage_server_cmaui: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_cmaui_port_1: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + os_server_cmaui: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + binding_server_cmaui_test_nested3_test_nested2: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + scalable_server_cmaui_test_nested3_test_nested2: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + host_server_cmaui_test_nested3_test_nested2: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + scalable_server_cmaui: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_22_test_nested3_test_nested2: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + host_server_cmaui: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_11_test_nested3_test_nested2: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + endpoint_server_cmaui: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_11_test_nested2: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + binding_server_cmaui: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_2: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + endpoint_server_cmaui_test_nested2: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + endpoint_server_cmaui_test_nested3_test_nested2: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + scalable_server_cmaui_test_nested2: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + host_server_cmaui_test_nested2: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + binding_server_cmaui_test_nested2: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + os_server_cmaui_test_nested2: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_22_test_nested2: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + os_server_cmaui_test_nested3_test_nested2: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_1: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + org.openecomp.resource.abstract.nodes.heat.nested3level: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + cmaui_names: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p2: + type: string + description: UID of OAM network + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + availability_zone_0: + type: string + description: availabilityzone name + cmaui_oam_ips: + type: string + description: cmaui_port_1 + net: + type: string + description: UID of OAM network + shared_security_group_id1: + type: string + description: UID of OAM network + requirements: + - link_cmaui_port_11: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_cmaui_port_22: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - local_storage_server_cmaui: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + capabilities: + host_server_cmaui: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + os_server_cmaui: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_11: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_22: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + endpoint_server_cmaui: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + binding_server_cmaui: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + scalable_server_cmaui: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + org.openecomp.resource.abstract.nodes.heat.nested2level: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + cmaui_names: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p2: + type: string + description: UID of OAM network + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + availability_zone_0: + type: string + description: availabilityzone name + cmaui_oam_ips: + type: string + description: cmaui_port_1 + net: + type: string + description: UID of OAM network + shared_security_group_id1: + type: string + description: UID of OAM network + requirements: + - link_cmaui_port_11: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_cmaui_port_22: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_cmaui_port_11_test_nested3: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_cmaui_port_22_test_nested3: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - local_storage_server_cmaui_test_nested3: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - local_storage_server_cmaui: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + capabilities: + os_server_cmaui: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_22_test_nested3: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_11_test_nested3: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + scalable_server_cmaui: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + host_server_cmaui: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_11: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_22: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + host_server_cmaui_test_nested3: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + endpoint_server_cmaui: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + binding_server_cmaui: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + endpoint_server_cmaui_test_nested3: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + os_server_cmaui_test_nested3: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + binding_server_cmaui_test_nested3: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + scalable_server_cmaui_test_nested3: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..b619c99256 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,241 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + shared_security_group_id2: + hidden: false + immutable: false + type: string + description: network name of jsa log network + jsa_net_name: + hidden: false + immutable: false + type: string + description: network name of jsa log network + shared_security_group_id1: + hidden: false + immutable: false + type: string + description: network name of jsa log network + node_templates: + jsa_security_group1: + type: org.openecomp.resource.vfc.rules.nodes.heat.network.neutron.SecurityRules + properties: + name: + get_input: security_group_name + description: ems security group + rules: + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + - protocol: tcp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv6 + remote_ip_prefix: ::/0 + direction: egress + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + - protocol: tcp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv6 + remote_ip_prefix: ::/0 + direction: ingress + requirements: + - port: + capability: attachment_cmaui_port_2 + node: test_nested + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: attachment_cmaui_port_1 + node: test_nested + relationship: org.openecomp.relationships.AttachesTo + jsa_security_group2: + type: org.openecomp.resource.vfc.rules.nodes.heat.network.neutron.SecurityRules + properties: + name: + get_input: security_group_name + description: ems security group + rules: + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + - protocol: tcp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv6 + remote_ip_prefix: ::/0 + direction: egress + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + - protocol: tcp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv6 + remote_ip_prefix: ::/0 + direction: ingress + requirements: + - port: + capability: attachment_cmaui_port_1 + node: test_nested + relationship: org.openecomp.relationships.AttachesTo + test_nested: + type: org.openecomp.resource.abstract.nodes.heat.nested + directives: + - substitutable + properties: + service_template_filter: + substitute_service_template: nestedServiceTemplate.yaml + p2: + get_input: shared_security_group_id2 + shared_security_group_id1: + get_input: shared_security_group_id1 + groups: + addOn: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/addOn.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - test_nested + base: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/base.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - jsa_security_group1 + - jsa_security_group2 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/expectedoutputfiles/nested2levelServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/expectedoutputfiles/nested2levelServiceTemplate.yaml new file mode 100644 index 0000000000..2c64802a2b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/expectedoutputfiles/nested2levelServiceTemplate.yaml @@ -0,0 +1,217 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested2level +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p2: + hidden: false + immutable: false + type: string + description: UID of OAM network + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + cmaui_oam_ips: + hidden: false + immutable: false + type: string + description: cmaui_port_1 + net: + hidden: false + immutable: false + type: string + description: UID of OAM network + shared_security_group_id1: + hidden: false + immutable: false + type: string + description: UID of OAM network + node_templates: + cmaui_port_11: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: shared_security_group_id1 + - get_input: p2 + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: net + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + cmaui_port_22: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: shared_security_group_id1 + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: net + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + test_nested3: + type: org.openecomp.resource.abstract.nodes.heat.nested3level + directives: + - substitutable + properties: + service_template_filter: + substitute_service_template: nested3levelServiceTemplate.yaml + p2: + get_input: p2 + shared_security_group_id1: + get_input: shared_security_group_id1 + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + name: + get_input: + - cmaui_names + - 0 + groups: + nested2level: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested2level.yml + description: cmaui server template for vMMSC + members: + - cmaui_port_11 + - cmaui_port_22 + - test_nested3 + - server_cmaui + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested2level + capabilities: + os_server_cmaui: + - server_cmaui + - os + attachment_cmaui_port_22_test_nested3: + - test_nested3 + - attachment_cmaui_port_22 + attachment_cmaui_port_11_test_nested3: + - test_nested3 + - attachment_cmaui_port_11 + scalable_server_cmaui: + - server_cmaui + - scalable + host_server_cmaui: + - server_cmaui + - host + attachment_cmaui_port_11: + - cmaui_port_11 + - attachment + attachment_cmaui_port_22: + - cmaui_port_22 + - attachment + host_server_cmaui_test_nested3: + - test_nested3 + - host_server_cmaui + endpoint_server_cmaui: + - server_cmaui + - endpoint + binding_server_cmaui: + - server_cmaui + - binding + endpoint_server_cmaui_test_nested3: + - test_nested3 + - endpoint_server_cmaui + os_server_cmaui_test_nested3: + - test_nested3 + - os_server_cmaui + binding_server_cmaui_test_nested3: + - test_nested3 + - binding_server_cmaui + scalable_server_cmaui_test_nested3: + - test_nested3 + - scalable_server_cmaui + requirements: + local_storage_server_cmaui_test_nested3: + - test_nested3 + - local_storage_server_cmaui + local_storage_server_cmaui: + - server_cmaui + - local_storage + link_cmaui_port_11: + - cmaui_port_11 + - link + link_cmaui_port_22: + - cmaui_port_22 + - link + link_cmaui_port_22_test_nested3: + - test_nested3 + - link_cmaui_port_22 + link_cmaui_port_11_test_nested3: + - test_nested3 + - link_cmaui_port_11 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/expectedoutputfiles/nested3levelServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/expectedoutputfiles/nested3levelServiceTemplate.yaml new file mode 100644 index 0000000000..d270626fa7 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/expectedoutputfiles/nested3levelServiceTemplate.yaml @@ -0,0 +1,175 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested3level +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p2: + hidden: false + immutable: false + type: string + description: UID of OAM network + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + cmaui_oam_ips: + hidden: false + immutable: false + type: string + description: cmaui_port_1 + net: + hidden: false + immutable: false + type: string + description: UID of OAM network + shared_security_group_id1: + hidden: false + immutable: false + type: string + description: UID of OAM network + node_templates: + cmaui_port_11: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: shared_security_group_id1 + - get_input: p2 + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: net + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + cmaui_port_22: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: shared_security_group_id1 + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: net + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + name: + get_input: + - cmaui_names + - 0 + groups: + nested3level: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested3level.yml + description: cmaui server template for vMMSC + members: + - cmaui_port_11 + - cmaui_port_22 + - server_cmaui + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested3level + capabilities: + host_server_cmaui: + - server_cmaui + - host + os_server_cmaui: + - server_cmaui + - os + attachment_cmaui_port_11: + - cmaui_port_11 + - attachment + attachment_cmaui_port_22: + - cmaui_port_22 + - attachment + endpoint_server_cmaui: + - server_cmaui + - endpoint + binding_server_cmaui: + - server_cmaui + - binding + scalable_server_cmaui: + - server_cmaui + - scalable + requirements: + local_storage_server_cmaui: + - server_cmaui + - local_storage + link_cmaui_port_11: + - cmaui_port_11 + - link + link_cmaui_port_22: + - cmaui_port_22 + - link \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/expectedoutputfiles/nestedServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/expectedoutputfiles/nestedServiceTemplate.yaml new file mode 100644 index 0000000000..d78a252f4f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/expectedoutputfiles/nestedServiceTemplate.yaml @@ -0,0 +1,247 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p2: + hidden: false + immutable: false + type: string + description: UID of OAM network + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + cmaui_oam_ips: + hidden: false + immutable: false + type: string + description: cmaui_port_1 + net: + hidden: false + immutable: false + type: string + description: UID of OAM network + shared_security_group_id1: + hidden: false + immutable: false + type: string + description: UID of OAM network + node_templates: + cmaui_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: shared_security_group_id1 + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: net + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + test_nested2: + type: org.openecomp.resource.abstract.nodes.heat.nested2level + directives: + - substitutable + properties: + service_template_filter: + substitute_service_template: nested2levelServiceTemplate.yaml + p2: + get_input: p2 + shared_security_group_id1: + get_input: shared_security_group_id1 + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + name: + get_input: + - cmaui_names + - 0 + cmaui_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: shared_security_group_id1 + - get_input: p2 + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: net + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + groups: + nested: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested.yml + description: cmaui server template for vMMSC + members: + - cmaui_port_2 + - test_nested2 + - server_cmaui + - cmaui_port_1 + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested + capabilities: + os_server_cmaui: + - server_cmaui + - os + binding_server_cmaui_test_nested3_test_nested2: + - test_nested2 + - binding_server_cmaui_test_nested3 + scalable_server_cmaui_test_nested3_test_nested2: + - test_nested2 + - scalable_server_cmaui_test_nested3 + host_server_cmaui_test_nested3_test_nested2: + - test_nested2 + - host_server_cmaui_test_nested3 + scalable_server_cmaui: + - server_cmaui + - scalable + attachment_cmaui_port_22_test_nested3_test_nested2: + - test_nested2 + - attachment_cmaui_port_22_test_nested3 + host_server_cmaui: + - server_cmaui + - host + attachment_cmaui_port_11_test_nested3_test_nested2: + - test_nested2 + - attachment_cmaui_port_11_test_nested3 + endpoint_server_cmaui: + - server_cmaui + - endpoint + attachment_cmaui_port_11_test_nested2: + - test_nested2 + - attachment_cmaui_port_11 + binding_server_cmaui: + - server_cmaui + - binding + attachment_cmaui_port_2: + - cmaui_port_2 + - attachment + endpoint_server_cmaui_test_nested2: + - test_nested2 + - endpoint_server_cmaui + endpoint_server_cmaui_test_nested3_test_nested2: + - test_nested2 + - endpoint_server_cmaui_test_nested3 + scalable_server_cmaui_test_nested2: + - test_nested2 + - scalable_server_cmaui + host_server_cmaui_test_nested2: + - test_nested2 + - host_server_cmaui + binding_server_cmaui_test_nested2: + - test_nested2 + - binding_server_cmaui + os_server_cmaui_test_nested2: + - test_nested2 + - os_server_cmaui + attachment_cmaui_port_22_test_nested2: + - test_nested2 + - attachment_cmaui_port_22 + os_server_cmaui_test_nested3_test_nested2: + - test_nested2 + - os_server_cmaui_test_nested3 + attachment_cmaui_port_1: + - cmaui_port_1 + - attachment + requirements: + local_storage_server_cmaui_test_nested2: + - test_nested2 + - local_storage_server_cmaui + local_storage_server_cmaui: + - server_cmaui + - local_storage + link_cmaui_port_11_test_nested3_test_nested2: + - test_nested2 + - link_cmaui_port_11_test_nested3 + link_cmaui_port_22_test_nested2: + - test_nested2 + - link_cmaui_port_22 + link_cmaui_port_22_test_nested3_test_nested2: + - test_nested2 + - link_cmaui_port_22_test_nested3 + local_storage_server_cmaui_test_nested3_test_nested2: + - test_nested2 + - local_storage_server_cmaui_test_nested3 + link_cmaui_port_2: + - cmaui_port_2 + - link + link_cmaui_port_11_test_nested2: + - test_nested2 + - link_cmaui_port_11 + link_cmaui_port_1: + - cmaui_port_1 + - link \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/inputs/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/inputs/MANIFEST.json new file mode 100644 index 0000000000..ea06fcc95a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/inputs/MANIFEST.json @@ -0,0 +1,32 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "base.yml", + "type": "HEAT", + "isBase": "true" + }, + { + "file": "nested.yml", + "type": "HEAT", + "isBase": "false" + }, + { + "file": "nested2level.yml", + "type": "HEAT", + "isBase": "false" + }, + { + "file": "nested3level.yml", + "type": "HEAT", + "isBase": "false" + }, + { + "file": "addOn.yml", + "type": "HEAT", + "isBase": "false" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/inputs/addOn.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/inputs/addOn.yml new file mode 100644 index 0000000000..0e7619a478 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/inputs/addOn.yml @@ -0,0 +1,26 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + shared_security_group_id1: + type: string + description: network name of jsa log network + shared_security_group_id2: + type: string + description: network name of jsa log network + jsa_net_name: + type: string + description: network name of jsa log network + security_group_name: + type: string + label: security group name + description: the name of security group + +resources: + test_nested: + type: nested.yml + properties: + shared_security_group_id1: { get_param: shared_security_group_id1} + p2: { get_param: shared_security_group_id2} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/inputs/base.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/inputs/base.yml new file mode 100644 index 0000000000..9167ffbafd --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/inputs/base.yml @@ -0,0 +1,58 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + jsa_net_name: + type: string + description: network name of jsa log network + security_group_name: + type: string + label: security group name + description: the name of security group + +resources: + jsa_security_group1: + type: OS::Neutron::SecurityGroup + properties: + description: ems security group + name: {get_param: security_group_name} + rules: [{"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": "::/0"}, + {"direction": egress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": "::/0"}, + {"direction": egress, "ethertype": IPv6, "protocol": icmp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv6, "protocol": icmp, "remote_ip_prefix": "::/0"} + ] + + jsa_security_group2: + type: OS::Neutron::SecurityGroup + properties: + description: ems security group + name: {get_param: security_group_name} + rules: [{"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": "::/0"}, + {"direction": egress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": "::/0"}, + {"direction": egress, "ethertype": IPv6, "protocol": icmp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv6, "protocol": icmp, "remote_ip_prefix": "::/0"} + ] +outputs: + shared_security_group_id1: + value: {get_resource: jsa_security_group1} + + shared_security_group_id2: + value: {get_resource: jsa_security_group2} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/inputs/nested.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/inputs/nested.yml new file mode 100644 index 0000000000..b202fef7b0 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/inputs/nested.yml @@ -0,0 +1,65 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + shared_security_group_id1: + type: string + description: UID of OAM network + p2: + type: string + description: UID of OAM network + net: + type: string + description: UID of OAM network + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_oam_ips: + type: string + description: cmaui_port_1 + +resources: + + cmaui_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: net } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: shared_security_group_id1}, {get_param: p2}] + replacement_policy: AUTO + + cmaui_port_2: + type: OS::Neutron::Port + properties: + network: { get_param: net } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: shared_security_group_id1}] + replacement_policy: AUTO + + server_cmaui: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_1 } + - port: { get_resource: cmaui_port_2 } + + test_nested2: + type: nested2level.yml + properties: + shared_security_group_id1: { get_param: shared_security_group_id1} + p2: { get_param: p2} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/inputs/nested2level.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/inputs/nested2level.yml new file mode 100644 index 0000000000..14c137a884 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/inputs/nested2level.yml @@ -0,0 +1,65 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + shared_security_group_id1: + type: string + description: UID of OAM network + p2: + type: string + description: UID of OAM network + net: + type: string + description: UID of OAM network + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_oam_ips: + type: string + description: cmaui_port_1 + +resources: + + cmaui_port_11: + type: OS::Neutron::Port + properties: + network: { get_param: net } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: shared_security_group_id1}, {get_param: p2}] + replacement_policy: AUTO + + cmaui_port_22: + type: OS::Neutron::Port + properties: + network: { get_param: net } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: shared_security_group_id1}] + replacement_policy: AUTO + + server_cmaui: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_11 } + - port: { get_resource: cmaui_port_22 } + + test_nested3: + type: nested3level.yml + properties: + shared_security_group_id1: { get_param: shared_security_group_id1} + p2: { get_param: p2} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/inputs/nested3level.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/inputs/nested3level.yml new file mode 100644 index 0000000000..6a123d1641 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nested3levels/inputs/nested3level.yml @@ -0,0 +1,59 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + shared_security_group_id1: + type: string + description: UID of OAM network + p2: + type: string + description: UID of OAM network + net: + type: string + description: UID of OAM network + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_oam_ips: + type: string + description: cmaui_port_1 + +resources: + + cmaui_port_11: + type: OS::Neutron::Port + properties: + network: { get_param: net } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: shared_security_group_id1}, {get_param: p2}] + replacement_policy: AUTO + + cmaui_port_22: + type: OS::Neutron::Port + properties: + network: { get_param: net } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: shared_security_group_id1}] + replacement_policy: AUTO + + server_cmaui: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_11 } + - port: { get_resource: cmaui_port_22 } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumelocal/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumelocal/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..ef081a9bec --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumelocal/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,79 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.nested-pcm_v0.1: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + nova_image_name: + type: string + description: PCRF CM server name + pcm_server_name: + type: string + description: PCRF CM server name + nove_001_vol_property: + type: string + description: PCRF CM server name + requirements: + - local_storage_nova_001: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + capabilities: + scalable_nova_001: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + host_nova_001: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + endpoint_nova_001: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + os_nova_001: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + binding_nova_001: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumelocal/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumelocal/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..136eb6309a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumelocal/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,65 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + not_null: + hidden: false + immutable: false + type: string + node_templates: + server_pcm_001: + type: org.openecomp.resource.abstract.nodes.heat.nested-pcm_v0.1 + directives: + - substitutable + properties: + service_template_filter: + substitute_service_template: nested-pcm_v0.1ServiceTemplate.yaml + nove_001_vol_property: nove_001_vol + requirements: + - local_storage_nova_001: + capability: tosca.capabilities.Attachment + node: nove_001_vol + relationship: tosca.relationships.AttachesTo + nove_001_vol: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: { + } + groups: + hot-nimbus-pcm_v0.4: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/hot-nimbus-pcm_v0.4.yaml + description: heat template that creates PCRF Cluman stack + members: + - server_pcm_001 + - nove_001_vol \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumelocal/expectedoutputfiles/nested-pcm_v0.1ServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumelocal/expectedoutputfiles/nested-pcm_v0.1ServiceTemplate.yaml new file mode 100644 index 0000000000..1b9c34f1da --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumelocal/expectedoutputfiles/nested-pcm_v0.1ServiceTemplate.yaml @@ -0,0 +1,91 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested-pcm_v0.1 +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.nova: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + nova_image_name: + label: nova_001 image name + hidden: false + immutable: false + type: string + description: PCRF CM server name + pcm_server_name: + label: PCRF CM server name + hidden: false + immutable: false + type: string + description: PCRF CM server name + nove_001_vol_property: + label: PCRF CM server name + hidden: false + immutable: false + type: string + description: PCRF CM server name + node_templates: + nova_001: + type: org.openecomp.resource.vfc.nodes.heat.nova + properties: + image: + get_input: nova_image_name + groups: + nested-pcm_v0.1: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested-pcm_v0.1.yaml + description: heat template that creates PCRF Cluman stack + members: + - nova_001 + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested-pcm_v0.1 + capabilities: + scalable_nova_001: + - nova_001 + - scalable + host_nova_001: + - nova_001 + - host + endpoint_nova_001: + - nova_001 + - endpoint + os_nova_001: + - nova_001 + - os + binding_nova_001: + - nova_001 + - binding + requirements: + local_storage_nova_001: + - nova_001 + - local_storage \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumelocal/inputs/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumelocal/inputs/MANIFEST.json new file mode 100644 index 0000000000..44c5652ed6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumelocal/inputs/MANIFEST.json @@ -0,0 +1,14 @@ +{ + "name": "vEP_JSA_Net", + "description": "Version 2.0 02-09-2016 (Authors: John Doe, user PROD)", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pcm_v0.4.yaml", + "type": "HEAT" + },{ + "file": "nested-pcm_v0.1.yaml", + "type": "HEAT" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumelocal/inputs/hot-nimbus-pcm_v0.4.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumelocal/inputs/hot-nimbus-pcm_v0.4.yaml new file mode 100644 index 0000000000..93dd4470b8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumelocal/inputs/hot-nimbus-pcm_v0.4.yaml @@ -0,0 +1,22 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Cluman stack + +parameters: + not_null: + type: string + + + +resources: + server_pcm_001: + type: nested-pcm_v0.1.yaml + properties: + nove_001_vol_property: { get_resource: nove_001_vol } + + nove_001_vol: + type: OS::Cinder::Volume + properties: + not_null: not_null + + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumelocal/inputs/nested-pcm_v0.1.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumelocal/inputs/nested-pcm_v0.1.yaml new file mode 100644 index 0000000000..d444a691ff --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumelocal/inputs/nested-pcm_v0.1.yaml @@ -0,0 +1,29 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Cluman stack + +parameters: + pcm_server_name: + type: string + label: PCRF CM server name + description: PCRF CM server name + nove_001_vol_property: + type: string + label: PCRF CM server name + description: PCRF CM server name + nova_image_name: + type: string + label: nova_001 image name + description: PCRF CM server name + +resources: + nova_001: + type: OS::Nova::Server + properties: + not_null: not_null + image: {get_param: nova_image_name} + nove_001_vol_attach: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_param: nove_001_vol_property} + instance_uuid: {get_resource: nova_001} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumeseperatefile/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumeseperatefile/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..5edf602a57 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumeseperatefile/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,79 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.nested-pcm_v0.1: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + nova_image_name: + type: string + description: nova image name + pcm_server_name: + type: string + description: PCRF CM server name + nove_001_vol_property: + type: string + description: volume name + requirements: + - local_storage_nova_001: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + capabilities: + scalable_nova_001: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + host_nova_001: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + endpoint_nova_001: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + os_nova_001: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + binding_nova_001: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumeseperatefile/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumeseperatefile/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..30e792209b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumeseperatefile/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,72 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + not_null: + hidden: false + immutable: false + type: string + nove_001_vol: + label: volume + hidden: false + immutable: false + type: string + description: volume name + node_templates: + server_pcm_001: + type: org.openecomp.resource.abstract.nodes.heat.nested-pcm_v0.1 + directives: + - substitutable + properties: + service_template_filter: + substitute_service_template: nested-pcm_v0.1ServiceTemplate.yaml + nove_001_vol_property: + get_input: nove_001_vol + nove_001_vol: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: { + } + groups: + volume: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/volume.yaml + members: + - nove_001_vol + hot-nimbus-pcm_v0.4: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/hot-nimbus-pcm_v0.4.yaml + description: heat template that creates PCRF Cluman stack + members: + - server_pcm_001 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumeseperatefile/expectedoutputfiles/nested-pcm_v0.1ServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumeseperatefile/expectedoutputfiles/nested-pcm_v0.1ServiceTemplate.yaml new file mode 100644 index 0000000000..3f03905588 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumeseperatefile/expectedoutputfiles/nested-pcm_v0.1ServiceTemplate.yaml @@ -0,0 +1,91 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested-pcm_v0.1 +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.nova: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + nova_image_name: + label: volume + hidden: false + immutable: false + type: string + description: nova image name + pcm_server_name: + label: PCRF CM server name + hidden: false + immutable: false + type: string + description: PCRF CM server name + nove_001_vol_property: + label: volume + hidden: false + immutable: false + type: string + description: volume name + node_templates: + nova_001: + type: org.openecomp.resource.vfc.nodes.heat.nova + properties: + image: + get_input: nova_image_name + groups: + nested-pcm_v0.1: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested-pcm_v0.1.yaml + description: heat template that creates PCRF Cluman stack + members: + - nova_001 + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested-pcm_v0.1 + capabilities: + scalable_nova_001: + - nova_001 + - scalable + host_nova_001: + - nova_001 + - host + endpoint_nova_001: + - nova_001 + - endpoint + os_nova_001: + - nova_001 + - os + binding_nova_001: + - nova_001 + - binding + requirements: + local_storage_nova_001: + - nova_001 + - local_storage \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumeseperatefile/inputs/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumeseperatefile/inputs/MANIFEST.json new file mode 100644 index 0000000000..63b14401c8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumeseperatefile/inputs/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "vEP_JSA_Net", + "description": "Version 2.0 02-09-2016 (Authors: John Doe, user PROD)", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pcm_v0.4.yaml", + "type": "HEAT" + },{ + "file": "nested-pcm_v0.1.yaml", + "type": "HEAT" + },{ + "file": "volume.yaml", + "type": "HEAT_VOL" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumeseperatefile/inputs/hot-nimbus-pcm_v0.4.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumeseperatefile/inputs/hot-nimbus-pcm_v0.4.yaml new file mode 100644 index 0000000000..f6cfa047ef --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumeseperatefile/inputs/hot-nimbus-pcm_v0.4.yaml @@ -0,0 +1,23 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Cluman stack + +parameters: + not_null: + type: string + + nove_001_vol: + type: string + label: volume + description: volume name + + + +resources: + server_pcm_001: + type: nested-pcm_v0.1.yaml + properties: + nove_001_vol_property: { get_param: nove_001_vol } + + + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumeseperatefile/inputs/nested-pcm_v0.1.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumeseperatefile/inputs/nested-pcm_v0.1.yaml new file mode 100644 index 0000000000..b8ab56319a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumeseperatefile/inputs/nested-pcm_v0.1.yaml @@ -0,0 +1,31 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Cluman stack + +parameters: + pcm_server_name: + type: string + label: PCRF CM server name + description: PCRF CM server name + + nove_001_vol_property: + type: string + label: volume + description: volume name + + nova_image_name: + type: string + label: volume + description: nova image name + +resources: + nova_001: + type: OS::Nova::Server + properties: + not_null: not_null + image: {get_param: nova_image_name} + nove_001_vol_attach: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_param: nove_001_vol_property} + instance_uuid: {get_resource: nova_001} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumeseperatefile/inputs/volume.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumeseperatefile/inputs/volume.yaml new file mode 100644 index 0000000000..dbb3859b37 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/nestedvolumeseperatefile/inputs/volume.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +parameters: + not_null: + type: number + label: not_number + + +resources: + nove_001_vol: + type: OS::Cinder::Volume + properties: + not_null: not_null + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..2dee4a9971 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,330 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.nested-pcm_v0.1_2: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + pcm_flavor_name: + type: string + description: flavor name of PCRF CM instance + availabilityzone_name: + type: string + description: availabilityzone name + pcm_image_name: + type: string + description: PCRF CM image name + pcm_vol: + type: string + description: CPS Cluman Cinder Volume + security_group_name: + type: string + description: the name of security group + cps_net_ip: + type: string + description: CPS network ip + pcm_server_name: + type: string + description: PCRF CM server name + cps_net_name: + type: string + description: CPS network name + cps_net_mask: + type: string + description: CPS network mask + oam_net_ip: + type: string + oam_net_name: + type: string + description: OAM network name + attributes: + server_pcm_id: + type: string + description: the pcm nova service id + requirements: + - link_pcm_port_1: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - local_storage_server_pcm: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_pcm_port_0: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + endpoint_server_pcm: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + link_network: + type: tosca.capabilities.network.Linkable + occurrences: + - 1 + - UNBOUNDED + os_server_pcm: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + host_server_pcm: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + scalable_server_pcm: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + attachment_network: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + binding_server_pcm: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + attachment_pcm_port_0: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + attachment_pcm_port_1: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + org.openecomp.resource.abstract.nodes.heat.nested-pcm_v0.1: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + availabilityzone_name: + type: string + description: availabilityzone name + oam_net_gw: + type: string + description: CPS network gateway + pcm_image_name: + type: string + description: PCRF CM image name + cps_net_ips: + type: string + description: CPS network ip + security_group_name: + type: string + description: the name of security group + cps_net_ip: + type: string + description: CPS network ip + pcm_volumes: + type: string + description: CPS Cluman Cinder Volume + pcm_flavor_name: + type: string + description: flavor name of PCRF CM instance + pcm_vol: + type: string + description: CPS Cluman Cinder Volume + pcm_server_name: + type: string + description: PCRF CM server name + cps_net_name: + type: string + description: CPS network name + cps_net_mask: + type: string + description: CPS network mask + oam_net_ip: + type: string + description: OAM network ip + oam_net_mask: + type: string + description: CPS network mask + oam_net_name: + type: string + description: OAM network name + attributes: + server_pcm_id: + type: string + description: the pcm nova service id + requirements: + - link_pcm_port_1: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - local_storage_server_pcm: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_pcm_port_1_server_pcm_005: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - local_storage_server_pcm_server_pcm_005: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_pcm_port_0_server_pcm_005: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_pcm_port_0: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + endpoint_server_pcm: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + host_server_pcm: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + host_server_pcm_server_pcm_005: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + os_server_pcm_server_pcm_005: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + scalable_server_pcm_server_pcm_005: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + binding_server_pcm_server_pcm_005: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + endpoint_server_pcm_server_pcm_005: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + attachment_network_server_pcm_005: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + attachment_network: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + binding_server_pcm: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + link_network: + type: tosca.capabilities.network.Linkable + occurrences: + - 1 + - UNBOUNDED + attachment_pcm_port_0_server_pcm_005: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + os_server_pcm: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + link_network_server_pcm_005: + type: tosca.capabilities.network.Linkable + occurrences: + - 1 + - UNBOUNDED + scalable_server_pcm: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + attachment_pcm_port_0: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + attachment_pcm_port_1: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + attachment_pcm_port_1_server_pcm_005: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..a0063b174e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,240 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + oam_net_ips: + label: OAM network ips + hidden: false + immutable: false + type: list + description: OAM network ips + entry_schema: + type: string + availabilityzone_name: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + oam_net_gw: + label: CPS network gateway + hidden: false + immutable: false + type: string + description: CPS network gateway + pcm_server_names: + label: PCRF CM server names + hidden: false + immutable: false + type: list + description: name of the PCRF CM instance + entry_schema: + type: string + pcm_image_name: + label: PCRF CM image name + hidden: false + immutable: false + type: string + description: PCRF CM image name + cps_net_ips: + label: CPS network ips + hidden: false + immutable: false + type: list + description: CPS network ips + entry_schema: + type: string + security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + pcm_volumes: + label: CPS Cluman Cinder Volume + hidden: false + immutable: false + type: list + description: CPS Cluman Cinder Volume + entry_schema: + type: string + pcm_flavor_name: + label: PCRF CM flavor name + hidden: false + immutable: false + type: string + description: flavor name of PCRF CM instance + cps_net_name: + label: CPS network name + hidden: false + immutable: false + type: string + description: CPS network name + cps_net_mask: + label: CPS network mask + hidden: false + immutable: false + type: string + description: CPS network mask + oam_net_mask: + label: CPS network mask + hidden: false + immutable: false + type: string + description: CPS network mask + oam_net_name: + label: OAM network name + hidden: false + immutable: false + type: string + description: OAM network name + node_templates: + server_pcm_002: + type: org.openecomp.resource.abstract.nodes.heat.nested-pcm_v0.1 + directives: + - substitutable + properties: + pcm_flavor_name: + get_input: pcm_flavor_name + service_template_filter: + substitute_service_template: nested-pcm_v0.1ServiceTemplate.yaml + availabilityzone_name: + get_input: availabilityzone_name + pcm_image_name: + get_input: pcm_image_name + pcm_vol: + get_input: + - pcm_volumes + - 0 + security_group_name: + get_input: security_group_name + pcm_server_name: + get_input: + - pcm_server_names + - 0 + server_pcm_001: + type: org.openecomp.resource.abstract.nodes.heat.nested-pcm_v0.1 + directives: + - substitutable + properties: + service_template_filter: + substitute_service_template: nested-pcm_v0.1ServiceTemplate.yaml + availabilityzone_name: + get_input: availabilityzone_name + oam_net_gw: + get_input: oam_net_gw + pcm_vol: + get_input: + - pcm_volumes + - 0 + security_group_name: + get_input: security_group_name + cps_net_ip: + get_input: + - cps_net_ips + - 0 + cps_net_name: + get_input: cps_net_name + cps_net_mask: + get_input: cps_net_mask + oam_net_ip: + get_input: + - oam_net_ips + - 0 + oam_net_mask: + get_input: oam_net_mask + oam_net_name: + get_input: oam_net_name + server_pcm_004: + type: org.openecomp.resource.abstract.nodes.heat.nested-pcm_v0.1_2 + directives: + - substitutable + properties: + service_template_filter: + substitute_service_template: nested-pcm_v0.1_2ServiceTemplate.yaml + availabilityzone_name: + get_input: availabilityzone_name + pcm_vol: + get_input: + - pcm_volumes + - 0 + security_group_name: + get_input: security_group_name + cps_net_ip: + get_input: + - cps_net_ips + - 0 + cps_net_name: + get_input: cps_net_name + cps_net_mask: + get_input: cps_net_mask + server_pcm_003: + type: org.openecomp.resource.abstract.nodes.heat.nested-pcm_v0.1 + directives: + - substitutable + properties: + service_template_filter: + substitute_service_template: nested-pcm_v0.1ServiceTemplate.yaml + availabilityzone_name: + get_input: availabilityzone_name + pcm_vol: + get_input: + - pcm_volumes + - 0 + security_group_name: + get_input: security_group_name + cps_net_ip: + get_input: + - cps_net_ips + - 0 + cps_net_name: + get_input: cps_net_name + cps_net_mask: + get_input: cps_net_mask + groups: + hot-nimbus-pcm_v0.4_2: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/hot-nimbus-pcm_v0.4_2.yaml + description: heat template that creates PCRF Cluman stack + members: + - server_pcm_004 + - server_pcm_003 + hot-nimbus-pcm_v0.4: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/hot-nimbus-pcm_v0.4.yaml + description: heat template that creates PCRF Cluman stack + members: + - server_pcm_002 + - server_pcm_001 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/expectedoutputfiles/nested-pcm_v0.1ServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/expectedoutputfiles/nested-pcm_v0.1ServiceTemplate.yaml new file mode 100644 index 0000000000..39fb736465 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/expectedoutputfiles/nested-pcm_v0.1ServiceTemplate.yaml @@ -0,0 +1,291 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested-pcm_v0.1 +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.pcm_server: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + availabilityzone_name: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + oam_net_gw: + label: CPS network gateway + hidden: false + immutable: false + type: string + description: CPS network gateway + pcm_image_name: + label: image name + hidden: false + immutable: false + type: string + description: PCRF CM image name + cps_net_ips: + label: CPS network ip + hidden: false + immutable: false + type: string + description: CPS network ip + security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + cps_net_ip: + label: CPS network ip + hidden: false + immutable: false + type: string + description: CPS network ip + pcm_volumes: + label: CPS Cluman Cinder Volume + hidden: false + immutable: false + type: string + description: CPS Cluman Cinder Volume + pcm_flavor_name: + label: PCRF CM flavor name + hidden: false + immutable: false + type: string + description: flavor name of PCRF CM instance + pcm_vol: + label: CPS Cluman Cinder Volume + hidden: false + immutable: false + type: string + description: CPS Cluman Cinder Volume + pcm_server_name: + label: PCRF CM server name + hidden: false + immutable: false + type: string + description: PCRF CM server name + cps_net_name: + label: CPS network name + hidden: false + immutable: false + type: string + description: CPS network name + cps_net_mask: + label: CPS network mask + hidden: false + immutable: false + type: string + description: CPS network mask + oam_net_ip: + label: OAM network ip + hidden: false + immutable: false + type: string + description: OAM network ip + oam_net_mask: + label: CPS network mask + hidden: false + immutable: false + type: string + description: CPS network mask + oam_net_name: + label: OAM network name + hidden: false + immutable: false + type: string + description: OAM network name + node_templates: + pcm_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: oam_net_ip + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_pcm + relationship: tosca.relationships.network.BindsTo + server_pcm: + type: org.openecomp.resource.vfc.nodes.heat.pcm_server + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + server_pcm_005: + type: org.openecomp.resource.abstract.nodes.heat.nested-pcm_v0.1_2 + directives: + - substitutable + properties: + service_template_filter: + substitute_service_template: nested-pcm_v0.1_2ServiceTemplate.yaml + availabilityzone_name: + get_input: availabilityzone_name + pcm_vol: + get_input: + - pcm_volumes + - 0 + security_group_name: + get_input: security_group_name + cps_net_ip: + get_input: + - cps_net_ips + - 0 + cps_net_name: + get_input: cps_net_name + cps_net_mask: + get_input: cps_net_mask + pcm_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: cps_net_ip + network: + get_input: cps_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_pcm + relationship: tosca.relationships.network.BindsTo + network: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + network_name: + get_input: cps_net_name + groups: + nested-pcm_v0.1: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested-pcm_v0.1.yaml + description: heat template that creates PCRF Cluman stack + members: + - pcm_port_1 + - server_pcm + - server_pcm_005 + - pcm_port_0 + - network + outputs: + server_pcm_id: + description: the pcm nova service id + value: server_pcm + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested-pcm_v0.1 + capabilities: + endpoint_server_pcm: + - server_pcm + - endpoint + host_server_pcm: + - server_pcm + - host + host_server_pcm_server_pcm_005: + - server_pcm_005 + - host_server_pcm + os_server_pcm_server_pcm_005: + - server_pcm_005 + - os_server_pcm + scalable_server_pcm_server_pcm_005: + - server_pcm_005 + - scalable_server_pcm + binding_server_pcm_server_pcm_005: + - server_pcm_005 + - binding_server_pcm + endpoint_server_pcm_server_pcm_005: + - server_pcm_005 + - endpoint_server_pcm + attachment_network_server_pcm_005: + - server_pcm_005 + - attachment_network + attachment_network: + - network + - attachment + binding_server_pcm: + - server_pcm + - binding + link_network: + - network + - link + attachment_pcm_port_0_server_pcm_005: + - server_pcm_005 + - attachment_pcm_port_0 + os_server_pcm: + - server_pcm + - os + link_network_server_pcm_005: + - server_pcm_005 + - link_network + scalable_server_pcm: + - server_pcm + - scalable + attachment_pcm_port_0: + - pcm_port_0 + - attachment + attachment_pcm_port_1: + - pcm_port_1 + - attachment + attachment_pcm_port_1_server_pcm_005: + - server_pcm_005 + - attachment_pcm_port_1 + requirements: + link_pcm_port_0: + - pcm_port_0 + - link + link_pcm_port_1: + - pcm_port_1 + - link + link_pcm_port_1_server_pcm_005: + - server_pcm_005 + - link_pcm_port_1 + link_pcm_port_0_server_pcm_005: + - server_pcm_005 + - link_pcm_port_0 + local_storage_server_pcm: + - server_pcm + - local_storage + local_storage_server_pcm_server_pcm_005: + - server_pcm_005 + - local_storage_server_pcm \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/expectedoutputfiles/nested-pcm_v0.1_2ServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/expectedoutputfiles/nested-pcm_v0.1_2ServiceTemplate.yaml new file mode 100644 index 0000000000..a80a5811b1 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/expectedoutputfiles/nested-pcm_v0.1_2ServiceTemplate.yaml @@ -0,0 +1,205 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested-pcm_v0.1_2 +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.pcm_server: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + pcm_flavor_name: + label: PCRF CM flavor name + hidden: false + immutable: false + type: string + description: flavor name of PCRF CM instance + availabilityzone_name: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + pcm_image_name: + label: image name + hidden: false + immutable: false + type: string + description: PCRF CM image name + pcm_vol: + label: CPS Cluman Cinder Volume + hidden: false + immutable: false + type: string + description: CPS Cluman Cinder Volume + security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + cps_net_ip: + label: CPS network ip + hidden: false + immutable: false + type: string + description: CPS network ip + pcm_server_name: + label: PCRF CM server name + hidden: false + immutable: false + type: string + description: PCRF CM server name + cps_net_name: + label: CPS network name + hidden: false + immutable: false + type: string + description: CPS network name + cps_net_mask: + label: CPS network mask + hidden: false + immutable: false + type: string + description: CPS network mask + oam_net_ip: + hidden: false + immutable: false + type: string + oam_net_name: + label: OAM network name + hidden: false + immutable: false + type: string + description: OAM network name + node_templates: + pcm_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: oam_net_ip + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_pcm + relationship: tosca.relationships.network.BindsTo + server_pcm: + type: org.openecomp.resource.vfc.nodes.heat.pcm_server + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + pcm_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: cps_net_ip + network: + get_input: cps_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_pcm + relationship: tosca.relationships.network.BindsTo + network: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + network_name: + get_input: cps_net_name + groups: + nested-pcm_v0.1_2: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested-pcm_v0.1_2.yaml + description: heat template that creates PCRF Cluman stack + members: + - pcm_port_1 + - server_pcm + - pcm_port_0 + - network + outputs: + server_pcm_id: + description: the pcm nova service id + value: server_pcm + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested-pcm_v0.1_2 + capabilities: + endpoint_server_pcm: + - server_pcm + - endpoint + link_network: + - network + - link + os_server_pcm: + - server_pcm + - os + host_server_pcm: + - server_pcm + - host + scalable_server_pcm: + - server_pcm + - scalable + attachment_network: + - network + - attachment + binding_server_pcm: + - server_pcm + - binding + attachment_pcm_port_0: + - pcm_port_0 + - attachment + attachment_pcm_port_1: + - pcm_port_1 + - attachment + requirements: + link_pcm_port_0: + - pcm_port_0 + - link + link_pcm_port_1: + - pcm_port_1 + - link + local_storage_server_pcm: + - server_pcm + - local_storage \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/inputs/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/inputs/MANIFEST.json new file mode 100644 index 0000000000..b4a1b43a1e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/inputs/MANIFEST.json @@ -0,0 +1,26 @@ +{ + "name": "vEP_JSA_Net", + "description": "Version 2.0 02-09-2016 (Authors: John Doe, user PROD)", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pcm_v0.4.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pcm_v0.4.env", + "type": "HEAT_ENV" + } + ] + },{ + "file": "nested-pcm_v0.1.yaml", + "type": "HEAT" + },{ + "file": "hot-nimbus-pcm_v0.4_2.yaml", + "type": "HEAT" + },{ + "file": "nested-pcm_v0.1_2.yaml", + "type": "HEAT" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/inputs/hot-nimbus-pcm_v0.4.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/inputs/hot-nimbus-pcm_v0.4.env new file mode 100644 index 0000000000..78cc03e2ea --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/inputs/hot-nimbus-pcm_v0.4.env @@ -0,0 +1,14 @@ +parameters: + pcm_server_names: ZRDM1PCRF01PCM001 + pcm_image_name: rhel2 + pcm_flavor_name: cps + availabilityzone_name: nova + cps_net_name: int_pcrf_net_0 + cps_net_ips: 172.26.16.113 + cps_net_mask: 255.255.255.0 + oam_net_name: oam_protected_net_0 + oam_net_ips: 107.239.64.121 + oam_net_gw: 107.239.64.1 + oam_net_mask: 255.255.255.0 + pcm_volumes: 249cb355-8fdf-4382-9c3c-a2ebe767d45b + security_group_name: nimbus_security_group diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/inputs/hot-nimbus-pcm_v0.4.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/inputs/hot-nimbus-pcm_v0.4.yaml new file mode 100644 index 0000000000..f7d050790f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/inputs/hot-nimbus-pcm_v0.4.yaml @@ -0,0 +1,82 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Cluman stack + +parameters: + pcm_server_names: + type: comma_delimited_list + label: PCRF CM server names + description: name of the PCRF CM instance + pcm_image_name: + type: string + label: PCRF CM image name + description: PCRF CM image name + pcm_flavor_name: + type: string + label: PCRF CM flavor name + description: flavor name of PCRF CM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + cps_net_name: + type: string + label: CPS network name + description: CPS network name + cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + oam_net_name: + type: string + label: OAM network name + description: OAM network name + oam_net_ips: + type: comma_delimited_list + label: OAM network ips + description: OAM network ips + oam_net_gw: + type: string + label: CPS network gateway + description: CPS network gateway + oam_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcm_volumes: + type: comma_delimited_list + label: CPS Cluman Cinder Volume + description: CPS Cluman Cinder Volume + security_group_name: + type: string + label: security group name + description: the name of security group + +resources: + server_pcm_001: + type: nested-pcm_v0.1.yaml + properties: + availabilityzone_name: { get_param: availabilityzone_name } + security_group_name: { get_param: security_group_name } + pcm_vol: { get_param: [pcm_volumes, 0] } + cps_net_name: { get_param: cps_net_name } + cps_net_ip: { get_param: [cps_net_ips, 0] } + cps_net_mask: { get_param: cps_net_mask } + oam_net_name: { get_param: oam_net_name } + oam_net_ip: { get_param: [oam_net_ips, 0] } + oam_net_mask: { get_param: oam_net_mask } + oam_net_gw: { get_param: oam_net_gw } + + server_pcm_002: + type: nested-pcm_v0.1.yaml + properties: + pcm_server_name: { get_param: [pcm_server_names, 0] } + pcm_image_name: { get_param: pcm_image_name } + pcm_flavor_name: { get_param: pcm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + security_group_name: { get_param: security_group_name } + pcm_vol: { get_param: [pcm_volumes, 0] } diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/inputs/hot-nimbus-pcm_v0.4_2.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/inputs/hot-nimbus-pcm_v0.4_2.yaml new file mode 100644 index 0000000000..b59df84764 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/inputs/hot-nimbus-pcm_v0.4_2.yaml @@ -0,0 +1,79 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Cluman stack + +parameters: + pcm_server_names: + type: comma_delimited_list + label: PCRF CM server names + description: name of the PCRF CM instance + pcm_image_name: + type: string + label: PCRF CM image name + description: PCRF CM image name + pcm_flavor_name: + type: string + label: PCRF CM flavor name + description: flavor name of PCRF CM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + cps_net_name: + type: string + label: CPS network name + description: CPS network name + cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + oam_net_name: + type: string + label: OAM network name + description: OAM network name + oam_net_ips: + type: comma_delimited_list + label: OAM network ips + description: OAM network ips + oam_net_gw: + type: string + label: CPS network gateway + description: CPS network gateway + oam_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcm_volumes: + type: comma_delimited_list + label: CPS Cluman Cinder Volume + description: CPS Cluman Cinder Volume + security_group_name: + type: string + label: security group name + description: the name of security group + +resources: + server_pcm_003: + type: nested-pcm_v0.1.yaml + properties: + availabilityzone_name: { get_param: availabilityzone_name } + security_group_name: { get_param: security_group_name } + pcm_vol: { get_param: [pcm_volumes, 0] } + cps_net_name: { get_param: cps_net_name } + cps_net_ip: { get_param: [cps_net_ips, 0] } + cps_net_mask: { get_param: cps_net_mask } + + server_pcm_004: + type: nested-pcm_v0.1_2.yaml + properties: + availabilityzone_name: { get_param: availabilityzone_name } + security_group_name: { get_param: security_group_name } + pcm_vol: { get_param: [pcm_volumes, 0] } + cps_net_name: { get_param: cps_net_name } + cps_net_ip: { get_param: [cps_net_ips, 0] } + cps_net_mask: { get_param: cps_net_mask } + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/inputs/nested-pcm_v0.1.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/inputs/nested-pcm_v0.1.yaml new file mode 100644 index 0000000000..66a03796fb --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/inputs/nested-pcm_v0.1.yaml @@ -0,0 +1,138 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Cluman stack + +parameters: + pcm_server_name: + type: string + label: PCRF CM server name + description: PCRF CM server name + pcm_image_name: + type: string + label: image name + description: PCRF CM image name + pcm_flavor_name: + type: string + label: PCRF CM flavor name + description: flavor name of PCRF CM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + cps_net_name: + type: string + label: CPS network name + description: CPS network name + cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + cps_net_ips: + type: string + label: CPS network ip + description: CPS network ip + cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + oam_net_name: + type: string + label: OAM network name + description: OAM network name + oam_net_ip: + type: string + label: OAM network ip + description: OAM network ip + oam_net_gw: + type: string + label: CPS network gateway + description: CPS network gateway + oam_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcm_vol: + type: string + label: CPS Cluman Cinder Volume + description: CPS Cluman Cinder Volume + pcm_volumes: + type: string + label: CPS Cluman Cinder Volume + description: CPS Cluman Cinder Volume + security_group_name: + type: string + label: security group name + description: the name of security group + +resources: + server_pcm_005: + type: nested-pcm_v0.1_2.yaml + properties: + availabilityzone_name: { get_param: availabilityzone_name } + security_group_name: { get_param: security_group_name } + pcm_vol: { get_param: [pcm_volumes, 0] } + cps_net_name: { get_param: cps_net_name } + cps_net_ip: { get_param: [cps_net_ips, 0] } + cps_net_mask: { get_param: cps_net_mask } + server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + script_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + + network: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: cps_net_name} + + server_pcm: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcm_server_name } + image: { get_param: pcm_image_name } + flavor: { get_param: pcm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcm_port_0} + - port: { get_resource: pcm_port_1} + block_device_mapping: + - device_name: vdb + volume_id: { get_param: pcm_vol} + user_data_format: RAW + user_data: + get_resource: server_init + + pcm_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: cps_net_name } + fixed_ips: + - ip_address: { get_param: cps_net_ip } + security_groups: [{ get_param: security_group_name }] + + pcm_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: + - ip_address: { get_param: oam_net_ip } + security_groups: [{ get_param: security_group_name }] + + #pcm_vol_attachment: + # type: OS::Cinder::VolumeAttachment + # properties: + # volume_id: { get_param: pcm_vol } + # mountpoint: /dev/vdb + # instance_uuid: { get_resource: server_pcm } +outputs: + server_pcm_id: + description: the pcm nova service id + value: { get_resource: server_pcm } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/inputs/nested-pcm_v0.1_2.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/inputs/nested-pcm_v0.1_2.yaml new file mode 100644 index 0000000000..11be0dd63b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/recursive/inputs/nested-pcm_v0.1_2.yaml @@ -0,0 +1,110 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Cluman stack + +parameters: + pcm_server_name: + type: string + label: PCRF CM server name + description: PCRF CM server name + pcm_image_name: + type: string + label: image name + description: PCRF CM image name + pcm_flavor_name: + type: string + label: PCRF CM flavor name + description: flavor name of PCRF CM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + cps_net_name: + type: string + label: CPS network name + description: CPS network name + cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcm_vol: + type: string + label: CPS Cluman Cinder Volume + description: CPS Cluman Cinder Volume + security_group_name: + type: string + label: security group name + description: the name of security group + oam_net_name: + type: string + label: OAM network name + description: OAM network name + oam_net_ip: + type: string +resources: + server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + script_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + + network: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: cps_net_name} + + server_pcm: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcm_server_name } + image: { get_param: pcm_image_name } + flavor: { get_param: pcm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcm_port_0} + - port: { get_resource: pcm_port_1} + block_device_mapping: + - device_name: vdb + volume_id: { get_param: pcm_vol} + user_data_format: RAW + user_data: + get_resource: server_init + + pcm_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: cps_net_name } + fixed_ips: + - ip_address: { get_param: cps_net_ip } + security_groups: [{ get_param: security_group_name }] + + pcm_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: + - ip_address: { get_param: oam_net_ip } + security_groups: [{ get_param: security_group_name }] + + #pcm_vol_attachment: + # type: OS::Cinder::VolumeAttachment + # properties: + # volume_id: { get_param: pcm_vol } + # mountpoint: /dev/vdb + # instance_uuid: { get_resource: server_pcm } +outputs: + server_pcm_id: + description: the pcm nova service id + value: { get_resource: server_pcm } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupIndexVar/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupIndexVar/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..15b5e3b3a8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupIndexVar/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,161 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.mvs.nested.heat: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + vf_module_id: + type: string + description: Unique ID for this VF_MODULE instance + vf_name: + type: string + description: The VF Name; defaults to VMVM for the virtual MVM VNF. + constraints: + - pattern: '[a-zA-Z0-9]+' + - max_length: 4 + - min_length: 4 + cloud_zone_id: + type: string + description: The cloud zone for this VF instance + vf_instance_num: + type: string + description: The number for this VF instance + constraints: + - pattern: '[0-9]+' + - max_length: 2 + - min_length: 2 + virtual_mgmt_ip_0: + type: string + description: Virtual management network ip address + indx: + type: float + description: Index of the current instance + mvs_mgmt_ip_0: + type: list + description: List of Management network IP addresses for IPv4 + entry_schema: + type: string + flavor: + type: string + description: Server flavor + constraints: [ + ] + key_name: + type: string + description: SSH key name + constraints: [ + ] + vnf_id: + type: string + description: Unique ID for this VF instance + availability_zone_0: + type: list + description: List of Availability Zone IDs or Names + entry_schema: + type: string + mgmt_net_id: + type: string + description: Neutron UUID for the Management network + constraints: [ + ] + vm_instance_num: + type: list + description: VM instance number list must be a list of three-digit numeric value + entry_schema: + type: string + bootimage: + type: string + description: Master bootimage volume id + sec_groups: + type: list + description: Security groups + entry_schema: + type: string + vf_component: + type: string + description: The component that this VF instance is running + constraints: + - pattern: '[a-zA-Z0-9]+' + - max_length: 3 + - min_length: 3 + attributes: + vnfci_id_2: + type: string + vnfci_id_1: + type: string + requirements: + - local_storage_vnfci: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_mgmt_port: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + os_vnfci: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + attachment_mgmt_port: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + endpoint_vnfci: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + host_vnfci: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + binding_vnfci: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + scalable_vnfci: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupIndexVar/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupIndexVar/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..b07fa5b70b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupIndexVar/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,569 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.compute: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + vf_module_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VF_MODULE instance + vf_name: + hidden: false + immutable: false + type: string + description: The VF Name; defaults to VMVM for the virtual MVM VNF. + constraints: + - pattern: '[a-zA-Z0-9]+' + - max_length: 4 + - min_length: 4 + type_name: + hidden: false + immutable: false + type: string + cloud_zone_id: + hidden: false + immutable: false + type: string + description: The cloud zone for this VF instance + vf_instance_num: + hidden: false + immutable: false + type: string + description: The number for this VF instance + constraints: + - pattern: '[0-9]+' + - max_length: 2 + - min_length: 2 + virtual_mgmt_ip_0: + hidden: false + immutable: false + type: string + description: Virtual management network ip address + mvs_mgmt_ip_0: + hidden: false + immutable: false + type: list + description: List of Management network IP addresses for IPv4 + entry_schema: + type: string + compute_image_name: + hidden: false + immutable: false + type: string + flavor: + hidden: false + immutable: false + type: string + description: Server flavor + constraints: [ + ] + key_name: + hidden: false + immutable: false + type: string + description: SSH key name + constraints: [ + ] + vnf_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VF instance + availability_zone_0: + hidden: false + immutable: false + type: list + description: List of Availability Zone IDs or Names + entry_schema: + type: string + mgmt_net_id: + hidden: false + immutable: false + type: string + description: Neutron UUID for the Management network + constraints: [ + ] + vm_instance_num: + hidden: false + immutable: false + type: list + description: VM instance number list must be a list of three-digit numeric value + entry_schema: + type: string + bootimage: + hidden: false + immutable: false + type: string + description: Master bootimage volume id + sec_groups: + hidden: false + immutable: false + type: list + description: Security groups + entry_schema: + type: string + vf_component: + hidden: false + immutable: false + type: string + description: The component that this VF instance is running + constraints: + - pattern: '[a-zA-Z0-9]+' + - max_length: 3 + - min_length: 3 + num_instances: + hidden: false + immutable: false + type: float + description: number of instance of the VF_module + node_templates: + mvs_modules_custIndexVar2: + type: org.openecomp.resource.abstract.nodes.heat.mvs.nested.heat + directives: + - substitutable + properties: + vf_module_id: + - get_input: vf_module_id + - get_property: + - SELF + - service_template_filter + - index_value + - concat: + - fff + - get_property: + - SELF + - service_template_filter + - index_value + vf_name: + concat: + - get_property: + - SELF + - service_template_filter + - index_value + - vf_name + cloud_zone_id: + concat: + - cloud_zone_id_ + - get_property: + - SELF + - service_template_filter + - index_value + vf_instance_num: + concat: + - vf_instance_num_ + - get_property: + - SELF + - service_template_filter + - index_value + - _bbbb + virtual_mgmt_ip_0: + get_input: virtual_mgmt_ip_0 + indx: + get_property: + - SELF + - service_template_filter + - index_value + mvs_mgmt_ip_0: mvs_mgmt_ip_0 + flavor: + a: a + b: b + e: + get_property: + - SELF + - service_template_filter + - index_value + w: + concat: + - get_property: + - SELF + - service_template_filter + - index_value + - _pp + key_name: + - a + - b + - get_property: + - SELF + - service_template_filter + - index_value + - concat: + - p + - get_property: + - SELF + - service_template_filter + - index_value + service_template_filter: + substitute_service_template: mvs.nested.heatServiceTemplate.yaml + count: 2 + mandatory: true + vnf_id: null + availability_zone_0: + get_input: availability_zone_0 + mgmt_net_id: + get_input: mgmt_net_id + vm_instance_num: + concat: + - get_property: + - SELF + - service_template_filter + - index_value + - _vm_instance_num_ + - get_property: + - SELF + - service_template_filter + - index_value + - _hhh_ + - get_property: + - SELF + - service_template_filter + - index_value + - get_property: + - SELF + - service_template_filter + - index_value + - get_property: + - SELF + - service_template_filter + - index_value + - _pppp + - get_property: + - SELF + - service_template_filter + - index_value + bootimage: + get_input: bootimage + sec_groups: + get_input: sec_groups + vf_component: + get_property: + - SELF + - service_template_filter + - index_value + mvs_modules_custIndexVar1: + type: org.openecomp.resource.abstract.nodes.heat.mvs.nested.heat + directives: + - substitutable + properties: + vf_module_id: + - get_input: vf_module_id + - get_property: + - SELF + - service_template_filter + - index_value + - concat: + - fff + - get_property: + - SELF + - service_template_filter + - index_value + vf_name: + concat: + - get_property: + - SELF + - service_template_filter + - index_value + - vf_name + cloud_zone_id: + concat: + - cloud_zone_id_ + - get_property: + - SELF + - service_template_filter + - index_value + vf_instance_num: + concat: + - vf_instance_num_ + - get_property: + - SELF + - service_template_filter + - index_value + - _bbbb + virtual_mgmt_ip_0: + get_input: virtual_mgmt_ip_0 + indx: + get_property: + - SELF + - service_template_filter + - index_value + mvs_mgmt_ip_0: mvs_mgmt_ip_0 + flavor: + a: a + b: b + e: + get_property: + - SELF + - service_template_filter + - index_value + w: + concat: + - get_property: + - SELF + - service_template_filter + - index_value + - _pp + key_name: + - a + - b + - get_property: + - SELF + - service_template_filter + - index_value + - concat: + - p + - get_property: + - SELF + - service_template_filter + - index_value + service_template_filter: + substitute_service_template: mvs.nested.heatServiceTemplate.yaml + count: 2 + mandatory: true + vnf_id: null + availability_zone_0: + get_input: availability_zone_0 + mgmt_net_id: + get_input: mgmt_net_id + vm_instance_num: + concat: + - get_property: + - SELF + - service_template_filter + - index_value + - _vm_instance_num_ + - get_property: + - SELF + - service_template_filter + - index_value + - _hhh_ + - get_property: + - SELF + - service_template_filter + - index_value + - get_property: + - SELF + - service_template_filter + - index_value + - get_property: + - SELF + - service_template_filter + - index_value + - _pppp + - get_property: + - SELF + - service_template_filter + - index_value + bootimage: + get_input: bootimage + sec_groups: + get_input: sec_groups + vf_component: + get_property: + - SELF + - service_template_filter + - index_value + mvs_modules_defaultIndexVar: + type: org.openecomp.resource.abstract.nodes.heat.mvs.nested.heat + directives: + - substitutable + properties: + vf_module_id: + - get_input: vf_module_id + - get_property: + - SELF + - service_template_filter + - index_value + - concat: + - fff + - get_property: + - SELF + - service_template_filter + - index_value + vf_name: + concat: + - get_property: + - SELF + - service_template_filter + - index_value + - vf_name + cloud_zone_id: + concat: + - cloud_zone_id_ + - get_property: + - SELF + - service_template_filter + - index_value + vf_instance_num: + concat: + - vf_instance_num_ + - get_property: + - SELF + - service_template_filter + - index_value + - _bbbb + virtual_mgmt_ip_0: + get_input: virtual_mgmt_ip_0 + indx: + get_property: + - SELF + - service_template_filter + - index_value + mvs_mgmt_ip_0: mvs_mgmt_ip_0 + flavor: + a: a + b: + aa: + - sss + - concat: + - dddd + - get_property: + - SELF + - service_template_filter + - index_value + - ppp + - sd + ppp: + concat: + - get_property: + - SELF + - service_template_filter + - index_value + - _pppp___ + - get_property: + - SELF + - service_template_filter + - index_value + eeee: eeeeeee + e: + get_property: + - SELF + - service_template_filter + - index_value + w: + concat: + - get_property: + - SELF + - service_template_filter + - index_value + - _pp + key_name: + - a + - b + - get_property: + - SELF + - service_template_filter + - index_value + - concat: + - p + - get_property: + - SELF + - service_template_filter + - index_value + service_template_filter: + substitute_service_template: mvs.nested.heatServiceTemplate.yaml + count: 3 + mandatory: true + vnf_id: null + availability_zone_0: + get_input: availability_zone_0 + mgmt_net_id: + get_input: mgmt_net_id + vm_instance_num: + concat: + - get_property: + - SELF + - service_template_filter + - index_value + - _vm_instance_num_ + - get_property: + - SELF + - service_template_filter + - index_value + - _hhh_ + - get_property: + - SELF + - service_template_filter + - index_value + - get_property: + - SELF + - service_template_filter + - index_value + - get_property: + - SELF + - service_template_filter + - index_value + - _pppp + - get_property: + - SELF + - service_template_filter + - index_value + bootimage: + get_input: bootimage + sec_groups: + get_input: sec_groups + vf_component: + get_property: + - SELF + - service_template_filter + - index_value + server_compute_get_attr_test: + type: org.openecomp.resource.vfc.nodes.heat.compute + properties: + flavor: compute_flavor_name + image: + get_input: compute_image_name + config_drive: + get_attribute: + - mvs_modules_defaultIndexVar + - vnfci_id_1 + - vnfci_id_2 + user_data_format: + get_attribute: + - mvs_modules_defaultIndexVar + - vnfci_id_1 + - 1 + name: compute_name + groups: + mvs.vfmodule.heat: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/mvs.vfmodule.heat.yaml + description: | + Metaswitch MVS (Metaview Server) + members: + - mvs_modules_custIndexVar2 + - mvs_modules_custIndexVar1 + - mvs_modules_defaultIndexVar + - server_compute_get_attr_test \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupIndexVar/expectedoutputfiles/mvs.nested.heatServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupIndexVar/expectedoutputfiles/mvs.nested.heatServiceTemplate.yaml new file mode 100644 index 0000000000..11369f9b68 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupIndexVar/expectedoutputfiles/mvs.nested.heatServiceTemplate.yaml @@ -0,0 +1,254 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: mvs.nested.heat +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.vnfci: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + vf_module_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VF_MODULE instance + vf_name: + hidden: false + immutable: false + type: string + description: The VF Name; defaults to VMVM for the virtual MVM VNF. + constraints: + - pattern: '[a-zA-Z0-9]+' + - max_length: 4 + - min_length: 4 + cloud_zone_id: + hidden: false + immutable: false + type: string + description: The cloud zone for this VF instance + vf_instance_num: + hidden: false + immutable: false + type: string + description: The number for this VF instance + constraints: + - pattern: '[0-9]+' + - max_length: 2 + - min_length: 2 + virtual_mgmt_ip_0: + hidden: false + immutable: false + type: string + description: Virtual management network ip address + indx: + hidden: false + immutable: false + type: float + description: Index of the current instance + mvs_mgmt_ip_0: + hidden: false + immutable: false + type: list + description: List of Management network IP addresses for IPv4 + entry_schema: + type: string + flavor: + hidden: false + immutable: false + type: string + description: Server flavor + constraints: [ + ] + key_name: + hidden: false + immutable: false + type: string + description: SSH key name + constraints: [ + ] + vnf_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VF instance + availability_zone_0: + hidden: false + immutable: false + type: list + description: List of Availability Zone IDs or Names + entry_schema: + type: string + mgmt_net_id: + hidden: false + immutable: false + type: string + description: Neutron UUID for the Management network + constraints: [ + ] + vm_instance_num: + hidden: false + immutable: false + type: list + description: VM instance number list must be a list of three-digit numeric value + entry_schema: + type: string + bootimage: + hidden: false + immutable: false + type: string + description: Master bootimage volume id + sec_groups: + hidden: false + immutable: false + type: list + description: Security groups + entry_schema: + type: string + vf_component: + hidden: false + immutable: false + type: string + description: The component that this VF instance is running + constraints: + - pattern: '[a-zA-Z0-9]+' + - max_length: 3 + - min_length: 3 + node_templates: + vnfci: + type: org.openecomp.resource.vfc.nodes.heat.vnfci + properties: + flavor: + get_input: flavor + key_name: + get_input: key_name + availability_zone: + Fn::Select: + - get_input: indx + - get_input: + - availability_zone_0 + name: + str_replace: + template: Z$CLOUD_ZONE_ID$VF_NAME$VF_INSTANCE_NUM$VF_COMPONENT$VM_INSTANCE_NUM + params: + $VF_NAME: + get_input: vf_name + $CLOUD_ZONE_ID: + get_input: cloud_zone_id + $VM_INSTANCE_NUM: + Fn::Select: + - get_input: indx + - get_input: + - vm_instance_num + $VF_COMPONENT: + get_input: vf_component + $VF_INSTANCE_NUM: + get_input: vf_instance_num + mgmt_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: sec_groups + fixed_ips: + - ip_address: + Fn::Select: + - get_input: indx + - get_input: + - get_input: mvs_mgmt_ip_0 + allowed_address_pairs: + - ip_address: + get_input: virtual_mgmt_ip_0 + name: + str_replace: + template: Z$CLOUD_ZONE_ID$VF_NAME$VF_INSTANCE_NUM$VF_COMPONENT$VM_INSTANCE_NUM-mgmt-port + params: + $VF_NAME: + get_input: vf_name + $CLOUD_ZONE_ID: + get_input: cloud_zone_id + $VM_INSTANCE_NUM: + Fn::Select: + - get_input: indx + - get_input: + - vm_instance_num + $VF_COMPONENT: + get_input: vf_component + $VF_INSTANCE_NUM: + get_input: vf_instance_num + network: + get_input: mgmt_net_id + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: vnfci + relationship: tosca.relationships.network.BindsTo + groups: + mvs.nested.heat: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/mvs.nested.heat.yaml + description: | + Metaswitch MVS (Metaview Server) + members: + - vnfci + - mgmt_port + outputs: + vnfci_id_2: + value: vnfci + vnfci_id_1: + value: vnfci + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.mvs.nested.heat + capabilities: + os_vnfci: + - vnfci + - os + attachment_mgmt_port: + - mgmt_port + - attachment + endpoint_vnfci: + - vnfci + - endpoint + host_vnfci: + - vnfci + - host + binding_vnfci: + - vnfci + - binding + scalable_vnfci: + - vnfci + - scalable + requirements: + local_storage_vnfci: + - vnfci + - local_storage + link_mgmt_port: + - mgmt_port + - link \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupIndexVar/inputs/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupIndexVar/inputs/MANIFEST.json new file mode 100644 index 0000000000..c7729c8653 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupIndexVar/inputs/MANIFEST.json @@ -0,0 +1,19 @@ +{ + "name": "mvs.vfmodule.heat.yaml", + "description": "Metaswitch MVS (Metaview Server)", + "version": "2013-05-23", + "data": [ + { + "file": "mvs.vfmodule.heat.yaml", + "type": "HEAT", + "data": [ + ] + }, + { + "file": "mvs.nested.heat.yaml", + "type": "HEAT", + "data": [ + ] + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupIndexVar/inputs/mvs.nested.heat.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupIndexVar/inputs/mvs.nested.heat.yaml new file mode 100644 index 0000000000..01adb51d71 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupIndexVar/inputs/mvs.nested.heat.yaml @@ -0,0 +1,129 @@ +heat_template_version: 2013-05-23 + +description: > + Metaswitch MVS (Metaview Server) + +parameters: + cloud_zone_id: + type: string + description: The cloud zone for this VF instance + vf_name: + type: string + description: The VF Name; defaults to VMVM for the virtual MVM VNF. + constraints: + - allowed_pattern: "[a-zA-Z0-9]+" + - length: { min: 4, max: 4 } + description: Each VF will have a 4-character alphanumeric identifier + vf_instance_num: + type: string + description: The number for this VF instance + constraints: + - allowed_pattern: "[0-9]+" + - length: { min: 2, max: 2 } + description: VF instance number must be a two-digit numeric value + vf_component: + type: string + description: The component that this VF instance is running + constraints: + - allowed_pattern: "[a-zA-Z0-9]+" + - length: { min: 3, max: 3 } + description: Each VF component will have a 3-character alphanumeric identifier + vm_instance_num: + type: comma_delimited_list + description: VM instance number list must be a list of three-digit numeric value + vnf_id: + type: string + description: Unique ID for this VF instance + vf_module_id: + type: string + description: Unique ID for this VF_MODULE instance + bootimage: + type: string + description: Master bootimage volume id + flavor: + type: string + description: Server flavor + constraints: + - custom_constraint: nova.flavor + key_name: + type: string + description: SSH key name + constraints: + - custom_constraint: nova.keypair + + availability_zone_0: + type: comma_delimited_list + description: List of Availability Zone IDs or Names + + sec_groups: + type: comma_delimited_list + description: Security groups + mgmt_net_id: + type: string + description: Neutron UUID for the Management network + constraints: + - custom_constraint: neutron.network + virtual_mgmt_ip_0: + type: string + description: Virtual management network ip address + + mvs_mgmt_ip_0: + type: comma_delimited_list + description: List of Management network IP addresses for IPv4 + + indx: + type: number + description: Index of the current instance + +resources: + mgmt_port: + type: OS::Neutron::Port + properties: + name: + str_replace: + template: Z$CLOUD_ZONE_ID$VF_NAME$VF_INSTANCE_NUM$VF_COMPONENT$VM_INSTANCE_NUM-mgmt-port + params: + $CLOUD_ZONE_ID: { get_param: cloud_zone_id } + $VF_NAME: { get_param: vf_name } + $VF_INSTANCE_NUM: { get_param: vf_instance_num } + $VF_COMPONENT: { get_param: vf_component } + $VM_INSTANCE_NUM: { "Fn::Select" : [ { get_param: indx }, { get_param: [vm_instance_num] } ] } + network_id: { get_param: mgmt_net_id } + security_groups: [{ get_param: sec_groups }] + + fixed_ips: + - ip_address: { "Fn::Select" : [ { get_param: indx }, { get_param: [{ get_param: mvs_mgmt_ip_0 }] } ] } + + allowed_address_pairs: + - ip_address: { get_param: virtual_mgmt_ip_0 } + + + + vnfci: + type: OS::Nova::Server + properties: + name: + str_replace: + template: Z$CLOUD_ZONE_ID$VF_NAME$VF_INSTANCE_NUM$VF_COMPONENT$VM_INSTANCE_NUM + params: + $CLOUD_ZONE_ID: { get_param: cloud_zone_id } + $VF_NAME: { get_param: vf_name } + $VF_INSTANCE_NUM: { get_param: vf_instance_num } + $VF_COMPONENT: { get_param: vf_component } + $VM_INSTANCE_NUM: { "Fn::Select" : [ { get_param: indx }, { get_param: [vm_instance_num] } ] } + flavor: { get_param: flavor } + key_name: { get_param: key_name } + networks: + - port: { get_resource: mgmt_port } + + availability_zone: { "Fn::Select" : [ { get_param: indx }, { get_param: [availability_zone_0] } ] } + + metadata: + vnf_id: { get_param: vnf_id } + vf_module_id: { get_param: vf_module_id } + +outputs: + vnfci_id_1: + value: { get_resource: vnfci } + vnfci_id_2: + value: { get_resource: vnfci } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupIndexVar/inputs/mvs.vfmodule.heat.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupIndexVar/inputs/mvs.vfmodule.heat.yaml new file mode 100644 index 0000000000..6b42078b21 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupIndexVar/inputs/mvs.vfmodule.heat.yaml @@ -0,0 +1,228 @@ +heat_template_version: 2013-05-23 + +description: > + Metaswitch MVS (Metaview Server) + +parameters: + cloud_zone_id: + type: string + description: The cloud zone for this VF instance + vf_name: + type: string + description: The VF Name; defaults to VMVM for the virtual MVM VNF. + constraints: + - allowed_pattern: "[a-zA-Z0-9]+" + - length: { min: 4, max: 4 } + description: Each VF will have a 4-character alphanumeric identifier + vf_instance_num: + type: string + description: The number for this VF instance + constraints: + - allowed_pattern: "[0-9]+" + - length: { min: 2, max: 2 } + description: VF instance number must be a two-digit numeric value + vf_component: + type: string + description: The component that this VF instance is running + constraints: + - allowed_pattern: "[a-zA-Z0-9]+" + - length: { min: 3, max: 3 } + description: Each VF component will have a 3-character alphanumeric identifier + vm_instance_num: + type: comma_delimited_list + description: VM instance number list must be a list of three-digit numeric value + vnf_id: + type: string + description: Unique ID for this VF instance + vf_module_id: + type: string + description: Unique ID for this VF_MODULE instance + bootimage: + type: string + description: Master bootimage volume id + flavor: + type: string + description: Server flavor + constraints: + - custom_constraint: nova.flavor + key_name: + type: string + description: SSH key name + constraints: + - custom_constraint: nova.keypair + type_name: + type: string + availability_zone_0: + type: comma_delimited_list + description: List of Availability Zone IDs or Names + + sec_groups: + type: comma_delimited_list + description: Security groups + mgmt_net_id: + type: string + description: Neutron UUID for the Management network + constraints: + - custom_constraint: neutron.network + virtual_mgmt_ip_0: + type: string + description: Virtual management network ip address + + mvs_mgmt_ip_0: + type: comma_delimited_list + description: List of Management network IP addresses for IPv4 + + num_instances: + type: number + description: number of instance of the VF_module + + compute_image_name: + type: string + +resources: + mvs_modules_defaultIndexVar: + type: OS::Heat::ResourceGroup + properties: + count: 3 + resource_def: + type: mvs.nested.heat.yaml + properties: + cloud_zone_id: cloud_zone_id_%index% + vf_name: "%index%vf_name" + vf_instance_num: "vf_instance_num_%index%_bbbb" + vf_component: "%index%" + vm_instance_num: "%index%_vm_instance_num_%index%_hhh_%index%%index%%index%_pppp%index%" + vnf_id: + vf_module_id: [{ get_param: vf_module_id }, "%index%", fff%index% ] + bootimage: { get_param: bootimage } + flavor: + a: a + b: + aa: [sss,dddd%index%ppp, sd] + ppp: "%index%_pppp___%index%" + eeee: eeeeeee + e: "%index%" + w: "%index%_pp" + key_name: [a,b,"%index%",p%index%] + availability_zone_0: { get_param: availability_zone_0 } + sec_groups: { get_param: sec_groups } + mgmt_net_id: { get_param: mgmt_net_id } + virtual_mgmt_ip_0: { get_param: virtual_mgmt_ip_0 } + mvs_mgmt_ip_0: mvs_mgmt_ip_0 + indx: "%index%" + + mvs_modules_custIndexVar1: + type: OS::Heat::ResourceGroup + properties: + count: 2 + index_var: myIndex + resource_def: + type: mvs.nested.heat.yaml + properties: + cloud_zone_id: cloud_zone_id_myIndex + vf_name: "myIndexvf_name" + vf_instance_num: "vf_instance_num_myIndex_bbbb" + vf_component: "myIndex" + vm_instance_num: "myIndex_vm_instance_num_myIndex_hhh_myIndexmyIndexmyIndex_ppppmyIndex" + vnf_id: + vf_module_id: [{ get_param: vf_module_id }, "myIndex", fffmyIndex ] + bootimage: { get_param: bootimage } + flavor: + a: a + b: b + e: myIndex + w: myIndex_pp + key_name: [a,b,myIndex,pmyIndex] + availability_zone_0: { get_param: availability_zone_0 } + sec_groups: { get_param: sec_groups } + mgmt_net_id: { get_param: mgmt_net_id } + virtual_mgmt_ip_0: { get_param: virtual_mgmt_ip_0 } + mvs_mgmt_ip_0: mvs_mgmt_ip_0 + indx: "myIndex" + + mvs_modules_custIndexVar2: + type: OS::Heat::ResourceGroup + properties: + count: 2 + index_var: "%myIndex%" + resource_def: + type: mvs.nested.heat.yaml + properties: + cloud_zone_id: cloud_zone_id_%myIndex% + vf_name: "%myIndex%vf_name" + vf_instance_num: "vf_instance_num_%myIndex%_bbbb" + vf_component: "%myIndex%" + vm_instance_num: "%myIndex%_vm_instance_num_%myIndex%_hhh_%myIndex%%myIndex%%myIndex%_pppp%myIndex%" + vnf_id: + vf_module_id: [{ get_param: vf_module_id }, "%myIndex%", fff%myIndex% ] + bootimage: { get_param: bootimage } + flavor: + a: a + b: b + e: "%myIndex%" + w: "%myIndex%_pp" + key_name: [a,b,"%myIndex%",p%myIndex%] + availability_zone_0: { get_param: availability_zone_0 } + sec_groups: { get_param: sec_groups } + mgmt_net_id: { get_param: mgmt_net_id } + virtual_mgmt_ip_0: { get_param: virtual_mgmt_ip_0 } + mvs_mgmt_ip_0: mvs_mgmt_ip_0 + indx: "%myIndex%" + + not_supported_resourceGroup1: + type: OS::Heat::ResourceGroup + properties: + count: 3 + resource_def: + type: OS::Heat::ResourceGroup + properties: + cloud_zone_id: { get_param: cloud_zone_id } + vf_name: { get_param: vf_name } + vf_instance_num: { get_param: vf_instance_num } + vf_component: { get_param: vf_component } + vm_instance_num: { get_param: vm_instance_num } + vnf_id: { get_param: vnf_id } + vf_module_id: { get_param: vf_module_id } + bootimage: { get_param: bootimage } + flavor: { get_param: flavor } + key_name: { get_param: key_name } + availability_zone_0: { get_param: availability_zone_0 } + sec_groups: { get_param: sec_groups } + mgmt_net_id: { get_param: mgmt_net_id } + virtual_mgmt_ip_0: { get_param: virtual_mgmt_ip_0 } + mvs_mgmt_ip_0: { get_param: mvs_mgmt_ip_0 } + indx: "%index%" + + not_supported_resourceGroup2: + type: OS::Heat::ResourceGroup + properties: + count: 3 + resource_def: + type: { get_param: type_name } + properties: + cloud_zone_id: { get_param: cloud_zone_id } + vf_name: { get_param: vf_name } + vf_instance_num: { get_param: vf_instance_num } + vf_component: { get_param: vf_component } + vm_instance_num: { get_param: vm_instance_num } + vnf_id: { get_param: vnf_id } + vf_module_id: { get_param: vf_module_id } + bootimage: { get_param: bootimage } + flavor: { get_param: flavor } + key_name: { get_param: key_name } + availability_zone_0: { get_param: availability_zone_0 } + sec_groups: { get_param: sec_groups } + mgmt_net_id: { get_param: mgmt_net_id } + virtual_mgmt_ip_0: { get_param: virtual_mgmt_ip_0 } + mvs_mgmt_ip_0: { get_param: mvs_mgmt_ip_0 } + indx: "%index%" + + server_compute_get_attr_test: + type: OS::Nova::Server + properties: + config_drive: {get_attr: [mvs_modules_defaultIndexVar]} + name: compute_name + image: { get_param: compute_image_name } + flavor: compute_flavor_name + user_data_format: { get_attr: [mvs_modules_defaultIndexVar , resource.1.vnfci_id_1] } + user_data: { get_attr: [mvs_modules_defaultIndexVar, resource.vnfci_id_2]} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupInvalid/inputs/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupInvalid/inputs/MANIFEST.json new file mode 100644 index 0000000000..c7729c8653 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupInvalid/inputs/MANIFEST.json @@ -0,0 +1,19 @@ +{ + "name": "mvs.vfmodule.heat.yaml", + "description": "Metaswitch MVS (Metaview Server)", + "version": "2013-05-23", + "data": [ + { + "file": "mvs.vfmodule.heat.yaml", + "type": "HEAT", + "data": [ + ] + }, + { + "file": "mvs.nested.heat.yaml", + "type": "HEAT", + "data": [ + ] + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupInvalid/inputs/mvs.nested.heat.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupInvalid/inputs/mvs.nested.heat.yaml new file mode 100644 index 0000000000..01adb51d71 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupInvalid/inputs/mvs.nested.heat.yaml @@ -0,0 +1,129 @@ +heat_template_version: 2013-05-23 + +description: > + Metaswitch MVS (Metaview Server) + +parameters: + cloud_zone_id: + type: string + description: The cloud zone for this VF instance + vf_name: + type: string + description: The VF Name; defaults to VMVM for the virtual MVM VNF. + constraints: + - allowed_pattern: "[a-zA-Z0-9]+" + - length: { min: 4, max: 4 } + description: Each VF will have a 4-character alphanumeric identifier + vf_instance_num: + type: string + description: The number for this VF instance + constraints: + - allowed_pattern: "[0-9]+" + - length: { min: 2, max: 2 } + description: VF instance number must be a two-digit numeric value + vf_component: + type: string + description: The component that this VF instance is running + constraints: + - allowed_pattern: "[a-zA-Z0-9]+" + - length: { min: 3, max: 3 } + description: Each VF component will have a 3-character alphanumeric identifier + vm_instance_num: + type: comma_delimited_list + description: VM instance number list must be a list of three-digit numeric value + vnf_id: + type: string + description: Unique ID for this VF instance + vf_module_id: + type: string + description: Unique ID for this VF_MODULE instance + bootimage: + type: string + description: Master bootimage volume id + flavor: + type: string + description: Server flavor + constraints: + - custom_constraint: nova.flavor + key_name: + type: string + description: SSH key name + constraints: + - custom_constraint: nova.keypair + + availability_zone_0: + type: comma_delimited_list + description: List of Availability Zone IDs or Names + + sec_groups: + type: comma_delimited_list + description: Security groups + mgmt_net_id: + type: string + description: Neutron UUID for the Management network + constraints: + - custom_constraint: neutron.network + virtual_mgmt_ip_0: + type: string + description: Virtual management network ip address + + mvs_mgmt_ip_0: + type: comma_delimited_list + description: List of Management network IP addresses for IPv4 + + indx: + type: number + description: Index of the current instance + +resources: + mgmt_port: + type: OS::Neutron::Port + properties: + name: + str_replace: + template: Z$CLOUD_ZONE_ID$VF_NAME$VF_INSTANCE_NUM$VF_COMPONENT$VM_INSTANCE_NUM-mgmt-port + params: + $CLOUD_ZONE_ID: { get_param: cloud_zone_id } + $VF_NAME: { get_param: vf_name } + $VF_INSTANCE_NUM: { get_param: vf_instance_num } + $VF_COMPONENT: { get_param: vf_component } + $VM_INSTANCE_NUM: { "Fn::Select" : [ { get_param: indx }, { get_param: [vm_instance_num] } ] } + network_id: { get_param: mgmt_net_id } + security_groups: [{ get_param: sec_groups }] + + fixed_ips: + - ip_address: { "Fn::Select" : [ { get_param: indx }, { get_param: [{ get_param: mvs_mgmt_ip_0 }] } ] } + + allowed_address_pairs: + - ip_address: { get_param: virtual_mgmt_ip_0 } + + + + vnfci: + type: OS::Nova::Server + properties: + name: + str_replace: + template: Z$CLOUD_ZONE_ID$VF_NAME$VF_INSTANCE_NUM$VF_COMPONENT$VM_INSTANCE_NUM + params: + $CLOUD_ZONE_ID: { get_param: cloud_zone_id } + $VF_NAME: { get_param: vf_name } + $VF_INSTANCE_NUM: { get_param: vf_instance_num } + $VF_COMPONENT: { get_param: vf_component } + $VM_INSTANCE_NUM: { "Fn::Select" : [ { get_param: indx }, { get_param: [vm_instance_num] } ] } + flavor: { get_param: flavor } + key_name: { get_param: key_name } + networks: + - port: { get_resource: mgmt_port } + + availability_zone: { "Fn::Select" : [ { get_param: indx }, { get_param: [availability_zone_0] } ] } + + metadata: + vnf_id: { get_param: vnf_id } + vf_module_id: { get_param: vf_module_id } + +outputs: + vnfci_id_1: + value: { get_resource: vnfci } + vnfci_id_2: + value: { get_resource: vnfci } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupInvalid/inputs/mvs.vfmodule.heat.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupInvalid/inputs/mvs.vfmodule.heat.yaml new file mode 100644 index 0000000000..d71dd81fbf --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupInvalid/inputs/mvs.vfmodule.heat.yaml @@ -0,0 +1,166 @@ +heat_template_version: 2013-05-23 + +description: > + Metaswitch MVS (Metaview Server) + +parameters: + cloud_zone_id: + type: string + description: The cloud zone for this VF instance + index_parameter: + type: string + vf_name: + type: string + description: The VF Name; defaults to VMVM for the virtual MVM VNF. + constraints: + - allowed_pattern: "[a-zA-Z0-9]+" + - length: { min: 4, max: 4 } + description: Each VF will have a 4-character alphanumeric identifier + vf_instance_num: + type: string + description: The number for this VF instance + constraints: + - allowed_pattern: "[0-9]+" + - length: { min: 2, max: 2 } + description: VF instance number must be a two-digit numeric value + vf_component: + type: string + description: The component that this VF instance is running + constraints: + - allowed_pattern: "[a-zA-Z0-9]+" + - length: { min: 3, max: 3 } + description: Each VF component will have a 3-character alphanumeric identifier + vm_instance_num: + type: comma_delimited_list + description: VM instance number list must be a list of three-digit numeric value + vnf_id: + type: string + description: Unique ID for this VF instance + vf_module_id: + type: string + description: Unique ID for this VF_MODULE instance + bootimage: + type: string + description: Master bootimage volume id + flavor: + type: string + description: Server flavor + constraints: + - custom_constraint: nova.flavor + key_name: + type: string + description: SSH key name + constraints: + - custom_constraint: nova.keypair + type_name: + type: string + availability_zone_0: + type: comma_delimited_list + description: List of Availability Zone IDs or Names + + sec_groups: + type: comma_delimited_list + description: Security groups + mgmt_net_id: + type: string + description: Neutron UUID for the Management network + constraints: + - custom_constraint: neutron.network + virtual_mgmt_ip_0: + type: string + description: Virtual management network ip address + + mvs_mgmt_ip_0: + type: comma_delimited_list + description: List of Management network IP addresses for IPv4 + + num_instances: + type: number + description: number of instance of the VF_module + + compute_image_name: + type: string + +resources: + mvs_modules: + type: OS::Heat::ResourceGroup + properties: + count: 3 + index_var: { get_param: index_parameter } + resource_def: + type: mvs.nested.heat.yaml + properties: + cloud_zone_id: { get_param: cloud_zone_id } + vf_name: { get_param: vf_name } + vf_instance_num: { get_param: vf_instance_num } + vf_component: { get_param: vf_component } + vm_instance_num: { get_param: vm_instance_num } + vnf_id: { get_param: vnf_id } + vf_module_id: { get_param: vf_module_id } + bootimage: { get_param: bootimage } + flavor: { get_param: flavor } + key_name: { get_param: key_name } + availability_zone_0: { get_param: availability_zone_0 } + sec_groups: { get_param: sec_groups } + mgmt_net_id: { get_param: mgmt_net_id } + virtual_mgmt_ip_0: { get_param: virtual_mgmt_ip_0 } + mvs_mgmt_ip_0: { get_param: mvs_mgmt_ip_0 } + indx: "%index%" + + not_supported_resourceGroup1: + type: OS::Heat::ResourceGroup + properties: + count: 3 + resource_def: + type: OS::Heat::ResourceGroup + properties: + cloud_zone_id: { get_param: cloud_zone_id } + vf_name: { get_param: vf_name } + vf_instance_num: { get_param: vf_instance_num } + vf_component: { get_param: vf_component } + vm_instance_num: { get_param: vm_instance_num } + vnf_id: { get_param: vnf_id } + vf_module_id: { get_param: vf_module_id } + bootimage: { get_param: bootimage } + flavor: { get_param: flavor } + key_name: { get_param: key_name } + availability_zone_0: { get_param: availability_zone_0 } + sec_groups: { get_param: sec_groups } + mgmt_net_id: { get_param: mgmt_net_id } + virtual_mgmt_ip_0: { get_param: virtual_mgmt_ip_0 } + mvs_mgmt_ip_0: { get_param: mvs_mgmt_ip_0 } + indx: "%index%" + + not_supported_resourceGroup2: + type: OS::Heat::ResourceGroup + properties: + count: 3 + resource_def: + type: { get_param: type_name } + properties: + cloud_zone_id: { get_param: cloud_zone_id } + vf_name: { get_param: vf_name } + vf_instance_num: { get_param: vf_instance_num } + vf_component: { get_param: vf_component } + vm_instance_num: { get_param: vm_instance_num } + vnf_id: { get_param: vnf_id } + vf_module_id: { get_param: vf_module_id } + bootimage: { get_param: bootimage } + flavor: { get_param: flavor } + key_name: { get_param: key_name } + availability_zone_0: { get_param: availability_zone_0 } + sec_groups: { get_param: sec_groups } + mgmt_net_id: { get_param: mgmt_net_id } + virtual_mgmt_ip_0: { get_param: virtual_mgmt_ip_0 } + mvs_mgmt_ip_0: { get_param: mvs_mgmt_ip_0 } + indx: "%index%" + + server_compute_get_attr_test: + type: OS::Nova::Server + properties: + config_drive: {get_attr: [mvs_modules]} + name: compute_name + image: { get_param: compute_image_name } + flavor: compute_flavor_name + user_data_format: { get_attr: [mvs_modules , resource.1.vnfci_id_1] } + user_data: { get_attr: [mvs_modules, resource.vnfci_id_2]} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..ec3b692135 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,153 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.dns_nested_01: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + vf_module_id: + type: string + description: Unique ID for this VF module instance + name_with_index: + type: string + description: name parameter which will include the index value + dns_int_bearer_ips: + type: list + description: DNS Bearer IP list + entry_schema: + type: string + vnf_name: + type: string + description: Unique name for this VF instance + index: + type: float + description: index parameter + security_group: + type: string + description: security group + oam_protected_net_name: + type: string + description: OAM network where instaces will connect + dns_oam_protected_ips: + type: list + description: DNS OAM IP list + entry_schema: + type: string + dns_key: + type: string + description: server key + int_bearer_net_name: + type: string + description: Bearer network where instaces will connect + route_eth0: + type: string + description: OAM network routes + dns_names: + type: list + description: server name + entry_schema: + type: string + vnf_id: + type: string + description: Unique ID for this VF instance + availability_zone_0: + type: string + description: availability zone ID or Name + dns_image_name: + type: string + description: server image + dns_int_bearer_ipv6_ips: + type: list + description: fixed IPv6 assignment for VM's on the Bearer network + entry_schema: + type: string + dns_flavor_name: + type: string + description: server flavor + requirements: + - link_dns_oam_protected_0_port: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_dns_int_bearer_0_port: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - local_storage_dns_servers: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + capabilities: + host_dns_servers: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + attachment_dns_int_bearer_0_port: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + attachment_dns_oam_protected_0_port: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + os_dns_servers: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + endpoint_dns_servers: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + binding_dns_servers: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + scalable_dns_servers: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..6eae1ff185 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,246 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + vf_module_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VF module instance + dns_int_bearer_ips: + hidden: false + immutable: false + type: list + description: DNS Bearer IP list + entry_schema: + type: string + vnf_name: + hidden: false + immutable: false + type: string + description: Unique name for this VF instance + oam_protected_net_name: + hidden: false + immutable: false + type: string + description: OAM network where instaces will connect + dns_oam_protected_ips: + hidden: false + immutable: false + type: list + description: DNS OAM IP list + entry_schema: + type: string + dns_key: + hidden: false + immutable: false + type: string + description: creator's ssh public key + int_bearer_net_name: + hidden: false + immutable: false + type: string + description: Bearer network where instaces will connect + route_eth0: + hidden: false + immutable: false + type: string + description: OAM network routes + vnf_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VF instance + availability_zone_0: + hidden: false + immutable: false + type: string + description: availability zone ID or Name + DNS_shared_sec_grp_id: + hidden: false + immutable: false + type: string + description: security group UUID + node_count: + hidden: false + immutable: false + type: float + description: the number of DNS nested instances + default: 4 + dns_image_name: + hidden: false + immutable: false + type: string + description: operative system image + default: NIMBUS_DNS_3.0.2.qcow2 + dns_int_bearer_ipv6_ips: + hidden: false + immutable: false + type: list + description: fixed IP assignment for VM's on the Bearer network + entry_schema: + type: string + dns_server_names: + hidden: false + immutable: false + type: list + description: DNS VM server name list + entry_schema: + type: string + dns_flavor_name: + hidden: false + immutable: false + type: string + description: resources to by appplied on instances + default: nv.c4r4d80 + node_templates: + dns_server_group_az: + type: org.openecomp.resource.abstract.nodes.heat.dns_nested_01 + directives: + - substitutable + properties: + vf_module_id: + get_input: vf_module_id + name_with_index: + concat: + - name_ + - get_property: + - SELF + - service_template_filter + - index_value + dns_int_bearer_ips: + get_input: dns_int_bearer_ips + vnf_name: + get_input: vnf_name + index: + get_property: + - SELF + - service_template_filter + - index_value + security_group: + get_input: DNS_shared_sec_grp_id + oam_protected_net_name: + get_input: oam_protected_net_name + dns_oam_protected_ips: + get_input: dns_oam_protected_ips + dns_key: + get_input: dns_key + int_bearer_net_name: + get_input: int_bearer_net_name + route_eth0: + get_input: route_eth0 + service_template_filter: + substitute_service_template: dns_nested_01ServiceTemplate.yaml + count: + get_input: node_count + mandatory: false + dns_names: + get_input: dns_server_names + vnf_id: + get_input: vnf_id + availability_zone_0: + get_input: availability_zone_0 + dns_image_name: + get_input: dns_image_name + dns_int_bearer_ipv6_ips: + get_input: dns_int_bearer_ipv6_ips + dns_flavor_name: + get_input: dns_flavor_name + DNS_SECURITY_GROUP: + type: org.openecomp.resource.vfc.rules.nodes.heat.network.neutron.SecurityRules + properties: + name: + str_replace: + template: VF_NAME_sec_grp_DNS + params: + VF_NAME: + get_input: vnf_name + description: vscp security group + rules: + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + requirements: + - port: + capability: attachment_dns_int_bearer_0_port + node: dns_server_group_az + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: attachment_dns_oam_protected_0_port + node: dns_server_group_az + relationship: org.openecomp.relationships.AttachesTo + groups: + base_dns: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/base_dns.yaml + description: | + Base HOT template to create The Security Group for the the DNS VNF + members: + - DNS_SECURITY_GROUP + dns_az_01: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/dns_az_01.yaml + description: DNS master template + members: + - dns_server_group_az \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/expectedoutputfiles/dns_nested_01ServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/expectedoutputfiles/dns_nested_01ServiceTemplate.yaml new file mode 100644 index 0000000000..db6b3a0179 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/expectedoutputfiles/dns_nested_01ServiceTemplate.yaml @@ -0,0 +1,249 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: dns_nested_01 +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.dns: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + vf_module_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VF module instance + name_with_index: + hidden: false + immutable: false + type: string + description: name parameter which will include the index value + dns_int_bearer_ips: + hidden: false + immutable: false + type: list + description: DNS Bearer IP list + entry_schema: + type: string + vnf_name: + hidden: false + immutable: false + type: string + description: Unique name for this VF instance + index: + hidden: false + immutable: false + type: float + description: index parameter + security_group: + hidden: false + immutable: false + type: string + description: security group + oam_protected_net_name: + hidden: false + immutable: false + type: string + description: OAM network where instaces will connect + dns_oam_protected_ips: + hidden: false + immutable: false + type: list + description: DNS OAM IP list + entry_schema: + type: string + dns_key: + hidden: false + immutable: false + type: string + description: server key + int_bearer_net_name: + hidden: false + immutable: false + type: string + description: Bearer network where instaces will connect + route_eth0: + hidden: false + immutable: false + type: string + description: OAM network routes + dns_names: + hidden: false + immutable: false + type: list + description: server name + entry_schema: + type: string + vnf_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VF instance + availability_zone_0: + hidden: false + immutable: false + type: string + description: availability zone ID or Name + dns_image_name: + hidden: false + immutable: false + type: string + description: server image + dns_int_bearer_ipv6_ips: + hidden: false + immutable: false + type: list + description: fixed IPv6 assignment for VM's on the Bearer network + entry_schema: + type: string + dns_flavor_name: + hidden: false + immutable: false + type: string + description: server flavor + node_templates: + dns_oam_protected_0_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: security_group + fixed_ips: + - ip_address: + get_input: + - dns_oam_protected_ips + - get_input: index + name: + str_replace: + template: VNF_NAME_dns_oam_port + params: + VNF_NAME: + get_input: vnf_name + network: + get_input: oam_protected_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: dns_servers + relationship: tosca.relationships.network.BindsTo + dns_int_bearer_0_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: security_group + fixed_ips: + - ip_address: + get_input: + - dns_int_bearer_ips + - get_input: index + - ip_address: + get_input: + - dns_int_bearer_ipv6_ips + - get_input: index + name: + str_replace: + template: VNF_NAME_dns_bearer_port + params: + VNF_NAME: + get_input: vnf_name + network: + get_input: int_bearer_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: dns_servers + relationship: tosca.relationships.network.BindsTo + dns_servers: + type: org.openecomp.resource.vfc.nodes.heat.dns + properties: + flavor: + get_input: dns_flavor_name + key_name: + get_input: dns_key + availability_zone: + get_input: availability_zone_0 + image: + get_input: dns_image_name + metadata: + vf_module_id: + get_input: vf_module_id + vnf_name {get_param: vnf_name } + vnf_id: + get_input: vnf_id + user_data_format: RAW + name: + get_input: + - dns_names + - get_input: index + groups: + dns_nested_01: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/dns_nested_01.yaml + description: | + nested DNS template for a single VM + all parameters are passed from calling heat template of resourcegroup + members: + - dns_oam_protected_0_port + - dns_int_bearer_0_port + - dns_servers + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.dns_nested_01 + capabilities: + host_dns_servers: + - dns_servers + - host + attachment_dns_int_bearer_0_port: + - dns_int_bearer_0_port + - attachment + attachment_dns_oam_protected_0_port: + - dns_oam_protected_0_port + - attachment + os_dns_servers: + - dns_servers + - os + endpoint_dns_servers: + - dns_servers + - endpoint + binding_dns_servers: + - dns_servers + - binding + scalable_dns_servers: + - dns_servers + - scalable + requirements: + local_storage_dns_servers: + - dns_servers + - local_storage + link_dns_oam_protected_0_port: + - dns_oam_protected_0_port + - link + link_dns_int_bearer_0_port: + - dns_int_bearer_0_port + - link \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/inputs/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/inputs/MANIFEST.json new file mode 100644 index 0000000000..0fa0f714da --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/inputs/MANIFEST.json @@ -0,0 +1,37 @@ +{ + "name": "", + "description": "", + "data": [ + { + "file": "dns_nested_01.yaml", + "type": "HEAT", + "isBase": "false" + }, + { + "file": "base_dns.yaml", + "type": "HEAT", + "isBase": "true", + "data": [ + { + "file": "base_dns.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "dns_az_01.yaml", + "type": "HEAT", + "isBase": "false", + "data": [ + { + "file": "dns_az_01.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "nimbus-willows-2.pem", + "type": "OTHER" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/inputs/base_dns.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/inputs/base_dns.env new file mode 100644 index 0000000000..3ab724f7ab --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/inputs/base_dns.env @@ -0,0 +1,8 @@ +##NIMBUS - DNS Base Template ENV File +#AUTHORS: + +##################### +parameters: +##################### + +# vnf_name: 'zrdm3mdns01' diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/inputs/base_dns.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/inputs/base_dns.yaml new file mode 100644 index 0000000000..821f10212f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/inputs/base_dns.yaml @@ -0,0 +1,43 @@ +heat_template_version: 2015-04-30 +#Nimbus DNS Base Template +#AUTHORS: +description: > + Base HOT template to create The Security Group for the the DNS VNF + +##################### +parameters: +##################### + +## GLOBAL//Basic Parameters + vnf_name: + type: string + description: Unique name for this VF instance +# For manual spinups, value must be in the ENV file. Must be removed from ENV before uploading to ASDC + +##################### +resources: +##################### + + DNS_SECURITY_GROUP: + type: OS::Neutron::SecurityGroup + properties: + description: vscp security group + name: + str_replace: + template: VF_NAME_sec_grp_DNS + params: + VF_NAME: {get_param: vnf_name} + rules: [{"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0} + ] + + +outputs: + DNS_shared_sec_grp_id: + description: UUID of DNS Resource SecurityGroup + value: { get_resource: DNS_SECURITY_GROUP } + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/inputs/dns_az_01.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/inputs/dns_az_01.env new file mode 100644 index 0000000000..8e0e80c67f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/inputs/dns_az_01.env @@ -0,0 +1,21 @@ +parameters: + dns_image_name: NIMBUS_DNS_3.0.2.qcow2 + dns_flavor_name: nv.c4r4d80 +# dns_key: nimbus-willows-1 +# oam_protected_net_name: MNS-25180-L-06Shared_OAM_PROTECTED_NET_1 +# int_bearer_net_name: Nimbus-25193-T-Willows1_int_fw_dns_trusted_net_1 + node_count: 4 +# dns_oam_protected_ips: 107.239.81.114,107.239.81.115,107.239.81.116,107.239.81.117 +# dns_int_bearer_ips: 172.26.18.64,172.26.18.65,172.26.18.66,172.26.18.67 +# dns_int_bearer_ipv6_ips: fd00:2600:2600:101::40,fd00:2600:2600:101::41,fd00:2600:2600:101::42,fd00:2600:2600:101::43 +# dns_server_names: zrdm3mdns01cmd001,zrdm3mdns01cmd002,zrdm3mdns01cmd003,zrdm3mdns01cmd004 +# route_eth0: | +# 10.147.38.211/32 via 107.239.81.1 dev eth0 +# 155.165.201.253/32 via 107.239.81.1 dev eth0 +# 141.204.0.0/16 via 107.239.81.1 dev eth0 +# DNS_shared_sec_grp_id: 5f809b4c-a1af-4064-86ef-0aebb761a749 +# availability_zone_0: rdm3-kvm-az01 +# vnf_name: 'zrdm3mdns01' +# vnf_id: 'dummy' +# vf_module_id: 'dummy' + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/inputs/dns_az_01.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/inputs/dns_az_01.yaml new file mode 100644 index 0000000000..84aacaba35 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/inputs/dns_az_01.yaml @@ -0,0 +1,94 @@ +heat_template_version: 2014-10-16 + +description: DNS master template + +parameters: + dns_image_name: + type: string + description: operative system image + dns_flavor_name: + type: string + description: resources to by appplied on instances + dns_key: + type: string + description: creator's ssh public key + node_count: + type: number + description: the number of DNS nested instances + oam_protected_net_name: + type: string + description: OAM network where instaces will connect + int_bearer_net_name: + type: string + description: Bearer network where instaces will connect + dns_oam_protected_ips: + type: comma_delimited_list + description: DNS OAM IP list + dns_int_bearer_ips: + type: comma_delimited_list + description: DNS Bearer IP list + dns_int_bearer_ipv6_ips: + type: comma_delimited_list + description: fixed IP assignment for VM's on the Bearer network + dns_server_names: + type: comma_delimited_list + description: DNS VM server name list + route_eth0: + type: string + description: OAM network routes + DNS_shared_sec_grp_id: + type: string + description: security group UUID + availability_zone_0: + type: string + description: availability zone ID or Name + vnf_name: + type: string + description: Unique name for this VF instance +# For manual spinups, value must be in the ENV file. Must be removed from ENV before uploading to ASDC + vnf_id: + type: string + description: Unique ID for this VF instance +# For manual spinups, value must be in the ENV file. Must be removed from ENV before uploading to ASDC + vf_module_id: + type: string + description: Unique ID for this VF module instance +# For manual spinups, value must be in the ENV file. Must be removed from ENV before uploading to ASDC + + +resources: + dns_server_group_az: + type: OS::Heat::ResourceGroup + properties: + count: { get_param: node_count } + index_var: index + resource_def: + type: dns_nested_01.yaml + properties: + index: index + name_with_index: name_index + dns_image_name: { get_param: dns_image_name } + dns_flavor_name: { get_param: dns_flavor_name } + dns_key: { get_param: dns_key } + availability_zone_0: { get_param: availability_zone_0 } + security_group: { get_param: DNS_shared_sec_grp_id } + oam_protected_net_name: { get_param: oam_protected_net_name } + int_bearer_net_name: { get_param: int_bearer_net_name } + dns_oam_protected_ips: { get_param: dns_oam_protected_ips } + dns_int_bearer_ips: { get_param: dns_int_bearer_ips } + dns_int_bearer_ipv6_ips: { get_param: dns_int_bearer_ipv6_ips } + dns_names: { get_param: dns_server_names } + route_eth0: { get_param: route_eth0 } + vnf_name: { get_param: vnf_name } + vnf_id: { get_param: vnf_id } + vf_module_id: {get_param: vf_module_id} + +#outputs: +# vm_name: +# description: VM name +# value: { get_attr: [ dns_server_group_az, vm_name ] } +# networks: +# description: networks +# value: { get_attr: [ dns_server_group_az, networks ] } + + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/inputs/dns_nested_01.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/inputs/dns_nested_01.yaml new file mode 100644 index 0000000000..5be9d49bb0 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/inputs/dns_nested_01.yaml @@ -0,0 +1,127 @@ +heat_template_version: 2014-10-16 + +description: | + nested DNS template for a single VM + all parameters are passed from calling heat template of resourcegroup + +parameters: + dns_image_name: + type: string + description: server image + dns_flavor_name: + type: string + description: server flavor + dns_key: + type: string + description: server key + oam_protected_net_name: + type: string + description: OAM network where instaces will connect + int_bearer_net_name: + type: string + description: Bearer network where instaces will connect + dns_oam_protected_ips: + type: comma_delimited_list + description: DNS OAM IP list + dns_int_bearer_ips: + type: comma_delimited_list + description: DNS Bearer IP list + dns_int_bearer_ipv6_ips: + type: comma_delimited_list + description: fixed IPv6 assignment for VM's on the Bearer network + dns_names: + type: comma_delimited_list + description: server name + route_eth0: + type: string + description: OAM network routes + index: + type: number + description: index parameter + name_with_index: + type: string + description: name parameter which will include the index value + security_group: + type: string + description: security group + availability_zone_0: + type: string + description: availability zone ID or Name +# this parameter does not follow the D2 Guidelines. This value will be az0 or az1. + vnf_name: + type: string + description: Unique name for this VF instance +# For manual spinups, value must be in the ENV file. Must be removed from ENV before uploading to ASDC + vnf_id: + type: string + description: Unique ID for this VF instance +# For manual spinups, value must be in the ENV file. Must be removed from ENV before uploading to ASDC + vf_module_id: + type: string + description: Unique ID for this VF module instance +# For manual spinups, value must be in the ENV file. Must be removed from ENV before uploading to ASDC + + +resources: + + dns_oam_protected_0_port: + type: OS::Neutron::Port + properties: + name: + str_replace: + template: VNF_NAME_dns_oam_port + params: + VNF_NAME: {get_param: vnf_name} + network: { get_param: oam_protected_net_name } + fixed_ips: [{ "ip_address": { get_param: [ dns_oam_protected_ips, get_param: index ]}}] + security_groups: [{ get_param: security_group }] + + dns_int_bearer_0_port: + type: OS::Neutron::Port + properties: + name: + str_replace: + template: VNF_NAME_dns_bearer_port + params: + VNF_NAME: {get_param: vnf_name} + network: { get_param: int_bearer_net_name } + fixed_ips: [{ "ip_address": { get_param: [ dns_int_bearer_ips, get_param: index ]}}, { "ip_address": { get_param: [ dns_int_bearer_ipv6_ips, get_param: index ]}}] + security_groups: [{ get_param: security_group }] + + dns_servers: + type: OS::Nova::Server + properties: + name: { get_param: [ dns_names, get_param: index ] } + image: { get_param: dns_image_name } + flavor: { get_param: dns_flavor_name } + key_name: { get_param: dns_key } + availability_zone: { get_param: availability_zone_0 } + networks: + - port: { get_resource: dns_oam_protected_0_port } + - port: { get_resource: dns_int_bearer_0_port } + metadata: + vnf_id: { get_param: vnf_id } + vf_module_id: { get_param: vf_module_id } + vnf_name {get_param: vnf_name } + user_data_format: RAW + user_data: { get_resource: server_interface_config } + + server_interface_config: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/route-eth0 + permissions: "0644" +# content: { get_file: route-eth0 } + content: { get_param: route_eth0 } + +#outputs: +# vm_name: +# description: VM name +# value: { get_attr: [ dns_servers, name] } +# networks: +# description: networks +# value: { get_attr: [ dns_servers, networks ] } + + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/inputs/nimbus-willows-2.pem b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/inputs/nimbus-willows-2.pem new file mode 100644 index 0000000000..ca613f176c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/inputs/nimbus-willows-2.pem @@ -0,0 +1,27 @@ +-----BEGIN RSA PRIVATE KEY----- +MIIEpAIBAAKCAQEA4JxAkJFmleoEjBIs+ZHH1yYn0uFtLnN2JX7alC9t/4LUgShK +CWHg+NZgCp1rCCfEZ16OMIlJViaw3i50BwSbh71vHHLfgpbKuCaxVblSsokWJf1P +vNjcpb1uE4/GgAGTOvVpBJ67aSFL2cqN0RRmoDkXD0Es0Oog7X2/DSXex6rSfWrh +I6RplcvljEOp3svhZxrCM5B9byn9931eja0NpJmggDQqzlrh6s01iqQKSZ3C6Cp4 +g0YMff3FP6b6xWbt/2wK2aR5/so64LZmBbxJHgBkQOAUsUdt6aWgx9lUKAly1KFo +4+E67IX9k6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9nmZdSAcoi8tOIgVOGMCCIhEbMMBx +vhZ+7wKBgQDizYvqTOyODzi3cebk7LzbSg+r1cNE9onvCVej+pnznt5oQtniAzS6 +GbGyKsDHDtmQ15tXdnU2KkTcsXEs9nFxIsOR2QZtQRcMSuRtye5o2qPXf0HdHW/M +5mheJi2LfaNP5csauJ/WUJYbAS4cn7dz4xUos+7la58upB/or+Q/cg== +-----END RSA PRIVATE KEY----- diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..15b5e3b3a8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,161 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.mvs.nested.heat: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + vf_module_id: + type: string + description: Unique ID for this VF_MODULE instance + vf_name: + type: string + description: The VF Name; defaults to VMVM for the virtual MVM VNF. + constraints: + - pattern: '[a-zA-Z0-9]+' + - max_length: 4 + - min_length: 4 + cloud_zone_id: + type: string + description: The cloud zone for this VF instance + vf_instance_num: + type: string + description: The number for this VF instance + constraints: + - pattern: '[0-9]+' + - max_length: 2 + - min_length: 2 + virtual_mgmt_ip_0: + type: string + description: Virtual management network ip address + indx: + type: float + description: Index of the current instance + mvs_mgmt_ip_0: + type: list + description: List of Management network IP addresses for IPv4 + entry_schema: + type: string + flavor: + type: string + description: Server flavor + constraints: [ + ] + key_name: + type: string + description: SSH key name + constraints: [ + ] + vnf_id: + type: string + description: Unique ID for this VF instance + availability_zone_0: + type: list + description: List of Availability Zone IDs or Names + entry_schema: + type: string + mgmt_net_id: + type: string + description: Neutron UUID for the Management network + constraints: [ + ] + vm_instance_num: + type: list + description: VM instance number list must be a list of three-digit numeric value + entry_schema: + type: string + bootimage: + type: string + description: Master bootimage volume id + sec_groups: + type: list + description: Security groups + entry_schema: + type: string + vf_component: + type: string + description: The component that this VF instance is running + constraints: + - pattern: '[a-zA-Z0-9]+' + - max_length: 3 + - min_length: 3 + attributes: + vnfci_id_2: + type: string + vnfci_id_1: + type: string + requirements: + - local_storage_vnfci: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_mgmt_port: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + os_vnfci: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + attachment_mgmt_port: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + endpoint_vnfci: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + host_vnfci: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + binding_vnfci: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + scalable_vnfci: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..632afc51b3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,223 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.compute: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + vf_module_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VF_MODULE instance + vf_name: + hidden: false + immutable: false + type: string + description: The VF Name; defaults to VMVM for the virtual MVM VNF. + constraints: + - pattern: '[a-zA-Z0-9]+' + - max_length: 4 + - min_length: 4 + type_name: + hidden: false + immutable: false + type: string + cloud_zone_id: + hidden: false + immutable: false + type: string + description: The cloud zone for this VF instance + vf_instance_num: + hidden: false + immutable: false + type: string + description: The number for this VF instance + constraints: + - pattern: '[0-9]+' + - max_length: 2 + - min_length: 2 + virtual_mgmt_ip_0: + hidden: false + immutable: false + type: string + description: Virtual management network ip address + mvs_mgmt_ip_0: + hidden: false + immutable: false + type: list + description: List of Management network IP addresses for IPv4 + entry_schema: + type: string + compute_image_name: + hidden: false + immutable: false + type: string + flavor: + hidden: false + immutable: false + type: string + description: Server flavor + constraints: [ + ] + key_name: + hidden: false + immutable: false + type: string + description: SSH key name + constraints: [ + ] + vnf_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VF instance + availability_zone_0: + hidden: false + immutable: false + type: list + description: List of Availability Zone IDs or Names + entry_schema: + type: string + mgmt_net_id: + hidden: false + immutable: false + type: string + description: Neutron UUID for the Management network + constraints: [ + ] + vm_instance_num: + hidden: false + immutable: false + type: list + description: VM instance number list must be a list of three-digit numeric value + entry_schema: + type: string + bootimage: + hidden: false + immutable: false + type: string + description: Master bootimage volume id + sec_groups: + hidden: false + immutable: false + type: list + description: Security groups + entry_schema: + type: string + vf_component: + hidden: false + immutable: false + type: string + description: The component that this VF instance is running + constraints: + - pattern: '[a-zA-Z0-9]+' + - max_length: 3 + - min_length: 3 + num_instances: + hidden: false + immutable: false + type: float + description: number of instance of the VF_module + node_templates: + mvs_modules: + type: org.openecomp.resource.abstract.nodes.heat.mvs.nested.heat + directives: + - substitutable + properties: + vf_module_id: + get_input: vf_module_id + vf_name: + get_input: vf_name + cloud_zone_id: + get_input: cloud_zone_id + vf_instance_num: + get_input: vf_instance_num + virtual_mgmt_ip_0: + get_input: virtual_mgmt_ip_0 + indx: + get_property: + - SELF + - service_template_filter + - index_value + mvs_mgmt_ip_0: + get_input: mvs_mgmt_ip_0 + flavor: + get_input: flavor + key_name: + get_input: key_name + service_template_filter: + substitute_service_template: mvs.nested.heatServiceTemplate.yaml + count: 3 + mandatory: true + vnf_id: + get_input: vnf_id + availability_zone_0: + get_input: availability_zone_0 + mgmt_net_id: + get_input: mgmt_net_id + vm_instance_num: + get_input: vm_instance_num + bootimage: + get_input: bootimage + sec_groups: + get_input: sec_groups + vf_component: + get_input: vf_component + server_compute_get_attr_test: + type: org.openecomp.resource.vfc.nodes.heat.compute + properties: + flavor: compute_flavor_name + image: + get_input: compute_image_name + config_drive: + get_attribute: + - mvs_modules + - vnfci_id_1 + - vnfci_id_2 + user_data_format: + get_attribute: + - mvs_modules + - vnfci_id_1 + - 1 + name: compute_name + groups: + mvs.vfmodule.heat: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/mvs.vfmodule.heat.yaml + description: | + Metaswitch MVS (Metaview Server) + members: + - mvs_modules + - server_compute_get_attr_test \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group/expectedoutputfiles/mvs.nested.heatServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group/expectedoutputfiles/mvs.nested.heatServiceTemplate.yaml new file mode 100644 index 0000000000..11369f9b68 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group/expectedoutputfiles/mvs.nested.heatServiceTemplate.yaml @@ -0,0 +1,254 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: mvs.nested.heat +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.vnfci: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + vf_module_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VF_MODULE instance + vf_name: + hidden: false + immutable: false + type: string + description: The VF Name; defaults to VMVM for the virtual MVM VNF. + constraints: + - pattern: '[a-zA-Z0-9]+' + - max_length: 4 + - min_length: 4 + cloud_zone_id: + hidden: false + immutable: false + type: string + description: The cloud zone for this VF instance + vf_instance_num: + hidden: false + immutable: false + type: string + description: The number for this VF instance + constraints: + - pattern: '[0-9]+' + - max_length: 2 + - min_length: 2 + virtual_mgmt_ip_0: + hidden: false + immutable: false + type: string + description: Virtual management network ip address + indx: + hidden: false + immutable: false + type: float + description: Index of the current instance + mvs_mgmt_ip_0: + hidden: false + immutable: false + type: list + description: List of Management network IP addresses for IPv4 + entry_schema: + type: string + flavor: + hidden: false + immutable: false + type: string + description: Server flavor + constraints: [ + ] + key_name: + hidden: false + immutable: false + type: string + description: SSH key name + constraints: [ + ] + vnf_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VF instance + availability_zone_0: + hidden: false + immutable: false + type: list + description: List of Availability Zone IDs or Names + entry_schema: + type: string + mgmt_net_id: + hidden: false + immutable: false + type: string + description: Neutron UUID for the Management network + constraints: [ + ] + vm_instance_num: + hidden: false + immutable: false + type: list + description: VM instance number list must be a list of three-digit numeric value + entry_schema: + type: string + bootimage: + hidden: false + immutable: false + type: string + description: Master bootimage volume id + sec_groups: + hidden: false + immutable: false + type: list + description: Security groups + entry_schema: + type: string + vf_component: + hidden: false + immutable: false + type: string + description: The component that this VF instance is running + constraints: + - pattern: '[a-zA-Z0-9]+' + - max_length: 3 + - min_length: 3 + node_templates: + vnfci: + type: org.openecomp.resource.vfc.nodes.heat.vnfci + properties: + flavor: + get_input: flavor + key_name: + get_input: key_name + availability_zone: + Fn::Select: + - get_input: indx + - get_input: + - availability_zone_0 + name: + str_replace: + template: Z$CLOUD_ZONE_ID$VF_NAME$VF_INSTANCE_NUM$VF_COMPONENT$VM_INSTANCE_NUM + params: + $VF_NAME: + get_input: vf_name + $CLOUD_ZONE_ID: + get_input: cloud_zone_id + $VM_INSTANCE_NUM: + Fn::Select: + - get_input: indx + - get_input: + - vm_instance_num + $VF_COMPONENT: + get_input: vf_component + $VF_INSTANCE_NUM: + get_input: vf_instance_num + mgmt_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: sec_groups + fixed_ips: + - ip_address: + Fn::Select: + - get_input: indx + - get_input: + - get_input: mvs_mgmt_ip_0 + allowed_address_pairs: + - ip_address: + get_input: virtual_mgmt_ip_0 + name: + str_replace: + template: Z$CLOUD_ZONE_ID$VF_NAME$VF_INSTANCE_NUM$VF_COMPONENT$VM_INSTANCE_NUM-mgmt-port + params: + $VF_NAME: + get_input: vf_name + $CLOUD_ZONE_ID: + get_input: cloud_zone_id + $VM_INSTANCE_NUM: + Fn::Select: + - get_input: indx + - get_input: + - vm_instance_num + $VF_COMPONENT: + get_input: vf_component + $VF_INSTANCE_NUM: + get_input: vf_instance_num + network: + get_input: mgmt_net_id + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: vnfci + relationship: tosca.relationships.network.BindsTo + groups: + mvs.nested.heat: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/mvs.nested.heat.yaml + description: | + Metaswitch MVS (Metaview Server) + members: + - vnfci + - mgmt_port + outputs: + vnfci_id_2: + value: vnfci + vnfci_id_1: + value: vnfci + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.mvs.nested.heat + capabilities: + os_vnfci: + - vnfci + - os + attachment_mgmt_port: + - mgmt_port + - attachment + endpoint_vnfci: + - vnfci + - endpoint + host_vnfci: + - vnfci + - host + binding_vnfci: + - vnfci + - binding + scalable_vnfci: + - vnfci + - scalable + requirements: + local_storage_vnfci: + - vnfci + - local_storage + link_mgmt_port: + - mgmt_port + - link \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group/inputs/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group/inputs/MANIFEST.json new file mode 100644 index 0000000000..c7729c8653 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group/inputs/MANIFEST.json @@ -0,0 +1,19 @@ +{ + "name": "mvs.vfmodule.heat.yaml", + "description": "Metaswitch MVS (Metaview Server)", + "version": "2013-05-23", + "data": [ + { + "file": "mvs.vfmodule.heat.yaml", + "type": "HEAT", + "data": [ + ] + }, + { + "file": "mvs.nested.heat.yaml", + "type": "HEAT", + "data": [ + ] + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group/inputs/mvs.nested.heat.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group/inputs/mvs.nested.heat.yaml new file mode 100644 index 0000000000..01adb51d71 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group/inputs/mvs.nested.heat.yaml @@ -0,0 +1,129 @@ +heat_template_version: 2013-05-23 + +description: > + Metaswitch MVS (Metaview Server) + +parameters: + cloud_zone_id: + type: string + description: The cloud zone for this VF instance + vf_name: + type: string + description: The VF Name; defaults to VMVM for the virtual MVM VNF. + constraints: + - allowed_pattern: "[a-zA-Z0-9]+" + - length: { min: 4, max: 4 } + description: Each VF will have a 4-character alphanumeric identifier + vf_instance_num: + type: string + description: The number for this VF instance + constraints: + - allowed_pattern: "[0-9]+" + - length: { min: 2, max: 2 } + description: VF instance number must be a two-digit numeric value + vf_component: + type: string + description: The component that this VF instance is running + constraints: + - allowed_pattern: "[a-zA-Z0-9]+" + - length: { min: 3, max: 3 } + description: Each VF component will have a 3-character alphanumeric identifier + vm_instance_num: + type: comma_delimited_list + description: VM instance number list must be a list of three-digit numeric value + vnf_id: + type: string + description: Unique ID for this VF instance + vf_module_id: + type: string + description: Unique ID for this VF_MODULE instance + bootimage: + type: string + description: Master bootimage volume id + flavor: + type: string + description: Server flavor + constraints: + - custom_constraint: nova.flavor + key_name: + type: string + description: SSH key name + constraints: + - custom_constraint: nova.keypair + + availability_zone_0: + type: comma_delimited_list + description: List of Availability Zone IDs or Names + + sec_groups: + type: comma_delimited_list + description: Security groups + mgmt_net_id: + type: string + description: Neutron UUID for the Management network + constraints: + - custom_constraint: neutron.network + virtual_mgmt_ip_0: + type: string + description: Virtual management network ip address + + mvs_mgmt_ip_0: + type: comma_delimited_list + description: List of Management network IP addresses for IPv4 + + indx: + type: number + description: Index of the current instance + +resources: + mgmt_port: + type: OS::Neutron::Port + properties: + name: + str_replace: + template: Z$CLOUD_ZONE_ID$VF_NAME$VF_INSTANCE_NUM$VF_COMPONENT$VM_INSTANCE_NUM-mgmt-port + params: + $CLOUD_ZONE_ID: { get_param: cloud_zone_id } + $VF_NAME: { get_param: vf_name } + $VF_INSTANCE_NUM: { get_param: vf_instance_num } + $VF_COMPONENT: { get_param: vf_component } + $VM_INSTANCE_NUM: { "Fn::Select" : [ { get_param: indx }, { get_param: [vm_instance_num] } ] } + network_id: { get_param: mgmt_net_id } + security_groups: [{ get_param: sec_groups }] + + fixed_ips: + - ip_address: { "Fn::Select" : [ { get_param: indx }, { get_param: [{ get_param: mvs_mgmt_ip_0 }] } ] } + + allowed_address_pairs: + - ip_address: { get_param: virtual_mgmt_ip_0 } + + + + vnfci: + type: OS::Nova::Server + properties: + name: + str_replace: + template: Z$CLOUD_ZONE_ID$VF_NAME$VF_INSTANCE_NUM$VF_COMPONENT$VM_INSTANCE_NUM + params: + $CLOUD_ZONE_ID: { get_param: cloud_zone_id } + $VF_NAME: { get_param: vf_name } + $VF_INSTANCE_NUM: { get_param: vf_instance_num } + $VF_COMPONENT: { get_param: vf_component } + $VM_INSTANCE_NUM: { "Fn::Select" : [ { get_param: indx }, { get_param: [vm_instance_num] } ] } + flavor: { get_param: flavor } + key_name: { get_param: key_name } + networks: + - port: { get_resource: mgmt_port } + + availability_zone: { "Fn::Select" : [ { get_param: indx }, { get_param: [availability_zone_0] } ] } + + metadata: + vnf_id: { get_param: vnf_id } + vf_module_id: { get_param: vf_module_id } + +outputs: + vnfci_id_1: + value: { get_resource: vnfci } + vnfci_id_2: + value: { get_resource: vnfci } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group/inputs/mvs.vfmodule.heat.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group/inputs/mvs.vfmodule.heat.yaml new file mode 100644 index 0000000000..380ceae2ff --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group/inputs/mvs.vfmodule.heat.yaml @@ -0,0 +1,163 @@ +heat_template_version: 2013-05-23 + +description: > + Metaswitch MVS (Metaview Server) + +parameters: + cloud_zone_id: + type: string + description: The cloud zone for this VF instance + vf_name: + type: string + description: The VF Name; defaults to VMVM for the virtual MVM VNF. + constraints: + - allowed_pattern: "[a-zA-Z0-9]+" + - length: { min: 4, max: 4 } + description: Each VF will have a 4-character alphanumeric identifier + vf_instance_num: + type: string + description: The number for this VF instance + constraints: + - allowed_pattern: "[0-9]+" + - length: { min: 2, max: 2 } + description: VF instance number must be a two-digit numeric value + vf_component: + type: string + description: The component that this VF instance is running + constraints: + - allowed_pattern: "[a-zA-Z0-9]+" + - length: { min: 3, max: 3 } + description: Each VF component will have a 3-character alphanumeric identifier + vm_instance_num: + type: comma_delimited_list + description: VM instance number list must be a list of three-digit numeric value + vnf_id: + type: string + description: Unique ID for this VF instance + vf_module_id: + type: string + description: Unique ID for this VF_MODULE instance + bootimage: + type: string + description: Master bootimage volume id + flavor: + type: string + description: Server flavor + constraints: + - custom_constraint: nova.flavor + key_name: + type: string + description: SSH key name + constraints: + - custom_constraint: nova.keypair + type_name: + type: string + availability_zone_0: + type: comma_delimited_list + description: List of Availability Zone IDs or Names + + sec_groups: + type: comma_delimited_list + description: Security groups + mgmt_net_id: + type: string + description: Neutron UUID for the Management network + constraints: + - custom_constraint: neutron.network + virtual_mgmt_ip_0: + type: string + description: Virtual management network ip address + + mvs_mgmt_ip_0: + type: comma_delimited_list + description: List of Management network IP addresses for IPv4 + + num_instances: + type: number + description: number of instance of the VF_module + + compute_image_name: + type: string + +resources: + mvs_modules: + type: OS::Heat::ResourceGroup + properties: + count: 3 + resource_def: + type: mvs.nested.heat.yaml + properties: + cloud_zone_id: { get_param: cloud_zone_id } + vf_name: { get_param: vf_name } + vf_instance_num: { get_param: vf_instance_num } + vf_component: { get_param: vf_component } + vm_instance_num: { get_param: vm_instance_num } + vnf_id: { get_param: vnf_id } + vf_module_id: { get_param: vf_module_id } + bootimage: { get_param: bootimage } + flavor: { get_param: flavor } + key_name: { get_param: key_name } + availability_zone_0: { get_param: availability_zone_0 } + sec_groups: { get_param: sec_groups } + mgmt_net_id: { get_param: mgmt_net_id } + virtual_mgmt_ip_0: { get_param: virtual_mgmt_ip_0 } + mvs_mgmt_ip_0: { get_param: mvs_mgmt_ip_0 } + indx: "%index%" + + not_supported_resourceGroup1: + type: OS::Heat::ResourceGroup + properties: + count: 3 + resource_def: + type: OS::Heat::ResourceGroup + properties: + cloud_zone_id: { get_param: cloud_zone_id } + vf_name: { get_param: vf_name } + vf_instance_num: { get_param: vf_instance_num } + vf_component: { get_param: vf_component } + vm_instance_num: { get_param: vm_instance_num } + vnf_id: { get_param: vnf_id } + vf_module_id: { get_param: vf_module_id } + bootimage: { get_param: bootimage } + flavor: { get_param: flavor } + key_name: { get_param: key_name } + availability_zone_0: { get_param: availability_zone_0 } + sec_groups: { get_param: sec_groups } + mgmt_net_id: { get_param: mgmt_net_id } + virtual_mgmt_ip_0: { get_param: virtual_mgmt_ip_0 } + mvs_mgmt_ip_0: { get_param: mvs_mgmt_ip_0 } + indx: "%index%" + + not_supported_resourceGroup2: + type: OS::Heat::ResourceGroup + properties: + count: 3 + resource_def: + type: { get_param: type_name } + properties: + cloud_zone_id: { get_param: cloud_zone_id } + vf_name: { get_param: vf_name } + vf_instance_num: { get_param: vf_instance_num } + vf_component: { get_param: vf_component } + vm_instance_num: { get_param: vm_instance_num } + vnf_id: { get_param: vnf_id } + vf_module_id: { get_param: vf_module_id } + bootimage: { get_param: bootimage } + flavor: { get_param: flavor } + key_name: { get_param: key_name } + availability_zone_0: { get_param: availability_zone_0 } + sec_groups: { get_param: sec_groups } + mgmt_net_id: { get_param: mgmt_net_id } + virtual_mgmt_ip_0: { get_param: virtual_mgmt_ip_0 } + mvs_mgmt_ip_0: { get_param: mvs_mgmt_ip_0 } + indx: "%index%" + + server_compute_get_attr_test: + type: OS::Nova::Server + properties: + config_drive: {get_attr: [mvs_modules]} + name: compute_name + image: { get_param: compute_image_name } + flavor: compute_flavor_name + user_data_format: { get_attr: [mvs_modules , resource.1.vnfci_id_1] } + user_data: { get_attr: [mvs_modules, resource.vnfci_id_2]} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group_with_dynamic_count/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group_with_dynamic_count/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..1b1c4dd621 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group_with_dynamic_count/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,166 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.mvs.nested.heat: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + vf_module_id: + type: string + description: Unique ID for this VF_MODULE instance + vf_name: + type: string + description: The VF Name; defaults to VMVM for the virtual MVM VNF. + constraints: + - pattern: '[a-zA-Z0-9]+' + - max_length: 4 + - min_length: 4 + cloud_zone_id: + type: string + description: The cloud zone for this VF instance + vf_instance_num: + type: string + description: The number for this VF instance + constraints: + - pattern: '[0-9]+' + - max_length: 2 + - min_length: 2 + virtual_mgmt_ip_0: + type: string + description: Virtual management network ip address + indx: + type: float + description: Index of the current instance + mvs_mgmt_ip_0: + type: list + description: List of Management network IP addresses for IPv4 + entry_schema: + type: string + flavor: + type: string + description: Server flavor + constraints: [ + ] + key_name: + type: string + description: SSH key name + constraints: [ + ] + vnf_id: + type: string + description: Unique ID for this VF instance + availability_zone_0: + type: list + description: List of Availability Zone IDs or Names + entry_schema: + type: string + mgmt_net_id: + type: string + description: Neutron UUID for the Management network + constraints: [ + ] + vm_instance_num: + type: list + description: VM instance number list must be a list of three-digit numeric value + entry_schema: + type: string + bootimage: + type: string + description: Master bootimage volume id + sec_groups: + type: list + description: Security groups + entry_schema: + type: string + vf_component: + type: string + description: The component that this VF instance is running + constraints: + - pattern: '[a-zA-Z0-9]+' + - max_length: 3 + - min_length: 3 + requirements: + - local_storage_vnfci: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_mgmt_port: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + os_vnfci: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + attachment_mgmt_port: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + endpoint_vnfci: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + host_vnfci: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + binding_vnfci: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + attachment_boot_volume: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + scalable_vnfci: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + attachment_data_volume: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group_with_dynamic_count/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group_with_dynamic_count/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..b3b1349b36 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group_with_dynamic_count/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,195 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + vf_module_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VF_MODULE instance + vf_name: + hidden: false + immutable: false + type: string + description: The VF Name; defaults to VMVM for the virtual MVM VNF. + constraints: + - pattern: '[a-zA-Z0-9]+' + - max_length: 4 + - min_length: 4 + cloud_zone_id: + hidden: false + immutable: false + type: string + description: The cloud zone for this VF instance + vf_instance_num: + hidden: false + immutable: false + type: string + description: The number for this VF instance + constraints: + - pattern: '[0-9]+' + - max_length: 2 + - min_length: 2 + virtual_mgmt_ip_0: + hidden: false + immutable: false + type: string + description: Virtual management network ip address + mvs_mgmt_ip_0: + hidden: false + immutable: false + type: list + description: List of Management network IP addresses for IPv4 + entry_schema: + type: string + flavor: + hidden: false + immutable: false + type: string + description: Server flavor + constraints: [ + ] + key_name: + hidden: false + immutable: false + type: string + description: SSH key name + constraints: [ + ] + vnf_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VF instance + availability_zone_0: + hidden: false + immutable: false + type: list + description: List of Availability Zone IDs or Names + entry_schema: + type: string + mgmt_net_id: + hidden: false + immutable: false + type: string + description: Neutron UUID for the Management network + constraints: [ + ] + vm_instance_num: + hidden: false + immutable: false + type: list + description: VM instance number list must be a list of three-digit numeric value + entry_schema: + type: string + bootimage: + hidden: false + immutable: false + type: string + description: Master bootimage volume id + sec_groups: + hidden: false + immutable: false + type: list + description: Security groups + entry_schema: + type: string + vf_component: + hidden: false + immutable: false + type: string + description: The component that this VF instance is running + constraints: + - pattern: '[a-zA-Z0-9]+' + - max_length: 3 + - min_length: 3 + num_instances: + hidden: false + immutable: false + type: float + description: number of instance of the VF_module + node_templates: + mvs_modules: + type: org.openecomp.resource.abstract.nodes.heat.mvs.nested.heat + directives: + - substitutable + properties: + vf_module_id: + get_input: vf_module_id + vf_name: + get_input: vf_name + cloud_zone_id: + get_input: cloud_zone_id + vf_instance_num: + get_input: vf_instance_num + virtual_mgmt_ip_0: + get_input: virtual_mgmt_ip_0 + indx: + get_property: + - SELF + - service_template_filter + - index_value + mvs_mgmt_ip_0: + get_input: mvs_mgmt_ip_0 + flavor: + get_input: flavor + key_name: + get_input: key_name + service_template_filter: + substitute_service_template: mvs.nested.heatServiceTemplate.yaml + count: + get_input: num_instances + mandatory: false + vnf_id: + get_input: vnf_id + availability_zone_0: + get_input: availability_zone_0 + mgmt_net_id: + get_input: mgmt_net_id + vm_instance_num: + get_input: vm_instance_num + bootimage: + get_input: bootimage + sec_groups: + get_input: sec_groups + vf_component: + get_input: vf_component + groups: + mvs.vfmodule.heat: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/mvs.vfmodule.heat.yaml + description: | + Metaswitch MVS (Metaview Server) + members: + - mvs_modules \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group_with_dynamic_count/expectedoutputfiles/mvs.nested.heatServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group_with_dynamic_count/expectedoutputfiles/mvs.nested.heatServiceTemplate.yaml new file mode 100644 index 0000000000..315318d4f6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group_with_dynamic_count/expectedoutputfiles/mvs.nested.heatServiceTemplate.yaml @@ -0,0 +1,320 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: mvs.nested.heat +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.vnfci: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + vf_module_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VF_MODULE instance + vf_name: + hidden: false + immutable: false + type: string + description: The VF Name; defaults to VMVM for the virtual MVM VNF. + constraints: + - pattern: '[a-zA-Z0-9]+' + - max_length: 4 + - min_length: 4 + cloud_zone_id: + hidden: false + immutable: false + type: string + description: The cloud zone for this VF instance + vf_instance_num: + hidden: false + immutable: false + type: string + description: The number for this VF instance + constraints: + - pattern: '[0-9]+' + - max_length: 2 + - min_length: 2 + virtual_mgmt_ip_0: + hidden: false + immutable: false + type: string + description: Virtual management network ip address + indx: + hidden: false + immutable: false + type: float + description: Index of the current instance + mvs_mgmt_ip_0: + hidden: false + immutable: false + type: list + description: List of Management network IP addresses for IPv4 + entry_schema: + type: string + flavor: + hidden: false + immutable: false + type: string + description: Server flavor + constraints: [ + ] + key_name: + hidden: false + immutable: false + type: string + description: SSH key name + constraints: [ + ] + vnf_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VF instance + availability_zone_0: + hidden: false + immutable: false + type: list + description: List of Availability Zone IDs or Names + entry_schema: + type: string + mgmt_net_id: + hidden: false + immutable: false + type: string + description: Neutron UUID for the Management network + constraints: [ + ] + vm_instance_num: + hidden: false + immutable: false + type: list + description: VM instance number list must be a list of three-digit numeric value + entry_schema: + type: string + bootimage: + hidden: false + immutable: false + type: string + description: Master bootimage volume id + sec_groups: + hidden: false + immutable: false + type: list + description: Security groups + entry_schema: + type: string + vf_component: + hidden: false + immutable: false + type: string + description: The component that this VF instance is running + constraints: + - pattern: '[a-zA-Z0-9]+' + - max_length: 3 + - min_length: 3 + node_templates: + boot_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + availability_zone: + Fn::Select: + - get_input: indx + - get_input: + - availability_zone_0 + image: + get_input: bootimage + size: 35*1024 + name: + str_replace: + template: Z$CLOUD_ZONE_ID$VF_NAME$VF_INSTANCE_NUM$VF_COMPONENT$VM_INSTANCE_NUM-boot-volume + params: + $VF_NAME: + get_input: vf_name + $CLOUD_ZONE_ID: + get_input: cloud_zone_id + $VM_INSTANCE_NUM: + Fn::Select: + - get_input: indx + - get_input: + - vm_instance_num + $VF_COMPONENT: + get_input: vf_component + $VF_INSTANCE_NUM: + get_input: vf_instance_num + vnfci: + type: org.openecomp.resource.vfc.nodes.heat.vnfci + properties: + flavor: + get_input: flavor + key_name: + get_input: key_name + availability_zone: + Fn::Select: + - get_input: indx + - get_input: + - availability_zone_0 + name: + str_replace: + template: Z$CLOUD_ZONE_ID$VF_NAME$VF_INSTANCE_NUM$VF_COMPONENT$VM_INSTANCE_NUM + params: + $VF_NAME: + get_input: vf_name + $CLOUD_ZONE_ID: + get_input: cloud_zone_id + $VM_INSTANCE_NUM: + Fn::Select: + - get_input: indx + - get_input: + - vm_instance_num + $VF_COMPONENT: + get_input: vf_component + $VF_INSTANCE_NUM: + get_input: vf_instance_num + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: boot_volume + relationship: tosca.relationships.AttachesTo + - local_storage: + capability: tosca.capabilities.Attachment + node: data_volume + relationship: tosca.relationships.AttachesTo + data_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + availability_zone: + Fn::Select: + - get_input: indx + - get_input: + - availability_zone_0 + size: 265*1024 + name: + str_replace: + template: Z$CLOUD_ZONE_ID$VF_NAME$VF_INSTANCE_NUM$VF_COMPONENT$VM_INSTANCE_NUM-data-volume + params: + $VF_NAME: + get_input: vf_name + $CLOUD_ZONE_ID: + get_input: cloud_zone_id + $VM_INSTANCE_NUM: + Fn::Select: + - get_input: indx + - get_input: + - vm_instance_num + $VF_COMPONENT: + get_input: vf_component + $VF_INSTANCE_NUM: + get_input: vf_instance_num + mgmt_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: sec_groups + fixed_ips: + - ip_address: + Fn::Select: + - get_input: indx + - get_input: + - get_input: mvs_mgmt_ip_0 + allowed_address_pairs: + - ip_address: + get_input: virtual_mgmt_ip_0 + name: + str_replace: + template: Z$CLOUD_ZONE_ID$VF_NAME$VF_INSTANCE_NUM$VF_COMPONENT$VM_INSTANCE_NUM-mgmt-port + params: + $VF_NAME: + get_input: vf_name + $CLOUD_ZONE_ID: + get_input: cloud_zone_id + $VM_INSTANCE_NUM: + Fn::Select: + - get_input: indx + - get_input: + - vm_instance_num + $VF_COMPONENT: + get_input: vf_component + $VF_INSTANCE_NUM: + get_input: vf_instance_num + network: + get_input: mgmt_net_id + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: vnfci + relationship: tosca.relationships.network.BindsTo + groups: + mvs.nested.heat: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/mvs.nested.heat.yaml + description: | + Metaswitch MVS (Metaview Server) + members: + - boot_volume + - vnfci + - data_volume + - mgmt_port + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.mvs.nested.heat + capabilities: + os_vnfci: + - vnfci + - os + attachment_mgmt_port: + - mgmt_port + - attachment + endpoint_vnfci: + - vnfci + - endpoint + host_vnfci: + - vnfci + - host + binding_vnfci: + - vnfci + - binding + attachment_boot_volume: + - boot_volume + - attachment + scalable_vnfci: + - vnfci + - scalable + attachment_data_volume: + - data_volume + - attachment + requirements: + local_storage_vnfci: + - vnfci + - local_storage + link_mgmt_port: + - mgmt_port + - link \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group_with_dynamic_count/inputs/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group_with_dynamic_count/inputs/MANIFEST.json new file mode 100644 index 0000000000..c7729c8653 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group_with_dynamic_count/inputs/MANIFEST.json @@ -0,0 +1,19 @@ +{ + "name": "mvs.vfmodule.heat.yaml", + "description": "Metaswitch MVS (Metaview Server)", + "version": "2013-05-23", + "data": [ + { + "file": "mvs.vfmodule.heat.yaml", + "type": "HEAT", + "data": [ + ] + }, + { + "file": "mvs.nested.heat.yaml", + "type": "HEAT", + "data": [ + ] + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group_with_dynamic_count/inputs/mvs.nested.heat.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group_with_dynamic_count/inputs/mvs.nested.heat.yaml new file mode 100644 index 0000000000..8ddc5c6488 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group_with_dynamic_count/inputs/mvs.nested.heat.yaml @@ -0,0 +1,165 @@ +heat_template_version: 2013-05-23 + +description: > + Metaswitch MVS (Metaview Server) + +parameters: + cloud_zone_id: + type: string + description: The cloud zone for this VF instance + vf_name: + type: string + description: The VF Name; defaults to VMVM for the virtual MVM VNF. + constraints: + - allowed_pattern: "[a-zA-Z0-9]+" + - length: { min: 4, max: 4 } + description: Each VF will have a 4-character alphanumeric identifier + vf_instance_num: + type: string + description: The number for this VF instance + constraints: + - allowed_pattern: "[0-9]+" + - length: { min: 2, max: 2 } + description: VF instance number must be a two-digit numeric value + vf_component: + type: string + description: The component that this VF instance is running + constraints: + - allowed_pattern: "[a-zA-Z0-9]+" + - length: { min: 3, max: 3 } + description: Each VF component will have a 3-character alphanumeric identifier + vm_instance_num: + type: comma_delimited_list + description: VM instance number list must be a list of three-digit numeric value + vnf_id: + type: string + description: Unique ID for this VF instance + vf_module_id: + type: string + description: Unique ID for this VF_MODULE instance + bootimage: + type: string + description: Master bootimage volume id + flavor: + type: string + description: Server flavor + constraints: + - custom_constraint: nova.flavor + key_name: + type: string + description: SSH key name + constraints: + - custom_constraint: nova.keypair + + availability_zone_0: + type: comma_delimited_list + description: List of Availability Zone IDs or Names + + sec_groups: + type: comma_delimited_list + description: Security groups + mgmt_net_id: + type: string + description: Neutron UUID for the Management network + constraints: + - custom_constraint: neutron.network + virtual_mgmt_ip_0: + type: string + description: Virtual management network ip address + + mvs_mgmt_ip_0: + type: comma_delimited_list + description: List of Management network IP addresses for IPv4 + + indx: + type: number + description: Index of the current instance + +resources: + mgmt_port: + type: OS::Neutron::Port + properties: + name: + str_replace: + template: Z$CLOUD_ZONE_ID$VF_NAME$VF_INSTANCE_NUM$VF_COMPONENT$VM_INSTANCE_NUM-mgmt-port + params: + $CLOUD_ZONE_ID: { get_param: cloud_zone_id } + $VF_NAME: { get_param: vf_name } + $VF_INSTANCE_NUM: { get_param: vf_instance_num } + $VF_COMPONENT: { get_param: vf_component } + $VM_INSTANCE_NUM: { "Fn::Select" : [ { get_param: indx }, { get_param: [vm_instance_num] } ] } + network_id: { get_param: mgmt_net_id } + security_groups: [{ get_param: sec_groups }] + + fixed_ips: + - ip_address: { "Fn::Select" : [ { get_param: indx }, { get_param: [{ get_param: mvs_mgmt_ip_0 }] } ] } + + allowed_address_pairs: + - ip_address: { get_param: virtual_mgmt_ip_0 } + + boot_volume: + type: OS::Cinder::Volume + properties: + size: 35 + name: + str_replace: + template: Z$CLOUD_ZONE_ID$VF_NAME$VF_INSTANCE_NUM$VF_COMPONENT$VM_INSTANCE_NUM-boot-volume + params: + $CLOUD_ZONE_ID: { get_param: cloud_zone_id } + $VF_NAME: { get_param: vf_name } + $VF_INSTANCE_NUM: { get_param: vf_instance_num } + $VF_COMPONENT: { get_param: vf_component } + $VM_INSTANCE_NUM: { "Fn::Select" : [ { get_param: indx }, { get_param: [vm_instance_num] } ] } + + image: { get_param: bootimage } + + + availability_zone: { "Fn::Select" : [ { get_param: indx }, { get_param: [availability_zone_0] } ] } + + + data_volume: + type: OS::Cinder::Volume + properties: + size: 265 + name: + str_replace: + template: Z$CLOUD_ZONE_ID$VF_NAME$VF_INSTANCE_NUM$VF_COMPONENT$VM_INSTANCE_NUM-data-volume + params: + $CLOUD_ZONE_ID: { get_param: cloud_zone_id } + $VF_NAME: { get_param: vf_name } + $VF_INSTANCE_NUM: { get_param: vf_instance_num } + $VF_COMPONENT: { get_param: vf_component } + $VM_INSTANCE_NUM: { "Fn::Select" : [ { get_param: indx }, { get_param: [vm_instance_num] } ] } + + availability_zone: { "Fn::Select" : [ { get_param: indx }, { get_param: [availability_zone_0] } ] } + + + vnfci: + type: OS::Nova::Server + properties: + name: + str_replace: + template: Z$CLOUD_ZONE_ID$VF_NAME$VF_INSTANCE_NUM$VF_COMPONENT$VM_INSTANCE_NUM + params: + $CLOUD_ZONE_ID: { get_param: cloud_zone_id } + $VF_NAME: { get_param: vf_name } + $VF_INSTANCE_NUM: { get_param: vf_instance_num } + $VF_COMPONENT: { get_param: vf_component } + $VM_INSTANCE_NUM: { "Fn::Select" : [ { get_param: indx }, { get_param: [vm_instance_num] } ] } + block_device_mapping: + - device_name: vda + volume_id: { get_resource: boot_volume } + delete_on_termination: false + - device_name: vdb + volume_id: { get_resource: data_volume } + delete_on_termination: false + flavor: { get_param: flavor } + key_name: { get_param: key_name } + networks: + - port: { get_resource: mgmt_port } + + availability_zone: { "Fn::Select" : [ { get_param: indx }, { get_param: [availability_zone_0] } ] } + + metadata: + vnf_id: { get_param: vnf_id } + vf_module_id: { get_param: vf_module_id } diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group_with_dynamic_count/inputs/mvs.vfmodule.heat.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group_with_dynamic_count/inputs/mvs.vfmodule.heat.yaml new file mode 100644 index 0000000000..95ca069bf8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resource_group_with_dynamic_count/inputs/mvs.vfmodule.heat.yaml @@ -0,0 +1,105 @@ +heat_template_version: 2013-05-23 + +description: > + Metaswitch MVS (Metaview Server) + +parameters: + cloud_zone_id: + type: string + description: The cloud zone for this VF instance + vf_name: + type: string + description: The VF Name; defaults to VMVM for the virtual MVM VNF. + constraints: + - allowed_pattern: "[a-zA-Z0-9]+" + - length: { min: 4, max: 4 } + description: Each VF will have a 4-character alphanumeric identifier + vf_instance_num: + type: string + description: The number for this VF instance + constraints: + - allowed_pattern: "[0-9]+" + - length: { min: 2, max: 2 } + description: VF instance number must be a two-digit numeric value + vf_component: + type: string + description: The component that this VF instance is running + constraints: + - allowed_pattern: "[a-zA-Z0-9]+" + - length: { min: 3, max: 3 } + description: Each VF component will have a 3-character alphanumeric identifier + vm_instance_num: + type: comma_delimited_list + description: VM instance number list must be a list of three-digit numeric value + vnf_id: + type: string + description: Unique ID for this VF instance + vf_module_id: + type: string + description: Unique ID for this VF_MODULE instance + bootimage: + type: string + description: Master bootimage volume id + flavor: + type: string + description: Server flavor + constraints: + - custom_constraint: nova.flavor + key_name: + type: string + description: SSH key name + constraints: + - custom_constraint: nova.keypair + + availability_zone_0: + type: comma_delimited_list + description: List of Availability Zone IDs or Names + + sec_groups: + type: comma_delimited_list + description: Security groups + mgmt_net_id: + type: string + description: Neutron UUID for the Management network + constraints: + - custom_constraint: neutron.network + virtual_mgmt_ip_0: + type: string + description: Virtual management network ip address + + mvs_mgmt_ip_0: + type: comma_delimited_list + description: List of Management network IP addresses for IPv4 + + num_instances: + type: number + description: number of instance of the VF_module + +resources: + mvs_modules: + type: OS::Heat::ResourceGroup + properties: + count: { get_param: num_instances } + resource_def: + type: mvs.nested.heat.yaml + properties: + cloud_zone_id: { get_param: cloud_zone_id } + vf_name: { get_param: vf_name } + vf_instance_num: { get_param: vf_instance_num } + vf_component: { get_param: vf_component } + vm_instance_num: { get_param: vm_instance_num } + vnf_id: { get_param: vnf_id } + vf_module_id: { get_param: vf_module_id } + bootimage: { get_param: bootimage } + flavor: { get_param: flavor } + key_name: { get_param: key_name } + + availability_zone_0: { get_param: availability_zone_0 } + + sec_groups: { get_param: sec_groups } + mgmt_net_id: { get_param: mgmt_net_id } + virtual_mgmt_ip_0: { get_param: virtual_mgmt_ip_0 } + + mvs_mgmt_ip_0: { get_param: mvs_mgmt_ip_0 } + + indx: "%index%" diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/reusenestedfrommultibase/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/reusenestedfrommultibase/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..b99ba37305 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/reusenestedfrommultibase/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,137 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.nested-pcm_v0.1: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + availabilityzone_name: + type: string + description: availabilityzone name + oam_net_gw: + type: string + description: CPS network gateway + pcm_image_name: + type: string + description: PCRF CM image name + security_group_name: + type: string + description: the name of security group + cps_net_ip: + type: string + description: CPS network ip + pcm_flavor_name: + type: string + description: flavor name of PCRF CM instance + pcm_vol: + type: string + description: CPS Cluman Cinder Volume + pcm_server_name: + type: string + description: PCRF CM server name + cps_net_name: + type: string + description: CPS network name + cps_net_mask: + type: string + description: CPS network mask + oam_net_ip: + type: string + description: OAM network ip + oam_net_mask: + type: string + description: CPS network mask + oam_net_name: + type: string + description: OAM network name + attributes: + server_pcm_id: + type: string + description: the pcm nova service id + requirements: + - link_pcm_port_1: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - local_storage_server_pcm: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_pcm_port_0: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + endpoint_server_pcm: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + os_server_pcm: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + host_server_pcm: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + scalable_server_pcm: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + binding_server_pcm: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + attachment_pcm_port_0: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + attachment_pcm_port_1: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/reusenestedfrommultibase/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/reusenestedfrommultibase/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..ed5854c2fd --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/reusenestedfrommultibase/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,216 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + oam_net_ips: + label: OAM network ips + hidden: false + immutable: false + type: list + description: OAM network ips + entry_schema: + type: string + availabilityzone_name: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + oam_net_gw: + label: CPS network gateway + hidden: false + immutable: false + type: string + description: CPS network gateway + pcm_server_names: + label: PCRF CM server names + hidden: false + immutable: false + type: list + description: name of the PCRF CM instance + entry_schema: + type: string + pcm_image_name: + label: PCRF CM image name + hidden: false + immutable: false + type: string + description: PCRF CM image name + cps_net_ips: + label: CPS network ips + hidden: false + immutable: false + type: list + description: CPS network ips + entry_schema: + type: string + security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + pcm_volumes: + label: CPS Cluman Cinder Volume + hidden: false + immutable: false + type: list + description: CPS Cluman Cinder Volume + entry_schema: + type: string + pcm_flavor_name: + label: PCRF CM flavor name + hidden: false + immutable: false + type: string + description: flavor name of PCRF CM instance + cps_net_name: + label: CPS network name + hidden: false + immutable: false + type: string + description: CPS network name + cps_net_mask: + label: CPS network mask + hidden: false + immutable: false + type: string + description: CPS network mask + oam_net_mask: + label: CPS network mask + hidden: false + immutable: false + type: string + description: CPS network mask + oam_net_name: + label: OAM network name + hidden: false + immutable: false + type: string + description: OAM network name + node_templates: + server_pcm_002: + type: org.openecomp.resource.abstract.nodes.heat.nested-pcm_v0.1 + directives: + - substitutable + properties: + pcm_flavor_name: + get_input: pcm_flavor_name + service_template_filter: + substitute_service_template: nested-pcm_v0.1ServiceTemplate.yaml + availabilityzone_name: + get_input: availabilityzone_name + pcm_image_name: + get_input: pcm_image_name + pcm_vol: + get_input: + - pcm_volumes + - 0 + security_group_name: + get_input: security_group_name + pcm_server_name: + get_input: + - pcm_server_names + - 0 + server_pcm_001: + type: org.openecomp.resource.abstract.nodes.heat.nested-pcm_v0.1 + directives: + - substitutable + properties: + service_template_filter: + substitute_service_template: nested-pcm_v0.1ServiceTemplate.yaml + availabilityzone_name: + get_input: availabilityzone_name + oam_net_gw: + get_input: oam_net_gw + pcm_vol: + get_input: + - pcm_volumes + - 0 + security_group_name: + get_input: security_group_name + cps_net_ip: + get_input: + - cps_net_ips + - 0 + cps_net_name: + get_input: cps_net_name + cps_net_mask: + get_input: cps_net_mask + oam_net_ip: + get_input: + - oam_net_ips + - 0 + oam_net_mask: + get_input: oam_net_mask + oam_net_name: + get_input: oam_net_name + server_pcm_003: + type: org.openecomp.resource.abstract.nodes.heat.nested-pcm_v0.1 + directives: + - substitutable + properties: + service_template_filter: + substitute_service_template: nested-pcm_v0.1ServiceTemplate.yaml + availabilityzone_name: + get_input: availabilityzone_name + pcm_vol: + get_input: + - pcm_volumes + - 0 + security_group_name: + get_input: security_group_name + cps_net_ip: + get_input: + - cps_net_ips + - 0 + cps_net_name: + get_input: cps_net_name + cps_net_mask: + get_input: cps_net_mask + groups: + hot-nimbus-pcm_v0.4_2: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/hot-nimbus-pcm_v0.4_2.yaml + description: heat template that creates PCRF Cluman stack + members: + - server_pcm_003 + hot-nimbus-pcm_v0.4: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/hot-nimbus-pcm_v0.4.yaml + description: heat template that creates PCRF Cluman stack + members: + - server_pcm_002 + - server_pcm_001 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/reusenestedfrommultibase/expectedoutputfiles/nested-pcm_v0.1ServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/reusenestedfrommultibase/expectedoutputfiles/nested-pcm_v0.1ServiceTemplate.yaml new file mode 100644 index 0000000000..1b03021742 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/reusenestedfrommultibase/expectedoutputfiles/nested-pcm_v0.1ServiceTemplate.yaml @@ -0,0 +1,207 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested-pcm_v0.1 +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.pcm_server: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + availabilityzone_name: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + oam_net_gw: + label: CPS network gateway + hidden: false + immutable: false + type: string + description: CPS network gateway + pcm_image_name: + label: image name + hidden: false + immutable: false + type: string + description: PCRF CM image name + security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + cps_net_ip: + label: CPS network ip + hidden: false + immutable: false + type: string + description: CPS network ip + pcm_flavor_name: + label: PCRF CM flavor name + hidden: false + immutable: false + type: string + description: flavor name of PCRF CM instance + pcm_vol: + label: CPS Cluman Cinder Volume + hidden: false + immutable: false + type: string + description: CPS Cluman Cinder Volume + pcm_server_name: + label: PCRF CM server name + hidden: false + immutable: false + type: string + description: PCRF CM server name + cps_net_name: + label: CPS network name + hidden: false + immutable: false + type: string + description: CPS network name + cps_net_mask: + label: CPS network mask + hidden: false + immutable: false + type: string + description: CPS network mask + oam_net_ip: + label: OAM network ip + hidden: false + immutable: false + type: string + description: OAM network ip + oam_net_mask: + label: CPS network mask + hidden: false + immutable: false + type: string + description: CPS network mask + oam_net_name: + label: OAM network name + hidden: false + immutable: false + type: string + description: OAM network name + node_templates: + pcm_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: oam_net_ip + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_pcm + relationship: tosca.relationships.network.BindsTo + server_pcm: + type: org.openecomp.resource.vfc.nodes.heat.pcm_server + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + pcm_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: cps_net_ip + network: + get_input: cps_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_pcm + relationship: tosca.relationships.network.BindsTo + groups: + nested-pcm_v0.1: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested-pcm_v0.1.yaml + description: heat template that creates PCRF Cluman stack + members: + - pcm_port_1 + - server_pcm + - pcm_port_0 + outputs: + server_pcm_id: + description: the pcm nova service id + value: server_pcm + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested-pcm_v0.1 + capabilities: + endpoint_server_pcm: + - server_pcm + - endpoint + os_server_pcm: + - server_pcm + - os + host_server_pcm: + - server_pcm + - host + scalable_server_pcm: + - server_pcm + - scalable + binding_server_pcm: + - server_pcm + - binding + attachment_pcm_port_0: + - pcm_port_0 + - attachment + attachment_pcm_port_1: + - pcm_port_1 + - attachment + requirements: + link_pcm_port_0: + - pcm_port_0 + - link + link_pcm_port_1: + - pcm_port_1 + - link + local_storage_server_pcm: + - server_pcm + - local_storage \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/reusenestedfrommultibase/inputs/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/reusenestedfrommultibase/inputs/MANIFEST.json new file mode 100644 index 0000000000..6f151c4f36 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/reusenestedfrommultibase/inputs/MANIFEST.json @@ -0,0 +1,23 @@ +{ + "name": "vEP_JSA_Net", + "description": "Version 2.0 02-09-2016 (Authors: John Doe, user PROD)", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pcm_v0.4.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pcm_v0.4.env", + "type": "HEAT_ENV" + } + ] + },{ + "file": "nested-pcm_v0.1.yaml", + "type": "HEAT" + },{ + "file": "hot-nimbus-pcm_v0.4_2.yaml", + "type": "HEAT" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/reusenestedfrommultibase/inputs/hot-nimbus-pcm_v0.4.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/reusenestedfrommultibase/inputs/hot-nimbus-pcm_v0.4.env new file mode 100644 index 0000000000..78cc03e2ea --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/reusenestedfrommultibase/inputs/hot-nimbus-pcm_v0.4.env @@ -0,0 +1,14 @@ +parameters: + pcm_server_names: ZRDM1PCRF01PCM001 + pcm_image_name: rhel2 + pcm_flavor_name: cps + availabilityzone_name: nova + cps_net_name: int_pcrf_net_0 + cps_net_ips: 172.26.16.113 + cps_net_mask: 255.255.255.0 + oam_net_name: oam_protected_net_0 + oam_net_ips: 107.239.64.121 + oam_net_gw: 107.239.64.1 + oam_net_mask: 255.255.255.0 + pcm_volumes: 249cb355-8fdf-4382-9c3c-a2ebe767d45b + security_group_name: nimbus_security_group diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/reusenestedfrommultibase/inputs/hot-nimbus-pcm_v0.4.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/reusenestedfrommultibase/inputs/hot-nimbus-pcm_v0.4.yaml new file mode 100644 index 0000000000..f7d050790f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/reusenestedfrommultibase/inputs/hot-nimbus-pcm_v0.4.yaml @@ -0,0 +1,82 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Cluman stack + +parameters: + pcm_server_names: + type: comma_delimited_list + label: PCRF CM server names + description: name of the PCRF CM instance + pcm_image_name: + type: string + label: PCRF CM image name + description: PCRF CM image name + pcm_flavor_name: + type: string + label: PCRF CM flavor name + description: flavor name of PCRF CM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + cps_net_name: + type: string + label: CPS network name + description: CPS network name + cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + oam_net_name: + type: string + label: OAM network name + description: OAM network name + oam_net_ips: + type: comma_delimited_list + label: OAM network ips + description: OAM network ips + oam_net_gw: + type: string + label: CPS network gateway + description: CPS network gateway + oam_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcm_volumes: + type: comma_delimited_list + label: CPS Cluman Cinder Volume + description: CPS Cluman Cinder Volume + security_group_name: + type: string + label: security group name + description: the name of security group + +resources: + server_pcm_001: + type: nested-pcm_v0.1.yaml + properties: + availabilityzone_name: { get_param: availabilityzone_name } + security_group_name: { get_param: security_group_name } + pcm_vol: { get_param: [pcm_volumes, 0] } + cps_net_name: { get_param: cps_net_name } + cps_net_ip: { get_param: [cps_net_ips, 0] } + cps_net_mask: { get_param: cps_net_mask } + oam_net_name: { get_param: oam_net_name } + oam_net_ip: { get_param: [oam_net_ips, 0] } + oam_net_mask: { get_param: oam_net_mask } + oam_net_gw: { get_param: oam_net_gw } + + server_pcm_002: + type: nested-pcm_v0.1.yaml + properties: + pcm_server_name: { get_param: [pcm_server_names, 0] } + pcm_image_name: { get_param: pcm_image_name } + pcm_flavor_name: { get_param: pcm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + security_group_name: { get_param: security_group_name } + pcm_vol: { get_param: [pcm_volumes, 0] } diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/reusenestedfrommultibase/inputs/hot-nimbus-pcm_v0.4_2.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/reusenestedfrommultibase/inputs/hot-nimbus-pcm_v0.4_2.yaml new file mode 100644 index 0000000000..72d84b64a4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/reusenestedfrommultibase/inputs/hot-nimbus-pcm_v0.4_2.yaml @@ -0,0 +1,71 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Cluman stack + +parameters: + pcm_server_names: + type: comma_delimited_list + label: PCRF CM server names + description: name of the PCRF CM instance + pcm_image_name: + type: string + label: PCRF CM image name + description: PCRF CM image name + pcm_flavor_name: + type: string + label: PCRF CM flavor name + description: flavor name of PCRF CM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + cps_net_name: + type: string + label: CPS network name + description: CPS network name + cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + oam_net_name: + type: string + label: OAM network name + description: OAM network name + oam_net_ips: + type: comma_delimited_list + label: OAM network ips + description: OAM network ips + oam_net_gw: + type: string + label: CPS network gateway + description: CPS network gateway + oam_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcm_volumes: + type: comma_delimited_list + label: CPS Cluman Cinder Volume + description: CPS Cluman Cinder Volume + security_group_name: + type: string + label: security group name + description: the name of security group + +resources: + server_pcm_003: + type: nested-pcm_v0.1.yaml + properties: + availabilityzone_name: { get_param: availabilityzone_name } + security_group_name: { get_param: security_group_name } + pcm_vol: { get_param: [pcm_volumes, 0] } + cps_net_name: { get_param: cps_net_name } + cps_net_ip: { get_param: [cps_net_ips, 0] } + cps_net_mask: { get_param: cps_net_mask } + + + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/reusenestedfrommultibase/inputs/nested-pcm_v0.1.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/reusenestedfrommultibase/inputs/nested-pcm_v0.1.yaml new file mode 100644 index 0000000000..4e12676aa8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/reusenestedfrommultibase/inputs/nested-pcm_v0.1.yaml @@ -0,0 +1,114 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Cluman stack + +parameters: + pcm_server_name: + type: string + label: PCRF CM server name + description: PCRF CM server name + pcm_image_name: + type: string + label: image name + description: PCRF CM image name + pcm_flavor_name: + type: string + label: PCRF CM flavor name + description: flavor name of PCRF CM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + cps_net_name: + type: string + label: CPS network name + description: CPS network name + cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + oam_net_name: + type: string + label: OAM network name + description: OAM network name + oam_net_ip: + type: string + label: OAM network ip + description: OAM network ip + oam_net_gw: + type: string + label: CPS network gateway + description: CPS network gateway + oam_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcm_vol: + type: string + label: CPS Cluman Cinder Volume + description: CPS Cluman Cinder Volume + security_group_name: + type: string + label: security group name + description: the name of security group + +resources: + network: + type: net + script_init: + type: OS:INIT + server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + server_pcm: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcm_server_name } + image: { get_param: pcm_image_name } + flavor: { get_param: pcm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcm_port_0} + - port: { get_resource: pcm_port_1} + block_device_mapping: + - device_name: vdb + volume_id: { get_param: pcm_vol} + user_data_format: RAW + user_data: + get_resource: server_init + + pcm_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: cps_net_name } + fixed_ips: + - ip_address: { get_param: cps_net_ip } + security_groups: [{ get_param: security_group_name }] + + pcm_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: + - ip_address: { get_param: oam_net_ip } + security_groups: [{ get_param: security_group_name }] + + #pcm_vol_attachment: + # type: OS::Cinder::VolumeAttachment + # properties: + # volume_id: { get_param: pcm_vol } + # mountpoint: /dev/vdb + # instance_uuid: { get_resource: server_pcm } +outputs: + server_pcm_id: + description: the pcm nova service id + value: { get_resource: server_pcm } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/single/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/single/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..b99ba37305 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/single/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,137 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.nested-pcm_v0.1: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + availabilityzone_name: + type: string + description: availabilityzone name + oam_net_gw: + type: string + description: CPS network gateway + pcm_image_name: + type: string + description: PCRF CM image name + security_group_name: + type: string + description: the name of security group + cps_net_ip: + type: string + description: CPS network ip + pcm_flavor_name: + type: string + description: flavor name of PCRF CM instance + pcm_vol: + type: string + description: CPS Cluman Cinder Volume + pcm_server_name: + type: string + description: PCRF CM server name + cps_net_name: + type: string + description: CPS network name + cps_net_mask: + type: string + description: CPS network mask + oam_net_ip: + type: string + description: OAM network ip + oam_net_mask: + type: string + description: CPS network mask + oam_net_name: + type: string + description: OAM network name + attributes: + server_pcm_id: + type: string + description: the pcm nova service id + requirements: + - link_pcm_port_1: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - local_storage_server_pcm: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_pcm_port_0: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + endpoint_server_pcm: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + os_server_pcm: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + host_server_pcm: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + scalable_server_pcm: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + binding_server_pcm: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + attachment_pcm_port_0: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + attachment_pcm_port_1: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/single/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/single/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..dcc2a9abbb --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/single/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,236 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.compute: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + oam_net_ips: + label: OAM network ips + hidden: false + immutable: false + type: list + description: OAM network ips + default: + - 107.239.64.121 + entry_schema: + type: string + availabilityzone_name: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + default: nova + oam_net_gw: + label: CPS network gateway + hidden: false + immutable: false + type: string + description: CPS network gateway + default: 107.239.64.1 + pcm_server_names: + label: PCRF CM server names + hidden: false + immutable: false + type: list + description: name of the PCRF CM instance + default: + - ZRDM1PCRF01PCM001 + entry_schema: + type: string + pcm_image_name: + label: PCRF CM image name + hidden: false + immutable: false + type: string + description: PCRF CM image name + default: rhel2 + cps_net_ips: + label: CPS network ips + hidden: false + immutable: false + type: list + description: CPS network ips + default: + - 172.26.16.113 + entry_schema: + type: string + security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + default: nimbus_security_group + pcm_volumes: + label: CPS Cluman Cinder Volume + hidden: false + immutable: false + type: list + description: CPS Cluman Cinder Volume + default: + - 249cb355-8fdf-4382-9c3c-a2ebe767d45b + entry_schema: + type: string + compute_image_name: + hidden: false + immutable: false + type: string + pcm_flavor_name: + label: PCRF CM flavor name + hidden: false + immutable: false + type: string + description: flavor name of PCRF CM instance + default: cps + net_name: + hidden: false + immutable: false + type: string + cps_net_name: + label: CPS network name + hidden: false + immutable: false + type: string + description: CPS network name + default: int_pcrf_net_0 + cps_net_mask: + label: CPS network mask + hidden: false + immutable: false + type: string + description: CPS network mask + default: 255.255.255.0 + oam_net_mask: + label: CPS network mask + hidden: false + immutable: false + type: string + description: CPS network mask + default: 255.255.255.0 + oam_net_name: + label: OAM network name + hidden: false + immutable: false + type: string + description: OAM network name + default: oam_protected_net_0 + node_templates: + server_pcm_001: + type: org.openecomp.resource.abstract.nodes.heat.nested-pcm_v0.1 + directives: + - substitutable + properties: + availabilityzone_name: + get_input: availabilityzone_name + oam_net_gw: + get_input: oam_net_gw + pcm_image_name: + get_input: pcm_image_name + security_group_name: + get_input: security_group_name + cps_net_ip: + get_input: + - cps_net_ips + - 0 + pcm_flavor_name: + get_input: pcm_flavor_name + service_template_filter: + substitute_service_template: nested-pcm_v0.1ServiceTemplate.yaml + pcm_vol: + get_input: + - pcm_volumes + - 0 + pcm_server_name: + get_input: + - pcm_server_names + - 0 + cps_net_name: + get_input: cps_net_name + cps_net_mask: + get_input: cps_net_mask + oam_net_ip: + get_input: + - oam_net_ips + - 0 + oam_net_mask: + get_input: oam_net_mask + oam_net_name: + get_input: oam_net_name + compute_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + network: + get_input: net_name + server_compute_get_attr_test: + type: org.openecomp.resource.vfc.nodes.heat.compute + properties: + flavor: + compute_flavor_name: null + image: + get_input: compute_image_name + config_drive: + get_attribute: + - compute_port_0 + - tenant_id + - port_security_enabled + - device_id + - qos_policy + - allowed_address_pairs + - show + - device_owner + - network + - security_groups + - fixed_ips + - mac_address + - admin_state_up + - name + - subnets + - status + user_data_format: + get_attribute: + - server_pcm_001 + - oam_net_gw + name: + compute_name: null + groups: + hot-nimbus-pcm_v0.4: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/hot-nimbus-pcm_v0.4.yaml + description: heat template that creates PCRF Cluman stack + members: + - server_pcm_001 + - compute_port_0 + - server_compute_get_attr_test \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/single/expectedoutputfiles/nested-pcm_v0.1ServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/single/expectedoutputfiles/nested-pcm_v0.1ServiceTemplate.yaml new file mode 100644 index 0000000000..1b03021742 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/single/expectedoutputfiles/nested-pcm_v0.1ServiceTemplate.yaml @@ -0,0 +1,207 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested-pcm_v0.1 +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.pcm_server: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + availabilityzone_name: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + oam_net_gw: + label: CPS network gateway + hidden: false + immutable: false + type: string + description: CPS network gateway + pcm_image_name: + label: image name + hidden: false + immutable: false + type: string + description: PCRF CM image name + security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + cps_net_ip: + label: CPS network ip + hidden: false + immutable: false + type: string + description: CPS network ip + pcm_flavor_name: + label: PCRF CM flavor name + hidden: false + immutable: false + type: string + description: flavor name of PCRF CM instance + pcm_vol: + label: CPS Cluman Cinder Volume + hidden: false + immutable: false + type: string + description: CPS Cluman Cinder Volume + pcm_server_name: + label: PCRF CM server name + hidden: false + immutable: false + type: string + description: PCRF CM server name + cps_net_name: + label: CPS network name + hidden: false + immutable: false + type: string + description: CPS network name + cps_net_mask: + label: CPS network mask + hidden: false + immutable: false + type: string + description: CPS network mask + oam_net_ip: + label: OAM network ip + hidden: false + immutable: false + type: string + description: OAM network ip + oam_net_mask: + label: CPS network mask + hidden: false + immutable: false + type: string + description: CPS network mask + oam_net_name: + label: OAM network name + hidden: false + immutable: false + type: string + description: OAM network name + node_templates: + pcm_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: oam_net_ip + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_pcm + relationship: tosca.relationships.network.BindsTo + server_pcm: + type: org.openecomp.resource.vfc.nodes.heat.pcm_server + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + pcm_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: cps_net_ip + network: + get_input: cps_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_pcm + relationship: tosca.relationships.network.BindsTo + groups: + nested-pcm_v0.1: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested-pcm_v0.1.yaml + description: heat template that creates PCRF Cluman stack + members: + - pcm_port_1 + - server_pcm + - pcm_port_0 + outputs: + server_pcm_id: + description: the pcm nova service id + value: server_pcm + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested-pcm_v0.1 + capabilities: + endpoint_server_pcm: + - server_pcm + - endpoint + os_server_pcm: + - server_pcm + - os + host_server_pcm: + - server_pcm + - host + scalable_server_pcm: + - server_pcm + - scalable + binding_server_pcm: + - server_pcm + - binding + attachment_pcm_port_0: + - pcm_port_0 + - attachment + attachment_pcm_port_1: + - pcm_port_1 + - attachment + requirements: + link_pcm_port_0: + - pcm_port_0 + - link + link_pcm_port_1: + - pcm_port_1 + - link + local_storage_server_pcm: + - server_pcm + - local_storage \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/single/inputs/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/single/inputs/MANIFEST.json new file mode 100644 index 0000000000..345ca77b2a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/single/inputs/MANIFEST.json @@ -0,0 +1,20 @@ +{ + "name": "vEP_JSA_Net", + "description": "Version 2.0 02-09-2016 (Authors: John Doe, user PROD)", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pcm_v0.4.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pcm_v0.4.env", + "type": "HEAT_ENV" + } + ] + },{ + "file": "nested-pcm_v0.1.yaml", + "type": "HEAT" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/single/inputs/hot-nimbus-pcm_v0.4.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/single/inputs/hot-nimbus-pcm_v0.4.env new file mode 100644 index 0000000000..78cc03e2ea --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/single/inputs/hot-nimbus-pcm_v0.4.env @@ -0,0 +1,14 @@ +parameters: + pcm_server_names: ZRDM1PCRF01PCM001 + pcm_image_name: rhel2 + pcm_flavor_name: cps + availabilityzone_name: nova + cps_net_name: int_pcrf_net_0 + cps_net_ips: 172.26.16.113 + cps_net_mask: 255.255.255.0 + oam_net_name: oam_protected_net_0 + oam_net_ips: 107.239.64.121 + oam_net_gw: 107.239.64.1 + oam_net_mask: 255.255.255.0 + pcm_volumes: 249cb355-8fdf-4382-9c3c-a2ebe767d45b + security_group_name: nimbus_security_group diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/single/inputs/hot-nimbus-pcm_v0.4.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/single/inputs/hot-nimbus-pcm_v0.4.yaml new file mode 100644 index 0000000000..e4a79f34ba --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/single/inputs/hot-nimbus-pcm_v0.4.yaml @@ -0,0 +1,94 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Cluman stack + +parameters: + pcm_server_names: + type: comma_delimited_list + label: PCRF CM server names + description: name of the PCRF CM instance + pcm_image_name: + type: string + label: PCRF CM image name + description: PCRF CM image name + pcm_flavor_name: + type: string + label: PCRF CM flavor name + description: flavor name of PCRF CM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + cps_net_name: + type: string + label: CPS network name + description: CPS network name + cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + oam_net_name: + type: string + label: OAM network name + description: OAM network name + oam_net_ips: + type: comma_delimited_list + label: OAM network ips + description: OAM network ips + oam_net_gw: + type: string + label: CPS network gateway + description: CPS network gateway + oam_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcm_volumes: + type: comma_delimited_list + label: CPS Cluman Cinder Volume + description: CPS Cluman Cinder Volume + security_group_name: + type: string + label: security group name + description: the name of security group + compute_image_name: + type: string + net_name: + type: string + +resources: + server_pcm_001: + type: nested-pcm_v0.1.yaml + properties: + pcm_server_name: { get_param: [pcm_server_names, 0] } + pcm_image_name: { get_param: pcm_image_name } + pcm_flavor_name: { get_param: pcm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + security_group_name: { get_param: security_group_name } + pcm_vol: { get_param: [pcm_volumes, 0] } + cps_net_name: { get_param: cps_net_name } + cps_net_ip: { get_param: [cps_net_ips, 0] } + cps_net_mask: { get_param: cps_net_mask } + oam_net_name: { get_param: oam_net_name } + oam_net_ip: { get_param: [oam_net_ips, 0] } + oam_net_mask: { get_param: oam_net_mask } + oam_net_gw: { get_param: oam_net_gw } + + server_compute_get_attr_test: + type: OS::Nova::Server + properties: + config_drive: {get_attr: [compute_port_0]} + name: { compute_name } + image: { get_param: compute_image_name } + flavor: { compute_flavor_name } + user_data_format: { get_attr: [server_pcm_001 , oam_net_gw] } + user_data: { get_attr: [server_pcm_001]} + + compute_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: net_name } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/single/inputs/nested-pcm_v0.1.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/single/inputs/nested-pcm_v0.1.yaml new file mode 100644 index 0000000000..4e12676aa8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/single/inputs/nested-pcm_v0.1.yaml @@ -0,0 +1,114 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Cluman stack + +parameters: + pcm_server_name: + type: string + label: PCRF CM server name + description: PCRF CM server name + pcm_image_name: + type: string + label: image name + description: PCRF CM image name + pcm_flavor_name: + type: string + label: PCRF CM flavor name + description: flavor name of PCRF CM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + cps_net_name: + type: string + label: CPS network name + description: CPS network name + cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + oam_net_name: + type: string + label: OAM network name + description: OAM network name + oam_net_ip: + type: string + label: OAM network ip + description: OAM network ip + oam_net_gw: + type: string + label: CPS network gateway + description: CPS network gateway + oam_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcm_vol: + type: string + label: CPS Cluman Cinder Volume + description: CPS Cluman Cinder Volume + security_group_name: + type: string + label: security group name + description: the name of security group + +resources: + network: + type: net + script_init: + type: OS:INIT + server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + server_pcm: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcm_server_name } + image: { get_param: pcm_image_name } + flavor: { get_param: pcm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcm_port_0} + - port: { get_resource: pcm_port_1} + block_device_mapping: + - device_name: vdb + volume_id: { get_param: pcm_vol} + user_data_format: RAW + user_data: + get_resource: server_init + + pcm_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: cps_net_name } + fixed_ips: + - ip_address: { get_param: cps_net_ip } + security_groups: [{ get_param: security_group_name }] + + pcm_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: + - ip_address: { get_param: oam_net_ip } + security_groups: [{ get_param: security_group_name }] + + #pcm_vol_attachment: + # type: OS::Cinder::VolumeAttachment + # properties: + # volume_id: { get_param: pcm_vol } + # mountpoint: /dev/vdb + # instance_uuid: { get_resource: server_pcm } +outputs: + server_pcm_id: + description: the pcm nova service id + value: { get_resource: server_pcm } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/outputs/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/outputs/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..eac8fd673d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/outputs/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,86 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + node_templates: + jsa_net: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + shared: true + network_name: + get_input: jsa_net_name + jsa_net_test_full_attribute: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + dhcp_agent_ids: + - '1000' + - '1001' + - '1002' + tenant_id: 23456 + port_security_enabled: true + shared: true + admin_state_up: false + qos_policy: full + network_name: + get_input: jsa_net_name + subnets: + jsa_net_test_full_attribute_subnet: + cidr: + get_input: jsa_cidr + value_specs: + key1: spec1 + key2: spec2 + groups: + outputs: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/outputs.yaml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - jsa_net + - jsa_net_test_full_attribute + outputs: + output_regular: + description: output_regula + value: regular + output_func_getParam: + description: output_func_getParam + value: + get_input: jsa_cidr + output_func_getAttr: + description: output_func_getAttr + value: + get_attribute: + - jsa_net_test_full_attribute + - network_name + output_func_getResource: + description: output_func_getResource + value: jsa_net_test_full_attribute \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/outputs/inputs/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/outputs/inputs/MANIFEST.json new file mode 100644 index 0000000000..3997ee80ff --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/outputs/inputs/MANIFEST.json @@ -0,0 +1,11 @@ +{ + "name": "vEP_JSA_Net", + "description": "Version 2.0 02-09-2016 (Authors: John Doe, user PROD)", + "version": "2013-05-23", + "data": [ + { + "file": "outputs.yaml", + "type": "HEAT" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/outputs/inputs/outputs.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/outputs/inputs/outputs.yaml new file mode 100644 index 0000000000..8d48c82e65 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/outputs/inputs/outputs.yaml @@ -0,0 +1,48 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +outputs: + output_regular: + description: output_regula + value: regular + output_func_getParam: + description: output_func_getParam + value: {get_param: jsa_cidr} + output_func_getAttr: + description: output_func_getAttr + value: {get_attr: [jsa_net_test_full_attribute, name]} + output_func_getResource: + description: output_func_getResource + value: {get_resource: jsa_net_test_full_attribute_subnet} + +resources: + jsa_net: + type: OS::Neutron::Net + properties: + name: {get_param: jsa_net_name} + shared: True + + jsa_net_test_full_attribute: + type: OS::Neutron::Net + properties: + name: {get_param: jsa_net_name} + shared: True + dhcp_agent_ids: ['1000','1001','1002'] + tenant_id: 23456 + port_security_enabled: t + admin_state_up: 0 + qos_policy: full + value_specs: + key1: "spec1" + key2: "spec2" + + jsa_net_test_full_attribute_subnet: + type: OS::Neutron::Subnet + properties: + network_id: {get_resource: jsa_net_test_full_attribute} + cidr: {get_param: jsa_cidr} + + + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/parameters/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/parameters/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..5cd5d0e597 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/parameters/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,181 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + param_type_comma_delimited_list: + hidden: false + immutable: false + type: list + description: param comma_delimited_list - List + entry_schema: + type: string + param_type_string_default_value_with_env: + hidden: false + immutable: false + type: string + description: param value should be - HEAT_ENV_default string + default: HEAT_ENV default string + volume_type: + label: FSB Volume + hidden: false + immutable: false + type: string + description: FSB Volume type + FSB1_volume_name: + label: FSB Volume + hidden: false + immutable: false + type: string + description: FSB Volume name + param_constraint_length_allowed_pattern_range_hidden: + label: User Name + hidden: true + immutable: false + type: string + description: User name to be configured for the application + constraints: + - max_length: 8 + - min_length: 6 + - pattern: '[A-Z]+[a-zA-Z0-9]*' + - in_range: + - 0 + - 10 + param_type_boolean_default_value_with_env: + hidden: false + immutable: false + type: boolean + description: param value should be false + default: false + param_type_string: + hidden: false + immutable: false + type: string + description: param String - string + param_type_string_default_value: + hidden: false + immutable: false + type: string + description: param value should be - HEAT_default string + default: HEAT_default string + param_type_number: + hidden: false + immutable: false + type: float + description: param number - float + param_type_boolean: + hidden: false + immutable: false + type: boolean + description: param boolean - boolean + param_type_comma_delimited_list_default_value_with_env: + hidden: false + immutable: false + type: list + description: param value should be [b1,b2,b3,b4] + default: + - b1 + - b2 + - b3 + - b4 + entry_schema: + type: string + param_type_boolean_default_value: + hidden: false + immutable: false + type: boolean + description: param value should be true + default: true + param_type_number_default_value: + hidden: false + immutable: false + type: float + description: param value should be 12345 + default: 12345 + FSB_1_image: + label: FSB Image + hidden: false + immutable: false + type: string + description: FSB Image name + param_type_comma_delimited_list_default_value: + hidden: false + immutable: false + type: list + description: param value should be [a1,a2,a3,a4] + default: + - a1 + - a2 + - a3 + - a4 + entry_schema: + type: string + param_type_number_default_value_with_env: + hidden: false + immutable: false + type: float + description: param value should be 54321 + default: 54321 + param_type_json: + hidden: false + immutable: false + type: json + description: param json - map + param_allowed_values: + label: Instance Type + hidden: false + immutable: false + type: string + description: Instance type for compute instances + constraints: + - valid_values: + - m1.small + - m1.medium + - m1.large + node_templates: + FSB1_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + image: + get_input: FSB_1_image + volume_type: + get_input: volume_type + size: 3*1024 + name: + get_input: FSB1_volume_name + groups: + parameters: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/parameters.yaml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - FSB1_volume \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/parameters/inputs/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/parameters/inputs/MANIFEST.json new file mode 100644 index 0000000000..bc0e397432 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/parameters/inputs/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "vEP_JSA_Net", + "description": "Version 2.0 02-09-2016 (Authors: John Doe, user PROD)", + "version": "2013-05-23", + "data": [ + { + "file": "parameters.yaml", + "type": "HEAT", + "data": [ + { + "file": "parameters.env", + "type": "HEAT_ENV" + } + ] + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/parameters/inputs/parameters.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/parameters/inputs/parameters.env new file mode 100644 index 0000000000..21978f2482 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/parameters/inputs/parameters.env @@ -0,0 +1,6 @@ +parameters: + param_type_string_default_value_with_env: HEAT_ENV default string + param_type_number_default_value_with_env: 54321 + param_type_boolean_default_value_with_env: false + param_type_comma_delimited_list_default_value_with_env: b1,b2,b3,b4 + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/parameters/inputs/parameters.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/parameters/inputs/parameters.yaml new file mode 100644 index 0000000000..6f1b69ac59 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/parameters/inputs/parameters.yaml @@ -0,0 +1,101 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + param_type_string: + type: string + description: param String - string + param_type_number: + type: number + description: param number - float + param_type_json: + type: json + description: param json - map + param_type_boolean: + type: boolean + description: param boolean - boolean + param_type_comma_delimited_list: + type: comma_delimited_list + description: param comma_delimited_list - List + + volume_type: + type: string + label: FSB Volume + description: FSB Volume type + + FSB1_volume_name: + type: string + label: FSB Volume + description: FSB Volume name + + FSB_1_image: + type: string + label: FSB Image + description: FSB Image name + + param_constraint_length_allowed_pattern_range_hidden: + type: string + label: User Name + description: User name to be configured for the application + hidden: true + constraints: + - length: { min: 6, max: 8 } + description: User name must be between 6 and 8 characters + - allowed_pattern: "[A-Z]+[a-zA-Z0-9]*" + description: User name must start with an uppercase character + - range: { min: 0, max: 10 } + param_allowed_values: + type: string + label: Instance Type + description: Instance type for compute instances + constraints: + - allowed_values: + - m1.small + - m1.medium + - m1.large + + param_type_string_default_value: + type: string + default: HEAT_default string + description: param value should be - HEAT_default string + param_type_string_default_value_with_env: + type: string + description: param value should be - HEAT_ENV_default string + default: HEAT_default string + + param_type_number_default_value: + type: number + description: param value should be 12345 + default: 12345 + param_type_number_default_value_with_env: + type: number + description: param value should be 54321 + default: 12345 + param_type_boolean_default_value: + type: boolean + description: param value should be true + default: true + param_type_boolean_default_value_with_env: + type: boolean + description: param value should be false + default: true + param_type_comma_delimited_list_default_value: + type: comma_delimited_list + description: param value should be [a1,a2,a3,a4] + default: a1,a2,a3,a4 + param_type_comma_delimited_list_default_value_with_env: + type: comma_delimited_list + description: param value should be [b1,b2,b3,b4] + default: a1,a2,a3,a4 +resources: + FSB1_volume: + type: OS::Cinder::Volume + properties: + size: 3 + volume_type: {get_param: volume_type} + name: {get_param: FSB1_volume_name} + image: {get_param: FSB_1_image} + + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Contrail_Network_Rule/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Contrail_Network_Rule/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..0d9ec35ce7 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Contrail_Network_Rule/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,197 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + start_src_ports: + hidden: false + immutable: false + type: float + description: Start of src port + private_net_1_gateway: + hidden: false + immutable: false + type: string + description: Private network gateway address + private_net_2_name: + hidden: false + immutable: false + type: string + description: Name of private network to be created + private_net_2_gateway: + hidden: false + immutable: false + type: string + description: Private network gateway address + policy_name: + hidden: false + immutable: false + type: string + description: Virtual network id + private_net_1_name: + hidden: false + immutable: false + type: string + description: Name of private network to be created + private_net_2_pool_start: + hidden: false + immutable: false + type: string + description: Start of private network IP address allocation pool + private_net_2_cidr: + hidden: false + immutable: false + type: string + description: Private network address (CIDR notation) + private_net_1_pool_end: + hidden: false + immutable: false + type: string + description: End of private network IP address allocation pool + end_src_ports: + hidden: false + immutable: false + type: float + description: End of src port + apply_service: + hidden: false + immutable: false + type: string + description: service to apply + start_dst_ports: + hidden: false + immutable: false + type: float + description: Start of dst port + end_dst_ports: + hidden: false + immutable: false + type: float + description: End of dst port + private_net_1_cidr: + hidden: false + immutable: false + type: string + description: Private network address (CIDR notation) + private_net_1_pool_start: + hidden: false + immutable: false + type: string + description: Start of private network IP address allocation pool + private_net_2_pool_end: + hidden: false + immutable: false + type: string + description: End of private network IP address allocation pool + direction: + hidden: false + immutable: false + type: string + description: Direction of Policy + node_templates: + private_net_1: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + network_name: + get_input: private_net_1_name + subnets: + private_subnet_1: + cidr: + get_input: private_net_1_cidr + gateway_ip: + get_input: private_net_1_gateway + allocation_pools: + - start: + get_input: private_net_1_pool_start + end: + get_input: private_net_1_pool_end + private_policy: + type: org.openecomp.resource.vfc.rules.nodes.heat.network.contrail.NetworkRules + properties: + entries: + policy_rule: + - src_ports: + - start_port: + get_input: start_src_ports + end_port: + get_input: end_src_ports + protocol: any + action_list: + apply_service: + - get_input: apply_service + dst_addresses: + - virtual_network: private_net_1 + dst_ports: + - start_port: + get_input: start_dst_ports + end_port: + get_input: end_dst_ports + src_addresses: + - virtual_network: private_net_2 + direction: + get_input: direction + name: + get_input: policy_name + requirements: + - network: + capability: tosca.capabilities.Attachment + node: private_net_1 + relationship: org.openecomp.relationships.AttachesTo + - network: + capability: tosca.capabilities.Attachment + node: private_net_2 + relationship: org.openecomp.relationships.AttachesTo + private_net_2: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + network_name: + get_input: private_net_2_name + subnets: + private_subnet_2: + cidr: + get_input: private_net_2_cidr + gateway_ip: + get_input: private_net_2_gateway + allocation_pools: + - start: + get_input: private_net_2_pool_start + end: + get_input: private_net_2_pool_end + groups: + network_policy_chain: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/network_policy_chain.yaml + description: | + HOT template to creates two virtual network with one subnet each. Creates a network policy for applying service between two VNs created before. Attach the network policy to two virtual networks + members: + - private_net_1 + - private_policy + - private_net_2 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Contrail_Network_Rule/inputs/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Contrail_Network_Rule/inputs/MANIFEST.json new file mode 100644 index 0000000000..81b11d1a77 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Contrail_Network_Rule/inputs/MANIFEST.json @@ -0,0 +1,12 @@ +{ + "name": "network_policy_chain", + "description": "network_policy_chain", + "version": "2013-05-23", + "data": [ + { + "file": "network_policy_chain.yaml", + "type": "HEAT", + "data": [] + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Contrail_Network_Rule/inputs/network_policy_chain.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Contrail_Network_Rule/inputs/network_policy_chain.yaml new file mode 100644 index 0000000000..8963b1ff75 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Contrail_Network_Rule/inputs/network_policy_chain.yaml @@ -0,0 +1,117 @@ +heat_template_version: 2013-05-23 + +description: > + HOT template to creates two virtual network with one subnet each. + Creates a network policy for applying service between two VNs created before. + Attach the network policy to two virtual networks +parameters: + policy_name: + type: string + description: Virtual network id + direction: + type: string + description: Direction of Policy + start_src_ports: + type: number + description: Start of src port + end_src_ports: + type: number + description: End of src port + start_dst_ports: + type: number + description: Start of dst port + end_dst_ports: + type: number + description: End of dst port + apply_service: + type: string + description: service to apply + private_net_1_name: + type: string + description: Name of private network to be created + private_net_1_cidr: + type: string + description: Private network address (CIDR notation) + private_net_1_gateway: + type: string + description: Private network gateway address + private_net_1_pool_start: + type: string + description: Start of private network IP address allocation pool + private_net_1_pool_end: + type: string + description: End of private network IP address allocation pool + private_net_2_name: + type: string + description: Name of private network to be created + private_net_2_cidr: + type: string + description: Private network address (CIDR notation) + private_net_2_gateway: + type: string + description: Private network gateway address + private_net_2_pool_start: + type: string + description: Start of private network IP address allocation pool + private_net_2_pool_end: + type: string + description: End of private network IP address allocation pool + +resources: + private_net_1: + type: OS::Neutron::Net + properties: + name: { get_param: private_net_1_name } + + private_net_2: + type: OS::Neutron::Net + properties: + name: { get_param: private_net_2_name } + + private_subnet_1: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: private_net_1 } + cidr: { get_param: private_net_1_cidr } + gateway_ip: { get_param: private_net_1_gateway } + allocation_pools: + - start: { get_param: private_net_1_pool_start } + end: { get_param: private_net_1_pool_end } + + private_subnet_2: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: private_net_2 } + cidr: { get_param: private_net_2_cidr } + gateway_ip: { get_param: private_net_2_gateway } + allocation_pools: + - start: { get_param: private_net_2_pool_start } + end: { get_param: private_net_2_pool_end } + + private_policy: + type: OS::Contrail::NetworkPolicy + properties: + name: { get_param: policy_name } + entries: + policy_rule: [ + { + "direction": { get_param: direction }, + "protocol": "any", + "src_ports": [{"start_port": {get_param: start_src_ports}, "end_port": {get_param: end_src_ports}}], + "dst_ports": [{"start_port": {get_param: start_dst_ports}, "end_port": {get_param: end_dst_ports}}], + "dst_addresses": [{ "virtual_network": {get_resource: private_net_1}}], + "action_list": {"apply_service": [{get_param: apply_service}]}, + "src_addresses": [{ "virtual_network": {get_resource: private_net_2}}] + }, + ] + private_policy_attach_net1: + type: OS::Contrail::AttachPolicy + properties: + network: { get_resource: private_net_1 } + policy: { get_attr: [private_policy, fq_name] } + + private_policy_attach_net2: + type: OS::Contrail::AttachPolicy + properties: + network: { get_resource: private_net_2 } + policy: { get_attr: [private_policy, fq_name] } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Contrail_VirtualNetwork/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Contrail_VirtualNetwork/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..2b047dd8ae --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Contrail_VirtualNetwork/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,1308 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.NCB1: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.GPB2: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.NCB2: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.GPB1: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.FSB2: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.VLC1: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.FSB1: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.VLC2: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + Internal2_name: + hidden: false + immutable: false + type: string + default: Internal2-subnet + vlc2-Internal2-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to vlc2-Internal2 + default: 00:81:37:0E:02:12 + epc-sctp-a-net-rt: + hidden: false + immutable: false + type: string + description: epc-sctp-a route target + default: 13979:105717 + epc-sctp-b-net-rt: + hidden: false + immutable: false + type: string + description: epc-sctp-b route target + default: 13979:105719 + gpb-flavor: + hidden: false + immutable: false + type: string + description: Flavor to use for servers gpb + default: m4.xlarge4 + Internal1_cidr: + hidden: false + immutable: false + type: string + default: 169.253.0.0/17 + epc-sctp-a-pool-start: + hidden: false + immutable: false + type: string + description: epc-sctp-a-net network ip pool start IP address + default: 107.243.37.3 + Internal2_subnet_name: + hidden: false + immutable: false + type: string + default: vmme_int_int_sub_2 + Internal1_subnet_name: + hidden: false + immutable: false + type: string + default: vmme_int_int_sub_1 + gpb1-Internal1-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to gpb1-Internal1 + default: 00:80:37:0E:01:22 + gpb1-Internal1-ip: + hidden: false + immutable: false + type: string + default: 169.254.0.101 + FSB_1_image: + hidden: false + immutable: false + type: string + description: image name + fsb1-Internal2-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to fsb1-Internal2 + default: 00:81:37:0E:0B:12 + ncb_zone: + hidden: false + immutable: false + type: string + description: cluster for spawnning ncb instances + default: nova + Internal2_net_name: + hidden: false + immutable: false + type: string + default: vmme_int_int_2 + epc-sctp-a-pool-end: + hidden: false + immutable: false + type: string + description: epc-sctp-a-net network ip pool end IP address + default: 107.243.37.30 + Internal1_name: + hidden: false + immutable: false + type: string + default: Internal1-subnet + gpb2-name: + hidden: false + immutable: false + type: string + description: Name of gpb2 + default: ZRDM1MMEX33GPB002 + fsb2-Internal1-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to fsb2-Internal1 + default: 00:80:37:0E:0D:12 + fsb2-name: + hidden: false + immutable: false + type: string + description: Name of fsb1 + default: ZRDM1MMEX33FSB002 + static_prefix_sctp_b_1: + hidden: false + immutable: false + type: string + description: Static Prefix + default: 107.239.40.64/30 + fsb2-oam-ip: + hidden: false + immutable: false + type: string + default: 107.250.172.222 + fsb2-flavor: + hidden: false + immutable: false + type: string + description: Flavor to use for servers fsb2 + default: m4.xlarge4 + fsb2-Internal2-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to fsb2-Internal2 + default: 00:81:37:0E:0D:12 + ncb2-Internal1-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to ncb2-Internal1 + default: 00:80:37:0E:0F:12 + ncb2-name: + hidden: false + immutable: false + type: string + description: Name of ncb2 + default: ZRDM1MMEX33NCB002 + epc-sctp-b-pool-end: + hidden: false + immutable: false + type: string + description: epc-sctp-b-net network ip pool end IP address + default: 107.243.37.62 + vlc1-gtp-ip: + hidden: false + immutable: false + type: string + default: 107.243.37.67 + epc-sctp-b-pool-start: + hidden: false + immutable: false + type: string + description: epc-sctp-b-net network ip pool start IP address + default: 107.243.37.35 + my_instance: + hidden: false + immutable: false + type: string + description: instance + Internal2_shared: + hidden: false + immutable: false + type: string + default: 'False' + Internal1_net_name: + hidden: false + immutable: false + type: string + default: vmme_int_int_1 + vlc2-name: + hidden: false + immutable: false + type: string + description: Name of vlc2 + default: ZRDM1MMEX33VLC002 + Internal2_ipam_name: + hidden: false + immutable: false + type: string + default: vmme_ipam_int2 + vlc1-sctp-b-ip: + hidden: false + immutable: false + type: string + default: 107.243.37.35 + Internal1_net_pool_end: + hidden: false + immutable: false + type: string + default: 169.253.0.254 + Internal1_default_gateway: + hidden: false + immutable: false + type: string + default: 169.253.0.3 + ncb1-Internal1-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to ncb1-Internal1 + default: 00:80:37:0E:09:12 + epc-gtp-net-name: + hidden: false + immutable: false + type: string + description: gtp net name + default: EPC-GTP + vlc1-Internal1-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to vlc1-Internal1 + default: 00:80:37:0E:01:12 + gpb2-Internal1-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to gpb2-Internal1 + default: 00:80:37:0E:02:22 + epc-gtp-net-cidr: + hidden: false + immutable: false + type: string + description: gtp stubnet + default: 107.243.37.64/27 + oam_net_id: + hidden: false + immutable: false + type: string + description: uuid of oam network + default: 47bf4cca-0961-422f-bcd6-d5a4fbb1a351 + vlc_zone: + hidden: false + immutable: false + type: string + description: cluster for spawnning vlc instances + default: nova + vlc2-Internal1-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to vlc2-Internal1 + default: 00:80:37:0E:02:12 + epc-sctp-a-net-cidr: + hidden: false + immutable: false + type: string + description: epc-sctp-a subnet + default: 107.243.37.0/27 + Internal1_forwarding_mode: + hidden: false + immutable: false + type: string + default: l2 + Internal2_dhcp: + hidden: false + immutable: false + type: boolean + default: false + fsb1-oam-ip: + hidden: false + immutable: false + type: string + default: 107.250.172.221 + FSB_2_image: + hidden: false + immutable: false + type: string + description: image name + vlc1-oam-ip: + hidden: false + immutable: false + type: string + default: 107.250.172.227 + epc-sctp-a-net-name: + hidden: false + immutable: false + type: string + description: epc-sctp-a net name + default: EPC-SCTP-A + vlc2-oam-ip: + hidden: false + immutable: false + type: string + default: 107.250.172.228 + Internal2_net_pool_start: + hidden: false + immutable: false + type: string + default: 169.255.0.100 + FSB1_volume_name: + hidden: false + immutable: false + type: string + description: volume name + vlc1-sctp-a-ip: + hidden: false + immutable: false + type: string + default: 107.243.37.3 + Internal1_ipam_name: + hidden: false + immutable: false + type: string + default: vmme_ipam_int1 + Internal1_dhcp: + hidden: false + immutable: false + type: boolean + default: false + Internal2_external: + hidden: false + immutable: false + type: string + default: 'False' + Internal2_forwarding_mode: + hidden: false + immutable: false + type: string + default: l2 + vlc1-name: + hidden: false + immutable: false + type: string + description: Name of vlc1 + default: ZRDM1MMEX33VLC002 + vlc-flavor: + hidden: false + immutable: false + type: string + description: Flavor to use for servers vlc + default: m4.xlarge4 + epc-gtp-net-rt: + hidden: false + immutable: false + type: string + description: gtp route target + default: 13979:105715 + gpb_zone: + hidden: false + immutable: false + type: string + description: cluster for spawnning gpb instances + default: nova + Internal1-net: + hidden: false + immutable: false + type: string + description: net + gpb1-Internal2-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to gpb1-Internal2 + default: 00:81:37:0E:01:22 + fsb1-Internal1-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to fsb1-Internal1 + default: 00:80:37:0E:0B:12 + FSB2_volume_name: + hidden: false + immutable: false + type: string + description: volume name + VMME_FSB2_boot_volume: + hidden: false + immutable: false + type: string + default: 089a0d11-4b15-4370-8343-3f90907b1221 + fsb_zone: + hidden: false + immutable: false + type: string + description: cluster for spawnning fsb instances + default: nova + VMME_FSB1_boot_volume: + hidden: false + immutable: false + type: string + default: 8248e794-6173-4b49-b9c3-8219b0b56f4e + Internal2_default_gateway: + hidden: false + immutable: false + type: string + default: 169.255.0.3 + Internal1_external: + hidden: false + immutable: false + type: string + default: 'False' + vlc2-sctp-a-ip: + hidden: false + immutable: false + type: string + default: 107.243.37.4 + ncb-flavor: + hidden: false + immutable: false + type: string + description: Flavor to use for servers ncb + default: m4.xlarge4 + Internal1_shared: + hidden: false + immutable: false + type: string + default: 'False' + fsb1-name: + hidden: false + immutable: false + type: string + description: Name of fsb1 + default: ZRDM1MMEX33FSB001 + static_prefix_gtp_1: + hidden: false + immutable: false + type: string + description: Static Prefix + default: 107.239.40.96/30 + epc-sctp-b-net-gateway: + hidden: false + immutable: false + type: string + description: epc-sctp-b-net network gateway + default: 107.243.37.33 + epc-sctp-b-net-cidr: + hidden: false + immutable: false + type: string + description: epc-sctp-b subnet + default: 107.243.37.32/24 + epc-gtp-pool-end: + hidden: false + immutable: false + type: string + description: gtp network ip pool end IP address + default: 107.243.37.94 + epc-sctp-a-net-gateway: + hidden: false + immutable: false + type: string + description: epc-sctp-a-net network gateway + default: 107.243.37.1 + vlc2-gtp-ip: + hidden: false + immutable: false + type: string + default: 107.243.37.68 + vlc2-sctp-b-ip: + hidden: false + immutable: false + type: string + default: 107.243.37.36 + Internal1_net_pool_start: + hidden: false + immutable: false + type: string + default: 169.253.0.100 + volume_size: + hidden: false + immutable: false + type: string + description: volume + fsb2-image: + hidden: false + immutable: false + type: string + description: Name of image to use for server fsb2 + default: MME_FSB2_15B-CP04-r5a01 + ncb2-Internal2-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to ncb2-Internal2 + default: 00:81:37:0E:0F:12 + ncb1-name: + hidden: false + immutable: false + type: string + description: Name of ncb1 + default: ZRDM1MMEX33NCB001 + fsb1-image: + hidden: false + immutable: false + type: string + description: Name of image to use for server fsb1 + default: MME_FSB1_15B-CP04-r5a01 + fsb1-flavor: + hidden: false + immutable: false + type: string + description: Flavor to use for servers fsb1 + default: m4.xlarge4 + volume_type: + hidden: false + immutable: false + type: string + description: volume + Internal2_net_pool_end: + hidden: false + immutable: false + type: string + default: 169.255.0.254 + epc-sctp-b-net-name: + hidden: false + immutable: false + type: string + description: epc-sctp-b net name + default: EPC-SCTP-B + Internal2_cidr: + hidden: false + immutable: false + type: string + default: 169.255.0.0/17 + epc-gtp-net-gateway: + hidden: false + immutable: false + type: string + description: gtp network gateway + default: 107.243.37.65 + gpb2-Internal2-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to gpb2-Internal2 + default: 00:81:37:0E:02:22 + ncb1-Internal2-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to ncb1-Internal2 + default: 00:81:37:0E:09:12 + epc-gtp-pool-start: + hidden: false + immutable: false + type: string + description: gtp network ip pool start IP address + default: 107.243.37.67 + static_prefix_sctp_a_1: + hidden: false + immutable: false + type: string + description: Static Prefix + default: 107.239.40.32/30 + gpb1-name: + hidden: false + immutable: false + type: string + description: Name of gpb1 + default: ZRDM1MMEX33GPB001 + pxe-image: + hidden: false + immutable: false + type: string + description: Name of image to use for server ncb + default: MME_PXE-BOOT_cxp9025898_2r5a01.qcow2 + vlc1-Internal2-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to vlc1-Internal2 + default: 00:81:37:0E:01:12 + node_templates: + NCB1: + type: org.openecomp.resource.vfc.nodes.heat.NCB1 + properties: + flavor: + get_input: ncb-flavor + availability_zone: + get_input: ncb_zone + image: + get_input: pxe-image + name: + get_input: ncb1-name + NCB2: + type: org.openecomp.resource.vfc.nodes.heat.NCB2 + properties: + flavor: + get_input: ncb-flavor + availability_zone: + get_input: ncb_zone + image: + get_input: pxe-image + name: + get_input: ncb2-name + VLC2_OAM: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + fixed_ips: + - ip_address: + get_input: vlc2-oam-ip + network: + get_input: oam_net_id + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: VLC2 + relationship: tosca.relationships.network.BindsTo + epc-gtp-net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + route_targets: + - get_input: epc-gtp-net-rt + network_name: + get_input: epc-gtp-net-name + subnets: + epc-gtp-subnet: + cidr: + get_input: epc-gtp-net-cidr + gateway_ip: + get_input: epc-gtp-net-gateway + allocation_pools: + - start: + get_input: epc-gtp-pool-start + end: + get_input: epc-gtp-pool-end + NCB1_Internal1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: ncb1-Internal1-mac + network: Internal1-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal1-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: NCB1 + relationship: tosca.relationships.network.BindsTo + VLC2_Internal2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: vlc2-Internal2-mac + network: Internal2-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal2-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: VLC2 + relationship: tosca.relationships.network.BindsTo + NCB1_Internal2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: ncb1-Internal2-mac + network: Internal2-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal2-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: NCB1 + relationship: tosca.relationships.network.BindsTo + VLC2_Internal1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: vlc2-Internal1-mac + network: Internal1-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal1-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: VLC2 + relationship: tosca.relationships.network.BindsTo + VLC2_GTP: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + fixed_ips: + - ip_address: + get_input: vlc2-gtp-ip + network: epc-gtp-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: epc-gtp-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: VLC2 + relationship: tosca.relationships.network.BindsTo + FSB1_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + image: + get_input: FSB_1_image + volume_type: + get_input: volume_type + size: 3*1024 + name: + get_input: FSB1_volume_name + testConvertGetParamFunctions: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + shared: + get_input: Internal1_shared + forwarding_mode: + get_input: Internal1_forwarding_mode + external: + get_input: + - my_instance + - networks + - private + - 0 + network_name: + get_input: Internal1_net_name + FSB2_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + image: + get_input: FSB_2_image + volume_type: + get_input: volume_type + size: '(get_input : volume_size) * 1024' + name: + get_input: FSB2_volume_name + FSB1_OAM: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + fixed_ips: + - ip_address: + get_input: fsb1-oam-ip + network: + get_input: oam_net_id + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: FSB1 + relationship: tosca.relationships.network.BindsTo + Internal1-net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + dhcp_enabled: + get_input: Internal1_dhcp + shared: + get_input: Internal1_shared + forwarding_mode: + get_input: Internal1_forwarding_mode + external: true + route_targets: + get_artifact: + - SELF + - nimbus-ethernet + network_name: + get_input: Internal1_net_name + subnets: + Internal3-subnet: + enable_dhcp: + get_input: Internal2_dhcp + cidr: + get_input: Internal2_cidr + gateway_ip: + get_input: Internal2_default_gateway + Internal1-subnet: + enable_dhcp: + get_input: Internal1_dhcp + cidr: + get_input: Internal1_cidr + gateway_ip: + get_input: Internal1_default_gateway + Internal4-subnet: + enable_dhcp: false + cidr: + get_input: Internal1_cidr + gateway_ip: + get_input: Internal1_default_gateway + artifacts: + nimbus-ethernet: + type: tosca.artifacts.Deployment + file: ../Artifacts/nimbus-ethernet.sh + GPB2_Internal1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: gpb2-Internal1-mac + network: Internal1-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal1-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: GPB2 + relationship: tosca.relationships.network.BindsTo + GPB2_Internal2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: gpb2-Internal2-mac + network: Internal2-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal2-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: GPB2 + relationship: tosca.relationships.network.BindsTo + testConvertGetAttributeFunctions: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + shared: + get_input: Internal1_shared + forwarding_mode: + get_input: Internal1_forwarding_mode + external: + get_input: Internal1_external + network_name: + get_input: Internal1_net_name + NCB2_Internal2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: ncb2-Internal2-mac + network: Internal2-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal2-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: NCB2 + relationship: tosca.relationships.network.BindsTo + NCB2_Internal1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: ncb2-Internal1-mac + network: Internal1-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal1-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: NCB2 + relationship: tosca.relationships.network.BindsTo + FSB2: + type: org.openecomp.resource.vfc.nodes.heat.FSB2 + properties: + flavor: + get_input: fsb2-flavor + availability_zone: + get_input: fsb_zone + name: + get_input: fsb2-name + FSB1: + type: org.openecomp.resource.vfc.nodes.heat.FSB1 + properties: + flavor: + get_input: fsb1-flavor + availability_zone: + get_input: fsb_zone + name: + get_input: fsb1-name + Internal2-net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + dhcp_enabled: + get_input: Internal2_dhcp + shared: + get_input: Internal2_shared + forwarding_mode: + get_input: Internal2_forwarding_mode + external: + get_input: Internal2_external + network_name: + get_input: Internal2_name + subnets: + Internal2-subnet: + enable_dhcp: + get_input: Internal2_dhcp + cidr: + get_input: Internal2_cidr + gateway_ip: + get_input: Internal2_default_gateway + VLC1_Internal1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: vlc1-Internal1-mac + network: Internal1-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal1-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: VLC1 + relationship: tosca.relationships.network.BindsTo + epc-sctp-a-net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + route_targets: + - get_input: epc-sctp-a-net-rt + network_name: + get_input: epc-sctp-a-net-name + subnets: + epc-sctp-a-subnet: + cidr: + get_input: epc-sctp-a-net-cidr + gateway_ip: + get_input: epc-sctp-a-net-gateway + allocation_pools: + - start: + get_input: epc-sctp-a-pool-start + end: + get_input: epc-sctp-a-pool-end + VLC1_Internal2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: vlc1-Internal2-mac + network: Internal2-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal2-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: VLC1 + relationship: tosca.relationships.network.BindsTo + VLC1_SCTP_B: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + fixed_ips: + - ip_address: + get_input: vlc1-sctp-b-ip + network: epc-sctp-b-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: epc-sctp-b-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: VLC1 + relationship: tosca.relationships.network.BindsTo + VLC2_SCTP_B: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + fixed_ips: + - ip_address: + get_input: vlc2-sctp-b-ip + network: epc-sctp-b-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: epc-sctp-b-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: VLC2 + relationship: tosca.relationships.network.BindsTo + VLC1_SCTP_A: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + fixed_ips: + - ip_address: + get_input: vlc1-sctp-a-ip + network: epc-sctp-a-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: epc-sctp-a-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: VLC1 + relationship: tosca.relationships.network.BindsTo + VLC2_SCTP_A: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + fixed_ips: + - ip_address: + get_input: vlc2-sctp-a-ip + network: epc-sctp-a-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: epc-sctp-a-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: VLC2 + relationship: tosca.relationships.network.BindsTo + VLC1: + type: org.openecomp.resource.vfc.nodes.heat.VLC1 + properties: + flavor: + get_input: vlc-flavor + availability_zone: + get_input: vlc_zone + image: + get_input: pxe-image + name: + get_input: vlc1-name + FSB1_Internal2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: fsb1-Internal2-mac + network: Internal2-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal2-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: FSB1 + relationship: tosca.relationships.network.BindsTo + VLC2: + type: org.openecomp.resource.vfc.nodes.heat.VLC2 + properties: + flavor: + get_input: vlc-flavor + availability_zone: + get_input: vlc_zone + image: + get_input: pxe-image + name: + get_input: vlc2-name + FSB1_Internal1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: fsb1-Internal1-mac + network: Internal1-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal1-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: FSB1 + relationship: tosca.relationships.network.BindsTo + FSB2_Internal2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: fsb2-Internal2-mac + network: Internal2-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal2-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: FSB2 + relationship: tosca.relationships.network.BindsTo + FSB2_Internal1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: fsb2-Internal1-mac + network: Internal1-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal1-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: FSB2 + relationship: tosca.relationships.network.BindsTo + VLC1_OAM: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + fixed_ips: + - ip_address: + get_input: vlc1-oam-ip + network: + get_input: oam_net_id + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: VLC1 + relationship: tosca.relationships.network.BindsTo + epc-sctp-b-net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + route_targets: + - get_input: epc-sctp-b-net-rt + network_name: + get_input: epc-sctp-b-net-name + subnets: + epc-sctp-b-subnet: + cidr: + get_input: epc-sctp-b-net-cidr + gateway_ip: + get_input: epc-sctp-b-net-gateway + allocation_pools: + - start: + get_input: epc-sctp-b-pool-start + end: + get_input: epc-sctp-b-pool-end + GPB2: + type: org.openecomp.resource.vfc.nodes.heat.GPB2 + properties: + flavor: + get_input: gpb-flavor + availability_zone: + get_input: gpb_zone + image: + get_input: pxe-image + name: + get_input: gpb2-name + GPB1: + type: org.openecomp.resource.vfc.nodes.heat.GPB1 + properties: + flavor: + get_input: gpb-flavor + availability_zone: + get_input: gpb_zone + image: + get_input: pxe-image + name: + get_input: gpb1-name + VLC1_GTP: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + fixed_ips: + - ip_address: + get_input: vlc1-gtp-ip + network: epc-gtp-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: epc-gtp-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: VLC1 + relationship: tosca.relationships.network.BindsTo + FSB2_OAM: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + fixed_ips: + - ip_address: + get_input: fsb2-oam-ip + network: + get_input: oam_net_id + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: FSB2 + relationship: tosca.relationships.network.BindsTo + GPB1_Internal2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: gpb1-Internal2-mac + network: Internal2-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal2-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: GPB1 + relationship: tosca.relationships.network.BindsTo + GPB1_Internal1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: gpb1-Internal1-mac + network: Internal1-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal1-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: GPB1 + relationship: tosca.relationships.network.BindsTo + groups: + vmme_small: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/vmme_small.yml + description: | + HOT template to create vmme 2 fsb 2 ncb 2 gbp 2 vlc + members: + - NCB1 + - NCB2 + - VLC2_OAM + - epc-gtp-net + - NCB1_Internal1 + - VLC2_Internal2 + - NCB1_Internal2 + - VLC2_Internal1 + - VLC2_GTP + - FSB1_volume + - testConvertGetParamFunctions + - FSB2_volume + - FSB1_OAM + - Internal1-net + - GPB2_Internal1 + - GPB2_Internal2 + - testConvertGetAttributeFunctions + - NCB2_Internal2 + - NCB2_Internal1 + - FSB2 + - FSB1 + - Internal2-net + - VLC1_Internal1 + - epc-sctp-a-net + - VLC1_Internal2 + - VLC1_SCTP_B + - VLC2_SCTP_B + - VLC1_SCTP_A + - VLC2_SCTP_A + - VLC1 + - FSB1_Internal2 + - VLC2 + - FSB1_Internal1 + - FSB2_Internal2 + - FSB2_Internal1 + - VLC1_OAM + - epc-sctp-b-net + - GPB2 + - GPB1 + - VLC1_GTP + - FSB2_OAM + - GPB1_Internal2 + - GPB1_Internal1 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Contrail_VirtualNetwork/inputs/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Contrail_VirtualNetwork/inputs/MANIFEST.json new file mode 100644 index 0000000000..9b0de07788 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Contrail_VirtualNetwork/inputs/MANIFEST.json @@ -0,0 +1,21 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create vmme 2 fsb 2 ncb 2 gbp 2 vlc", + "version": "2013-05-23", + "data": [ + { + "file": "vmme_small.yml", + "type": "HEAT", + "data": [ + { + "file": "vmme_small.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "nimbus-ethernet.sh", + "type": "OTHER" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Contrail_VirtualNetwork/inputs/nimbus-ethernet.sh b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Contrail_VirtualNetwork/inputs/nimbus-ethernet.sh new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Contrail_VirtualNetwork/inputs/vmme_small.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Contrail_VirtualNetwork/inputs/vmme_small.env new file mode 100644 index 0000000000..e46cfd2a2d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Contrail_VirtualNetwork/inputs/vmme_small.env @@ -0,0 +1,97 @@ +parameters: + oam_net_id: 47bf4cca-0961-422f-bcd6-d5a4fbb1a351 + fsb1-name: ZRDM1MMEX33FSB001 + fsb2-name: ZRDM1MMEX33FSB002 + ncb1-name: ZRDM1MMEX33NCB001 + ncb2-name: ZRDM1MMEX33NCB002 + vlc1-name: ZRDM1MMEX33VLC002 + vlc2-name: ZRDM1MMEX33VLC002 + gpb1-name: ZRDM1MMEX33GPB001 + gpb2-name: ZRDM1MMEX33GPB002 + epc-sctp-a-net-name: EPC-SCTP-A + epc-sctp-a-net-rt: 13979:105717 + epc-sctp-a-net-cidr: 107.243.37.0/27 + epc-sctp-a-net-gateway: 107.243.37.1 + epc-sctp-a-pool-start: 107.243.37.3 + epc-sctp-a-pool-end: 107.243.37.30 + epc-sctp-b-net-name: EPC-SCTP-B + epc-sctp-b-net-rt: 13979:105719 + epc-sctp-b-net-cidr: 107.243.37.32/24 + epc-sctp-b-net-gateway: 107.243.37.33 + epc-sctp-b-pool-start: 107.243.37.35 + epc-sctp-b-pool-end: 107.243.37.62 + epc-gtp-net-name: EPC-GTP + epc-gtp-net-rt: 13979:105715 + epc-gtp-net-cidr: 107.243.37.64/27 + epc-gtp-net-gateway: 107.243.37.65 + epc-gtp-pool-start: 107.243.37.67 + epc-gtp-pool-end: 107.243.37.94 + fsb1-image: MME_FSB1_15B-CP04-r5a01 + fsb2-image: MME_FSB2_15B-CP04-r5a01 + fsb1-flavor: m4.xlarge4 + fsb2-flavor: m4.xlarge4 + fsb_zone: nova + fsb1-Internal1-mac: 00:80:37:0E:0B:12 + fsb1-Internal2-mac: 00:81:37:0E:0B:12 + fsb1-oam-ip: 107.250.172.221 + fsb2-Internal1-mac: 00:80:37:0E:0D:12 + fsb2-Internal2-mac: 00:81:37:0E:0D:12 + fsb2-oam-ip: 107.250.172.222 + pxe-image: MME_PXE-BOOT_cxp9025898_2r5a01.qcow2 + ncb-flavor: m4.xlarge4 + ncb_zone: nova + ncb1-Internal1-mac: 00:80:37:0E:09:12 + ncb1-Internal2-mac: 00:81:37:0E:09:12 + ncb2-Internal1-mac: 00:80:37:0E:0F:12 + ncb2-Internal2-mac: 00:81:37:0E:0F:12 + gpb-flavor: m4.xlarge4 + gpb_zone: nova + gpb1-Internal1-mac: 00:80:37:0E:01:22 + gpb1-Internal1-ip: 169.254.0.101 + gpb1-Internal2-mac: 00:81:37:0E:01:22 + gpb2-Internal1-mac: 00:80:37:0E:02:22 + gpb2-Internal2-mac: 00:81:37:0E:02:22 + vlc-flavor: m4.xlarge4 + vlc_zone: nova + vlc1-sctp-a-ip: 107.243.37.3 + vlc1-sctp-b-ip: 107.243.37.35 + vlc1-gtp-ip: 107.243.37.67 + vlc1-oam-ip: 107.250.172.227 + vlc2-sctp-a-ip: 107.243.37.4 + vlc2-sctp-b-ip: 107.243.37.36 + vlc2-gtp-ip: 107.243.37.68 + vlc2-oam-ip: 107.250.172.228 + vlc1-Internal1-mac: 00:80:37:0E:01:12 + vlc1-Internal2-mac: 00:81:37:0E:01:12 + vlc2-Internal1-mac: 00:80:37:0E:02:12 + vlc2-Internal2-mac: 00:81:37:0E:02:12 + Internal1_net_name: vmme_int_int_1 + Internal1_subnet_name: vmme_int_int_sub_1 + Internal1_ipam_name: vmme_ipam_int1 + Internal1_cidr: 169.253.0.0/17 + Internal1_forwarding_mode: "l2" + Internal1_dhcp: "False" + Internal1_shared: "False" + Internal1_external: "False" + Internal1_name: "Internal1-subnet" + Internal1_default_gateway: 169.253.0.3 + Internal1_net_pool_start: 169.253.0.100 + Internal1_net_pool_end: 169.253.0.254 + Internal2_net_name: vmme_int_int_2 + Internal2_subnet_name: vmme_int_int_sub_2 + Internal2_ipam_name: vmme_ipam_int2 + Internal2_cidr: 169.255.0.0/17 + Internal2_shared: "False" + Internal2_external: "False" + Internal2_forwarding_mode: "l2" + Internal2_dhcp: "False" + Internal2_name: "Internal2-subnet" + Internal2_default_gateway: 169.255.0.3 + Internal2_net_pool_start: 169.255.0.100 + Internal2_net_pool_end: 169.255.0.254 + static_prefix_sctp_a_1: 107.239.40.32/30 + static_prefix_gtp_1: 107.239.40.96/30 + static_prefix_sctp_b_1: 107.239.40.64/30 + VMME_FSB1_boot_volume: 8248e794-6173-4b49-b9c3-8219b0b56f4e + VMME_FSB2_boot_volume: 089a0d11-4b15-4370-8343-3f90907b1221 + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Contrail_VirtualNetwork/inputs/vmme_small.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Contrail_VirtualNetwork/inputs/vmme_small.yml new file mode 100644 index 0000000000..21df075c4a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Contrail_VirtualNetwork/inputs/vmme_small.yml @@ -0,0 +1,722 @@ +heat_template_version: 2013-05-23 + +description: > + HOT template to create vmme 2 fsb 2 ncb 2 gbp 2 vlc + +parameters: + fsb1-oam-ip: + type: string + fsb2-oam-ip: + type: string + vlc1-oam-ip: + type: string + vlc2-oam-ip: + type: string + Internal1_net_pool_start: + type: string + Internal1_net_pool_end: + type: string + Internal2_net_pool_start: + type: string + Internal2_net_pool_end: + type: string + Internal1_default_gateway: + type: string + Internal2_default_gateway: + type: string + Internal1_shared: + type: string + Internal1_external: + type: string + Internal1_net_name: + type: string + Internal1_subnet_name: + type: string + Internal1_ipam_name: + type: string + Internal1_cidr: + type: string + Internal1_forwarding_mode: + type: string + Internal1_dhcp: + type: string + Internal1_name: + type: string + Internal2_net_name: + type: string + Internal2_subnet_name: + type: string + Internal2_ipam_name: + type: string + Internal2_cidr: + type: string + Internal2_forwarding_mode: + type: string + Internal2_dhcp: + type: string + Internal2_name: + type: string + Internal2_shared: + type: string + Internal2_external: + type: string + vlc1-sctp-a-ip: + type: string + vlc1-sctp-b-ip: + type: string + vlc1-gtp-ip: + type: string + vlc2-sctp-a-ip: + type: string + vlc2-sctp-b-ip: + type: string + vlc2-gtp-ip: + type: string + fsb1-name: + type: string + description: Name of fsb1 + fsb2-name: + type: string + description: Name of fsb1 + ncb1-name: + type: string + description: Name of ncb1 + ncb2-name: + type: string + description: Name of ncb2 + vlc1-name: + type: string + description: Name of vlc1 + vlc2-name: + type: string + description: Name of vlc2 + gpb1-name: + type: string + description: Name of gpb1 + gpb2-name: + type: string + description: Name of gpb2 + fsb_zone: + type: string + description: cluster for spawnning fsb instances + fsb1-image: + type: string + description: Name of image to use for server fsb1 + fsb1-flavor: + type: string + description: Flavor to use for servers fsb1 + oam_net_id: + type: string + description: uuid of oam network + fsb1-Internal1-mac: + type: string + description: static mac address assigned to fsb1-Internal1 + fsb1-Internal2-mac: + type: string + description: static mac address assigned to fsb1-Internal2 + fsb2-image: + type: string + description: Name of image to use for server fsb2 + fsb2-flavor: + type: string + description: Flavor to use for servers fsb2 + fsb2-Internal1-mac: + type: string + description: static mac address assigned to fsb2-Internal1 + fsb2-Internal2-mac: + type: string + description: static mac address assigned to fsb2-Internal2 + pxe-image: + type: string + description: Name of image to use for server ncb + ncb-flavor: + type: string + description: Flavor to use for servers ncb + ncb_zone: + type: string + description: cluster for spawnning ncb instances + ncb1-Internal1-mac: + type: string + description: static mac address assigned to ncb1-Internal1 + ncb1-Internal2-mac: + type: string + description: static mac address assigned to ncb1-Internal2 + ncb2-Internal1-mac: + type: string + description: static mac address assigned to ncb2-Internal1 + ncb2-Internal2-mac: + type: string + description: static mac address assigned to ncb2-Internal2 + gpb-flavor: + type: string + description: Flavor to use for servers gpb + gpb_zone: + type: string + description: cluster for spawnning gpb instances + gpb1-Internal1-ip: + type: string + gpb1-Internal1-mac: + type: string + description: static mac address assigned to gpb1-Internal1 + gpb1-Internal2-mac: + type: string + description: static mac address assigned to gpb1-Internal2 + gpb2-Internal1-mac: + type: string + description: static mac address assigned to gpb2-Internal1 + gpb2-Internal2-mac: + type: string + description: static mac address assigned to gpb2-Internal2 + vlc-flavor: + type: string + description: Flavor to use for servers vlc + vlc_zone: + type: string + description: cluster for spawnning vlc instances + vlc1-Internal1-mac: + type: string + description: static mac address assigned to vlc1-Internal1 + vlc1-Internal2-mac: + type: string + description: static mac address assigned to vlc1-Internal2 + vlc2-Internal1-mac: + type: string + description: static mac address assigned to vlc2-Internal1 + vlc2-Internal2-mac: + type: string + description: static mac address assigned to vlc2-Internal2 + epc-sctp-a-net-name: + type: string + description: epc-sctp-a net name + epc-sctp-a-net-rt: + type: string + description: epc-sctp-a route target + epc-sctp-a-net-cidr: + type: string + description: epc-sctp-a subnet + epc-sctp-a-net-gateway: + type: string + description: epc-sctp-a-net network gateway + epc-sctp-a-pool-start: + type: string + description: epc-sctp-a-net network ip pool start IP address + epc-sctp-a-pool-end: + type: string + description: epc-sctp-a-net network ip pool end IP address + epc-sctp-b-net-name: + type: string + description: epc-sctp-b net name + epc-sctp-b-net-rt: + type: string + description: epc-sctp-b route target + epc-sctp-b-net-cidr: + type: string + description: epc-sctp-b subnet + epc-sctp-b-net-gateway: + type: string + description: epc-sctp-b-net network gateway + epc-sctp-b-pool-start: + type: string + description: epc-sctp-b-net network ip pool start IP address + epc-sctp-b-pool-end: + type: string + description: epc-sctp-b-net network ip pool end IP address + epc-gtp-net-name: + type: string + description: gtp net name + epc-gtp-net-rt: + type: string + description: gtp route target + epc-gtp-net-cidr: + type: string + description: gtp stubnet + epc-gtp-net-gateway: + type: string + description: gtp network gateway + epc-gtp-pool-start: + type: string + description: gtp network ip pool start IP address + epc-gtp-pool-end: + type: string + description: gtp network ip pool end IP address + static_prefix_sctp_a_1: + type: string + description: Static Prefix + static_prefix_sctp_b_1: + type: string + description: Static Prefix + static_prefix_gtp_1: + type: string + description: Static Prefix + VMME_FSB1_boot_volume: + type: string + VMME_FSB2_boot_volume: + type: string + volume_type: + type: string + description: volume + volume_size: + type: string + description: volume + FSB1_volume_name: + type: string + description: volume name + FSB_1_image: + type: string + description: image name + FSB2_volume_name: + type: string + description: volume name + FSB_2_image: + type: string + description: image name + my_instance: + type: string + description: instance + Internal1-net: + type: string + description: net + +resources: + FSB1_volume: + type: OS::Cinder::Volume + properties: + size: 3 + volume_type: {get_param: volume_type} + name: {get_param: FSB1_volume_name} + image: {get_param: FSB_1_image} + + FSB2_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: volume_size} + volume_type: {get_param: volume_type} + name: {get_param: FSB2_volume_name} + image: {get_param: FSB_2_image} + + Internal1_ipam: + type: OS::Contrail::NetworkIpam + properties: + name: { get_param: Internal1_ipam_name } + + Internal2_ipam: + type: OS::Contrail::NetworkIpam + properties: + name: { get_param: Internal2_ipam_name } + + Internal1-net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: Internal1_net_name } + forwarding_mode: { get_param: Internal1_forwarding_mode } + shared: { get_param: Internal1_shared } + external: true + route_targets: { get_file: 'file:///nimbus-ethernet.sh' } + testConvertGetParamFunctions: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: Internal1_net_name } + forwarding_mode: { get_param: Internal1_forwarding_mode } + shared: { get_param: Internal1_shared } + external: { get_param: [my_instance, networks, private, 0] } +# route_targets: { "Fn::Split" : [ ",", Ref: route_targets ] } + testConvertGetAttributeFunctions: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: Internal1_net_name } + forwarding_mode: { get_param: Internal1_forwarding_mode } + shared: { get_param: Internal1_shared } + external: { get_param: Internal1_external } +# route_targets: { "Fn::Split" : [ ",", Ref: route_targets ] } + + Internal1-subnet: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: Internal1-net } + cidr: { get_param: Internal1_cidr } + gateway_ip: { get_param: Internal1_default_gateway } + enable_dhcp: { get_param: Internal1_dhcp } + + Internal3-subnet: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: Internal1-net } + cidr: { get_param: Internal2_cidr } + gateway_ip: { get_param: Internal2_default_gateway } + enable_dhcp: { get_param: Internal2_dhcp } + + Internal4-subnet: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: Internal1-net } + cidr: { get_param: Internal1_cidr } + gateway_ip: { get_param: Internal1_default_gateway } + enable_dhcp: off + +# Internal1-subnet: +# type: OS::Contrail::VnSubnet +# properties: +# name: { get_param: Internal1_subnet_name } +# network: { get_resource: Internal1-net } +# ip_prefix: { get_param: Internal1_cidr } + # ipam: { get_resource: Internal1_ipam } + # enable_dhcp: { get_param: Internal1_dhcp } + # default_gateway: { get_param: Internal1_default_gateway } + # allocation_pools: + # - start: { get_param: Internal1_net_pool_start } + # end: { get_param: Internal1_net_pool_end } + + + + Internal2-net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: Internal2_name } + forwarding_mode: { get_param: Internal2_forwarding_mode } + shared: { get_param: Internal2_shared } + external: { get_param: Internal2_external } +# route_targets: { "Fn::Split" : [ ",", Ref: route_targets ] } + +# Internal2-subnet: +# type: OS::Contrail::VnSubnet +# properties: +# name: { get_param: Internal2_subnet_name } +# network: { get_resource: Internal2-net } +# ip_prefix: { get_param: Internal2_cidr } +# ipam: { get_resource: Internal2_ipam } +# enable_dhcp: { get_param: Internal2_dhcp } +# default_gateway: { get_param: Internal2_default_gateway } +# allocation_pools: +# - start: { get_param: Internal2_net_pool_start } +# end: { get_param: Internal2_net_pool_end } + + Internal2-subnet: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: Internal2-net } + cidr: { get_param: Internal2_cidr } + gateway_ip: { get_param: Internal2_default_gateway } + enable_dhcp: { get_param: Internal2_dhcp } + + epc-sctp-a-net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: epc-sctp-a-net-name } + route_targets: [ get_param: epc-sctp-a-net-rt ] + + + epc-sctp-a-subnet: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: epc-sctp-a-net } + cidr: { get_param: epc-sctp-a-net-cidr } + gateway_ip: { get_param: epc-sctp-a-net-gateway } + allocation_pools: + - start: { get_param: epc-sctp-a-pool-start } + end: { get_param: epc-sctp-a-pool-end } + + epc-sctp-b-net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: epc-sctp-b-net-name } + route_targets: [ get_param: epc-sctp-b-net-rt ] + + epc-sctp-b-subnet: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: epc-sctp-b-net } + cidr: { get_param: epc-sctp-b-net-cidr } + gateway_ip: { get_param: epc-sctp-b-net-gateway } + allocation_pools: + - start: { get_param: epc-sctp-b-pool-start } + end: { get_param: epc-sctp-b-pool-end } + + epc-gtp-net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: epc-gtp-net-name } + route_targets: [ get_param: epc-gtp-net-rt ] + + epc-gtp-subnet: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: epc-gtp-net } + cidr: { get_param: epc-gtp-net-cidr } + gateway_ip: { get_param: epc-gtp-net-gateway } + allocation_pools: + - start: { get_param: epc-gtp-pool-start } + end: { get_param: epc-gtp-pool-end } + + FSB1: + type: OS::Nova::Server + properties: + name: { get_param: fsb1-name } + block_device_mapping: [{device_name: "vda", volume_id : {get_param: VMME_FSB1_boot_volume }, delete_on_termination: "false" }] + flavor: { get_param: fsb1-flavor } + availability_zone: { get_param: fsb_zone } + networks: + - port: { get_resource: FSB1_Internal1 } + - port: { get_resource: FSB1_Internal2 } + - port: { get_resource: FSB1_OAM } + + FSB1_Internal1: + type: OS::Neutron::Port + properties: + network: { get_resource: Internal1-net } + mac_address: { get_param: fsb1-Internal1-mac } + + FSB1_Internal2: + type: OS::Neutron::Port + properties: + network: { get_resource: Internal2-net } + mac_address: { get_param: fsb1-Internal2-mac } + + FSB1_OAM: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_id } + fixed_ips: + - ip_address: { get_param: fsb1-oam-ip } + + FSB2: + type: OS::Nova::Server + properties: + name: { get_param: fsb2-name } + block_device_mapping: [{device_name: "vda", volume_id : {get_param: VMME_FSB2_boot_volume }, delete_on_termination: "false" }] + flavor: { get_param: fsb2-flavor } + availability_zone: { get_param: fsb_zone } + networks: + - port: { get_resource: FSB2_Internal1 } + - port: { get_resource: FSB2_Internal2 } + - port: { get_resource: FSB2_OAM } + + FSB2_Internal1: + type: OS::Neutron::Port + properties: + network: { get_resource: Internal1-net } + mac_address: { get_param: fsb2-Internal1-mac } + + + FSB2_Internal2: + type: OS::Neutron::Port + properties: + network: { get_resource: Internal2-net } + mac_address: { get_param: fsb2-Internal2-mac } + + FSB2_OAM: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_id } + fixed_ips: + - ip_address: { get_param: fsb2-oam-ip } + + NCB1: + type: OS::Nova::Server + properties: + name: { get_param: ncb1-name } + image: { get_param: pxe-image } + flavor: { get_param: ncb-flavor } + availability_zone: { get_param: ncb_zone } + networks: + - port: { get_resource: NCB1_Internal1 } + - port: { get_resource: NCB1_Internal2 } + + NCB1_Internal1: + type: OS::Neutron::Port + properties: + network: { get_resource: Internal1-net } + mac_address: { get_param: ncb1-Internal1-mac } + + NCB1_Internal2: + type: OS::Neutron::Port + properties: + network: { get_resource: Internal2-net } + mac_address: { get_param: ncb1-Internal2-mac } + + NCB2: + type: OS::Nova::Server + properties: + name: { get_param: ncb2-name } + image: { get_param: pxe-image } + flavor: { get_param: ncb-flavor } + availability_zone: { get_param: ncb_zone } + networks: + - port: { get_resource: NCB2_Internal1 } + - port: { get_resource: NCB2_Internal2 } + + NCB2_Internal1: + type: OS::Neutron::Port + properties: + network: { get_resource: Internal1-net } + mac_address: { get_param: ncb2-Internal1-mac } + + NCB2_Internal2: + type: OS::Neutron::Port + properties: + network: { get_resource: Internal2-net } + mac_address: { get_param: ncb2-Internal2-mac } + + GPB1: + type: OS::Nova::Server + properties: + name: { get_param: gpb1-name } + image: { get_param: pxe-image } + flavor: { get_param: gpb-flavor } + availability_zone: { get_param: gpb_zone } + networks: + - port: { get_resource: GPB1_Internal1 } + - port: { get_resource: GPB1_Internal2 } + + GPB1_Internal1: + type: OS::Neutron::Port + properties: + network: { get_resource: Internal1-net } + mac_address: { get_param: gpb1-Internal1-mac } + + GPB1_Internal2: + type: OS::Neutron::Port + properties: + network: { get_resource: Internal2-net } + mac_address: { get_param: gpb1-Internal2-mac } + + GPB2: + type: OS::Nova::Server + properties: + name: { get_param: gpb2-name } + image: { get_param: pxe-image } + flavor: { get_param: gpb-flavor } + availability_zone: { get_param: gpb_zone } + networks: + - port: { get_resource: GPB2_Internal1 } + - port: { get_resource: GPB2_Internal2 } + + GPB2_Internal1: + type: OS::Neutron::Port + properties: + network: { get_resource: Internal1-net } + mac_address: { get_param: gpb2-Internal1-mac } + + GPB2_Internal2: + type: OS::Neutron::Port + properties: + network: { get_resource: Internal2-net } + mac_address: { get_param: gpb2-Internal2-mac } + + VLC1: + type: OS::Nova::Server + properties: + name: { get_param: vlc1-name } + image: { get_param: pxe-image } + flavor: { get_param: vlc-flavor } + availability_zone: { get_param: vlc_zone } + networks: + - port: { get_resource: VLC1_Internal1 } + - port: { get_resource: VLC1_Internal2 } + - port: { get_resource: VLC1_OAM } + - port: { get_resource: VLC1_SCTP_A } + - port: { get_resource: VLC1_SCTP_B } + - port: { get_resource: VLC1_GTP } + + VLC1_Internal1: + type: OS::Neutron::Port + properties: + network: { get_resource: Internal1-net } + mac_address: { get_param: vlc1-Internal1-mac } + + VLC1_Internal2: + type: OS::Neutron::Port + properties: + network: { get_resource: Internal2-net } + mac_address: { get_param: vlc1-Internal2-mac } + + VLC1_OAM: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_id } + fixed_ips: + - ip_address: { get_param: vlc1-oam-ip } + + VLC1_SCTP_A: + type: OS::Neutron::Port + properties: + network: { get_resource: epc-sctp-a-net } + fixed_ips: + - ip_address: { get_param: vlc1-sctp-a-ip } + + VLC1_SCTP_B: + type: OS::Neutron::Port + properties: + network: { get_resource: epc-sctp-b-net } + fixed_ips: + - ip_address: { get_param: vlc1-sctp-b-ip } + + VLC1_GTP: + type: OS::Neutron::Port + properties: + network: { get_resource: epc-gtp-net } + fixed_ips: + - ip_address: { get_param: vlc1-gtp-ip } + + VLC2: + type: OS::Nova::Server + properties: + name: { get_param: vlc2-name } + image: { get_param: pxe-image } + flavor: { get_param: vlc-flavor } + availability_zone: { get_param: vlc_zone } + networks: + - port: { get_resource: VLC2_Internal1 } + - port: { get_resource: VLC2_Internal2 } + - port: { get_resource: VLC2_OAM } + - port: { get_resource: VLC2_SCTP_A } + - port: { get_resource: VLC2_SCTP_B } + - port: { get_resource: VLC2_GTP } + + + VLC2_Internal1: + type: OS::Neutron::Port + properties: + network: { get_resource: Internal1-net } + mac_address: { get_param: vlc2-Internal1-mac } + + VLC2_OAM: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_id } + fixed_ips: + - ip_address: { get_param: vlc2-oam-ip } + + VLC2_Internal2: + type: OS::Neutron::Port + properties: + network: { get_resource: Internal2-net } + mac_address: { get_param: vlc2-Internal2-mac } + + VLC2_SCTP_A: + type: OS::Neutron::Port + properties: + network: { get_resource: epc-sctp-a-net } + fixed_ips: + - ip_address: { get_param: vlc2-sctp-a-ip } + + VLC2_SCTP_B: + type: OS::Neutron::Port + properties: + network: { get_resource: epc-sctp-b-net } + fixed_ips: + - ip_address: { get_param: vlc2-sctp-b-ip } + + VLC2_GTP: + type: OS::Neutron::Port + properties: + network: { get_resource: epc-gtp-net } + fixed_ips: + - ip_address: { get_param: vlc2-gtp-ip } + + Test-empty-network-in-subnet: + type: OS::Neutron::Subnet + properties: + network_id: { get_param: Internal1-net } + cidr: { get_param: Internal1_cidr } + gateway_ip: { get_param: Internal1_default_gateway } + enable_dhcp: { get_param: Internal1_dhcp } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Neutron_Net/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Neutron_Net/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..c93363e850 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Neutron_Net/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,219 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + param_number: + hidden: false + immutable: false + type: float + description: param number - float + jsa_cidr: + hidden: false + immutable: false + type: string + description: CIDR of jsa log network + default: 107.243.7.128/26 + param_string: + hidden: false + immutable: false + type: string + description: param String - string + param_json: + hidden: false + immutable: false + type: json + description: param json - map + param_comma_delimited_list: + hidden: false + immutable: false + type: list + description: param comma_delimited_list - List + entry_schema: + type: string + user_name: + label: User Name + hidden: true + immutable: false + type: string + description: User name to be configured for the application + constraints: + - max_length: 8 + - min_length: 6 + - pattern: '[A-Z]+[a-zA-Z0-9]*' + - in_range: + - 0 + - 10 + param_boolean: + hidden: false + immutable: false + type: boolean + description: param boolean - boolean + instance_type: + label: Instance Type + hidden: false + immutable: false + type: string + description: Instance type for compute instances + constraints: + - valid_values: + - m1.small + - m1.medium + - m1.large + jsa_net_name: + hidden: false + immutable: false + type: string + description: network name of jsa log network + default: jsa_log_net_0 + node_templates: + jsa_net: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + shared: true + network_name: + get_input: jsa_net_name + subnets: + jsa_subnet: + cidr: + get_input: jsa_cidr + jsa_net_test_get_attribute_2_params: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + dhcp_agent_ids: + - '1000' + - '1001' + - '1002' + tenant_id: 23456 + port_security_enabled: true + shared: true + admin_state_up: false + qos_policy: full + network_name: + get_attribute: + - jsa_net + - network_name + value_specs: + key1: spec1 + jsa_net_test_get_attribute_3_params: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + dhcp_agent_ids: + - '1000' + - '1001' + - '1002' + tenant_id: 23456 + port_security_enabled: true + shared: true + admin_state_up: false + qos_policy: full + network_name: + get_attribute: + - jsa_net + - network_name + - 0 + value_specs: + key1: spec1 + jsa_net_test_get_attribute_4_params: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + dhcp_agent_ids: + - '1000' + - '1001' + - '1002' + tenant_id: 23456 + port_security_enabled: true + shared: true + admin_state_up: false + qos_policy: full + network_name: + get_attribute: + - jsa_net + - network_name + - 0 + - a1 + value_specs: + key1: spec1 + jsa_net_test_get_attribute_5_params: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + dhcp_agent_ids: + - '1000' + - '1001' + - '1002' + tenant_id: 23456 + port_security_enabled: true + shared: true + admin_state_up: false + qos_policy: full + network_name: + get_attribute: + - jsa_net + - network_name + - 0 + - a1 + - a2 + value_specs: + key1: spec1 + jsa_net_test_full_attribute: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + dhcp_agent_ids: + - '1000' + - '1001' + - '1002' + tenant_id: 23456 + port_security_enabled: true + shared: true + admin_state_up: false + qos_policy: full + network_name: + get_input: jsa_net_name + subnets: + jsa_net_test_full_attribute_subnet: + cidr: + get_input: jsa_cidr + value_specs: + key1: spec1 + key2: spec2 + groups: + ep-jsa_net: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/ep-jsa_net.yaml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - jsa_net + - jsa_net_test_get_attribute_2_params + - jsa_net_test_get_attribute_3_params + - jsa_net_test_get_attribute_4_params + - jsa_net_test_get_attribute_5_params + - jsa_net_test_full_attribute \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Neutron_Net/inputs/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Neutron_Net/inputs/MANIFEST.json new file mode 100644 index 0000000000..0d0f2bd7cf --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Neutron_Net/inputs/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "vEP_JSA_Net", + "description": "Version 2.0 02-09-2016 (Authors: John Doe, user PROD)", + "version": "2013-05-23", + "data": [ + { + "file": "ep-jsa_net.yaml", + "type": "HEAT", + "data": [ + { + "file": "ep-jsa_net.env", + "type": "HEAT_ENV" + } + ] + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Neutron_Net/inputs/ep-jsa_net.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Neutron_Net/inputs/ep-jsa_net.env new file mode 100644 index 0000000000..9dd1cd441f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Neutron_Net/inputs/ep-jsa_net.env @@ -0,0 +1,4 @@ +parameters: + jsa_net_name: jsa_log_net_0 + jsa_cidr: 107.243.7.128/26 + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Neutron_Net/inputs/ep-jsa_net.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Neutron_Net/inputs/ep-jsa_net.yaml new file mode 100644 index 0000000000..3c5b00dc48 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Neutron_Net/inputs/ep-jsa_net.yaml @@ -0,0 +1,135 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + param_string: + type: string + description: param String - string + param_number: + type: number + description: param number - float + param_json: + type: json + description: param json - map + param_boolean: + type: boolean + description: param boolean - boolean + param_comma_delimited_list: + type: comma_delimited_list + description: param comma_delimited_list - List + + jsa_net_name: + type: string + description: network name of jsa log network + jsa_cidr: + type: string + description: CIDR of jsa log network + user_name: + type: string + label: User Name + description: User name to be configured for the application + hidden: true + constraints: + - length: { min: 6, max: 8 } + description: User name must be between 6 and 8 characters + - allowed_pattern: "[A-Z]+[a-zA-Z0-9]*" + description: User name must start with an uppercase character + - range: { min: 0, max: 10 } + instance_type: + type: string + label: Instance Type + description: Instance type for compute instances + constraints: + - allowed_values: + - m1.small + - m1.medium + - m1.large + +resources: + jsa_subnet: + type: OS::Neutron::Subnet + properties: + network_id: {get_resource: jsa_net} + cidr: {get_param: jsa_cidr} + + jsa_net: + type: OS::Neutron::Net + properties: + name: {get_param: jsa_net_name} + shared: True + + jsa_net_test_full_attribute: + type: OS::Neutron::Net + properties: + name: {get_param: jsa_net_name} + shared: True + dhcp_agent_ids: ['1000','1001','1002'] + tenant_id: 23456 + port_security_enabled: t + admin_state_up: 0 + qos_policy: full + value_specs: + key1: "spec1" + key2: "spec2" + + jsa_net_test_full_attribute_subnet: + type: OS::Neutron::Subnet + properties: + network_id: {get_resource: jsa_net_test_full_attribute} + cidr: {get_param: jsa_cidr} + + jsa_net_test_get_attribute_2_params: + type: OS::Neutron::Net + properties: + name: {get_attr: [jsa_net, name]} + shared: True + dhcp_agent_ids: ['1000','1001','1002'] + tenant_id: 23456 + port_security_enabled: t + admin_state_up: 0 + qos_policy: full + value_specs: + key1: "spec1" + + jsa_net_test_get_attribute_3_params: + type: OS::Neutron::Net + properties: + name: {get_attr: [jsa_net, name, 0]} + shared: True + dhcp_agent_ids: ['1000','1001','1002'] + tenant_id: 23456 + port_security_enabled: t + admin_state_up: 0 + qos_policy: full + value_specs: + key1: "spec1" + + jsa_net_test_get_attribute_4_params: + type: OS::Neutron::Net + properties: + name: {get_attr: [jsa_net, name, 0,a1]} + shared: True + dhcp_agent_ids: ['1000','1001','1002'] + tenant_id: 23456 + port_security_enabled: t + admin_state_up: 0 + qos_policy: full + value_specs: + key1: "spec1" + + jsa_net_test_get_attribute_5_params: + type: OS::Neutron::Net + properties: + name: {get_attr: [jsa_net, name, 0, a1, a2]} + shared: True + dhcp_agent_ids: ['1000','1001','1002'] + tenant_id: 23456 + port_security_enabled: t + admin_state_up: 0 + qos_policy: full + value_specs: + key1: "spec1" + + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Nova_Server/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Nova_Server/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..4eacd2f60a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Nova_Server/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,602 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.FSB2: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.FSB1: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.pcm_server: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.pcrf_psm_server: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + Internal2_name: + label: Internal2_name + hidden: false + immutable: false + type: string + description: Internal2_name + Internal1_shared: + label: Internal1_shared + hidden: false + immutable: false + type: string + description: Internal1_shared + FSB1_volume_name: + label: FSB1_volume + hidden: false + immutable: false + type: string + description: FSB1_volume_1 + jsa_cidr: + label: jsa_cidr + hidden: false + immutable: false + type: string + description: jsa_cidr + default: 107.243.7.128/26 + availabilityzone_name: + label: availabilityzone_name + hidden: false + immutable: false + type: string + description: availabilityzone_name + fsb1-name: + label: FSB1_name + hidden: false + immutable: false + type: string + description: FSB1_name + pcm_image_name: + label: pcm_image_name + hidden: false + immutable: false + type: string + description: pcm_image_name + Internal2_external: + label: Internal2_external + hidden: false + immutable: false + type: string + description: Internal2_external + Internal2_forwarding_mode: + label: Internal2_forwarding_mode + hidden: false + immutable: false + type: string + description: Internal2_forwarding_mode + pcrf_psm_flavor_name: + label: pcrf_psm_flavor_name + hidden: false + immutable: false + type: string + description: pcrf_psm_flavor_name + pcrf_psm_image_name: + label: pcrf_psm_image_name + hidden: false + immutable: false + type: string + description: pcrf_psm_image_name + pcrf_vnf_id: + hidden: false + immutable: false + type: string + description: prop + FSB_1_image: + label: MME_FSB1 + hidden: false + immutable: false + type: string + description: MME_FSB1_15B-CP04-r5a01 + snapshot01: + hidden: false + immutable: false + type: string + description: prop + volume_size: + label: volume size + hidden: false + immutable: false + type: float + description: my volume size 320GB + snapshot02: + hidden: false + immutable: false + type: string + description: prop + fsb1-Internal1-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + Internal2_shared: + label: Internal2_shared + hidden: false + immutable: false + type: string + description: Internal2_shared + pcm_server_name: + label: pcm_server_name + hidden: false + immutable: false + type: string + description: pcm_server_name + cps_net_mask: + hidden: false + immutable: false + type: string + description: prop + Internal1_net_name: + label: Internal1_net_name + hidden: false + immutable: false + type: string + description: Internal1_net_name + oam_net_name: + label: oam_net_name + hidden: false + immutable: false + type: string + description: oam_net_name + fsb1-flavor: + label: FSB1_flavor + hidden: false + immutable: false + type: string + description: FSB1_flavor + fsb1-Internal2-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + pcm_vol_01: + hidden: false + immutable: false + type: string + description: prop + volume_type: + label: volume type + hidden: false + immutable: false + type: string + description: volume type Gold + fsb1-zone: + label: FSB1_zone + hidden: false + immutable: false + type: string + description: FSB1_zone + fsb_zone: + label: FSB1_zone + hidden: false + immutable: false + type: string + description: FSB1_zone + oam_net_gw: + hidden: false + immutable: false + type: string + description: prop + VMME_FSB1_boot_volume: + hidden: false + immutable: false + type: string + network_name: + hidden: false + immutable: false + type: string + description: prop + security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + cps_net_ip: + hidden: false + immutable: false + type: string + description: prop + jsa_net_name: + label: jsa_net_name + hidden: false + immutable: false + type: string + description: jsa_net_name + default: jsa_log_net_0 + pcrf_psm_server_name: + label: pcrf_psm_server_name + hidden: false + immutable: false + type: string + description: pcrf_psm_server_name + pcm_flavor_name: + label: pcm_flavor_name + hidden: false + immutable: false + type: string + description: pcm_flavor_name + oam_net_id: + label: oam_net_id + hidden: false + immutable: false + type: string + description: oam_net_id + pcrf_cps_net_ip: + hidden: false + immutable: false + type: string + description: prop + fsb2-Internal1-mac: + label: FSB1_internal_mac + hidden: false + immutable: false + type: string + description: FSB1_internal_mac + Internal1_forwarding_mode: + label: Internal1_forwarding_mode + hidden: false + immutable: false + type: string + description: Internal1_forwarding_mode + pcrf_cps_net_name: + label: pcrf_cps_net_name + hidden: false + immutable: false + type: string + description: pcrf_cps_net_name + pcm_vol: + hidden: false + immutable: false + type: string + description: prop + cps_net_name: + label: cps_net_name + hidden: false + immutable: false + type: string + description: cps_net_name + oam_net_ip: + hidden: false + immutable: false + type: string + description: prop + oam_net_mask: + hidden: false + immutable: false + type: string + description: prop + fsb1-oam-ip: + hidden: false + immutable: false + type: string + description: prop + pcrf_security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + Internal1_external: + label: Internal1_external + hidden: false + immutable: false + type: string + description: Internal1_external + node_templates: + pcm_vol_02: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + image: + get_input: FSB_1_image + volume_type: + get_input: volume_type + size: '(get_input : volume_size) * 1024' + read_only: true + name: + get_input: FSB1_volume_name + Internal2-net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + shared: + get_input: Internal2_shared + forwarding_mode: + get_input: Internal2_forwarding_mode + external: + get_input: Internal2_external + network_name: + get_input: Internal2_name + pcm_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: oam_net_ip + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_pcm + relationship: tosca.relationships.network.BindsTo + server_VolumeTest_snapshot02: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + snapshot_id: + get_input: snapshot02 + FSB1_Internal2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: fsb1-Internal2-mac + network: Internal2-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal2-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: FSB1 + relationship: tosca.relationships.network.BindsTo + server_VolumeTest_snapshot01: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + snapshot_id: + get_input: snapshot01 + FSB1_Internal1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: fsb1-Internal1-mac + network: Internal1-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal1-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: FSB1 + relationship: tosca.relationships.network.BindsTo + FSB1_OAM: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + fixed_ips: + - ip_address: + get_input: fsb1-oam-ip + network: + get_input: oam_net_id + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: FSB1 + relationship: tosca.relationships.network.BindsTo + psm01_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: pcrf_security_group_name + fixed_ips: + - ip_address: + get_input: pcrf_cps_net_ip + network: + get_input: pcrf_cps_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: pcrf_server_psm + relationship: tosca.relationships.network.BindsTo + pcm_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: cps_net_ip + network: + get_input: cps_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_pcm + relationship: tosca.relationships.network.BindsTo + network: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + network_name: + get_input: Internal1_net_name + server_pcm: + type: org.openecomp.resource.vfc.nodes.heat.pcm_server + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + Internal1-net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + shared: + get_input: Internal1_shared + forwarding_mode: + get_input: Internal1_forwarding_mode + external: + get_input: Internal1_external + network_name: + get_input: Internal1_net_name + pcrf_server_psm: + type: org.openecomp.resource.vfc.nodes.heat.pcrf_psm_server + properties: + flavor: + get_input: pcrf_psm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcrf_psm_image_name + config_drive: 'True' + metadata: + vnf_id: + get_input: pcrf_vnf_id + user_data_format: RAW + name: + get_input: pcrf_psm_server_name + server_VolumeTest: + type: org.openecomp.resource.vfc.nodes.heat.pcm_server + properties: + flavor: + get_input: pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcm_image_name + config_drive: 'True' + user_data_format: RAW + name: + get_input: pcm_server_name + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: pcm_vol_02 + relationship: tosca.relationships.AttachesTo + - local_storage: + capability: tosca.capabilities.Attachment + node: server_VolumeTest_snapshot01 + relationship: server_VolumeTest_4 + - local_storage: + capability: tosca.capabilities.Attachment + node: server_VolumeTest_snapshot02 + relationship: server_VolumeTest_5 + FSB2: + type: org.openecomp.resource.vfc.nodes.heat.FSB2 + properties: + flavor: + get_input: fsb1-flavor + availability_zone: + get_input: fsb_zone + name: + get_input: fsb1-name + FSB1: + type: org.openecomp.resource.vfc.nodes.heat.FSB1 + properties: + flavor: + get_input: fsb1-flavor + availability_zone: + get_input: fsb_zone + metadata: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: '0644' + content: + str_replace: + template: + get_artifact: + - SELF + - nimbus-ethernet + params: + $dev: eth0 + $netmask: + get_input: cps_net_mask + $ip: + get_input: cps_net_ip + - path: /etc/sysconfig/network-scripts/ifcfg-eth1 + permissions: '0644' + content: + str_replace: + template: + get_artifact: + - SELF + - nimbus-ethernet-gw + params: + $dev: eth1 + $netmask: + get_input: oam_net_mask + $gateway: + get_input: oam_net_gw + $ip: + get_input: oam_net_ip + name: + get_input: fsb1-name + artifacts: + nimbus-ethernet-gw: + type: tosca.artifacts.Deployment + file: ../Artifacts/nimbus-ethernet-gw + nimbus-ethernet: + type: tosca.artifacts.Deployment + file: ../Artifacts/nimbus-ethernet + relationship_templates: + server_VolumeTest_4: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: server_VolumeTest_snapshot01 + instance_uuid: server_VolumeTest + device: vdb + server_VolumeTest_5: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: server_VolumeTest_snapshot02 + instance_uuid: server_VolumeTest + groups: + ep-jsa_net: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/ep-jsa_net.yaml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - pcm_vol_02 + - Internal2-net + - pcm_port_1 + - FSB1_Internal2 + - FSB1_Internal1 + - FSB1_OAM + - psm01_port_0 + - pcm_port_0 + - network + - server_pcm + - Internal1-net + - pcrf_server_psm + - server_VolumeTest + - FSB2 + - FSB1 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Nova_Server/inputs/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Nova_Server/inputs/MANIFEST.json new file mode 100644 index 0000000000..cd0c5e8803 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Nova_Server/inputs/MANIFEST.json @@ -0,0 +1,25 @@ +{ + "name": "vEP_JSA_Net", + "description": "Version 2.0 02-09-2016 (Authors: John Doe, user PROD)", + "version": "2013-05-23", + "data": [ + { + "file": "ep-jsa_net.yaml", + "type": "HEAT", + "data": [ + { + "file": "ep-jsa_net.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "nimbus-ethernet", + "type": "OTHER" + }, + { + "file": "nimbus-ethernet-gw", + "type": "OTHER" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Nova_Server/inputs/ep-jsa_net.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Nova_Server/inputs/ep-jsa_net.env new file mode 100644 index 0000000000..9dd1cd441f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Nova_Server/inputs/ep-jsa_net.env @@ -0,0 +1,4 @@ +parameters: + jsa_net_name: jsa_log_net_0 + jsa_cidr: 107.243.7.128/26 + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Nova_Server/inputs/ep-jsa_net.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Nova_Server/inputs/ep-jsa_net.yaml new file mode 100644 index 0000000000..3e6d1ec2e4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Nova_Server/inputs/ep-jsa_net.yaml @@ -0,0 +1,411 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + security_group_name: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + pcrf_security_group_name: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + volume_type: + type: string + label: volume type + description: volume type Gold + + volume_size: + type: number + label: volume size + description: my volume size 320GB + + FSB_1_image: + type: string + label: MME_FSB1 + description: MME_FSB1_15B-CP04-r5a01 + + FSB1_volume_name: + type: string + label: FSB1_volume + description: FSB1_volume_1 + + fsb1-name: + type: string + label: FSB1_name + description: FSB1_name + + fsb1-flavor: + type: string + label: FSB1_flavor + description: FSB1_flavor + + fsb1-zone: + type: string + label: FSB1_zone + description: FSB1_zone + + fsb_zone: + type: string + label: FSB1_zone + description: FSB1_zone + + fsb1-Internal1-mac: + type: string + label: FSB1_internal_mac + description: FSB1_internal_mac + + fsb1-Internal2-mac: + type: string + label: FSB1_internal_mac + description: FSB1_internal_mac + + fsb2-Internal1-mac: + type: string + label: FSB1_internal_mac + description: FSB1_internal_mac + + oam_net_id: + type: string + label: oam_net_id + description: oam_net_id + + jsa_net_name: + type: string + label: jsa_net_name + description: jsa_net_name + + jsa_cidr: + type: string + label: jsa_cidr + description: jsa_cidr + + pcrf_cps_net_name: + type: string + label: pcrf_cps_net_name + description: pcrf_cps_net_name + + pcrf_psm_server_name: + type: string + label: pcrf_psm_server_name + description: pcrf_psm_server_name + + pcrf_psm_image_name: + type: string + label: pcrf_psm_image_name + description: pcrf_psm_image_name + + pcrf_psm_flavor_name: + type: string + label: pcrf_psm_flavor_name + description: pcrf_psm_flavor_name + + availabilityzone_name: + type: string + label: availabilityzone_name + description: availabilityzone_name + + pcm_server_name: + type: string + label: pcm_server_name + description: pcm_server_name + + pcm_image_name: + type: string + label: pcm_image_name + description: pcm_image_name + + pcm_flavor_name: + type: string + label: pcm_flavor_name + description: pcm_flavor_name + + Internal1_net_name: + type: string + label: Internal1_net_name + description: Internal1_net_name + + Internal1_forwarding_mode: + type: string + label: Internal1_forwarding_mode + description: Internal1_forwarding_mode + + Internal1_shared: + type: string + label: Internal1_shared + description: Internal1_shared + + Internal1_external: + type: string + label: Internal1_external + description: Internal1_external + + Internal2_name: + type: string + label: Internal2_name + description: Internal2_name + + Internal2_shared: + type: string + label: Internal2_shared + description: Internal2_shared + + Internal2_external: + type: string + label: Internal2_external + description: Internal2_external + + Internal2_forwarding_mode: + type: string + label: Internal2_forwarding_mode + description: Internal2_forwarding_mode + + cps_net_name: + type: string + label: cps_net_name + description: cps_net_name + + oam_net_name: + type: string + label: oam_net_name + description: oam_net_name + oam_net_gw: + type: string + description: prop + cps_net_ip: + type: string + description: prop + cps_net_mask: + type: string + description: prop + oam_net_ip: + type: string + description: prop + oam_net_mask: + type: string + description: prop + fsb1-oam-ip: + type: string + description: prop + pcrf_cps_net_ip: + type: string + description: prop + pcrf_vnf_id: + type: string + description: prop + pcm_vol: + type: string + description: prop + pcm_vol_01: + type: string + description: prop + snapshot01: + type: string + description: prop + snapshot02: + type: string + description: prop + VMME_FSB1_boot_volume: + type: string + network_name: + type: string + description: prop + + +resources: + FSB1: + type: OS::Nova::Server + depends_on: script_init + properties: + name: { get_param: fsb1-name } + block_device_mapping: [{device_name: "vda", volume_id : {get_param: VMME_FSB1_boot_volume }, delete_on_termination: "false" }] + flavor: { get_param: fsb1-flavor } + availability_zone: { get_param: fsb_zone } + networks: + - port: { get_resource: FSB1_Internal1 } + fixed_ip: 10.0.0.0 + floating_ip: 10.0.0.1 + network: 100_1000_0011 + port_extra_properties: {admin_state_up: true , allowed_address_pairs: 10} + subnet: 10.0.0.2 + - port: { get_resource: FSB1_Internal2 } + - port: { get_resource: FSB1_OAM } + metadata: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + template: { get_file: "file:///nimbus-ethernet" } + params: + $dev: eth0 + $ip: { get_param: cps_net_ip } + $netmask: { get_param: cps_net_mask } + - path: /etc/sysconfig/network-scripts/ifcfg-eth1 + permissions: "0644" + content: + str_replace: + template: { get_file: "file:///nimbus-ethernet-gw" } + params: + $dev: eth1 + $ip: { get_param: oam_net_ip } + $netmask: { get_param: oam_net_mask } + $gateway: { get_param: oam_net_gw } + + + FSB1_Internal1: + type: OS::Neutron::Port + properties: + network_id: { get_resource: Internal1-net } + mac_address: { get_param: fsb1-Internal1-mac } + + FSB1_Internal2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: Internal2-net } + mac_address: { get_param: fsb1-Internal2-mac } + + FSB1_OAM: + type: OS::Neutron::Port + properties: + network_id: { get_param: oam_net_id } + fixed_ips: + - ip_address: { get_param: fsb1-oam-ip } + + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + psm01_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] + + pcrf_server_psm: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_psm_server_name } + image: { get_param: pcrf_psm_image_name } + flavor: { get_param: pcrf_psm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: psm01_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + server_pcm: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcm_server_name } + image: { get_param: pcm_image_name } + flavor: { get_param: pcm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcm_port_0} + - port: { get_resource: pcm_port_1} + block_device_mapping: + - device_name: vdb + volume_id: { get_param: pcm_vol} + user_data_format: RAW + user_data: + get_resource: server_init + server_VolumeTest: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcm_server_name } + image: { get_param: pcm_image_name } + flavor: { get_param: pcm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + block_device_mapping: + - device_name: vdb + - device_name: vdb + volume_id: { get_param: pcm_vol} + - device_name: vdb + volume_id: { get_param: pcm_vol_01} + - device_name: vdb + volume_id: { get_resource: pcm_vol_02} + - device_name: vdb + snapshot_id: { get_param: snapshot01} + - snapshot_id: { get_param: snapshot02} + user_data_format: RAW + user_data: + get_resource: server_init + server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + script_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + + network: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: Internal1_net_name } + + pcm_vol_02: + type: OS::Cinder::Volume + properties: + size: {get_param: volume_size} + volume_type: {get_param: volume_type} + name: {get_param: FSB1_volume_name} + image: {get_param: FSB_1_image} + read_only: 1 + + pcm_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: cps_net_name } + fixed_ips: + - ip_address: { get_param: cps_net_ip } + security_groups: [{ get_param: security_group_name }] + + pcm_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: + - ip_address: { get_param: oam_net_ip } + security_groups: [{ get_param: security_group_name }] + + Internal1-net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: Internal1_net_name } + forwarding_mode: { get_param: Internal1_forwarding_mode } + shared: { get_param: Internal1_shared } + external: { get_param: Internal1_external } +# route_targets: { "Fn::Split" : [ ",", Ref: route_targets ] } + + Internal2-net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: Internal2_name } + forwarding_mode: { get_param: Internal2_forwarding_mode } + shared: { get_param: Internal2_shared } + external: { get_param: Internal2_external } +# route_targets: { "Fn::Split" : [ ",", Ref: route_targets ] } + + FSB2: + type: OS::Nova::Server + properties: + name: { get_param: fsb1-name } + flavor: { get_param: fsb1-flavor } + availability_zone: { get_param: fsb_zone } + networks: + - network: {get_param: network_name} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Nova_Server/inputs/nimbus-ethernet b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Nova_Server/inputs/nimbus-ethernet new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Nova_Server/inputs/nimbus-ethernet-gw b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/resources/OS_Nova_Server/inputs/nimbus-ethernet-gw new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/sharedresources/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/sharedresources/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..6d35846244 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/sharedresources/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,95 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.server_pcm_002: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.server_pcm_001: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + fsb1-flavor: + label: FSB1_flavor + hidden: false + immutable: false + type: string + description: FSB1_flavor + fsb_zone: + label: FSB1_zone + hidden: false + immutable: false + type: string + description: FSB1_zone + fsb1-name: + label: FSB1_name + hidden: false + immutable: false + type: string + description: FSB1_name + FSB_1_image: + label: MME_FSB1 + hidden: false + immutable: false + type: string + description: MME_FSB1_15B-CP04-r5a01 + node_templates: + server_pcm_002: + type: org.openecomp.resource.vfc.nodes.heat.server_pcm_002 + properties: + flavor: + get_input: fsb1-flavor + availability_zone: + get_input: fsb_zone + name: + get_input: fsb1-name + server_pcm_001: + type: org.openecomp.resource.vfc.nodes.heat.server_pcm_001 + properties: + flavor: + get_input: fsb1-flavor + availability_zone: + get_input: fsb_zone + name: + get_input: fsb1-name + groups: + sharedDefinitionOutParam: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/sharedDefinitionOutParam.yaml + description: heat template that creates PCRF Cluman stack + members: + - server_pcm_002 + - server_pcm_001 + outputs: + out_id2: + value: static value + out_id1: + value: + get_input: oam_net_gw \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/sharedresources/inputs/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/sharedresources/inputs/MANIFEST.json new file mode 100644 index 0000000000..786c357838 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/sharedresources/inputs/MANIFEST.json @@ -0,0 +1,12 @@ +{ + "name": "vEP_JSA_Net", + "description": "Version 2.0 02-09-2016 (Authors: John Doe, user PROD)", + "version": "2013-05-23", + "data": [ + { + "file": "sharedDefinitionOutParam.yaml", + "type": "HEAT", + "isBase": "true" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/sharedresources/inputs/sharedDefinitionOutParam.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/sharedresources/inputs/sharedDefinitionOutParam.yaml new file mode 100644 index 0000000000..778375425b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/sharedresources/inputs/sharedDefinitionOutParam.yaml @@ -0,0 +1,45 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Cluman stack + +parameters: + FSB_1_image: + type: string + label: MME_FSB1 + description: MME_FSB1_15B-CP04-r5a01 + fsb1-flavor: + type: string + label: FSB1_flavor + description: FSB1_flavor + fsb_zone: + type: string + label: FSB1_zone + description: FSB1_zone + fsb1-name: + type: string + label: FSB1_name + description: FSB1_name +resources: + server_pcm_001: + type: OS::Nova::Server + properties: + name: { get_param: fsb1-name } + flavor: { get_param: fsb1-flavor } + availability_zone: { get_param: fsb_zone } + + server_pcm_002: + type: OS::Nova::Server + properties: + name: { get_param: fsb1-name } + flavor: { get_param: fsb1-flavor } + availability_zone: { get_param: fsb_zone } + +outputs: + server_pcm_001_id: + value: {get_resource: server_pcm_001} + server_pcm_002_id: + value: {get_resource: server_pcm_002} + out_id1: + value: {get_param: oam_net_gw} + out_id2: + value: "static value" diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/expectedOutput/validationOutput.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/expectedOutput/validationOutput.json new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/expectedOutput/validationOutput.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/MANIFEST.json new file mode 100644 index 0000000000..e5bfbd157d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/MANIFEST.json @@ -0,0 +1,83 @@ +{ + "name": "multiple_not_nested", + "description": "multiple heat files in zip, no nesting", + "version": "2013-05-23", + "data": [{ + "file": "cmaui.yml", + "type": "HEAT", + "isBase": true, + "data": [{ + "file": "cmaui.env", + "type": "HEAT_ENV" + }, + { + "file": "cmaui_net.yaml", + "type": "HEAT_NET" + }] + }, + { + "file": "eca_oam.yaml", + "type": "HEAT", + "data": [{ + "file": "eca_oam.env", + "type": "HEAT_ENV" + }] + }, + { + "file": "eca_oam_nested.yaml", + "type": "HEAT" + }, + { + "file": "nested1.yaml", + "type": "HEAT" + }, + { + "file": "nested2.yaml", + "type": "HEAT" + }, + { + "file": "MMSC_Capacity_Line.yml", + "type": "HEAT", + "data": [{ + "file": "MMSC_Capacity_Line_1.env", + "type": "HEAT_ENV" + }, + { + "file": "VOLUME.yaml", + "type": "HEAT_VOL", + "data": [{ + "file": "volume.env", + "type": "HEAT_ENV" + }] + }] + }, + { + "file": "SG_ECA_MGMT.yaml", + "type": "HEAT", + "data": [{ + "file": "sg_eca_mgmt.env", + "type": "HEAT_ENV" + }] + }, + { + "file": "VOLUME_OUT.yaml", + "type": "HEAT_VOL", + "data": [{ + "file": "volume_out.env", + "type": "HEAT_ENV" + }] + }, + { + "file": "NETWORK_OUT.yaml", + "type": "HEAT_NET", + "data": [{ + "file": "network_out.env", + "type": "HEAT_ENV" + }] + }, + { + "file": "art.sh", + "type": "SHELL" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/MMSC_Capacity_Line.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/MMSC_Capacity_Line.yml new file mode 100644 index 0000000000..746b96dfe8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/MMSC_Capacity_Line.yml @@ -0,0 +1,3234 @@ +heat_template_version: 2013-05-23 + +description: > + HOT template that creates internal networks, load balancers and servers for vMMSC capacity Line 1. + #11/23: updated the network definition to meet the juniper best practices way of defining the gateway, DHCP enable for internal networks (L457-L547) + +parameters: + vnf_id: + type: string + description: Unique ID for this VNF instance + default: This_is_the_MMSC_id + oam_net_name: + type: string + label: UID of OAM network + description: UID of OAM network + oam_network_netmask: + type: string + label: oam network netmask + description: oam network gateway + oam_network_gateway: + type: string + label: oam network gateway + description: oam network gateway + oam_network_route_1: + type: string + label: oam network route 1 + description: oam network route 1 + oam_network_route_2: + type: string + label: oam network route 2 + description: oam network route 2 + external_dns: + type: string + label: dns server + description: dns server for MMSC + external_ntp: + type: string + label: ntp server + description: ntp server for MMSC + lb_oam_ips: + type: comma_delimited_list + label: management network ips for mmsc lb + description: the ips of the management network for mmsc lb + dmz_protected_net_name: + type: string + label: UID of dmz_protected network + description: UID of dmz_protected network + lb_dmz_protected_ips: + type: comma_delimited_list + label: dmz protected network local ips for lb VM + description: local ips of the dmz protected network for lb VM + cor_direct_net_name: + type: string + label: cor direct net UID + description: cor direct net + lb_cor_direct_ips: + type: comma_delimited_list + label: cor direct network local ips for lb VM + description: local ips of cor direct network for lb VM + mms_traffic_net_name: + type: string + label: Name of MMS traffic network + description: Name of MMS traffic network + mms_traffic_netmask: + type: string + label: MMS traffic network subnet mask + description: MMS traffic network subnet mask + mms_traffic_net_gateway: + type: string + label: MMS traffic network gateway address + description: MMS traffic network gateway address + mms_traffic_start: + type: string + label: mmsc traffic start IP + description: mmsc traffic start IP + mms_traffic_end: + type: string + label: mmsc traffic end IP + description: mmsc traffic end IP + mms_traffic_net_cidr: + type: string + label: mmsc traffic cidr + description: mmsc traffic cidr + mms_traffic_net_local_ip1: + type: string + label: mmsc traffic network local ip1 + description: the local ip1 of the mmsc traffic network + mms_traffic_net_local_ip2: + type: string + label: mmsc traffic network local ip2 + description: the local ip2 of the mmsc traffic network + mms_traffic_net_floating_ip: + type: string + label: mmsc traffic floating ip + description: mmsc traffic floating ip + nems_internal_name: + type: string + label: nems internal network name + description: nems internal network name + nems_internal_start: + type: string + label: nems internal start + description: nems internal start + nems_internal_end: + type: string + label: nems internal end + description: nems internal end + nems_internal_cidr: + type: string + label: nems ineternal cidr + description: nems internal cidr + nems_internal_netmask: + type: string + label: NEMS internal network subnet mask + description: NEMS internal network subnet mask + nems_internal_gateway: + type: string + label: nems internal gw + description: nems internal gw + nems_traffic_name: + type: string + label: nems traffic name + description: nems traffic name + nems_traffic_start: + type: string + label: nems traffic start + description: nems traffic start + nems_traffic_end: + type: string + label: nems traffic end + description: nems traffic end + nems_traffic_cidr: + type: string + label: nems traffic cidr + description: nems traffic cidr + nems_traffic_netmask: + type: string + label: NEMS traffic network subnet mask + description: NEMS traffic network subnet mask + nems_traffic_gateway: + type: string + label: NEMS traffic network gateway + description: NEMS traffic network gateway + nems_traffic_net_local_ip1: + type: string + label: nems traffic network local ip1 + description: the local ip1 of the nems traffic network + nems_traffic_net_local_ip2: + type: string + label: nems traffic network local ip2 + description: the local ip2 of the nems traffic network + nems_traffic_net_floating_ip: + type: string + label: nems traffic floating ip + description: nems traffic floating ip + nems_user_web_name: + type: string + label: nems user web name + description: nems user web name + nems_user_web_start: + type: string + label: nems user web start + description: nems user web end + nems_user_web_end: + type: string + label: nems user web end + description: nems user web end + nems_user_web_cidr: + type: string + label: nems user web cidr + description: nems user web cidr + nems_user_web_netmask: + type: string + label: NEMS user web network subnet mask + description: NEMS user web network subnet mask + nems_user_web_gateway: + type: string + label: NEMS user web network gateway + description: NEMS user web network gateway + nems_user_web_net_local_ip1: + type: string + label: nems user web network local ip1 + description: the local ip1 of the nems user web network + nems_user_web_net_local_ip2: + type: string + label: nems user web network local ip2 + description: the local ip2 of the nems user web network + nems_user_web_net_floating_ip: + type: string + label: nems user web floating ip + description: nems user web floating ip + nems_imap_name: + type: string + label: nems imap name + description: nems imap name + nems_imap_netmask: + type: string + label: nems imap subnet mask + description: nems imap subnet mask + nems_imap_start: + type: string + label: nems imap start + description: nems imap start + nems_imap_end: + type: string + label: nems imap end + description: nems imap end + nems_imap_cidr: + type: string + label: nems imap cidr + description: nems imap cidr + nems_imap_gateway: + type: string + label: nems imap gateway + description: nems imap gateway + eca_traffic_name: + type: string + label: eca traffic name + description: eca traffic name + eca_traffic_start: + type: string + label: eca traffic start + description: eca traffic start + eca_traffic_end: + type: string + label: eca traffic end + description: eca traffic end + eca_traffic_cidr: + type: string + label: eca traffic cidr + description: eca traffic cidr + eca_traffic_netmask: + type: string + label: ECA traffic network subnet mask + description: ECA traffic network subnet mask + eca_traffic_net_gateway: + type: string + label: eca_traffic network gateway + description: eca_traffic network gateway + eca_traffic_net_local_ip1: + type: string + label: eca traffic network local ip1 + description: the local ip1 of the eca traffic network + eca_traffic_net_local_ip2: + type: string + label: eca traffic network local ip2 + description: the local ip2 of the eca traffic network + eca_traffic_net_floating_ip: + type: string + label: eca traffic floating ip + description: eca traffic floating ip + ha_net_name: + type: string + label: ha_failover network name + description: ha_failover network name + ha_net_start: + type: string + label: ha net start + description: ha net start + ha_net_end: + type: string + label: ha net end + description: ha net end + ha_net_cidr: + type: string + label: ha net cidr + description: ha net cidr + ha_net_local_ip1: + type: string + label: ha net network local ip1 + description: the local ip1 of the ha network + ha_net_local_ip2: + type: string + label: ha net network local ip2 + description: the local ip2 of the ha network + lb_names: + type: comma_delimited_list + label: MMSC load balancer instance names + description: MMSC load balancer instance names + lb_image_name: + type: string + label: MMSC load balancer image name + description: MMSC load balancer image name + lb_flavor_name: + type: string + label: Load balancer flavor name + description: the flavor name of MMSC load balancer instance + availability_zone_0: + type: string + label: MMSC availabilityzone name + description: MMSC availabilityzone name + security_group_name: + type: string + label: MMSC security group name + description: MMSC security group name + mmsc_image: + type: string + label: Image for MMSC server + description: Image for MMSC server + mmsc_flavor: + type: string + label: Flavor for MMSC server + description: Flavor for MMSC server + mmsc_cinder_volume_size: + type: number + label: MMSC Cinder volume size + description: the size of the MMSC Cinder volume + nems_fe_image: + type: string + label: Image for NEMS FE server + description: Image for NEMS FE server + nems_fe_flavor: + type: string + label: Flavor for NEMS FE server + description: Flavor for NEMS FE server + nems_be_image: + type: string + label: Image for NEMS BE server + description: Image for NEMS BE server + nems_be_flavor: + type: string + label: Flavor for NEMS BE server + description: Flavor for NEMS BE server + eca_trx_image: + type: string + label: Image for ECA TRX server + description: Image for ECA TRX server + eca_trx_flavor: + type: string + label: Flavor for ECA TRX server + description: Flavor for ECA TRX server + mmsc_oam_ips: + type: comma_delimited_list + label: MMSC oam_net IP addresses + description: MMSC oam_net IP addresses + mmsc_mms_traffic_net_ips: + type: comma_delimited_list + label: MMSC mms_traffic_net IP addresses + description: MMSC mms_traffic_net IP addresses + nems_fe_names: + type: comma_delimited_list + label: NEMS_FE server names + description: NEMS_FE server names + nems_fe_node_roles: + type: comma_delimited_list + label: nems fe node roles + description: nems fe node roles + nems_fe_oam_ips: + type: comma_delimited_list + label: OAM_net IP for NEMS_FE + description: OAM_net IP for NEMS_FE + nems_fe_nems_traffic_net_ips: + type: comma_delimited_list + label: nems_traffic_net IPs for NEMS_FE + description: nems_traffic_net IPs for NEMS_FE + nems_fe_nems_user_web_net_ips: + type: comma_delimited_list + label: nems_web_user_net IPs for NEMS_FE + description: nems_web_user_net IPs for NEMS_FE + nems_fe_nems_internal_net_ips: + type: comma_delimited_list + label: nems_internal_net IPs for NEMS_FE + description: nems_internal_net IPs for NEMS_FE + nems_fe_nems_imap_net_ips: + type: comma_delimited_list + label: nems_imap_net IPs for NEMS_FE + description: nems_imap_net IPs for NEMS_FE + nems_be_names: + type: string + label: NEMS_BE server names + description: NEMS_BE server names + nems_be_node_roles: + type: string + label: nems node roles + description: nems node roles + nems_be_oam_ips: + type: string + label: OAM net IPs for NEMS_BE + description: OAM net IPs for NEMS_BE + nems_be_nems_internal_net_ips: + type: string + label: nems internal net IPs for NEMS_BE + description: nems internal net IPs for NEMS_BE + nems_be_nems_imap_net_ips: + type: string + label: nems imap_net IPs for NEMS_BE + description: nems imap net IPs for NEMS_BE + eca_trx_oam_ips: + type: comma_delimited_list + label: OAM net IP for ECA_TRX + description: OAM net IP for ECA_TRX + eca_trx_mgmt_ips: + type: comma_delimited_list + label: eca mgmt net IP for ECA_TRX + description: eca mgmt net IP for ECA_TRX + timezone: + type: string + label: timezone + description: timezone + eca_trx_names: + type: comma_delimited_list + label: ECA_TRX server names + description: ECA_TRX server names + eca_trx_eca_traffic_net_ips: + type: comma_delimited_list + label: eca traffic net IPs for ECA_TRX + description: eca traffic net IPs for ECA_TRX + mmsc_names: + type: comma_delimited_list + label: MMSC server names + description: MMSC server names + nems_volume_size: + type: number + label: nems fe volume size + description: nems fe volume size + nems_be_volume_size: + type: number + label: nems be volume size + description: nems be volume size + MMSC_volume_type: + type: string + label: MMSC vm volume type + description: the name of the target volume backend + NEMS_FE_volume_type: + type: string + label: nems fe vm volume type + description: the name of the target volume backend + NEMS_BE_volume_type: + type: string + label: nems be vm volume type + description: the name of the target volume backend + mmsc_core_virtual_server_ips: + type: comma_delimited_list + label: mmsc core virtual server ips + description: mmsc core virtual server ips + mmsc_core_snat_ips: + type: comma_delimited_list + label: mmsc core snat ips + description: mmsc core snat ips + mmsc_dmz_protected_virtual_server_ips: + type: comma_delimited_list + label: mmsc dmz_protected virtual server ips + description: mmsc dmz_protected virtual server ips + mmsc_dmz_protected_snat_ips: + type: comma_delimited_list + label: mmsc dmz_protected snat ips + description: mmsc dmz_protected snat ips + eca_mgmt_net_name: + type: string + label: eca management network ID + description: Network ID for eca management + +resources: + mms_traffic_net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: mms_traffic_net_name } + + mms_traffic_artifact: + type: OS::Contrail::VirtualNetwork + properties: + property_get_file_name: { get_file: art.sh } + + mms_traffic_net_nested_1: + type: nested1.yaml + properties: + cmaui_names: { get_param: mms_traffic_net_name } + + mms_traffic_net_nested_2: + type: nested2.yaml + properties: + cmaui_names: { get_param: mms_traffic_net_name } + + mms_traffic_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: mms_traffic_net_name} + network_id: { get_resource: mms_traffic_net } + cidr: { get_param: mms_traffic_net_cidr } + allocation_pools: [{"start": {get_param: mms_traffic_start}, "end": {get_param: mms_traffic_end}}] + + nems_internal_net: + type: OS::Contrail::VirtualNetwork + properties: + name: {get_param: nems_internal_name} + + nems_internal_network_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: nems_internal_name} + allocation_pools: [{"start": {get_param: nems_internal_start}, "end": {get_param: nems_internal_end}}] + cidr: {get_param: nems_internal_cidr} + network_id: {get_resource: nems_internal_net} + + nems_traffic_net: + type: OS::Contrail::VirtualNetwork + properties: + name: {get_param: nems_traffic_name} + + nems_traffic_network_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: nems_traffic_name} + allocation_pools: [{"start": {get_param: nems_traffic_start}, "end": {get_param: nems_traffic_end}}] + cidr: {get_param: nems_traffic_cidr} + network_id: {get_resource: nems_traffic_net} + + nems_user_web_net: + type: OS::Contrail::VirtualNetwork + properties: + name: {get_param: nems_user_web_name} + + nems_user_web_network_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: nems_user_web_name} + allocation_pools: [{"start": {get_param: nems_user_web_start}, "end": {get_param: nems_user_web_end}}] + cidr: {get_param: nems_user_web_cidr} + network_id: {get_resource: nems_user_web_net} + + nems_imap_net: + type: OS::Contrail::VirtualNetwork + properties: + name: {get_param: nems_imap_name} + + nems_imap_network_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: nems_imap_name} + allocation_pools: [{"start": {get_param: nems_imap_start}, "end": {get_param: nems_imap_end}}] + cidr: {get_param: nems_imap_cidr} + network_id: {get_resource: nems_imap_net} + + eca_traffic_net: + type: OS::Contrail::VirtualNetwork + properties: + name: {get_param: eca_traffic_name} + + eca_traffic_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: eca_traffic_name} + allocation_pools: [{"start": {get_param: eca_traffic_start}, "end": {get_param: eca_traffic_end}}] + cidr: {get_param: eca_traffic_cidr} + network_id: {get_resource: eca_traffic_net} + + ha_net: + type: OS::Contrail::VirtualNetwork + properties: + name: {get_param: ha_net_name} + + ha_net_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: ha_net_name} + allocation_pools: [{"start": {get_param: ha_net_start}, "end": {get_param: ha_net_end}}] + cidr: {get_param: ha_net_cidr} + network_id: {get_resource: ha_net} + + lb1_instance: + type: OS::Nova::Server + properties: + name: {get_param: [lb_names, 0]} + image: {get_param: lb_image_name} + flavor: {get_param: lb_flavor_name} + availability_zone: {get_param: availability_zone_0} + networks: + - port: {get_resource: lb1_mgmt_port} + - port: {get_resource: lb1_dmz_protected_port} + - port: {get_resource: lb1_cor_direct_port} + - port: {get_resource: lb1_mms_traffic_port} + - port: {get_resource: lb1_nems_traffic_port} + - port: {get_resource: lb1_nems_user_web_port} + - port: {get_resource: lb1_eca_traffic_port} + - port: {get_resource: lb1_ha_net_port} + metadata: + vnf_id: { get_param: vnf_id } + + lb1_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [lb_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb1_mms_traffic_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: mms_traffic_net} + fixed_ips: [{"ip_address": {get_param: mms_traffic_net_local_ip1}}] + allowed_address_pairs: [{"ip_address": {get_param: mms_traffic_net_floating_ip} }] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb1_dmz_protected_port: + type: OS::Neutron::Port + properties: + network: {get_param: dmz_protected_net_name} + fixed_ips: [{"ip_address": {get_param: [lb_dmz_protected_ips, 0]}}] + allowed_address_pairs: [{"ip_address": {get_param: [mmsc_dmz_protected_virtual_server_ips, 0]}}, {"ip_address": {get_param: [mmsc_dmz_protected_virtual_server_ips, 1]}}, {"ip_address": {get_param: [mmsc_dmz_protected_virtual_server_ips, 2]}}, {"ip_address": {get_param: [mmsc_dmz_protected_snat_ips, 0]}}, {"ip_address": {get_param: [mmsc_dmz_protected_snat_ips, 1]}}, {"ip_address": {get_param: [mmsc_dmz_protected_snat_ips, 2]}}, {"ip_address": {get_param: [mmsc_dmz_protected_snat_ips, 3]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb1_cor_direct_port: + type: OS::Neutron::Port + properties: + network: {get_param: cor_direct_net_name} + fixed_ips: [{"ip_address": {get_param: [lb_cor_direct_ips, 0]}}] + allowed_address_pairs: [{"ip_address": {get_param: [mmsc_core_virtual_server_ips, 0]}}, {"ip_address": {get_param: [mmsc_core_virtual_server_ips, 1]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 0]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 1]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 2]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 3]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 4]}} ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb1_nems_traffic_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: nems_traffic_net} + fixed_ips: [{"ip_address": {get_param: nems_traffic_net_local_ip1}}] + allowed_address_pairs: [{"ip_address": {get_param: nems_traffic_net_floating_ip} }] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb1_nems_user_web_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: nems_user_web_net} + fixed_ips: [{"ip_address": {get_param: nems_user_web_net_local_ip1}}] + allowed_address_pairs: [{"ip_address": {get_param: nems_user_web_net_floating_ip} }] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb1_ha_net_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: ha_net} + fixed_ips: [{"ip_address": {get_param: ha_net_local_ip1}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb1_eca_traffic_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: eca_traffic_net} + fixed_ips: [{"ip_address": {get_param: eca_traffic_net_local_ip1}}] + allowed_address_pairs: [{"ip_address": {get_param: eca_traffic_net_floating_ip} }] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb2_instance: + type: OS::Nova::Server + properties: + name: {get_param: [lb_names, 1]} + image: {get_param: lb_image_name} + flavor: {get_param: lb_flavor_name} + availability_zone: {get_param: availability_zone_0} + networks: + - port: {get_resource: lb2_mgmt_port} + - port: {get_resource: lb2_dmz_protected_port} + - port: {get_resource: lb2_cor_direct_port} + - port: {get_resource: lb2_mms_traffic_port} + - port: {get_resource: lb2_nems_traffic_port} + - port: {get_resource: lb2_nems_user_web_port} + - port: {get_resource: lb2_eca_traffic_port} + - port: {get_resource: lb2_ha_net_port} + metadata: + vnf_id: { get_param: vnf_id } + + lb2_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [lb_oam_ips, 1]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb2_mms_traffic_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: mms_traffic_net} + fixed_ips: [{"ip_address": {get_param: mms_traffic_net_local_ip2}}] + allowed_address_pairs: [{"ip_address": {get_param: mms_traffic_net_floating_ip}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb2_dmz_protected_port: + type: OS::Neutron::Port + properties: + network: {get_param: dmz_protected_net_name} + fixed_ips: [{"ip_address": {get_param: [lb_dmz_protected_ips, 1]}}] + allowed_address_pairs: [{"ip_address": {get_param: [mmsc_dmz_protected_virtual_server_ips, 0]}}, {"ip_address": {get_param: [mmsc_dmz_protected_virtual_server_ips, 1]}}, {"ip_address": {get_param: [mmsc_dmz_protected_virtual_server_ips, 2]}}, {"ip_address": {get_param: [mmsc_dmz_protected_snat_ips, 0]}}, {"ip_address": {get_param: [mmsc_dmz_protected_snat_ips, 1]}}, {"ip_address": {get_param: [mmsc_dmz_protected_snat_ips, 2]}}, {"ip_address": {get_param: [mmsc_dmz_protected_snat_ips, 3]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb2_cor_direct_port: + type: OS::Neutron::Port + properties: + network: {get_param: cor_direct_net_name} + fixed_ips: [{"ip_address": {get_param: [lb_cor_direct_ips, 1]}}] + allowed_address_pairs: [{"ip_address": {get_param: [mmsc_core_virtual_server_ips, 0]}}, {"ip_address": {get_param: [mmsc_core_virtual_server_ips, 1]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 0]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 1]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 2]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 3]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 4]}} ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb2_nems_traffic_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: nems_traffic_net} + fixed_ips: [{"ip_address": {get_param: nems_traffic_net_local_ip2}}] + allowed_address_pairs: [{"ip_address": {get_param: nems_traffic_net_floating_ip}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb2_nems_user_web_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: nems_user_web_net} + fixed_ips: [{"ip_address": {get_param: nems_user_web_net_local_ip2}}] + allowed_address_pairs: [{"ip_address": {get_param: nems_user_web_net_floating_ip}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb2_ha_net_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: ha_net} + fixed_ips: [{"ip_address": {get_param: ha_net_local_ip2}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb2_eca_traffic_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: eca_traffic_net} + fixed_ips: [{"ip_address": {get_param: eca_traffic_net_local_ip2}}] + allowed_address_pairs: [{"ip_address": {get_param: eca_traffic_net_floating_ip} }] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_mmsc1: + type: OS::Nova::Server + properties: + name: { get_param: [mmsc_names, 0]} + image: { get_param: mmsc_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: mmsc_flavor } + networks: + - port: { get_resource: mmsc1_port_0 } + - port: { get_resource: mmsc1_port_1 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + mmsc.mgmt.ip=${mmsc.mgmt.ip} + mmsc.mgmt.netmask=${mmsc.mgmt.netmask} + mmsc.mgmt.gateway=${mmsc.mgmt.gateway} + mmsc.traffic.ip=${mmsc.traffic.ip} + mmsc.traffic.netmask=${mmsc.traffic.netmask} + mmsc.traffic.gateway=${mmsc.traffic.gateway} + mmsc.mgmt.route.1=${mmsc.mgmt.route.1} + mmsc.mgmt.route.2=${mmsc.mgmt.route.2} + mmsc.external.dns=${mmsc.external.dns} + mmsc.external.ntp=${mmsc.external.ntp} + mmsc.hostname=${mmsc.hostname} + mmsc.timezone=${mmsc.timezone} + params: + ${mmsc.mgmt.ip}: {get_param: [mmsc_oam_ips, 0]} + ${mmsc.mgmt.netmask}: {get_param: oam_network_netmask} + ${mmsc.mgmt.gateway}: {get_param: oam_network_gateway} + ${mmsc.traffic.ip}: {get_param: [mmsc_mms_traffic_net_ips, 0]} + ${mmsc.traffic.netmask}: {get_param: mms_traffic_netmask} + ${mmsc.traffic.gateway}: {get_param: mms_traffic_net_gateway} + ${mmsc.mgmt.route.1}: {get_param: oam_network_route_1} + ${mmsc.mgmt.route.2}: {get_param: oam_network_route_2} + ${mmsc.external.dns}: {get_param: external_dns} + ${mmsc.external.ntp}: {get_param: external_ntp} + ${mmsc.hostname}: {get_param: [mmsc_names, 0]} + ${mmsc.timezone}: {get_param: timezone} + user_data_format: RAW + + mmsc1_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: mmsc_cinder_volume_size} + volume_type: {get_param: MMSC_volume_type} + + mmsc1_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: mmsc1_volume} + instance_uuid: {get_resource: server_mmsc1} + + mmsc1_port_0: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [ + "ip_address": {get_param: [mmsc_oam_ips, 0]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + mmsc1_port_1: + type: OS::Neutron::Port + properties: + network_id: {get_resource: mms_traffic_net} + fixed_ips: [ + "ip_address": {get_param: [mmsc_mms_traffic_net_ips, 0]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_mmsc2: + type: OS::Nova::Server + properties: + name: { get_param: [mmsc_names, 1]} + image: { get_param: mmsc_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: mmsc_flavor } + networks: + - port: { get_resource: mmsc2_port_0 } + - port: { get_resource: mmsc2_port_1 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + mmsc.mgmt.ip=${mmsc.mgmt.ip} + mmsc.mgmt.netmask=${mmsc.mgmt.netmask} + mmsc.mgmt.gateway=${mmsc.mgmt.gateway} + mmsc.traffic.ip=${mmsc.traffic.ip} + mmsc.traffic.netmask=${mmsc.traffic.netmask} + mmsc.traffic.gateway=${mmsc.traffic.gateway} + mmsc.mgmt.route.1=${mmsc.mgmt.route.1} + mmsc.mgmt.route.2=${mmsc.mgmt.route.2} + mmsc.external.dns=${mmsc.external.dns} + mmsc.external.ntp=${mmsc.external.ntp} + mmsc.hostname=${mmsc.hostname} + mmsc.timezone=${mmsc.timezone} + params: + ${mmsc.mgmt.ip}: {get_param: [mmsc_oam_ips, 1]} + ${mmsc.mgmt.netmask}: {get_param: oam_network_netmask} + ${mmsc.mgmt.gateway}: {get_param: oam_network_gateway} + ${mmsc.traffic.ip}: {get_param: [mmsc_mms_traffic_net_ips, 1]} + ${mmsc.traffic.netmask}: {get_param: mms_traffic_netmask} + ${mmsc.traffic.gateway}: {get_param: mms_traffic_net_gateway} + ${mmsc.mgmt.route.1}: {get_param: oam_network_route_1} + ${mmsc.mgmt.route.2}: {get_param: oam_network_route_2} + ${mmsc.external.dns}: {get_param: external_dns} + ${mmsc.external.ntp}: {get_param: external_ntp} + ${mmsc.hostname}: {get_param: [mmsc_names, 1]} + ${mmsc.timezone}: {get_param: timezone} + user_data_format: RAW + + mmsc2_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: mmsc_cinder_volume_size} + volume_type: {get_param: MMSC_volume_type} + + mmsc2_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: mmsc2_volume} + instance_uuid: {get_resource: server_mmsc2} + + mmsc2_port_0: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [ + "ip_address": {get_param: [mmsc_oam_ips, 1]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + mmsc2_port_1: + type: OS::Neutron::Port + properties: + network_id: {get_resource: mms_traffic_net} + fixed_ips: [ + "ip_address": {get_param: [mmsc_mms_traffic_net_ips, 1]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_mmsc3: + type: OS::Nova::Server + properties: + name: { get_param: [mmsc_names, 2]} + image: { get_param: mmsc_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: mmsc_flavor } + networks: + - port: { get_resource: mmsc3_port_0 } + - port: { get_resource: mmsc3_port_1 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + mmsc.mgmt.ip=${mmsc.mgmt.ip} + mmsc.mgmt.netmask=${mmsc.mgmt.netmask} + mmsc.mgmt.gateway=${mmsc.mgmt.gateway} + mmsc.traffic.ip=${mmsc.traffic.ip} + mmsc.traffic.netmask=${mmsc.traffic.netmask} + mmsc.traffic.gateway=${mmsc.traffic.gateway} + mmsc.mgmt.route.1=${mmsc.mgmt.route.1} + mmsc.mgmt.route.2=${mmsc.mgmt.route.2} + mmsc.external.dns=${mmsc.external.dns} + mmsc.external.ntp=${mmsc.external.ntp} + mmsc.hostname=${mmsc.hostname} + mmsc.timezone=${mmsc.timezone} + params: + ${mmsc.mgmt.ip}: {get_param: [mmsc_oam_ips, 2]} + ${mmsc.mgmt.netmask}: {get_param: oam_network_netmask} + ${mmsc.mgmt.gateway}: {get_param: oam_network_gateway} + ${mmsc.traffic.ip}: {get_param: [mmsc_mms_traffic_net_ips, 2]} + ${mmsc.traffic.netmask}: {get_param: mms_traffic_netmask} + ${mmsc.traffic.gateway}: {get_param: mms_traffic_net_gateway} + ${mmsc.mgmt.route.1}: {get_param: oam_network_route_1} + ${mmsc.mgmt.route.2}: {get_param: oam_network_route_2} + ${mmsc.external.dns}: {get_param: external_dns} + ${mmsc.external.ntp}: {get_param: external_ntp} + ${mmsc.hostname}: {get_param: [mmsc_names, 2]} + ${mmsc.timezone}: {get_param: timezone} + user_data_format: RAW + + mmsc3_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: mmsc_cinder_volume_size} + volume_type: {get_param: MMSC_volume_type} + + mmsc3_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: mmsc3_volume} + instance_uuid: {get_resource: server_mmsc3} + + mmsc3_port_0: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [ + "ip_address": {get_param: [mmsc_oam_ips, 2]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + mmsc3_port_1: + type: OS::Neutron::Port + properties: + network_id: {get_resource: mms_traffic_net} + fixed_ips: [ + "ip_address": {get_param: [mmsc_mms_traffic_net_ips, 2]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_mmsc4: + type: OS::Nova::Server + properties: + name: { get_param: [mmsc_names, 3]} + image: { get_param: mmsc_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: mmsc_flavor } + networks: + - port: { get_resource: mmsc4_port_0 } + - port: { get_resource: mmsc4_port_1 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + mmsc.mgmt.ip=${mmsc.mgmt.ip} + mmsc.mgmt.netmask=${mmsc.mgmt.netmask} + mmsc.mgmt.gateway=${mmsc.mgmt.gateway} + mmsc.traffic.ip=${mmsc.traffic.ip} + mmsc.traffic.netmask=${mmsc.traffic.netmask} + mmsc.traffic.gateway=${mmsc.traffic.gateway} + mmsc.mgmt.route.1=${mmsc.mgmt.route.1} + mmsc.mgmt.route.2=${mmsc.mgmt.route.2} + mmsc.external.dns=${mmsc.external.dns} + mmsc.external.ntp=${mmsc.external.ntp} + mmsc.hostname=${mmsc.hostname} + mmsc.timezone=${mmsc.timezone} + params: + ${mmsc.mgmt.ip}: {get_param: [mmsc_oam_ips, 3]} + ${mmsc.mgmt.netmask}: {get_param: oam_network_netmask} + ${mmsc.mgmt.gateway}: {get_param: oam_network_gateway} + ${mmsc.traffic.ip}: {get_param: [mmsc_mms_traffic_net_ips, 3]} + ${mmsc.traffic.netmask}: {get_param: mms_traffic_netmask} + ${mmsc.traffic.gateway}: {get_param: mms_traffic_net_gateway} + ${mmsc.mgmt.route.1}: {get_param: oam_network_route_1} + ${mmsc.mgmt.route.2}: {get_param: oam_network_route_2} + ${mmsc.external.dns}: {get_param: external_dns} + ${mmsc.external.ntp}: {get_param: external_ntp} + ${mmsc.hostname}: {get_param: [mmsc_names, 3]} + ${mmsc.timezone}: {get_param: timezone} + user_data_format: RAW + + mmsc4_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: mmsc_cinder_volume_size} + volume_type: {get_param: MMSC_volume_type} + + mmsc4_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: mmsc4_volume} + instance_uuid: {get_resource: server_mmsc4} + + mmsc4_port_0: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [ + "ip_address": {get_param: [mmsc_oam_ips, 3]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + mmsc4_port_1: + type: OS::Neutron::Port + properties: + network_id: {get_resource: mms_traffic_net} + fixed_ips: [ + "ip_address": {get_param: [mmsc_mms_traffic_net_ips, 3]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_mmsc5: + type: OS::Nova::Server + properties: + name: { get_param: [mmsc_names, 4]} + image: { get_param: mmsc_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: mmsc_flavor } + networks: + - port: { get_resource: mmsc5_port_0 } + - port: { get_resource: mmsc5_port_1 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + mmsc.mgmt.ip=${mmsc.mgmt.ip} + mmsc.mgmt.netmask=${mmsc.mgmt.netmask} + mmsc.mgmt.gateway=${mmsc.mgmt.gateway} + mmsc.traffic.ip=${mmsc.traffic.ip} + mmsc.traffic.netmask=${mmsc.traffic.netmask} + mmsc.traffic.gateway=${mmsc.traffic.gateway} + mmsc.mgmt.route.1=${mmsc.mgmt.route.1} + mmsc.mgmt.route.2=${mmsc.mgmt.route.2} + mmsc.external.dns=${mmsc.external.dns} + mmsc.external.ntp=${mmsc.external.ntp} + mmsc.hostname=${mmsc.hostname} + mmsc.timezone=${mmsc.timezone} + params: + ${mmsc.mgmt.ip}: {get_param: [mmsc_oam_ips, 4]} + ${mmsc.mgmt.netmask}: {get_param: oam_network_netmask} + ${mmsc.mgmt.gateway}: {get_param: oam_network_gateway} + ${mmsc.traffic.ip}: {get_param: [mmsc_mms_traffic_net_ips, 4]} + ${mmsc.traffic.netmask}: {get_param: mms_traffic_netmask} + ${mmsc.traffic.gateway}: {get_param: mms_traffic_net_gateway} + ${mmsc.mgmt.route.1}: {get_param: oam_network_route_1} + ${mmsc.mgmt.route.2}: {get_param: oam_network_route_2} + ${mmsc.external.dns}: {get_param: external_dns} + ${mmsc.external.ntp}: {get_param: external_ntp} + ${mmsc.hostname}: {get_param: [mmsc_names, 4]} + ${mmsc.timezone}: {get_param: timezone} + user_data_format: RAW + + mmsc5_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: mmsc_cinder_volume_size} + volume_type: {get_param: MMSC_volume_type} + + mmsc5_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: mmsc5_volume} + instance_uuid: {get_resource: server_mmsc5} + + mmsc5_port_0: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [ + "ip_address": {get_param: [mmsc_oam_ips, 4]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + mmsc5_port_1: + type: OS::Neutron::Port + properties: + network_id: {get_resource: mms_traffic_net} + fixed_ips: [ + "ip_address": {get_param: [mmsc_mms_traffic_net_ips, 4]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_nems_fe1: + type: OS::Nova::Server + properties: + name: { get_param: [nems_fe_names, 0] } + image: { get_param: nems_fe_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: nems_fe_flavor } + networks: + - port: { get_resource: nems_fe1_port_0 } + - port: { get_resource: nems_fe1_port_1 } + - port: { get_resource: nems_fe1_port_2 } + - port: { get_resource: nems_fe1_port_3 } + - port: { get_resource: nems_fe1_port_4 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + nems.mgmt.ip=${nems.mgmt.ip} + nems.mgmt.netmask=${nems.mgmt.netmask} + nems.mgmt.gateway=${nems.mgmt.gateway} + nems.traffic.ip=${nems.traffic.ip} + nems.traffic.netmask=${nems.traffic.netmask} + nems.traffic.gateway=${nems.traffic.gateway} + nems.fe0.internal.ip=${nems.fe0.internal.ip} + nems.fe1.internal.ip=${nems.fe1.internal.ip} + nems.internal.netmask=${nems.internal.netmask} + nems.userweb.ip=${nems.userweb.ip} + nems.userweb.netmask=${nems.userweb.netmask} + nems.userweb.gateway=${nems.userweb.gateway} + nems.imap.ip=${nems.imap.ip} + nems.imap.netmask=${nems.imap.netmask} + nems.be.internal.ip=${nems.be.internal.ip} + nems.be.imap.ip=${nems.be.imap.ip} + nems.mgmt.route.1=${nems.mgmt.route.1} + nems.mgmt.route.2=${nems.mgmt.route.2} + nems.external.dns=${nems.external.dns} + nems.external.ntp=${nems.external.ntp} + nems.node=${nems.node} + nems.be0.host.name=${nems.be0.host.name} + nems.fe0.host.name=${nems.fe0.host.name} + nems.fe1.host.name=${nems.fe1.host.name} + nems.timezone=${nems.timezone} + params: + ${nems.mgmt.ip}: {get_param: [nems_fe_oam_ips, 0]} + ${nems.mgmt.netmask}: {get_param: oam_network_netmask} + ${nems.mgmt.gateway}: {get_param: oam_network_gateway} + ${nems.traffic.ip}: {get_param: [nems_fe_nems_traffic_net_ips, 0]} + ${nems.traffic.netmask}: {get_param: nems_traffic_netmask} + ${nems.traffic.gateway}: {get_param: nems_traffic_gateway} + ${nems.fe0.internal.ip}: {get_param: [nems_fe_nems_internal_net_ips, 0]} + ${nems.fe1.internal.ip}: {get_param: [nems_fe_nems_internal_net_ips, 1]} + ${nems.internal.netmask}: {get_param: nems_internal_netmask} + ${nems.userweb.ip}: {get_param: [nems_fe_nems_user_web_net_ips, 0]} + ${nems.userweb.netmask}: {get_param: nems_user_web_netmask} + ${nems.userweb.gateway}: {get_param: nems_user_web_gateway} + ${nems.imap.ip}: {get_param: [nems_fe_nems_imap_net_ips, 0]} + ${nems.imap.netmask}: {get_param: nems_imap_netmask} + ${nems.be.internal.ip}: {get_param: nems_be_nems_internal_net_ips} + ${nems.be.imap.ip}: {get_param: nems_be_nems_imap_net_ips} + ${nems.mgmt.route.1}: {get_param: oam_network_route_1} + ${nems.mgmt.route.2}: {get_param: oam_network_route_2} + ${nems.external.dns}: {get_param: external_dns} + ${nems.external.ntp}: {get_param: external_ntp} + ${nems.node}: {get_param: [nems_fe_node_roles, 0]} + ${nems.fe0.host.name}: {get_param: [nems_fe_names, 0]} + ${nems.fe1.host.name}: {get_param: [nems_fe_names, 1]} + ${nems.be0.host.name}: {get_param: nems_be_names} + ${nems.timezone}: {get_param: timezone} + user_data_format: RAW + + nems1_fe_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: nems_volume_size} + volume_type: {get_param: NEMS_FE_volume_type} + + nems1_fe_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: nems1_fe_volume} + instance_uuid: {get_resource: server_nems_fe1} + + nems_fe1_port_0: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [ + "ip_address": { get_param: [nems_fe_oam_ips, 0] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_fe1_port_1: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [nems_fe_nems_traffic_net_ips, 0] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_fe1_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_user_web_net } + fixed_ips: [ + "ip_address": { get_param: [nems_fe_nems_user_web_net_ips, 0] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_fe1_port_3: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_internal_net } + fixed_ips: [ + "ip_address": { get_param: [nems_fe_nems_internal_net_ips, 0] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_fe1_port_4: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_imap_net } + fixed_ips: [ + "ip_address": { get_param: [nems_fe_nems_imap_net_ips, 0] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_nems_fe2: + type: OS::Nova::Server + properties: + name: { get_param: [nems_fe_names, 1] } + image: { get_param: nems_fe_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: nems_fe_flavor } + networks: + - port: { get_resource: nems_fe2_port_0 } + - port: { get_resource: nems_fe2_port_1 } + - port: { get_resource: nems_fe2_port_2 } + - port: { get_resource: nems_fe2_port_3 } + - port: { get_resource: nems_fe2_port_4 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + nems.mgmt.ip=${nems.mgmt.ip} + nems.mgmt.netmask=${nems.mgmt.netmask} + nems.mgmt.gateway=${nems.mgmt.gateway} + nems.traffic.ip=${nems.traffic.ip} + nems.traffic.netmask=${nems.traffic.netmask} + nems.traffic.gateway=${nems.traffic.gateway} + nems.fe0.internal.ip=${nems.fe0.internal.ip} + nems.fe1.internal.ip=${nems.fe1.internal.ip} + nems.internal.netmask=${nems.internal.netmask} + nems.userweb.ip=${nems.userweb.ip} + nems.userweb.netmask=${nems.userweb.netmask} + nems.userweb.gateway=${nems.userweb.gateway} + nems.imap.ip=${nems.imap.ip} + nems.imap.netmask=${nems.imap.netmask} + nems.be.internal.ip=${nems.be.internal.ip} + nems.be.imap.ip=${nems.be.imap.ip} + nems.mgmt.route.1=${nems.mgmt.route.1} + nems.mgmt.route.2=${nems.mgmt.route.2} + nems.external.dns=${nems.external.dns} + nems.external.ntp=${nems.external.ntp} + nems.node=${nems.node} + nems.be0.host.name=${nems.be0.host.name} + nems.fe0.host.name=${nems.fe0.host.name} + nems.fe1.host.name=${nems.fe1.host.name} + nems.timezone=${nems.timezone} + params: + ${nems.mgmt.ip}: {get_param: [nems_fe_oam_ips, 1]} + ${nems.mgmt.netmask}: {get_param: oam_network_netmask} + ${nems.mgmt.gateway}: {get_param: oam_network_gateway} + ${nems.traffic.ip}: {get_param: [nems_fe_nems_traffic_net_ips, 1]} + ${nems.traffic.netmask}: {get_param: nems_traffic_netmask} + ${nems.traffic.gateway}: {get_param: nems_traffic_gateway} + ${nems.fe0.internal.ip}: {get_param: [nems_fe_nems_internal_net_ips, 0]} + ${nems.fe1.internal.ip}: {get_param: [nems_fe_nems_internal_net_ips, 1]} + ${nems.internal.netmask}: {get_param: nems_internal_netmask} + ${nems.userweb.ip}: {get_param: [nems_fe_nems_user_web_net_ips, 1]} + ${nems.userweb.netmask}: {get_param: nems_user_web_netmask} + ${nems.userweb.gateway}: {get_param: nems_user_web_gateway} + ${nems.imap.ip}: {get_param: [nems_fe_nems_imap_net_ips, 1]} + ${nems.imap.netmask}: {get_param: nems_imap_netmask} + ${nems.be.internal.ip}: {get_param: nems_be_nems_internal_net_ips} + ${nems.be.imap.ip}: {get_param: nems_be_nems_imap_net_ips} + ${nems.mgmt.route.1}: {get_param: oam_network_route_1} + ${nems.mgmt.route.2}: {get_param: oam_network_route_2} + ${nems.external.dns}: {get_param: external_dns} + ${nems.external.ntp}: {get_param: external_ntp} + ${nems.node}: {get_param: [nems_fe_node_roles, 1]} + ${nems.fe0.host.name}: {get_param: [nems_fe_names, 0]} + ${nems.fe1.host.name}: {get_param: [nems_fe_names, 1]} + ${nems.be0.host.name}: {get_param: nems_be_names} + ${nems.timezone}: {get_param: timezone} + user_data_format: RAW + + nems2_fe_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: nems_volume_size} + volume_type: {get_param: NEMS_FE_volume_type} + + nems2_fe_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: nems2_fe_volume} + instance_uuid: {get_resource: server_nems_fe2} + + nems_fe2_port_0: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [ + "ip_address": {get_param: [nems_fe_oam_ips, 1]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_fe2_port_1: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [nems_fe_nems_traffic_net_ips, 1] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_fe2_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_user_web_net } + fixed_ips: [ + "ip_address": { get_param: [nems_fe_nems_user_web_net_ips, 1] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_fe2_port_3: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_internal_net } + fixed_ips: [ + "ip_address": { get_param: [nems_fe_nems_internal_net_ips, 1] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + + nems_fe2_port_4: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_imap_net } + fixed_ips: [ + "ip_address": { get_param: [nems_fe_nems_imap_net_ips, 1] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_nems_be1: + type: OS::Nova::Server + properties: + name: { get_param: nems_be_names } + image: { get_param: nems_be_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: nems_be_flavor } + networks: + - port: { get_resource: nems_be1_port_0 } + - port: { get_resource: nems_be1_port_1 } + - port: { get_resource: nems_be1_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + nems.be.mgmt.ip=${nems.be.mgmt.ip} + nems.mgmt.netmask=${nems.mgmt.netmask} + nems.mgmt.gateway=${nems.mgmt.gateway} + nems.be.internal.ip=${nems.be.internal.ip} + nems.internal.netmask=${nems.internal.netmask} + nems.imap.netmask=${nems.imap.netmask} + nems.fe0.internal.ip=${nems.fe0.internal.ip} + nems.fe1.internal.ip=${nems.fe1.internal.ip} + nems.be.imap.ip=${nems.be.imap.ip} + nems.mgmt.route.1=${nems.mgmt.route.1} + nems.mgmt.route.2=${nems.mgmt.route.2} + nems.external.dns=${nems.external.dns} + nems.external.ntp=${nems.external.ntp} + nems.node=${nems.node} + nems.be0.host.name=${nems.be0.host.name} + nems.fe0.host.name=${nems.fe0.host.name} + nems.fe1.host.name=${nems.fe1.host.name} + nems.timezone=${nems.timezone} + params: + ${nems.be.mgmt.ip}: {get_param: nems_be_oam_ips} + ${nems.mgmt.netmask}: {get_param: oam_network_netmask} + ${nems.mgmt.gateway}: {get_param: oam_network_gateway} + ${nems.fe0.internal.ip}: {get_param: [nems_fe_nems_internal_net_ips, 0]} + ${nems.fe1.internal.ip}: {get_param: [nems_fe_nems_internal_net_ips, 1]} + ${nems.be.internal.ip}: {get_param: nems_be_nems_internal_net_ips} + ${nems.internal.netmask}: {get_param: nems_internal_netmask} + ${nems.imap.netmask}: {get_param: nems_imap_netmask} + ${nems.be.imap.ip}: {get_param: nems_be_nems_imap_net_ips} + ${nems.mgmt.route.1}: {get_param: oam_network_route_1} + ${nems.mgmt.route.2}: {get_param: oam_network_route_2} + ${nems.external.dns}: {get_param: external_dns} + ${nems.external.ntp}: {get_param: external_ntp} + ${nems.node}: {get_param: nems_be_node_roles} + ${nems.be0.host.name}: {get_param: nems_be_names} + ${nems.fe0.host.name}: {get_param: [nems_fe_names, 0]} + ${nems.fe1.host.name}: {get_param: [nems_fe_names, 1]} + ${nems.timezone}: {get_param: timezone} + user_data_format: RAW + + nems_be_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: nems_be_volume_size} + volume_type: {get_param: NEMS_BE_volume_type} + + nems_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: nems_be_volume} + instance_uuid: {get_resource: server_nems_be1} + + + nems_be1_port_0: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [ + "ip_address": { get_param: nems_be_oam_ips} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_be1_port_1: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_internal_net } + fixed_ips: [ + "ip_address": { get_param: nems_be_nems_internal_net_ips} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_be1_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_imap_net } + fixed_ips: [ + "ip_address": { get_param: nems_be_nems_imap_net_ips} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx1: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 0]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx1_port_0 } + - port: { get_resource: eca_trx1_port_1 } + - port: { get_resource: eca_trx1_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 0]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 0]} + + eca_trx1_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 0] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx1_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 0] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx1_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 0] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + + server_eca_trx2: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 1]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx2_port_0 } + - port: { get_resource: eca_trx2_port_1 } + - port: { get_resource: eca_trx2_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 1]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 1]} + + eca_trx2_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 1] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx2_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 1] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx2_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 1] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx3: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 2]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx3_port_0 } + - port: { get_resource: eca_trx3_port_1 } + - port: { get_resource: eca_trx3_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 2]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 2]} + + eca_trx3_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 2] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx3_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 2] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx3_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 2] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx4: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 3]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx4_port_0 } + - port: { get_resource: eca_trx4_port_1 } + - port: { get_resource: eca_trx4_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 3]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 3]} + + eca_trx4_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 3] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx4_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 3] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx4_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 3] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx5: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 4]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx5_port_0 } + - port: { get_resource: eca_trx5_port_1 } + - port: { get_resource: eca_trx5_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 4]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 4]} + + eca_trx5_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 4] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx5_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 4] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx5_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 4] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx6: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 5]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx6_port_0 } + - port: { get_resource: eca_trx6_port_1 } + - port: { get_resource: eca_trx6_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 5]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 5]} + + eca_trx6_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 5] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx6_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 5] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx6_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 5] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx7: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 6]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx7_port_0 } + - port: { get_resource: eca_trx7_port_1 } + - port: { get_resource: eca_trx7_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 6]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 6]} + + eca_trx7_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 6] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx7_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 6] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx7_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 6] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx8: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 7]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx8_port_0 } + - port: { get_resource: eca_trx8_port_1 } + - port: { get_resource: eca_trx8_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 7]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 7]} + + eca_trx8_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 7] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx8_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 7] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx8_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 7] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx9: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 8]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx9_port_0 } + - port: { get_resource: eca_trx9_port_1 } + - port: { get_resource: eca_trx9_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 8]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 8]} + + eca_trx9_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 8] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx9_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 8] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx9_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 8] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx10: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 9]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx10_port_0 } + - port: { get_resource: eca_trx10_port_1 } + - port: { get_resource: eca_trx10_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 9]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 9]} + + eca_trx10_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 9] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx10_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 9] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx10_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 9] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx11: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 10]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx11_port_0 } + - port: { get_resource: eca_trx11_port_1 } + - port: { get_resource: eca_trx11_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 10]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 10]} + + eca_trx11_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 10] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx11_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 10] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx11_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 10] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + + server_eca_trx12: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 11]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx12_port_0 } + - port: { get_resource: eca_trx12_port_1 } + - port: { get_resource: eca_trx12_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 11]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 11]} + + eca_trx12_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 11] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx12_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 11] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx12_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 11] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx13: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 12]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx13_port_0 } + - port: { get_resource: eca_trx13_port_1 } + - port: { get_resource: eca_trx13_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 12]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 12]} + + eca_trx13_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 12] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx13_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 12] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx13_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 12] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx14: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 13]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx14_port_0 } + - port: { get_resource: eca_trx14_port_1 } + - port: { get_resource: eca_trx14_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 13]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 13]} + + eca_trx14_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 13] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx14_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 13] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx14_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 13] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx15: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 14]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx15_port_0 } + - port: { get_resource: eca_trx15_port_1 } + - port: { get_resource: eca_trx15_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 14]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 14]} + + eca_trx15_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 14] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx15_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 14] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx15_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 14] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx16: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 15]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx16_port_0 } + - port: { get_resource: eca_trx16_port_1 } + - port: { get_resource: eca_trx16_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 15]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 15]} + + eca_trx16_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 15] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx16_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 15] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx16_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 15] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + + server_eca_trx17: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 16]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx17_port_0 } + - port: { get_resource: eca_trx17_port_1 } + - port: { get_resource: eca_trx17_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 16]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 16]} + + eca_trx17_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 16] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx17_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 16] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx17_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 16] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx18: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 17]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx18_port_0 } + - port: { get_resource: eca_trx18_port_1 } + - port: { get_resource: eca_trx18_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 17]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 17]} + + eca_trx18_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 17] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx18_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 17] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx18_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 17] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx19: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 18]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx19_port_0 } + - port: { get_resource: eca_trx19_port_1 } + - port: { get_resource: eca_trx19_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 8]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 18]} + + eca_trx19_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 18] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx19_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 18] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx19_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 18] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx20: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 19]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx20_port_0 } + - port: { get_resource: eca_trx20_port_1 } + - port: { get_resource: eca_trx20_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 19]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 19]} + + eca_trx20_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 19] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx20_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 19] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx20_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 19] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/MMSC_Capacity_Line_1.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/MMSC_Capacity_Line_1.env new file mode 100644 index 0000000000..b346d67d97 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/MMSC_Capacity_Line_1.env @@ -0,0 +1,111 @@ +parameters: + oam_net_name: oam_protected_net_0 + oam_network_netmask: 255.255.254.0 + oam_network_gateway: 107.250.172.1 + oam_network_route_1: 155.165.201.250/32,107.250.172.1 + oam_network_route_2: 155.165.194.100/32,107.250.172.1 + external_dns: 155.165.194.100 + external_ntp: 155.165.201.250 + lb_oam_ips: 107.250.172.50,107.250.172.51 + dmz_protected_net_name: dmz_protected_net_0 + lb_dmz_protected_ips: 107.239.14.19,107.239.14.20 + cor_direct_net_name: cor_direct_net_0 + lb_cor_direct_ips: 172.31.10.19,172.31.10.20 + mms_traffic_net_name: int_mms_mms_traffic_net_2 + mms_traffic_net_cidr: 172.26.2.0/24 + mms_traffic_netmask: 255.255.255.0 + mms_traffic_net_gateway: 172.26.2.1 + mms_traffic_start: 172.26.2.3 + mms_traffic_end: 172.26.2.254 + mms_traffic_net_local_ip1: 172.26.2.3 + mms_traffic_net_local_ip2: 172.26.2.4 + mms_traffic_net_floating_ip: 172.26.2.5 + nems_internal_name: int_mms_nems_internal_net_2 + nems_internal_start: 172.26.6.3 + nems_internal_end: 172.26.6.254 + nems_internal_cidr: 172.26.6.0/24 + nems_internal_netmask: 255.255.255.0 + nems_internal_gateway: 172.26.6.1 + nems_traffic_name: int_mms_nems_traffic_net_2 + nems_traffic_start: 172.26.3.3 + nems_traffic_end: 172.26.3.254 + nems_traffic_cidr: 172.26.3.0/24 + nems_traffic_netmask: 255.255.255.0 + nems_traffic_gateway: 172.26.3.1 + nems_traffic_net_local_ip1: 172.26.3.3 + nems_traffic_net_local_ip2: 172.26.3.4 + nems_traffic_net_floating_ip: 172.26.3.5 + nems_user_web_name: int_mms_nems_web_net_2 + nems_user_web_start: 172.26.4.3 + nems_user_web_end: 172.26.4.254 + nems_user_web_cidr: 172.26.4.0/24 + nems_user_web_netmask: 255.255.255.0 + nems_user_web_gateway: 172.26.4.1 + nems_user_web_net_local_ip1: 172.26.4.3 + nems_user_web_net_local_ip2: 172.26.4.4 + nems_user_web_net_floating_ip: 172.26.4.5 + nems_imap_name: int_mms_nems_imap_net_2 + nems_imap_start: 172.26.7.3 + nems_imap_end: 172.26.7.254 + nems_imap_cidr: 172.26.7.0/24 + nems_imap_netmask: 255.255.255.0 + nems_imap_gateway: 172.26.7.1 + eca_traffic_name: int_mms_eca_traffic_net_2 + eca_traffic_cidr: 172.26.5.0/24 + eca_traffic_netmask: 255.255.255.0 + eca_traffic_net_gateway: 172.26.5.1 + eca_traffic_start: 172.26.5.3 + eca_traffic_end: 172.26.5.254 + eca_traffic_net_local_ip1: 172.26.5.3 + eca_traffic_net_local_ip2: 172.26.5.4 + eca_traffic_net_floating_ip: 172.26.5.5 + ha_net_name: int_mms_ha_net_2 + ha_net_cidr: 172.26.1.0/24 + ha_net_start: 172.26.1.3 + ha_net_end: 172.26.1.254 + ha_net_local_ip1: 172.26.1.3 + ha_net_local_ip2: 172.26.1.4 + lb_names: ZRDM1MMSC03ALB001,ZRDM1MMSC03ALB002 + lb_image_name: BIGIP-11.5.3.0.0.163 + lb_flavor_name: m1.xlarge + security_group_name: mmsc_security_group_1 + availability_zone_0: nova + mmsc_mms_traffic_net_ips: 172.26.2.11,172.26.2.12,172.26.2.13,172.26.2.14,172.26.2.15 + mmsc_oam_ips: 107.250.172.54,107.250.172.55,107.250.172.56,107.250.172.57,107.250.172.58 + mmsc_flavor: lc.4xlarge4 + mmsc_image: mmsc-6.0.2_v5 + mmsc_cinder_volume_size: 480 + nems_fe_flavor: m1.large2 + nems_fe_image: nems-2.1.2_v29 + nems_fe_names: ZRDM1MMSC03NFE001,ZRDM1MMSC03NFE002 + nems_fe_node_roles: FE0,FE1 + nems_fe_oam_ips: 107.250.172.64,107.250.172.65 + nems_fe_nems_traffic_net_ips: 172.26.3.11,172.26.3.12 + nems_fe_nems_user_web_net_ips: 172.26.4.11,172.26.4.12 + nems_fe_nems_internal_net_ips: 172.26.6.11,172.26.6.12 + nems_fe_nems_imap_net_ips: 172.26.7.11,172.26.7.12 + nems_be_names: ZRDM1MMSC03NBE001 + nems_be_node_roles: BE0 + nems_be_oam_ips: 107.250.172.66 + nems_be_nems_internal_net_ips: 172.26.6.13 + nems_be_nems_imap_net_ips: 172.26.7.13 + nems_be_flavor: m1.large2 + nems_be_image: nems-2.1.2_v29 + eca_trx_oam_ips: 107.250.172.70,107.250.172.71,107.250.172.72,107.250.172.73,107.250.172.74,107.250.172.75,107.250.172.76,107.250.172.77,107.250.172.78,107.250.172.79,107.250.172.80,107.250.172.81,107.250.172.82,107.250.172.83,107.250.172.84,107.250.172.85,107.250.172.86,107.250.172.87,107.250.172.88,107.250.172.89 + eca_trx_mgmt_ips: 172.25.137.202,172.25.137.203,172.25.137.204,172.25.137.205,172.25.137.206,172.25.137.207,172.25.137.208,172.25.137.209,172.25.137.210,172.25.137.211,172.25.137.212,172.25.137.213,172.25.137.214,172.25.137.215,172.25.137.216,172.25.137.217,172.25.137.218,172.25.137.219,172.25.137.220,172.25.137.221 + eca_trx_flavor: m1.xlarge + eca_trx_image: ECABASE + timezone: UTC + eca_trx_names: ZRDM1MMSC03TRX001,ZRDM1MMSC03TRX002,ZRDM1MMSC03TRX003,ZRDM1MMSC03TRX004,ZRDM1MMSC03TRX005,ZRDM1MMSC03TRX006,ZRDM1MMSC03TRX007,ZRDM1MMSC03TRX008,ZRDM1MMSC03TRX009,ZRDM1MMSC03TRX010,ZRDM1MMSC03TRX011,ZRDM1MMSC03TRX012,ZRDM1MMSC03TRX013,ZRDM1MMSC03TRX014,ZRDM1MMSC03TRX015,ZRDM1MMSC03TRX016,ZRDM1MMSC03TRX017,ZRDM1MMSC03TRX018,ZRDM1MMSC03TRX019,ZRDM1MMSC03TRX020 + eca_trx_eca_traffic_net_ips: 172.26.5.11,172.26.5.12,172.26.5.13,172.26.5.14,172.26.5.15,172.26.5.16,172.26.5.17,172.26.5.18,172.26.5.19,172.26.5.20,172.26.5.21,172.26.5.22,172.26.5.23,172.26.5.24,172.26.5.25,172.26.5.26,172.26.5.27,172.26.5.28,172.26.5.29,172.26.5.30 + mmsc_names: ZRDM1MMSC03MMS001,ZRDM1MMSC03MMS002,ZRDM1MMSC03MMS003,ZRDM1MMSC03MMS004,ZRDM1MMSC03MMS005 + nems_volume_size: 50 + nems_be_volume_size: 610 + MMSC_volume_type: Platinum + NEMS_FE_volume_type: Platinum + NEMS_BE_volume_type: Platinum + mmsc_core_virtual_server_ips: 172.31.10.21,172.31.10.22 + mmsc_core_snat_ips: 172.31.10.23,172.31.10.24,172.31.10.25,172.31.10.26,172.31.10.27 + mmsc_dmz_protected_virtual_server_ips: 107.239.14.21,107.239.14.22,107.239.14.23 + mmsc_dmz_protected_snat_ips: 107.239.14.24,107.239.14.25,107.239.14.26,107.239.14.27 + eca_mgmt_net_name: int_eca_mgmt_net_1 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/NETWORK_OUT.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/NETWORK_OUT.yaml new file mode 100644 index 0000000000..53efc5e36e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/NETWORK_OUT.yaml @@ -0,0 +1,76 @@ +heat_template_version: 2013-05-23 + +################################# +# +# Changes from MSO - 11/5/2015 +# - Parameter changes as below +# - CDLs for vmNames, IPs +# - aZone->availability_zone_0 +# - nwName->{nwRole}_net_name +# - nwID->{nwRole}_net_id +# - vmName->{vmType}_names +# - ips ->{vmType}_{nwRole}_ips +# - fips->{vmType}_{nwRole}_floating_ip +# - added replacement_policy: AUTO to all ports +# - added vnf_id for metadata to all servers +# - externalized security group resource +# - externalized eca_mgmt network +# +################################# + +description: > + HOT template that creates Security Group and ECA network + +parameters: + eca_mgmt_name: + type: string + label: eca management name + description: eca management name + eca_mgmt_start: + type: string + label: eca management start + description: eca management start + eca_mgmt_end: + type: string + label: eca management end + description: eca management end + eca_mgmt_cidr: + type: string + label: eca management cidr + description: eca management cidr + eca_mgmt_netmask: + type: string + label: ECA mgmt network subnet mask + description: ECA mgmt network subnet mask + security_group_name: + type: string + label: MMSC security group name + description: MMSC security group name + +resources: + mms_security_group: + type: OS::Neutron::SecurityGroup + properties: + description: mmsc security group + name: {get_param: security_group_name} + rules: [{"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0} + ] + eca_mgmt_net: + type: OS::Contrail::VirtualNetwork + properties: + name: {get_param: eca_mgmt_name} + + eca_mgmt_network_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: eca_mgmt_name} + allocation_pools: [{"start": {get_param: eca_mgmt_start}, "end": {get_param: eca_mgmt_end}}] + cidr: {get_param: eca_mgmt_cidr} + #enable_dhcp: false + #gateway_ip: null + network_id: {get_resource: eca_mgmt_net} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/SG_ECA_MGMT.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/SG_ECA_MGMT.yaml new file mode 100644 index 0000000000..6e68fd8783 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/SG_ECA_MGMT.yaml @@ -0,0 +1,81 @@ +heat_template_version: 2013-05-23 + +################################# +# +# Changes from MSO - 11/5/2015 +# - Parameter changes as below +# - CDLs for vmNames, IPs +# - aZone->availability_zone_0 +# - nwName->{nwRole}_net_name +# - nwID->{nwRole}_net_id +# - vmName->{vmType}_names +# - ips ->{vmType}_{nwRole}_ips +# - fips->{vmType}_{nwRole}_floating_ip +# - added replacement_policy: AUTO to all ports +# - added vnf_id for metadata to all servers +# - externalized security group resource +# - externalized eca_mgmt network +# +################################# + +description: > + HOT template that creates Security Group and ECA network + +parameters: + eca_mgmt_name: + type: string + label: eca management name + description: eca management name + eca_mgmt_start: + type: string + label: eca management start + description: eca management start + eca_mgmt_end: + type: string + label: eca management end + description: eca management end + eca_mgmt_cidr: + type: string + label: eca management cidr + description: eca management cidr + eca_mgmt_netmask: + type: string + label: ECA mgmt network subnet mask + description: ECA mgmt network subnet mask + security_group_name: + type: string + label: MMSC security group name + description: MMSC security group name + +resources: + mms_traffic_artifact: + type: OS::Contrail::VirtualNetwork + properties: + property_get_file_name: { get_file: "file:///art.sh" } + + mms_security_group: + type: OS::Neutron::SecurityGroup + properties: + description: mmsc security group + name: {get_param: security_group_name} + rules: [{"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0} + ] + eca_mgmt_net: + type: OS::Contrail::VirtualNetwork + properties: + name: {get_param: eca_mgmt_name} + + eca_mgmt_network_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: eca_mgmt_name} + allocation_pools: [{"start": {get_param: eca_mgmt_start}, "end": {get_param: eca_mgmt_end}}] + cidr: {get_param: eca_mgmt_cidr} + #enable_dhcp: false + #gateway_ip: null + network_id: {get_resource: eca_mgmt_net} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/VOLUME.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/VOLUME.yaml new file mode 100644 index 0000000000..53efc5e36e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/VOLUME.yaml @@ -0,0 +1,76 @@ +heat_template_version: 2013-05-23 + +################################# +# +# Changes from MSO - 11/5/2015 +# - Parameter changes as below +# - CDLs for vmNames, IPs +# - aZone->availability_zone_0 +# - nwName->{nwRole}_net_name +# - nwID->{nwRole}_net_id +# - vmName->{vmType}_names +# - ips ->{vmType}_{nwRole}_ips +# - fips->{vmType}_{nwRole}_floating_ip +# - added replacement_policy: AUTO to all ports +# - added vnf_id for metadata to all servers +# - externalized security group resource +# - externalized eca_mgmt network +# +################################# + +description: > + HOT template that creates Security Group and ECA network + +parameters: + eca_mgmt_name: + type: string + label: eca management name + description: eca management name + eca_mgmt_start: + type: string + label: eca management start + description: eca management start + eca_mgmt_end: + type: string + label: eca management end + description: eca management end + eca_mgmt_cidr: + type: string + label: eca management cidr + description: eca management cidr + eca_mgmt_netmask: + type: string + label: ECA mgmt network subnet mask + description: ECA mgmt network subnet mask + security_group_name: + type: string + label: MMSC security group name + description: MMSC security group name + +resources: + mms_security_group: + type: OS::Neutron::SecurityGroup + properties: + description: mmsc security group + name: {get_param: security_group_name} + rules: [{"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0} + ] + eca_mgmt_net: + type: OS::Contrail::VirtualNetwork + properties: + name: {get_param: eca_mgmt_name} + + eca_mgmt_network_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: eca_mgmt_name} + allocation_pools: [{"start": {get_param: eca_mgmt_start}, "end": {get_param: eca_mgmt_end}}] + cidr: {get_param: eca_mgmt_cidr} + #enable_dhcp: false + #gateway_ip: null + network_id: {get_resource: eca_mgmt_net} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/VOLUME_OUT.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/VOLUME_OUT.yaml new file mode 100644 index 0000000000..53efc5e36e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/VOLUME_OUT.yaml @@ -0,0 +1,76 @@ +heat_template_version: 2013-05-23 + +################################# +# +# Changes from MSO - 11/5/2015 +# - Parameter changes as below +# - CDLs for vmNames, IPs +# - aZone->availability_zone_0 +# - nwName->{nwRole}_net_name +# - nwID->{nwRole}_net_id +# - vmName->{vmType}_names +# - ips ->{vmType}_{nwRole}_ips +# - fips->{vmType}_{nwRole}_floating_ip +# - added replacement_policy: AUTO to all ports +# - added vnf_id for metadata to all servers +# - externalized security group resource +# - externalized eca_mgmt network +# +################################# + +description: > + HOT template that creates Security Group and ECA network + +parameters: + eca_mgmt_name: + type: string + label: eca management name + description: eca management name + eca_mgmt_start: + type: string + label: eca management start + description: eca management start + eca_mgmt_end: + type: string + label: eca management end + description: eca management end + eca_mgmt_cidr: + type: string + label: eca management cidr + description: eca management cidr + eca_mgmt_netmask: + type: string + label: ECA mgmt network subnet mask + description: ECA mgmt network subnet mask + security_group_name: + type: string + label: MMSC security group name + description: MMSC security group name + +resources: + mms_security_group: + type: OS::Neutron::SecurityGroup + properties: + description: mmsc security group + name: {get_param: security_group_name} + rules: [{"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0} + ] + eca_mgmt_net: + type: OS::Contrail::VirtualNetwork + properties: + name: {get_param: eca_mgmt_name} + + eca_mgmt_network_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: eca_mgmt_name} + allocation_pools: [{"start": {get_param: eca_mgmt_start}, "end": {get_param: eca_mgmt_end}}] + cidr: {get_param: eca_mgmt_cidr} + #enable_dhcp: false + #gateway_ip: null + network_id: {get_resource: eca_mgmt_net} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/art.sh b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/art.sh new file mode 100644 index 0000000000..186d1c34fb --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/art.sh @@ -0,0 +1 @@ +heat stack-create vMME -e vmme_small.env -f vmme_small.yml diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/cmaui.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/cmaui.env new file mode 100644 index 0000000000..2e6012d1c5 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/cmaui.env @@ -0,0 +1,15 @@ +parameters: + cmaui_names: ZRDM1MMSC02CMI001,ZRDM1MMSC02CMI002 + cmaui_flavor: m1.large + cmaui_image: cmaui-5.0.2.5_v25 + cmaui_cinder_volume_size: 55 + oam_net_name: oam_protected_net_0 + oam_network_netmask: 255.255.254.0 + oam_network_gateway: 107.250.172.1 + external_dns: 155.165.201.250 + external_ntp: 155.165.194.100 + security_group_name: mmsc_security_group_1 + availability_zone_0: nova + timezone: UTC + cmaui_oam_ips: 107.250.172.42,107.250.172.43 + CMAUI_volume_type: Platinum \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/cmaui.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/cmaui.yml new file mode 100644 index 0000000000..3d757b1631 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/cmaui.yml @@ -0,0 +1,179 @@ +heat_template_version: 2013-05-23 + +################################# +# +# Changes from MSO 01/26/2016 +# Updated per ECOMP feedback +# +################################# + +description: cmaui server template for vMMSC + +parameters: + vnf_id: + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-CMAUI_id + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_cinder_volume_size: + type: number + label: CMAUI Cinder volume size + description: the size of the CMAUI Cinder volume + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + oam_net_name: + type: string + description: UID of OAM network + oam_network_netmask: + type: string + label: oam network netmask + description: oam network gateway + oam_network_gateway: + type: string + label: oam network gateway + description: oam network gateway + external_dns: + type: string + label: dns server + description: dns server + external_ntp: + type: string + label: ntp server + description: ntp server + security_group_name: + type: string + label: security group name + description: the name of security group + timezone: + type: string + label: timezone + description: timezone + cmaui_oam_ips: + type: comma_delimited_list + label: CMAUI oam_net IP addresses + description: CMAUI oam_net IP addresses + CMAUI_volume_type: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + +resources: + server_cmaui: + type: eca_oam.yaml + properties: + cmaui_name: { get_param: [cmaui_names, 0]} + cmaui_image: { get_param: cmaui_image } + availability_zone_0: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_0 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + cmaui.mgmt.ip=${cmaui.mgmt.ip} + cmaui.mgmt.netmask=${cmaui.mgmt.netmask} + cmaui.mgmt.gateway=${cmaui.mgmt.gateway} + cmaui.external.dns=${cmaui.external.dns} + cmaui.external.ntp=${cmaui.external.ntp} + cmaui.node=${cmaui.node} + cmaui.timezone=${cmaui.timezone} + params: + ${cmaui.mgmt.ip}: {get_param: [cmaui_oam_ips, 0]} + ${cmaui.mgmt.netmask}: {get_param: oam_network_netmask} + ${cmaui.mgmt.gateway}: {get_param: oam_network_gateway} + ${cmaui.external.dns}: {get_param: external_dns} + ${cmaui.external.ntp}: {get_param: external_ntp} + ${cmaui.node}: {get_param: [cmaui_names, 0]} + ${cmaui.timezone}: {get_param: timezone} + user_data_format: RAW + + cmaui_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: cmaui_cinder_volume_size} + volume_type: {get_param: CMAUI_volume_type} + + cmaui_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: cmaui_volume} + instance_uuid: {get_resource: server_cmaui} + + cmaui_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_cmaui1: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 1]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui1_port_0 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + cmaui.mgmt.ip=${cmaui.mgmt.ip} + cmaui.mgmt.netmask=${cmaui.mgmt.netmask} + cmaui.mgmt.gateway=${cmaui.mgmt.gateway} + cmaui.external.dns=${cmaui.external.dns} + cmaui.external.ntp=${cmaui.external.ntp} + cmaui.node=${cmaui.node} + cmaui.timezone=${cmaui.timezone} + params: + ${cmaui.mgmt.ip}: {get_param: [cmaui_oam_ips, 1]} + ${cmaui.mgmt.netmask}: {get_param: oam_network_netmask} + ${cmaui.mgmt.gateway}: {get_param: oam_network_gateway} + ${cmaui.external.dns}: {get_param: external_dns} + ${cmaui.external.ntp}: {get_param: external_ntp} + ${cmaui.node}: {get_param: [cmaui_names, 1]} + ${cmaui.timezone}: {get_param: timezone} + user_data_format: RAW + + cmaui1_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: cmaui_cinder_volume_size} + volume_type: {get_param: CMAUI_volume_type} + + cmaui1_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: cmaui1_volume} + instance_uuid: {get_resource: server_cmaui1} + + cmaui1_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 1]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + +outputs: + expose_1: + description: the pcrf_server + value: { get_resource: cmaui_volume } + expose_2: + description: the pcrf_server + value: { get_resource: cmaui1_volume } diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/cmaui_net.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/cmaui_net.yaml new file mode 100644 index 0000000000..53efc5e36e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/cmaui_net.yaml @@ -0,0 +1,76 @@ +heat_template_version: 2013-05-23 + +################################# +# +# Changes from MSO - 11/5/2015 +# - Parameter changes as below +# - CDLs for vmNames, IPs +# - aZone->availability_zone_0 +# - nwName->{nwRole}_net_name +# - nwID->{nwRole}_net_id +# - vmName->{vmType}_names +# - ips ->{vmType}_{nwRole}_ips +# - fips->{vmType}_{nwRole}_floating_ip +# - added replacement_policy: AUTO to all ports +# - added vnf_id for metadata to all servers +# - externalized security group resource +# - externalized eca_mgmt network +# +################################# + +description: > + HOT template that creates Security Group and ECA network + +parameters: + eca_mgmt_name: + type: string + label: eca management name + description: eca management name + eca_mgmt_start: + type: string + label: eca management start + description: eca management start + eca_mgmt_end: + type: string + label: eca management end + description: eca management end + eca_mgmt_cidr: + type: string + label: eca management cidr + description: eca management cidr + eca_mgmt_netmask: + type: string + label: ECA mgmt network subnet mask + description: ECA mgmt network subnet mask + security_group_name: + type: string + label: MMSC security group name + description: MMSC security group name + +resources: + mms_security_group: + type: OS::Neutron::SecurityGroup + properties: + description: mmsc security group + name: {get_param: security_group_name} + rules: [{"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0} + ] + eca_mgmt_net: + type: OS::Contrail::VirtualNetwork + properties: + name: {get_param: eca_mgmt_name} + + eca_mgmt_network_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: eca_mgmt_name} + allocation_pools: [{"start": {get_param: eca_mgmt_start}, "end": {get_param: eca_mgmt_end}}] + cidr: {get_param: eca_mgmt_cidr} + #enable_dhcp: false + #gateway_ip: null + network_id: {get_resource: eca_mgmt_net} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/eca_oam.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/eca_oam.env new file mode 100644 index 0000000000..f9991722b3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/eca_oam.env @@ -0,0 +1,20 @@ +parameters: + eca_names: ZRDM1MMSC02OAM001,ZRDM1MMSC02OAM002 + arb_names: ZRDM1MMSC02ARB001 + oam_image_name: ECABASE + oam_flavor: lc.xlarge4 + arbiter_flavor: m1.large2 + availability_zone_0: nova + oam_net_name: oam_protected_net_0 + eca_mgmt_net_name: int_mms_eca_mgmt_net_1 + eca_oam_ips: 107.250.172.44,107.250.172.45 + eca_eca_mgmt_ips: 172.25.137.242,172.25.137.243 + eca_oam_gateway: 107.250.172.1 + arb_oam_ips: 107.250.172.46 + arb_eca_mgmt_ips: 172.25.137.244 + security_group_name: mmsc_security_group_1 + oam_volume_size: 1800 + arb_volume_size: 40 + swift_eca_url: http://object-store.rdm2.cci.com:8080/v1/AUTH_1bbab536a19b4756926e7d0ec1eb543c/eca + ECA_OAM_volume_type: Platinum + ARB_volume_type: Platinum diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/eca_oam.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/eca_oam.yaml new file mode 100644 index 0000000000..243bccf3d0 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/eca_oam.yaml @@ -0,0 +1,453 @@ +heat_template_version: 2013-05-23 + +########################################################## +# +# Changes from MSO +# - Updated per ECOMP Feedback +# +# +########################################################## + +description: This stack creates two ECA OAM VM and one ARB VM + +parameters: + vnf_id: + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-ECA_id + eca_names: + type: comma_delimited_list + label: oam servers names + description: the names of the OAM1,OAM2 VM instances + cmaui_name: + type: comma_delimited_list + label: oam servers names + cmaui_image: + type: comma_delimited_list + label: oam servers names + description: the names of the OAM1,OAM2 VM instances + networks: + type: string + label: internal network name + description: the name of the internal network + flavor: + type: string + label: internal network name + description: the name of the internal network + metadata: + type: string + label: internal network name + description: the name of the internal network + user_data: + type: string + label: internal network name + description: the name of the internal network + user_data_format: + type: string + label: internal network name + description: the name of the internal network + cmaui_names: + type: comma_delimited_list + label: oam servers names + description: the names of the OAM1,OAM2 VM instances + cmaui_flavor: + type: comma_delimited_list + label: oam servers names + description: the names of the OAM1,OAM2 VM instances + arb_names: + type: comma_delimited_list + label: arbiter server names + description: the names of the arbiter VM instances + oam_image_name: + type: string + label: image name + description: the OAM image name + oam_flavor: + type: string + label: flavor name + description: OAM flavor name + arbiter_flavor: + type: string + label: flavor name + description: arbiter flavor name + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + oam_net_name: + type: string + label: oam network name + description: the name of the oam network + eca_mgmt_net_name: + type: string + label: internal network name + description: the name of the internal network + eca_oam_ips: + type: comma_delimited_list + label: oam network ips + description: the ips of oam networks for eca VM + eca_eca_mgmt_ips: + type: comma_delimited_list + label: eca_mgmt network ips for eca VM + description: internal eca_mgmt network ips for eca VM + arb_oam_ips: + type: comma_delimited_list + label: oam network ips for arb VM + description: oam network ips for eca VM + arb_eca_mgmt_ips: + type: comma_delimited_list + label: eca_mgmt network ips + description: internal eca_mgmt network ips for arb VM + eca_oam_gateway: + type: string + label: oam network gateway + description: oam network gateway + security_group_name: + type: string + label: security group name + description: the name of security group + oam_volume_size: + type: number + label: volume size + description: the size of the OAM volume + arb_volume_size: + type: number + label: volume size + description: the size of the ARB volume + swift_eca_url: + type: string + label: Swift URL + description: Base URL for eca swift object store + ECA_OAM_volume_type: + type: string + label: eca oam vm volume type + description: the name of the target volume backend + ARB_volume_type: + type: string + label: arb vm volume type + description: the name of the target volume backend + +resources: + server_cmaui_nested: + type: eca_oam_nested.yaml + properties: + cmaui_name: { get_param: [cmaui_names, 0]} + cmaui_image: { get_param: cmaui_image } + availability_zone_0: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_0 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + cmaui.mgmt.ip=${cmaui.mgmt.ip} + cmaui.mgmt.netmask=${cmaui.mgmt.netmask} + cmaui.mgmt.gateway=${cmaui.mgmt.gateway} + cmaui.external.dns=${cmaui.external.dns} + cmaui.external.ntp=${cmaui.external.ntp} + cmaui.node=${cmaui.node} + cmaui.timezone=${cmaui.timezone} + params: + ${cmaui.mgmt.ip}: {get_param: [cmaui_oam_ips, 0]} + ${cmaui.mgmt.netmask}: {get_param: oam_network_netmask} + ${cmaui.mgmt.gateway}: {get_param: oam_network_gateway} + ${cmaui.external.dns}: {get_param: external_dns} + ${cmaui.external.ntp}: {get_param: external_ntp} + ${cmaui.node}: {get_param: [cmaui_names, 0]} + ${cmaui.timezone}: {get_param: timezone} + user_data_format: RAW + + oam1_instance: + type: OS::Nova::Server + properties: + name: {get_param: [eca_names, 0]} + image: {get_param: oam_image_name} + flavor: {get_param: oam_flavor} + availability_zone: {get_param: availability_zone_0} + networks: + - port: {get_resource: oam1_int_port} + - port: {get_resource: oam1_mgmt_port} + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + sed -i s/HOSTNAME.*/"HOSTNAME=oam1_hostname"/g /etc/sysconfig/network + eth1_ip_address='oam1_mgt_ip' + eth1_gateway='oam_gateway' + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + mkdir /etc/puppet/files/roles/transcoder + mkdir /etc/puppet/files/roles/oam_primary + curl swift_url/etc/puppet/manifests/roles/oam_primary.pp > /etc/puppet/manifests/roles/oam_primary.pp + curl swift_url/etc/puppet/manifests/roles/transcoder.pp > /etc/puppet/manifests/roles/transcoder.pp + curl swift_url/etc/puppet/files/roles/oam_primary/config.yaml > /etc/puppet/files/roles/oam_primary/config.yaml + curl swift_url/etc/puppet/files/roles/transcoder/config.yaml > /etc/puppet/files/roles/transcoder/config.yaml + curl swift_url/etc/puppet/files/roles/transcoder/hpm.conf > /etc/puppet/files/roles/transcoder/hpm.conf + curl swift_url/etc/puppet/files/roles/transcoder/trx.conf > /etc/puppet/files/roles/transcoder/trx.conf + curl swift_url/etc/puppet/files/roles/transcoder/plugins-mo.conf > /etc/puppet/files/roles/transcoder/plugins-mo.conf + curl swift_url/etc/puppet/files/global/11-customer.conf > /etc/puppet/files/global/11-customer.conf + curl swift_url/etc/puppet/manifests/site.pp > /etc/puppet/manifests/site.pp + curl swift_url/scripts/van-init-replicaset > /usr/sbin/van-init-replicaset + van-role oam_primary > /root/startup-van-role.out + curl swift_url/scripts/fdisk-keystrokes > /root/fdisk-keystrokes + fdisk /dev/vdb < /root/fdisk-keystrokes + curl swift_url/scripts/os-conf-cinder-vol > /root/os-conf-cinder-vol + chmod 755 /root/os-conf-cinder-vol + /root/os-conf-cinder-vol 2>> /tmp/cinder_volume.log + params: + oam1_mgt_ip: {get_param: [eca_oam_ips, 0] } + oam_gateway: {get_param: eca_oam_gateway } + oam1_hostname: {get_param: [eca_names, 0]} + swift_url: {get_param: swift_eca_url} + + oam1_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [eca_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + cmaui_port_0: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [eca_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + oam1_int_port: + type: OS::Neutron::Port + properties: + network: {get_param: eca_mgmt_net_name} + fixed_ips: [{"ip_address": {get_param: [eca_eca_mgmt_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + oam1_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: oam_volume_size} + volume_type: {get_param: ECA_OAM_volume_type} + + oam1_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: oam1_volume} + instance_uuid: {get_resource: oam1_instance} + + oam2_instance: + type: OS::Nova::Server + properties: + name: {get_param: [eca_names, 1]} + image: {get_param: oam_image_name} + flavor: {get_param: oam_flavor} + availability_zone: {get_param: availability_zone_0} + networks: + - port: {get_resource: oam2_int_port} + - port: {get_resource: oam2_mgmt_port} + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + sed -i s/HOSTNAME.*/"HOSTNAME=oam2_hostname"/g /etc/sysconfig/network + eth1_ip_address='oam2_mgt_ip' + eth1_gateway='oam_gateway' + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + curl swift_url/etc/puppet/manifests/roles/oam_secondary.pp > /etc/puppet/manifests/roles/oam_secondary.pp + curl swift_url/etc/puppet/files/global/config.yaml > /etc/puppet/files/global/config.yaml + curl swift_url/etc/puppet/files/global/11-customer.conf > /etc/puppet/files/global/11-customer.conf + van-role oam_secondary > /root/startup-van-role.out + curl swift_url/scripts/fdisk-keystrokes > /root/fdisk-keystrokes + fdisk /dev/vdb < /root/fdisk-keystrokes + curl swift_url/scripts/os-conf-cinder-vol > /root/os-conf-cinder-vol + chmod 755 /root/os-conf-cinder-vol + /root/os-conf-cinder-vol 2>> /tmp/cinder_volume.log + + params: + oam2_mgt_ip: {get_param: [eca_oam_ips, 1] } + oam2_hostname: {get_param: [eca_names, 1]} + swift_url: {get_param: swift_eca_url} + oam_gateway: {get_param: eca_oam_gateway } + + oam2_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [eca_oam_ips, 1]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + oam2_int_port: + type: OS::Neutron::Port + properties: + network: {get_param: eca_mgmt_net_name} + fixed_ips: [{"ip_address": {get_param: [eca_eca_mgmt_ips, 1]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + oam2_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: oam_volume_size} + volume_type: {get_param: ECA_OAM_volume_type} + + oam2_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: oam2_volume} + instance_uuid: {get_resource: oam2_instance} + + arb_instance: + type: OS::Nova::Server + properties: + name: {get_param: [arb_names, 0]} + image: {get_param: oam_image_name} + flavor: {get_param: arbiter_flavor} + availability_zone: {get_param: availability_zone_0} + networks: + - port: {get_resource: arb_int_port} + - port: {get_resource: arb_mgmt_port} + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + sed -i s/HOSTNAME.*/"HOSTNAME=arb_hostname"/g /etc/sysconfig/network + eth1_ip_address='arb_mgt_ip' + eth1_gateway='oam_gateway' + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + curl swift_url/etc/puppet/manifests/roles/oam_arbiter.pp > /etc/puppet/manifests/roles/oam_arbiter.pp + curl swift_url/etc/puppet/files/global/config.yaml > /etc/puppet/files/global/config.yaml + curl swift_url/etc/puppet/files/global/11-customer.conf > /etc/puppet/files/global/11-customer.conf + van-role oam_arbiter > /root/startup-van-role.out + curl swift_url/scripts/fdisk-keystrokes > /root/fdisk-keystrokes + fdisk /dev/vdb < /root/fdisk-keystrokes + curl swift_url/scripts/os-conf-cinder-vol > /root/os-conf-cinder-vol + chmod 755 /root/os-conf-cinder-vol + /root/os-conf-cinder-vol 2>> /tmp/cinder_volume.log + params: + arb_mgt_ip: {get_param: [arb_oam_ips, 0] } + arb_hostname: {get_param: [arb_names, 0]} + swift_url: {get_param: swift_eca_url} + oam_gateway: {get_param: eca_oam_gateway } + + arb_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [arb_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + arb_int_port: + type: OS::Neutron::Port + properties: + network: {get_param: eca_mgmt_net_name} + fixed_ips: [{"ip_address": {get_param: [arb_eca_mgmt_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + arb_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: arb_volume_size} + volume_type: {get_param: ARB_volume_type} + arb_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: arb_volume} + instance_uuid: {get_resource: arb_instance} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/eca_oam_nested.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/eca_oam_nested.yaml new file mode 100644 index 0000000000..c8b9527555 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/eca_oam_nested.yaml @@ -0,0 +1,406 @@ +heat_template_version: 2013-05-23 + +########################################################## +# +# Changes from MSO +# - Updated per ECOMP Feedback +# +# +########################################################## + +description: This stack creates two ECA OAM VM and one ARB VM + +parameters: + vnf_id: + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-ECA_id + cmaui_name: + type: comma_delimited_list + label: oam servers names + cmaui_image: + type: comma_delimited_list + label: oam servers names + description: the names of the OAM1,OAM2 VM instances + networks: + type: string + label: internal network name + description: the name of the internal network + flavor: + type: string + label: internal network name + description: the name of the internal network + metadata: + type: string + label: internal network name + description: the name of the internal network + user_data: + type: string + label: internal network name + description: the name of the internal network + user_data_format: + type: string + label: internal network name + description: the name of the internal network + eca_names: + type: comma_delimited_list + label: oam servers names + description: the names of the OAM1,OAM2 VM instances + arb_names: + type: comma_delimited_list + label: arbiter server names + description: the names of the arbiter VM instances + oam_image_name: + type: string + label: image name + description: the OAM image name + oam_flavor: + type: string + label: flavor name + description: OAM flavor name + arbiter_flavor: + type: string + label: flavor name + description: arbiter flavor name + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + oam_net_name: + type: string + label: oam network name + description: the name of the oam network + eca_mgmt_net_name: + type: string + label: internal network name + description: the name of the internal network + eca_oam_ips: + type: comma_delimited_list + label: oam network ips + description: the ips of oam networks for eca VM + eca_eca_mgmt_ips: + type: comma_delimited_list + label: eca_mgmt network ips for eca VM + description: internal eca_mgmt network ips for eca VM + arb_oam_ips: + type: comma_delimited_list + label: oam network ips for arb VM + description: oam network ips for eca VM + arb_eca_mgmt_ips: + type: comma_delimited_list + label: eca_mgmt network ips + description: internal eca_mgmt network ips for arb VM + eca_oam_gateway: + type: string + label: oam network gateway + description: oam network gateway + security_group_name: + type: string + label: security group name + description: the name of security group + oam_volume_size: + type: number + label: volume size + description: the size of the OAM volume + arb_volume_size: + type: number + label: volume size + description: the size of the ARB volume + swift_eca_url: + type: string + label: Swift URL + description: Base URL for eca swift object store + ECA_OAM_volume_type: + type: string + label: eca oam vm volume type + description: the name of the target volume backend + ARB_volume_type: + type: string + label: arb vm volume type + description: the name of the target volume backend + +resources: + oam1_instance: + type: OS::Nova::Server + properties: + name: {get_param: [eca_names, 0]} + image: {get_param: oam_image_name} + flavor: {get_param: oam_flavor} + availability_zone: {get_param: availability_zone_0} + networks: + - port: {get_resource: oam1_int_port} + - port: {get_resource: oam1_mgmt_port} + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + sed -i s/HOSTNAME.*/"HOSTNAME=oam1_hostname"/g /etc/sysconfig/network + eth1_ip_address='oam1_mgt_ip' + eth1_gateway='oam_gateway' + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + mkdir /etc/puppet/files/roles/transcoder + mkdir /etc/puppet/files/roles/oam_primary + curl swift_url/etc/puppet/manifests/roles/oam_primary.pp > /etc/puppet/manifests/roles/oam_primary.pp + curl swift_url/etc/puppet/manifests/roles/transcoder.pp > /etc/puppet/manifests/roles/transcoder.pp + curl swift_url/etc/puppet/files/roles/oam_primary/config.yaml > /etc/puppet/files/roles/oam_primary/config.yaml + curl swift_url/etc/puppet/files/roles/transcoder/config.yaml > /etc/puppet/files/roles/transcoder/config.yaml + curl swift_url/etc/puppet/files/roles/transcoder/hpm.conf > /etc/puppet/files/roles/transcoder/hpm.conf + curl swift_url/etc/puppet/files/roles/transcoder/trx.conf > /etc/puppet/files/roles/transcoder/trx.conf + curl swift_url/etc/puppet/files/roles/transcoder/plugins-mo.conf > /etc/puppet/files/roles/transcoder/plugins-mo.conf + curl swift_url/etc/puppet/files/global/11-customer.conf > /etc/puppet/files/global/11-customer.conf + curl swift_url/etc/puppet/manifests/site.pp > /etc/puppet/manifests/site.pp + curl swift_url/scripts/van-init-replicaset > /usr/sbin/van-init-replicaset + van-role oam_primary > /root/startup-van-role.out + curl swift_url/scripts/fdisk-keystrokes > /root/fdisk-keystrokes + fdisk /dev/vdb < /root/fdisk-keystrokes + curl swift_url/scripts/os-conf-cinder-vol > /root/os-conf-cinder-vol + chmod 755 /root/os-conf-cinder-vol + /root/os-conf-cinder-vol 2>> /tmp/cinder_volume.log + params: + oam1_mgt_ip: {get_param: [eca_oam_ips, 0] } + oam_gateway: {get_param: eca_oam_gateway } + oam1_hostname: {get_param: [eca_names, 0]} + swift_url: {get_param: swift_eca_url} + + oam1_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [eca_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + oam1_int_port: + type: OS::Neutron::Port + properties: + network: {get_param: eca_mgmt_net_name} + fixed_ips: [{"ip_address": {get_param: [eca_eca_mgmt_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + oam1_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: oam_volume_size} + volume_type: {get_param: ECA_OAM_volume_type} + + oam1_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: oam1_volume} + instance_uuid: {get_resource: oam1_instance} + + oam2_instance: + type: OS::Nova::Server + properties: + name: {get_param: [eca_names, 1]} + image: {get_param: oam_image_name} + flavor: {get_param: oam_flavor} + availability_zone: {get_param: availability_zone_0} + networks: + - port: {get_resource: oam2_int_port} + - port: {get_resource: oam2_mgmt_port} + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + sed -i s/HOSTNAME.*/"HOSTNAME=oam2_hostname"/g /etc/sysconfig/network + eth1_ip_address='oam2_mgt_ip' + eth1_gateway='oam_gateway' + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + curl swift_url/etc/puppet/manifests/roles/oam_secondary.pp > /etc/puppet/manifests/roles/oam_secondary.pp + curl swift_url/etc/puppet/files/global/config.yaml > /etc/puppet/files/global/config.yaml + curl swift_url/etc/puppet/files/global/11-customer.conf > /etc/puppet/files/global/11-customer.conf + van-role oam_secondary > /root/startup-van-role.out + curl swift_url/scripts/fdisk-keystrokes > /root/fdisk-keystrokes + fdisk /dev/vdb < /root/fdisk-keystrokes + curl swift_url/scripts/os-conf-cinder-vol > /root/os-conf-cinder-vol + chmod 755 /root/os-conf-cinder-vol + /root/os-conf-cinder-vol 2>> /tmp/cinder_volume.log + + params: + oam2_mgt_ip: {get_param: [eca_oam_ips, 1] } + oam2_hostname: {get_param: [eca_names, 1]} + swift_url: {get_param: swift_eca_url} + oam_gateway: {get_param: eca_oam_gateway } + + oam2_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [eca_oam_ips, 1]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + oam2_int_port: + type: OS::Neutron::Port + properties: + network: {get_param: eca_mgmt_net_name} + fixed_ips: [{"ip_address": {get_param: [eca_eca_mgmt_ips, 1]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + oam2_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: oam_volume_size} + volume_type: {get_param: ECA_OAM_volume_type} + + oam2_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: oam2_volume} + instance_uuid: {get_resource: oam2_instance} + + arb_instance: + type: OS::Nova::Server + properties: + name: {get_param: [arb_names, 0]} + image: {get_param: oam_image_name} + flavor: {get_param: arbiter_flavor} + availability_zone: {get_param: availability_zone_0} + networks: + - port: {get_resource: arb_int_port} + - port: {get_resource: arb_mgmt_port} + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + sed -i s/HOSTNAME.*/"HOSTNAME=arb_hostname"/g /etc/sysconfig/network + eth1_ip_address='arb_mgt_ip' + eth1_gateway='oam_gateway' + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + curl swift_url/etc/puppet/manifests/roles/oam_arbiter.pp > /etc/puppet/manifests/roles/oam_arbiter.pp + curl swift_url/etc/puppet/files/global/config.yaml > /etc/puppet/files/global/config.yaml + curl swift_url/etc/puppet/files/global/11-customer.conf > /etc/puppet/files/global/11-customer.conf + van-role oam_arbiter > /root/startup-van-role.out + curl swift_url/scripts/fdisk-keystrokes > /root/fdisk-keystrokes + fdisk /dev/vdb < /root/fdisk-keystrokes + curl swift_url/scripts/os-conf-cinder-vol > /root/os-conf-cinder-vol + chmod 755 /root/os-conf-cinder-vol + /root/os-conf-cinder-vol 2>> /tmp/cinder_volume.log + params: + arb_mgt_ip: {get_param: [arb_oam_ips, 0] } + arb_hostname: {get_param: [arb_names, 0]} + swift_url: {get_param: swift_eca_url} + oam_gateway: {get_param: eca_oam_gateway } + + arb_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [arb_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + arb_int_port: + type: OS::Neutron::Port + properties: + network: {get_param: eca_mgmt_net_name} + fixed_ips: [{"ip_address": {get_param: [arb_eca_mgmt_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + arb_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: arb_volume_size} + volume_type: {get_param: ARB_volume_type} + arb_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: arb_volume} + instance_uuid: {get_resource: arb_instance} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/nested1.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/nested1.yaml new file mode 100644 index 0000000000..a0c56d9da7 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/nested1.yaml @@ -0,0 +1,430 @@ +heat_template_version: 2013-05-23 + +########################################################## +# +# Changes from MSO +# - Updated per ECOMP Feedback +# +# +########################################################## + +description: This stack creates two ECA OAM VM and one ARB VM + +parameters: + vnf_id: + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-ECA_id + cmaui_names: + type: comma_delimited_list + label: oam servers names + description: the names of the OAM1,OAM2 VM instances + cmaui_image: + type: comma_delimited_list + label: oam servers names + description: the names of the OAM1,OAM2 VM instances + cmaui_flavor: + type: comma_delimited_list + label: oam servers names + description: the names of the OAM1,OAM2 VM instances + eca_names: + type: comma_delimited_list + label: oam servers names + description: the names of the OAM1,OAM2 VM instances + arb_names: + type: comma_delimited_list + label: arbiter server names + description: the names of the arbiter VM instances + oam_image_name: + type: string + label: image name + description: the OAM image name + oam_flavor: + type: string + label: flavor name + description: OAM flavor name + arbiter_flavor: + type: string + label: flavor name + description: arbiter flavor name + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + oam_net_name: + type: string + label: oam network name + description: the name of the oam network + eca_mgmt_net_name: + type: string + label: internal network name + description: the name of the internal network + eca_oam_ips: + type: comma_delimited_list + label: oam network ips + description: the ips of oam networks for eca VM + eca_eca_mgmt_ips: + type: comma_delimited_list + label: eca_mgmt network ips for eca VM + description: internal eca_mgmt network ips for eca VM + arb_oam_ips: + type: comma_delimited_list + label: oam network ips for arb VM + description: oam network ips for eca VM + arb_eca_mgmt_ips: + type: comma_delimited_list + label: eca_mgmt network ips + description: internal eca_mgmt network ips for arb VM + eca_oam_gateway: + type: string + label: oam network gateway + description: oam network gateway + security_group_name: + type: string + label: security group name + description: the name of security group + oam_volume_size: + type: number + label: volume size + description: the size of the OAM volume + arb_volume_size: + type: number + label: volume size + description: the size of the ARB volume + swift_eca_url: + type: string + label: Swift URL + description: Base URL for eca swift object store + ECA_OAM_volume_type: + type: string + label: eca oam vm volume type + description: the name of the target volume backend + ARB_volume_type: + type: string + label: arb vm volume type + description: the name of the target volume backend + +resources: + server_cmaui_nested: + type: eca_oam_nested.yaml + properties: + cmaui_name: { get_param: [cmaui_names, 0]} + cmaui_image: { get_param: cmaui_image } + availability_zone_0: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_0 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + cmaui.mgmt.ip=${cmaui.mgmt.ip} + cmaui.mgmt.netmask=${cmaui.mgmt.netmask} + cmaui.mgmt.gateway=${cmaui.mgmt.gateway} + cmaui.external.dns=${cmaui.external.dns} + cmaui.external.ntp=${cmaui.external.ntp} + cmaui.node=${cmaui.node} + cmaui.timezone=${cmaui.timezone} + params: + ${cmaui.mgmt.ip}: {get_param: [cmaui_oam_ips, 0]} + ${cmaui.mgmt.netmask}: {get_param: oam_network_netmask} + ${cmaui.mgmt.gateway}: {get_param: oam_network_gateway} + ${cmaui.external.dns}: {get_param: external_dns} + ${cmaui.external.ntp}: {get_param: external_ntp} + ${cmaui.node}: {get_param: [cmaui_names, 0]} + ${cmaui.timezone}: {get_param: timezone} + user_data_format: RAW + + oam1_instance: + type: OS::Nova::Server + properties: + name: {get_param: [eca_names, 0]} + image: {get_param: oam_image_name} + flavor: {get_param: oam_flavor} + availability_zone: {get_param: availability_zone_0} + networks: + - port: {get_resource: oam1_int_port} + - port: {get_resource: oam1_mgmt_port} + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + sed -i s/HOSTNAME.*/"HOSTNAME=oam1_hostname"/g /etc/sysconfig/network + eth1_ip_address='oam1_mgt_ip' + eth1_gateway='oam_gateway' + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + mkdir /etc/puppet/files/roles/transcoder + mkdir /etc/puppet/files/roles/oam_primary + curl swift_url/etc/puppet/manifests/roles/oam_primary.pp > /etc/puppet/manifests/roles/oam_primary.pp + curl swift_url/etc/puppet/manifests/roles/transcoder.pp > /etc/puppet/manifests/roles/transcoder.pp + curl swift_url/etc/puppet/files/roles/oam_primary/config.yaml > /etc/puppet/files/roles/oam_primary/config.yaml + curl swift_url/etc/puppet/files/roles/transcoder/config.yaml > /etc/puppet/files/roles/transcoder/config.yaml + curl swift_url/etc/puppet/files/roles/transcoder/hpm.conf > /etc/puppet/files/roles/transcoder/hpm.conf + curl swift_url/etc/puppet/files/roles/transcoder/trx.conf > /etc/puppet/files/roles/transcoder/trx.conf + curl swift_url/etc/puppet/files/roles/transcoder/plugins-mo.conf > /etc/puppet/files/roles/transcoder/plugins-mo.conf + curl swift_url/etc/puppet/files/global/11-customer.conf > /etc/puppet/files/global/11-customer.conf + curl swift_url/etc/puppet/manifests/site.pp > /etc/puppet/manifests/site.pp + curl swift_url/scripts/van-init-replicaset > /usr/sbin/van-init-replicaset + van-role oam_primary > /root/startup-van-role.out + curl swift_url/scripts/fdisk-keystrokes > /root/fdisk-keystrokes + fdisk /dev/vdb < /root/fdisk-keystrokes + curl swift_url/scripts/os-conf-cinder-vol > /root/os-conf-cinder-vol + chmod 755 /root/os-conf-cinder-vol + /root/os-conf-cinder-vol 2>> /tmp/cinder_volume.log + params: + oam1_mgt_ip: {get_param: [eca_oam_ips, 0] } + oam_gateway: {get_param: eca_oam_gateway } + oam1_hostname: {get_param: [eca_names, 0]} + swift_url: {get_param: swift_eca_url} + + oam1_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [eca_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + cmaui_port_0: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [eca_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + oam1_int_port: + type: OS::Neutron::Port + properties: + network: {get_param: eca_mgmt_net_name} + fixed_ips: [{"ip_address": {get_param: [eca_eca_mgmt_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + oam1_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: oam_volume_size} + volume_type: {get_param: ECA_OAM_volume_type} + + oam1_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: oam1_volume} + instance_uuid: {get_resource: oam1_instance} + + oam2_instance: + type: OS::Nova::Server + properties: + name: {get_param: [eca_names, 1]} + image: {get_param: oam_image_name} + flavor: {get_param: oam_flavor} + availability_zone: {get_param: availability_zone_0} + networks: + - port: {get_resource: oam2_int_port} + - port: {get_resource: oam2_mgmt_port} + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + sed -i s/HOSTNAME.*/"HOSTNAME=oam2_hostname"/g /etc/sysconfig/network + eth1_ip_address='oam2_mgt_ip' + eth1_gateway='oam_gateway' + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + curl swift_url/etc/puppet/manifests/roles/oam_secondary.pp > /etc/puppet/manifests/roles/oam_secondary.pp + curl swift_url/etc/puppet/files/global/config.yaml > /etc/puppet/files/global/config.yaml + curl swift_url/etc/puppet/files/global/11-customer.conf > /etc/puppet/files/global/11-customer.conf + van-role oam_secondary > /root/startup-van-role.out + curl swift_url/scripts/fdisk-keystrokes > /root/fdisk-keystrokes + fdisk /dev/vdb < /root/fdisk-keystrokes + curl swift_url/scripts/os-conf-cinder-vol > /root/os-conf-cinder-vol + chmod 755 /root/os-conf-cinder-vol + /root/os-conf-cinder-vol 2>> /tmp/cinder_volume.log + + params: + oam2_mgt_ip: {get_param: [eca_oam_ips, 1] } + oam2_hostname: {get_param: [eca_names, 1]} + swift_url: {get_param: swift_eca_url} + oam_gateway: {get_param: eca_oam_gateway } + + oam2_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [eca_oam_ips, 1]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + oam2_int_port: + type: OS::Neutron::Port + properties: + network: {get_param: eca_mgmt_net_name} + fixed_ips: [{"ip_address": {get_param: [eca_eca_mgmt_ips, 1]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + oam2_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: oam_volume_size} + volume_type: {get_param: ECA_OAM_volume_type} + + oam2_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: oam2_volume} + instance_uuid: {get_resource: oam2_instance} + + arb_instance: + type: OS::Nova::Server + properties: + name: {get_param: [arb_names, 0]} + image: {get_param: oam_image_name} + flavor: {get_param: arbiter_flavor} + availability_zone: {get_param: availability_zone_0} + networks: + - port: {get_resource: arb_int_port} + - port: {get_resource: arb_mgmt_port} + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + sed -i s/HOSTNAME.*/"HOSTNAME=arb_hostname"/g /etc/sysconfig/network + eth1_ip_address='arb_mgt_ip' + eth1_gateway='oam_gateway' + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + curl swift_url/etc/puppet/manifests/roles/oam_arbiter.pp > /etc/puppet/manifests/roles/oam_arbiter.pp + curl swift_url/etc/puppet/files/global/config.yaml > /etc/puppet/files/global/config.yaml + curl swift_url/etc/puppet/files/global/11-customer.conf > /etc/puppet/files/global/11-customer.conf + van-role oam_arbiter > /root/startup-van-role.out + curl swift_url/scripts/fdisk-keystrokes > /root/fdisk-keystrokes + fdisk /dev/vdb < /root/fdisk-keystrokes + curl swift_url/scripts/os-conf-cinder-vol > /root/os-conf-cinder-vol + chmod 755 /root/os-conf-cinder-vol + /root/os-conf-cinder-vol 2>> /tmp/cinder_volume.log + params: + arb_mgt_ip: {get_param: [arb_oam_ips, 0] } + arb_hostname: {get_param: [arb_names, 0]} + swift_url: {get_param: swift_eca_url} + oam_gateway: {get_param: eca_oam_gateway } + + arb_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [arb_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + arb_int_port: + type: OS::Neutron::Port + properties: + network: {get_param: eca_mgmt_net_name} + fixed_ips: [{"ip_address": {get_param: [arb_eca_mgmt_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + arb_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: arb_volume_size} + volume_type: {get_param: ARB_volume_type} + arb_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: arb_volume} + instance_uuid: {get_resource: arb_instance} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/nested2.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/nested2.yaml new file mode 100644 index 0000000000..8775ffc72e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/nested2.yaml @@ -0,0 +1,431 @@ +heat_template_version: 2013-05-23 + +########################################################## +# +# Changes from MSO +# - Updated per ECOMP Feedback +# +# +########################################################## + +description: This stack creates two ECA OAM VM and one ARB VM + +parameters: + vnf_id: + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-ECA_id + cmaui_names: + type: comma_delimited_list + label: oam servers names + description: the names of the OAM1,OAM2 VM instances + cmaui_image: + type: comma_delimited_list + label: oam servers names + description: the names of the OAM1,OAM2 VM instances + cmaui_flavor: + type: comma_delimited_list + label: oam servers names + description: the names of the OAM1,OAM2 VM instances + eca_names: + type: comma_delimited_list + label: oam servers names + description: the names of the OAM1,OAM2 VM instances + arb_names: + type: comma_delimited_list + label: arbiter server names + description: the names of the arbiter VM instances + oam_image_name: + type: string + label: image name + description: the OAM image name + oam_flavor: + type: string + label: flavor name + description: OAM flavor name + arbiter_flavor: + type: string + label: flavor name + description: arbiter flavor name + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + oam_net_name: + type: string + label: oam network name + description: the name of the oam network + eca_mgmt_net_name: + type: string + label: internal network name + description: the name of the internal network + eca_oam_ips: + type: comma_delimited_list + label: oam network ips + description: the ips of oam networks for eca VM + eca_eca_mgmt_ips: + type: comma_delimited_list + label: eca_mgmt network ips for eca VM + description: internal eca_mgmt network ips for eca VM + arb_oam_ips: + type: comma_delimited_list + label: oam network ips for arb VM + description: oam network ips for eca VM + arb_eca_mgmt_ips: + type: comma_delimited_list + label: eca_mgmt network ips + description: internal eca_mgmt network ips for arb VM + eca_oam_gateway: + type: string + label: oam network gateway + description: oam network gateway + security_group_name: + type: string + label: security group name + description: the name of security group + oam_volume_size: + type: number + label: volume size + description: the size of the OAM volume + arb_volume_size: + type: number + label: volume size + description: the size of the ARB volume + swift_eca_url: + type: string + label: Swift URL + description: Base URL for eca swift object store + ECA_OAM_volume_type: + type: string + label: eca oam vm volume type + description: the name of the target volume backend + ARB_volume_type: + type: string + label: arb vm volume type + description: the name of the target volume backend + +resources: + server_cmaui_nested: + type: eca_oam_nested.yaml + properties: + cmaui_name: { get_param: [cmaui_names, 0]} + cmaui_image: { get_param: cmaui_image } + availability_zone_0: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_0 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + cmaui.mgmt.ip=${cmaui.mgmt.ip} + cmaui.mgmt.netmask=${cmaui.mgmt.netmask} + cmaui.mgmt.gateway=${cmaui.mgmt.gateway} + cmaui.external.dns=${cmaui.external.dns} + cmaui.external.ntp=${cmaui.external.ntp} + cmaui.node=${cmaui.node} + cmaui.timezone=${cmaui.timezone} + params: + ${cmaui.mgmt.ip}: {get_param: [cmaui_oam_ips, 0]} + ${cmaui.mgmt.netmask}: {get_param: oam_network_netmask} + ${cmaui.mgmt.gateway}: {get_param: oam_network_gateway} + ${cmaui.external.dns}: {get_param: external_dns} + ${cmaui.external.ntp}: {get_param: external_ntp} + ${cmaui.node}: {get_param: [cmaui_names, 0]} + ${cmaui.timezone}: {get_param: timezone} + user_data_format: RAW + + oam1_instance: + type: OS::Nova::Server + properties: + name: {get_param: [eca_names, 0]} + image: {get_param: oam_image_name} + flavor: {get_param: oam_flavor} + availability_zone: {get_param: availability_zone_0} + networks: + - port: {get_resource: oam1_int_port} + - port: {get_resource: oam1_mgmt_port} + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + sed -i s/HOSTNAME.*/"HOSTNAME=oam1_hostname"/g /etc/sysconfig/network + eth1_ip_address='oam1_mgt_ip' + eth1_gateway='oam_gateway' + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + mkdir /etc/puppet/files/roles/transcoder + mkdir /etc/puppet/files/roles/oam_primary + curl swift_url/etc/puppet/manifests/roles/oam_primary.pp > /etc/puppet/manifests/roles/oam_primary.pp + curl swift_url/etc/puppet/manifests/roles/transcoder.pp > /etc/puppet/manifests/roles/transcoder.pp + curl swift_url/etc/puppet/files/roles/oam_primary/config.yaml > /etc/puppet/files/roles/oam_primary/config.yaml + curl swift_url/etc/puppet/files/roles/transcoder/config.yaml > /etc/puppet/files/roles/transcoder/config.yaml + curl swift_url/etc/puppet/files/roles/transcoder/hpm.conf > /etc/puppet/files/roles/transcoder/hpm.conf + curl swift_url/etc/puppet/files/roles/transcoder/trx.conf > /etc/puppet/files/roles/transcoder/trx.conf + curl swift_url/etc/puppet/files/roles/transcoder/plugins-mo.conf > /etc/puppet/files/roles/transcoder/plugins-mo.conf + curl swift_url/etc/puppet/files/global/11-customer.conf > /etc/puppet/files/global/11-customer.conf + curl swift_url/etc/puppet/manifests/site.pp > /etc/puppet/manifests/site.pp + curl swift_url/scripts/van-init-replicaset > /usr/sbin/van-init-replicaset + van-role oam_primary > /root/startup-van-role.out + curl swift_url/scripts/fdisk-keystrokes > /root/fdisk-keystrokes + fdisk /dev/vdb < /root/fdisk-keystrokes + curl swift_url/scripts/os-conf-cinder-vol > /root/os-conf-cinder-vol + chmod 755 /root/os-conf-cinder-vol + /root/os-conf-cinder-vol 2>> /tmp/cinder_volume.log + params: + oam1_mgt_ip: {get_param: [eca_oam_ips, 0] } + oam_gateway: {get_param: eca_oam_gateway } + oam1_hostname: {get_param: [eca_names, 0]} + swift_url: {get_param: swift_eca_url} + + oam1_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [eca_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + + cmaui_port_0: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [eca_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + oam1_int_port: + type: OS::Neutron::Port + properties: + network: {get_param: eca_mgmt_net_name} + fixed_ips: [{"ip_address": {get_param: [eca_eca_mgmt_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + oam1_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: oam_volume_size} + volume_type: {get_param: ECA_OAM_volume_type} + + oam1_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: oam1_volume} + instance_uuid: {get_resource: oam1_instance} + + oam2_instance: + type: OS::Nova::Server + properties: + name: {get_param: [eca_names, 1]} + image: {get_param: oam_image_name} + flavor: {get_param: oam_flavor} + availability_zone: {get_param: availability_zone_0} + networks: + - port: {get_resource: oam2_int_port} + - port: {get_resource: oam2_mgmt_port} + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + sed -i s/HOSTNAME.*/"HOSTNAME=oam2_hostname"/g /etc/sysconfig/network + eth1_ip_address='oam2_mgt_ip' + eth1_gateway='oam_gateway' + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + curl swift_url/etc/puppet/manifests/roles/oam_secondary.pp > /etc/puppet/manifests/roles/oam_secondary.pp + curl swift_url/etc/puppet/files/global/config.yaml > /etc/puppet/files/global/config.yaml + curl swift_url/etc/puppet/files/global/11-customer.conf > /etc/puppet/files/global/11-customer.conf + van-role oam_secondary > /root/startup-van-role.out + curl swift_url/scripts/fdisk-keystrokes > /root/fdisk-keystrokes + fdisk /dev/vdb < /root/fdisk-keystrokes + curl swift_url/scripts/os-conf-cinder-vol > /root/os-conf-cinder-vol + chmod 755 /root/os-conf-cinder-vol + /root/os-conf-cinder-vol 2>> /tmp/cinder_volume.log + + params: + oam2_mgt_ip: {get_param: [eca_oam_ips, 1] } + oam2_hostname: {get_param: [eca_names, 1]} + swift_url: {get_param: swift_eca_url} + oam_gateway: {get_param: eca_oam_gateway } + + oam2_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [eca_oam_ips, 1]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + oam2_int_port: + type: OS::Neutron::Port + properties: + network: {get_param: eca_mgmt_net_name} + fixed_ips: [{"ip_address": {get_param: [eca_eca_mgmt_ips, 1]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + oam2_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: oam_volume_size} + volume_type: {get_param: ECA_OAM_volume_type} + + oam2_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: oam2_volume} + instance_uuid: {get_resource: oam2_instance} + + arb_instance: + type: OS::Nova::Server + properties: + name: {get_param: [arb_names, 0]} + image: {get_param: oam_image_name} + flavor: {get_param: arbiter_flavor} + availability_zone: {get_param: availability_zone_0} + networks: + - port: {get_resource: arb_int_port} + - port: {get_resource: arb_mgmt_port} + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + sed -i s/HOSTNAME.*/"HOSTNAME=arb_hostname"/g /etc/sysconfig/network + eth1_ip_address='arb_mgt_ip' + eth1_gateway='oam_gateway' + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + curl swift_url/etc/puppet/manifests/roles/oam_arbiter.pp > /etc/puppet/manifests/roles/oam_arbiter.pp + curl swift_url/etc/puppet/files/global/config.yaml > /etc/puppet/files/global/config.yaml + curl swift_url/etc/puppet/files/global/11-customer.conf > /etc/puppet/files/global/11-customer.conf + van-role oam_arbiter > /root/startup-van-role.out + curl swift_url/scripts/fdisk-keystrokes > /root/fdisk-keystrokes + fdisk /dev/vdb < /root/fdisk-keystrokes + curl swift_url/scripts/os-conf-cinder-vol > /root/os-conf-cinder-vol + chmod 755 /root/os-conf-cinder-vol + /root/os-conf-cinder-vol 2>> /tmp/cinder_volume.log + params: + arb_mgt_ip: {get_param: [arb_oam_ips, 0] } + arb_hostname: {get_param: [arb_names, 0]} + swift_url: {get_param: swift_eca_url} + oam_gateway: {get_param: eca_oam_gateway } + + arb_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [arb_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + arb_int_port: + type: OS::Neutron::Port + properties: + network: {get_param: eca_mgmt_net_name} + fixed_ips: [{"ip_address": {get_param: [arb_eca_mgmt_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + arb_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: arb_volume_size} + volume_type: {get_param: ARB_volume_type} + arb_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: arb_volume} + instance_uuid: {get_resource: arb_instance} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/network_out.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/network_out.env new file mode 100644 index 0000000000..8012063ac0 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/network_out.env @@ -0,0 +1,7 @@ +parameters: + eca_mgmt_name: int_eca_mgmt_net_1 + eca_mgmt_cidr: 172.25.137.192/26 + eca_mgmt_netmask: 255.255.255.192 + eca_mgmt_start: 172.25.137.195 + eca_mgmt_end: 172.25.137.254 + security_group_name: mmsc_security_group_1 diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/sg_eca_mgmt.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/sg_eca_mgmt.env new file mode 100644 index 0000000000..8012063ac0 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/sg_eca_mgmt.env @@ -0,0 +1,7 @@ +parameters: + eca_mgmt_name: int_eca_mgmt_net_1 + eca_mgmt_cidr: 172.25.137.192/26 + eca_mgmt_netmask: 255.255.255.192 + eca_mgmt_start: 172.25.137.195 + eca_mgmt_end: 172.25.137.254 + security_group_name: mmsc_security_group_1 diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/volume.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/volume.env new file mode 100644 index 0000000000..8012063ac0 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/volume.env @@ -0,0 +1,7 @@ +parameters: + eca_mgmt_name: int_eca_mgmt_net_1 + eca_mgmt_cidr: 172.25.137.192/26 + eca_mgmt_netmask: 255.255.255.192 + eca_mgmt_start: 172.25.137.195 + eca_mgmt_end: 172.25.137.254 + security_group_name: mmsc_security_group_1 diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/volume_out.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/volume_out.env new file mode 100644 index 0000000000..8012063ac0 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heattotoscatranslator/overallexample/inputs/volume_out.env @@ -0,0 +1,7 @@ +parameters: + eca_mgmt_name: int_eca_mgmt_net_1 + eca_mgmt_cidr: 172.25.137.192/26 + eca_mgmt_netmask: 255.255.255.192 + eca_mgmt_start: 172.25.137.195 + eca_mgmt_end: 172.25.137.254 + security_group_name: mmsc_security_group_1 diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/expectedOutput/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/expectedOutput/MainServiceTemplate.yaml new file mode 100644 index 0000000000..5aa6e2e213 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/expectedOutput/MainServiceTemplate.yaml @@ -0,0 +1,4518 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.nems_be: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.lb: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.eca: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.arb: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.eca_trx: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.nems_fe: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.mmsc: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + lb_flavor_name: + label: Load balancer flavor name + hidden: false + immutable: false + type: string + description: the flavor name of MMSC load balancer instance + default: m1.xlarge + ha_net_local_ip2: + label: ha net network local ip2 + hidden: false + immutable: false + type: string + description: the local ip2 of the ha network + default: 172.26.1.4 + mmsc_dmz_protected_snat_ips: + label: mmsc dmz_protected snat ips + hidden: false + immutable: false + type: list + description: mmsc dmz_protected snat ips + default: + - 107.239.14.24 + - 107.239.14.25 + - 107.239.14.26 + - 107.239.14.27 + entry_schema: + type: string + ha_net_local_ip1: + label: ha net network local ip1 + hidden: false + immutable: false + type: string + description: the local ip1 of the ha network + default: 172.26.1.3 + mms_traffic_end: + label: mmsc traffic end IP + hidden: false + immutable: false + type: string + description: mmsc traffic end IP + default: 172.26.2.254 + nems_traffic_end: + label: nems traffic end + hidden: false + immutable: false + type: string + description: nems traffic end + default: 172.26.3.254 + mmsc_cinder_volume_size: + label: MMSC Cinder volume size + hidden: false + immutable: false + type: float + description: the size of the MMSC Cinder volume + default: 480 + nems_internal_cidr: + label: nems ineternal cidr + hidden: false + immutable: false + type: string + description: nems internal cidr + default: 172.26.6.0/24 + eca_mgmt_cidr: + label: eca management cidr + hidden: false + immutable: false + type: string + description: eca management cidr + default: 172.25.137.192/26 + nems_traffic_start: + label: nems traffic start + hidden: false + immutable: false + type: string + description: nems traffic start + default: 172.26.3.3 + oam_volume_size: + label: volume size + hidden: false + immutable: false + type: float + description: the size of the OAM volume + default: 1800 + eca_trx_names: + label: ECA_TRX server names + hidden: false + immutable: false + type: list + description: ECA_TRX server names + default: + - ZRDM1MMSC03TRX001 + - ZRDM1MMSC03TRX002 + - ZRDM1MMSC03TRX003 + - ZRDM1MMSC03TRX004 + - ZRDM1MMSC03TRX005 + - ZRDM1MMSC03TRX006 + - ZRDM1MMSC03TRX007 + - ZRDM1MMSC03TRX008 + - ZRDM1MMSC03TRX009 + - ZRDM1MMSC03TRX010 + - ZRDM1MMSC03TRX011 + - ZRDM1MMSC03TRX012 + - ZRDM1MMSC03TRX013 + - ZRDM1MMSC03TRX014 + - ZRDM1MMSC03TRX015 + - ZRDM1MMSC03TRX016 + - ZRDM1MMSC03TRX017 + - ZRDM1MMSC03TRX018 + - ZRDM1MMSC03TRX019 + - ZRDM1MMSC03TRX020 + entry_schema: + type: string + nems_internal_name: + label: nems internal network name + hidden: false + immutable: false + type: string + description: nems internal network name + default: int_mms_nems_internal_net_2 + nems_traffic_net_local_ip1: + label: nems traffic network local ip1 + hidden: false + immutable: false + type: string + description: the local ip1 of the nems traffic network + default: 172.26.3.3 + nems_traffic_net_local_ip2: + label: nems traffic network local ip2 + hidden: false + immutable: false + type: string + description: the local ip2 of the nems traffic network + default: 172.26.3.4 + nems_fe_names: + label: NEMS_FE server names + hidden: false + immutable: false + type: list + description: NEMS_FE server names + default: + - ZRDM1MMSC03NFE001 + - ZRDM1MMSC03NFE002 + entry_schema: + type: string + eca_names: + label: oam servers names + hidden: false + immutable: false + type: list + description: the names of the OAM1,OAM2 VM instances + default: + - ZRDM1MMSC02OAM001 + - ZRDM1MMSC02OAM002 + entry_schema: + type: string + nems_be_nems_imap_net_ips: + label: nems imap_net IPs for NEMS_BE + hidden: false + immutable: false + type: string + description: nems imap net IPs for NEMS_BE + default: 172.26.7.13 + nems_be_names: + label: NEMS_BE server names + hidden: false + immutable: false + type: string + description: NEMS_BE server names + default: ZRDM1MMSC03NBE001 + nems_traffic_netmask: + label: NEMS traffic network subnet mask + hidden: false + immutable: false + type: string + description: NEMS traffic network subnet mask + default: 255.255.255.0 + nems_fe_nems_imap_net_ips: + label: nems_imap_net IPs for NEMS_FE + hidden: false + immutable: false + type: list + description: nems_imap_net IPs for NEMS_FE + default: + - 172.26.7.11 + - 172.26.7.12 + entry_schema: + type: string + nems_fe_nems_user_web_net_ips: + label: nems_web_user_net IPs for NEMS_FE + hidden: false + immutable: false + type: list + description: nems_web_user_net IPs for NEMS_FE + default: + - 172.26.4.11 + - 172.26.4.12 + entry_schema: + type: string + nems_user_web_gateway: + label: NEMS user web network gateway + hidden: false + immutable: false + type: string + description: NEMS user web network gateway + default: 172.26.4.1 + nems_imap_end: + label: nems imap end + hidden: false + immutable: false + type: string + description: nems imap end + default: 172.26.7.254 + eca_traffic_net_local_ip1: + label: eca traffic network local ip1 + hidden: false + immutable: false + type: string + description: the local ip1 of the eca traffic network + default: 172.26.5.3 + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + default: cmaui-5.0.2.5_v25 + eca_traffic_net_local_ip2: + label: eca traffic network local ip2 + hidden: false + immutable: false + type: string + description: the local ip2 of the eca traffic network + default: 172.26.5.4 + nems_volume_size: + label: nems fe volume size + hidden: false + immutable: false + type: float + description: nems fe volume size + default: 50 + mms_traffic_start: + label: mmsc traffic start IP + hidden: false + immutable: false + type: string + description: mmsc traffic start IP + default: 172.26.2.3 + ha_net_start: + label: ha net start + hidden: false + immutable: false + type: string + description: ha net start + default: 172.26.1.3 + nems_imap_gateway: + label: nems imap gateway + hidden: false + immutable: false + type: string + description: nems imap gateway + default: 172.26.7.1 + mmsc_core_virtual_server_ips: + label: mmsc core virtual server ips + hidden: false + immutable: false + type: list + description: mmsc core virtual server ips + default: + - 172.31.10.21 + - 172.31.10.22 + entry_schema: + type: string + cmaui_oam_ips: + label: CMAUI oam_net IP addresses + hidden: false + immutable: false + type: list + description: CMAUI oam_net IP addresses + default: + - 107.250.172.42 + - 107.250.172.43 + entry_schema: + type: string + CMAUI_volume_type: + label: CMAUI vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + default: Platinum + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + default: + - ZRDM1MMSC02CMI001 + - ZRDM1MMSC02CMI002 + entry_schema: + type: string + eca_trx_eca_traffic_net_ips: + label: eca traffic net IPs for ECA_TRX + hidden: false + immutable: false + type: list + description: eca traffic net IPs for ECA_TRX + default: + - 172.26.5.11 + - 172.26.5.12 + - 172.26.5.13 + - 172.26.5.14 + - 172.26.5.15 + - 172.26.5.16 + - 172.26.5.17 + - 172.26.5.18 + - 172.26.5.19 + - 172.26.5.20 + - 172.26.5.21 + - 172.26.5.22 + - 172.26.5.23 + - 172.26.5.24 + - 172.26.5.25 + - 172.26.5.26 + - 172.26.5.27 + - 172.26.5.28 + - 172.26.5.29 + - 172.26.5.30 + entry_schema: + type: string + eca_trx_image: + label: Image for ECA TRX server + hidden: false + immutable: false + type: string + description: Image for ECA TRX server + default: ECABASE + lb_names: + label: MMSC load balancer instance names + hidden: false + immutable: false + type: list + description: MMSC load balancer instance names + default: + - ZRDM1MMSC03ALB001 + - ZRDM1MMSC03ALB002 + entry_schema: + type: string + eca_mgmt_end: + label: eca management end + hidden: false + immutable: false + type: string + description: eca management end + default: 172.25.137.254 + nems_user_web_end: + label: nems user web end + hidden: false + immutable: false + type: string + description: nems user web end + default: 172.26.4.254 + ECA_OAM_volume_type: + label: eca oam vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + default: Platinum + arb_eca_mgmt_ips: + label: eca_mgmt network ips + hidden: false + immutable: false + type: list + description: internal eca_mgmt network ips for arb VM + default: + - 172.25.137.244 + entry_schema: + type: string + eca_traffic_cidr: + label: eca traffic cidr + hidden: false + immutable: false + type: string + description: eca traffic cidr + default: 172.26.5.0/24 + ha_net_cidr: + label: ha net cidr + hidden: false + immutable: false + type: string + description: ha net cidr + default: 172.26.1.0/24 + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + default: nova + ARB_volume_type: + label: arb vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + default: Platinum + nems_fe_nems_internal_net_ips: + label: nems_internal_net IPs for NEMS_FE + hidden: false + immutable: false + type: list + description: nems_internal_net IPs for NEMS_FE + default: + - 172.26.6.11 + - 172.26.6.12 + entry_schema: + type: string + NEMS_FE_volume_type: + label: nems fe vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + default: Platinum + security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + default: mmsc_security_group_1 + nems_fe_nems_traffic_net_ips: + label: nems_traffic_net IPs for NEMS_FE + hidden: false + immutable: false + type: list + description: nems_traffic_net IPs for NEMS_FE + default: + - 172.26.3.11 + - 172.26.3.12 + entry_schema: + type: string + nems_imap_start: + label: nems imap start + hidden: false + immutable: false + type: string + description: nems imap start + default: 172.26.7.3 + ha_net_name: + label: ha_failover network name + hidden: false + immutable: false + type: string + description: ha_failover network name + default: int_mms_ha_net_2 + arb_names: + label: arbiter server names + hidden: false + immutable: false + type: list + description: the names of the arbiter VM instances + default: + - ZRDM1MMSC02ARB001 + entry_schema: + type: string + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + default: m1.large + eca_oam_gateway: + label: oam1 oam gateway + hidden: false + immutable: false + type: string + description: the ip of oam gateway + default: 107.250.172.1 + eca_traffic_start: + label: eca traffic start + hidden: false + immutable: false + type: string + description: eca traffic start + default: 172.26.5.3 + NEMS_BE_volume_type: + label: nems be vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + default: Platinum + lb_image_name: + label: MMSC load balancer image name + hidden: false + immutable: false + type: string + description: MMSC load balancer image name + default: BIGIP-11.5.3.0.0.163 + nems_internal_start: + label: nems internal start + hidden: false + immutable: false + type: string + description: nems internal start + default: 172.26.6.3 + nems_internal_gateway: + label: nems internal gw + hidden: false + immutable: false + type: string + description: nems internal gw + default: 172.26.6.1 + arb_oam_ips: + label: oam network ips for arb VM + hidden: false + immutable: false + type: list + description: oam network ips for eca VM + default: + - 107.250.172.46 + entry_schema: + type: string + dmz_protected_net_name: + label: UID of dmz_protected network + hidden: false + immutable: false + type: string + description: UID of dmz_protected network + default: dmz_protected_net_0 + nems_be_volume_size: + label: nems be volume size + hidden: false + immutable: false + type: float + description: nems be volume size + default: 610 + mms_traffic_netmask: + label: MMS traffic network subnet mask + hidden: false + immutable: false + type: string + description: MMS traffic network subnet mask + default: 255.255.255.0 + nems_be_image: + label: Image for NEMS BE server + hidden: false + immutable: false + type: string + description: Image for NEMS BE server + default: nems-2.1.2_v29 + nems_user_web_net_local_ip1: + label: nems user web network local ip1 + hidden: false + immutable: false + type: string + description: the local ip1 of the nems user web network + default: 172.26.4.3 + eca_trx_mgmt_ips: + label: eca mgmt net IP for ECA_TRX + hidden: false + immutable: false + type: list + description: eca mgmt net IP for ECA_TRX + default: + - 172.25.137.202 + - 172.25.137.203 + - 172.25.137.204 + - 172.25.137.205 + - 172.25.137.206 + - 172.25.137.207 + - 172.25.137.208 + - 172.25.137.209 + - 172.25.137.210 + - 172.25.137.211 + - 172.25.137.212 + - 172.25.137.213 + - 172.25.137.214 + - 172.25.137.215 + - 172.25.137.216 + - 172.25.137.217 + - 172.25.137.218 + - 172.25.137.219 + - 172.25.137.220 + - 172.25.137.221 + entry_schema: + type: string + nems_user_web_cidr: + label: nems user web cidr + hidden: false + immutable: false + type: string + description: nems user web cidr + default: 172.26.4.0/24 + nems_user_web_net_local_ip2: + label: nems user web network local ip2 + hidden: false + immutable: false + type: string + description: the local ip2 of the nems user web network + default: 172.26.4.4 + nems_traffic_gateway: + label: NEMS traffic network gateway + hidden: false + immutable: false + type: string + description: NEMS traffic network gateway + default: 172.26.3.1 + nems_imap_name: + label: nems imap name + hidden: false + immutable: false + type: string + description: nems imap name + default: int_mms_nems_imap_net_2 + mms_traffic_net_floating_ip: + label: mmsc traffic floating ip + hidden: false + immutable: false + type: string + description: mmsc traffic floating ip + default: 172.26.2.5 + nems_internal_netmask: + label: NEMS internal network subnet mask + hidden: false + immutable: false + type: string + description: NEMS internal network subnet mask + default: 255.255.255.0 + nems_user_web_netmask: + label: NEMS user web network subnet mask + hidden: false + immutable: false + type: string + description: NEMS user web network subnet mask + default: 255.255.255.0 + mms_traffic_net_local_ip1: + label: mmsc traffic network local ip1 + hidden: false + immutable: false + type: string + description: the local ip1 of the mmsc traffic network + default: 172.26.2.3 + mms_traffic_net_local_ip2: + label: mmsc traffic network local ip2 + hidden: false + immutable: false + type: string + description: the local ip2 of the mmsc traffic network + default: 172.26.2.4 + oam_image_name: + label: image name + hidden: false + immutable: false + type: string + description: the OAM image name + default: ECABASE + oam_net_name: + hidden: false + immutable: false + type: string + description: UID of OAM network + default: oam_protected_net_0 + external_ntp: + label: ntp server + hidden: false + immutable: false + type: string + description: ntp server + default: 155.165.194.100 + mms_traffic_net_cidr: + label: MMS traffic network address (CIDR notation) + hidden: false + immutable: false + type: string + description: MMS traffic network address (CIDR notation) + default: 172.26.2.0/24 + lb_dmz_protected_ips: + label: dmz protected network local ips for lb VM + hidden: false + immutable: false + type: list + description: local ips of the dmz protected network for lb VM + default: + - 107.239.14.19 + - 107.239.14.20 + entry_schema: + type: string + eca_mgmt_start: + label: eca management start + hidden: false + immutable: false + type: string + description: eca management start + default: 172.25.137.195 + eca_oam_ips: + label: oam network ips + hidden: false + immutable: false + type: list + description: the ips of oam networks for eca VM + default: + - 107.250.172.44 + - 107.250.172.45 + entry_schema: + type: string + MMSC_volume_type: + label: MMSC vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + default: Platinum + nems_fe_flavor: + label: Flavor for NEMS FE server + hidden: false + immutable: false + type: string + description: Flavor for NEMS FE server + default: m1.large2 + eca_mgmt_netmask: + label: ECA mgmt network subnet mask + hidden: false + immutable: false + type: string + description: ECA mgmt network subnet mask + default: 255.255.255.192 + oam_network_netmask: + label: oam network netmask + hidden: false + immutable: false + type: string + description: oam network gateway + default: 255.255.255.192 + oam_network_route_1: + label: oam network route 1 + hidden: false + immutable: false + type: string + description: oam network route 1 + default: 155.165.201.250/32,107.250.172.1 + oam_network_route_2: + label: oam network route 2 + hidden: false + immutable: false + type: string + description: oam network route 2 + default: 155.165.194.100/32,107.250.172.1 + mms_traffic_net_name: + label: Name of MMS traffic network + hidden: false + immutable: false + type: string + description: Name of MMS traffic network + default: int_mms_mms_traffic_net_2 + nems_user_web_name: + label: nems user web name + hidden: false + immutable: false + type: string + description: nems user web name + default: int_mms_nems_web_net_2 + eca_traffic_net_floating_ip: + label: eca traffic floating ip + hidden: false + immutable: false + type: string + description: eca traffic floating ip + default: 172.26.5.5 + eca_traffic_end: + label: eca traffic end + hidden: false + immutable: false + type: string + description: eca traffic end + default: 172.26.5.254 + eca_trx_flavor: + label: Flavor for ECA TRX server + hidden: false + immutable: false + type: string + description: Flavor for ECA TRX server + default: m1.xlarge + lb_oam_ips: + label: management network ips for mmsc lb + hidden: false + immutable: false + type: list + description: the ips of the management network for mmsc lb + default: + - 107.250.172.50 + - 107.250.172.51 + entry_schema: + type: string + nems_fe_oam_ips: + label: OAM_net IP for NEMS_FE + hidden: false + immutable: false + type: list + description: OAM_net IP for NEMS_FE + default: + - 107.250.172.64 + - 107.250.172.65 + entry_schema: + type: string + nems_be_flavor: + label: Flavor for NEMS BE server + hidden: false + immutable: false + type: string + description: Flavor for NEMS BE server + default: m1.large2 + lb_cor_direct_ips: + label: cor direct network local ips for lb VM + hidden: false + immutable: false + type: list + description: local ips of cor direct network for lb VM + default: + - 172.31.10.19 + - 172.31.10.20 + entry_schema: + type: string + nems_traffic_name: + label: nems traffic name + hidden: false + immutable: false + type: string + description: nems traffic name + default: int_mms_nems_traffic_net_2 + timezone: + label: timezone + hidden: false + immutable: false + type: string + description: timezone + default: UTC + oam_flavor: + label: flavor name + hidden: false + immutable: false + type: string + description: OAM flavor name + default: lc.xlarge4 + cmaui_cinder_volume_size: + label: CMAUI Cinder volume size + hidden: false + immutable: false + type: float + description: the size of the CMAUI Cinder volume + default: 55 + nems_user_web_start: + label: nems user web start + hidden: false + immutable: false + type: string + description: nems user web end + default: 172.26.4.3 + eca_eca_mgmt_ips: + label: eca_mgmt network ips for eca VM + hidden: false + immutable: false + type: list + description: internal eca_mgmt network ips for eca VM + default: + - 172.25.137.242 + - 172.25.137.243 + entry_schema: + type: string + mmsc_names: + label: MMSC server names + hidden: false + immutable: false + type: list + description: MMSC server names + default: + - ZRDM1MMSC03MMS001 + - ZRDM1MMSC03MMS002 + - ZRDM1MMSC03MMS003 + - ZRDM1MMSC03MMS004 + - ZRDM1MMSC03MMS005 + entry_schema: + type: string + eca_mgmt_net_name: + label: internal network name + hidden: false + immutable: false + type: string + description: the name of the internal network + default: int_mms_eca_mgmt_net_1 + eca_traffic_name: + label: eca traffic name + hidden: false + immutable: false + type: string + description: eca traffic name + default: int_mms_eca_traffic_net_2 + nems_internal_end: + label: nems internal end + hidden: false + immutable: false + type: string + description: nems internal end + default: 172.26.6.254 + nems_be_nems_internal_net_ips: + label: nems internal net IPs for NEMS_BE + hidden: false + immutable: false + type: string + description: nems internal net IPs for NEMS_BE + default: 172.26.6.13 + arb_volume_size: + label: volume size + hidden: false + immutable: false + type: float + description: the size of the ARB volume + default: 40 + mmsc_dmz_protected_virtual_server_ips: + label: mmsc dmz_protected virtual server ips + hidden: false + immutable: false + type: list + description: mmsc dmz_protected virtual server ips + default: + - 107.239.14.21 + - 107.239.14.22 + - 107.239.14.23 + entry_schema: + type: string + cor_direct_net_name: + label: cor direct net UID + hidden: false + immutable: false + type: string + description: cor direct net + default: cor_direct_net_0 + vnf_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-CMAUI_id + oam_network_gateway: + label: oam network gateway + hidden: false + immutable: false + type: string + description: oam network gateway + default: 10.20.30.1 + mmsc_flavor: + label: Flavor for MMSC server + hidden: false + immutable: false + type: string + description: Flavor for MMSC server + default: lc.4xlarge4 + ha_net_end: + label: ha net end + hidden: false + immutable: false + type: string + description: ha net end + default: 172.26.1.254 + nems_imap_netmask: + label: nems imap subnet mask + hidden: false + immutable: false + type: string + description: nems imap subnet mask + default: 255.255.255.0 + external_dns: + label: dns server + hidden: false + immutable: false + type: string + description: dns server + default: 155.165.201.250 + swift_eca_url: + label: Swift URL + hidden: false + immutable: false + type: string + description: Base URL for eca swift object store + default: http://object-store.rdm2.cci.com:8080/v1/AUTH_1bbab536a19b4756926e7d0ec1eb543c/eca + eca_traffic_net_gateway: + label: eca_traffic network gateway + hidden: false + immutable: false + type: string + description: eca_traffic network gateway + default: 172.26.5.1 + nems_be_oam_ips: + label: OAM net IPs for NEMS_BE + hidden: false + immutable: false + type: string + description: OAM net IPs for NEMS_BE + default: 107.250.172.66 + eca_trx_oam_ips: + label: OAM net IP for ECA_TRX + hidden: false + immutable: false + type: list + description: OAM net IP for ECA_TRX + default: + - 107.250.172.70 + - 107.250.172.71 + - 107.250.172.72 + - 107.250.172.73 + - 107.250.172.74 + - 107.250.172.75 + - 107.250.172.76 + - 107.250.172.77 + - 107.250.172.78 + - 107.250.172.79 + - 107.250.172.80 + - 107.250.172.81 + - 107.250.172.82 + - 107.250.172.83 + - 107.250.172.84 + - 107.250.172.85 + - 107.250.172.86 + - 107.250.172.87 + - 107.250.172.88 + - 107.250.172.89 + entry_schema: + type: string + mmsc_image: + label: Image for MMSC server + hidden: false + immutable: false + type: string + description: Image for MMSC server + default: mmsc-6.0.2_v5 + arbiter_flavor: + label: flavor name + hidden: false + immutable: false + type: string + description: arbiter flavor name + default: m1.large2 + nems_imap_cidr: + label: nems imap cidr + hidden: false + immutable: false + type: string + description: nems imap cidr + default: 172.26.7.0/24 + eca_traffic_netmask: + label: ECA traffic network subnet mask + hidden: false + immutable: false + type: string + description: ECA traffic network subnet mask + default: 255.255.255.0 + nems_fe_node_roles: + label: nems fe node roles + hidden: false + immutable: false + type: list + description: nems fe node roles + default: + - FE0 + - FE1 + entry_schema: + type: string + mmsc_mms_traffic_net_ips: + label: MMSC mms_traffic_net IP addresses + hidden: false + immutable: false + type: list + description: MMSC mms_traffic_net IP addresses + default: + - 172.26.2.11 + - 172.26.2.12 + - 172.26.2.13 + - 172.26.2.14 + - 172.26.2.15 + entry_schema: + type: string + nems_traffic_net_floating_ip: + label: nems traffic floating ip + hidden: false + immutable: false + type: string + description: nems traffic floating ip + default: 172.26.3.5 + mms_traffic_net_gateway: + label: MMS traffic network gateway address + hidden: false + immutable: false + type: string + description: MMS traffic network gateway address + default: 172.26.2.1 + nems_fe_image: + label: Image for NEMS FE server + hidden: false + immutable: false + type: string + description: Image for NEMS FE server + default: nems-2.1.2_v29 + mmsc_oam_ips: + label: MMSC oam_net IP addresses + hidden: false + immutable: false + type: list + description: MMSC oam_net IP addresses + default: + - 107.250.172.54 + - 107.250.172.55 + - 107.250.172.56 + - 107.250.172.57 + - 107.250.172.58 + entry_schema: + type: string + eca_mgmt_name: + label: eca management name + hidden: false + immutable: false + type: string + description: eca management name + default: int_eca_mgmt_net_1 + nems_traffic_cidr: + label: nems traffic cidr + hidden: false + immutable: false + type: string + description: nems traffic cidr + default: 172.26.3.0/24 + nems_be_node_roles: + label: nems node roles + hidden: false + immutable: false + type: string + description: nems node roles + default: BE0 + mmsc_core_snat_ips: + label: mmsc core snat ips + hidden: false + immutable: false + type: list + description: mmsc core snat ips + default: + - 172.31.10.23 + - 172.31.10.24 + - 172.31.10.25 + - 172.31.10.26 + - 172.31.10.27 + entry_schema: + type: string + nems_user_web_net_floating_ip: + label: nems user web floating ip + hidden: false + immutable: false + type: string + description: nems user web floating ip + default: 172.26.4.5 + node_templates: + server_eca_trx9: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 8 + server_eca_trx8: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 7 + server_eca_trx7: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 6 + server_eca_trx6: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 5 + arb_instance: + type: org.openecomp.resource.vfc.nodes.heat.arb + properties: + flavor: + get_input: arbiter_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: oam_image_name + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - arb_names + - 0 + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: arb_volume + relationship: arb_volume_attachment + server_eca_trx5: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 4 + nems_internal_net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + network_name: + get_input: nems_internal_name + subnets: + nems_internal_network_ip_subnet: + name: + get_input: nems_internal_name + cidr: + get_input: nems_internal_cidr + allocation_pools: + - start: + get_input: nems_internal_start + end: + get_input: nems_internal_end + server_eca_trx4: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 3 + server_eca_trx3: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 2 + server_eca_trx2: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 1 + lb1_mgmt_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - lb_oam_ips + - 0 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: lb1_instance + relationship: tosca.relationships.network.BindsTo + lb2_mms_traffic_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: mms_traffic_net_local_ip2 + allowed_address_pairs: + - ip_address: + get_input: mms_traffic_net_floating_ip + network: mms_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: mms_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: lb2_instance + relationship: tosca.relationships.network.BindsTo + nems_fe1_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - nems_fe_nems_traffic_net_ips + - 0 + network: nems_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: nems_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_nems_fe1 + relationship: tosca.relationships.network.BindsTo + nems_fe2_port_3: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - nems_fe_nems_internal_net_ips + - 1 + network: nems_internal_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: nems_internal_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_nems_fe2 + relationship: tosca.relationships.network.BindsTo + server_eca_trx1: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 0 + nems_fe1_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - nems_fe_nems_user_web_net_ips + - 0 + network: nems_user_web_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: nems_user_web_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_nems_fe1 + relationship: tosca.relationships.network.BindsTo + nems_fe2_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - nems_fe_nems_user_web_net_ips + - 1 + network: nems_user_web_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: nems_user_web_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_nems_fe2 + relationship: tosca.relationships.network.BindsTo + nems_fe2_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - nems_fe_nems_traffic_net_ips + - 1 + network: nems_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: nems_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_nems_fe2 + relationship: tosca.relationships.network.BindsTo + nems_fe1_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - nems_fe_oam_ips + - 0 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_nems_fe1 + relationship: tosca.relationships.network.BindsTo + nems_fe2_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - nems_fe_oam_ips + - 1 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_nems_fe2 + relationship: tosca.relationships.network.BindsTo + nems_fe1_port_3: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - nems_fe_nems_internal_net_ips + - 0 + network: nems_internal_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: nems_internal_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_nems_fe1 + relationship: tosca.relationships.network.BindsTo + nems_fe1_port_4: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - nems_fe_nems_imap_net_ips + - 0 + network: nems_imap_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: nems_imap_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_nems_fe1 + relationship: tosca.relationships.network.BindsTo + nems_fe2_port_4: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - nems_fe_nems_imap_net_ips + - 1 + network: nems_imap_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: nems_imap_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_nems_fe2 + relationship: tosca.relationships.network.BindsTo + mms_security_group: + type: org.openecomp.resource.vfc.rules.nodes.heat.network.neutron.SecurityRules + properties: + name: + get_input: security_group_name + description: mmsc security group + rules: + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + mmsc4_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: MMSC_volume_type + size: '(get_input : mmsc_cinder_volume_size) * 1024' + lb2_eca_traffic_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: eca_traffic_net_local_ip2 + allowed_address_pairs: + - ip_address: + get_input: eca_traffic_net_floating_ip + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: lb2_instance + relationship: tosca.relationships.network.BindsTo + lb2_ha_net_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: ha_net_local_ip2 + network: ha_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: ha_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: lb2_instance + relationship: tosca.relationships.network.BindsTo + oam2_mgmt_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_oam_ips + - 1 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: oam2_instance + relationship: tosca.relationships.network.BindsTo + nems_user_web_net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + network_name: + get_input: nems_user_web_name + subnets: + nems_user_web_network_ip_subnet: + name: + get_input: nems_user_web_name + cidr: + get_input: nems_user_web_cidr + allocation_pools: + - start: + get_input: nems_user_web_start + end: + get_input: nems_user_web_end + lb1_ha_net_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: ha_net_local_ip1 + network: ha_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: ha_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: lb1_instance + relationship: tosca.relationships.network.BindsTo + mmsc2_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: MMSC_volume_type + size: '(get_input : mmsc_cinder_volume_size) * 1024' + cmaui1_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: CMAUI_volume_type + size: '(get_input : cmaui_cinder_volume_size) * 1024' + nems_traffic_net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + network_name: + get_input: nems_traffic_name + subnets: + nems_traffic_network_ip_subnet: + name: + get_input: nems_traffic_name + cidr: + get_input: nems_traffic_cidr + allocation_pools: + - start: + get_input: nems_traffic_start + end: + get_input: nems_traffic_end + eca_trx16_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 15 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx16 + relationship: tosca.relationships.network.BindsTo + eca_trx19_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 18 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx19 + relationship: tosca.relationships.network.BindsTo + eca_trx16_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 15 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx16 + relationship: tosca.relationships.network.BindsTo + eca_trx19_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 18 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx19 + relationship: tosca.relationships.network.BindsTo + eca_trx15_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 14 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx15 + relationship: tosca.relationships.network.BindsTo + eca_trx19_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 18 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx19 + relationship: tosca.relationships.network.BindsTo + lb1_nems_traffic_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: nems_traffic_net_local_ip1 + allowed_address_pairs: + - ip_address: + get_input: nems_traffic_net_floating_ip + network: nems_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: nems_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: lb1_instance + relationship: tosca.relationships.network.BindsTo + oam2_instance: + type: org.openecomp.resource.vfc.nodes.heat.eca + properties: + flavor: + get_input: oam_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: oam_image_name + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_names + - 1 + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: oam2_volume + relationship: oam2_volume_attachment + eca_trx11_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 10 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx11 + relationship: tosca.relationships.network.BindsTo + eca_trx11_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 10 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx11 + relationship: tosca.relationships.network.BindsTo + eca_trx12_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 11 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx12 + relationship: tosca.relationships.network.BindsTo + arb_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: ARB_volume_type + size: '(get_input : arb_volume_size) * 1024' + eca_trx12_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 11 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx12 + relationship: tosca.relationships.network.BindsTo + eca_trx11_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 10 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx11 + relationship: tosca.relationships.network.BindsTo + eca_trx12_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 11 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx12 + relationship: tosca.relationships.network.BindsTo + mmsc4_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - mmsc_oam_ips + - 3 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_mmsc4 + relationship: tosca.relationships.network.BindsTo + cmaui1_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 1 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui1 + relationship: tosca.relationships.network.BindsTo + mmsc3_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - mmsc_oam_ips + - 2 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_mmsc3 + relationship: tosca.relationships.network.BindsTo + eca_trx15_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 14 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx15 + relationship: tosca.relationships.network.BindsTo + mmsc3_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - mmsc_mms_traffic_net_ips + - 2 + network: mms_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: mms_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_mmsc3 + relationship: tosca.relationships.network.BindsTo + mmsc4_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - mmsc_mms_traffic_net_ips + - 3 + network: mms_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: mms_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_mmsc4 + relationship: tosca.relationships.network.BindsTo + eca_trx15_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 14 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx15 + relationship: tosca.relationships.network.BindsTo + eca_trx16_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 15 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx16 + relationship: tosca.relationships.network.BindsTo + arb_mgmt_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - arb_oam_ips + - 0 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: arb_instance + relationship: tosca.relationships.network.BindsTo + lb2_mgmt_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - lb_oam_ips + - 1 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: lb2_instance + relationship: tosca.relationships.network.BindsTo + mmsc5_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: MMSC_volume_type + size: '(get_input : mmsc_cinder_volume_size) * 1024' + eca_trx7_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 6 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx7 + relationship: tosca.relationships.network.BindsTo + oam1_mgmt_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_oam_ips + - 0 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: oam1_instance + relationship: tosca.relationships.network.BindsTo + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + metadata: + vnf_id: + get_input: vnf_id + user_data_format: RAW + name: + get_input: + - cmaui_names + - 0 + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: cmaui_volume + relationship: cmaui_volume_attachment + eca_trx7_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 6 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx7 + relationship: tosca.relationships.network.BindsTo + eca_trx7_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 6 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx7 + relationship: tosca.relationships.network.BindsTo + cmaui_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: CMAUI_volume_type + size: '(get_input : cmaui_cinder_volume_size) * 1024' + eca_trx3_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 2 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx3 + relationship: tosca.relationships.network.BindsTo + eca_trx3_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 2 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx3 + relationship: tosca.relationships.network.BindsTo + eca_trx3_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 2 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx3 + relationship: tosca.relationships.network.BindsTo + mmsc1_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: MMSC_volume_type + size: '(get_input : mmsc_cinder_volume_size) * 1024' + nems_imap_net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + network_name: + get_input: nems_imap_name + subnets: + nems_imap_network_ip_subnet: + name: + get_input: nems_imap_name + cidr: + get_input: nems_imap_cidr + allocation_pools: + - start: + get_input: nems_imap_start + end: + get_input: nems_imap_end + server_cmaui1: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + metadata: + vnf_id: + get_input: vnf_id + user_data_format: RAW + name: + get_input: + - cmaui_names + - 1 + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: cmaui1_volume + relationship: cmaui1_volume_attachment + lb2_dmz_protected_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - lb_dmz_protected_ips + - 1 + allowed_address_pairs: + - ip_address: + get_input: + - mmsc_dmz_protected_virtual_server_ips + - 0 + - ip_address: + get_input: + - mmsc_dmz_protected_virtual_server_ips + - 1 + - ip_address: + get_input: + - mmsc_dmz_protected_virtual_server_ips + - 2 + - ip_address: + get_input: + - mmsc_dmz_protected_snat_ips + - 0 + - ip_address: + get_input: + - mmsc_dmz_protected_snat_ips + - 1 + - ip_address: + get_input: + - mmsc_dmz_protected_snat_ips + - 2 + - ip_address: + get_input: + - mmsc_dmz_protected_snat_ips + - 3 + network: + get_input: dmz_protected_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: lb2_instance + relationship: tosca.relationships.network.BindsTo + lb1_eca_traffic_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: eca_traffic_net_local_ip1 + allowed_address_pairs: + - ip_address: + get_input: eca_traffic_net_floating_ip + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: lb1_instance + relationship: tosca.relationships.network.BindsTo + lb1_dmz_protected_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - lb_dmz_protected_ips + - 0 + allowed_address_pairs: + - ip_address: + get_input: + - mmsc_dmz_protected_virtual_server_ips + - 0 + - ip_address: + get_input: + - mmsc_dmz_protected_virtual_server_ips + - 1 + - ip_address: + get_input: + - mmsc_dmz_protected_virtual_server_ips + - 2 + - ip_address: + get_input: + - mmsc_dmz_protected_snat_ips + - 0 + - ip_address: + get_input: + - mmsc_dmz_protected_snat_ips + - 1 + - ip_address: + get_input: + - mmsc_dmz_protected_snat_ips + - 2 + - ip_address: + get_input: + - mmsc_dmz_protected_snat_ips + - 3 + network: + get_input: dmz_protected_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: lb1_instance + relationship: tosca.relationships.network.BindsTo + lb1_mms_traffic_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: mms_traffic_net_local_ip1 + allowed_address_pairs: + - ip_address: + get_input: mms_traffic_net_floating_ip + network: mms_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: mms_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: lb1_instance + relationship: tosca.relationships.network.BindsTo + eca_mgmt_net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + network_name: + get_input: eca_mgmt_name + subnets: + eca_mgmt_network_ip_subnet: + name: + get_input: eca_mgmt_name + cidr: + get_input: eca_mgmt_cidr + allocation_pools: + - start: + get_input: eca_mgmt_start + end: + get_input: eca_mgmt_end + eca_trx1_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 0 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx1 + relationship: tosca.relationships.network.BindsTo + nems2_fe_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: NEMS_FE_volume_type + size: '(get_input : nems_volume_size) * 1024' + server_nems_be1: + type: org.openecomp.resource.vfc.nodes.heat.nems_be + properties: + flavor: + get_input: nems_be_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: nems_be_image + metadata: + vnf_id: + get_input: vnf_id + user_data_format: RAW + name: + get_input: nems_be_names + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: nems_be_volume + relationship: nems_volume_attachment + server_nems_fe1: + type: org.openecomp.resource.vfc.nodes.heat.nems_fe + properties: + flavor: + get_input: nems_fe_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: nems_fe_image + metadata: + vnf_id: + get_input: vnf_id + user_data_format: RAW + name: + get_input: + - nems_fe_names + - 0 + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: nems1_fe_volume + relationship: nems1_fe_volume_attachment + oam2_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: ECA_OAM_volume_type + size: '(get_input : oam_volume_size) * 1024' + server_nems_fe2: + type: org.openecomp.resource.vfc.nodes.heat.nems_fe + properties: + flavor: + get_input: nems_fe_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: nems_fe_image + metadata: + vnf_id: + get_input: vnf_id + user_data_format: RAW + name: + get_input: + - nems_fe_names + - 1 + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: nems2_fe_volume + relationship: nems2_fe_volume_attachment + oam1_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: ECA_OAM_volume_type + size: '(get_input : oam_volume_size) * 1024' + lb2_cor_direct_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - lb_cor_direct_ips + - 1 + allowed_address_pairs: + - ip_address: + get_input: + - mmsc_core_virtual_server_ips + - 0 + - ip_address: + get_input: + - mmsc_core_virtual_server_ips + - 1 + - ip_address: + get_input: + - mmsc_core_snat_ips + - 0 + - ip_address: + get_input: + - mmsc_core_snat_ips + - 1 + - ip_address: + get_input: + - mmsc_core_snat_ips + - 2 + - ip_address: + get_input: + - mmsc_core_snat_ips + - 3 + - ip_address: + get_input: + - mmsc_core_snat_ips + - 4 + network: + get_input: cor_direct_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: lb2_instance + relationship: tosca.relationships.network.BindsTo + eca_trx20_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 19 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx20 + relationship: tosca.relationships.network.BindsTo + eca_trx20_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 19 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx20 + relationship: tosca.relationships.network.BindsTo + eca_trx20_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 19 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx20 + relationship: tosca.relationships.network.BindsTo + eca_trx8_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 7 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx8 + relationship: tosca.relationships.network.BindsTo + oam1_int_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_eca_mgmt_ips + - 0 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: oam1_instance + relationship: tosca.relationships.network.BindsTo + eca_trx6_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 5 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx6 + relationship: tosca.relationships.network.BindsTo + lb2_nems_user_web_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: nems_user_web_net_local_ip2 + allowed_address_pairs: + - ip_address: + get_input: nems_user_web_net_floating_ip + network: nems_user_web_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: nems_user_web_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: lb2_instance + relationship: tosca.relationships.network.BindsTo + lb2_instance: + type: org.openecomp.resource.vfc.nodes.heat.lb + properties: + flavor: + get_input: lb_flavor_name + availability_zone: + get_input: availability_zone_0 + image: + get_input: lb_image_name + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - lb_names + - 1 + eca_trx6_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 5 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx6 + relationship: tosca.relationships.network.BindsTo + eca_trx8_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 7 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx8 + relationship: tosca.relationships.network.BindsTo + lb1_nems_user_web_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: nems_user_web_net_local_ip1 + allowed_address_pairs: + - ip_address: + get_input: nems_user_web_net_floating_ip + network: nems_user_web_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: nems_user_web_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: lb1_instance + relationship: tosca.relationships.network.BindsTo + eca_trx6_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 5 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx6 + relationship: tosca.relationships.network.BindsTo + eca_trx8_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 7 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx8 + relationship: tosca.relationships.network.BindsTo + arb_int_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - arb_eca_mgmt_ips + - 0 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: arb_instance + relationship: tosca.relationships.network.BindsTo + ha_net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + network_name: + get_input: ha_net_name + subnets: + ha_net_ip_subnet: + name: + get_input: ha_net_name + cidr: + get_input: ha_net_cidr + allocation_pools: + - start: + get_input: ha_net_start + end: + get_input: ha_net_end + server_mmsc1: + type: org.openecomp.resource.vfc.nodes.heat.mmsc + properties: + flavor: + get_input: mmsc_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: mmsc_image + metadata: + vnf_id: + get_input: vnf_id + user_data_format: RAW + name: + get_input: + - mmsc_names + - 0 + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: mmsc1_volume + relationship: mmsc1_volume_attachment + nems_be1_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: nems_be_oam_ips + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_nems_be1 + relationship: tosca.relationships.network.BindsTo + eca_trx2_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 1 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx2 + relationship: tosca.relationships.network.BindsTo + server_mmsc2: + type: org.openecomp.resource.vfc.nodes.heat.mmsc + properties: + flavor: + get_input: mmsc_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: mmsc_image + metadata: + vnf_id: + get_input: vnf_id + user_data_format: RAW + name: + get_input: + - mmsc_names + - 1 + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: mmsc2_volume + relationship: mmsc2_volume_attachment + nems_be1_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: nems_be_nems_internal_net_ips + network: nems_internal_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: nems_internal_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_nems_be1 + relationship: tosca.relationships.network.BindsTo + eca_trx2_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 1 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx2 + relationship: tosca.relationships.network.BindsTo + eca_trx4_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 3 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx4 + relationship: tosca.relationships.network.BindsTo + server_mmsc3: + type: org.openecomp.resource.vfc.nodes.heat.mmsc + properties: + flavor: + get_input: mmsc_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: mmsc_image + metadata: + vnf_id: + get_input: vnf_id + user_data_format: RAW + name: + get_input: + - mmsc_names + - 2 + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: mmsc3_volume + relationship: mmsc3_volume_attachment + nems_be1_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: nems_be_nems_imap_net_ips + network: nems_imap_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: nems_imap_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_nems_be1 + relationship: tosca.relationships.network.BindsTo + eca_trx2_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 1 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx2 + relationship: tosca.relationships.network.BindsTo + eca_trx4_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 3 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx4 + relationship: tosca.relationships.network.BindsTo + server_eca_trx20: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 19 + eca_trx4_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 3 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx4 + relationship: tosca.relationships.network.BindsTo + nems_be_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: NEMS_BE_volume_type + size: '(get_input : nems_be_volume_size) * 1024' + server_mmsc4: + type: org.openecomp.resource.vfc.nodes.heat.mmsc + properties: + flavor: + get_input: mmsc_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: mmsc_image + metadata: + vnf_id: + get_input: vnf_id + user_data_format: RAW + name: + get_input: + - mmsc_names + - 3 + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: mmsc4_volume + relationship: mmsc4_volume_attachment + server_mmsc5: + type: org.openecomp.resource.vfc.nodes.heat.mmsc + properties: + flavor: + get_input: mmsc_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: mmsc_image + metadata: + vnf_id: + get_input: vnf_id + user_data_format: RAW + name: + get_input: + - mmsc_names + - 4 + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: mmsc5_volume + relationship: mmsc5_volume_attachment + oam2_int_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_eca_mgmt_ips + - 1 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: oam2_instance + relationship: tosca.relationships.network.BindsTo + eca_trx17_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 16 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx17 + relationship: tosca.relationships.network.BindsTo + eca_trx18_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 17 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx18 + relationship: tosca.relationships.network.BindsTo + lb1_cor_direct_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - lb_cor_direct_ips + - 0 + allowed_address_pairs: + - ip_address: + get_input: + - mmsc_core_virtual_server_ips + - 0 + - ip_address: + get_input: + - mmsc_core_virtual_server_ips + - 1 + - ip_address: + get_input: + - mmsc_core_snat_ips + - 0 + - ip_address: + get_input: + - mmsc_core_snat_ips + - 1 + - ip_address: + get_input: + - mmsc_core_snat_ips + - 2 + - ip_address: + get_input: + - mmsc_core_snat_ips + - 3 + - ip_address: + get_input: + - mmsc_core_snat_ips + - 4 + network: + get_input: cor_direct_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: lb1_instance + relationship: tosca.relationships.network.BindsTo + mmsc1_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - mmsc_oam_ips + - 0 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_mmsc1 + relationship: tosca.relationships.network.BindsTo + eca_trx17_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 16 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx17 + relationship: tosca.relationships.network.BindsTo + eca_trx18_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 17 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx18 + relationship: tosca.relationships.network.BindsTo + mmsc1_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - mmsc_mms_traffic_net_ips + - 0 + network: mms_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: mms_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_mmsc1 + relationship: tosca.relationships.network.BindsTo + mmsc2_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - mmsc_mms_traffic_net_ips + - 1 + network: mms_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: mms_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_mmsc2 + relationship: tosca.relationships.network.BindsTo + eca_trx17_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 16 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx17 + relationship: tosca.relationships.network.BindsTo + eca_trx18_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 17 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx18 + relationship: tosca.relationships.network.BindsTo + mms_traffic_net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + network_name: + get_input: mms_traffic_net_name + subnets: + mms_traffic_ip_subnet: + name: + get_input: mms_traffic_net_name + cidr: + get_input: mms_traffic_net_cidr + allocation_pools: + - start: + get_input: mms_traffic_start + end: + get_input: mms_traffic_end + cmaui_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + eca_trx10_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 9 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx10 + relationship: tosca.relationships.network.BindsTo + server_eca_trx13: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 12 + lb1_instance: + type: org.openecomp.resource.vfc.nodes.heat.lb + properties: + flavor: + get_input: lb_flavor_name + availability_zone: + get_input: availability_zone_0 + image: + get_input: lb_image_name + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - lb_names + - 0 + eca_trx10_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 9 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx10 + relationship: tosca.relationships.network.BindsTo + server_eca_trx14: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 13 + server_eca_trx15: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 14 + nems1_fe_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: NEMS_FE_volume_type + size: '(get_input : nems_volume_size) * 1024' + eca_trx10_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 9 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx10 + relationship: tosca.relationships.network.BindsTo + server_eca_trx16: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 15 + server_eca_trx10: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 9 + server_eca_trx11: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 10 + server_eca_trx12: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 11 + eca_trx14_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 13 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx14 + relationship: tosca.relationships.network.BindsTo + eca_trx13_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 12 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx13 + relationship: tosca.relationships.network.BindsTo + eca_trx14_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 13 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx14 + relationship: tosca.relationships.network.BindsTo + mmsc5_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - mmsc_mms_traffic_net_ips + - 4 + network: mms_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: mms_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_mmsc5 + relationship: tosca.relationships.network.BindsTo + eca_trx13_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 12 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx13 + relationship: tosca.relationships.network.BindsTo + mmsc5_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - mmsc_oam_ips + - 4 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_mmsc5 + relationship: tosca.relationships.network.BindsTo + eca_trx13_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 12 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx13 + relationship: tosca.relationships.network.BindsTo + eca_trx14_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 13 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx14 + relationship: tosca.relationships.network.BindsTo + mmsc2_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - mmsc_oam_ips + - 1 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_mmsc2 + relationship: tosca.relationships.network.BindsTo + server_eca_trx17: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 16 + server_eca_trx18: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 17 + server_eca_trx19: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 18 + eca_trx9_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 8 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx9 + relationship: tosca.relationships.network.BindsTo + eca_trx9_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 8 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx9 + relationship: tosca.relationships.network.BindsTo + eca_trx9_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 8 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx9 + relationship: tosca.relationships.network.BindsTo + lb2_nems_traffic_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: nems_traffic_net_local_ip2 + allowed_address_pairs: + - ip_address: + get_input: nems_traffic_net_floating_ip + network: nems_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: nems_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: lb2_instance + relationship: tosca.relationships.network.BindsTo + eca_trx5_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 4 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx5 + relationship: tosca.relationships.network.BindsTo + eca_traffic_net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + network_name: + get_input: eca_traffic_name + subnets: + eca_traffic_ip_subnet: + name: + get_input: eca_traffic_name + cidr: + get_input: eca_traffic_cidr + allocation_pools: + - start: + get_input: eca_traffic_start + end: + get_input: eca_traffic_end + eca_trx1_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 0 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx1 + relationship: tosca.relationships.network.BindsTo + eca_trx5_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 4 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx5 + relationship: tosca.relationships.network.BindsTo + oam1_instance: + type: org.openecomp.resource.vfc.nodes.heat.eca + properties: + flavor: + get_input: oam_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: oam_image_name + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_names + - 0 + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: oam1_volume + relationship: oam1_volume_attachment + eca_trx1_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 0 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx1 + relationship: tosca.relationships.network.BindsTo + eca_trx5_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 4 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx5 + relationship: tosca.relationships.network.BindsTo + mmsc3_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: MMSC_volume_type + size: '(get_input : mmsc_cinder_volume_size) * 1024' + relationship_templates: + mmsc1_volume_attachment: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: mmsc1_volume + instance_uuid: server_mmsc1 + mmsc4_volume_attachment: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: mmsc4_volume + instance_uuid: server_mmsc4 + arb_volume_attachment: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: arb_volume + instance_uuid: arb_instance + cmaui_volume_attachment: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: cmaui_volume + instance_uuid: server_cmaui + nems1_fe_volume_attachment: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: nems1_fe_volume + instance_uuid: server_nems_fe1 + mmsc3_volume_attachment: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: mmsc3_volume + instance_uuid: server_mmsc3 + oam2_volume_attachment: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: oam2_volume + instance_uuid: oam2_instance + cmaui1_volume_attachment: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: cmaui1_volume + instance_uuid: server_cmaui1 + nems_volume_attachment: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: nems_be_volume + instance_uuid: server_nems_be1 + oam1_volume_attachment: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: oam1_volume + instance_uuid: oam1_instance + nems2_fe_volume_attachment: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: nems2_fe_volume + instance_uuid: server_nems_fe2 + mmsc5_volume_attachment: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: mmsc5_volume + instance_uuid: server_mmsc5 + mmsc2_volume_attachment: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: mmsc2_volume + instance_uuid: server_mmsc2 + groups: + MMSC_Capacity_Line: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/MMSC_Capacity_Line.yml + description: | + HOT template that creates internal networks, load balancers and servers for vMMSC capacity Line 1. #11/23: updated the network definition to meet the juniper best practices way of defining the gateway, DHCP enable for internal networks (L457-L547) + members: + - server_eca_trx9 + - server_eca_trx8 + - server_eca_trx7 + - server_eca_trx6 + - server_eca_trx5 + - nems_internal_net + - server_eca_trx4 + - server_eca_trx3 + - server_eca_trx2 + - lb1_mgmt_port + - lb2_mms_traffic_port + - nems_fe1_port_1 + - nems_fe2_port_3 + - server_eca_trx1 + - nems_fe1_port_2 + - nems_fe2_port_2 + - nems_fe2_port_1 + - nems_fe1_port_0 + - nems_fe2_port_0 + - nems_fe1_port_3 + - nems_fe1_port_4 + - nems_fe2_port_4 + - mmsc4_volume + - lb2_eca_traffic_port + - lb2_ha_net_port + - nems_user_web_net + - lb1_ha_net_port + - mmsc2_volume + - nems_traffic_net + - eca_trx16_port_0 + - eca_trx19_port_2 + - eca_trx16_port_1 + - eca_trx19_port_1 + - eca_trx15_port_0 + - eca_trx19_port_0 + - lb1_nems_traffic_port + - eca_trx11_port_1 + - eca_trx11_port_2 + - eca_trx12_port_2 + - eca_trx12_port_1 + - eca_trx11_port_0 + - eca_trx12_port_0 + - mmsc4_port_0 + - mmsc3_port_0 + - eca_trx15_port_2 + - mmsc3_port_1 + - mmsc4_port_1 + - eca_trx15_port_1 + - eca_trx16_port_2 + - lb2_mgmt_port + - mmsc5_volume + - eca_trx7_port_2 + - eca_trx7_port_0 + - eca_trx7_port_1 + - eca_trx3_port_1 + - eca_trx3_port_0 + - eca_trx3_port_2 + - mmsc1_volume + - nems_imap_net + - lb2_dmz_protected_port + - lb1_eca_traffic_port + - lb1_dmz_protected_port + - lb1_mms_traffic_port + - eca_trx1_port_2 + - nems2_fe_volume + - server_nems_be1 + - server_nems_fe1 + - server_nems_fe2 + - lb2_cor_direct_port + - eca_trx20_port_0 + - eca_trx20_port_2 + - eca_trx20_port_1 + - eca_trx8_port_0 + - eca_trx6_port_0 + - lb2_nems_user_web_port + - lb2_instance + - eca_trx6_port_2 + - eca_trx8_port_2 + - lb1_nems_user_web_port + - eca_trx6_port_1 + - eca_trx8_port_1 + - ha_net + - server_mmsc1 + - nems_be1_port_0 + - eca_trx2_port_0 + - server_mmsc2 + - nems_be1_port_1 + - eca_trx2_port_1 + - eca_trx4_port_1 + - server_mmsc3 + - nems_be1_port_2 + - eca_trx2_port_2 + - eca_trx4_port_2 + - server_eca_trx20 + - eca_trx4_port_0 + - nems_be_volume + - server_mmsc4 + - server_mmsc5 + - eca_trx17_port_0 + - eca_trx18_port_2 + - lb1_cor_direct_port + - mmsc1_port_0 + - eca_trx17_port_2 + - eca_trx18_port_0 + - mmsc1_port_1 + - mmsc2_port_1 + - eca_trx17_port_1 + - eca_trx18_port_1 + - mms_traffic_net + - eca_trx10_port_1 + - server_eca_trx13 + - lb1_instance + - eca_trx10_port_0 + - server_eca_trx14 + - server_eca_trx15 + - nems1_fe_volume + - eca_trx10_port_2 + - server_eca_trx16 + - server_eca_trx10 + - server_eca_trx11 + - server_eca_trx12 + - eca_trx14_port_1 + - eca_trx13_port_0 + - eca_trx14_port_0 + - mmsc5_port_1 + - eca_trx13_port_1 + - mmsc5_port_0 + - eca_trx13_port_2 + - eca_trx14_port_2 + - mmsc2_port_0 + - server_eca_trx17 + - server_eca_trx18 + - server_eca_trx19 + - eca_trx9_port_0 + - eca_trx9_port_1 + - eca_trx9_port_2 + - lb2_nems_traffic_port + - eca_trx5_port_2 + - eca_traffic_net + - eca_trx1_port_1 + - eca_trx5_port_1 + - eca_trx1_port_0 + - eca_trx5_port_0 + - mmsc3_volume + eca_oam: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/eca_oam.yaml + description: This stack creates two ECA OAM VM and one ARB VM + members: + - arb_mgmt_port + - oam2_mgmt_port + - arb_instance + - arb_volume + - oam1_instance + - oam2_volume + - oam1_volume + - oam1_int_port + - oam1_mgmt_port + - arb_int_port + - oam2_int_port + - oam2_instance + SG_ECA_MGMT: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/SG_ECA_MGMT.yaml + description: | + HOT template that creates Security Group and ECA network + members: + - mms_security_group + - eca_mgmt_net + cmaui: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/cmaui.yml + description: cmaui server template for vMMSC + members: + - server_cmaui1 + - server_cmaui + - cmaui1_port_0 + - cmaui_volume + - cmaui1_volume + - cmaui_port_0 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/MANIFEST.json new file mode 100644 index 0000000000..167ae4e9d8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/MANIFEST.json @@ -0,0 +1,37 @@ +{ + "name": "multiple_not_nested", + "description": "multiple heat files in zip, no nesting", + "version": "2013-05-23", + "data": [{ + "file": "cmaui.yml", + "type": "HEAT", + "data": [{ + "file": "cmaui.env", + "type": "HEAT_ENV" + }] + }, + { + "file": "eca_oam.yaml", + "type": "HEAT", + "data": [{ + "file": "eca_oam.env", + "type": "HEAT_ENV" + }] + }, + { + "file": "MMSC_Capacity_Line.yml", + "type": "HEAT", + "data": [{ + "file": "MMSC_Capacity_Line_1.env", + "type": "HEAT_ENV" + }] + }, + { + "file": "SG_ECA_MGMT.yaml", + "type": "HEAT", + "data": [{ + "file": "sg_eca_mgmt.env", + "type": "HEAT_ENV" + }] + }] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/MMSC_Capacity_Line.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/MMSC_Capacity_Line.yml new file mode 100644 index 0000000000..9e36eb9cd4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/MMSC_Capacity_Line.yml @@ -0,0 +1,3219 @@ +heat_template_version: 2013-05-23 + +description: > + HOT template that creates internal networks, load balancers and servers for vMMSC capacity Line 1. + #11/23: updated the network definition to meet the juniper best practices way of defining the gateway, DHCP enable for internal networks (L457-L547) + +parameters: + vnf_id: + type: string + description: Unique ID for this VNF instance + default: This_is_the_MMSC_id + oam_net_name: + type: string + label: UID of OAM network + description: UID of OAM network + oam_network_netmask: + type: string + label: oam network netmask + description: oam network gateway + oam_network_gateway: + type: string + label: oam network gateway + description: oam network gateway + oam_network_route_1: + type: string + label: oam network route 1 + description: oam network route 1 + oam_network_route_2: + type: string + label: oam network route 2 + description: oam network route 2 + external_dns: + type: string + label: dns server + description: dns server for MMSC + external_ntp: + type: string + label: ntp server + description: ntp server for MMSC + lb_oam_ips: + type: comma_delimited_list + label: management network ips for mmsc lb + description: the ips of the management network for mmsc lb + dmz_protected_net_name: + type: string + label: UID of dmz_protected network + description: UID of dmz_protected network + lb_dmz_protected_ips: + type: comma_delimited_list + label: dmz protected network local ips for lb VM + description: local ips of the dmz protected network for lb VM + cor_direct_net_name: + type: string + label: cor direct net UID + description: cor direct net + lb_cor_direct_ips: + type: comma_delimited_list + label: cor direct network local ips for lb VM + description: local ips of cor direct network for lb VM + mms_traffic_net_name: + type: string + label: Name of MMS traffic network + description: Name of MMS traffic network + mms_traffic_net_cidr: + type: string + label: MMS traffic network address (CIDR notation) + description: MMS traffic network address (CIDR notation) + mms_traffic_netmask: + type: string + label: MMS traffic network subnet mask + description: MMS traffic network subnet mask + mms_traffic_net_gateway: + type: string + label: MMS traffic network gateway address + description: MMS traffic network gateway address + mms_traffic_start: + type: string + label: mmsc traffic start IP + description: mmsc traffic start IP + mms_traffic_end: + type: string + label: mmsc traffic end IP + description: mmsc traffic end IP + mms_traffic_net_local_ip1: + type: string + label: mmsc traffic network local ip1 + description: the local ip1 of the mmsc traffic network + mms_traffic_net_local_ip2: + type: string + label: mmsc traffic network local ip2 + description: the local ip2 of the mmsc traffic network + mms_traffic_net_floating_ip: + type: string + label: mmsc traffic floating ip + description: mmsc traffic floating ip + nems_internal_name: + type: string + label: nems internal network name + description: nems internal network name + nems_internal_start: + type: string + label: nems internal start + description: nems internal start + nems_internal_end: + type: string + label: nems internal end + description: nems internal end + nems_internal_cidr: + type: string + label: nems ineternal cidr + description: nems internal cidr + nems_internal_netmask: + type: string + label: NEMS internal network subnet mask + description: NEMS internal network subnet mask + nems_internal_gateway: + type: string + label: nems internal gw + description: nems internal gw + nems_traffic_name: + type: string + label: nems traffic name + description: nems traffic name + nems_traffic_start: + type: string + label: nems traffic start + description: nems traffic start + nems_traffic_end: + type: string + label: nems traffic end + description: nems traffic end + nems_traffic_cidr: + type: string + label: nems traffic cidr + description: nems traffic cidr + nems_traffic_netmask: + type: string + label: NEMS traffic network subnet mask + description: NEMS traffic network subnet mask + nems_traffic_gateway: + type: string + label: NEMS traffic network gateway + description: NEMS traffic network gateway + nems_traffic_net_local_ip1: + type: string + label: nems traffic network local ip1 + description: the local ip1 of the nems traffic network + nems_traffic_net_local_ip2: + type: string + label: nems traffic network local ip2 + description: the local ip2 of the nems traffic network + nems_traffic_net_floating_ip: + type: string + label: nems traffic floating ip + description: nems traffic floating ip + nems_user_web_name: + type: string + label: nems user web name + description: nems user web name + nems_user_web_start: + type: string + label: nems user web start + description: nems user web end + nems_user_web_end: + type: string + label: nems user web end + description: nems user web end + nems_user_web_cidr: + type: string + label: nems user web cidr + description: nems user web cidr + nems_user_web_netmask: + type: string + label: NEMS user web network subnet mask + description: NEMS user web network subnet mask + nems_user_web_gateway: + type: string + label: NEMS user web network gateway + description: NEMS user web network gateway + nems_user_web_net_local_ip1: + type: string + label: nems user web network local ip1 + description: the local ip1 of the nems user web network + nems_user_web_net_local_ip2: + type: string + label: nems user web network local ip2 + description: the local ip2 of the nems user web network + nems_user_web_net_floating_ip: + type: string + label: nems user web floating ip + description: nems user web floating ip + nems_imap_name: + type: string + label: nems imap name + description: nems imap name + nems_imap_netmask: + type: string + label: nems imap subnet mask + description: nems imap subnet mask + nems_imap_start: + type: string + label: nems imap start + description: nems imap start + nems_imap_end: + type: string + label: nems imap end + description: nems imap end + nems_imap_cidr: + type: string + label: nems imap cidr + description: nems imap cidr + nems_imap_gateway: + type: string + label: nems imap gateway + description: nems imap gateway + eca_traffic_name: + type: string + label: eca traffic name + description: eca traffic name + eca_traffic_start: + type: string + label: eca traffic start + description: eca traffic start + eca_traffic_end: + type: string + label: eca traffic end + description: eca traffic end + eca_traffic_cidr: + type: string + label: eca traffic cidr + description: eca traffic cidr + eca_traffic_netmask: + type: string + label: ECA traffic network subnet mask + description: ECA traffic network subnet mask + eca_traffic_net_gateway: + type: string + label: eca_traffic network gateway + description: eca_traffic network gateway + eca_traffic_net_local_ip1: + type: string + label: eca traffic network local ip1 + description: the local ip1 of the eca traffic network + eca_traffic_net_local_ip2: + type: string + label: eca traffic network local ip2 + description: the local ip2 of the eca traffic network + eca_traffic_net_floating_ip: + type: string + label: eca traffic floating ip + description: eca traffic floating ip + ha_net_name: + type: string + label: ha_failover network name + description: ha_failover network name + ha_net_start: + type: string + label: ha net start + description: ha net start + ha_net_end: + type: string + label: ha net end + description: ha net end + ha_net_cidr: + type: string + label: ha net cidr + description: ha net cidr + ha_net_local_ip1: + type: string + label: ha net network local ip1 + description: the local ip1 of the ha network + ha_net_local_ip2: + type: string + label: ha net network local ip2 + description: the local ip2 of the ha network + lb_names: + type: comma_delimited_list + label: MMSC load balancer instance names + description: MMSC load balancer instance names + lb_image_name: + type: string + label: MMSC load balancer image name + description: MMSC load balancer image name + lb_flavor_name: + type: string + label: Load balancer flavor name + description: the flavor name of MMSC load balancer instance + availability_zone_0: + type: string + label: MMSC availabilityzone name + description: MMSC availabilityzone name + security_group_name: + type: string + label: MMSC security group name + description: MMSC security group name + mmsc_image: + type: string + label: Image for MMSC server + description: Image for MMSC server + mmsc_flavor: + type: string + label: Flavor for MMSC server + description: Flavor for MMSC server + mmsc_cinder_volume_size: + type: number + label: MMSC Cinder volume size + description: the size of the MMSC Cinder volume + nems_fe_image: + type: string + label: Image for NEMS FE server + description: Image for NEMS FE server + nems_fe_flavor: + type: string + label: Flavor for NEMS FE server + description: Flavor for NEMS FE server + nems_be_image: + type: string + label: Image for NEMS BE server + description: Image for NEMS BE server + nems_be_flavor: + type: string + label: Flavor for NEMS BE server + description: Flavor for NEMS BE server + eca_trx_image: + type: string + label: Image for ECA TRX server + description: Image for ECA TRX server + eca_trx_flavor: + type: string + label: Flavor for ECA TRX server + description: Flavor for ECA TRX server + mmsc_oam_ips: + type: comma_delimited_list + label: MMSC oam_net IP addresses + description: MMSC oam_net IP addresses + mmsc_mms_traffic_net_ips: + type: comma_delimited_list + label: MMSC mms_traffic_net IP addresses + description: MMSC mms_traffic_net IP addresses + nems_fe_names: + type: comma_delimited_list + label: NEMS_FE server names + description: NEMS_FE server names + nems_fe_node_roles: + type: comma_delimited_list + label: nems fe node roles + description: nems fe node roles + nems_fe_oam_ips: + type: comma_delimited_list + label: OAM_net IP for NEMS_FE + description: OAM_net IP for NEMS_FE + nems_fe_nems_traffic_net_ips: + type: comma_delimited_list + label: nems_traffic_net IPs for NEMS_FE + description: nems_traffic_net IPs for NEMS_FE + nems_fe_nems_user_web_net_ips: + type: comma_delimited_list + label: nems_web_user_net IPs for NEMS_FE + description: nems_web_user_net IPs for NEMS_FE + nems_fe_nems_internal_net_ips: + type: comma_delimited_list + label: nems_internal_net IPs for NEMS_FE + description: nems_internal_net IPs for NEMS_FE + nems_fe_nems_imap_net_ips: + type: comma_delimited_list + label: nems_imap_net IPs for NEMS_FE + description: nems_imap_net IPs for NEMS_FE + nems_be_names: + type: string + label: NEMS_BE server names + description: NEMS_BE server names + nems_be_node_roles: + type: string + label: nems node roles + description: nems node roles + nems_be_oam_ips: + type: string + label: OAM net IPs for NEMS_BE + description: OAM net IPs for NEMS_BE + nems_be_nems_internal_net_ips: + type: string + label: nems internal net IPs for NEMS_BE + description: nems internal net IPs for NEMS_BE + nems_be_nems_imap_net_ips: + type: string + label: nems imap_net IPs for NEMS_BE + description: nems imap net IPs for NEMS_BE + eca_trx_oam_ips: + type: comma_delimited_list + label: OAM net IP for ECA_TRX + description: OAM net IP for ECA_TRX + eca_trx_mgmt_ips: + type: comma_delimited_list + label: eca mgmt net IP for ECA_TRX + description: eca mgmt net IP for ECA_TRX + timezone: + type: string + label: timezone + description: timezone + eca_trx_names: + type: comma_delimited_list + label: ECA_TRX server names + description: ECA_TRX server names + eca_trx_eca_traffic_net_ips: + type: comma_delimited_list + label: eca traffic net IPs for ECA_TRX + description: eca traffic net IPs for ECA_TRX + mmsc_names: + type: comma_delimited_list + label: MMSC server names + description: MMSC server names + nems_volume_size: + type: number + label: nems fe volume size + description: nems fe volume size + nems_be_volume_size: + type: number + label: nems be volume size + description: nems be volume size + MMSC_volume_type: + type: string + label: MMSC vm volume type + description: the name of the target volume backend + NEMS_FE_volume_type: + type: string + label: nems fe vm volume type + description: the name of the target volume backend + NEMS_BE_volume_type: + type: string + label: nems be vm volume type + description: the name of the target volume backend + mmsc_core_virtual_server_ips: + type: comma_delimited_list + label: mmsc core virtual server ips + description: mmsc core virtual server ips + mmsc_core_snat_ips: + type: comma_delimited_list + label: mmsc core snat ips + description: mmsc core snat ips + mmsc_dmz_protected_virtual_server_ips: + type: comma_delimited_list + label: mmsc dmz_protected virtual server ips + description: mmsc dmz_protected virtual server ips + mmsc_dmz_protected_snat_ips: + type: comma_delimited_list + label: mmsc dmz_protected snat ips + description: mmsc dmz_protected snat ips + eca_mgmt_net_name: + type: string + label: eca management network ID + description: Network ID for eca management + +resources: + mms_traffic_net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: mms_traffic_net_name } + + mms_traffic_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: mms_traffic_net_name} + network_id: { get_resource: mms_traffic_net } + cidr: { get_param: mms_traffic_net_cidr } + allocation_pools: [{"start": {get_param: mms_traffic_start}, "end": {get_param: mms_traffic_end}}] + + nems_internal_net: + type: OS::Contrail::VirtualNetwork + properties: + name: {get_param: nems_internal_name} + + nems_internal_network_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: nems_internal_name} + allocation_pools: [{"start": {get_param: nems_internal_start}, "end": {get_param: nems_internal_end}}] + cidr: {get_param: nems_internal_cidr} + network_id: {get_resource: nems_internal_net} + + nems_traffic_net: + type: OS::Contrail::VirtualNetwork + properties: + name: {get_param: nems_traffic_name} + + nems_traffic_network_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: nems_traffic_name} + allocation_pools: [{"start": {get_param: nems_traffic_start}, "end": {get_param: nems_traffic_end}}] + cidr: {get_param: nems_traffic_cidr} + network_id: {get_resource: nems_traffic_net} + + nems_user_web_net: + type: OS::Contrail::VirtualNetwork + properties: + name: {get_param: nems_user_web_name} + + nems_user_web_network_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: nems_user_web_name} + allocation_pools: [{"start": {get_param: nems_user_web_start}, "end": {get_param: nems_user_web_end}}] + cidr: {get_param: nems_user_web_cidr} + network_id: {get_resource: nems_user_web_net} + + nems_imap_net: + type: OS::Contrail::VirtualNetwork + properties: + name: {get_param: nems_imap_name} + + nems_imap_network_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: nems_imap_name} + allocation_pools: [{"start": {get_param: nems_imap_start}, "end": {get_param: nems_imap_end}}] + cidr: {get_param: nems_imap_cidr} + network_id: {get_resource: nems_imap_net} + + eca_traffic_net: + type: OS::Contrail::VirtualNetwork + properties: + name: {get_param: eca_traffic_name} + + eca_traffic_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: eca_traffic_name} + allocation_pools: [{"start": {get_param: eca_traffic_start}, "end": {get_param: eca_traffic_end}}] + cidr: {get_param: eca_traffic_cidr} + network_id: {get_resource: eca_traffic_net} + + ha_net: + type: OS::Contrail::VirtualNetwork + properties: + name: {get_param: ha_net_name} + + ha_net_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: ha_net_name} + allocation_pools: [{"start": {get_param: ha_net_start}, "end": {get_param: ha_net_end}}] + cidr: {get_param: ha_net_cidr} + network_id: {get_resource: ha_net} + + lb1_instance: + type: OS::Nova::Server + properties: + name: {get_param: [lb_names, 0]} + image: {get_param: lb_image_name} + flavor: {get_param: lb_flavor_name} + availability_zone: {get_param: availability_zone_0} + networks: + - port: {get_resource: lb1_mgmt_port} + - port: {get_resource: lb1_dmz_protected_port} + - port: {get_resource: lb1_cor_direct_port} + - port: {get_resource: lb1_mms_traffic_port} + - port: {get_resource: lb1_nems_traffic_port} + - port: {get_resource: lb1_nems_user_web_port} + - port: {get_resource: lb1_eca_traffic_port} + - port: {get_resource: lb1_ha_net_port} + metadata: + vnf_id: { get_param: vnf_id } + + lb1_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [lb_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb1_mms_traffic_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: mms_traffic_net} + fixed_ips: [{"ip_address": {get_param: mms_traffic_net_local_ip1}}] + allowed_address_pairs: [{"ip_address": {get_param: mms_traffic_net_floating_ip} }] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb1_dmz_protected_port: + type: OS::Neutron::Port + properties: + network: {get_param: dmz_protected_net_name} + fixed_ips: [{"ip_address": {get_param: [lb_dmz_protected_ips, 0]}}] + allowed_address_pairs: [{"ip_address": {get_param: [mmsc_dmz_protected_virtual_server_ips, 0]}}, {"ip_address": {get_param: [mmsc_dmz_protected_virtual_server_ips, 1]}}, {"ip_address": {get_param: [mmsc_dmz_protected_virtual_server_ips, 2]}}, {"ip_address": {get_param: [mmsc_dmz_protected_snat_ips, 0]}}, {"ip_address": {get_param: [mmsc_dmz_protected_snat_ips, 1]}}, {"ip_address": {get_param: [mmsc_dmz_protected_snat_ips, 2]}}, {"ip_address": {get_param: [mmsc_dmz_protected_snat_ips, 3]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb1_cor_direct_port: + type: OS::Neutron::Port + properties: + network: {get_param: cor_direct_net_name} + fixed_ips: [{"ip_address": {get_param: [lb_cor_direct_ips, 0]}}] + allowed_address_pairs: [{"ip_address": {get_param: [mmsc_core_virtual_server_ips, 0]}}, {"ip_address": {get_param: [mmsc_core_virtual_server_ips, 1]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 0]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 1]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 2]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 3]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 4]}} ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb1_nems_traffic_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: nems_traffic_net} + fixed_ips: [{"ip_address": {get_param: nems_traffic_net_local_ip1}}] + allowed_address_pairs: [{"ip_address": {get_param: nems_traffic_net_floating_ip} }] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb1_nems_user_web_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: nems_user_web_net} + fixed_ips: [{"ip_address": {get_param: nems_user_web_net_local_ip1}}] + allowed_address_pairs: [{"ip_address": {get_param: nems_user_web_net_floating_ip} }] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb1_ha_net_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: ha_net} + fixed_ips: [{"ip_address": {get_param: ha_net_local_ip1}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb1_eca_traffic_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: eca_traffic_net} + fixed_ips: [{"ip_address": {get_param: eca_traffic_net_local_ip1}}] + allowed_address_pairs: [{"ip_address": {get_param: eca_traffic_net_floating_ip} }] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb2_instance: + type: OS::Nova::Server + properties: + name: {get_param: [lb_names, 1]} + image: {get_param: lb_image_name} + flavor: {get_param: lb_flavor_name} + availability_zone: {get_param: availability_zone_0} + networks: + - port: {get_resource: lb2_mgmt_port} + - port: {get_resource: lb2_dmz_protected_port} + - port: {get_resource: lb2_cor_direct_port} + - port: {get_resource: lb2_mms_traffic_port} + - port: {get_resource: lb2_nems_traffic_port} + - port: {get_resource: lb2_nems_user_web_port} + - port: {get_resource: lb2_eca_traffic_port} + - port: {get_resource: lb2_ha_net_port} + metadata: + vnf_id: { get_param: vnf_id } + + lb2_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [lb_oam_ips, 1]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb2_mms_traffic_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: mms_traffic_net} + fixed_ips: [{"ip_address": {get_param: mms_traffic_net_local_ip2}}] + allowed_address_pairs: [{"ip_address": {get_param: mms_traffic_net_floating_ip}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb2_dmz_protected_port: + type: OS::Neutron::Port + properties: + network: {get_param: dmz_protected_net_name} + fixed_ips: [{"ip_address": {get_param: [lb_dmz_protected_ips, 1]}}] + allowed_address_pairs: [{"ip_address": {get_param: [mmsc_dmz_protected_virtual_server_ips, 0]}}, {"ip_address": {get_param: [mmsc_dmz_protected_virtual_server_ips, 1]}}, {"ip_address": {get_param: [mmsc_dmz_protected_virtual_server_ips, 2]}}, {"ip_address": {get_param: [mmsc_dmz_protected_snat_ips, 0]}}, {"ip_address": {get_param: [mmsc_dmz_protected_snat_ips, 1]}}, {"ip_address": {get_param: [mmsc_dmz_protected_snat_ips, 2]}}, {"ip_address": {get_param: [mmsc_dmz_protected_snat_ips, 3]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb2_cor_direct_port: + type: OS::Neutron::Port + properties: + network: {get_param: cor_direct_net_name} + fixed_ips: [{"ip_address": {get_param: [lb_cor_direct_ips, 1]}}] + allowed_address_pairs: [{"ip_address": {get_param: [mmsc_core_virtual_server_ips, 0]}}, {"ip_address": {get_param: [mmsc_core_virtual_server_ips, 1]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 0]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 1]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 2]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 3]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 4]}} ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb2_nems_traffic_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: nems_traffic_net} + fixed_ips: [{"ip_address": {get_param: nems_traffic_net_local_ip2}}] + allowed_address_pairs: [{"ip_address": {get_param: nems_traffic_net_floating_ip}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb2_nems_user_web_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: nems_user_web_net} + fixed_ips: [{"ip_address": {get_param: nems_user_web_net_local_ip2}}] + allowed_address_pairs: [{"ip_address": {get_param: nems_user_web_net_floating_ip}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb2_ha_net_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: ha_net} + fixed_ips: [{"ip_address": {get_param: ha_net_local_ip2}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb2_eca_traffic_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: eca_traffic_net} + fixed_ips: [{"ip_address": {get_param: eca_traffic_net_local_ip2}}] + allowed_address_pairs: [{"ip_address": {get_param: eca_traffic_net_floating_ip} }] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_mmsc1: + type: OS::Nova::Server + properties: + name: { get_param: [mmsc_names, 0]} + image: { get_param: mmsc_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: mmsc_flavor } + networks: + - port: { get_resource: mmsc1_port_0 } + - port: { get_resource: mmsc1_port_1 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + mmsc.mgmt.ip=${mmsc.mgmt.ip} + mmsc.mgmt.netmask=${mmsc.mgmt.netmask} + mmsc.mgmt.gateway=${mmsc.mgmt.gateway} + mmsc.traffic.ip=${mmsc.traffic.ip} + mmsc.traffic.netmask=${mmsc.traffic.netmask} + mmsc.traffic.gateway=${mmsc.traffic.gateway} + mmsc.mgmt.route.1=${mmsc.mgmt.route.1} + mmsc.mgmt.route.2=${mmsc.mgmt.route.2} + mmsc.external.dns=${mmsc.external.dns} + mmsc.external.ntp=${mmsc.external.ntp} + mmsc.hostname=${mmsc.hostname} + mmsc.timezone=${mmsc.timezone} + params: + ${mmsc.mgmt.ip}: {get_param: [mmsc_oam_ips, 0]} + ${mmsc.mgmt.netmask}: {get_param: oam_network_netmask} + ${mmsc.mgmt.gateway}: {get_param: oam_network_gateway} + ${mmsc.traffic.ip}: {get_param: [mmsc_mms_traffic_net_ips, 0]} + ${mmsc.traffic.netmask}: {get_param: mms_traffic_netmask} + ${mmsc.traffic.gateway}: {get_param: mms_traffic_net_gateway} + ${mmsc.mgmt.route.1}: {get_param: oam_network_route_1} + ${mmsc.mgmt.route.2}: {get_param: oam_network_route_2} + ${mmsc.external.dns}: {get_param: external_dns} + ${mmsc.external.ntp}: {get_param: external_ntp} + ${mmsc.hostname}: {get_param: [mmsc_names, 0]} + ${mmsc.timezone}: {get_param: timezone} + user_data_format: RAW + + mmsc1_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: mmsc_cinder_volume_size} + volume_type: {get_param: MMSC_volume_type} + + mmsc1_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: mmsc1_volume} + instance_uuid: {get_resource: server_mmsc1} + + mmsc1_port_0: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [ + "ip_address": {get_param: [mmsc_oam_ips, 0]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + mmsc1_port_1: + type: OS::Neutron::Port + properties: + network_id: {get_resource: mms_traffic_net} + fixed_ips: [ + "ip_address": {get_param: [mmsc_mms_traffic_net_ips, 0]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_mmsc2: + type: OS::Nova::Server + properties: + name: { get_param: [mmsc_names, 1]} + image: { get_param: mmsc_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: mmsc_flavor } + networks: + - port: { get_resource: mmsc2_port_0 } + - port: { get_resource: mmsc2_port_1 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + mmsc.mgmt.ip=${mmsc.mgmt.ip} + mmsc.mgmt.netmask=${mmsc.mgmt.netmask} + mmsc.mgmt.gateway=${mmsc.mgmt.gateway} + mmsc.traffic.ip=${mmsc.traffic.ip} + mmsc.traffic.netmask=${mmsc.traffic.netmask} + mmsc.traffic.gateway=${mmsc.traffic.gateway} + mmsc.mgmt.route.1=${mmsc.mgmt.route.1} + mmsc.mgmt.route.2=${mmsc.mgmt.route.2} + mmsc.external.dns=${mmsc.external.dns} + mmsc.external.ntp=${mmsc.external.ntp} + mmsc.hostname=${mmsc.hostname} + mmsc.timezone=${mmsc.timezone} + params: + ${mmsc.mgmt.ip}: {get_param: [mmsc_oam_ips, 1]} + ${mmsc.mgmt.netmask}: {get_param: oam_network_netmask} + ${mmsc.mgmt.gateway}: {get_param: oam_network_gateway} + ${mmsc.traffic.ip}: {get_param: [mmsc_mms_traffic_net_ips, 1]} + ${mmsc.traffic.netmask}: {get_param: mms_traffic_netmask} + ${mmsc.traffic.gateway}: {get_param: mms_traffic_net_gateway} + ${mmsc.mgmt.route.1}: {get_param: oam_network_route_1} + ${mmsc.mgmt.route.2}: {get_param: oam_network_route_2} + ${mmsc.external.dns}: {get_param: external_dns} + ${mmsc.external.ntp}: {get_param: external_ntp} + ${mmsc.hostname}: {get_param: [mmsc_names, 1]} + ${mmsc.timezone}: {get_param: timezone} + user_data_format: RAW + + mmsc2_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: mmsc_cinder_volume_size} + volume_type: {get_param: MMSC_volume_type} + + mmsc2_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: mmsc2_volume} + instance_uuid: {get_resource: server_mmsc2} + + mmsc2_port_0: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [ + "ip_address": {get_param: [mmsc_oam_ips, 1]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + mmsc2_port_1: + type: OS::Neutron::Port + properties: + network_id: {get_resource: mms_traffic_net} + fixed_ips: [ + "ip_address": {get_param: [mmsc_mms_traffic_net_ips, 1]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_mmsc3: + type: OS::Nova::Server + properties: + name: { get_param: [mmsc_names, 2]} + image: { get_param: mmsc_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: mmsc_flavor } + networks: + - port: { get_resource: mmsc3_port_0 } + - port: { get_resource: mmsc3_port_1 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + mmsc.mgmt.ip=${mmsc.mgmt.ip} + mmsc.mgmt.netmask=${mmsc.mgmt.netmask} + mmsc.mgmt.gateway=${mmsc.mgmt.gateway} + mmsc.traffic.ip=${mmsc.traffic.ip} + mmsc.traffic.netmask=${mmsc.traffic.netmask} + mmsc.traffic.gateway=${mmsc.traffic.gateway} + mmsc.mgmt.route.1=${mmsc.mgmt.route.1} + mmsc.mgmt.route.2=${mmsc.mgmt.route.2} + mmsc.external.dns=${mmsc.external.dns} + mmsc.external.ntp=${mmsc.external.ntp} + mmsc.hostname=${mmsc.hostname} + mmsc.timezone=${mmsc.timezone} + params: + ${mmsc.mgmt.ip}: {get_param: [mmsc_oam_ips, 2]} + ${mmsc.mgmt.netmask}: {get_param: oam_network_netmask} + ${mmsc.mgmt.gateway}: {get_param: oam_network_gateway} + ${mmsc.traffic.ip}: {get_param: [mmsc_mms_traffic_net_ips, 2]} + ${mmsc.traffic.netmask}: {get_param: mms_traffic_netmask} + ${mmsc.traffic.gateway}: {get_param: mms_traffic_net_gateway} + ${mmsc.mgmt.route.1}: {get_param: oam_network_route_1} + ${mmsc.mgmt.route.2}: {get_param: oam_network_route_2} + ${mmsc.external.dns}: {get_param: external_dns} + ${mmsc.external.ntp}: {get_param: external_ntp} + ${mmsc.hostname}: {get_param: [mmsc_names, 2]} + ${mmsc.timezone}: {get_param: timezone} + user_data_format: RAW + + mmsc3_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: mmsc_cinder_volume_size} + volume_type: {get_param: MMSC_volume_type} + + mmsc3_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: mmsc3_volume} + instance_uuid: {get_resource: server_mmsc3} + + mmsc3_port_0: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [ + "ip_address": {get_param: [mmsc_oam_ips, 2]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + mmsc3_port_1: + type: OS::Neutron::Port + properties: + network_id: {get_resource: mms_traffic_net} + fixed_ips: [ + "ip_address": {get_param: [mmsc_mms_traffic_net_ips, 2]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_mmsc4: + type: OS::Nova::Server + properties: + name: { get_param: [mmsc_names, 3]} + image: { get_param: mmsc_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: mmsc_flavor } + networks: + - port: { get_resource: mmsc4_port_0 } + - port: { get_resource: mmsc4_port_1 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + mmsc.mgmt.ip=${mmsc.mgmt.ip} + mmsc.mgmt.netmask=${mmsc.mgmt.netmask} + mmsc.mgmt.gateway=${mmsc.mgmt.gateway} + mmsc.traffic.ip=${mmsc.traffic.ip} + mmsc.traffic.netmask=${mmsc.traffic.netmask} + mmsc.traffic.gateway=${mmsc.traffic.gateway} + mmsc.mgmt.route.1=${mmsc.mgmt.route.1} + mmsc.mgmt.route.2=${mmsc.mgmt.route.2} + mmsc.external.dns=${mmsc.external.dns} + mmsc.external.ntp=${mmsc.external.ntp} + mmsc.hostname=${mmsc.hostname} + mmsc.timezone=${mmsc.timezone} + params: + ${mmsc.mgmt.ip}: {get_param: [mmsc_oam_ips, 3]} + ${mmsc.mgmt.netmask}: {get_param: oam_network_netmask} + ${mmsc.mgmt.gateway}: {get_param: oam_network_gateway} + ${mmsc.traffic.ip}: {get_param: [mmsc_mms_traffic_net_ips, 3]} + ${mmsc.traffic.netmask}: {get_param: mms_traffic_netmask} + ${mmsc.traffic.gateway}: {get_param: mms_traffic_net_gateway} + ${mmsc.mgmt.route.1}: {get_param: oam_network_route_1} + ${mmsc.mgmt.route.2}: {get_param: oam_network_route_2} + ${mmsc.external.dns}: {get_param: external_dns} + ${mmsc.external.ntp}: {get_param: external_ntp} + ${mmsc.hostname}: {get_param: [mmsc_names, 3]} + ${mmsc.timezone}: {get_param: timezone} + user_data_format: RAW + + mmsc4_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: mmsc_cinder_volume_size} + volume_type: {get_param: MMSC_volume_type} + + mmsc4_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: mmsc4_volume} + instance_uuid: {get_resource: server_mmsc4} + + mmsc4_port_0: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [ + "ip_address": {get_param: [mmsc_oam_ips, 3]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + mmsc4_port_1: + type: OS::Neutron::Port + properties: + network_id: {get_resource: mms_traffic_net} + fixed_ips: [ + "ip_address": {get_param: [mmsc_mms_traffic_net_ips, 3]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_mmsc5: + type: OS::Nova::Server + properties: + name: { get_param: [mmsc_names, 4]} + image: { get_param: mmsc_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: mmsc_flavor } + networks: + - port: { get_resource: mmsc5_port_0 } + - port: { get_resource: mmsc5_port_1 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + mmsc.mgmt.ip=${mmsc.mgmt.ip} + mmsc.mgmt.netmask=${mmsc.mgmt.netmask} + mmsc.mgmt.gateway=${mmsc.mgmt.gateway} + mmsc.traffic.ip=${mmsc.traffic.ip} + mmsc.traffic.netmask=${mmsc.traffic.netmask} + mmsc.traffic.gateway=${mmsc.traffic.gateway} + mmsc.mgmt.route.1=${mmsc.mgmt.route.1} + mmsc.mgmt.route.2=${mmsc.mgmt.route.2} + mmsc.external.dns=${mmsc.external.dns} + mmsc.external.ntp=${mmsc.external.ntp} + mmsc.hostname=${mmsc.hostname} + mmsc.timezone=${mmsc.timezone} + params: + ${mmsc.mgmt.ip}: {get_param: [mmsc_oam_ips, 4]} + ${mmsc.mgmt.netmask}: {get_param: oam_network_netmask} + ${mmsc.mgmt.gateway}: {get_param: oam_network_gateway} + ${mmsc.traffic.ip}: {get_param: [mmsc_mms_traffic_net_ips, 4]} + ${mmsc.traffic.netmask}: {get_param: mms_traffic_netmask} + ${mmsc.traffic.gateway}: {get_param: mms_traffic_net_gateway} + ${mmsc.mgmt.route.1}: {get_param: oam_network_route_1} + ${mmsc.mgmt.route.2}: {get_param: oam_network_route_2} + ${mmsc.external.dns}: {get_param: external_dns} + ${mmsc.external.ntp}: {get_param: external_ntp} + ${mmsc.hostname}: {get_param: [mmsc_names, 4]} + ${mmsc.timezone}: {get_param: timezone} + user_data_format: RAW + + mmsc5_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: mmsc_cinder_volume_size} + volume_type: {get_param: MMSC_volume_type} + + mmsc5_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: mmsc5_volume} + instance_uuid: {get_resource: server_mmsc5} + + mmsc5_port_0: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [ + "ip_address": {get_param: [mmsc_oam_ips, 4]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + mmsc5_port_1: + type: OS::Neutron::Port + properties: + network_id: {get_resource: mms_traffic_net} + fixed_ips: [ + "ip_address": {get_param: [mmsc_mms_traffic_net_ips, 4]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_nems_fe1: + type: OS::Nova::Server + properties: + name: { get_param: [nems_fe_names, 0] } + image: { get_param: nems_fe_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: nems_fe_flavor } + networks: + - port: { get_resource: nems_fe1_port_0 } + - port: { get_resource: nems_fe1_port_1 } + - port: { get_resource: nems_fe1_port_2 } + - port: { get_resource: nems_fe1_port_3 } + - port: { get_resource: nems_fe1_port_4 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + nems.mgmt.ip=${nems.mgmt.ip} + nems.mgmt.netmask=${nems.mgmt.netmask} + nems.mgmt.gateway=${nems.mgmt.gateway} + nems.traffic.ip=${nems.traffic.ip} + nems.traffic.netmask=${nems.traffic.netmask} + nems.traffic.gateway=${nems.traffic.gateway} + nems.fe0.internal.ip=${nems.fe0.internal.ip} + nems.fe1.internal.ip=${nems.fe1.internal.ip} + nems.internal.netmask=${nems.internal.netmask} + nems.userweb.ip=${nems.userweb.ip} + nems.userweb.netmask=${nems.userweb.netmask} + nems.userweb.gateway=${nems.userweb.gateway} + nems.imap.ip=${nems.imap.ip} + nems.imap.netmask=${nems.imap.netmask} + nems.be.internal.ip=${nems.be.internal.ip} + nems.be.imap.ip=${nems.be.imap.ip} + nems.mgmt.route.1=${nems.mgmt.route.1} + nems.mgmt.route.2=${nems.mgmt.route.2} + nems.external.dns=${nems.external.dns} + nems.external.ntp=${nems.external.ntp} + nems.node=${nems.node} + nems.be0.host.name=${nems.be0.host.name} + nems.fe0.host.name=${nems.fe0.host.name} + nems.fe1.host.name=${nems.fe1.host.name} + nems.timezone=${nems.timezone} + params: + ${nems.mgmt.ip}: {get_param: [nems_fe_oam_ips, 0]} + ${nems.mgmt.netmask}: {get_param: oam_network_netmask} + ${nems.mgmt.gateway}: {get_param: oam_network_gateway} + ${nems.traffic.ip}: {get_param: [nems_fe_nems_traffic_net_ips, 0]} + ${nems.traffic.netmask}: {get_param: nems_traffic_netmask} + ${nems.traffic.gateway}: {get_param: nems_traffic_gateway} + ${nems.fe0.internal.ip}: {get_param: [nems_fe_nems_internal_net_ips, 0]} + ${nems.fe1.internal.ip}: {get_param: [nems_fe_nems_internal_net_ips, 1]} + ${nems.internal.netmask}: {get_param: nems_internal_netmask} + ${nems.userweb.ip}: {get_param: [nems_fe_nems_user_web_net_ips, 0]} + ${nems.userweb.netmask}: {get_param: nems_user_web_netmask} + ${nems.userweb.gateway}: {get_param: nems_user_web_gateway} + ${nems.imap.ip}: {get_param: [nems_fe_nems_imap_net_ips, 0]} + ${nems.imap.netmask}: {get_param: nems_imap_netmask} + ${nems.be.internal.ip}: {get_param: nems_be_nems_internal_net_ips} + ${nems.be.imap.ip}: {get_param: nems_be_nems_imap_net_ips} + ${nems.mgmt.route.1}: {get_param: oam_network_route_1} + ${nems.mgmt.route.2}: {get_param: oam_network_route_2} + ${nems.external.dns}: {get_param: external_dns} + ${nems.external.ntp}: {get_param: external_ntp} + ${nems.node}: {get_param: [nems_fe_node_roles, 0]} + ${nems.fe0.host.name}: {get_param: [nems_fe_names, 0]} + ${nems.fe1.host.name}: {get_param: [nems_fe_names, 1]} + ${nems.be0.host.name}: {get_param: nems_be_names} + ${nems.timezone}: {get_param: timezone} + user_data_format: RAW + + nems1_fe_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: nems_volume_size} + volume_type: {get_param: NEMS_FE_volume_type} + + nems1_fe_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: nems1_fe_volume} + instance_uuid: {get_resource: server_nems_fe1} + + nems_fe1_port_0: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [ + "ip_address": { get_param: [nems_fe_oam_ips, 0] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_fe1_port_1: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [nems_fe_nems_traffic_net_ips, 0] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_fe1_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_user_web_net } + fixed_ips: [ + "ip_address": { get_param: [nems_fe_nems_user_web_net_ips, 0] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_fe1_port_3: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_internal_net } + fixed_ips: [ + "ip_address": { get_param: [nems_fe_nems_internal_net_ips, 0] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_fe1_port_4: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_imap_net } + fixed_ips: [ + "ip_address": { get_param: [nems_fe_nems_imap_net_ips, 0] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_nems_fe2: + type: OS::Nova::Server + properties: + name: { get_param: [nems_fe_names, 1] } + image: { get_param: nems_fe_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: nems_fe_flavor } + networks: + - port: { get_resource: nems_fe2_port_0 } + - port: { get_resource: nems_fe2_port_1 } + - port: { get_resource: nems_fe2_port_2 } + - port: { get_resource: nems_fe2_port_3 } + - port: { get_resource: nems_fe2_port_4 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + nems.mgmt.ip=${nems.mgmt.ip} + nems.mgmt.netmask=${nems.mgmt.netmask} + nems.mgmt.gateway=${nems.mgmt.gateway} + nems.traffic.ip=${nems.traffic.ip} + nems.traffic.netmask=${nems.traffic.netmask} + nems.traffic.gateway=${nems.traffic.gateway} + nems.fe0.internal.ip=${nems.fe0.internal.ip} + nems.fe1.internal.ip=${nems.fe1.internal.ip} + nems.internal.netmask=${nems.internal.netmask} + nems.userweb.ip=${nems.userweb.ip} + nems.userweb.netmask=${nems.userweb.netmask} + nems.userweb.gateway=${nems.userweb.gateway} + nems.imap.ip=${nems.imap.ip} + nems.imap.netmask=${nems.imap.netmask} + nems.be.internal.ip=${nems.be.internal.ip} + nems.be.imap.ip=${nems.be.imap.ip} + nems.mgmt.route.1=${nems.mgmt.route.1} + nems.mgmt.route.2=${nems.mgmt.route.2} + nems.external.dns=${nems.external.dns} + nems.external.ntp=${nems.external.ntp} + nems.node=${nems.node} + nems.be0.host.name=${nems.be0.host.name} + nems.fe0.host.name=${nems.fe0.host.name} + nems.fe1.host.name=${nems.fe1.host.name} + nems.timezone=${nems.timezone} + params: + ${nems.mgmt.ip}: {get_param: [nems_fe_oam_ips, 1]} + ${nems.mgmt.netmask}: {get_param: oam_network_netmask} + ${nems.mgmt.gateway}: {get_param: oam_network_gateway} + ${nems.traffic.ip}: {get_param: [nems_fe_nems_traffic_net_ips, 1]} + ${nems.traffic.netmask}: {get_param: nems_traffic_netmask} + ${nems.traffic.gateway}: {get_param: nems_traffic_gateway} + ${nems.fe0.internal.ip}: {get_param: [nems_fe_nems_internal_net_ips, 0]} + ${nems.fe1.internal.ip}: {get_param: [nems_fe_nems_internal_net_ips, 1]} + ${nems.internal.netmask}: {get_param: nems_internal_netmask} + ${nems.userweb.ip}: {get_param: [nems_fe_nems_user_web_net_ips, 1]} + ${nems.userweb.netmask}: {get_param: nems_user_web_netmask} + ${nems.userweb.gateway}: {get_param: nems_user_web_gateway} + ${nems.imap.ip}: {get_param: [nems_fe_nems_imap_net_ips, 1]} + ${nems.imap.netmask}: {get_param: nems_imap_netmask} + ${nems.be.internal.ip}: {get_param: nems_be_nems_internal_net_ips} + ${nems.be.imap.ip}: {get_param: nems_be_nems_imap_net_ips} + ${nems.mgmt.route.1}: {get_param: oam_network_route_1} + ${nems.mgmt.route.2}: {get_param: oam_network_route_2} + ${nems.external.dns}: {get_param: external_dns} + ${nems.external.ntp}: {get_param: external_ntp} + ${nems.node}: {get_param: [nems_fe_node_roles, 1]} + ${nems.fe0.host.name}: {get_param: [nems_fe_names, 0]} + ${nems.fe1.host.name}: {get_param: [nems_fe_names, 1]} + ${nems.be0.host.name}: {get_param: nems_be_names} + ${nems.timezone}: {get_param: timezone} + user_data_format: RAW + + nems2_fe_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: nems_volume_size} + volume_type: {get_param: NEMS_FE_volume_type} + + nems2_fe_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: nems2_fe_volume} + instance_uuid: {get_resource: server_nems_fe2} + + nems_fe2_port_0: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [ + "ip_address": {get_param: [nems_fe_oam_ips, 1]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_fe2_port_1: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [nems_fe_nems_traffic_net_ips, 1] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_fe2_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_user_web_net } + fixed_ips: [ + "ip_address": { get_param: [nems_fe_nems_user_web_net_ips, 1] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_fe2_port_3: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_internal_net } + fixed_ips: [ + "ip_address": { get_param: [nems_fe_nems_internal_net_ips, 1] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + + nems_fe2_port_4: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_imap_net } + fixed_ips: [ + "ip_address": { get_param: [nems_fe_nems_imap_net_ips, 1] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_nems_be1: + type: OS::Nova::Server + properties: + name: { get_param: nems_be_names } + image: { get_param: nems_be_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: nems_be_flavor } + networks: + - port: { get_resource: nems_be1_port_0 } + - port: { get_resource: nems_be1_port_1 } + - port: { get_resource: nems_be1_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + nems.be.mgmt.ip=${nems.be.mgmt.ip} + nems.mgmt.netmask=${nems.mgmt.netmask} + nems.mgmt.gateway=${nems.mgmt.gateway} + nems.be.internal.ip=${nems.be.internal.ip} + nems.internal.netmask=${nems.internal.netmask} + nems.imap.netmask=${nems.imap.netmask} + nems.fe0.internal.ip=${nems.fe0.internal.ip} + nems.fe1.internal.ip=${nems.fe1.internal.ip} + nems.be.imap.ip=${nems.be.imap.ip} + nems.mgmt.route.1=${nems.mgmt.route.1} + nems.mgmt.route.2=${nems.mgmt.route.2} + nems.external.dns=${nems.external.dns} + nems.external.ntp=${nems.external.ntp} + nems.node=${nems.node} + nems.be0.host.name=${nems.be0.host.name} + nems.fe0.host.name=${nems.fe0.host.name} + nems.fe1.host.name=${nems.fe1.host.name} + nems.timezone=${nems.timezone} + params: + ${nems.be.mgmt.ip}: {get_param: nems_be_oam_ips} + ${nems.mgmt.netmask}: {get_param: oam_network_netmask} + ${nems.mgmt.gateway}: {get_param: oam_network_gateway} + ${nems.fe0.internal.ip}: {get_param: [nems_fe_nems_internal_net_ips, 0]} + ${nems.fe1.internal.ip}: {get_param: [nems_fe_nems_internal_net_ips, 1]} + ${nems.be.internal.ip}: {get_param: nems_be_nems_internal_net_ips} + ${nems.internal.netmask}: {get_param: nems_internal_netmask} + ${nems.imap.netmask}: {get_param: nems_imap_netmask} + ${nems.be.imap.ip}: {get_param: nems_be_nems_imap_net_ips} + ${nems.mgmt.route.1}: {get_param: oam_network_route_1} + ${nems.mgmt.route.2}: {get_param: oam_network_route_2} + ${nems.external.dns}: {get_param: external_dns} + ${nems.external.ntp}: {get_param: external_ntp} + ${nems.node}: {get_param: nems_be_node_roles} + ${nems.be0.host.name}: {get_param: nems_be_names} + ${nems.fe0.host.name}: {get_param: [nems_fe_names, 0]} + ${nems.fe1.host.name}: {get_param: [nems_fe_names, 1]} + ${nems.timezone}: {get_param: timezone} + user_data_format: RAW + + nems_be_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: nems_be_volume_size} + volume_type: {get_param: NEMS_BE_volume_type} + + nems_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: nems_be_volume} + instance_uuid: {get_resource: server_nems_be1} + + + nems_be1_port_0: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [ + "ip_address": { get_param: nems_be_oam_ips} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_be1_port_1: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_internal_net } + fixed_ips: [ + "ip_address": { get_param: nems_be_nems_internal_net_ips} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_be1_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_imap_net } + fixed_ips: [ + "ip_address": { get_param: nems_be_nems_imap_net_ips} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx1: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 0]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx1_port_0 } + - port: { get_resource: eca_trx1_port_1 } + - port: { get_resource: eca_trx1_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 0]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 0]} + + eca_trx1_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 0] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx1_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 0] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx1_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 0] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + + server_eca_trx2: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 1]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx2_port_0 } + - port: { get_resource: eca_trx2_port_1 } + - port: { get_resource: eca_trx2_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 1]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 1]} + + eca_trx2_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 1] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx2_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 1] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx2_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 1] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx3: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 2]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx3_port_0 } + - port: { get_resource: eca_trx3_port_1 } + - port: { get_resource: eca_trx3_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 2]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 2]} + + eca_trx3_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 2] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx3_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 2] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx3_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 2] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx4: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 3]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx4_port_0 } + - port: { get_resource: eca_trx4_port_1 } + - port: { get_resource: eca_trx4_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 3]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 3]} + + eca_trx4_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 3] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx4_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 3] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx4_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 3] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx5: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 4]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx5_port_0 } + - port: { get_resource: eca_trx5_port_1 } + - port: { get_resource: eca_trx5_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 4]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 4]} + + eca_trx5_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 4] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx5_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 4] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx5_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 4] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx6: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 5]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx6_port_0 } + - port: { get_resource: eca_trx6_port_1 } + - port: { get_resource: eca_trx6_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 5]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 5]} + + eca_trx6_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 5] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx6_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 5] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx6_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 5] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx7: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 6]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx7_port_0 } + - port: { get_resource: eca_trx7_port_1 } + - port: { get_resource: eca_trx7_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 6]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 6]} + + eca_trx7_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 6] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx7_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 6] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx7_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 6] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx8: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 7]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx8_port_0 } + - port: { get_resource: eca_trx8_port_1 } + - port: { get_resource: eca_trx8_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 7]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 7]} + + eca_trx8_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 7] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx8_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 7] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx8_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 7] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx9: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 8]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx9_port_0 } + - port: { get_resource: eca_trx9_port_1 } + - port: { get_resource: eca_trx9_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 8]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 8]} + + eca_trx9_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 8] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx9_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 8] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx9_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 8] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx10: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 9]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx10_port_0 } + - port: { get_resource: eca_trx10_port_1 } + - port: { get_resource: eca_trx10_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 9]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 9]} + + eca_trx10_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 9] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx10_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 9] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx10_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 9] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx11: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 10]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx11_port_0 } + - port: { get_resource: eca_trx11_port_1 } + - port: { get_resource: eca_trx11_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 10]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 10]} + + eca_trx11_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 10] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx11_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 10] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx11_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 10] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + + server_eca_trx12: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 11]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx12_port_0 } + - port: { get_resource: eca_trx12_port_1 } + - port: { get_resource: eca_trx12_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 11]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 11]} + + eca_trx12_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 11] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx12_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 11] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx12_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 11] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx13: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 12]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx13_port_0 } + - port: { get_resource: eca_trx13_port_1 } + - port: { get_resource: eca_trx13_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 12]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 12]} + + eca_trx13_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 12] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx13_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 12] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx13_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 12] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx14: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 13]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx14_port_0 } + - port: { get_resource: eca_trx14_port_1 } + - port: { get_resource: eca_trx14_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 13]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 13]} + + eca_trx14_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 13] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx14_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 13] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx14_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 13] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx15: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 14]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx15_port_0 } + - port: { get_resource: eca_trx15_port_1 } + - port: { get_resource: eca_trx15_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 14]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 14]} + + eca_trx15_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 14] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx15_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 14] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx15_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 14] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx16: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 15]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx16_port_0 } + - port: { get_resource: eca_trx16_port_1 } + - port: { get_resource: eca_trx16_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 15]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 15]} + + eca_trx16_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 15] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx16_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 15] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx16_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 15] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + + server_eca_trx17: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 16]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx17_port_0 } + - port: { get_resource: eca_trx17_port_1 } + - port: { get_resource: eca_trx17_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 16]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 16]} + + eca_trx17_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 16] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx17_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 16] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx17_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 16] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx18: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 17]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx18_port_0 } + - port: { get_resource: eca_trx18_port_1 } + - port: { get_resource: eca_trx18_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 17]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 17]} + + eca_trx18_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 17] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx18_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 17] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx18_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 17] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx19: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 18]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx19_port_0 } + - port: { get_resource: eca_trx19_port_1 } + - port: { get_resource: eca_trx19_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 8]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 18]} + + eca_trx19_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 18] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx19_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 18] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx19_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 18] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx20: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 19]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx20_port_0 } + - port: { get_resource: eca_trx20_port_1 } + - port: { get_resource: eca_trx20_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 19]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 19]} + + eca_trx20_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 19] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx20_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 19] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx20_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 19] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/MMSC_Capacity_Line_1.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/MMSC_Capacity_Line_1.env new file mode 100644 index 0000000000..b346d67d97 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/MMSC_Capacity_Line_1.env @@ -0,0 +1,111 @@ +parameters: + oam_net_name: oam_protected_net_0 + oam_network_netmask: 255.255.254.0 + oam_network_gateway: 107.250.172.1 + oam_network_route_1: 155.165.201.250/32,107.250.172.1 + oam_network_route_2: 155.165.194.100/32,107.250.172.1 + external_dns: 155.165.194.100 + external_ntp: 155.165.201.250 + lb_oam_ips: 107.250.172.50,107.250.172.51 + dmz_protected_net_name: dmz_protected_net_0 + lb_dmz_protected_ips: 107.239.14.19,107.239.14.20 + cor_direct_net_name: cor_direct_net_0 + lb_cor_direct_ips: 172.31.10.19,172.31.10.20 + mms_traffic_net_name: int_mms_mms_traffic_net_2 + mms_traffic_net_cidr: 172.26.2.0/24 + mms_traffic_netmask: 255.255.255.0 + mms_traffic_net_gateway: 172.26.2.1 + mms_traffic_start: 172.26.2.3 + mms_traffic_end: 172.26.2.254 + mms_traffic_net_local_ip1: 172.26.2.3 + mms_traffic_net_local_ip2: 172.26.2.4 + mms_traffic_net_floating_ip: 172.26.2.5 + nems_internal_name: int_mms_nems_internal_net_2 + nems_internal_start: 172.26.6.3 + nems_internal_end: 172.26.6.254 + nems_internal_cidr: 172.26.6.0/24 + nems_internal_netmask: 255.255.255.0 + nems_internal_gateway: 172.26.6.1 + nems_traffic_name: int_mms_nems_traffic_net_2 + nems_traffic_start: 172.26.3.3 + nems_traffic_end: 172.26.3.254 + nems_traffic_cidr: 172.26.3.0/24 + nems_traffic_netmask: 255.255.255.0 + nems_traffic_gateway: 172.26.3.1 + nems_traffic_net_local_ip1: 172.26.3.3 + nems_traffic_net_local_ip2: 172.26.3.4 + nems_traffic_net_floating_ip: 172.26.3.5 + nems_user_web_name: int_mms_nems_web_net_2 + nems_user_web_start: 172.26.4.3 + nems_user_web_end: 172.26.4.254 + nems_user_web_cidr: 172.26.4.0/24 + nems_user_web_netmask: 255.255.255.0 + nems_user_web_gateway: 172.26.4.1 + nems_user_web_net_local_ip1: 172.26.4.3 + nems_user_web_net_local_ip2: 172.26.4.4 + nems_user_web_net_floating_ip: 172.26.4.5 + nems_imap_name: int_mms_nems_imap_net_2 + nems_imap_start: 172.26.7.3 + nems_imap_end: 172.26.7.254 + nems_imap_cidr: 172.26.7.0/24 + nems_imap_netmask: 255.255.255.0 + nems_imap_gateway: 172.26.7.1 + eca_traffic_name: int_mms_eca_traffic_net_2 + eca_traffic_cidr: 172.26.5.0/24 + eca_traffic_netmask: 255.255.255.0 + eca_traffic_net_gateway: 172.26.5.1 + eca_traffic_start: 172.26.5.3 + eca_traffic_end: 172.26.5.254 + eca_traffic_net_local_ip1: 172.26.5.3 + eca_traffic_net_local_ip2: 172.26.5.4 + eca_traffic_net_floating_ip: 172.26.5.5 + ha_net_name: int_mms_ha_net_2 + ha_net_cidr: 172.26.1.0/24 + ha_net_start: 172.26.1.3 + ha_net_end: 172.26.1.254 + ha_net_local_ip1: 172.26.1.3 + ha_net_local_ip2: 172.26.1.4 + lb_names: ZRDM1MMSC03ALB001,ZRDM1MMSC03ALB002 + lb_image_name: BIGIP-11.5.3.0.0.163 + lb_flavor_name: m1.xlarge + security_group_name: mmsc_security_group_1 + availability_zone_0: nova + mmsc_mms_traffic_net_ips: 172.26.2.11,172.26.2.12,172.26.2.13,172.26.2.14,172.26.2.15 + mmsc_oam_ips: 107.250.172.54,107.250.172.55,107.250.172.56,107.250.172.57,107.250.172.58 + mmsc_flavor: lc.4xlarge4 + mmsc_image: mmsc-6.0.2_v5 + mmsc_cinder_volume_size: 480 + nems_fe_flavor: m1.large2 + nems_fe_image: nems-2.1.2_v29 + nems_fe_names: ZRDM1MMSC03NFE001,ZRDM1MMSC03NFE002 + nems_fe_node_roles: FE0,FE1 + nems_fe_oam_ips: 107.250.172.64,107.250.172.65 + nems_fe_nems_traffic_net_ips: 172.26.3.11,172.26.3.12 + nems_fe_nems_user_web_net_ips: 172.26.4.11,172.26.4.12 + nems_fe_nems_internal_net_ips: 172.26.6.11,172.26.6.12 + nems_fe_nems_imap_net_ips: 172.26.7.11,172.26.7.12 + nems_be_names: ZRDM1MMSC03NBE001 + nems_be_node_roles: BE0 + nems_be_oam_ips: 107.250.172.66 + nems_be_nems_internal_net_ips: 172.26.6.13 + nems_be_nems_imap_net_ips: 172.26.7.13 + nems_be_flavor: m1.large2 + nems_be_image: nems-2.1.2_v29 + eca_trx_oam_ips: 107.250.172.70,107.250.172.71,107.250.172.72,107.250.172.73,107.250.172.74,107.250.172.75,107.250.172.76,107.250.172.77,107.250.172.78,107.250.172.79,107.250.172.80,107.250.172.81,107.250.172.82,107.250.172.83,107.250.172.84,107.250.172.85,107.250.172.86,107.250.172.87,107.250.172.88,107.250.172.89 + eca_trx_mgmt_ips: 172.25.137.202,172.25.137.203,172.25.137.204,172.25.137.205,172.25.137.206,172.25.137.207,172.25.137.208,172.25.137.209,172.25.137.210,172.25.137.211,172.25.137.212,172.25.137.213,172.25.137.214,172.25.137.215,172.25.137.216,172.25.137.217,172.25.137.218,172.25.137.219,172.25.137.220,172.25.137.221 + eca_trx_flavor: m1.xlarge + eca_trx_image: ECABASE + timezone: UTC + eca_trx_names: ZRDM1MMSC03TRX001,ZRDM1MMSC03TRX002,ZRDM1MMSC03TRX003,ZRDM1MMSC03TRX004,ZRDM1MMSC03TRX005,ZRDM1MMSC03TRX006,ZRDM1MMSC03TRX007,ZRDM1MMSC03TRX008,ZRDM1MMSC03TRX009,ZRDM1MMSC03TRX010,ZRDM1MMSC03TRX011,ZRDM1MMSC03TRX012,ZRDM1MMSC03TRX013,ZRDM1MMSC03TRX014,ZRDM1MMSC03TRX015,ZRDM1MMSC03TRX016,ZRDM1MMSC03TRX017,ZRDM1MMSC03TRX018,ZRDM1MMSC03TRX019,ZRDM1MMSC03TRX020 + eca_trx_eca_traffic_net_ips: 172.26.5.11,172.26.5.12,172.26.5.13,172.26.5.14,172.26.5.15,172.26.5.16,172.26.5.17,172.26.5.18,172.26.5.19,172.26.5.20,172.26.5.21,172.26.5.22,172.26.5.23,172.26.5.24,172.26.5.25,172.26.5.26,172.26.5.27,172.26.5.28,172.26.5.29,172.26.5.30 + mmsc_names: ZRDM1MMSC03MMS001,ZRDM1MMSC03MMS002,ZRDM1MMSC03MMS003,ZRDM1MMSC03MMS004,ZRDM1MMSC03MMS005 + nems_volume_size: 50 + nems_be_volume_size: 610 + MMSC_volume_type: Platinum + NEMS_FE_volume_type: Platinum + NEMS_BE_volume_type: Platinum + mmsc_core_virtual_server_ips: 172.31.10.21,172.31.10.22 + mmsc_core_snat_ips: 172.31.10.23,172.31.10.24,172.31.10.25,172.31.10.26,172.31.10.27 + mmsc_dmz_protected_virtual_server_ips: 107.239.14.21,107.239.14.22,107.239.14.23 + mmsc_dmz_protected_snat_ips: 107.239.14.24,107.239.14.25,107.239.14.26,107.239.14.27 + eca_mgmt_net_name: int_eca_mgmt_net_1 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/SG_ECA_MGMT.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/SG_ECA_MGMT.yaml new file mode 100644 index 0000000000..53efc5e36e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/SG_ECA_MGMT.yaml @@ -0,0 +1,76 @@ +heat_template_version: 2013-05-23 + +################################# +# +# Changes from MSO - 11/5/2015 +# - Parameter changes as below +# - CDLs for vmNames, IPs +# - aZone->availability_zone_0 +# - nwName->{nwRole}_net_name +# - nwID->{nwRole}_net_id +# - vmName->{vmType}_names +# - ips ->{vmType}_{nwRole}_ips +# - fips->{vmType}_{nwRole}_floating_ip +# - added replacement_policy: AUTO to all ports +# - added vnf_id for metadata to all servers +# - externalized security group resource +# - externalized eca_mgmt network +# +################################# + +description: > + HOT template that creates Security Group and ECA network + +parameters: + eca_mgmt_name: + type: string + label: eca management name + description: eca management name + eca_mgmt_start: + type: string + label: eca management start + description: eca management start + eca_mgmt_end: + type: string + label: eca management end + description: eca management end + eca_mgmt_cidr: + type: string + label: eca management cidr + description: eca management cidr + eca_mgmt_netmask: + type: string + label: ECA mgmt network subnet mask + description: ECA mgmt network subnet mask + security_group_name: + type: string + label: MMSC security group name + description: MMSC security group name + +resources: + mms_security_group: + type: OS::Neutron::SecurityGroup + properties: + description: mmsc security group + name: {get_param: security_group_name} + rules: [{"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0} + ] + eca_mgmt_net: + type: OS::Contrail::VirtualNetwork + properties: + name: {get_param: eca_mgmt_name} + + eca_mgmt_network_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: eca_mgmt_name} + allocation_pools: [{"start": {get_param: eca_mgmt_start}, "end": {get_param: eca_mgmt_end}}] + cidr: {get_param: eca_mgmt_cidr} + #enable_dhcp: false + #gateway_ip: null + network_id: {get_resource: eca_mgmt_net} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/cmaui.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/cmaui.env new file mode 100644 index 0000000000..2e0f4c0796 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/cmaui.env @@ -0,0 +1,15 @@ +parameters: + cmaui_names: ZRDM1MMSC02CMI001,ZRDM1MMSC02CMI002 + cmaui_flavor: m1.large + cmaui_image: cmaui-5.0.2.5_v25 + cmaui_cinder_volume_size: 55 + oam_net_name: oam_protected_net_0 + oam_network_netmask: 255.255.255.192 + oam_network_gateway: 10.20.30.1 + external_dns: 155.165.201.250 + external_ntp: 155.165.194.100 + security_group_name: mmsc_security_group_1 + availability_zone_0: nova + timezone: UTC + cmaui_oam_ips: 107.250.172.42,107.250.172.43 + CMAUI_volume_type: Platinum \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/cmaui.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/cmaui.yml new file mode 100644 index 0000000000..1b575858fb --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/cmaui.yml @@ -0,0 +1,171 @@ +heat_template_version: 2013-05-23 + +################################# +# +# Changes from MSO 01/26/2016 +# Updated per ECOMP feedback +# +################################# + +description: cmaui server template for vMMSC + +parameters: + vnf_id: + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-CMAUI_id + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_cinder_volume_size: + type: number + label: CMAUI Cinder volume size + description: the size of the CMAUI Cinder volume + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + oam_net_name: + type: string + description: UID of OAM network + oam_network_netmask: + type: string + label: oam network netmask + description: oam network gateway + oam_network_gateway: + type: string + label: oam network gateway + description: oam network gateway + external_dns: + type: string + label: dns server + description: dns server + external_ntp: + type: string + label: ntp server + description: ntp server + security_group_name: + type: string + label: security group name + description: the name of security group + timezone: + type: string + label: timezone + description: timezone + cmaui_oam_ips: + type: comma_delimited_list + label: CMAUI oam_net IP addresses + description: CMAUI oam_net IP addresses + CMAUI_volume_type: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + +resources: + server_cmaui: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_0 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + cmaui.mgmt.ip=${cmaui.mgmt.ip} + cmaui.mgmt.netmask=${cmaui.mgmt.netmask} + cmaui.mgmt.gateway=${cmaui.mgmt.gateway} + cmaui.external.dns=${cmaui.external.dns} + cmaui.external.ntp=${cmaui.external.ntp} + cmaui.node=${cmaui.node} + cmaui.timezone=${cmaui.timezone} + params: + ${cmaui.mgmt.ip}: {get_param: [cmaui_oam_ips, 0]} + ${cmaui.mgmt.netmask}: {get_param: oam_network_netmask} + ${cmaui.mgmt.gateway}: {get_param: oam_network_gateway} + ${cmaui.external.dns}: {get_param: external_dns} + ${cmaui.external.ntp}: {get_param: external_ntp} + ${cmaui.node}: {get_param: [cmaui_names, 0]} + ${cmaui.timezone}: {get_param: timezone} + user_data_format: RAW + + cmaui_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: cmaui_cinder_volume_size} + volume_type: {get_param: CMAUI_volume_type} + + cmaui_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: cmaui_volume} + instance_uuid: {get_resource: server_cmaui} + + cmaui_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_cmaui1: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 1]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui1_port_0 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + cmaui.mgmt.ip=${cmaui.mgmt.ip} + cmaui.mgmt.netmask=${cmaui.mgmt.netmask} + cmaui.mgmt.gateway=${cmaui.mgmt.gateway} + cmaui.external.dns=${cmaui.external.dns} + cmaui.external.ntp=${cmaui.external.ntp} + cmaui.node=${cmaui.node} + cmaui.timezone=${cmaui.timezone} + params: + ${cmaui.mgmt.ip}: {get_param: [cmaui_oam_ips, 1]} + ${cmaui.mgmt.netmask}: {get_param: oam_network_netmask} + ${cmaui.mgmt.gateway}: {get_param: oam_network_gateway} + ${cmaui.external.dns}: {get_param: external_dns} + ${cmaui.external.ntp}: {get_param: external_ntp} + ${cmaui.node}: {get_param: [cmaui_names, 1]} + ${cmaui.timezone}: {get_param: timezone} + user_data_format: RAW + + cmaui1_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: cmaui_cinder_volume_size} + volume_type: {get_param: CMAUI_volume_type} + + cmaui1_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: cmaui1_volume} + instance_uuid: {get_resource: server_cmaui1} + + cmaui1_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 1]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/eca_oam.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/eca_oam.env new file mode 100644 index 0000000000..f9991722b3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/eca_oam.env @@ -0,0 +1,20 @@ +parameters: + eca_names: ZRDM1MMSC02OAM001,ZRDM1MMSC02OAM002 + arb_names: ZRDM1MMSC02ARB001 + oam_image_name: ECABASE + oam_flavor: lc.xlarge4 + arbiter_flavor: m1.large2 + availability_zone_0: nova + oam_net_name: oam_protected_net_0 + eca_mgmt_net_name: int_mms_eca_mgmt_net_1 + eca_oam_ips: 107.250.172.44,107.250.172.45 + eca_eca_mgmt_ips: 172.25.137.242,172.25.137.243 + eca_oam_gateway: 107.250.172.1 + arb_oam_ips: 107.250.172.46 + arb_eca_mgmt_ips: 172.25.137.244 + security_group_name: mmsc_security_group_1 + oam_volume_size: 1800 + arb_volume_size: 40 + swift_eca_url: http://object-store.rdm2.cci.com:8080/v1/AUTH_1bbab536a19b4756926e7d0ec1eb543c/eca + ECA_OAM_volume_type: Platinum + ARB_volume_type: Platinum diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/eca_oam.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/eca_oam.yaml new file mode 100644 index 0000000000..84e8f7c6c9 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/eca_oam.yaml @@ -0,0 +1,379 @@ +heat_template_version: 2013-05-23 + +########################################################## +# +# Changes from MSO +# - Updated per ECOMP Feedback +# +# +########################################################## + +description: This stack creates two ECA OAM VM and one ARB VM + +parameters: + vnf_id: + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-ECA_id + eca_names: + type: comma_delimited_list + label: oam servers names + description: the names of the OAM1,OAM2 VM instances + arb_names: + type: comma_delimited_list + label: arbiter server names + description: the names of the arbiter VM instances + oam_image_name: + type: string + label: image name + description: the OAM image name + oam_flavor: + type: string + label: flavor name + description: OAM flavor name + arbiter_flavor: + type: string + label: flavor name + description: arbiter flavor name + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + oam_net_name: + type: string + label: oam network name + description: the name of the oam network + eca_mgmt_net_name: + type: string + label: internal network name + description: the name of the internal network + eca_oam_ips: + type: comma_delimited_list + label: oam network ips + description: the ips of oam networks for eca VM + eca_oam_gateway: + type: string + label: oam1 oam gateway + description: the ip of oam gateway + eca_eca_mgmt_ips: + type: comma_delimited_list + label: eca_mgmt network ips for eca VM + description: internal eca_mgmt network ips for eca VM + arb_oam_ips: + type: comma_delimited_list + label: oam network ips for arb VM + description: oam network ips for eca VM + arb_eca_mgmt_ips: + type: comma_delimited_list + label: eca_mgmt network ips + description: internal eca_mgmt network ips for arb VM + security_group_name: + type: string + label: security group name + description: the name of security group + oam_volume_size: + type: number + label: volume size + description: the size of the OAM volume + arb_volume_size: + type: number + label: volume size + description: the size of the ARB volume + swift_eca_url: + type: string + label: Swift URL + description: Base URL for eca swift object store + ECA_OAM_volume_type: + type: string + label: eca oam vm volume type + description: the name of the target volume backend + ARB_volume_type: + type: string + label: arb vm volume type + description: the name of the target volume backend + +resources: + oam1_instance: + type: OS::Nova::Server + properties: + name: {get_param: [eca_names, 0]} + image: {get_param: oam_image_name} + flavor: {get_param: oam_flavor} + availability_zone: {get_param: availability_zone_0} + networks: + - port: {get_resource: oam1_int_port} + - port: {get_resource: oam1_mgmt_port} + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + sed -i s/HOSTNAME.*/"HOSTNAME=oam1_hostname"/g /etc/sysconfig/network + eth1_ip_address='oam1_mgt_ip' + eth1_gateway='oam_gateway' + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + mkdir /etc/puppet/files/roles/transcoder + mkdir /etc/puppet/files/roles/oam_primary + curl swift_url/etc/puppet/manifests/roles/oam_primary.pp > /etc/puppet/manifests/roles/oam_primary.pp + curl swift_url/etc/puppet/manifests/roles/transcoder.pp > /etc/puppet/manifests/roles/transcoder.pp + curl swift_url/etc/puppet/files/roles/oam_primary/config.yaml > /etc/puppet/files/roles/oam_primary/config.yaml + curl swift_url/etc/puppet/files/roles/transcoder/config.yaml > /etc/puppet/files/roles/transcoder/config.yaml + curl swift_url/etc/puppet/files/roles/transcoder/hpm.conf > /etc/puppet/files/roles/transcoder/hpm.conf + curl swift_url/etc/puppet/files/roles/transcoder/trx.conf > /etc/puppet/files/roles/transcoder/trx.conf + curl swift_url/etc/puppet/files/roles/transcoder/plugins-mo.conf > /etc/puppet/files/roles/transcoder/plugins-mo.conf + curl swift_url/etc/puppet/files/global/11-customer.conf > /etc/puppet/files/global/11-customer.conf + curl swift_url/etc/puppet/manifests/site.pp > /etc/puppet/manifests/site.pp + curl swift_url/scripts/van-init-replicaset > /usr/sbin/van-init-replicaset + van-role oam_primary > /root/startup-van-role.out + curl swift_url/scripts/fdisk-keystrokes > /root/fdisk-keystrokes + fdisk /dev/vdb < /root/fdisk-keystrokes + curl swift_url/scripts/os-conf-cinder-vol > /root/os-conf-cinder-vol + chmod 755 /root/os-conf-cinder-vol + /root/os-conf-cinder-vol 2>> /tmp/cinder_volume.log + params: + oam1_mgt_ip: {get_param: [eca_oam_ips, 0] } + oam_gateway: {get_param: eca_oam_gateway } + oam1_hostname: {get_param: [eca_names, 0]} + swift_url: {get_param: swift_eca_url} + + oam1_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [eca_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + oam1_int_port: + type: OS::Neutron::Port + properties: + network: {get_param: eca_mgmt_net_name} + fixed_ips: [{"ip_address": {get_param: [eca_eca_mgmt_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + oam1_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: oam_volume_size} + volume_type: {get_param: ECA_OAM_volume_type} + + oam1_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: oam1_volume} + instance_uuid: {get_resource: oam1_instance} + + oam2_instance: + type: OS::Nova::Server + properties: + name: {get_param: [eca_names, 1]} + image: {get_param: oam_image_name} + flavor: {get_param: oam_flavor} + availability_zone: {get_param: availability_zone_0} + networks: + - port: {get_resource: oam2_int_port} + - port: {get_resource: oam2_mgmt_port} + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + sed -i s/HOSTNAME.*/"HOSTNAME=oam2_hostname"/g /etc/sysconfig/network + eth1_ip_address='oam2_mgt_ip' + eth1_gateway='oam_gateway' + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + curl swift_url/etc/puppet/manifests/roles/oam_secondary.pp > /etc/puppet/manifests/roles/oam_secondary.pp + curl swift_url/etc/puppet/files/global/config.yaml > /etc/puppet/files/global/config.yaml + curl swift_url/etc/puppet/files/global/11-customer.conf > /etc/puppet/files/global/11-customer.conf + van-role oam_secondary > /root/startup-van-role.out + curl swift_url/scripts/fdisk-keystrokes > /root/fdisk-keystrokes + fdisk /dev/vdb < /root/fdisk-keystrokes + curl swift_url/scripts/os-conf-cinder-vol > /root/os-conf-cinder-vol + chmod 755 /root/os-conf-cinder-vol + /root/os-conf-cinder-vol 2>> /tmp/cinder_volume.log + + params: + oam2_mgt_ip: {get_param: [eca_oam_ips, 1] } + oam2_hostname: {get_param: [eca_names, 1]} + swift_url: {get_param: swift_eca_url} + oam_gateway: {get_param: eca_oam_gateway } + + oam2_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [eca_oam_ips, 1]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + oam2_int_port: + type: OS::Neutron::Port + properties: + network: {get_param: eca_mgmt_net_name} + fixed_ips: [{"ip_address": {get_param: [eca_eca_mgmt_ips, 1]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + oam2_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: oam_volume_size} + volume_type: {get_param: ECA_OAM_volume_type} + + oam2_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: oam2_volume} + instance_uuid: {get_resource: oam2_instance} + + arb_instance: + type: OS::Nova::Server + properties: + name: {get_param: [arb_names, 0]} + image: {get_param: oam_image_name} + flavor: {get_param: arbiter_flavor} + availability_zone: {get_param: availability_zone_0} + networks: + - port: {get_resource: arb_int_port} + - port: {get_resource: arb_mgmt_port} + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + sed -i s/HOSTNAME.*/"HOSTNAME=arb_hostname"/g /etc/sysconfig/network + eth1_ip_address='arb_mgt_ip' + eth1_gateway='oam_gateway' + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + curl swift_url/etc/puppet/manifests/roles/oam_arbiter.pp > /etc/puppet/manifests/roles/oam_arbiter.pp + curl swift_url/etc/puppet/files/global/config.yaml > /etc/puppet/files/global/config.yaml + curl swift_url/etc/puppet/files/global/11-customer.conf > /etc/puppet/files/global/11-customer.conf + van-role oam_arbiter > /root/startup-van-role.out + curl swift_url/scripts/fdisk-keystrokes > /root/fdisk-keystrokes + fdisk /dev/vdb < /root/fdisk-keystrokes + curl swift_url/scripts/os-conf-cinder-vol > /root/os-conf-cinder-vol + chmod 755 /root/os-conf-cinder-vol + /root/os-conf-cinder-vol 2>> /tmp/cinder_volume.log + params: + arb_mgt_ip: {get_param: [arb_oam_ips, 0] } + arb_hostname: {get_param: [arb_names, 0]} + swift_url: {get_param: swift_eca_url} + oam_gateway: {get_param: eca_oam_gateway } + + arb_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [arb_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + arb_int_port: + type: OS::Neutron::Port + properties: + network: {get_param: eca_mgmt_net_name} + fixed_ips: [{"ip_address": {get_param: [arb_eca_mgmt_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + arb_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: arb_volume_size} + volume_type: {get_param: ARB_volume_type} + arb_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: arb_volume} + instance_uuid: {get_resource: arb_instance} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/sg_eca_mgmt.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/sg_eca_mgmt.env new file mode 100644 index 0000000000..8012063ac0 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/allHeatsAreBase/inputs/sg_eca_mgmt.env @@ -0,0 +1,7 @@ +parameters: + eca_mgmt_name: int_eca_mgmt_net_1 + eca_mgmt_cidr: 172.25.137.192/26 + eca_mgmt_netmask: 255.255.255.192 + eca_mgmt_start: 172.25.137.195 + eca_mgmt_end: 172.25.137.254 + security_group_name: mmsc_security_group_1 diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/expectedOutput/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/expectedOutput/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..4814d1c086 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/expectedOutput/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,347 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.eca_oam: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + metadata: + type: string + description: cmaui metadata + oam_flavor: + type: string + description: OAM flavor name + default: lc.xlarge4 + eca_eca_mgmt_ips: + type: list + description: internal eca_mgmt network ips for eca VM + default: + - 172.25.137.242 + - 172.25.137.243 + entry_schema: + type: string + eca_mgmt_net_name: + type: string + description: the name of the internal network + default: int_mms_eca_mgmt_net_1 + ECA_OAM_volume_type: + type: string + description: the name of the target volume backend + default: Platinum + arb_eca_mgmt_ips: + type: list + description: internal eca_mgmt network ips for arb VM + default: + - 172.25.137.244 + entry_schema: + type: string + networks: + type: string + description: cmaui network name + cmaui_name: + type: string + description: cmaui name + arb_volume_size: + type: float + description: the size of the ARB volume + default: 40 + vnf_id: + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-ECA_id + availability_zone_0: + type: string + description: availabilityzone name + default: nova + oam_image_name: + type: string + description: the OAM image name + default: ECABASE + oam_volume_size: + type: float + description: the size of the OAM volume + default: 1800 + swift_eca_url: + type: string + description: Base URL for eca swift object store + default: http://object-store.rdm2.cci.com:8080/v1/AUTH_1bbab536a19b4756926e7d0ec1eb543c/eca + oam_net_name: + type: string + description: the name of the oam network + default: oam_protected_net_0 + ARB_volume_type: + type: string + description: the name of the target volume backend + default: Platinum + eca_names: + type: list + description: the names of the OAM1,OAM2 VM instances + default: + - ZRDM1MMSC02OAM001 + - ZRDM1MMSC02OAM002 + entry_schema: + type: string + arbiter_flavor: + type: string + description: arbiter flavor name + default: m1.large2 + eca_oam_ips: + type: list + description: the ips of oam networks for eca VM + default: + - 107.250.172.44 + - 107.250.172.45 + entry_schema: + type: string + security_group_name: + type: string + description: the name of security group + default: mmsc_security_group_1 + user_data: + type: string + description: cmaui user data + cmaui_image: + type: string + description: cmaui image + arb_names: + type: list + description: the names of the arbiter VM instances + default: + - ZRDM1MMSC02ARB001 + entry_schema: + type: string + cmaui_flavor: + type: string + description: cmaui flavor name + user_data_format: + type: string + description: cmaui user data + eca_oam_gateway: + type: string + description: the ip of oam gateway + default: 107.250.172.1 + arb_oam_ips: + type: list + description: oam network ips for eca VM + default: + - 107.250.172.46 + entry_schema: + type: string + requirements: + - link_arb_mgmt_port: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_oam2_mgmt_port: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - local_storage_arb_instance: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - local_storage_oam1_instance: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_oam1_int_port: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_oam1_mgmt_port: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_arb_int_port: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_oam2_int_port: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - local_storage_oam2_instance: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + capabilities: + attachment_oam2_volume: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + binding_oam2_instance: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + attachment_oam2_int_port: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + attachment_oam1_volume: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + os_oam1_instance: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + scalable_oam2_instance: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + scalable_arb_instance: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + endpoint_oam1_instance: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + binding_arb_instance: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + host_arb_instance: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + endpoint_arb_instance: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + attachment_oam1_int_port: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + attachment_arb_volume: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + host_oam1_instance: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + os_oam2_instance: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + endpoint_oam2_instance: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + scalable_oam1_instance: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + host_oam2_instance: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + os_arb_instance: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + attachment_oam1_mgmt_port: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + attachment_arb_int_port: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + attachment_arb_mgmt_port: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + attachment_oam2_mgmt_port: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + binding_oam1_instance: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/expectedOutput/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/expectedOutput/MainServiceTemplate.yaml new file mode 100644 index 0000000000..d9f89dfc0e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/expectedOutput/MainServiceTemplate.yaml @@ -0,0 +1,4193 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.nems_be: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.lb: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.eca_trx: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.nems_fe: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.mmsc: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + lb_flavor_name: + label: Load balancer flavor name + hidden: false + immutable: false + type: string + description: the flavor name of MMSC load balancer instance + default: m1.xlarge + ha_net_local_ip2: + label: ha net network local ip2 + hidden: false + immutable: false + type: string + description: the local ip2 of the ha network + default: 172.26.1.4 + mmsc_dmz_protected_snat_ips: + label: mmsc dmz_protected snat ips + hidden: false + immutable: false + type: list + description: mmsc dmz_protected snat ips + default: + - 107.239.14.24 + - 107.239.14.25 + - 107.239.14.26 + - 107.239.14.27 + entry_schema: + type: string + ha_net_local_ip1: + label: ha net network local ip1 + hidden: false + immutable: false + type: string + description: the local ip1 of the ha network + default: 172.26.1.3 + mms_traffic_end: + label: mmsc traffic end IP + hidden: false + immutable: false + type: string + description: mmsc traffic end IP + default: 172.26.2.254 + nems_traffic_end: + label: nems traffic end + hidden: false + immutable: false + type: string + description: nems traffic end + default: 172.26.3.254 + mmsc_cinder_volume_size: + label: MMSC Cinder volume size + hidden: false + immutable: false + type: float + description: the size of the MMSC Cinder volume + default: 480 + nems_internal_cidr: + label: nems ineternal cidr + hidden: false + immutable: false + type: string + description: nems internal cidr + default: 172.26.6.0/24 + eca_mgmt_cidr: + label: eca management cidr + hidden: false + immutable: false + type: string + description: eca management cidr + default: 172.25.137.192/26 + nems_traffic_start: + label: nems traffic start + hidden: false + immutable: false + type: string + description: nems traffic start + default: 172.26.3.3 + eca_trx_names: + label: ECA_TRX server names + hidden: false + immutable: false + type: list + description: ECA_TRX server names + default: + - ZRDM1MMSC03TRX001 + - ZRDM1MMSC03TRX002 + - ZRDM1MMSC03TRX003 + - ZRDM1MMSC03TRX004 + - ZRDM1MMSC03TRX005 + - ZRDM1MMSC03TRX006 + - ZRDM1MMSC03TRX007 + - ZRDM1MMSC03TRX008 + - ZRDM1MMSC03TRX009 + - ZRDM1MMSC03TRX010 + - ZRDM1MMSC03TRX011 + - ZRDM1MMSC03TRX012 + - ZRDM1MMSC03TRX013 + - ZRDM1MMSC03TRX014 + - ZRDM1MMSC03TRX015 + - ZRDM1MMSC03TRX016 + - ZRDM1MMSC03TRX017 + - ZRDM1MMSC03TRX018 + - ZRDM1MMSC03TRX019 + - ZRDM1MMSC03TRX020 + entry_schema: + type: string + nems_internal_name: + label: nems internal network name + hidden: false + immutable: false + type: string + description: nems internal network name + default: int_mms_nems_internal_net_2 + nems_traffic_net_local_ip1: + label: nems traffic network local ip1 + hidden: false + immutable: false + type: string + description: the local ip1 of the nems traffic network + default: 172.26.3.3 + nems_traffic_net_local_ip2: + label: nems traffic network local ip2 + hidden: false + immutable: false + type: string + description: the local ip2 of the nems traffic network + default: 172.26.3.4 + nems_fe_names: + label: NEMS_FE server names + hidden: false + immutable: false + type: list + description: NEMS_FE server names + default: + - ZRDM1MMSC03NFE001 + - ZRDM1MMSC03NFE002 + entry_schema: + type: string + nems_be_nems_imap_net_ips: + label: nems imap_net IPs for NEMS_BE + hidden: false + immutable: false + type: string + description: nems imap net IPs for NEMS_BE + default: 172.26.7.13 + nems_be_names: + label: NEMS_BE server names + hidden: false + immutable: false + type: string + description: NEMS_BE server names + default: ZRDM1MMSC03NBE001 + nems_traffic_netmask: + label: NEMS traffic network subnet mask + hidden: false + immutable: false + type: string + description: NEMS traffic network subnet mask + default: 255.255.255.0 + nems_fe_nems_imap_net_ips: + label: nems_imap_net IPs for NEMS_FE + hidden: false + immutable: false + type: list + description: nems_imap_net IPs for NEMS_FE + default: + - 172.26.7.11 + - 172.26.7.12 + entry_schema: + type: string + nems_fe_nems_user_web_net_ips: + label: nems_web_user_net IPs for NEMS_FE + hidden: false + immutable: false + type: list + description: nems_web_user_net IPs for NEMS_FE + default: + - 172.26.4.11 + - 172.26.4.12 + entry_schema: + type: string + nems_user_web_gateway: + label: NEMS user web network gateway + hidden: false + immutable: false + type: string + description: NEMS user web network gateway + default: 172.26.4.1 + nems_imap_end: + label: nems imap end + hidden: false + immutable: false + type: string + description: nems imap end + default: 172.26.7.254 + eca_traffic_net_local_ip1: + label: eca traffic network local ip1 + hidden: false + immutable: false + type: string + description: the local ip1 of the eca traffic network + default: 172.26.5.3 + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + default: cmaui-5.0.2.5_v25 + eca_traffic_net_local_ip2: + label: eca traffic network local ip2 + hidden: false + immutable: false + type: string + description: the local ip2 of the eca traffic network + default: 172.26.5.4 + nems_volume_size: + label: nems fe volume size + hidden: false + immutable: false + type: float + description: nems fe volume size + default: 50 + mms_traffic_start: + label: mmsc traffic start IP + hidden: false + immutable: false + type: string + description: mmsc traffic start IP + default: 172.26.2.3 + ha_net_start: + label: ha net start + hidden: false + immutable: false + type: string + description: ha net start + default: 172.26.1.3 + nems_imap_gateway: + label: nems imap gateway + hidden: false + immutable: false + type: string + description: nems imap gateway + default: 172.26.7.1 + mmsc_core_virtual_server_ips: + label: mmsc core virtual server ips + hidden: false + immutable: false + type: list + description: mmsc core virtual server ips + default: + - 172.31.10.21 + - 172.31.10.22 + entry_schema: + type: string + cmaui_oam_ips: + label: CMAUI oam_net IP addresses + hidden: false + immutable: false + type: list + description: CMAUI oam_net IP addresses + default: + - 107.250.172.42 + - 107.250.172.43 + entry_schema: + type: string + CMAUI_volume_type: + label: CMAUI vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + default: Platinum + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + default: + - ZRDM1MMSC02CMI001 + - ZRDM1MMSC02CMI002 + entry_schema: + type: string + eca_trx_eca_traffic_net_ips: + label: eca traffic net IPs for ECA_TRX + hidden: false + immutable: false + type: list + description: eca traffic net IPs for ECA_TRX + default: + - 172.26.5.11 + - 172.26.5.12 + - 172.26.5.13 + - 172.26.5.14 + - 172.26.5.15 + - 172.26.5.16 + - 172.26.5.17 + - 172.26.5.18 + - 172.26.5.19 + - 172.26.5.20 + - 172.26.5.21 + - 172.26.5.22 + - 172.26.5.23 + - 172.26.5.24 + - 172.26.5.25 + - 172.26.5.26 + - 172.26.5.27 + - 172.26.5.28 + - 172.26.5.29 + - 172.26.5.30 + entry_schema: + type: string + eca_trx_image: + label: Image for ECA TRX server + hidden: false + immutable: false + type: string + description: Image for ECA TRX server + default: ECABASE + lb_names: + label: MMSC load balancer instance names + hidden: false + immutable: false + type: list + description: MMSC load balancer instance names + default: + - ZRDM1MMSC03ALB001 + - ZRDM1MMSC03ALB002 + entry_schema: + type: string + eca_mgmt_end: + label: eca management end + hidden: false + immutable: false + type: string + description: eca management end + default: 172.25.137.254 + nems_user_web_end: + label: nems user web end + hidden: false + immutable: false + type: string + description: nems user web end + default: 172.26.4.254 + eca_traffic_cidr: + label: eca traffic cidr + hidden: false + immutable: false + type: string + description: eca traffic cidr + default: 172.26.5.0/24 + ha_net_cidr: + label: ha net cidr + hidden: false + immutable: false + type: string + description: ha net cidr + default: 172.26.1.0/24 + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + default: nova + nems_fe_nems_internal_net_ips: + label: nems_internal_net IPs for NEMS_FE + hidden: false + immutable: false + type: list + description: nems_internal_net IPs for NEMS_FE + default: + - 172.26.6.11 + - 172.26.6.12 + entry_schema: + type: string + NEMS_FE_volume_type: + label: nems fe vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + default: Platinum + security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + default: mmsc_security_group_1 + nems_fe_nems_traffic_net_ips: + label: nems_traffic_net IPs for NEMS_FE + hidden: false + immutable: false + type: list + description: nems_traffic_net IPs for NEMS_FE + default: + - 172.26.3.11 + - 172.26.3.12 + entry_schema: + type: string + nems_imap_start: + label: nems imap start + hidden: false + immutable: false + type: string + description: nems imap start + default: 172.26.7.3 + ha_net_name: + label: ha_failover network name + hidden: false + immutable: false + type: string + description: ha_failover network name + default: int_mms_ha_net_2 + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + default: m1.large + eca_traffic_start: + label: eca traffic start + hidden: false + immutable: false + type: string + description: eca traffic start + default: 172.26.5.3 + NEMS_BE_volume_type: + label: nems be vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + default: Platinum + lb_image_name: + label: MMSC load balancer image name + hidden: false + immutable: false + type: string + description: MMSC load balancer image name + default: BIGIP-11.5.3.0.0.163 + nems_internal_start: + label: nems internal start + hidden: false + immutable: false + type: string + description: nems internal start + default: 172.26.6.3 + nems_internal_gateway: + label: nems internal gw + hidden: false + immutable: false + type: string + description: nems internal gw + default: 172.26.6.1 + dmz_protected_net_name: + label: UID of dmz_protected network + hidden: false + immutable: false + type: string + description: UID of dmz_protected network + default: dmz_protected_net_0 + nems_be_volume_size: + label: nems be volume size + hidden: false + immutable: false + type: float + description: nems be volume size + default: 610 + mms_traffic_netmask: + label: MMS traffic network subnet mask + hidden: false + immutable: false + type: string + description: MMS traffic network subnet mask + default: 255.255.255.0 + nems_be_image: + label: Image for NEMS BE server + hidden: false + immutable: false + type: string + description: Image for NEMS BE server + default: nems-2.1.2_v29 + nems_user_web_net_local_ip1: + label: nems user web network local ip1 + hidden: false + immutable: false + type: string + description: the local ip1 of the nems user web network + default: 172.26.4.3 + eca_trx_mgmt_ips: + label: eca mgmt net IP for ECA_TRX + hidden: false + immutable: false + type: list + description: eca mgmt net IP for ECA_TRX + default: + - 172.25.137.202 + - 172.25.137.203 + - 172.25.137.204 + - 172.25.137.205 + - 172.25.137.206 + - 172.25.137.207 + - 172.25.137.208 + - 172.25.137.209 + - 172.25.137.210 + - 172.25.137.211 + - 172.25.137.212 + - 172.25.137.213 + - 172.25.137.214 + - 172.25.137.215 + - 172.25.137.216 + - 172.25.137.217 + - 172.25.137.218 + - 172.25.137.219 + - 172.25.137.220 + - 172.25.137.221 + entry_schema: + type: string + nems_user_web_cidr: + label: nems user web cidr + hidden: false + immutable: false + type: string + description: nems user web cidr + default: 172.26.4.0/24 + nems_user_web_net_local_ip2: + label: nems user web network local ip2 + hidden: false + immutable: false + type: string + description: the local ip2 of the nems user web network + default: 172.26.4.4 + nems_traffic_gateway: + label: NEMS traffic network gateway + hidden: false + immutable: false + type: string + description: NEMS traffic network gateway + default: 172.26.3.1 + nems_imap_name: + label: nems imap name + hidden: false + immutable: false + type: string + description: nems imap name + default: int_mms_nems_imap_net_2 + mms_traffic_net_floating_ip: + label: mmsc traffic floating ip + hidden: false + immutable: false + type: string + description: mmsc traffic floating ip + default: 172.26.2.5 + nems_internal_netmask: + label: NEMS internal network subnet mask + hidden: false + immutable: false + type: string + description: NEMS internal network subnet mask + default: 255.255.255.0 + nems_user_web_netmask: + label: NEMS user web network subnet mask + hidden: false + immutable: false + type: string + description: NEMS user web network subnet mask + default: 255.255.255.0 + mms_traffic_net_local_ip1: + label: mmsc traffic network local ip1 + hidden: false + immutable: false + type: string + description: the local ip1 of the mmsc traffic network + default: 172.26.2.3 + mms_traffic_net_local_ip2: + label: mmsc traffic network local ip2 + hidden: false + immutable: false + type: string + description: the local ip2 of the mmsc traffic network + default: 172.26.2.4 + oam_net_name: + hidden: false + immutable: false + type: string + description: UID of OAM network + default: oam_protected_net_0 + external_ntp: + label: ntp server + hidden: false + immutable: false + type: string + description: ntp server + default: 155.165.194.100 + mms_traffic_net_cidr: + label: MMS traffic network address (CIDR notation) + hidden: false + immutable: false + type: string + description: MMS traffic network address (CIDR notation) + default: 172.26.2.0/24 + lb_dmz_protected_ips: + label: dmz protected network local ips for lb VM + hidden: false + immutable: false + type: list + description: local ips of the dmz protected network for lb VM + default: + - 107.239.14.19 + - 107.239.14.20 + entry_schema: + type: string + eca_mgmt_start: + label: eca management start + hidden: false + immutable: false + type: string + description: eca management start + default: 172.25.137.195 + MMSC_volume_type: + label: MMSC vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + default: Platinum + nems_fe_flavor: + label: Flavor for NEMS FE server + hidden: false + immutable: false + type: string + description: Flavor for NEMS FE server + default: m1.large2 + eca_mgmt_netmask: + label: ECA mgmt network subnet mask + hidden: false + immutable: false + type: string + description: ECA mgmt network subnet mask + default: 255.255.255.192 + oam_network_netmask: + label: oam network netmask + hidden: false + immutable: false + type: string + description: oam network gateway + default: 255.255.255.192 + oam_network_route_1: + label: oam network route 1 + hidden: false + immutable: false + type: string + description: oam network route 1 + default: 155.165.201.250/32,107.250.172.1 + oam_network_route_2: + label: oam network route 2 + hidden: false + immutable: false + type: string + description: oam network route 2 + default: 155.165.194.100/32,107.250.172.1 + mms_traffic_net_name: + label: Name of MMS traffic network + hidden: false + immutable: false + type: string + description: Name of MMS traffic network + default: int_mms_mms_traffic_net_2 + nems_user_web_name: + label: nems user web name + hidden: false + immutable: false + type: string + description: nems user web name + default: int_mms_nems_web_net_2 + eca_traffic_net_floating_ip: + label: eca traffic floating ip + hidden: false + immutable: false + type: string + description: eca traffic floating ip + default: 172.26.5.5 + eca_traffic_end: + label: eca traffic end + hidden: false + immutable: false + type: string + description: eca traffic end + default: 172.26.5.254 + eca_trx_flavor: + label: Flavor for ECA TRX server + hidden: false + immutable: false + type: string + description: Flavor for ECA TRX server + default: m1.xlarge + lb_oam_ips: + label: management network ips for mmsc lb + hidden: false + immutable: false + type: list + description: the ips of the management network for mmsc lb + default: + - 107.250.172.50 + - 107.250.172.51 + entry_schema: + type: string + nems_fe_oam_ips: + label: OAM_net IP for NEMS_FE + hidden: false + immutable: false + type: list + description: OAM_net IP for NEMS_FE + default: + - 107.250.172.64 + - 107.250.172.65 + entry_schema: + type: string + nems_be_flavor: + label: Flavor for NEMS BE server + hidden: false + immutable: false + type: string + description: Flavor for NEMS BE server + default: m1.large2 + lb_cor_direct_ips: + label: cor direct network local ips for lb VM + hidden: false + immutable: false + type: list + description: local ips of cor direct network for lb VM + default: + - 172.31.10.19 + - 172.31.10.20 + entry_schema: + type: string + nems_traffic_name: + label: nems traffic name + hidden: false + immutable: false + type: string + description: nems traffic name + default: int_mms_nems_traffic_net_2 + timezone: + label: timezone + hidden: false + immutable: false + type: string + description: timezone + default: UTC + cmaui_cinder_volume_size: + label: CMAUI Cinder volume size + hidden: false + immutable: false + type: float + description: the size of the CMAUI Cinder volume + default: 55 + nems_user_web_start: + label: nems user web start + hidden: false + immutable: false + type: string + description: nems user web end + default: 172.26.4.3 + mmsc_names: + label: MMSC server names + hidden: false + immutable: false + type: list + description: MMSC server names + default: + - ZRDM1MMSC03MMS001 + - ZRDM1MMSC03MMS002 + - ZRDM1MMSC03MMS003 + - ZRDM1MMSC03MMS004 + - ZRDM1MMSC03MMS005 + entry_schema: + type: string + eca_mgmt_net_name: + label: eca management network ID + hidden: false + immutable: false + type: string + description: Network ID for eca management + default: int_eca_mgmt_net_1 + eca_traffic_name: + label: eca traffic name + hidden: false + immutable: false + type: string + description: eca traffic name + default: int_mms_eca_traffic_net_2 + nems_internal_end: + label: nems internal end + hidden: false + immutable: false + type: string + description: nems internal end + default: 172.26.6.254 + nems_be_nems_internal_net_ips: + label: nems internal net IPs for NEMS_BE + hidden: false + immutable: false + type: string + description: nems internal net IPs for NEMS_BE + default: 172.26.6.13 + mmsc_dmz_protected_virtual_server_ips: + label: mmsc dmz_protected virtual server ips + hidden: false + immutable: false + type: list + description: mmsc dmz_protected virtual server ips + default: + - 107.239.14.21 + - 107.239.14.22 + - 107.239.14.23 + entry_schema: + type: string + cor_direct_net_name: + label: cor direct net UID + hidden: false + immutable: false + type: string + description: cor direct net + default: cor_direct_net_0 + vnf_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-CMAUI_id + oam_network_gateway: + label: oam network gateway + hidden: false + immutable: false + type: string + description: oam network gateway + default: 10.20.30.1 + mmsc_flavor: + label: Flavor for MMSC server + hidden: false + immutable: false + type: string + description: Flavor for MMSC server + default: lc.4xlarge4 + ha_net_end: + label: ha net end + hidden: false + immutable: false + type: string + description: ha net end + default: 172.26.1.254 + nems_imap_netmask: + label: nems imap subnet mask + hidden: false + immutable: false + type: string + description: nems imap subnet mask + default: 255.255.255.0 + external_dns: + label: dns server + hidden: false + immutable: false + type: string + description: dns server + default: 155.165.201.250 + eca_traffic_net_gateway: + label: eca_traffic network gateway + hidden: false + immutable: false + type: string + description: eca_traffic network gateway + default: 172.26.5.1 + nems_be_oam_ips: + label: OAM net IPs for NEMS_BE + hidden: false + immutable: false + type: string + description: OAM net IPs for NEMS_BE + default: 107.250.172.66 + eca_trx_oam_ips: + label: OAM net IP for ECA_TRX + hidden: false + immutable: false + type: list + description: OAM net IP for ECA_TRX + default: + - 107.250.172.70 + - 107.250.172.71 + - 107.250.172.72 + - 107.250.172.73 + - 107.250.172.74 + - 107.250.172.75 + - 107.250.172.76 + - 107.250.172.77 + - 107.250.172.78 + - 107.250.172.79 + - 107.250.172.80 + - 107.250.172.81 + - 107.250.172.82 + - 107.250.172.83 + - 107.250.172.84 + - 107.250.172.85 + - 107.250.172.86 + - 107.250.172.87 + - 107.250.172.88 + - 107.250.172.89 + entry_schema: + type: string + mmsc_image: + label: Image for MMSC server + hidden: false + immutable: false + type: string + description: Image for MMSC server + default: mmsc-6.0.2_v5 + nems_imap_cidr: + label: nems imap cidr + hidden: false + immutable: false + type: string + description: nems imap cidr + default: 172.26.7.0/24 + eca_traffic_netmask: + label: ECA traffic network subnet mask + hidden: false + immutable: false + type: string + description: ECA traffic network subnet mask + default: 255.255.255.0 + nems_fe_node_roles: + label: nems fe node roles + hidden: false + immutable: false + type: list + description: nems fe node roles + default: + - FE0 + - FE1 + entry_schema: + type: string + mmsc_mms_traffic_net_ips: + label: MMSC mms_traffic_net IP addresses + hidden: false + immutable: false + type: list + description: MMSC mms_traffic_net IP addresses + default: + - 172.26.2.11 + - 172.26.2.12 + - 172.26.2.13 + - 172.26.2.14 + - 172.26.2.15 + entry_schema: + type: string + nems_traffic_net_floating_ip: + label: nems traffic floating ip + hidden: false + immutable: false + type: string + description: nems traffic floating ip + default: 172.26.3.5 + mms_traffic_net_gateway: + label: MMS traffic network gateway address + hidden: false + immutable: false + type: string + description: MMS traffic network gateway address + default: 172.26.2.1 + nems_fe_image: + label: Image for NEMS FE server + hidden: false + immutable: false + type: string + description: Image for NEMS FE server + default: nems-2.1.2_v29 + mmsc_oam_ips: + label: MMSC oam_net IP addresses + hidden: false + immutable: false + type: list + description: MMSC oam_net IP addresses + default: + - 107.250.172.54 + - 107.250.172.55 + - 107.250.172.56 + - 107.250.172.57 + - 107.250.172.58 + entry_schema: + type: string + eca_mgmt_name: + label: eca management name + hidden: false + immutable: false + type: string + description: eca management name + default: int_eca_mgmt_net_1 + nems_traffic_cidr: + label: nems traffic cidr + hidden: false + immutable: false + type: string + description: nems traffic cidr + default: 172.26.3.0/24 + nems_be_node_roles: + label: nems node roles + hidden: false + immutable: false + type: string + description: nems node roles + default: BE0 + mmsc_core_snat_ips: + label: mmsc core snat ips + hidden: false + immutable: false + type: list + description: mmsc core snat ips + default: + - 172.31.10.23 + - 172.31.10.24 + - 172.31.10.25 + - 172.31.10.26 + - 172.31.10.27 + entry_schema: + type: string + nems_user_web_net_floating_ip: + label: nems user web floating ip + hidden: false + immutable: false + type: string + description: nems user web floating ip + default: 172.26.4.5 + node_templates: + server_eca_trx9: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 8 + server_eca_trx8: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 7 + server_eca_trx7: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 6 + server_eca_trx6: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 5 + server_eca_trx5: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 4 + nems_internal_net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + network_name: + get_input: nems_internal_name + subnets: + nems_internal_network_ip_subnet: + name: + get_input: nems_internal_name + cidr: + get_input: nems_internal_cidr + allocation_pools: + - start: + get_input: nems_internal_start + end: + get_input: nems_internal_end + server_eca_trx4: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 3 + server_eca_trx3: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 2 + server_eca_trx2: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 1 + lb1_mgmt_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - lb_oam_ips + - 0 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: lb1_instance + relationship: tosca.relationships.network.BindsTo + lb2_mms_traffic_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: mms_traffic_net_local_ip2 + allowed_address_pairs: + - ip_address: + get_input: mms_traffic_net_floating_ip + network: mms_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: mms_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: lb2_instance + relationship: tosca.relationships.network.BindsTo + nems_fe1_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - nems_fe_nems_traffic_net_ips + - 0 + network: nems_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: nems_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_nems_fe1 + relationship: tosca.relationships.network.BindsTo + nems_fe2_port_3: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - nems_fe_nems_internal_net_ips + - 1 + network: nems_internal_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: nems_internal_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_nems_fe2 + relationship: tosca.relationships.network.BindsTo + server_eca_trx1: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 0 + nems_fe1_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - nems_fe_nems_user_web_net_ips + - 0 + network: nems_user_web_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: nems_user_web_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_nems_fe1 + relationship: tosca.relationships.network.BindsTo + nems_fe2_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - nems_fe_nems_user_web_net_ips + - 1 + network: nems_user_web_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: nems_user_web_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_nems_fe2 + relationship: tosca.relationships.network.BindsTo + nems_fe2_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - nems_fe_nems_traffic_net_ips + - 1 + network: nems_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: nems_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_nems_fe2 + relationship: tosca.relationships.network.BindsTo + nems_fe1_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - nems_fe_oam_ips + - 0 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_nems_fe1 + relationship: tosca.relationships.network.BindsTo + nems_fe2_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - nems_fe_oam_ips + - 1 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_nems_fe2 + relationship: tosca.relationships.network.BindsTo + nems_fe1_port_3: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - nems_fe_nems_internal_net_ips + - 0 + network: nems_internal_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: nems_internal_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_nems_fe1 + relationship: tosca.relationships.network.BindsTo + nems_fe1_port_4: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - nems_fe_nems_imap_net_ips + - 0 + network: nems_imap_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: nems_imap_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_nems_fe1 + relationship: tosca.relationships.network.BindsTo + nems_fe2_port_4: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - nems_fe_nems_imap_net_ips + - 1 + network: nems_imap_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: nems_imap_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_nems_fe2 + relationship: tosca.relationships.network.BindsTo + mms_security_group: + type: org.openecomp.resource.vfc.rules.nodes.heat.network.neutron.SecurityRules + properties: + name: + get_input: security_group_name + description: mmsc security group + rules: + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + mmsc4_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: MMSC_volume_type + size: '(get_input : mmsc_cinder_volume_size) * 1024' + lb2_eca_traffic_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: eca_traffic_net_local_ip2 + allowed_address_pairs: + - ip_address: + get_input: eca_traffic_net_floating_ip + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: lb2_instance + relationship: tosca.relationships.network.BindsTo + lb2_ha_net_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: ha_net_local_ip2 + network: ha_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: ha_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: lb2_instance + relationship: tosca.relationships.network.BindsTo + nems_user_web_net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + network_name: + get_input: nems_user_web_name + subnets: + nems_user_web_network_ip_subnet: + name: + get_input: nems_user_web_name + cidr: + get_input: nems_user_web_cidr + allocation_pools: + - start: + get_input: nems_user_web_start + end: + get_input: nems_user_web_end + lb1_ha_net_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: ha_net_local_ip1 + network: ha_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: ha_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: lb1_instance + relationship: tosca.relationships.network.BindsTo + mmsc2_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: MMSC_volume_type + size: '(get_input : mmsc_cinder_volume_size) * 1024' + cmaui1_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: CMAUI_volume_type + size: '(get_input : cmaui_cinder_volume_size) * 1024' + nems_traffic_net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + network_name: + get_input: nems_traffic_name + subnets: + nems_traffic_network_ip_subnet: + name: + get_input: nems_traffic_name + cidr: + get_input: nems_traffic_cidr + allocation_pools: + - start: + get_input: nems_traffic_start + end: + get_input: nems_traffic_end + eca_trx16_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 15 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx16 + relationship: tosca.relationships.network.BindsTo + eca_trx19_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 18 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx19 + relationship: tosca.relationships.network.BindsTo + eca_trx16_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 15 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx16 + relationship: tosca.relationships.network.BindsTo + eca_trx19_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 18 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx19 + relationship: tosca.relationships.network.BindsTo + eca_trx15_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 14 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx15 + relationship: tosca.relationships.network.BindsTo + eca_trx19_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 18 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx19 + relationship: tosca.relationships.network.BindsTo + lb1_nems_traffic_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: nems_traffic_net_local_ip1 + allowed_address_pairs: + - ip_address: + get_input: nems_traffic_net_floating_ip + network: nems_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: nems_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: lb1_instance + relationship: tosca.relationships.network.BindsTo + eca_trx11_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 10 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx11 + relationship: tosca.relationships.network.BindsTo + eca_trx11_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 10 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx11 + relationship: tosca.relationships.network.BindsTo + eca_trx12_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 11 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx12 + relationship: tosca.relationships.network.BindsTo + eca_trx12_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 11 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx12 + relationship: tosca.relationships.network.BindsTo + eca_trx11_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 10 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx11 + relationship: tosca.relationships.network.BindsTo + eca_trx12_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 11 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx12 + relationship: tosca.relationships.network.BindsTo + mmsc4_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - mmsc_oam_ips + - 3 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_mmsc4 + relationship: tosca.relationships.network.BindsTo + cmaui1_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 1 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui1 + relationship: tosca.relationships.network.BindsTo + mmsc3_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - mmsc_oam_ips + - 2 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_mmsc3 + relationship: tosca.relationships.network.BindsTo + eca_trx15_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 14 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx15 + relationship: tosca.relationships.network.BindsTo + mmsc3_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - mmsc_mms_traffic_net_ips + - 2 + network: mms_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: mms_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_mmsc3 + relationship: tosca.relationships.network.BindsTo + mmsc4_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - mmsc_mms_traffic_net_ips + - 3 + network: mms_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: mms_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_mmsc4 + relationship: tosca.relationships.network.BindsTo + eca_trx15_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 14 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx15 + relationship: tosca.relationships.network.BindsTo + eca_trx16_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 15 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx16 + relationship: tosca.relationships.network.BindsTo + lb2_mgmt_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - lb_oam_ips + - 1 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: lb2_instance + relationship: tosca.relationships.network.BindsTo + mmsc5_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: MMSC_volume_type + size: '(get_input : mmsc_cinder_volume_size) * 1024' + eca_trx7_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 6 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx7 + relationship: tosca.relationships.network.BindsTo + server_cmaui: + type: org.openecomp.resource.abstract.nodes.heat.eca_oam + directives: + - substitutable + properties: + service_template_filter: + substitute_service_template: eca_oamServiceTemplate.yaml + metadata: + vnf_id: + get_input: vnf_id + cmaui_image: + get_input: cmaui_image + cmaui_flavor: + get_input: cmaui_flavor + user_data_format: RAW + availability_zone_0: + get_input: availability_zone_0 + user_data: + str_replace: + template: | + cmaui.mgmt.ip=${cmaui.mgmt.ip} + cmaui.mgmt.netmask=${cmaui.mgmt.netmask} + cmaui.mgmt.gateway=${cmaui.mgmt.gateway} + cmaui.external.dns=${cmaui.external.dns} + cmaui.external.ntp=${cmaui.external.ntp} + cmaui.node=${cmaui.node} + cmaui.timezone=${cmaui.timezone} + params: + ${cmaui.mgmt.netmask}: + get_input: oam_network_netmask + ${cmaui.node}: + get_input: + - cmaui_names + - 0 + ${cmaui.mgmt.gateway}: + get_input: oam_network_gateway + ${cmaui.mgmt.ip}: + get_input: + - cmaui_oam_ips + - 0 + ${cmaui.external.ntp}: + get_input: external_ntp + ${cmaui.timezone}: + get_input: timezone + ${cmaui.external.dns}: + get_input: external_dns + networks: + - port: cmaui_port_0 + cmaui_name: + get_input: + - cmaui_names + - 0 + eca_trx7_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 6 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx7 + relationship: tosca.relationships.network.BindsTo + eca_trx7_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 6 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx7 + relationship: tosca.relationships.network.BindsTo + cmaui_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: CMAUI_volume_type + size: '(get_input : cmaui_cinder_volume_size) * 1024' + eca_trx3_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 2 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx3 + relationship: tosca.relationships.network.BindsTo + eca_trx3_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 2 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx3 + relationship: tosca.relationships.network.BindsTo + eca_trx3_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 2 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx3 + relationship: tosca.relationships.network.BindsTo + mmsc1_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: MMSC_volume_type + size: '(get_input : mmsc_cinder_volume_size) * 1024' + nems_imap_net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + network_name: + get_input: nems_imap_name + subnets: + nems_imap_network_ip_subnet: + name: + get_input: nems_imap_name + cidr: + get_input: nems_imap_cidr + allocation_pools: + - start: + get_input: nems_imap_start + end: + get_input: nems_imap_end + server_cmaui1: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + metadata: + vnf_id: + get_input: vnf_id + user_data_format: RAW + name: + get_input: + - cmaui_names + - 1 + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: cmaui1_volume + relationship: cmaui1_volume_attachment + lb2_dmz_protected_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - lb_dmz_protected_ips + - 1 + allowed_address_pairs: + - ip_address: + get_input: + - mmsc_dmz_protected_virtual_server_ips + - 0 + - ip_address: + get_input: + - mmsc_dmz_protected_virtual_server_ips + - 1 + - ip_address: + get_input: + - mmsc_dmz_protected_virtual_server_ips + - 2 + - ip_address: + get_input: + - mmsc_dmz_protected_snat_ips + - 0 + - ip_address: + get_input: + - mmsc_dmz_protected_snat_ips + - 1 + - ip_address: + get_input: + - mmsc_dmz_protected_snat_ips + - 2 + - ip_address: + get_input: + - mmsc_dmz_protected_snat_ips + - 3 + network: + get_input: dmz_protected_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: lb2_instance + relationship: tosca.relationships.network.BindsTo + lb1_eca_traffic_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: eca_traffic_net_local_ip1 + allowed_address_pairs: + - ip_address: + get_input: eca_traffic_net_floating_ip + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: lb1_instance + relationship: tosca.relationships.network.BindsTo + lb1_dmz_protected_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - lb_dmz_protected_ips + - 0 + allowed_address_pairs: + - ip_address: + get_input: + - mmsc_dmz_protected_virtual_server_ips + - 0 + - ip_address: + get_input: + - mmsc_dmz_protected_virtual_server_ips + - 1 + - ip_address: + get_input: + - mmsc_dmz_protected_virtual_server_ips + - 2 + - ip_address: + get_input: + - mmsc_dmz_protected_snat_ips + - 0 + - ip_address: + get_input: + - mmsc_dmz_protected_snat_ips + - 1 + - ip_address: + get_input: + - mmsc_dmz_protected_snat_ips + - 2 + - ip_address: + get_input: + - mmsc_dmz_protected_snat_ips + - 3 + network: + get_input: dmz_protected_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: lb1_instance + relationship: tosca.relationships.network.BindsTo + lb1_mms_traffic_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: mms_traffic_net_local_ip1 + allowed_address_pairs: + - ip_address: + get_input: mms_traffic_net_floating_ip + network: mms_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: mms_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: lb1_instance + relationship: tosca.relationships.network.BindsTo + eca_mgmt_net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + network_name: + get_input: eca_mgmt_name + subnets: + eca_mgmt_network_ip_subnet: + name: + get_input: eca_mgmt_name + cidr: + get_input: eca_mgmt_cidr + allocation_pools: + - start: + get_input: eca_mgmt_start + end: + get_input: eca_mgmt_end + eca_trx1_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 0 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx1 + relationship: tosca.relationships.network.BindsTo + nems2_fe_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: NEMS_FE_volume_type + size: '(get_input : nems_volume_size) * 1024' + server_nems_be1: + type: org.openecomp.resource.vfc.nodes.heat.nems_be + properties: + flavor: + get_input: nems_be_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: nems_be_image + metadata: + vnf_id: + get_input: vnf_id + user_data_format: RAW + name: + get_input: nems_be_names + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: nems_be_volume + relationship: nems_volume_attachment + server_nems_fe1: + type: org.openecomp.resource.vfc.nodes.heat.nems_fe + properties: + flavor: + get_input: nems_fe_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: nems_fe_image + metadata: + vnf_id: + get_input: vnf_id + user_data_format: RAW + name: + get_input: + - nems_fe_names + - 0 + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: nems1_fe_volume + relationship: nems1_fe_volume_attachment + server_nems_fe2: + type: org.openecomp.resource.vfc.nodes.heat.nems_fe + properties: + flavor: + get_input: nems_fe_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: nems_fe_image + metadata: + vnf_id: + get_input: vnf_id + user_data_format: RAW + name: + get_input: + - nems_fe_names + - 1 + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: nems2_fe_volume + relationship: nems2_fe_volume_attachment + lb2_cor_direct_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - lb_cor_direct_ips + - 1 + allowed_address_pairs: + - ip_address: + get_input: + - mmsc_core_virtual_server_ips + - 0 + - ip_address: + get_input: + - mmsc_core_virtual_server_ips + - 1 + - ip_address: + get_input: + - mmsc_core_snat_ips + - 0 + - ip_address: + get_input: + - mmsc_core_snat_ips + - 1 + - ip_address: + get_input: + - mmsc_core_snat_ips + - 2 + - ip_address: + get_input: + - mmsc_core_snat_ips + - 3 + - ip_address: + get_input: + - mmsc_core_snat_ips + - 4 + network: + get_input: cor_direct_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: lb2_instance + relationship: tosca.relationships.network.BindsTo + eca_trx20_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 19 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx20 + relationship: tosca.relationships.network.BindsTo + eca_trx20_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 19 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx20 + relationship: tosca.relationships.network.BindsTo + eca_trx20_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 19 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx20 + relationship: tosca.relationships.network.BindsTo + eca_trx8_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 7 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx8 + relationship: tosca.relationships.network.BindsTo + eca_trx6_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 5 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx6 + relationship: tosca.relationships.network.BindsTo + lb2_nems_user_web_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: nems_user_web_net_local_ip2 + allowed_address_pairs: + - ip_address: + get_input: nems_user_web_net_floating_ip + network: nems_user_web_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: nems_user_web_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: lb2_instance + relationship: tosca.relationships.network.BindsTo + lb2_instance: + type: org.openecomp.resource.vfc.nodes.heat.lb + properties: + flavor: + get_input: lb_flavor_name + availability_zone: + get_input: availability_zone_0 + image: + get_input: lb_image_name + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - lb_names + - 1 + eca_trx6_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 5 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx6 + relationship: tosca.relationships.network.BindsTo + eca_trx8_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 7 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx8 + relationship: tosca.relationships.network.BindsTo + lb1_nems_user_web_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: nems_user_web_net_local_ip1 + allowed_address_pairs: + - ip_address: + get_input: nems_user_web_net_floating_ip + network: nems_user_web_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: nems_user_web_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: lb1_instance + relationship: tosca.relationships.network.BindsTo + eca_trx6_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 5 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx6 + relationship: tosca.relationships.network.BindsTo + eca_trx8_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 7 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx8 + relationship: tosca.relationships.network.BindsTo + ha_net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + network_name: + get_input: ha_net_name + subnets: + ha_net_ip_subnet: + name: + get_input: ha_net_name + cidr: + get_input: ha_net_cidr + allocation_pools: + - start: + get_input: ha_net_start + end: + get_input: ha_net_end + server_mmsc1: + type: org.openecomp.resource.vfc.nodes.heat.mmsc + properties: + flavor: + get_input: mmsc_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: mmsc_image + metadata: + vnf_id: + get_input: vnf_id + user_data_format: RAW + name: + get_input: + - mmsc_names + - 0 + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: mmsc1_volume + relationship: mmsc1_volume_attachment + nems_be1_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: nems_be_oam_ips + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_nems_be1 + relationship: tosca.relationships.network.BindsTo + eca_trx2_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 1 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx2 + relationship: tosca.relationships.network.BindsTo + server_mmsc2: + type: org.openecomp.resource.vfc.nodes.heat.mmsc + properties: + flavor: + get_input: mmsc_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: mmsc_image + metadata: + vnf_id: + get_input: vnf_id + user_data_format: RAW + name: + get_input: + - mmsc_names + - 1 + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: mmsc2_volume + relationship: mmsc2_volume_attachment + nems_be1_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: nems_be_nems_internal_net_ips + network: nems_internal_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: nems_internal_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_nems_be1 + relationship: tosca.relationships.network.BindsTo + eca_trx2_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 1 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx2 + relationship: tosca.relationships.network.BindsTo + eca_trx4_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 3 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx4 + relationship: tosca.relationships.network.BindsTo + server_mmsc3: + type: org.openecomp.resource.vfc.nodes.heat.mmsc + properties: + flavor: + get_input: mmsc_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: mmsc_image + metadata: + vnf_id: + get_input: vnf_id + user_data_format: RAW + name: + get_input: + - mmsc_names + - 2 + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: mmsc3_volume + relationship: mmsc3_volume_attachment + nems_be1_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: nems_be_nems_imap_net_ips + network: nems_imap_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: nems_imap_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_nems_be1 + relationship: tosca.relationships.network.BindsTo + eca_trx2_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 1 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx2 + relationship: tosca.relationships.network.BindsTo + eca_trx4_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 3 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx4 + relationship: tosca.relationships.network.BindsTo + server_eca_trx20: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 19 + eca_trx4_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 3 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx4 + relationship: tosca.relationships.network.BindsTo + nems_be_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: NEMS_BE_volume_type + size: '(get_input : nems_be_volume_size) * 1024' + server_mmsc4: + type: org.openecomp.resource.vfc.nodes.heat.mmsc + properties: + flavor: + get_input: mmsc_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: mmsc_image + metadata: + vnf_id: + get_input: vnf_id + user_data_format: RAW + name: + get_input: + - mmsc_names + - 3 + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: mmsc4_volume + relationship: mmsc4_volume_attachment + server_mmsc5: + type: org.openecomp.resource.vfc.nodes.heat.mmsc + properties: + flavor: + get_input: mmsc_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: mmsc_image + metadata: + vnf_id: + get_input: vnf_id + user_data_format: RAW + name: + get_input: + - mmsc_names + - 4 + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: mmsc5_volume + relationship: mmsc5_volume_attachment + eca_trx17_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 16 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx17 + relationship: tosca.relationships.network.BindsTo + eca_trx18_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 17 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx18 + relationship: tosca.relationships.network.BindsTo + lb1_cor_direct_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - lb_cor_direct_ips + - 0 + allowed_address_pairs: + - ip_address: + get_input: + - mmsc_core_virtual_server_ips + - 0 + - ip_address: + get_input: + - mmsc_core_virtual_server_ips + - 1 + - ip_address: + get_input: + - mmsc_core_snat_ips + - 0 + - ip_address: + get_input: + - mmsc_core_snat_ips + - 1 + - ip_address: + get_input: + - mmsc_core_snat_ips + - 2 + - ip_address: + get_input: + - mmsc_core_snat_ips + - 3 + - ip_address: + get_input: + - mmsc_core_snat_ips + - 4 + network: + get_input: cor_direct_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: lb1_instance + relationship: tosca.relationships.network.BindsTo + mmsc1_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - mmsc_oam_ips + - 0 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_mmsc1 + relationship: tosca.relationships.network.BindsTo + eca_trx17_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 16 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx17 + relationship: tosca.relationships.network.BindsTo + eca_trx18_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 17 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx18 + relationship: tosca.relationships.network.BindsTo + mmsc1_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - mmsc_mms_traffic_net_ips + - 0 + network: mms_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: mms_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_mmsc1 + relationship: tosca.relationships.network.BindsTo + mmsc2_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - mmsc_mms_traffic_net_ips + - 1 + network: mms_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: mms_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_mmsc2 + relationship: tosca.relationships.network.BindsTo + eca_trx17_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 16 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx17 + relationship: tosca.relationships.network.BindsTo + eca_trx18_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 17 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx18 + relationship: tosca.relationships.network.BindsTo + mms_traffic_net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + network_name: + get_input: mms_traffic_net_name + subnets: + mms_traffic_ip_subnet: + name: + get_input: mms_traffic_net_name + cidr: + get_input: mms_traffic_net_cidr + allocation_pools: + - start: + get_input: mms_traffic_start + end: + get_input: mms_traffic_end + cmaui_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: oam_net_name + eca_trx10_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 9 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx10 + relationship: tosca.relationships.network.BindsTo + server_eca_trx13: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 12 + lb1_instance: + type: org.openecomp.resource.vfc.nodes.heat.lb + properties: + flavor: + get_input: lb_flavor_name + availability_zone: + get_input: availability_zone_0 + image: + get_input: lb_image_name + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - lb_names + - 0 + eca_trx10_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 9 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx10 + relationship: tosca.relationships.network.BindsTo + server_eca_trx14: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 13 + server_eca_trx15: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 14 + nems1_fe_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: NEMS_FE_volume_type + size: '(get_input : nems_volume_size) * 1024' + eca_trx10_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 9 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx10 + relationship: tosca.relationships.network.BindsTo + server_eca_trx16: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 15 + server_eca_trx10: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 9 + server_eca_trx11: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 10 + server_eca_trx12: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 11 + eca_trx14_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 13 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx14 + relationship: tosca.relationships.network.BindsTo + eca_trx13_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 12 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx13 + relationship: tosca.relationships.network.BindsTo + eca_trx14_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 13 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx14 + relationship: tosca.relationships.network.BindsTo + mmsc5_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - mmsc_mms_traffic_net_ips + - 4 + network: mms_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: mms_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_mmsc5 + relationship: tosca.relationships.network.BindsTo + eca_trx13_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 12 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx13 + relationship: tosca.relationships.network.BindsTo + mmsc5_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - mmsc_oam_ips + - 4 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_mmsc5 + relationship: tosca.relationships.network.BindsTo + eca_trx13_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 12 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx13 + relationship: tosca.relationships.network.BindsTo + eca_trx14_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 13 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx14 + relationship: tosca.relationships.network.BindsTo + mmsc2_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - mmsc_oam_ips + - 1 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_mmsc2 + relationship: tosca.relationships.network.BindsTo + server_eca_trx17: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 16 + server_eca_trx18: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 17 + server_eca_trx19: + type: org.openecomp.resource.vfc.nodes.heat.eca_trx + properties: + flavor: + get_input: eca_trx_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: eca_trx_image + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_trx_names + - 18 + eca_trx9_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 8 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx9 + relationship: tosca.relationships.network.BindsTo + eca_trx9_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 8 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx9 + relationship: tosca.relationships.network.BindsTo + eca_trx9_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 8 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx9 + relationship: tosca.relationships.network.BindsTo + lb2_nems_traffic_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: nems_traffic_net_local_ip2 + allowed_address_pairs: + - ip_address: + get_input: nems_traffic_net_floating_ip + network: nems_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: nems_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: lb2_instance + relationship: tosca.relationships.network.BindsTo + eca_trx5_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_eca_traffic_net_ips + - 4 + network: eca_traffic_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: eca_traffic_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx5 + relationship: tosca.relationships.network.BindsTo + eca_traffic_net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + network_name: + get_input: eca_traffic_name + subnets: + eca_traffic_ip_subnet: + name: + get_input: eca_traffic_name + cidr: + get_input: eca_traffic_cidr + allocation_pools: + - start: + get_input: eca_traffic_start + end: + get_input: eca_traffic_end + eca_trx1_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 0 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx1 + relationship: tosca.relationships.network.BindsTo + eca_trx5_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_mgmt_ips + - 4 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx5 + relationship: tosca.relationships.network.BindsTo + eca_trx1_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 0 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx1 + relationship: tosca.relationships.network.BindsTo + eca_trx5_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_trx_oam_ips + - 4 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_eca_trx5 + relationship: tosca.relationships.network.BindsTo + mmsc3_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: MMSC_volume_type + size: '(get_input : mmsc_cinder_volume_size) * 1024' + relationship_templates: + nems1_fe_volume_attachment: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: nems1_fe_volume + instance_uuid: server_nems_fe1 + mmsc3_volume_attachment: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: mmsc3_volume + instance_uuid: server_mmsc3 + mmsc1_volume_attachment: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: mmsc1_volume + instance_uuid: server_mmsc1 + cmaui1_volume_attachment: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: cmaui1_volume + instance_uuid: server_cmaui1 + mmsc4_volume_attachment: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: mmsc4_volume + instance_uuid: server_mmsc4 + nems_volume_attachment: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: nems_be_volume + instance_uuid: server_nems_be1 + cmaui_volume_attachment: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: cmaui_volume + instance_uuid: server_cmaui + nems2_fe_volume_attachment: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: nems2_fe_volume + instance_uuid: server_nems_fe2 + mmsc5_volume_attachment: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: mmsc5_volume + instance_uuid: server_mmsc5 + mmsc2_volume_attachment: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: mmsc2_volume + instance_uuid: server_mmsc2 + groups: + MMSC_Capacity_Line: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/MMSC_Capacity_Line.yml + description: | + HOT template that creates internal networks, load balancers and servers for vMMSC capacity Line 1. #11/23: updated the network definition to meet the juniper best practices way of defining the gateway, DHCP enable for internal networks (L457-L547) + members: + - server_eca_trx9 + - server_eca_trx8 + - server_eca_trx7 + - server_eca_trx6 + - server_eca_trx5 + - nems_internal_net + - server_eca_trx4 + - server_eca_trx3 + - server_eca_trx2 + - lb1_mgmt_port + - lb2_mms_traffic_port + - nems_fe1_port_1 + - nems_fe2_port_3 + - server_eca_trx1 + - nems_fe1_port_2 + - nems_fe2_port_2 + - nems_fe2_port_1 + - nems_fe1_port_0 + - nems_fe2_port_0 + - nems_fe1_port_3 + - nems_fe1_port_4 + - nems_fe2_port_4 + - mmsc4_volume + - lb2_eca_traffic_port + - lb2_ha_net_port + - nems_user_web_net + - lb1_ha_net_port + - mmsc2_volume + - nems_traffic_net + - eca_trx16_port_0 + - eca_trx19_port_2 + - eca_trx16_port_1 + - eca_trx19_port_1 + - eca_trx15_port_0 + - eca_trx19_port_0 + - lb1_nems_traffic_port + - eca_trx11_port_1 + - eca_trx11_port_2 + - eca_trx12_port_2 + - eca_trx12_port_1 + - eca_trx11_port_0 + - eca_trx12_port_0 + - mmsc4_port_0 + - mmsc3_port_0 + - eca_trx15_port_2 + - mmsc3_port_1 + - mmsc4_port_1 + - eca_trx15_port_1 + - eca_trx16_port_2 + - lb2_mgmt_port + - mmsc5_volume + - eca_trx7_port_2 + - eca_trx7_port_0 + - eca_trx7_port_1 + - eca_trx3_port_1 + - eca_trx3_port_0 + - eca_trx3_port_2 + - mmsc1_volume + - nems_imap_net + - lb2_dmz_protected_port + - lb1_eca_traffic_port + - lb1_dmz_protected_port + - lb1_mms_traffic_port + - eca_trx1_port_2 + - nems2_fe_volume + - server_nems_be1 + - server_nems_fe1 + - server_nems_fe2 + - lb2_cor_direct_port + - eca_trx20_port_0 + - eca_trx20_port_2 + - eca_trx20_port_1 + - eca_trx8_port_0 + - eca_trx6_port_0 + - lb2_nems_user_web_port + - lb2_instance + - eca_trx6_port_2 + - eca_trx8_port_2 + - lb1_nems_user_web_port + - eca_trx6_port_1 + - eca_trx8_port_1 + - ha_net + - server_mmsc1 + - nems_be1_port_0 + - eca_trx2_port_0 + - server_mmsc2 + - nems_be1_port_1 + - eca_trx2_port_1 + - eca_trx4_port_1 + - server_mmsc3 + - nems_be1_port_2 + - eca_trx2_port_2 + - eca_trx4_port_2 + - server_eca_trx20 + - eca_trx4_port_0 + - nems_be_volume + - server_mmsc4 + - server_mmsc5 + - eca_trx17_port_0 + - eca_trx18_port_2 + - lb1_cor_direct_port + - mmsc1_port_0 + - eca_trx17_port_2 + - eca_trx18_port_0 + - mmsc1_port_1 + - mmsc2_port_1 + - eca_trx17_port_1 + - eca_trx18_port_1 + - mms_traffic_net + - eca_trx10_port_1 + - server_eca_trx13 + - lb1_instance + - eca_trx10_port_0 + - server_eca_trx14 + - server_eca_trx15 + - nems1_fe_volume + - eca_trx10_port_2 + - server_eca_trx16 + - server_eca_trx10 + - server_eca_trx11 + - server_eca_trx12 + - eca_trx14_port_1 + - eca_trx13_port_0 + - eca_trx14_port_0 + - mmsc5_port_1 + - eca_trx13_port_1 + - mmsc5_port_0 + - eca_trx13_port_2 + - eca_trx14_port_2 + - mmsc2_port_0 + - server_eca_trx17 + - server_eca_trx18 + - server_eca_trx19 + - eca_trx9_port_0 + - eca_trx9_port_1 + - eca_trx9_port_2 + - lb2_nems_traffic_port + - eca_trx5_port_2 + - eca_traffic_net + - eca_trx1_port_1 + - eca_trx5_port_1 + - eca_trx1_port_0 + - eca_trx5_port_0 + - mmsc3_volume + SG_ECA_MGMT: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/SG_ECA_MGMT.yaml + description: | + HOT template that creates Security Group and ECA network + members: + - mms_security_group + - eca_mgmt_net + cmaui: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/cmaui.yml + description: cmaui server template for vMMSC + members: + - server_cmaui1 + - server_cmaui + - cmaui1_port_0 + - cmaui_volume + - cmaui1_volume + - cmaui_port_0 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/expectedOutput/eca_oamServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/expectedOutput/eca_oamServiceTemplate.yaml new file mode 100644 index 0000000000..90d4df7dab --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/expectedOutput/eca_oamServiceTemplate.yaml @@ -0,0 +1,569 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: eca_oam +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.eca: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.arb: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + metadata: + label: metadata + hidden: false + immutable: false + type: string + description: cmaui metadata + oam_flavor: + label: flavor name + hidden: false + immutable: false + type: string + description: OAM flavor name + default: lc.xlarge4 + eca_eca_mgmt_ips: + label: eca_mgmt network ips for eca VM + hidden: false + immutable: false + type: list + description: internal eca_mgmt network ips for eca VM + default: + - 172.25.137.242 + - 172.25.137.243 + entry_schema: + type: string + eca_mgmt_net_name: + label: internal network name + hidden: false + immutable: false + type: string + description: the name of the internal network + default: int_mms_eca_mgmt_net_1 + ECA_OAM_volume_type: + label: eca oam vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + default: Platinum + arb_eca_mgmt_ips: + label: eca_mgmt network ips + hidden: false + immutable: false + type: list + description: internal eca_mgmt network ips for arb VM + default: + - 172.25.137.244 + entry_schema: + type: string + networks: + label: network name + hidden: false + immutable: false + type: string + description: cmaui network name + cmaui_name: + label: cmaui name + hidden: false + immutable: false + type: string + description: cmaui name + arb_volume_size: + label: volume size + hidden: false + immutable: false + type: float + description: the size of the ARB volume + default: 40 + vnf_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-ECA_id + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + default: nova + oam_image_name: + label: image name + hidden: false + immutable: false + type: string + description: the OAM image name + default: ECABASE + oam_volume_size: + label: volume size + hidden: false + immutable: false + type: float + description: the size of the OAM volume + default: 1800 + swift_eca_url: + label: Swift URL + hidden: false + immutable: false + type: string + description: Base URL for eca swift object store + default: http://object-store.rdm2.cci.com:8080/v1/AUTH_1bbab536a19b4756926e7d0ec1eb543c/eca + oam_net_name: + label: oam network name + hidden: false + immutable: false + type: string + description: the name of the oam network + default: oam_protected_net_0 + ARB_volume_type: + label: arb vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + default: Platinum + eca_names: + label: oam servers names + hidden: false + immutable: false + type: list + description: the names of the OAM1,OAM2 VM instances + default: + - ZRDM1MMSC02OAM001 + - ZRDM1MMSC02OAM002 + entry_schema: + type: string + arbiter_flavor: + label: flavor name + hidden: false + immutable: false + type: string + description: arbiter flavor name + default: m1.large2 + eca_oam_ips: + label: oam network ips + hidden: false + immutable: false + type: list + description: the ips of oam networks for eca VM + default: + - 107.250.172.44 + - 107.250.172.45 + entry_schema: + type: string + security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + default: mmsc_security_group_1 + user_data: + label: user data + hidden: false + immutable: false + type: string + description: cmaui user data + cmaui_image: + label: cmaui image + hidden: false + immutable: false + type: string + description: cmaui image + arb_names: + label: arbiter server names + hidden: false + immutable: false + type: list + description: the names of the arbiter VM instances + default: + - ZRDM1MMSC02ARB001 + entry_schema: + type: string + cmaui_flavor: + label: flavor name + hidden: false + immutable: false + type: string + description: cmaui flavor name + user_data_format: + label: user data + hidden: false + immutable: false + type: string + description: cmaui user data + eca_oam_gateway: + label: oam1 oam gateway + hidden: false + immutable: false + type: string + description: the ip of oam gateway + default: 107.250.172.1 + arb_oam_ips: + label: oam network ips for arb VM + hidden: false + immutable: false + type: list + description: oam network ips for eca VM + default: + - 107.250.172.46 + entry_schema: + type: string + node_templates: + arb_mgmt_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - arb_oam_ips + - 0 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: arb_instance + relationship: tosca.relationships.network.BindsTo + oam2_mgmt_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_oam_ips + - 1 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: oam2_instance + relationship: tosca.relationships.network.BindsTo + arb_instance: + type: org.openecomp.resource.vfc.nodes.heat.arb + properties: + flavor: + get_input: arbiter_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: oam_image_name + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - arb_names + - 0 + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: arb_volume + relationship: arb_volume_attachment + arb_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: ARB_volume_type + size: '(get_input : arb_volume_size) * 1024' + oam1_instance: + type: org.openecomp.resource.vfc.nodes.heat.eca + properties: + flavor: + get_input: oam_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: oam_image_name + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_names + - 0 + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: oam1_volume + relationship: oam1_volume_attachment + oam2_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: ECA_OAM_volume_type + size: '(get_input : oam_volume_size) * 1024' + oam1_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: ECA_OAM_volume_type + size: '(get_input : oam_volume_size) * 1024' + oam1_int_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_eca_mgmt_ips + - 0 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: oam1_instance + relationship: tosca.relationships.network.BindsTo + oam1_mgmt_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_oam_ips + - 0 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: oam1_instance + relationship: tosca.relationships.network.BindsTo + arb_int_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - arb_eca_mgmt_ips + - 0 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: arb_instance + relationship: tosca.relationships.network.BindsTo + oam2_int_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - eca_eca_mgmt_ips + - 1 + network: + get_input: eca_mgmt_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: oam2_instance + relationship: tosca.relationships.network.BindsTo + oam2_instance: + type: org.openecomp.resource.vfc.nodes.heat.eca + properties: + flavor: + get_input: oam_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: oam_image_name + metadata: + vnf_id: + get_input: vnf_id + name: + get_input: + - eca_names + - 1 + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: oam2_volume + relationship: oam2_volume_attachment + relationship_templates: + oam2_volume_attachment: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: oam2_volume + instance_uuid: oam2_instance + oam1_volume_attachment: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: oam1_volume + instance_uuid: oam1_instance + arb_volume_attachment: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: arb_volume + instance_uuid: arb_instance + groups: + eca_oam: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/eca_oam.yaml + description: This stack creates two ECA OAM VM and one ARB VM + members: + - arb_mgmt_port + - oam2_mgmt_port + - arb_instance + - arb_volume + - oam1_instance + - oam2_volume + - oam1_volume + - oam1_int_port + - oam1_mgmt_port + - arb_int_port + - oam2_int_port + - oam2_instance + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.eca_oam + capabilities: + attachment_oam2_volume: + - oam2_volume + - attachment + binding_oam2_instance: + - oam2_instance + - binding + attachment_oam2_int_port: + - oam2_int_port + - attachment + attachment_oam1_volume: + - oam1_volume + - attachment + os_oam1_instance: + - oam1_instance + - os + scalable_oam2_instance: + - oam2_instance + - scalable + scalable_arb_instance: + - arb_instance + - scalable + endpoint_oam1_instance: + - oam1_instance + - endpoint + binding_arb_instance: + - arb_instance + - binding + host_arb_instance: + - arb_instance + - host + endpoint_arb_instance: + - arb_instance + - endpoint + attachment_oam1_int_port: + - oam1_int_port + - attachment + attachment_arb_volume: + - arb_volume + - attachment + host_oam1_instance: + - oam1_instance + - host + os_oam2_instance: + - oam2_instance + - os + endpoint_oam2_instance: + - oam2_instance + - endpoint + scalable_oam1_instance: + - oam1_instance + - scalable + host_oam2_instance: + - oam2_instance + - host + os_arb_instance: + - arb_instance + - os + attachment_oam1_mgmt_port: + - oam1_mgmt_port + - attachment + attachment_arb_int_port: + - arb_int_port + - attachment + attachment_arb_mgmt_port: + - arb_mgmt_port + - attachment + attachment_oam2_mgmt_port: + - oam2_mgmt_port + - attachment + binding_oam1_instance: + - oam1_instance + - binding + requirements: + link_oam2_mgmt_port: + - oam2_mgmt_port + - link + link_oam1_int_port: + - oam1_int_port + - link + link_oam1_mgmt_port: + - oam1_mgmt_port + - link + local_storage_arb_instance: + - arb_instance + - local_storage + link_arb_mgmt_port: + - arb_mgmt_port + - link + local_storage_oam2_instance: + - oam2_instance + - local_storage + link_arb_int_port: + - arb_int_port + - link + link_oam2_int_port: + - oam2_int_port + - link + local_storage_oam1_instance: + - oam1_instance + - local_storage \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/MANIFEST.json new file mode 100644 index 0000000000..167ae4e9d8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/MANIFEST.json @@ -0,0 +1,37 @@ +{ + "name": "multiple_not_nested", + "description": "multiple heat files in zip, no nesting", + "version": "2013-05-23", + "data": [{ + "file": "cmaui.yml", + "type": "HEAT", + "data": [{ + "file": "cmaui.env", + "type": "HEAT_ENV" + }] + }, + { + "file": "eca_oam.yaml", + "type": "HEAT", + "data": [{ + "file": "eca_oam.env", + "type": "HEAT_ENV" + }] + }, + { + "file": "MMSC_Capacity_Line.yml", + "type": "HEAT", + "data": [{ + "file": "MMSC_Capacity_Line_1.env", + "type": "HEAT_ENV" + }] + }, + { + "file": "SG_ECA_MGMT.yaml", + "type": "HEAT", + "data": [{ + "file": "sg_eca_mgmt.env", + "type": "HEAT_ENV" + }] + }] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/MMSC_Capacity_Line.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/MMSC_Capacity_Line.yml new file mode 100644 index 0000000000..9e36eb9cd4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/MMSC_Capacity_Line.yml @@ -0,0 +1,3219 @@ +heat_template_version: 2013-05-23 + +description: > + HOT template that creates internal networks, load balancers and servers for vMMSC capacity Line 1. + #11/23: updated the network definition to meet the juniper best practices way of defining the gateway, DHCP enable for internal networks (L457-L547) + +parameters: + vnf_id: + type: string + description: Unique ID for this VNF instance + default: This_is_the_MMSC_id + oam_net_name: + type: string + label: UID of OAM network + description: UID of OAM network + oam_network_netmask: + type: string + label: oam network netmask + description: oam network gateway + oam_network_gateway: + type: string + label: oam network gateway + description: oam network gateway + oam_network_route_1: + type: string + label: oam network route 1 + description: oam network route 1 + oam_network_route_2: + type: string + label: oam network route 2 + description: oam network route 2 + external_dns: + type: string + label: dns server + description: dns server for MMSC + external_ntp: + type: string + label: ntp server + description: ntp server for MMSC + lb_oam_ips: + type: comma_delimited_list + label: management network ips for mmsc lb + description: the ips of the management network for mmsc lb + dmz_protected_net_name: + type: string + label: UID of dmz_protected network + description: UID of dmz_protected network + lb_dmz_protected_ips: + type: comma_delimited_list + label: dmz protected network local ips for lb VM + description: local ips of the dmz protected network for lb VM + cor_direct_net_name: + type: string + label: cor direct net UID + description: cor direct net + lb_cor_direct_ips: + type: comma_delimited_list + label: cor direct network local ips for lb VM + description: local ips of cor direct network for lb VM + mms_traffic_net_name: + type: string + label: Name of MMS traffic network + description: Name of MMS traffic network + mms_traffic_net_cidr: + type: string + label: MMS traffic network address (CIDR notation) + description: MMS traffic network address (CIDR notation) + mms_traffic_netmask: + type: string + label: MMS traffic network subnet mask + description: MMS traffic network subnet mask + mms_traffic_net_gateway: + type: string + label: MMS traffic network gateway address + description: MMS traffic network gateway address + mms_traffic_start: + type: string + label: mmsc traffic start IP + description: mmsc traffic start IP + mms_traffic_end: + type: string + label: mmsc traffic end IP + description: mmsc traffic end IP + mms_traffic_net_local_ip1: + type: string + label: mmsc traffic network local ip1 + description: the local ip1 of the mmsc traffic network + mms_traffic_net_local_ip2: + type: string + label: mmsc traffic network local ip2 + description: the local ip2 of the mmsc traffic network + mms_traffic_net_floating_ip: + type: string + label: mmsc traffic floating ip + description: mmsc traffic floating ip + nems_internal_name: + type: string + label: nems internal network name + description: nems internal network name + nems_internal_start: + type: string + label: nems internal start + description: nems internal start + nems_internal_end: + type: string + label: nems internal end + description: nems internal end + nems_internal_cidr: + type: string + label: nems ineternal cidr + description: nems internal cidr + nems_internal_netmask: + type: string + label: NEMS internal network subnet mask + description: NEMS internal network subnet mask + nems_internal_gateway: + type: string + label: nems internal gw + description: nems internal gw + nems_traffic_name: + type: string + label: nems traffic name + description: nems traffic name + nems_traffic_start: + type: string + label: nems traffic start + description: nems traffic start + nems_traffic_end: + type: string + label: nems traffic end + description: nems traffic end + nems_traffic_cidr: + type: string + label: nems traffic cidr + description: nems traffic cidr + nems_traffic_netmask: + type: string + label: NEMS traffic network subnet mask + description: NEMS traffic network subnet mask + nems_traffic_gateway: + type: string + label: NEMS traffic network gateway + description: NEMS traffic network gateway + nems_traffic_net_local_ip1: + type: string + label: nems traffic network local ip1 + description: the local ip1 of the nems traffic network + nems_traffic_net_local_ip2: + type: string + label: nems traffic network local ip2 + description: the local ip2 of the nems traffic network + nems_traffic_net_floating_ip: + type: string + label: nems traffic floating ip + description: nems traffic floating ip + nems_user_web_name: + type: string + label: nems user web name + description: nems user web name + nems_user_web_start: + type: string + label: nems user web start + description: nems user web end + nems_user_web_end: + type: string + label: nems user web end + description: nems user web end + nems_user_web_cidr: + type: string + label: nems user web cidr + description: nems user web cidr + nems_user_web_netmask: + type: string + label: NEMS user web network subnet mask + description: NEMS user web network subnet mask + nems_user_web_gateway: + type: string + label: NEMS user web network gateway + description: NEMS user web network gateway + nems_user_web_net_local_ip1: + type: string + label: nems user web network local ip1 + description: the local ip1 of the nems user web network + nems_user_web_net_local_ip2: + type: string + label: nems user web network local ip2 + description: the local ip2 of the nems user web network + nems_user_web_net_floating_ip: + type: string + label: nems user web floating ip + description: nems user web floating ip + nems_imap_name: + type: string + label: nems imap name + description: nems imap name + nems_imap_netmask: + type: string + label: nems imap subnet mask + description: nems imap subnet mask + nems_imap_start: + type: string + label: nems imap start + description: nems imap start + nems_imap_end: + type: string + label: nems imap end + description: nems imap end + nems_imap_cidr: + type: string + label: nems imap cidr + description: nems imap cidr + nems_imap_gateway: + type: string + label: nems imap gateway + description: nems imap gateway + eca_traffic_name: + type: string + label: eca traffic name + description: eca traffic name + eca_traffic_start: + type: string + label: eca traffic start + description: eca traffic start + eca_traffic_end: + type: string + label: eca traffic end + description: eca traffic end + eca_traffic_cidr: + type: string + label: eca traffic cidr + description: eca traffic cidr + eca_traffic_netmask: + type: string + label: ECA traffic network subnet mask + description: ECA traffic network subnet mask + eca_traffic_net_gateway: + type: string + label: eca_traffic network gateway + description: eca_traffic network gateway + eca_traffic_net_local_ip1: + type: string + label: eca traffic network local ip1 + description: the local ip1 of the eca traffic network + eca_traffic_net_local_ip2: + type: string + label: eca traffic network local ip2 + description: the local ip2 of the eca traffic network + eca_traffic_net_floating_ip: + type: string + label: eca traffic floating ip + description: eca traffic floating ip + ha_net_name: + type: string + label: ha_failover network name + description: ha_failover network name + ha_net_start: + type: string + label: ha net start + description: ha net start + ha_net_end: + type: string + label: ha net end + description: ha net end + ha_net_cidr: + type: string + label: ha net cidr + description: ha net cidr + ha_net_local_ip1: + type: string + label: ha net network local ip1 + description: the local ip1 of the ha network + ha_net_local_ip2: + type: string + label: ha net network local ip2 + description: the local ip2 of the ha network + lb_names: + type: comma_delimited_list + label: MMSC load balancer instance names + description: MMSC load balancer instance names + lb_image_name: + type: string + label: MMSC load balancer image name + description: MMSC load balancer image name + lb_flavor_name: + type: string + label: Load balancer flavor name + description: the flavor name of MMSC load balancer instance + availability_zone_0: + type: string + label: MMSC availabilityzone name + description: MMSC availabilityzone name + security_group_name: + type: string + label: MMSC security group name + description: MMSC security group name + mmsc_image: + type: string + label: Image for MMSC server + description: Image for MMSC server + mmsc_flavor: + type: string + label: Flavor for MMSC server + description: Flavor for MMSC server + mmsc_cinder_volume_size: + type: number + label: MMSC Cinder volume size + description: the size of the MMSC Cinder volume + nems_fe_image: + type: string + label: Image for NEMS FE server + description: Image for NEMS FE server + nems_fe_flavor: + type: string + label: Flavor for NEMS FE server + description: Flavor for NEMS FE server + nems_be_image: + type: string + label: Image for NEMS BE server + description: Image for NEMS BE server + nems_be_flavor: + type: string + label: Flavor for NEMS BE server + description: Flavor for NEMS BE server + eca_trx_image: + type: string + label: Image for ECA TRX server + description: Image for ECA TRX server + eca_trx_flavor: + type: string + label: Flavor for ECA TRX server + description: Flavor for ECA TRX server + mmsc_oam_ips: + type: comma_delimited_list + label: MMSC oam_net IP addresses + description: MMSC oam_net IP addresses + mmsc_mms_traffic_net_ips: + type: comma_delimited_list + label: MMSC mms_traffic_net IP addresses + description: MMSC mms_traffic_net IP addresses + nems_fe_names: + type: comma_delimited_list + label: NEMS_FE server names + description: NEMS_FE server names + nems_fe_node_roles: + type: comma_delimited_list + label: nems fe node roles + description: nems fe node roles + nems_fe_oam_ips: + type: comma_delimited_list + label: OAM_net IP for NEMS_FE + description: OAM_net IP for NEMS_FE + nems_fe_nems_traffic_net_ips: + type: comma_delimited_list + label: nems_traffic_net IPs for NEMS_FE + description: nems_traffic_net IPs for NEMS_FE + nems_fe_nems_user_web_net_ips: + type: comma_delimited_list + label: nems_web_user_net IPs for NEMS_FE + description: nems_web_user_net IPs for NEMS_FE + nems_fe_nems_internal_net_ips: + type: comma_delimited_list + label: nems_internal_net IPs for NEMS_FE + description: nems_internal_net IPs for NEMS_FE + nems_fe_nems_imap_net_ips: + type: comma_delimited_list + label: nems_imap_net IPs for NEMS_FE + description: nems_imap_net IPs for NEMS_FE + nems_be_names: + type: string + label: NEMS_BE server names + description: NEMS_BE server names + nems_be_node_roles: + type: string + label: nems node roles + description: nems node roles + nems_be_oam_ips: + type: string + label: OAM net IPs for NEMS_BE + description: OAM net IPs for NEMS_BE + nems_be_nems_internal_net_ips: + type: string + label: nems internal net IPs for NEMS_BE + description: nems internal net IPs for NEMS_BE + nems_be_nems_imap_net_ips: + type: string + label: nems imap_net IPs for NEMS_BE + description: nems imap net IPs for NEMS_BE + eca_trx_oam_ips: + type: comma_delimited_list + label: OAM net IP for ECA_TRX + description: OAM net IP for ECA_TRX + eca_trx_mgmt_ips: + type: comma_delimited_list + label: eca mgmt net IP for ECA_TRX + description: eca mgmt net IP for ECA_TRX + timezone: + type: string + label: timezone + description: timezone + eca_trx_names: + type: comma_delimited_list + label: ECA_TRX server names + description: ECA_TRX server names + eca_trx_eca_traffic_net_ips: + type: comma_delimited_list + label: eca traffic net IPs for ECA_TRX + description: eca traffic net IPs for ECA_TRX + mmsc_names: + type: comma_delimited_list + label: MMSC server names + description: MMSC server names + nems_volume_size: + type: number + label: nems fe volume size + description: nems fe volume size + nems_be_volume_size: + type: number + label: nems be volume size + description: nems be volume size + MMSC_volume_type: + type: string + label: MMSC vm volume type + description: the name of the target volume backend + NEMS_FE_volume_type: + type: string + label: nems fe vm volume type + description: the name of the target volume backend + NEMS_BE_volume_type: + type: string + label: nems be vm volume type + description: the name of the target volume backend + mmsc_core_virtual_server_ips: + type: comma_delimited_list + label: mmsc core virtual server ips + description: mmsc core virtual server ips + mmsc_core_snat_ips: + type: comma_delimited_list + label: mmsc core snat ips + description: mmsc core snat ips + mmsc_dmz_protected_virtual_server_ips: + type: comma_delimited_list + label: mmsc dmz_protected virtual server ips + description: mmsc dmz_protected virtual server ips + mmsc_dmz_protected_snat_ips: + type: comma_delimited_list + label: mmsc dmz_protected snat ips + description: mmsc dmz_protected snat ips + eca_mgmt_net_name: + type: string + label: eca management network ID + description: Network ID for eca management + +resources: + mms_traffic_net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: mms_traffic_net_name } + + mms_traffic_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: mms_traffic_net_name} + network_id: { get_resource: mms_traffic_net } + cidr: { get_param: mms_traffic_net_cidr } + allocation_pools: [{"start": {get_param: mms_traffic_start}, "end": {get_param: mms_traffic_end}}] + + nems_internal_net: + type: OS::Contrail::VirtualNetwork + properties: + name: {get_param: nems_internal_name} + + nems_internal_network_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: nems_internal_name} + allocation_pools: [{"start": {get_param: nems_internal_start}, "end": {get_param: nems_internal_end}}] + cidr: {get_param: nems_internal_cidr} + network_id: {get_resource: nems_internal_net} + + nems_traffic_net: + type: OS::Contrail::VirtualNetwork + properties: + name: {get_param: nems_traffic_name} + + nems_traffic_network_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: nems_traffic_name} + allocation_pools: [{"start": {get_param: nems_traffic_start}, "end": {get_param: nems_traffic_end}}] + cidr: {get_param: nems_traffic_cidr} + network_id: {get_resource: nems_traffic_net} + + nems_user_web_net: + type: OS::Contrail::VirtualNetwork + properties: + name: {get_param: nems_user_web_name} + + nems_user_web_network_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: nems_user_web_name} + allocation_pools: [{"start": {get_param: nems_user_web_start}, "end": {get_param: nems_user_web_end}}] + cidr: {get_param: nems_user_web_cidr} + network_id: {get_resource: nems_user_web_net} + + nems_imap_net: + type: OS::Contrail::VirtualNetwork + properties: + name: {get_param: nems_imap_name} + + nems_imap_network_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: nems_imap_name} + allocation_pools: [{"start": {get_param: nems_imap_start}, "end": {get_param: nems_imap_end}}] + cidr: {get_param: nems_imap_cidr} + network_id: {get_resource: nems_imap_net} + + eca_traffic_net: + type: OS::Contrail::VirtualNetwork + properties: + name: {get_param: eca_traffic_name} + + eca_traffic_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: eca_traffic_name} + allocation_pools: [{"start": {get_param: eca_traffic_start}, "end": {get_param: eca_traffic_end}}] + cidr: {get_param: eca_traffic_cidr} + network_id: {get_resource: eca_traffic_net} + + ha_net: + type: OS::Contrail::VirtualNetwork + properties: + name: {get_param: ha_net_name} + + ha_net_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: ha_net_name} + allocation_pools: [{"start": {get_param: ha_net_start}, "end": {get_param: ha_net_end}}] + cidr: {get_param: ha_net_cidr} + network_id: {get_resource: ha_net} + + lb1_instance: + type: OS::Nova::Server + properties: + name: {get_param: [lb_names, 0]} + image: {get_param: lb_image_name} + flavor: {get_param: lb_flavor_name} + availability_zone: {get_param: availability_zone_0} + networks: + - port: {get_resource: lb1_mgmt_port} + - port: {get_resource: lb1_dmz_protected_port} + - port: {get_resource: lb1_cor_direct_port} + - port: {get_resource: lb1_mms_traffic_port} + - port: {get_resource: lb1_nems_traffic_port} + - port: {get_resource: lb1_nems_user_web_port} + - port: {get_resource: lb1_eca_traffic_port} + - port: {get_resource: lb1_ha_net_port} + metadata: + vnf_id: { get_param: vnf_id } + + lb1_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [lb_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb1_mms_traffic_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: mms_traffic_net} + fixed_ips: [{"ip_address": {get_param: mms_traffic_net_local_ip1}}] + allowed_address_pairs: [{"ip_address": {get_param: mms_traffic_net_floating_ip} }] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb1_dmz_protected_port: + type: OS::Neutron::Port + properties: + network: {get_param: dmz_protected_net_name} + fixed_ips: [{"ip_address": {get_param: [lb_dmz_protected_ips, 0]}}] + allowed_address_pairs: [{"ip_address": {get_param: [mmsc_dmz_protected_virtual_server_ips, 0]}}, {"ip_address": {get_param: [mmsc_dmz_protected_virtual_server_ips, 1]}}, {"ip_address": {get_param: [mmsc_dmz_protected_virtual_server_ips, 2]}}, {"ip_address": {get_param: [mmsc_dmz_protected_snat_ips, 0]}}, {"ip_address": {get_param: [mmsc_dmz_protected_snat_ips, 1]}}, {"ip_address": {get_param: [mmsc_dmz_protected_snat_ips, 2]}}, {"ip_address": {get_param: [mmsc_dmz_protected_snat_ips, 3]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb1_cor_direct_port: + type: OS::Neutron::Port + properties: + network: {get_param: cor_direct_net_name} + fixed_ips: [{"ip_address": {get_param: [lb_cor_direct_ips, 0]}}] + allowed_address_pairs: [{"ip_address": {get_param: [mmsc_core_virtual_server_ips, 0]}}, {"ip_address": {get_param: [mmsc_core_virtual_server_ips, 1]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 0]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 1]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 2]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 3]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 4]}} ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb1_nems_traffic_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: nems_traffic_net} + fixed_ips: [{"ip_address": {get_param: nems_traffic_net_local_ip1}}] + allowed_address_pairs: [{"ip_address": {get_param: nems_traffic_net_floating_ip} }] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb1_nems_user_web_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: nems_user_web_net} + fixed_ips: [{"ip_address": {get_param: nems_user_web_net_local_ip1}}] + allowed_address_pairs: [{"ip_address": {get_param: nems_user_web_net_floating_ip} }] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb1_ha_net_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: ha_net} + fixed_ips: [{"ip_address": {get_param: ha_net_local_ip1}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb1_eca_traffic_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: eca_traffic_net} + fixed_ips: [{"ip_address": {get_param: eca_traffic_net_local_ip1}}] + allowed_address_pairs: [{"ip_address": {get_param: eca_traffic_net_floating_ip} }] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb2_instance: + type: OS::Nova::Server + properties: + name: {get_param: [lb_names, 1]} + image: {get_param: lb_image_name} + flavor: {get_param: lb_flavor_name} + availability_zone: {get_param: availability_zone_0} + networks: + - port: {get_resource: lb2_mgmt_port} + - port: {get_resource: lb2_dmz_protected_port} + - port: {get_resource: lb2_cor_direct_port} + - port: {get_resource: lb2_mms_traffic_port} + - port: {get_resource: lb2_nems_traffic_port} + - port: {get_resource: lb2_nems_user_web_port} + - port: {get_resource: lb2_eca_traffic_port} + - port: {get_resource: lb2_ha_net_port} + metadata: + vnf_id: { get_param: vnf_id } + + lb2_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [lb_oam_ips, 1]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb2_mms_traffic_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: mms_traffic_net} + fixed_ips: [{"ip_address": {get_param: mms_traffic_net_local_ip2}}] + allowed_address_pairs: [{"ip_address": {get_param: mms_traffic_net_floating_ip}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb2_dmz_protected_port: + type: OS::Neutron::Port + properties: + network: {get_param: dmz_protected_net_name} + fixed_ips: [{"ip_address": {get_param: [lb_dmz_protected_ips, 1]}}] + allowed_address_pairs: [{"ip_address": {get_param: [mmsc_dmz_protected_virtual_server_ips, 0]}}, {"ip_address": {get_param: [mmsc_dmz_protected_virtual_server_ips, 1]}}, {"ip_address": {get_param: [mmsc_dmz_protected_virtual_server_ips, 2]}}, {"ip_address": {get_param: [mmsc_dmz_protected_snat_ips, 0]}}, {"ip_address": {get_param: [mmsc_dmz_protected_snat_ips, 1]}}, {"ip_address": {get_param: [mmsc_dmz_protected_snat_ips, 2]}}, {"ip_address": {get_param: [mmsc_dmz_protected_snat_ips, 3]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb2_cor_direct_port: + type: OS::Neutron::Port + properties: + network: {get_param: cor_direct_net_name} + fixed_ips: [{"ip_address": {get_param: [lb_cor_direct_ips, 1]}}] + allowed_address_pairs: [{"ip_address": {get_param: [mmsc_core_virtual_server_ips, 0]}}, {"ip_address": {get_param: [mmsc_core_virtual_server_ips, 1]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 0]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 1]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 2]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 3]}}, {"ip_address": {get_param: [mmsc_core_snat_ips, 4]}} ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb2_nems_traffic_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: nems_traffic_net} + fixed_ips: [{"ip_address": {get_param: nems_traffic_net_local_ip2}}] + allowed_address_pairs: [{"ip_address": {get_param: nems_traffic_net_floating_ip}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb2_nems_user_web_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: nems_user_web_net} + fixed_ips: [{"ip_address": {get_param: nems_user_web_net_local_ip2}}] + allowed_address_pairs: [{"ip_address": {get_param: nems_user_web_net_floating_ip}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb2_ha_net_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: ha_net} + fixed_ips: [{"ip_address": {get_param: ha_net_local_ip2}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + lb2_eca_traffic_port: + type: OS::Neutron::Port + properties: + network_id: {get_resource: eca_traffic_net} + fixed_ips: [{"ip_address": {get_param: eca_traffic_net_local_ip2}}] + allowed_address_pairs: [{"ip_address": {get_param: eca_traffic_net_floating_ip} }] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_mmsc1: + type: OS::Nova::Server + properties: + name: { get_param: [mmsc_names, 0]} + image: { get_param: mmsc_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: mmsc_flavor } + networks: + - port: { get_resource: mmsc1_port_0 } + - port: { get_resource: mmsc1_port_1 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + mmsc.mgmt.ip=${mmsc.mgmt.ip} + mmsc.mgmt.netmask=${mmsc.mgmt.netmask} + mmsc.mgmt.gateway=${mmsc.mgmt.gateway} + mmsc.traffic.ip=${mmsc.traffic.ip} + mmsc.traffic.netmask=${mmsc.traffic.netmask} + mmsc.traffic.gateway=${mmsc.traffic.gateway} + mmsc.mgmt.route.1=${mmsc.mgmt.route.1} + mmsc.mgmt.route.2=${mmsc.mgmt.route.2} + mmsc.external.dns=${mmsc.external.dns} + mmsc.external.ntp=${mmsc.external.ntp} + mmsc.hostname=${mmsc.hostname} + mmsc.timezone=${mmsc.timezone} + params: + ${mmsc.mgmt.ip}: {get_param: [mmsc_oam_ips, 0]} + ${mmsc.mgmt.netmask}: {get_param: oam_network_netmask} + ${mmsc.mgmt.gateway}: {get_param: oam_network_gateway} + ${mmsc.traffic.ip}: {get_param: [mmsc_mms_traffic_net_ips, 0]} + ${mmsc.traffic.netmask}: {get_param: mms_traffic_netmask} + ${mmsc.traffic.gateway}: {get_param: mms_traffic_net_gateway} + ${mmsc.mgmt.route.1}: {get_param: oam_network_route_1} + ${mmsc.mgmt.route.2}: {get_param: oam_network_route_2} + ${mmsc.external.dns}: {get_param: external_dns} + ${mmsc.external.ntp}: {get_param: external_ntp} + ${mmsc.hostname}: {get_param: [mmsc_names, 0]} + ${mmsc.timezone}: {get_param: timezone} + user_data_format: RAW + + mmsc1_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: mmsc_cinder_volume_size} + volume_type: {get_param: MMSC_volume_type} + + mmsc1_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: mmsc1_volume} + instance_uuid: {get_resource: server_mmsc1} + + mmsc1_port_0: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [ + "ip_address": {get_param: [mmsc_oam_ips, 0]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + mmsc1_port_1: + type: OS::Neutron::Port + properties: + network_id: {get_resource: mms_traffic_net} + fixed_ips: [ + "ip_address": {get_param: [mmsc_mms_traffic_net_ips, 0]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_mmsc2: + type: OS::Nova::Server + properties: + name: { get_param: [mmsc_names, 1]} + image: { get_param: mmsc_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: mmsc_flavor } + networks: + - port: { get_resource: mmsc2_port_0 } + - port: { get_resource: mmsc2_port_1 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + mmsc.mgmt.ip=${mmsc.mgmt.ip} + mmsc.mgmt.netmask=${mmsc.mgmt.netmask} + mmsc.mgmt.gateway=${mmsc.mgmt.gateway} + mmsc.traffic.ip=${mmsc.traffic.ip} + mmsc.traffic.netmask=${mmsc.traffic.netmask} + mmsc.traffic.gateway=${mmsc.traffic.gateway} + mmsc.mgmt.route.1=${mmsc.mgmt.route.1} + mmsc.mgmt.route.2=${mmsc.mgmt.route.2} + mmsc.external.dns=${mmsc.external.dns} + mmsc.external.ntp=${mmsc.external.ntp} + mmsc.hostname=${mmsc.hostname} + mmsc.timezone=${mmsc.timezone} + params: + ${mmsc.mgmt.ip}: {get_param: [mmsc_oam_ips, 1]} + ${mmsc.mgmt.netmask}: {get_param: oam_network_netmask} + ${mmsc.mgmt.gateway}: {get_param: oam_network_gateway} + ${mmsc.traffic.ip}: {get_param: [mmsc_mms_traffic_net_ips, 1]} + ${mmsc.traffic.netmask}: {get_param: mms_traffic_netmask} + ${mmsc.traffic.gateway}: {get_param: mms_traffic_net_gateway} + ${mmsc.mgmt.route.1}: {get_param: oam_network_route_1} + ${mmsc.mgmt.route.2}: {get_param: oam_network_route_2} + ${mmsc.external.dns}: {get_param: external_dns} + ${mmsc.external.ntp}: {get_param: external_ntp} + ${mmsc.hostname}: {get_param: [mmsc_names, 1]} + ${mmsc.timezone}: {get_param: timezone} + user_data_format: RAW + + mmsc2_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: mmsc_cinder_volume_size} + volume_type: {get_param: MMSC_volume_type} + + mmsc2_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: mmsc2_volume} + instance_uuid: {get_resource: server_mmsc2} + + mmsc2_port_0: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [ + "ip_address": {get_param: [mmsc_oam_ips, 1]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + mmsc2_port_1: + type: OS::Neutron::Port + properties: + network_id: {get_resource: mms_traffic_net} + fixed_ips: [ + "ip_address": {get_param: [mmsc_mms_traffic_net_ips, 1]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_mmsc3: + type: OS::Nova::Server + properties: + name: { get_param: [mmsc_names, 2]} + image: { get_param: mmsc_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: mmsc_flavor } + networks: + - port: { get_resource: mmsc3_port_0 } + - port: { get_resource: mmsc3_port_1 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + mmsc.mgmt.ip=${mmsc.mgmt.ip} + mmsc.mgmt.netmask=${mmsc.mgmt.netmask} + mmsc.mgmt.gateway=${mmsc.mgmt.gateway} + mmsc.traffic.ip=${mmsc.traffic.ip} + mmsc.traffic.netmask=${mmsc.traffic.netmask} + mmsc.traffic.gateway=${mmsc.traffic.gateway} + mmsc.mgmt.route.1=${mmsc.mgmt.route.1} + mmsc.mgmt.route.2=${mmsc.mgmt.route.2} + mmsc.external.dns=${mmsc.external.dns} + mmsc.external.ntp=${mmsc.external.ntp} + mmsc.hostname=${mmsc.hostname} + mmsc.timezone=${mmsc.timezone} + params: + ${mmsc.mgmt.ip}: {get_param: [mmsc_oam_ips, 2]} + ${mmsc.mgmt.netmask}: {get_param: oam_network_netmask} + ${mmsc.mgmt.gateway}: {get_param: oam_network_gateway} + ${mmsc.traffic.ip}: {get_param: [mmsc_mms_traffic_net_ips, 2]} + ${mmsc.traffic.netmask}: {get_param: mms_traffic_netmask} + ${mmsc.traffic.gateway}: {get_param: mms_traffic_net_gateway} + ${mmsc.mgmt.route.1}: {get_param: oam_network_route_1} + ${mmsc.mgmt.route.2}: {get_param: oam_network_route_2} + ${mmsc.external.dns}: {get_param: external_dns} + ${mmsc.external.ntp}: {get_param: external_ntp} + ${mmsc.hostname}: {get_param: [mmsc_names, 2]} + ${mmsc.timezone}: {get_param: timezone} + user_data_format: RAW + + mmsc3_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: mmsc_cinder_volume_size} + volume_type: {get_param: MMSC_volume_type} + + mmsc3_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: mmsc3_volume} + instance_uuid: {get_resource: server_mmsc3} + + mmsc3_port_0: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [ + "ip_address": {get_param: [mmsc_oam_ips, 2]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + mmsc3_port_1: + type: OS::Neutron::Port + properties: + network_id: {get_resource: mms_traffic_net} + fixed_ips: [ + "ip_address": {get_param: [mmsc_mms_traffic_net_ips, 2]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_mmsc4: + type: OS::Nova::Server + properties: + name: { get_param: [mmsc_names, 3]} + image: { get_param: mmsc_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: mmsc_flavor } + networks: + - port: { get_resource: mmsc4_port_0 } + - port: { get_resource: mmsc4_port_1 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + mmsc.mgmt.ip=${mmsc.mgmt.ip} + mmsc.mgmt.netmask=${mmsc.mgmt.netmask} + mmsc.mgmt.gateway=${mmsc.mgmt.gateway} + mmsc.traffic.ip=${mmsc.traffic.ip} + mmsc.traffic.netmask=${mmsc.traffic.netmask} + mmsc.traffic.gateway=${mmsc.traffic.gateway} + mmsc.mgmt.route.1=${mmsc.mgmt.route.1} + mmsc.mgmt.route.2=${mmsc.mgmt.route.2} + mmsc.external.dns=${mmsc.external.dns} + mmsc.external.ntp=${mmsc.external.ntp} + mmsc.hostname=${mmsc.hostname} + mmsc.timezone=${mmsc.timezone} + params: + ${mmsc.mgmt.ip}: {get_param: [mmsc_oam_ips, 3]} + ${mmsc.mgmt.netmask}: {get_param: oam_network_netmask} + ${mmsc.mgmt.gateway}: {get_param: oam_network_gateway} + ${mmsc.traffic.ip}: {get_param: [mmsc_mms_traffic_net_ips, 3]} + ${mmsc.traffic.netmask}: {get_param: mms_traffic_netmask} + ${mmsc.traffic.gateway}: {get_param: mms_traffic_net_gateway} + ${mmsc.mgmt.route.1}: {get_param: oam_network_route_1} + ${mmsc.mgmt.route.2}: {get_param: oam_network_route_2} + ${mmsc.external.dns}: {get_param: external_dns} + ${mmsc.external.ntp}: {get_param: external_ntp} + ${mmsc.hostname}: {get_param: [mmsc_names, 3]} + ${mmsc.timezone}: {get_param: timezone} + user_data_format: RAW + + mmsc4_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: mmsc_cinder_volume_size} + volume_type: {get_param: MMSC_volume_type} + + mmsc4_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: mmsc4_volume} + instance_uuid: {get_resource: server_mmsc4} + + mmsc4_port_0: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [ + "ip_address": {get_param: [mmsc_oam_ips, 3]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + mmsc4_port_1: + type: OS::Neutron::Port + properties: + network_id: {get_resource: mms_traffic_net} + fixed_ips: [ + "ip_address": {get_param: [mmsc_mms_traffic_net_ips, 3]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_mmsc5: + type: OS::Nova::Server + properties: + name: { get_param: [mmsc_names, 4]} + image: { get_param: mmsc_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: mmsc_flavor } + networks: + - port: { get_resource: mmsc5_port_0 } + - port: { get_resource: mmsc5_port_1 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + mmsc.mgmt.ip=${mmsc.mgmt.ip} + mmsc.mgmt.netmask=${mmsc.mgmt.netmask} + mmsc.mgmt.gateway=${mmsc.mgmt.gateway} + mmsc.traffic.ip=${mmsc.traffic.ip} + mmsc.traffic.netmask=${mmsc.traffic.netmask} + mmsc.traffic.gateway=${mmsc.traffic.gateway} + mmsc.mgmt.route.1=${mmsc.mgmt.route.1} + mmsc.mgmt.route.2=${mmsc.mgmt.route.2} + mmsc.external.dns=${mmsc.external.dns} + mmsc.external.ntp=${mmsc.external.ntp} + mmsc.hostname=${mmsc.hostname} + mmsc.timezone=${mmsc.timezone} + params: + ${mmsc.mgmt.ip}: {get_param: [mmsc_oam_ips, 4]} + ${mmsc.mgmt.netmask}: {get_param: oam_network_netmask} + ${mmsc.mgmt.gateway}: {get_param: oam_network_gateway} + ${mmsc.traffic.ip}: {get_param: [mmsc_mms_traffic_net_ips, 4]} + ${mmsc.traffic.netmask}: {get_param: mms_traffic_netmask} + ${mmsc.traffic.gateway}: {get_param: mms_traffic_net_gateway} + ${mmsc.mgmt.route.1}: {get_param: oam_network_route_1} + ${mmsc.mgmt.route.2}: {get_param: oam_network_route_2} + ${mmsc.external.dns}: {get_param: external_dns} + ${mmsc.external.ntp}: {get_param: external_ntp} + ${mmsc.hostname}: {get_param: [mmsc_names, 4]} + ${mmsc.timezone}: {get_param: timezone} + user_data_format: RAW + + mmsc5_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: mmsc_cinder_volume_size} + volume_type: {get_param: MMSC_volume_type} + + mmsc5_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: mmsc5_volume} + instance_uuid: {get_resource: server_mmsc5} + + mmsc5_port_0: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [ + "ip_address": {get_param: [mmsc_oam_ips, 4]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + mmsc5_port_1: + type: OS::Neutron::Port + properties: + network_id: {get_resource: mms_traffic_net} + fixed_ips: [ + "ip_address": {get_param: [mmsc_mms_traffic_net_ips, 4]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_nems_fe1: + type: OS::Nova::Server + properties: + name: { get_param: [nems_fe_names, 0] } + image: { get_param: nems_fe_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: nems_fe_flavor } + networks: + - port: { get_resource: nems_fe1_port_0 } + - port: { get_resource: nems_fe1_port_1 } + - port: { get_resource: nems_fe1_port_2 } + - port: { get_resource: nems_fe1_port_3 } + - port: { get_resource: nems_fe1_port_4 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + nems.mgmt.ip=${nems.mgmt.ip} + nems.mgmt.netmask=${nems.mgmt.netmask} + nems.mgmt.gateway=${nems.mgmt.gateway} + nems.traffic.ip=${nems.traffic.ip} + nems.traffic.netmask=${nems.traffic.netmask} + nems.traffic.gateway=${nems.traffic.gateway} + nems.fe0.internal.ip=${nems.fe0.internal.ip} + nems.fe1.internal.ip=${nems.fe1.internal.ip} + nems.internal.netmask=${nems.internal.netmask} + nems.userweb.ip=${nems.userweb.ip} + nems.userweb.netmask=${nems.userweb.netmask} + nems.userweb.gateway=${nems.userweb.gateway} + nems.imap.ip=${nems.imap.ip} + nems.imap.netmask=${nems.imap.netmask} + nems.be.internal.ip=${nems.be.internal.ip} + nems.be.imap.ip=${nems.be.imap.ip} + nems.mgmt.route.1=${nems.mgmt.route.1} + nems.mgmt.route.2=${nems.mgmt.route.2} + nems.external.dns=${nems.external.dns} + nems.external.ntp=${nems.external.ntp} + nems.node=${nems.node} + nems.be0.host.name=${nems.be0.host.name} + nems.fe0.host.name=${nems.fe0.host.name} + nems.fe1.host.name=${nems.fe1.host.name} + nems.timezone=${nems.timezone} + params: + ${nems.mgmt.ip}: {get_param: [nems_fe_oam_ips, 0]} + ${nems.mgmt.netmask}: {get_param: oam_network_netmask} + ${nems.mgmt.gateway}: {get_param: oam_network_gateway} + ${nems.traffic.ip}: {get_param: [nems_fe_nems_traffic_net_ips, 0]} + ${nems.traffic.netmask}: {get_param: nems_traffic_netmask} + ${nems.traffic.gateway}: {get_param: nems_traffic_gateway} + ${nems.fe0.internal.ip}: {get_param: [nems_fe_nems_internal_net_ips, 0]} + ${nems.fe1.internal.ip}: {get_param: [nems_fe_nems_internal_net_ips, 1]} + ${nems.internal.netmask}: {get_param: nems_internal_netmask} + ${nems.userweb.ip}: {get_param: [nems_fe_nems_user_web_net_ips, 0]} + ${nems.userweb.netmask}: {get_param: nems_user_web_netmask} + ${nems.userweb.gateway}: {get_param: nems_user_web_gateway} + ${nems.imap.ip}: {get_param: [nems_fe_nems_imap_net_ips, 0]} + ${nems.imap.netmask}: {get_param: nems_imap_netmask} + ${nems.be.internal.ip}: {get_param: nems_be_nems_internal_net_ips} + ${nems.be.imap.ip}: {get_param: nems_be_nems_imap_net_ips} + ${nems.mgmt.route.1}: {get_param: oam_network_route_1} + ${nems.mgmt.route.2}: {get_param: oam_network_route_2} + ${nems.external.dns}: {get_param: external_dns} + ${nems.external.ntp}: {get_param: external_ntp} + ${nems.node}: {get_param: [nems_fe_node_roles, 0]} + ${nems.fe0.host.name}: {get_param: [nems_fe_names, 0]} + ${nems.fe1.host.name}: {get_param: [nems_fe_names, 1]} + ${nems.be0.host.name}: {get_param: nems_be_names} + ${nems.timezone}: {get_param: timezone} + user_data_format: RAW + + nems1_fe_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: nems_volume_size} + volume_type: {get_param: NEMS_FE_volume_type} + + nems1_fe_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: nems1_fe_volume} + instance_uuid: {get_resource: server_nems_fe1} + + nems_fe1_port_0: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [ + "ip_address": { get_param: [nems_fe_oam_ips, 0] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_fe1_port_1: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [nems_fe_nems_traffic_net_ips, 0] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_fe1_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_user_web_net } + fixed_ips: [ + "ip_address": { get_param: [nems_fe_nems_user_web_net_ips, 0] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_fe1_port_3: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_internal_net } + fixed_ips: [ + "ip_address": { get_param: [nems_fe_nems_internal_net_ips, 0] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_fe1_port_4: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_imap_net } + fixed_ips: [ + "ip_address": { get_param: [nems_fe_nems_imap_net_ips, 0] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_nems_fe2: + type: OS::Nova::Server + properties: + name: { get_param: [nems_fe_names, 1] } + image: { get_param: nems_fe_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: nems_fe_flavor } + networks: + - port: { get_resource: nems_fe2_port_0 } + - port: { get_resource: nems_fe2_port_1 } + - port: { get_resource: nems_fe2_port_2 } + - port: { get_resource: nems_fe2_port_3 } + - port: { get_resource: nems_fe2_port_4 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + nems.mgmt.ip=${nems.mgmt.ip} + nems.mgmt.netmask=${nems.mgmt.netmask} + nems.mgmt.gateway=${nems.mgmt.gateway} + nems.traffic.ip=${nems.traffic.ip} + nems.traffic.netmask=${nems.traffic.netmask} + nems.traffic.gateway=${nems.traffic.gateway} + nems.fe0.internal.ip=${nems.fe0.internal.ip} + nems.fe1.internal.ip=${nems.fe1.internal.ip} + nems.internal.netmask=${nems.internal.netmask} + nems.userweb.ip=${nems.userweb.ip} + nems.userweb.netmask=${nems.userweb.netmask} + nems.userweb.gateway=${nems.userweb.gateway} + nems.imap.ip=${nems.imap.ip} + nems.imap.netmask=${nems.imap.netmask} + nems.be.internal.ip=${nems.be.internal.ip} + nems.be.imap.ip=${nems.be.imap.ip} + nems.mgmt.route.1=${nems.mgmt.route.1} + nems.mgmt.route.2=${nems.mgmt.route.2} + nems.external.dns=${nems.external.dns} + nems.external.ntp=${nems.external.ntp} + nems.node=${nems.node} + nems.be0.host.name=${nems.be0.host.name} + nems.fe0.host.name=${nems.fe0.host.name} + nems.fe1.host.name=${nems.fe1.host.name} + nems.timezone=${nems.timezone} + params: + ${nems.mgmt.ip}: {get_param: [nems_fe_oam_ips, 1]} + ${nems.mgmt.netmask}: {get_param: oam_network_netmask} + ${nems.mgmt.gateway}: {get_param: oam_network_gateway} + ${nems.traffic.ip}: {get_param: [nems_fe_nems_traffic_net_ips, 1]} + ${nems.traffic.netmask}: {get_param: nems_traffic_netmask} + ${nems.traffic.gateway}: {get_param: nems_traffic_gateway} + ${nems.fe0.internal.ip}: {get_param: [nems_fe_nems_internal_net_ips, 0]} + ${nems.fe1.internal.ip}: {get_param: [nems_fe_nems_internal_net_ips, 1]} + ${nems.internal.netmask}: {get_param: nems_internal_netmask} + ${nems.userweb.ip}: {get_param: [nems_fe_nems_user_web_net_ips, 1]} + ${nems.userweb.netmask}: {get_param: nems_user_web_netmask} + ${nems.userweb.gateway}: {get_param: nems_user_web_gateway} + ${nems.imap.ip}: {get_param: [nems_fe_nems_imap_net_ips, 1]} + ${nems.imap.netmask}: {get_param: nems_imap_netmask} + ${nems.be.internal.ip}: {get_param: nems_be_nems_internal_net_ips} + ${nems.be.imap.ip}: {get_param: nems_be_nems_imap_net_ips} + ${nems.mgmt.route.1}: {get_param: oam_network_route_1} + ${nems.mgmt.route.2}: {get_param: oam_network_route_2} + ${nems.external.dns}: {get_param: external_dns} + ${nems.external.ntp}: {get_param: external_ntp} + ${nems.node}: {get_param: [nems_fe_node_roles, 1]} + ${nems.fe0.host.name}: {get_param: [nems_fe_names, 0]} + ${nems.fe1.host.name}: {get_param: [nems_fe_names, 1]} + ${nems.be0.host.name}: {get_param: nems_be_names} + ${nems.timezone}: {get_param: timezone} + user_data_format: RAW + + nems2_fe_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: nems_volume_size} + volume_type: {get_param: NEMS_FE_volume_type} + + nems2_fe_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: nems2_fe_volume} + instance_uuid: {get_resource: server_nems_fe2} + + nems_fe2_port_0: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [ + "ip_address": {get_param: [nems_fe_oam_ips, 1]} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_fe2_port_1: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [nems_fe_nems_traffic_net_ips, 1] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_fe2_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_user_web_net } + fixed_ips: [ + "ip_address": { get_param: [nems_fe_nems_user_web_net_ips, 1] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_fe2_port_3: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_internal_net } + fixed_ips: [ + "ip_address": { get_param: [nems_fe_nems_internal_net_ips, 1] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + + nems_fe2_port_4: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_imap_net } + fixed_ips: [ + "ip_address": { get_param: [nems_fe_nems_imap_net_ips, 1] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_nems_be1: + type: OS::Nova::Server + properties: + name: { get_param: nems_be_names } + image: { get_param: nems_be_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: nems_be_flavor } + networks: + - port: { get_resource: nems_be1_port_0 } + - port: { get_resource: nems_be1_port_1 } + - port: { get_resource: nems_be1_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + nems.be.mgmt.ip=${nems.be.mgmt.ip} + nems.mgmt.netmask=${nems.mgmt.netmask} + nems.mgmt.gateway=${nems.mgmt.gateway} + nems.be.internal.ip=${nems.be.internal.ip} + nems.internal.netmask=${nems.internal.netmask} + nems.imap.netmask=${nems.imap.netmask} + nems.fe0.internal.ip=${nems.fe0.internal.ip} + nems.fe1.internal.ip=${nems.fe1.internal.ip} + nems.be.imap.ip=${nems.be.imap.ip} + nems.mgmt.route.1=${nems.mgmt.route.1} + nems.mgmt.route.2=${nems.mgmt.route.2} + nems.external.dns=${nems.external.dns} + nems.external.ntp=${nems.external.ntp} + nems.node=${nems.node} + nems.be0.host.name=${nems.be0.host.name} + nems.fe0.host.name=${nems.fe0.host.name} + nems.fe1.host.name=${nems.fe1.host.name} + nems.timezone=${nems.timezone} + params: + ${nems.be.mgmt.ip}: {get_param: nems_be_oam_ips} + ${nems.mgmt.netmask}: {get_param: oam_network_netmask} + ${nems.mgmt.gateway}: {get_param: oam_network_gateway} + ${nems.fe0.internal.ip}: {get_param: [nems_fe_nems_internal_net_ips, 0]} + ${nems.fe1.internal.ip}: {get_param: [nems_fe_nems_internal_net_ips, 1]} + ${nems.be.internal.ip}: {get_param: nems_be_nems_internal_net_ips} + ${nems.internal.netmask}: {get_param: nems_internal_netmask} + ${nems.imap.netmask}: {get_param: nems_imap_netmask} + ${nems.be.imap.ip}: {get_param: nems_be_nems_imap_net_ips} + ${nems.mgmt.route.1}: {get_param: oam_network_route_1} + ${nems.mgmt.route.2}: {get_param: oam_network_route_2} + ${nems.external.dns}: {get_param: external_dns} + ${nems.external.ntp}: {get_param: external_ntp} + ${nems.node}: {get_param: nems_be_node_roles} + ${nems.be0.host.name}: {get_param: nems_be_names} + ${nems.fe0.host.name}: {get_param: [nems_fe_names, 0]} + ${nems.fe1.host.name}: {get_param: [nems_fe_names, 1]} + ${nems.timezone}: {get_param: timezone} + user_data_format: RAW + + nems_be_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: nems_be_volume_size} + volume_type: {get_param: NEMS_BE_volume_type} + + nems_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: nems_be_volume} + instance_uuid: {get_resource: server_nems_be1} + + + nems_be1_port_0: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [ + "ip_address": { get_param: nems_be_oam_ips} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_be1_port_1: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_internal_net } + fixed_ips: [ + "ip_address": { get_param: nems_be_nems_internal_net_ips} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + nems_be1_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: nems_imap_net } + fixed_ips: [ + "ip_address": { get_param: nems_be_nems_imap_net_ips} + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx1: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 0]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx1_port_0 } + - port: { get_resource: eca_trx1_port_1 } + - port: { get_resource: eca_trx1_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 0]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 0]} + + eca_trx1_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 0] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx1_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 0] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx1_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 0] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + + server_eca_trx2: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 1]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx2_port_0 } + - port: { get_resource: eca_trx2_port_1 } + - port: { get_resource: eca_trx2_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 1]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 1]} + + eca_trx2_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 1] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx2_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 1] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx2_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 1] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx3: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 2]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx3_port_0 } + - port: { get_resource: eca_trx3_port_1 } + - port: { get_resource: eca_trx3_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 2]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 2]} + + eca_trx3_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 2] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx3_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 2] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx3_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 2] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx4: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 3]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx4_port_0 } + - port: { get_resource: eca_trx4_port_1 } + - port: { get_resource: eca_trx4_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 3]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 3]} + + eca_trx4_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 3] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx4_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 3] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx4_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 3] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx5: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 4]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx5_port_0 } + - port: { get_resource: eca_trx5_port_1 } + - port: { get_resource: eca_trx5_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 4]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 4]} + + eca_trx5_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 4] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx5_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 4] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx5_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 4] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx6: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 5]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx6_port_0 } + - port: { get_resource: eca_trx6_port_1 } + - port: { get_resource: eca_trx6_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 5]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 5]} + + eca_trx6_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 5] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx6_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 5] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx6_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 5] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx7: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 6]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx7_port_0 } + - port: { get_resource: eca_trx7_port_1 } + - port: { get_resource: eca_trx7_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 6]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 6]} + + eca_trx7_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 6] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx7_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 6] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx7_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 6] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx8: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 7]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx8_port_0 } + - port: { get_resource: eca_trx8_port_1 } + - port: { get_resource: eca_trx8_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 7]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 7]} + + eca_trx8_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 7] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx8_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 7] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx8_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 7] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx9: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 8]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx9_port_0 } + - port: { get_resource: eca_trx9_port_1 } + - port: { get_resource: eca_trx9_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 8]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 8]} + + eca_trx9_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 8] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx9_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 8] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx9_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 8] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx10: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 9]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx10_port_0 } + - port: { get_resource: eca_trx10_port_1 } + - port: { get_resource: eca_trx10_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 9]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 9]} + + eca_trx10_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 9] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx10_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 9] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx10_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 9] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx11: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 10]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx11_port_0 } + - port: { get_resource: eca_trx11_port_1 } + - port: { get_resource: eca_trx11_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 10]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 10]} + + eca_trx11_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 10] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx11_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 10] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx11_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 10] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + + server_eca_trx12: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 11]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx12_port_0 } + - port: { get_resource: eca_trx12_port_1 } + - port: { get_resource: eca_trx12_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 11]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 11]} + + eca_trx12_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 11] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx12_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 11] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx12_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 11] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx13: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 12]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx13_port_0 } + - port: { get_resource: eca_trx13_port_1 } + - port: { get_resource: eca_trx13_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 12]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 12]} + + eca_trx13_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 12] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx13_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 12] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx13_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 12] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx14: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 13]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx14_port_0 } + - port: { get_resource: eca_trx14_port_1 } + - port: { get_resource: eca_trx14_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 13]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 13]} + + eca_trx14_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 13] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx14_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 13] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx14_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 13] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx15: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 14]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx15_port_0 } + - port: { get_resource: eca_trx15_port_1 } + - port: { get_resource: eca_trx15_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 14]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 14]} + + eca_trx15_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 14] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx15_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 14] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx15_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 14] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx16: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 15]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx16_port_0 } + - port: { get_resource: eca_trx16_port_1 } + - port: { get_resource: eca_trx16_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 15]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 15]} + + eca_trx16_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 15] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx16_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 15] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx16_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 15] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + + server_eca_trx17: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 16]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx17_port_0 } + - port: { get_resource: eca_trx17_port_1 } + - port: { get_resource: eca_trx17_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 16]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 16]} + + eca_trx17_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 16] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx17_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 16] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx17_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 16] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx18: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 17]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx18_port_0 } + - port: { get_resource: eca_trx18_port_1 } + - port: { get_resource: eca_trx18_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 17]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 17]} + + eca_trx18_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 17] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx18_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 17] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx18_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 17] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx19: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 18]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx19_port_0 } + - port: { get_resource: eca_trx19_port_1 } + - port: { get_resource: eca_trx19_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 8]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 18]} + + eca_trx19_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 18] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx19_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 18] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx19_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 18] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_eca_trx20: + type: OS::Nova::Server + properties: + name: { get_param: [eca_trx_names, 19]} + image: { get_param: eca_trx_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: eca_trx_flavor } + networks: + - port: { get_resource: eca_trx20_port_0 } + - port: { get_resource: eca_trx20_port_1 } + - port: { get_resource: eca_trx20_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + touch /tmp/user_data.log + sed -i s/HOSTNAME.*/"HOSTNAME=trx_hostname"/g /etc/sysconfig/network + echo "172.26.8.6 puppet" > /etc/hosts + eth0_ip_address='trx_traf_ip_address' + eth0_gateway='172.26.5.3' + echo "$eth0_ip_address" >>/tmp/user_data.log + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + puppet agent -t > /root/puppet-agent-t.out + params: + trx_hostname: {get_param: [eca_trx_names, 19]} + trx_traf_ip_address: {get_param: [eca_trx_eca_traffic_net_ips, 19]} + + eca_trx20_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_oam_ips, 19] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx20_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: eca_mgmt_net_name } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_mgmt_ips, 19] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + eca_trx20_port_2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: eca_traffic_net } + fixed_ips: [ + "ip_address": { get_param: [eca_trx_eca_traffic_net_ips, 19] } + ] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/MMSC_Capacity_Line_1.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/MMSC_Capacity_Line_1.env new file mode 100644 index 0000000000..b346d67d97 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/MMSC_Capacity_Line_1.env @@ -0,0 +1,111 @@ +parameters: + oam_net_name: oam_protected_net_0 + oam_network_netmask: 255.255.254.0 + oam_network_gateway: 107.250.172.1 + oam_network_route_1: 155.165.201.250/32,107.250.172.1 + oam_network_route_2: 155.165.194.100/32,107.250.172.1 + external_dns: 155.165.194.100 + external_ntp: 155.165.201.250 + lb_oam_ips: 107.250.172.50,107.250.172.51 + dmz_protected_net_name: dmz_protected_net_0 + lb_dmz_protected_ips: 107.239.14.19,107.239.14.20 + cor_direct_net_name: cor_direct_net_0 + lb_cor_direct_ips: 172.31.10.19,172.31.10.20 + mms_traffic_net_name: int_mms_mms_traffic_net_2 + mms_traffic_net_cidr: 172.26.2.0/24 + mms_traffic_netmask: 255.255.255.0 + mms_traffic_net_gateway: 172.26.2.1 + mms_traffic_start: 172.26.2.3 + mms_traffic_end: 172.26.2.254 + mms_traffic_net_local_ip1: 172.26.2.3 + mms_traffic_net_local_ip2: 172.26.2.4 + mms_traffic_net_floating_ip: 172.26.2.5 + nems_internal_name: int_mms_nems_internal_net_2 + nems_internal_start: 172.26.6.3 + nems_internal_end: 172.26.6.254 + nems_internal_cidr: 172.26.6.0/24 + nems_internal_netmask: 255.255.255.0 + nems_internal_gateway: 172.26.6.1 + nems_traffic_name: int_mms_nems_traffic_net_2 + nems_traffic_start: 172.26.3.3 + nems_traffic_end: 172.26.3.254 + nems_traffic_cidr: 172.26.3.0/24 + nems_traffic_netmask: 255.255.255.0 + nems_traffic_gateway: 172.26.3.1 + nems_traffic_net_local_ip1: 172.26.3.3 + nems_traffic_net_local_ip2: 172.26.3.4 + nems_traffic_net_floating_ip: 172.26.3.5 + nems_user_web_name: int_mms_nems_web_net_2 + nems_user_web_start: 172.26.4.3 + nems_user_web_end: 172.26.4.254 + nems_user_web_cidr: 172.26.4.0/24 + nems_user_web_netmask: 255.255.255.0 + nems_user_web_gateway: 172.26.4.1 + nems_user_web_net_local_ip1: 172.26.4.3 + nems_user_web_net_local_ip2: 172.26.4.4 + nems_user_web_net_floating_ip: 172.26.4.5 + nems_imap_name: int_mms_nems_imap_net_2 + nems_imap_start: 172.26.7.3 + nems_imap_end: 172.26.7.254 + nems_imap_cidr: 172.26.7.0/24 + nems_imap_netmask: 255.255.255.0 + nems_imap_gateway: 172.26.7.1 + eca_traffic_name: int_mms_eca_traffic_net_2 + eca_traffic_cidr: 172.26.5.0/24 + eca_traffic_netmask: 255.255.255.0 + eca_traffic_net_gateway: 172.26.5.1 + eca_traffic_start: 172.26.5.3 + eca_traffic_end: 172.26.5.254 + eca_traffic_net_local_ip1: 172.26.5.3 + eca_traffic_net_local_ip2: 172.26.5.4 + eca_traffic_net_floating_ip: 172.26.5.5 + ha_net_name: int_mms_ha_net_2 + ha_net_cidr: 172.26.1.0/24 + ha_net_start: 172.26.1.3 + ha_net_end: 172.26.1.254 + ha_net_local_ip1: 172.26.1.3 + ha_net_local_ip2: 172.26.1.4 + lb_names: ZRDM1MMSC03ALB001,ZRDM1MMSC03ALB002 + lb_image_name: BIGIP-11.5.3.0.0.163 + lb_flavor_name: m1.xlarge + security_group_name: mmsc_security_group_1 + availability_zone_0: nova + mmsc_mms_traffic_net_ips: 172.26.2.11,172.26.2.12,172.26.2.13,172.26.2.14,172.26.2.15 + mmsc_oam_ips: 107.250.172.54,107.250.172.55,107.250.172.56,107.250.172.57,107.250.172.58 + mmsc_flavor: lc.4xlarge4 + mmsc_image: mmsc-6.0.2_v5 + mmsc_cinder_volume_size: 480 + nems_fe_flavor: m1.large2 + nems_fe_image: nems-2.1.2_v29 + nems_fe_names: ZRDM1MMSC03NFE001,ZRDM1MMSC03NFE002 + nems_fe_node_roles: FE0,FE1 + nems_fe_oam_ips: 107.250.172.64,107.250.172.65 + nems_fe_nems_traffic_net_ips: 172.26.3.11,172.26.3.12 + nems_fe_nems_user_web_net_ips: 172.26.4.11,172.26.4.12 + nems_fe_nems_internal_net_ips: 172.26.6.11,172.26.6.12 + nems_fe_nems_imap_net_ips: 172.26.7.11,172.26.7.12 + nems_be_names: ZRDM1MMSC03NBE001 + nems_be_node_roles: BE0 + nems_be_oam_ips: 107.250.172.66 + nems_be_nems_internal_net_ips: 172.26.6.13 + nems_be_nems_imap_net_ips: 172.26.7.13 + nems_be_flavor: m1.large2 + nems_be_image: nems-2.1.2_v29 + eca_trx_oam_ips: 107.250.172.70,107.250.172.71,107.250.172.72,107.250.172.73,107.250.172.74,107.250.172.75,107.250.172.76,107.250.172.77,107.250.172.78,107.250.172.79,107.250.172.80,107.250.172.81,107.250.172.82,107.250.172.83,107.250.172.84,107.250.172.85,107.250.172.86,107.250.172.87,107.250.172.88,107.250.172.89 + eca_trx_mgmt_ips: 172.25.137.202,172.25.137.203,172.25.137.204,172.25.137.205,172.25.137.206,172.25.137.207,172.25.137.208,172.25.137.209,172.25.137.210,172.25.137.211,172.25.137.212,172.25.137.213,172.25.137.214,172.25.137.215,172.25.137.216,172.25.137.217,172.25.137.218,172.25.137.219,172.25.137.220,172.25.137.221 + eca_trx_flavor: m1.xlarge + eca_trx_image: ECABASE + timezone: UTC + eca_trx_names: ZRDM1MMSC03TRX001,ZRDM1MMSC03TRX002,ZRDM1MMSC03TRX003,ZRDM1MMSC03TRX004,ZRDM1MMSC03TRX005,ZRDM1MMSC03TRX006,ZRDM1MMSC03TRX007,ZRDM1MMSC03TRX008,ZRDM1MMSC03TRX009,ZRDM1MMSC03TRX010,ZRDM1MMSC03TRX011,ZRDM1MMSC03TRX012,ZRDM1MMSC03TRX013,ZRDM1MMSC03TRX014,ZRDM1MMSC03TRX015,ZRDM1MMSC03TRX016,ZRDM1MMSC03TRX017,ZRDM1MMSC03TRX018,ZRDM1MMSC03TRX019,ZRDM1MMSC03TRX020 + eca_trx_eca_traffic_net_ips: 172.26.5.11,172.26.5.12,172.26.5.13,172.26.5.14,172.26.5.15,172.26.5.16,172.26.5.17,172.26.5.18,172.26.5.19,172.26.5.20,172.26.5.21,172.26.5.22,172.26.5.23,172.26.5.24,172.26.5.25,172.26.5.26,172.26.5.27,172.26.5.28,172.26.5.29,172.26.5.30 + mmsc_names: ZRDM1MMSC03MMS001,ZRDM1MMSC03MMS002,ZRDM1MMSC03MMS003,ZRDM1MMSC03MMS004,ZRDM1MMSC03MMS005 + nems_volume_size: 50 + nems_be_volume_size: 610 + MMSC_volume_type: Platinum + NEMS_FE_volume_type: Platinum + NEMS_BE_volume_type: Platinum + mmsc_core_virtual_server_ips: 172.31.10.21,172.31.10.22 + mmsc_core_snat_ips: 172.31.10.23,172.31.10.24,172.31.10.25,172.31.10.26,172.31.10.27 + mmsc_dmz_protected_virtual_server_ips: 107.239.14.21,107.239.14.22,107.239.14.23 + mmsc_dmz_protected_snat_ips: 107.239.14.24,107.239.14.25,107.239.14.26,107.239.14.27 + eca_mgmt_net_name: int_eca_mgmt_net_1 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/SG_ECA_MGMT.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/SG_ECA_MGMT.yaml new file mode 100644 index 0000000000..53efc5e36e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/SG_ECA_MGMT.yaml @@ -0,0 +1,76 @@ +heat_template_version: 2013-05-23 + +################################# +# +# Changes from MSO - 11/5/2015 +# - Parameter changes as below +# - CDLs for vmNames, IPs +# - aZone->availability_zone_0 +# - nwName->{nwRole}_net_name +# - nwID->{nwRole}_net_id +# - vmName->{vmType}_names +# - ips ->{vmType}_{nwRole}_ips +# - fips->{vmType}_{nwRole}_floating_ip +# - added replacement_policy: AUTO to all ports +# - added vnf_id for metadata to all servers +# - externalized security group resource +# - externalized eca_mgmt network +# +################################# + +description: > + HOT template that creates Security Group and ECA network + +parameters: + eca_mgmt_name: + type: string + label: eca management name + description: eca management name + eca_mgmt_start: + type: string + label: eca management start + description: eca management start + eca_mgmt_end: + type: string + label: eca management end + description: eca management end + eca_mgmt_cidr: + type: string + label: eca management cidr + description: eca management cidr + eca_mgmt_netmask: + type: string + label: ECA mgmt network subnet mask + description: ECA mgmt network subnet mask + security_group_name: + type: string + label: MMSC security group name + description: MMSC security group name + +resources: + mms_security_group: + type: OS::Neutron::SecurityGroup + properties: + description: mmsc security group + name: {get_param: security_group_name} + rules: [{"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0} + ] + eca_mgmt_net: + type: OS::Contrail::VirtualNetwork + properties: + name: {get_param: eca_mgmt_name} + + eca_mgmt_network_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: eca_mgmt_name} + allocation_pools: [{"start": {get_param: eca_mgmt_start}, "end": {get_param: eca_mgmt_end}}] + cidr: {get_param: eca_mgmt_cidr} + #enable_dhcp: false + #gateway_ip: null + network_id: {get_resource: eca_mgmt_net} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/cmaui.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/cmaui.env new file mode 100644 index 0000000000..2e0f4c0796 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/cmaui.env @@ -0,0 +1,15 @@ +parameters: + cmaui_names: ZRDM1MMSC02CMI001,ZRDM1MMSC02CMI002 + cmaui_flavor: m1.large + cmaui_image: cmaui-5.0.2.5_v25 + cmaui_cinder_volume_size: 55 + oam_net_name: oam_protected_net_0 + oam_network_netmask: 255.255.255.192 + oam_network_gateway: 10.20.30.1 + external_dns: 155.165.201.250 + external_ntp: 155.165.194.100 + security_group_name: mmsc_security_group_1 + availability_zone_0: nova + timezone: UTC + cmaui_oam_ips: 107.250.172.42,107.250.172.43 + CMAUI_volume_type: Platinum \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/cmaui.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/cmaui.yml new file mode 100644 index 0000000000..6d094be26f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/cmaui.yml @@ -0,0 +1,171 @@ +heat_template_version: 2013-05-23 + +################################# +# +# Changes from MSO 01/26/2016 +# Updated per ECOMP feedback +# +################################# + +description: cmaui server template for vMMSC + +parameters: + vnf_id: + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-CMAUI_id + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_cinder_volume_size: + type: number + label: CMAUI Cinder volume size + description: the size of the CMAUI Cinder volume + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + oam_net_name: + type: string + description: UID of OAM network + oam_network_netmask: + type: string + label: oam network netmask + description: oam network gateway + oam_network_gateway: + type: string + label: oam network gateway + description: oam network gateway + external_dns: + type: string + label: dns server + description: dns server + external_ntp: + type: string + label: ntp server + description: ntp server + security_group_name: + type: string + label: security group name + description: the name of security group + timezone: + type: string + label: timezone + description: timezone + cmaui_oam_ips: + type: comma_delimited_list + label: CMAUI oam_net IP addresses + description: CMAUI oam_net IP addresses + CMAUI_volume_type: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + +resources: + server_cmaui: + type: eca_oam.yaml + properties: + cmaui_name: { get_param: [cmaui_names, 0]} + cmaui_image: { get_param: cmaui_image } + availability_zone_0: { get_param: availability_zone_0 } + cmaui_flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_0 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + cmaui.mgmt.ip=${cmaui.mgmt.ip} + cmaui.mgmt.netmask=${cmaui.mgmt.netmask} + cmaui.mgmt.gateway=${cmaui.mgmt.gateway} + cmaui.external.dns=${cmaui.external.dns} + cmaui.external.ntp=${cmaui.external.ntp} + cmaui.node=${cmaui.node} + cmaui.timezone=${cmaui.timezone} + params: + ${cmaui.mgmt.ip}: {get_param: [cmaui_oam_ips, 0]} + ${cmaui.mgmt.netmask}: {get_param: oam_network_netmask} + ${cmaui.mgmt.gateway}: {get_param: oam_network_gateway} + ${cmaui.external.dns}: {get_param: external_dns} + ${cmaui.external.ntp}: {get_param: external_ntp} + ${cmaui.node}: {get_param: [cmaui_names, 0]} + ${cmaui.timezone}: {get_param: timezone} + user_data_format: RAW + + cmaui_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: cmaui_cinder_volume_size} + volume_type: {get_param: CMAUI_volume_type} + + cmaui_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: cmaui_volume} + instance_uuid: {get_resource: server_cmaui} + + cmaui_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_cmaui1: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 1]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui1_port_0 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + cmaui.mgmt.ip=${cmaui.mgmt.ip} + cmaui.mgmt.netmask=${cmaui.mgmt.netmask} + cmaui.mgmt.gateway=${cmaui.mgmt.gateway} + cmaui.external.dns=${cmaui.external.dns} + cmaui.external.ntp=${cmaui.external.ntp} + cmaui.node=${cmaui.node} + cmaui.timezone=${cmaui.timezone} + params: + ${cmaui.mgmt.ip}: {get_param: [cmaui_oam_ips, 1]} + ${cmaui.mgmt.netmask}: {get_param: oam_network_netmask} + ${cmaui.mgmt.gateway}: {get_param: oam_network_gateway} + ${cmaui.external.dns}: {get_param: external_dns} + ${cmaui.external.ntp}: {get_param: external_ntp} + ${cmaui.node}: {get_param: [cmaui_names, 1]} + ${cmaui.timezone}: {get_param: timezone} + user_data_format: RAW + + cmaui1_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: cmaui_cinder_volume_size} + volume_type: {get_param: CMAUI_volume_type} + + cmaui1_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: cmaui1_volume} + instance_uuid: {get_resource: server_cmaui1} + + cmaui1_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 1]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/eca_oam.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/eca_oam.env new file mode 100644 index 0000000000..f9991722b3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/eca_oam.env @@ -0,0 +1,20 @@ +parameters: + eca_names: ZRDM1MMSC02OAM001,ZRDM1MMSC02OAM002 + arb_names: ZRDM1MMSC02ARB001 + oam_image_name: ECABASE + oam_flavor: lc.xlarge4 + arbiter_flavor: m1.large2 + availability_zone_0: nova + oam_net_name: oam_protected_net_0 + eca_mgmt_net_name: int_mms_eca_mgmt_net_1 + eca_oam_ips: 107.250.172.44,107.250.172.45 + eca_eca_mgmt_ips: 172.25.137.242,172.25.137.243 + eca_oam_gateway: 107.250.172.1 + arb_oam_ips: 107.250.172.46 + arb_eca_mgmt_ips: 172.25.137.244 + security_group_name: mmsc_security_group_1 + oam_volume_size: 1800 + arb_volume_size: 40 + swift_eca_url: http://object-store.rdm2.cci.com:8080/v1/AUTH_1bbab536a19b4756926e7d0ec1eb543c/eca + ECA_OAM_volume_type: Platinum + ARB_volume_type: Platinum diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/eca_oam.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/eca_oam.yaml new file mode 100644 index 0000000000..db5ab5c26b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/eca_oam.yaml @@ -0,0 +1,407 @@ +heat_template_version: 2013-05-23 + +########################################################## +# +# Changes from MSO +# - Updated per ECOMP Feedback +# +# +########################################################## + +description: This stack creates two ECA OAM VM and one ARB VM + +parameters: + vnf_id: + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-ECA_id + cmaui_name: + type: string + label: cmaui name + description: cmaui name + cmaui_image: + type: string + label: cmaui image + description: cmaui image + cmaui_flavor: + type: string + label: flavor name + description: cmaui flavor name + networks: + type: string + label: network name + description: cmaui network name + metadata: + type: string + label: metadata + description: cmaui metadata + user_data: + type: string + label: user data + description: cmaui user data + user_data_format: + type: string + label: user data + description: cmaui user data + eca_names: + type: comma_delimited_list + label: oam servers names + description: the names of the OAM1,OAM2 VM instances + arb_names: + type: comma_delimited_list + label: arbiter server names + description: the names of the arbiter VM instances + oam_image_name: + type: string + label: image name + description: the OAM image name + oam_flavor: + type: string + label: flavor name + description: OAM flavor name + arbiter_flavor: + type: string + label: flavor name + description: arbiter flavor name + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + oam_net_name: + type: string + label: oam network name + description: the name of the oam network + eca_mgmt_net_name: + type: string + label: internal network name + description: the name of the internal network + eca_oam_ips: + type: comma_delimited_list + label: oam network ips + description: the ips of oam networks for eca VM + eca_oam_gateway: + type: string + label: oam1 oam gateway + description: the ip of oam gateway + eca_eca_mgmt_ips: + type: comma_delimited_list + label: eca_mgmt network ips for eca VM + description: internal eca_mgmt network ips for eca VM + arb_oam_ips: + type: comma_delimited_list + label: oam network ips for arb VM + description: oam network ips for eca VM + arb_eca_mgmt_ips: + type: comma_delimited_list + label: eca_mgmt network ips + description: internal eca_mgmt network ips for arb VM + security_group_name: + type: string + label: security group name + description: the name of security group + oam_volume_size: + type: number + label: volume size + description: the size of the OAM volume + arb_volume_size: + type: number + label: volume size + description: the size of the ARB volume + swift_eca_url: + type: string + label: Swift URL + description: Base URL for eca swift object store + ECA_OAM_volume_type: + type: string + label: eca oam vm volume type + description: the name of the target volume backend + ARB_volume_type: + type: string + label: arb vm volume type + description: the name of the target volume backend + +resources: + oam1_instance: + type: OS::Nova::Server + properties: + name: {get_param: [eca_names, 0]} + image: {get_param: oam_image_name} + flavor: {get_param: oam_flavor} + availability_zone: {get_param: availability_zone_0} + networks: + - port: {get_resource: oam1_int_port} + - port: {get_resource: oam1_mgmt_port} + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + sed -i s/HOSTNAME.*/"HOSTNAME=oam1_hostname"/g /etc/sysconfig/network + eth1_ip_address='oam1_mgt_ip' + eth1_gateway='oam_gateway' + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + mkdir /etc/puppet/files/roles/transcoder + mkdir /etc/puppet/files/roles/oam_primary + curl swift_url/etc/puppet/manifests/roles/oam_primary.pp > /etc/puppet/manifests/roles/oam_primary.pp + curl swift_url/etc/puppet/manifests/roles/transcoder.pp > /etc/puppet/manifests/roles/transcoder.pp + curl swift_url/etc/puppet/files/roles/oam_primary/config.yaml > /etc/puppet/files/roles/oam_primary/config.yaml + curl swift_url/etc/puppet/files/roles/transcoder/config.yaml > /etc/puppet/files/roles/transcoder/config.yaml + curl swift_url/etc/puppet/files/roles/transcoder/hpm.conf > /etc/puppet/files/roles/transcoder/hpm.conf + curl swift_url/etc/puppet/files/roles/transcoder/trx.conf > /etc/puppet/files/roles/transcoder/trx.conf + curl swift_url/etc/puppet/files/roles/transcoder/plugins-mo.conf > /etc/puppet/files/roles/transcoder/plugins-mo.conf + curl swift_url/etc/puppet/files/global/11-customer.conf > /etc/puppet/files/global/11-customer.conf + curl swift_url/etc/puppet/manifests/site.pp > /etc/puppet/manifests/site.pp + curl swift_url/scripts/van-init-replicaset > /usr/sbin/van-init-replicaset + van-role oam_primary > /root/startup-van-role.out + curl swift_url/scripts/fdisk-keystrokes > /root/fdisk-keystrokes + fdisk /dev/vdb < /root/fdisk-keystrokes + curl swift_url/scripts/os-conf-cinder-vol > /root/os-conf-cinder-vol + chmod 755 /root/os-conf-cinder-vol + /root/os-conf-cinder-vol 2>> /tmp/cinder_volume.log + params: + oam1_mgt_ip: {get_param: [eca_oam_ips, 0] } + oam_gateway: {get_param: eca_oam_gateway } + oam1_hostname: {get_param: [eca_names, 0]} + swift_url: {get_param: swift_eca_url} + + oam1_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [eca_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + oam1_int_port: + type: OS::Neutron::Port + properties: + network: {get_param: eca_mgmt_net_name} + fixed_ips: [{"ip_address": {get_param: [eca_eca_mgmt_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + oam1_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: oam_volume_size} + volume_type: {get_param: ECA_OAM_volume_type} + + oam1_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: oam1_volume} + instance_uuid: {get_resource: oam1_instance} + + oam2_instance: + type: OS::Nova::Server + properties: + name: {get_param: [eca_names, 1]} + image: {get_param: oam_image_name} + flavor: {get_param: oam_flavor} + availability_zone: {get_param: availability_zone_0} + networks: + - port: {get_resource: oam2_int_port} + - port: {get_resource: oam2_mgmt_port} + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + sed -i s/HOSTNAME.*/"HOSTNAME=oam2_hostname"/g /etc/sysconfig/network + eth1_ip_address='oam2_mgt_ip' + eth1_gateway='oam_gateway' + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + curl swift_url/etc/puppet/manifests/roles/oam_secondary.pp > /etc/puppet/manifests/roles/oam_secondary.pp + curl swift_url/etc/puppet/files/global/config.yaml > /etc/puppet/files/global/config.yaml + curl swift_url/etc/puppet/files/global/11-customer.conf > /etc/puppet/files/global/11-customer.conf + van-role oam_secondary > /root/startup-van-role.out + curl swift_url/scripts/fdisk-keystrokes > /root/fdisk-keystrokes + fdisk /dev/vdb < /root/fdisk-keystrokes + curl swift_url/scripts/os-conf-cinder-vol > /root/os-conf-cinder-vol + chmod 755 /root/os-conf-cinder-vol + /root/os-conf-cinder-vol 2>> /tmp/cinder_volume.log + + params: + oam2_mgt_ip: {get_param: [eca_oam_ips, 1] } + oam2_hostname: {get_param: [eca_names, 1]} + swift_url: {get_param: swift_eca_url} + oam_gateway: {get_param: eca_oam_gateway } + + oam2_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [eca_oam_ips, 1]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + oam2_int_port: + type: OS::Neutron::Port + properties: + network: {get_param: eca_mgmt_net_name} + fixed_ips: [{"ip_address": {get_param: [eca_eca_mgmt_ips, 1]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + oam2_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: oam_volume_size} + volume_type: {get_param: ECA_OAM_volume_type} + + oam2_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: oam2_volume} + instance_uuid: {get_resource: oam2_instance} + + arb_instance: + type: OS::Nova::Server + properties: + name: {get_param: [arb_names, 0]} + image: {get_param: oam_image_name} + flavor: {get_param: arbiter_flavor} + availability_zone: {get_param: availability_zone_0} + networks: + - port: {get_resource: arb_int_port} + - port: {get_resource: arb_mgmt_port} + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + #!/bin/bash + sed -i s/HOSTNAME.*/"HOSTNAME=arb_hostname"/g /etc/sysconfig/network + eth1_ip_address='arb_mgt_ip' + eth1_gateway='oam_gateway' + for interface in $(ip addr show|perl -nle 's/\d:\s([a-z0-9]*?):/print $1/e') ; do + if [ "$interface" != "lo" ]; then + DEVICE_NAME=$interface + interface_ip_var="${DEVICE_NAME}_ip_address" + gateway_var="${DEVICE_NAME}_gateway" + var_name="$interface_ip_var" + var_gateway="$gateway_var" + if [ ! -z ${!var_name} ]; then + IPADDR=${!var_name} + BOOTPROTO="static" + GATEWAY=${!var_gateway} + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes\nUSERCTL=no" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=$BOOTPROTO" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nIPADDR=$IPADDR" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nNETMASK=255.255.255.0" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nGATEWAY=$GATEWAY" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + else + if [ ! -f /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME ]; then + echo "Configuring $DEVICE_NAME to use DHCP" + IFCFG_TEMPLATE="DEVICE=$DEVICE_NAME\nNM_CONTROLLED=no\nONBOOT=yes" + IFCFG_TEMPLATE="$IFCFG_TEMPLATE\nBOOTPROTO=dhcp\nUSERCTL=no" + printf $IFCFG_TEMPLATE > /etc/sysconfig/network-scripts/ifcfg-$DEVICE_NAME + fi + fi + ifdown $DEVICE_NAME + ifup $DEVICE_NAME + printf "$DEVICE_NAME\n" >> /tmp/network_config + fi + done + curl swift_url/etc/puppet/manifests/roles/oam_arbiter.pp > /etc/puppet/manifests/roles/oam_arbiter.pp + curl swift_url/etc/puppet/files/global/config.yaml > /etc/puppet/files/global/config.yaml + curl swift_url/etc/puppet/files/global/11-customer.conf > /etc/puppet/files/global/11-customer.conf + van-role oam_arbiter > /root/startup-van-role.out + curl swift_url/scripts/fdisk-keystrokes > /root/fdisk-keystrokes + fdisk /dev/vdb < /root/fdisk-keystrokes + curl swift_url/scripts/os-conf-cinder-vol > /root/os-conf-cinder-vol + chmod 755 /root/os-conf-cinder-vol + /root/os-conf-cinder-vol 2>> /tmp/cinder_volume.log + params: + arb_mgt_ip: {get_param: [arb_oam_ips, 0] } + arb_hostname: {get_param: [arb_names, 0]} + swift_url: {get_param: swift_eca_url} + oam_gateway: {get_param: eca_oam_gateway } + + arb_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [arb_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + arb_int_port: + type: OS::Neutron::Port + properties: + network: {get_param: eca_mgmt_net_name} + fixed_ips: [{"ip_address": {get_param: [arb_eca_mgmt_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + arb_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: arb_volume_size} + volume_type: {get_param: ARB_volume_type} + arb_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: arb_volume} + instance_uuid: {get_resource: arb_instance} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/sg_eca_mgmt.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/sg_eca_mgmt.env new file mode 100644 index 0000000000..8012063ac0 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/multiHeat/referencedHeatResources/inputs/sg_eca_mgmt.env @@ -0,0 +1,7 @@ +parameters: + eca_mgmt_name: int_eca_mgmt_net_1 + eca_mgmt_cidr: 172.25.137.192/26 + eca_mgmt_netmask: 255.255.255.192 + eca_mgmt_start: 172.25.137.195 + eca_mgmt_end: 172.25.137.254 + security_group_name: mmsc_security_group_1 diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/ContrailV2_MultiPolicy_single_net_translation/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/ContrailV2_MultiPolicy_single_net_translation/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..0744579c92 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/ContrailV2_MultiPolicy_single_net_translation/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,305 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + left_vn_fqdn: + hidden: false + immutable: false + type: string + description: dummy + Internal1_cidr: + hidden: false + immutable: false + type: string + src_port_start: + hidden: false + immutable: false + type: string + description: dummy + Internal1_default_gateway: + hidden: false + immutable: false + type: string + Internal1_dhcp: + hidden: false + immutable: false + type: string + src_port_end: + hidden: false + immutable: false + type: string + description: dummy + policy_name: + hidden: false + immutable: false + type: string + description: dummy + dst_port_end: + hidden: false + immutable: false + type: string + description: dummy + simple_action: + hidden: false + immutable: false + type: string + description: dummy + service_instance_fq_name: + hidden: false + immutable: false + type: string + Internal2_cidr: + hidden: false + immutable: false + type: string + protocol: + hidden: false + immutable: false + type: string + description: dummy + Internal2_dhcp: + hidden: false + immutable: false + type: string + dst_port_start: + hidden: false + immutable: false + type: string + description: dummy + network_ipam_refs_data_ipam_subnets_addr_from_start_true: + hidden: false + immutable: false + type: string + description: dummy + Internal2_default_gateway: + hidden: false + immutable: false + type: string + right_vn_fqdn: + hidden: false + immutable: false + type: string + description: dummy + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2: + hidden: false + immutable: false + type: string + description: dummy + left_vn: + hidden: false + immutable: false + type: string + description: dummy + direction: + hidden: false + immutable: false + type: string + description: dummy + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2: + hidden: false + immutable: false + type: string + description: dummy + node_templates: + template_VirtualNetwork_2: + type: org.openecomp.resource.vl.nodes.heat.network.contrailV2.VirtualNetwork + properties: + dhcp_enabled: + get_input: Internal1_dhcp + network_ipam_refs_data: + - network_ipam_refs_data_ipam_subnets: + - network_ipam_refs_data_ipam_subnets_subnet: + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len: + get_input: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2 + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix: + get_input: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2 + network_ipam_refs_data_ipam_subnets_addr_from_start: + get_input: network_ipam_refs_data_ipam_subnets_addr_from_start_true + network_policy_refs_data: + - network_policy_refs_data_sequence: + network_policy_refs_data_sequence_major: 0 + network_policy_refs_data_sequence_minor: 0 + network_name: + get_input: left_vn + network_ipam_refs: + - UNSUPPORTED_RESOURCE_template_NetworkIpam_2 + network_policy_refs: + - list_join: + - ':' + - get_attribute: + - template_NetworkPolicy_1 + - fq_name + - get_attribute: + - template_NetworkPolicy_2 + - fq_name + - template_NetworkPolicy_3 + subnets: + Internal-subnet-1: + enable_dhcp: + get_input: Internal1_dhcp + cidr: + get_input: Internal1_cidr + gateway_ip: + get_input: Internal1_default_gateway + Internal-subnet-2: + enable_dhcp: + get_input: Internal2_dhcp + cidr: + get_input: Internal2_cidr + gateway_ip: + get_input: Internal2_default_gateway + requirements: + - dependency: + capability: tosca.capabilities.Node + node: template_NetworkPolicy_1 + relationship: tosca.relationships.DependsOn + template_NetworkPolicy_1: + type: org.openecomp.resource.vfc.rules.nodes.heat.network.contrailV2.NetworkRules + properties: + name: + get_input: policy_name + network_policy_entries: + network_policy_entries_policy_rule: + - network_policy_entries_policy_rule_dst_addresses: + - network_policy_entries_policy_rule_dst_addresses_virtual_network: + get_input: right_vn_fqdn + network_policy_entries_policy_rule_dst_ports: + - network_policy_entries_policy_rule_dst_ports_start_port: + get_input: dst_port_start + network_policy_entries_policy_rule_dst_ports_end_port: + get_input: dst_port_end + network_policy_entries_policy_rule_protocol: + get_input: protocol + network_policy_entries_policy_rule_src_addresses: + - network_policy_entries_policy_rule_src_addresses_virtual_network: + get_input: left_vn_fqdn + network_policy_entries_policy_rule_direction: + get_input: direction + network_policy_entries_policy_rule_src_ports: + - network_policy_entries_policy_rule_src_ports_start_port: + get_input: src_port_start + network_policy_entries_policy_rule_src_ports_end_port: + get_input: src_port_end + network_policy_entries_policy_rule_action_list: + network_policy_entries_policy_rule_action_list_simple_action: + get_input: simple_action + network_policy_entries_policy_rule_action_list_apply_service: + - get_input: service_instance_fq_name + requirements: + - network: + capability: tosca.capabilities.Attachment + node: template_VirtualNetwork_2 + relationship: org.openecomp.relationships.AttachesTo + template_NetworkPolicy_3: + type: org.openecomp.resource.vfc.rules.nodes.heat.network.contrailV2.NetworkRules + properties: + name: + get_input: policy_name + network_policy_entries: + network_policy_entries_policy_rule: + - network_policy_entries_policy_rule_dst_addresses: + - network_policy_entries_policy_rule_dst_addresses_virtual_network: + get_input: right_vn_fqdn + network_policy_entries_policy_rule_dst_ports: + - network_policy_entries_policy_rule_dst_ports_start_port: + get_input: dst_port_start + network_policy_entries_policy_rule_dst_ports_end_port: + get_input: dst_port_end + network_policy_entries_policy_rule_protocol: + get_input: protocol + network_policy_entries_policy_rule_src_addresses: + - network_policy_entries_policy_rule_src_addresses_virtual_network: + get_input: left_vn_fqdn + network_policy_entries_policy_rule_direction: + get_input: direction + network_policy_entries_policy_rule_src_ports: + - network_policy_entries_policy_rule_src_ports_start_port: + get_input: src_port_start + network_policy_entries_policy_rule_src_ports_end_port: + get_input: src_port_end + network_policy_entries_policy_rule_action_list: + network_policy_entries_policy_rule_action_list_simple_action: + get_input: simple_action + network_policy_entries_policy_rule_action_list_apply_service: + - get_input: service_instance_fq_name + requirements: + - network: + capability: tosca.capabilities.Attachment + node: template_VirtualNetwork_2 + relationship: org.openecomp.relationships.AttachesTo + template_NetworkPolicy_2: + type: org.openecomp.resource.vfc.rules.nodes.heat.network.contrailV2.NetworkRules + properties: + name: + get_input: policy_name + network_policy_entries: + network_policy_entries_policy_rule: + - network_policy_entries_policy_rule_dst_addresses: + - network_policy_entries_policy_rule_dst_addresses_virtual_network: + get_input: right_vn_fqdn + network_policy_entries_policy_rule_dst_ports: + - network_policy_entries_policy_rule_dst_ports_start_port: + get_input: dst_port_start + network_policy_entries_policy_rule_dst_ports_end_port: + get_input: dst_port_end + network_policy_entries_policy_rule_protocol: + get_input: protocol + network_policy_entries_policy_rule_src_addresses: + - network_policy_entries_policy_rule_src_addresses_virtual_network: + get_input: left_vn_fqdn + network_policy_entries_policy_rule_direction: + get_input: direction + network_policy_entries_policy_rule_src_ports: + - network_policy_entries_policy_rule_src_ports_start_port: + get_input: src_port_start + network_policy_entries_policy_rule_src_ports_end_port: + get_input: src_port_end + network_policy_entries_policy_rule_action_list: + network_policy_entries_policy_rule_action_list_simple_action: + get_input: simple_action + network_policy_entries_policy_rule_action_list_apply_service: + - get_input: service_instance_fq_name + requirements: + - network: + capability: tosca.capabilities.Attachment + node: template_VirtualNetwork_2 + relationship: org.openecomp.relationships.AttachesTo + groups: + main: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/main.yml + description: cmaui server template for vMMSC + members: + - template_VirtualNetwork_2 + - template_NetworkPolicy_1 + - template_NetworkPolicy_3 + - template_NetworkPolicy_2 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/ContrailV2_MultiPolicy_single_net_translation/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/ContrailV2_MultiPolicy_single_net_translation/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..539e26b7ab --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/ContrailV2_MultiPolicy_single_net_translation/inputfiles/MANIFEST.json @@ -0,0 +1,12 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "main.yml", + "type": "HEAT", + "isBase": "true" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/ContrailV2_MultiPolicy_single_net_translation/inputfiles/main.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/ContrailV2_MultiPolicy_single_net_translation/inputfiles/main.yml new file mode 100644 index 0000000000..3681b1962b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/ContrailV2_MultiPolicy_single_net_translation/inputfiles/main.yml @@ -0,0 +1,223 @@ +description: "cmaui server template for vMMSC" +heat_template_version: 2013-05-23 +parameters: + Internal1_cidr: + type: string + Internal2_cidr: + type: string + Internal1_default_gateway: + type: string + Internal2_default_gateway: + type: string + Internal1_dhcp: + type: string + Internal2_dhcp: + type: string + direction: + description: dummy + type: string + dst_port_end: + description: dummy + type: string + dst_port_start: + description: dummy + type: string + left_vn: + description: dummy + type: string + left_vn_fqdn: + description: dummy + type: string + network_ipam_refs_data_ipam_subnets_addr_from_start_true: + description: dummy + type: string + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2: + description: dummy + type: string + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2: + description: dummy + type: string + policy_name: + description: dummy + type: string + protocol: + description: dummy + type: string + right_vn_fqdn: + description: dummy + type: string + simple_action: + description: dummy + type: string + src_port_end: + description: dummy + type: string + src_port_start: + description: dummy + type: string + service_instance_fq_name: + type: string +resources: + template_NetworkIpam_2: + properties: + name: + get_param: left_vn + type: "OS::ContrailV2::NetworkIpam" + template_NetworkPolicy_1: + properties: + name: + get_param: policy_name + network_policy_entries: + network_policy_entries_policy_rule: + - + network_policy_entries_policy_rule_action_list: + network_policy_entries_policy_rule_action_list_apply_service: + - + get_param: service_instance_fq_name + network_policy_entries_policy_rule_action_list_simple_action: + get_param: simple_action + network_policy_entries_policy_rule_direction: + get_param: direction + network_policy_entries_policy_rule_dst_addresses: + - + network_policy_entries_policy_rule_dst_addresses_virtual_network: + get_param: right_vn_fqdn + network_policy_entries_policy_rule_dst_ports: + - + network_policy_entries_policy_rule_dst_ports_end_port: + get_param: dst_port_end + network_policy_entries_policy_rule_dst_ports_start_port: + get_param: dst_port_start + network_policy_entries_policy_rule_protocol: + get_param: protocol + network_policy_entries_policy_rule_src_addresses: + - + network_policy_entries_policy_rule_src_addresses_virtual_network: + get_param: left_vn_fqdn + network_policy_entries_policy_rule_src_ports: + - + network_policy_entries_policy_rule_src_ports_end_port: + get_param: src_port_end + network_policy_entries_policy_rule_src_ports_start_port: + get_param: src_port_start + type: "OS::ContrailV2::NetworkPolicy" + template_NetworkPolicy_2: + properties: + name: + get_param: policy_name + network_policy_entries: + network_policy_entries_policy_rule: + - + network_policy_entries_policy_rule_action_list: + network_policy_entries_policy_rule_action_list_apply_service: + - + get_param: service_instance_fq_name + network_policy_entries_policy_rule_action_list_simple_action: + get_param: simple_action + network_policy_entries_policy_rule_direction: + get_param: direction + network_policy_entries_policy_rule_dst_addresses: + - + network_policy_entries_policy_rule_dst_addresses_virtual_network: + get_param: right_vn_fqdn + network_policy_entries_policy_rule_dst_ports: + - + network_policy_entries_policy_rule_dst_ports_end_port: + get_param: dst_port_end + network_policy_entries_policy_rule_dst_ports_start_port: + get_param: dst_port_start + network_policy_entries_policy_rule_protocol: + get_param: protocol + network_policy_entries_policy_rule_src_addresses: + - + network_policy_entries_policy_rule_src_addresses_virtual_network: + get_param: left_vn_fqdn + network_policy_entries_policy_rule_src_ports: + - + network_policy_entries_policy_rule_src_ports_end_port: + get_param: src_port_end + network_policy_entries_policy_rule_src_ports_start_port: + get_param: src_port_start + type: "OS::ContrailV2::NetworkPolicy" + template_NetworkPolicy_3: + properties: + name: + get_param: policy_name + network_policy_entries: + network_policy_entries_policy_rule: + - + network_policy_entries_policy_rule_action_list: + network_policy_entries_policy_rule_action_list_apply_service: + - + get_param: service_instance_fq_name + network_policy_entries_policy_rule_action_list_simple_action: + get_param: simple_action + network_policy_entries_policy_rule_direction: + get_param: direction + network_policy_entries_policy_rule_dst_addresses: + - + network_policy_entries_policy_rule_dst_addresses_virtual_network: + get_param: right_vn_fqdn + network_policy_entries_policy_rule_dst_ports: + - + network_policy_entries_policy_rule_dst_ports_end_port: + get_param: dst_port_end + network_policy_entries_policy_rule_dst_ports_start_port: + get_param: dst_port_start + network_policy_entries_policy_rule_protocol: + get_param: protocol + network_policy_entries_policy_rule_src_addresses: + - + network_policy_entries_policy_rule_src_addresses_virtual_network: + get_param: left_vn_fqdn + network_policy_entries_policy_rule_src_ports: + - + network_policy_entries_policy_rule_src_ports_end_port: + get_param: src_port_end + network_policy_entries_policy_rule_src_ports_start_port: + get_param: src_port_start + type: "OS::ContrailV2::NetworkPolicy" + + template_VirtualNetwork_2: + depends_on: + - template_NetworkIpam_2 + - template_NetworkPolicy_1 + properties: + name: + get_param: left_vn + network_ipam_refs: + - + get_resource: template_NetworkIpam_2 + network_ipam_refs_data: + - + network_ipam_refs_data_ipam_subnets: + - + network_ipam_refs_data_ipam_subnets_addr_from_start: + get_param: network_ipam_refs_data_ipam_subnets_addr_from_start_true + network_ipam_refs_data_ipam_subnets_subnet: + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix: + get_param: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2 + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len: + get_param: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2 + network_policy_refs: [ { list_join: [':', { get_attr: [ template_NetworkPolicy_1, fq_name ] } ] }, { get_attr: [ template_NetworkPolicy_2, fq_name ] },{ get_resource: template_NetworkPolicy_3}] + network_policy_refs_data: + - + network_policy_refs_data_sequence: + network_policy_refs_data_sequence_major: 0 + network_policy_refs_data_sequence_minor: 0 + type: "OS::ContrailV2::VirtualNetwork" + Internal-subnet-1: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: template_VirtualNetwork_2 } + cidr: { get_param: Internal1_cidr } + gateway_ip: { get_param: Internal1_default_gateway } + enable_dhcp: { get_param: Internal1_dhcp } + + Internal-subnet-2: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: template_VirtualNetwork_2 } + cidr: { get_param: Internal2_cidr } + gateway_ip: { get_param: Internal2_default_gateway } + enable_dhcp: { get_param: Internal2_dhcp } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/ContrailV2_Multi_net_single_policy_translation/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/ContrailV2_Multi_net_single_policy_translation/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..f00614b2ad --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/ContrailV2_Multi_net_single_policy_translation/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,291 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + left_vn_fqdn: + hidden: false + immutable: false + type: string + description: dummy + Internal1_cidr: + hidden: false + immutable: false + type: string + src_port_start: + hidden: false + immutable: false + type: string + description: dummy + Internal1_default_gateway: + hidden: false + immutable: false + type: string + Internal1_dhcp: + hidden: false + immutable: false + type: string + src_port_end: + hidden: false + immutable: false + type: string + description: dummy + policy_name: + hidden: false + immutable: false + type: string + description: dummy + dst_port_end: + hidden: false + immutable: false + type: string + description: dummy + simple_action: + hidden: false + immutable: false + type: string + description: dummy + service_instance_fq_name: + hidden: false + immutable: false + type: string + Internal2_cidr: + hidden: false + immutable: false + type: string + protocol: + hidden: false + immutable: false + type: string + description: dummy + Internal2_dhcp: + hidden: false + immutable: false + type: string + dst_port_start: + hidden: false + immutable: false + type: string + description: dummy + network_ipam_refs_data_ipam_subnets_addr_from_start_true: + hidden: false + immutable: false + type: string + description: dummy + Internal2_default_gateway: + hidden: false + immutable: false + type: string + right_vn_fqdn: + hidden: false + immutable: false + type: string + description: dummy + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2: + hidden: false + immutable: false + type: string + description: dummy + left_vn: + hidden: false + immutable: false + type: string + description: dummy + direction: + hidden: false + immutable: false + type: string + description: dummy + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2: + hidden: false + immutable: false + type: string + description: dummy + node_templates: + template_NetworkPolicy: + type: org.openecomp.resource.vfc.rules.nodes.heat.network.contrailV2.NetworkRules + properties: + name: + get_input: policy_name + network_policy_entries: + network_policy_entries_policy_rule: + - network_policy_entries_policy_rule_dst_addresses: + - network_policy_entries_policy_rule_dst_addresses_virtual_network: + get_input: right_vn_fqdn + network_policy_entries_policy_rule_dst_ports: + - network_policy_entries_policy_rule_dst_ports_start_port: + get_input: dst_port_start + network_policy_entries_policy_rule_dst_ports_end_port: + get_input: dst_port_end + network_policy_entries_policy_rule_protocol: + get_input: protocol + network_policy_entries_policy_rule_src_addresses: + - network_policy_entries_policy_rule_src_addresses_virtual_network: + get_input: left_vn_fqdn + network_policy_entries_policy_rule_direction: + get_input: direction + network_policy_entries_policy_rule_src_ports: + - network_policy_entries_policy_rule_src_ports_start_port: + get_input: src_port_start + network_policy_entries_policy_rule_src_ports_end_port: + get_input: src_port_end + network_policy_entries_policy_rule_action_list: + network_policy_entries_policy_rule_action_list_simple_action: + get_input: simple_action + network_policy_entries_policy_rule_action_list_apply_service: + - get_input: service_instance_fq_name + requirements: + - network: + capability: tosca.capabilities.Attachment + node: template_VirtualNetwork_1 + relationship: org.openecomp.relationships.AttachesTo + - network: + capability: tosca.capabilities.Attachment + node: template_VirtualNetwork_2 + relationship: org.openecomp.relationships.AttachesTo + - network: + capability: tosca.capabilities.Attachment + node: template_VirtualNetwork_3 + relationship: org.openecomp.relationships.AttachesTo + template_VirtualNetwork_2: + type: org.openecomp.resource.vl.nodes.heat.network.contrailV2.VirtualNetwork + properties: + dhcp_enabled: + get_input: Internal1_dhcp + network_ipam_refs_data: + - network_ipam_refs_data_ipam_subnets: + - network_ipam_refs_data_ipam_subnets_subnet: + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len: + get_input: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2 + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix: + get_input: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2 + network_ipam_refs_data_ipam_subnets_addr_from_start: + get_input: network_ipam_refs_data_ipam_subnets_addr_from_start_true + network_policy_refs_data: + - network_policy_refs_data_sequence: + network_policy_refs_data_sequence_major: 0 + network_policy_refs_data_sequence_minor: 0 + network_name: + get_input: left_vn + network_ipam_refs: + - UNSUPPORTED_RESOURCE_template_NetworkIpam_2 + network_policy_refs: + - get_attribute: + - template_NetworkPolicy + - fq_name + subnets: + Internal-subnet-1: + enable_dhcp: + get_input: Internal1_dhcp + cidr: + get_input: Internal1_cidr + gateway_ip: + get_input: Internal1_default_gateway + Internal-subnet-2: + enable_dhcp: + get_input: Internal2_dhcp + cidr: + get_input: Internal2_cidr + gateway_ip: + get_input: Internal2_default_gateway + requirements: + - dependency: + capability: tosca.capabilities.Node + node: template_NetworkPolicy + relationship: tosca.relationships.DependsOn + template_VirtualNetwork_1: + type: org.openecomp.resource.vl.nodes.heat.network.contrailV2.VirtualNetwork + properties: + network_ipam_refs_data: + - network_ipam_refs_data_ipam_subnets: + - network_ipam_refs_data_ipam_subnets_subnet: + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len: + get_input: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2 + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix: + get_input: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2 + network_ipam_refs_data_ipam_subnets_addr_from_start: + get_input: network_ipam_refs_data_ipam_subnets_addr_from_start_true + network_policy_refs_data: + - network_policy_refs_data_sequence: + network_policy_refs_data_sequence_major: 0 + network_policy_refs_data_sequence_minor: 0 + network_name: + get_input: left_vn + network_ipam_refs: + - UNSUPPORTED_RESOURCE_template_NetworkIpam_2 + network_policy_refs: + - list_join: + - ':' + - get_attribute: + - template_NetworkPolicy + - fq_name + requirements: + - dependency: + capability: tosca.capabilities.Node + node: template_NetworkPolicy + relationship: tosca.relationships.DependsOn + template_VirtualNetwork_3: + type: org.openecomp.resource.vl.nodes.heat.network.contrailV2.VirtualNetwork + properties: + network_ipam_refs_data: + - network_ipam_refs_data_ipam_subnets: + - network_ipam_refs_data_ipam_subnets_subnet: + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len: + get_input: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2 + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix: + get_input: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2 + network_ipam_refs_data_ipam_subnets_addr_from_start: + get_input: network_ipam_refs_data_ipam_subnets_addr_from_start_true + network_policy_refs_data: + - network_policy_refs_data_sequence: + network_policy_refs_data_sequence_major: 0 + network_policy_refs_data_sequence_minor: 0 + network_name: + get_input: left_vn + network_ipam_refs: + - UNSUPPORTED_RESOURCE_template_NetworkIpam_2 + network_policy_refs: + - template_NetworkPolicy + requirements: + - dependency: + capability: tosca.capabilities.Node + node: template_NetworkPolicy + relationship: tosca.relationships.DependsOn + groups: + main: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/main.yml + description: cmaui server template for vMMSC + members: + - template_NetworkPolicy + - template_VirtualNetwork_2 + - template_VirtualNetwork_1 + - template_VirtualNetwork_3 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/ContrailV2_Multi_net_single_policy_translation/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/ContrailV2_Multi_net_single_policy_translation/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..539e26b7ab --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/ContrailV2_Multi_net_single_policy_translation/inputfiles/MANIFEST.json @@ -0,0 +1,12 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "main.yml", + "type": "HEAT", + "isBase": "true" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/ContrailV2_Multi_net_single_policy_translation/inputfiles/main.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/ContrailV2_Multi_net_single_policy_translation/inputfiles/main.yml new file mode 100644 index 0000000000..ceb55edea2 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/ContrailV2_Multi_net_single_policy_translation/inputfiles/main.yml @@ -0,0 +1,203 @@ +description: "cmaui server template for vMMSC" +heat_template_version: 2013-05-23 +parameters: + Internal1_cidr: + type: string + Internal2_cidr: + type: string + Internal1_default_gateway: + type: string + Internal2_default_gateway: + type: string + Internal1_dhcp: + type: string + Internal2_dhcp: + type: string + direction: + description: dummy + type: string + dst_port_end: + description: dummy + type: string + dst_port_start: + description: dummy + type: string + left_vn: + description: dummy + type: string + left_vn_fqdn: + description: dummy + type: string + network_ipam_refs_data_ipam_subnets_addr_from_start_true: + description: dummy + type: string + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2: + description: dummy + type: string + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2: + description: dummy + type: string + policy_name: + description: dummy + type: string + protocol: + description: dummy + type: string + right_vn_fqdn: + description: dummy + type: string + simple_action: + description: dummy + type: string + src_port_end: + description: dummy + type: string + src_port_start: + description: dummy + type: string + service_instance_fq_name: + type: string +resources: + template_NetworkIpam_2: + properties: + name: + get_param: left_vn + type: "OS::ContrailV2::NetworkIpam" + template_NetworkPolicy: + properties: + name: + get_param: policy_name + network_policy_entries: + network_policy_entries_policy_rule: + - + network_policy_entries_policy_rule_action_list: + network_policy_entries_policy_rule_action_list_apply_service: + - + get_param: service_instance_fq_name + network_policy_entries_policy_rule_action_list_simple_action: + get_param: simple_action + network_policy_entries_policy_rule_direction: + get_param: direction + network_policy_entries_policy_rule_dst_addresses: + - + network_policy_entries_policy_rule_dst_addresses_virtual_network: + get_param: right_vn_fqdn + network_policy_entries_policy_rule_dst_ports: + - + network_policy_entries_policy_rule_dst_ports_end_port: + get_param: dst_port_end + network_policy_entries_policy_rule_dst_ports_start_port: + get_param: dst_port_start + network_policy_entries_policy_rule_protocol: + get_param: protocol + network_policy_entries_policy_rule_src_addresses: + - + network_policy_entries_policy_rule_src_addresses_virtual_network: + get_param: left_vn_fqdn + network_policy_entries_policy_rule_src_ports: + - + network_policy_entries_policy_rule_src_ports_end_port: + get_param: src_port_end + network_policy_entries_policy_rule_src_ports_start_port: + get_param: src_port_start + type: "OS::ContrailV2::NetworkPolicy" + template_VirtualNetwork_1: + depends_on: + - template_NetworkIpam_2 + - template_NetworkPolicy + properties: + name: + get_param: left_vn + network_ipam_refs: + - + get_resource: template_NetworkIpam_2 + network_ipam_refs_data: + - + network_ipam_refs_data_ipam_subnets: + - + network_ipam_refs_data_ipam_subnets_addr_from_start: + get_param: network_ipam_refs_data_ipam_subnets_addr_from_start_true + network_ipam_refs_data_ipam_subnets_subnet: + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix: + get_param: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2 + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len: + get_param: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2 + network_policy_refs: [ { list_join: [':', { get_attr: [ template_NetworkPolicy, fq_name ] } ] } ] + network_policy_refs_data: + - + network_policy_refs_data_sequence: + network_policy_refs_data_sequence_major: 0 + network_policy_refs_data_sequence_minor: 0 + type: "OS::ContrailV2::VirtualNetwork" + template_VirtualNetwork_2: + depends_on: + - template_NetworkIpam_2 + - template_NetworkPolicy + properties: + name: + get_param: left_vn + network_ipam_refs: + - + get_resource: template_NetworkIpam_2 + network_ipam_refs_data: + - + network_ipam_refs_data_ipam_subnets: + - + network_ipam_refs_data_ipam_subnets_addr_from_start: + get_param: network_ipam_refs_data_ipam_subnets_addr_from_start_true + network_ipam_refs_data_ipam_subnets_subnet: + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix: + get_param: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2 + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len: + get_param: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2 + network_policy_refs: [ { get_attr: [ template_NetworkPolicy, fq_name ] } ] + network_policy_refs_data: + - + network_policy_refs_data_sequence: + network_policy_refs_data_sequence_major: 0 + network_policy_refs_data_sequence_minor: 0 + type: "OS::ContrailV2::VirtualNetwork" + template_VirtualNetwork_3: + depends_on: + - template_NetworkIpam_2 + - template_NetworkPolicy + properties: + name: + get_param: left_vn + network_ipam_refs: + - + get_resource: template_NetworkIpam_2 + network_ipam_refs_data: + - + network_ipam_refs_data_ipam_subnets: + - + network_ipam_refs_data_ipam_subnets_addr_from_start: + get_param: network_ipam_refs_data_ipam_subnets_addr_from_start_true + network_ipam_refs_data_ipam_subnets_subnet: + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix: + get_param: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2 + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len: + get_param: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2 + network_policy_refs: [ { get_resource: template_NetworkPolicy } ] + network_policy_refs_data: + - + network_policy_refs_data_sequence: + network_policy_refs_data_sequence_major: 0 + network_policy_refs_data_sequence_minor: 0 + type: "OS::ContrailV2::VirtualNetwork" + + Internal-subnet-1: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: template_VirtualNetwork_2 } + cidr: { get_param: Internal1_cidr } + gateway_ip: { get_param: Internal1_default_gateway } + enable_dhcp: { get_param: Internal1_dhcp } + + Internal-subnet-2: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: template_VirtualNetwork_2 } + cidr: { get_param: Internal2_cidr } + gateway_ip: { get_param: Internal2_default_gateway } + enable_dhcp: { get_param: Internal2_dhcp } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/invalid_policy_resource_type/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/invalid_policy_resource_type/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..31bb9db74a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/invalid_policy_resource_type/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,193 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + left_vn_fqdn: + hidden: false + immutable: false + type: string + description: dummy + Internal1_cidr: + hidden: false + immutable: false + type: string + src_port_start: + hidden: false + immutable: false + type: string + description: dummy + Internal1_default_gateway: + hidden: false + immutable: false + type: string + Internal1_dhcp: + hidden: false + immutable: false + type: string + src_port_end: + hidden: false + immutable: false + type: string + description: dummy + policy_name: + hidden: false + immutable: false + type: string + description: dummy + dst_port_end: + hidden: false + immutable: false + type: string + description: dummy + simple_action: + hidden: false + immutable: false + type: string + description: dummy + service_instance_fq_name: + hidden: false + immutable: false + type: string + Internal2_cidr: + hidden: false + immutable: false + type: string + protocol: + hidden: false + immutable: false + type: string + description: dummy + Internal2_dhcp: + hidden: false + immutable: false + type: string + dst_port_start: + hidden: false + immutable: false + type: string + description: dummy + network_ipam_refs_data_ipam_subnets_addr_from_start_true: + hidden: false + immutable: false + type: string + description: dummy + Internal2_default_gateway: + hidden: false + immutable: false + type: string + right_vn_fqdn: + hidden: false + immutable: false + type: string + description: dummy + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2: + hidden: false + immutable: false + type: string + description: dummy + left_vn: + hidden: false + immutable: false + type: string + description: dummy + direction: + hidden: false + immutable: false + type: string + description: dummy + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2: + hidden: false + immutable: false + type: string + description: dummy + node_templates: + template_NetworkPolicy: + type: org.openecomp.resource.vfc.rules.nodes.heat.network.contrail.NetworkRules + properties: + name: + get_input: policy_name + template_VirtualNetwork_2: + type: org.openecomp.resource.vl.nodes.heat.network.contrailV2.VirtualNetwork + properties: + dhcp_enabled: + get_input: Internal1_dhcp + network_ipam_refs_data: + - network_ipam_refs_data_ipam_subnets: + - network_ipam_refs_data_ipam_subnets_subnet: + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len: + get_input: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2 + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix: + get_input: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2 + network_ipam_refs_data_ipam_subnets_addr_from_start: + get_input: network_ipam_refs_data_ipam_subnets_addr_from_start_true + network_policy_refs_data: + - network_policy_refs_data_sequence: + network_policy_refs_data_sequence_major: 0 + network_policy_refs_data_sequence_minor: 0 + network_name: + get_input: left_vn + network_ipam_refs: + - UNSUPPORTED_RESOURCE_template_NetworkIpam_2 + network_policy_refs: + - list_join: + - ':' + - get_attribute: + - template_NetworkPolicy + - fq_name + subnets: + Internal-subnet-1: + enable_dhcp: + get_input: Internal1_dhcp + cidr: + get_input: Internal1_cidr + gateway_ip: + get_input: Internal1_default_gateway + Internal-subnet-2: + enable_dhcp: + get_input: Internal2_dhcp + cidr: + get_input: Internal2_cidr + gateway_ip: + get_input: Internal2_default_gateway + requirements: + - dependency: + capability: tosca.capabilities.Node + node: template_NetworkPolicy + relationship: tosca.relationships.DependsOn + groups: + main: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/main.yml + description: cmaui server template for vMMSC + members: + - template_NetworkPolicy + - template_VirtualNetwork_2 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/invalid_policy_resource_type/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/invalid_policy_resource_type/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..539e26b7ab --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/invalid_policy_resource_type/inputfiles/MANIFEST.json @@ -0,0 +1,12 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "main.yml", + "type": "HEAT", + "isBase": "true" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/invalid_policy_resource_type/inputfiles/main.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/invalid_policy_resource_type/inputfiles/main.yml new file mode 100644 index 0000000000..013b62d42c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/invalid_policy_resource_type/inputfiles/main.yml @@ -0,0 +1,153 @@ +description: "cmaui server template for vMMSC" +heat_template_version: 2013-05-23 +parameters: + Internal1_cidr: + type: string + Internal2_cidr: + type: string + Internal1_default_gateway: + type: string + Internal2_default_gateway: + type: string + Internal1_dhcp: + type: string + Internal2_dhcp: + type: string + direction: + description: dummy + type: string + dst_port_end: + description: dummy + type: string + dst_port_start: + description: dummy + type: string + left_vn: + description: dummy + type: string + left_vn_fqdn: + description: dummy + type: string + network_ipam_refs_data_ipam_subnets_addr_from_start_true: + description: dummy + type: string + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2: + description: dummy + type: string + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2: + description: dummy + type: string + policy_name: + description: dummy + type: string + protocol: + description: dummy + type: string + right_vn_fqdn: + description: dummy + type: string + simple_action: + description: dummy + type: string + src_port_end: + description: dummy + type: string + src_port_start: + description: dummy + type: string + service_instance_fq_name: + type: string +resources: + template_NetworkIpam_2: + properties: + name: + get_param: left_vn + type: "OS::ContrailV2::NetworkIpam" + template_NetworkPolicy: + properties: + name: + get_param: policy_name + network_policy_entries: + network_policy_entries_policy_rule: + - + network_policy_entries_policy_rule_action_list: + network_policy_entries_policy_rule_action_list_apply_service: + - + get_param: service_instance_fq_name + network_policy_entries_policy_rule_action_list_simple_action: + get_param: simple_action + network_policy_entries_policy_rule_direction: + get_param: direction + network_policy_entries_policy_rule_dst_addresses: + - + network_policy_entries_policy_rule_dst_addresses_virtual_network: + get_param: right_vn_fqdn + network_policy_entries_policy_rule_dst_ports: + - + network_policy_entries_policy_rule_dst_ports_end_port: + get_param: dst_port_end + network_policy_entries_policy_rule_dst_ports_start_port: + get_param: dst_port_start + network_policy_entries_policy_rule_protocol: + get_param: protocol + network_policy_entries_policy_rule_src_addresses: + - + network_policy_entries_policy_rule_src_addresses_virtual_network: + get_param: left_vn_fqdn + network_policy_entries_policy_rule_src_ports: + - + network_policy_entries_policy_rule_src_ports_end_port: + get_param: src_port_end + network_policy_entries_policy_rule_src_ports_start_port: + get_param: src_port_start + type: "OS::Contrail::NetworkPolicy" + template_VirtualNetwork_2: + depends_on: + - template_NetworkIpam_2 + - template_NetworkPolicy + properties: + name: + get_param: left_vn + network_ipam_refs: + - + get_resource: template_NetworkIpam_2 + network_ipam_refs_data: + - + network_ipam_refs_data_ipam_subnets: + - + network_ipam_refs_data_ipam_subnets_addr_from_start: + get_param: network_ipam_refs_data_ipam_subnets_addr_from_start_true + network_ipam_refs_data_ipam_subnets_subnet: + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix: + get_param: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2 + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len: + get_param: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2 + network_policy_refs: + - + list_join: + - ":" + - + get_attr: + - template_NetworkPolicy + - fq_name + network_policy_refs_data: + - + network_policy_refs_data_sequence: + network_policy_refs_data_sequence_major: 0 + network_policy_refs_data_sequence_minor: 0 + type: "OS::ContrailV2::VirtualNetwork" + Internal-subnet-1: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: template_VirtualNetwork_2 } + cidr: { get_param: Internal1_cidr } + gateway_ip: { get_param: Internal1_default_gateway } + enable_dhcp: { get_param: Internal1_dhcp } + + Internal-subnet-2: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: template_VirtualNetwork_2 } + cidr: { get_param: Internal2_cidr } + gateway_ip: { get_param: Internal2_default_gateway } + enable_dhcp: { get_param: Internal2_dhcp } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/simple/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/simple/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..3abd06c651 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/simple/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,225 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + left_vn_fqdn: + hidden: false + immutable: false + type: string + description: dummy + Internal1_cidr: + hidden: false + immutable: false + type: string + src_port_start: + hidden: false + immutable: false + type: string + description: dummy + Internal1_default_gateway: + hidden: false + immutable: false + type: string + Internal1_dhcp: + hidden: false + immutable: false + type: string + src_port_end: + hidden: false + immutable: false + type: string + description: dummy + policy_name: + hidden: false + immutable: false + type: string + description: dummy + dst_port_end: + hidden: false + immutable: false + type: string + description: dummy + simple_action: + hidden: false + immutable: false + type: string + description: dummy + service_instance_fq_name: + hidden: false + immutable: false + type: string + Internal2_cidr: + hidden: false + immutable: false + type: string + protocol: + hidden: false + immutable: false + type: string + description: dummy + Internal2_dhcp: + hidden: false + immutable: false + type: string + dst_port_start: + hidden: false + immutable: false + type: string + description: dummy + network_ipam_refs_data_ipam_subnets_addr_from_start_true: + hidden: false + immutable: false + type: string + description: dummy + Internal2_default_gateway: + hidden: false + immutable: false + type: string + right_vn_fqdn: + hidden: false + immutable: false + type: string + description: dummy + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2: + hidden: false + immutable: false + type: string + description: dummy + left_vn: + hidden: false + immutable: false + type: string + description: dummy + direction: + hidden: false + immutable: false + type: string + description: dummy + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2: + hidden: false + immutable: false + type: string + description: dummy + node_templates: + template_NetworkPolicy: + type: org.openecomp.resource.vfc.rules.nodes.heat.network.contrailV2.NetworkRules + properties: + name: + get_input: policy_name + network_policy_entries: + network_policy_entries_policy_rule: + - network_policy_entries_policy_rule_dst_addresses: + - network_policy_entries_policy_rule_dst_addresses_virtual_network: + get_input: right_vn_fqdn + network_policy_entries_policy_rule_dst_ports: + - network_policy_entries_policy_rule_dst_ports_start_port: + get_input: dst_port_start + network_policy_entries_policy_rule_dst_ports_end_port: + get_input: dst_port_end + network_policy_entries_policy_rule_protocol: + get_input: protocol + network_policy_entries_policy_rule_src_addresses: + - network_policy_entries_policy_rule_src_addresses_virtual_network: + get_input: left_vn_fqdn + network_policy_entries_policy_rule_direction: + get_input: direction + network_policy_entries_policy_rule_src_ports: + - network_policy_entries_policy_rule_src_ports_start_port: + get_input: src_port_start + network_policy_entries_policy_rule_src_ports_end_port: + get_input: src_port_end + network_policy_entries_policy_rule_action_list: + network_policy_entries_policy_rule_action_list_simple_action: + get_input: simple_action + network_policy_entries_policy_rule_action_list_apply_service: + - get_input: service_instance_fq_name + requirements: + - network: + capability: tosca.capabilities.Attachment + node: template_VirtualNetwork_2 + relationship: org.openecomp.relationships.AttachesTo + template_VirtualNetwork_2: + type: org.openecomp.resource.vl.nodes.heat.network.contrailV2.VirtualNetwork + properties: + dhcp_enabled: + get_input: Internal1_dhcp + network_ipam_refs_data: + - network_ipam_refs_data_ipam_subnets: + - network_ipam_refs_data_ipam_subnets_subnet: + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len: + get_input: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2 + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix: + get_input: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2 + network_ipam_refs_data_ipam_subnets_addr_from_start: + get_input: network_ipam_refs_data_ipam_subnets_addr_from_start_true + network_policy_refs_data: + - network_policy_refs_data_sequence: + network_policy_refs_data_sequence_major: 0 + network_policy_refs_data_sequence_minor: 0 + network_name: + get_input: left_vn + network_ipam_refs: + - UNSUPPORTED_RESOURCE_template_NetworkIpam_2 + network_policy_refs: + - list_join: + - ':' + - get_attribute: + - template_NetworkPolicy + - fq_name + subnets: + Internal-subnet-1: + enable_dhcp: + get_input: Internal1_dhcp + cidr: + get_input: Internal1_cidr + gateway_ip: + get_input: Internal1_default_gateway + Internal-subnet-2: + enable_dhcp: + get_input: Internal2_dhcp + cidr: + get_input: Internal2_cidr + gateway_ip: + get_input: Internal2_default_gateway + requirements: + - dependency: + capability: tosca.capabilities.Node + node: template_NetworkPolicy + relationship: tosca.relationships.DependsOn + groups: + main: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/main.yml + description: cmaui server template for vMMSC + members: + - template_NetworkPolicy + - template_VirtualNetwork_2 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/simple/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/simple/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..539e26b7ab --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/simple/inputfiles/MANIFEST.json @@ -0,0 +1,12 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "main.yml", + "type": "HEAT", + "isBase": "true" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/simple/inputfiles/main.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/simple/inputfiles/main.yml new file mode 100644 index 0000000000..b14811e8e0 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/ContrailV2_translation/simple/inputfiles/main.yml @@ -0,0 +1,153 @@ +description: "cmaui server template for vMMSC" +heat_template_version: 2013-05-23 +parameters: + Internal1_cidr: + type: string + Internal2_cidr: + type: string + Internal1_default_gateway: + type: string + Internal2_default_gateway: + type: string + Internal1_dhcp: + type: string + Internal2_dhcp: + type: string + direction: + description: dummy + type: string + dst_port_end: + description: dummy + type: string + dst_port_start: + description: dummy + type: string + left_vn: + description: dummy + type: string + left_vn_fqdn: + description: dummy + type: string + network_ipam_refs_data_ipam_subnets_addr_from_start_true: + description: dummy + type: string + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2: + description: dummy + type: string + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2: + description: dummy + type: string + policy_name: + description: dummy + type: string + protocol: + description: dummy + type: string + right_vn_fqdn: + description: dummy + type: string + simple_action: + description: dummy + type: string + src_port_end: + description: dummy + type: string + src_port_start: + description: dummy + type: string + service_instance_fq_name: + type: string +resources: + template_NetworkIpam_2: + properties: + name: + get_param: left_vn + type: "OS::ContrailV2::NetworkIpam" + template_NetworkPolicy: + properties: + name: + get_param: policy_name + network_policy_entries: + network_policy_entries_policy_rule: + - + network_policy_entries_policy_rule_action_list: + network_policy_entries_policy_rule_action_list_apply_service: + - + get_param: service_instance_fq_name + network_policy_entries_policy_rule_action_list_simple_action: + get_param: simple_action + network_policy_entries_policy_rule_direction: + get_param: direction + network_policy_entries_policy_rule_dst_addresses: + - + network_policy_entries_policy_rule_dst_addresses_virtual_network: + get_param: right_vn_fqdn + network_policy_entries_policy_rule_dst_ports: + - + network_policy_entries_policy_rule_dst_ports_end_port: + get_param: dst_port_end + network_policy_entries_policy_rule_dst_ports_start_port: + get_param: dst_port_start + network_policy_entries_policy_rule_protocol: + get_param: protocol + network_policy_entries_policy_rule_src_addresses: + - + network_policy_entries_policy_rule_src_addresses_virtual_network: + get_param: left_vn_fqdn + network_policy_entries_policy_rule_src_ports: + - + network_policy_entries_policy_rule_src_ports_end_port: + get_param: src_port_end + network_policy_entries_policy_rule_src_ports_start_port: + get_param: src_port_start + type: "OS::ContrailV2::NetworkPolicy" + template_VirtualNetwork_2: + depends_on: + - template_NetworkIpam_2 + - template_NetworkPolicy + properties: + name: + get_param: left_vn + network_ipam_refs: + - + get_resource: template_NetworkIpam_2 + network_ipam_refs_data: + - + network_ipam_refs_data_ipam_subnets: + - + network_ipam_refs_data_ipam_subnets_addr_from_start: + get_param: network_ipam_refs_data_ipam_subnets_addr_from_start_true + network_ipam_refs_data_ipam_subnets_subnet: + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix: + get_param: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2 + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len: + get_param: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2 + network_policy_refs: + - + list_join: + - ":" + - + get_attr: + - template_NetworkPolicy + - fq_name + network_policy_refs_data: + - + network_policy_refs_data_sequence: + network_policy_refs_data_sequence_major: 0 + network_policy_refs_data_sequence_minor: 0 + type: "OS::ContrailV2::VirtualNetwork" + Internal-subnet-1: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: template_VirtualNetwork_2 } + cidr: { get_param: Internal1_cidr } + gateway_ip: { get_param: Internal1_default_gateway } + enable_dhcp: { get_param: Internal1_dhcp } + + Internal-subnet-2: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: template_VirtualNetwork_2 } + cidr: { get_param: Internal2_cidr } + gateway_ip: { get_param: Internal2_default_gateway } + enable_dhcp: { get_param: Internal2_dhcp } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/multi/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/multi/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..9b25041540 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/multi/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,190 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p1: + hidden: false + immutable: false + type: string + description: UID of OAM network + template_PortTuple_LB1: + hidden: false + immutable: false + type: string + oam_sec_group_name: + hidden: false + immutable: false + type: string + lb_st_interface_type_oam: + hidden: false + immutable: false + type: string + security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + shared_network_id: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + jsa_net_name: + hidden: false + immutable: false + type: string + description: network name of jsa log network + shared_network_id1: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + cmaui_oam_ips: + hidden: false + immutable: false + type: string + node_templates: + template_VMInt_OAM_lb_1: + type: org.openecomp.resource.cp.nodes.heat.contrailV2.VirtualMachineInterface + properties: + security_group_refs: + - get_input: oam_sec_group_name + virtual_network_refs: + - get_input: shared_network_id + virtual_machine_interface_properties: + virtual_machine_interface_properties_service_interface_type: + get_input: lb_st_interface_type_oam + port_tuple_refs: + - get_input: template_PortTuple_LB1 + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: test_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + template_VMInt_OAM_lb_2: + type: org.openecomp.resource.cp.nodes.heat.contrailV2.VirtualMachineInterface + properties: + security_group_refs: + - get_input: oam_sec_group_name + virtual_network_refs: + - get_input: shared_network_id + - get_input: shared_network_id1 + virtual_machine_interface_properties: + virtual_machine_interface_properties_service_interface_type: + get_input: lb_st_interface_type_oam + port_tuple_refs: + - get_input: template_PortTuple_LB1 + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: test_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + test_net1: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + shared: true + network_name: + get_input: jsa_net_name + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + contrail_service_instance_ind: true + name: + get_input: + - cmaui_names + - 0 + test_net: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + shared: true + network_name: + get_input: jsa_net_name + groups: + addOn: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/addOn.yml + description: cmaui server template for vMMSC + members: + - template_VMInt_OAM_lb_1 + - template_VMInt_OAM_lb_2 + - server_cmaui + main: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/main.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - test_net1 + - test_net \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/multi/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/multi/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..1f762d0ccc --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/multi/inputfiles/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "main.yml", + "type": "HEAT", + "isBase": "true" + }, + { + "file": "addOn.yml", + "type": "HEAT", + "isBase": "false" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/multi/inputfiles/addOn.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/multi/inputfiles/addOn.yml new file mode 100644 index 0000000000..4894cfa44c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/multi/inputfiles/addOn.yml @@ -0,0 +1,72 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + p1: + type: string + description: UID of OAM network + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + security_group_name: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + cmaui_flavor: + type: string + description: Flavor for CMAUI server + shared_network_id: + type: string + description: Flavor for CMAUI server + shared_network_id1: + type: string + description: Flavor for CMAUI server + cmaui_oam_ips: + type: string + oam_sec_group_name: + type: string + lb_st_interface_type_oam: + type: string + template_PortTuple_LB1: + type: string + +resources: + template_VMInt_OAM_lb_1: + type: OS::ContrailV2::VirtualMachineInterface + properties: + virtual_machine_interface_properties: + { + virtual_machine_interface_properties_service_interface_type: { get_param: lb_st_interface_type_oam }, + } + virtual_network_refs: [{ get_param: shared_network_id }] + port_tuple_refs: [{ get_param: template_PortTuple_LB1 }] + security_group_refs: [{ get_param: oam_sec_group_name}] + + template_VMInt_OAM_lb_2: + type: OS::ContrailV2::VirtualMachineInterface + properties: + virtual_machine_interface_properties: + { + virtual_machine_interface_properties_service_interface_type: { get_param: lb_st_interface_type_oam }, + } + virtual_network_refs: [{ get_param: shared_network_id }, { get_param: shared_network_id1 }] + port_tuple_refs: [{ get_param: template_PortTuple_LB1 }] + security_group_refs: [{ get_param: oam_sec_group_name}] + + server_cmaui: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: template_VMInt_OAM_lb_1 } + - port: { get_resource: template_VMInt_OAM_lb_2 } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/multi/inputfiles/main.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/multi/inputfiles/main.yml new file mode 100644 index 0000000000..3bd60fc93e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/multi/inputfiles/main.yml @@ -0,0 +1,28 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + jsa_net_name: + type: string + description: network name of jsa log network + +resources: + test_net: + type: OS::Neutron::Net + properties: + name: {get_param: jsa_net_name} + shared: True + + test_net1: + type: OS::Neutron::Net + properties: + name: {get_param: jsa_net_name} + shared: True + +outputs: + shared_network_id: + value: {get_resource: test_net} + shared_network_id1: + value: {get_resource: test_net1} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/nested/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/nested/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..7b58dd24e0 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/nested/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,117 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.nested: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + cmaui_names: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p1: + type: string + description: UID of OAM network + p2: + type: string + description: UID of OAM network + cmaui_image: + type: string + description: Image for CMAUI server + template_PortTuple_LB1: + type: string + cmaui_flavor: + type: string + description: Flavor for CMAUI server + oam_sec_group_name: + type: string + lb_st_interface_type_oam: + type: string + security_group_name: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + availability_zone_0: + type: string + description: availabilityzone name + cmaui_oam_ips: + type: string + requirements: + - link_template_VMInt_OAM_lb_1: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_template_VMInt_OAM_lb_2: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - local_storage_server_cmaui: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + capabilities: + host_server_cmaui: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + os_server_cmaui: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + endpoint_server_cmaui: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + binding_server_cmaui: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + scalable_server_cmaui: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/nested/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/nested/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..623325a944 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/nested/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,81 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + jsa_net_name: + hidden: false + immutable: false + type: string + description: network name of jsa log network + node_templates: + test_net1: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + shared: true + network_name: + get_input: jsa_net_name + test_net: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + shared: true + network_name: + get_input: jsa_net_name + test_nested: + type: org.openecomp.resource.abstract.nodes.heat.nested + directives: + - substitutable + properties: + p1: test_net + service_template_filter: + substitute_service_template: nestedServiceTemplate.yaml + p2: test_net1 + requirements: + - link_template_VMInt_OAM_lb_1: + capability: tosca.capabilities.network.Linkable + node: test_net + relationship: tosca.relationships.network.LinksTo + - link_template_VMInt_OAM_lb_2: + capability: tosca.capabilities.network.Linkable + node: test_net + relationship: tosca.relationships.network.LinksTo + groups: + main: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/main.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - test_net1 + - test_net + - test_nested \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/nested/expectedoutputfiles/nestedServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/nested/expectedoutputfiles/nestedServiceTemplate.yaml new file mode 100644 index 0000000000..4484578db6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/nested/expectedoutputfiles/nestedServiceTemplate.yaml @@ -0,0 +1,181 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p1: + hidden: false + immutable: false + type: string + description: UID of OAM network + p2: + hidden: false + immutable: false + type: string + description: UID of OAM network + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + template_PortTuple_LB1: + hidden: false + immutable: false + type: string + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + oam_sec_group_name: + hidden: false + immutable: false + type: string + lb_st_interface_type_oam: + hidden: false + immutable: false + type: string + security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + cmaui_oam_ips: + hidden: false + immutable: false + type: string + node_templates: + template_VMInt_OAM_lb_1: + type: org.openecomp.resource.cp.nodes.heat.contrailV2.VirtualMachineInterface + properties: + security_group_refs: + - get_input: oam_sec_group_name + virtual_network_refs: + - get_input: p1 + virtual_machine_interface_properties: + virtual_machine_interface_properties_service_interface_type: + get_input: lb_st_interface_type_oam + port_tuple_refs: + - get_input: template_PortTuple_LB1 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + template_VMInt_OAM_lb_2: + type: org.openecomp.resource.cp.nodes.heat.contrailV2.VirtualMachineInterface + properties: + security_group_refs: + - get_input: oam_sec_group_name + virtual_network_refs: + - get_input: p1 + - get_input: p2 + virtual_machine_interface_properties: + virtual_machine_interface_properties_service_interface_type: + get_input: lb_st_interface_type_oam + port_tuple_refs: + - get_input: template_PortTuple_LB1 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + contrail_service_instance_ind: true + name: + get_input: + - cmaui_names + - 0 + groups: + nested: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested.yml + description: cmaui server template for vMMSC + members: + - template_VMInt_OAM_lb_1 + - template_VMInt_OAM_lb_2 + - server_cmaui + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested + capabilities: + host_server_cmaui: + - server_cmaui + - host + os_server_cmaui: + - server_cmaui + - os + endpoint_server_cmaui: + - server_cmaui + - endpoint + binding_server_cmaui: + - server_cmaui + - binding + scalable_server_cmaui: + - server_cmaui + - scalable + requirements: + link_template_VMInt_OAM_lb_1: + - template_VMInt_OAM_lb_1 + - link + local_storage_server_cmaui: + - server_cmaui + - local_storage + link_template_VMInt_OAM_lb_2: + - template_VMInt_OAM_lb_2 + - link \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/nested/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/nested/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..aca75b5055 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/nested/inputfiles/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "main.yml", + "type": "HEAT", + "isBase": "true" + }, + { + "file": "nested.yml", + "type": "HEAT", + "isBase": "false" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/nested/inputfiles/main.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/nested/inputfiles/main.yml new file mode 100644 index 0000000000..e68f16ec29 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/nested/inputfiles/main.yml @@ -0,0 +1,27 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + jsa_net_name: + type: string + description: network name of jsa log network + +resources: + test_net: + type: OS::Neutron::Net + properties: + name: {get_param: jsa_net_name} + shared: True + test_net1: + type: OS::Neutron::Net + properties: + name: {get_param: jsa_net_name} + shared: True + + test_nested: + type: nested.yml + properties: + p1: { get_resource: test_net} + p2: { get_resource: test_net1} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/nested/inputfiles/nested.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/nested/inputfiles/nested.yml new file mode 100644 index 0000000000..c8d8857d08 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/nested/inputfiles/nested.yml @@ -0,0 +1,68 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + p1: + type: string + description: UID of OAM network + p2: + type: string + description: UID of OAM network + security_group_name: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_oam_ips: + type: string + oam_sec_group_name: + type: string + lb_st_interface_type_oam: + type: string + template_PortTuple_LB1: + type: string +resources: + template_VMInt_OAM_lb_1: + type: OS::ContrailV2::VirtualMachineInterface + properties: + virtual_machine_interface_properties: + { + virtual_machine_interface_properties_service_interface_type: { get_param: lb_st_interface_type_oam }, + } + virtual_network_refs: [{ get_param: p1 }] + port_tuple_refs: [{ get_param: template_PortTuple_LB1 }] + security_group_refs: [{ get_param: oam_sec_group_name}] + + template_VMInt_OAM_lb_2: + type: OS::ContrailV2::VirtualMachineInterface + properties: + virtual_machine_interface_properties: + { + virtual_machine_interface_properties_service_interface_type: { get_param: lb_st_interface_type_oam }, + } + virtual_network_refs: [{ get_param: p1 },{ get_param: p2 }] + port_tuple_refs: [{ get_param: template_PortTuple_LB1 }] + security_group_refs: [{ get_param: oam_sec_group_name}] + + server_cmaui: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: template_VMInt_OAM_lb_1 } + - port: { get_resource: template_VMInt_OAM_lb_2 } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..f0124b6d68 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,254 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.nested1: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + cmaui_names: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p2: + type: string + description: UID of OAM network + abc_flavor: + type: string + description: Flavor for CMAUI server + template_PortTuple_LB1: + type: string + oam_sec_group_name: + type: string + lb_st_interface_type_oam: + type: string + abc_names: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + security_group_name: + description: not impotrtant + shared_network_id1: + type: string + description: UID of OAM network + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + availability_zone_0: + type: string + description: availabilityzone name + abc_oam_ips: + type: string + cmaui_oam_ips: + type: string + abc_image: + type: string + description: Image for CMAUI server + requirements: + - link_template_VMInt_OAM_lb_1: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_template_VMInt_OAM_lb_2: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_template_VMInt_OAM_lb_3: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - local_storage_server_cmaui: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - local_storage_server_abc: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_abc_port_1: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + scalable_server_abc: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + host_server_cmaui: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + os_server_cmaui: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + binding_server_abc: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + endpoint_server_cmaui: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + attachment_abc_port_1: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + binding_server_cmaui: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + endpoint_server_abc: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + scalable_server_cmaui: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + host_server_abc: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + os_server_abc: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + org.openecomp.resource.abstract.nodes.heat.nested2: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + cmaui_names: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p1: + type: string + description: UID of OAM network + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + security_group_name: + description: not impotrtant + availability_zone_0: + type: string + description: availabilityzone name + abc_oam_ips: + type: string + cmaui_oam_ips: + type: string + requirements: + - local_storage_server_cmaui: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_cmaui_port_1: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + host_server_cmaui: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + os_server_cmaui: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + endpoint_server_cmaui: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + binding_server_cmaui: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + scalable_server_cmaui: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_1: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..c5d68ff070 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,152 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + shared_network_id1: + hidden: false + immutable: false + type: string + description: network name of jsa log network + shared_network_id2: + hidden: false + immutable: false + type: string + description: network name of jsa log network + jsa_net_name: + hidden: false + immutable: false + type: string + description: network name of jsa log network + node_templates: + test_net2: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + shared: true + network_name: + get_input: jsa_net_name + test_nested2: + type: org.openecomp.resource.abstract.nodes.heat.nested2 + directives: + - substitutable + properties: + p1: + get_input: shared_network_id1 + service_template_filter: + substitute_service_template: nested2ServiceTemplate.yaml + requirements: + - link_cmaui_port_1: + capability: tosca.capabilities.network.Linkable + node: test_net1 + relationship: tosca.relationships.network.LinksTo + test_nested3: + type: org.openecomp.resource.abstract.nodes.heat.nested1 + directives: + - substitutable + properties: + service_template_filter: + substitute_service_template: nested1ServiceTemplate.yaml + shared_network_id1: + get_input: shared_network_id1 + p2: + get_input: shared_network_id2 + requirements: + - link_abc_port_1: + capability: tosca.capabilities.network.Linkable + node: test_net2 + relationship: tosca.relationships.network.LinksTo + - link_template_VMInt_OAM_lb_1: + capability: tosca.capabilities.network.Linkable + node: test_net1 + relationship: tosca.relationships.network.LinksTo + - link_template_VMInt_OAM_lb_2: + capability: tosca.capabilities.network.Linkable + node: test_net2 + relationship: tosca.relationships.network.LinksTo + - link_template_VMInt_OAM_lb_3: + capability: tosca.capabilities.network.Linkable + node: test_net2 + relationship: tosca.relationships.network.LinksTo + test_net1: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + shared: true + network_name: + get_input: jsa_net_name + test_nested1: + type: org.openecomp.resource.abstract.nodes.heat.nested1 + directives: + - substitutable + properties: + service_template_filter: + substitute_service_template: nested1ServiceTemplate.yaml + shared_network_id1: + get_input: shared_network_id1 + p2: + get_input: shared_network_id2 + requirements: + - link_abc_port_1: + capability: tosca.capabilities.network.Linkable + node: test_net2 + relationship: tosca.relationships.network.LinksTo + - link_template_VMInt_OAM_lb_1: + capability: tosca.capabilities.network.Linkable + node: test_net1 + relationship: tosca.relationships.network.LinksTo + - link_template_VMInt_OAM_lb_2: + capability: tosca.capabilities.network.Linkable + node: test_net2 + relationship: tosca.relationships.network.LinksTo + - link_template_VMInt_OAM_lb_3: + capability: tosca.capabilities.network.Linkable + node: test_net2 + relationship: tosca.relationships.network.LinksTo + groups: + addOn: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/addOn.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - test_nested2 + - test_nested3 + - test_nested1 + main: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/main.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - test_net2 + - test_net1 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/expectedoutputfiles/nested1ServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/expectedoutputfiles/nested1ServiceTemplate.yaml new file mode 100644 index 0000000000..a10ccc2e1a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/expectedoutputfiles/nested1ServiceTemplate.yaml @@ -0,0 +1,279 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested1 +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.abc: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p2: + hidden: false + immutable: false + type: string + description: UID of OAM network + abc_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + template_PortTuple_LB1: + hidden: false + immutable: false + type: string + oam_sec_group_name: + hidden: false + immutable: false + type: string + lb_st_interface_type_oam: + hidden: false + immutable: false + type: string + abc_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + security_group_name: + hidden: false + immutable: false + description: not impotrtant + shared_network_id1: + hidden: false + immutable: false + type: string + description: UID of OAM network + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + abc_oam_ips: + hidden: false + immutable: false + type: string + cmaui_oam_ips: + hidden: false + immutable: false + type: string + abc_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + node_templates: + template_VMInt_OAM_lb_1: + type: org.openecomp.resource.cp.nodes.heat.contrailV2.VirtualMachineInterface + properties: + security_group_refs: + - get_input: oam_sec_group_name + virtual_network_refs: + - get_input: shared_network_id1 + virtual_machine_interface_properties: + virtual_machine_interface_properties_service_interface_type: + get_input: lb_st_interface_type_oam + port_tuple_refs: + - get_input: template_PortTuple_LB1 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + template_VMInt_OAM_lb_2: + type: org.openecomp.resource.cp.nodes.heat.contrailV2.VirtualMachineInterface + properties: + security_group_refs: + - get_input: oam_sec_group_name + virtual_network_refs: + - get_input: p2 + virtual_machine_interface_properties: + virtual_machine_interface_properties_service_interface_type: + get_input: lb_st_interface_type_oam + port_tuple_refs: + - get_input: template_PortTuple_LB1 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + template_VMInt_OAM_lb_3: + type: org.openecomp.resource.cp.nodes.heat.contrailV2.VirtualMachineInterface + properties: + security_group_refs: + - get_input: oam_sec_group_name + virtual_network_refs: + - get_input: p2 + - get_input: shared_network_id1 + virtual_machine_interface_properties: + virtual_machine_interface_properties_service_interface_type: + get_input: lb_st_interface_type_oam + port_tuple_refs: + - get_input: template_PortTuple_LB1 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + contrail_service_instance_ind: true + name: + get_input: + - cmaui_names + - 0 + server_abc: + type: org.openecomp.resource.vfc.nodes.heat.abc + properties: + flavor: + get_input: abc_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: abc_image + name: + get_input: + - abc_names + - 0 + abc_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - abc_oam_ips + - 0 + network: + get_input: p2 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_abc + relationship: tosca.relationships.network.BindsTo + groups: + nested1: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested1.yml + description: cmaui server template for vMMSC + members: + - template_VMInt_OAM_lb_1 + - template_VMInt_OAM_lb_2 + - template_VMInt_OAM_lb_3 + - server_cmaui + - server_abc + - abc_port_1 + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested1 + capabilities: + scalable_server_abc: + - server_abc + - scalable + host_server_cmaui: + - server_cmaui + - host + os_server_cmaui: + - server_cmaui + - os + binding_server_abc: + - server_abc + - binding + endpoint_server_cmaui: + - server_cmaui + - endpoint + attachment_abc_port_1: + - abc_port_1 + - attachment + binding_server_cmaui: + - server_cmaui + - binding + endpoint_server_abc: + - server_abc + - endpoint + scalable_server_cmaui: + - server_cmaui + - scalable + host_server_abc: + - server_abc + - host + os_server_abc: + - server_abc + - os + requirements: + link_template_VMInt_OAM_lb_1: + - template_VMInt_OAM_lb_1 + - link + local_storage_server_cmaui: + - server_cmaui + - local_storage + link_template_VMInt_OAM_lb_3: + - template_VMInt_OAM_lb_3 + - link + link_template_VMInt_OAM_lb_2: + - template_VMInt_OAM_lb_2 + - link + link_abc_port_1: + - abc_port_1 + - link + local_storage_server_abc: + - server_abc + - local_storage \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/expectedoutputfiles/nested2ServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/expectedoutputfiles/nested2ServiceTemplate.yaml new file mode 100644 index 0000000000..992e1c017c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/expectedoutputfiles/nested2ServiceTemplate.yaml @@ -0,0 +1,146 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested2 +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p1: + hidden: false + immutable: false + type: string + description: UID of OAM network + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + security_group_name: + hidden: false + immutable: false + description: not impotrtant + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + abc_oam_ips: + hidden: false + immutable: false + type: string + cmaui_oam_ips: + hidden: false + immutable: false + type: string + node_templates: + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + name: + get_input: + - cmaui_names + - 0 + cmaui_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: p1 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + groups: + nested2: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested2.yml + description: cmaui server template for vMMSC + members: + - server_cmaui + - cmaui_port_1 + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested2 + capabilities: + host_server_cmaui: + - server_cmaui + - host + os_server_cmaui: + - server_cmaui + - os + endpoint_server_cmaui: + - server_cmaui + - endpoint + binding_server_cmaui: + - server_cmaui + - binding + scalable_server_cmaui: + - server_cmaui + - scalable + attachment_cmaui_port_1: + - cmaui_port_1 + - attachment + requirements: + local_storage_server_cmaui: + - server_cmaui + - local_storage + link_cmaui_port_1: + - cmaui_port_1 + - link \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..e593097c44 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/inputfiles/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "main.yml", + "type": "HEAT", + "isBase": "true" + }, + { + "file": "nested1.yml", + "type": "HEAT", + "isBase": "false" + }, + { + "file": "nested2.yml", + "type": "HEAT", + "isBase": "false" + }, + { + "file": "addOn.yml", + "type": "HEAT", + "isBase": "false" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/inputfiles/addOn.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/inputfiles/addOn.yml new file mode 100644 index 0000000000..507bfcaa08 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/inputfiles/addOn.yml @@ -0,0 +1,32 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + shared_network_id1: + type: string + description: network name of jsa log network + + shared_network_id2: + type: string + description: network name of jsa log network + +resources: + + test_nested1: + type: nested1.yml + properties: + shared_network_id1: { get_param: shared_network_id1} + p2: { get_param: shared_network_id2} + + test_nested2: + type: nested2.yml + properties: + p1: { get_param: shared_network_id1} + + test_nested3: + type: nested1.yml + properties: + shared_network_id1: { get_param: shared_network_id1} + p2: { get_param: shared_network_id2} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/inputfiles/main.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/inputfiles/main.yml new file mode 100644 index 0000000000..9601c0f86d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/inputfiles/main.yml @@ -0,0 +1,29 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + jsa_net_name: + type: string + description: network name of jsa log network + +resources: + test_net1: + type: OS::Neutron::Net + properties: + name: {get_param: jsa_net_name} + shared: True + + test_net2: + type: OS::Neutron::Net + properties: + name: {get_param: jsa_net_name} + shared: True + +outputs: + shared_network_id1: + value: {get_resource: test_net1} + + shared_network_id2: + value: {get_resource: test_net2} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/inputfiles/nested1.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/inputfiles/nested1.yml new file mode 100644 index 0000000000..ab65fc9718 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/inputfiles/nested1.yml @@ -0,0 +1,110 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + shared_network_id1: + type: string + description: UID of OAM network + p2: + type: string + description: UID of OAM network + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + abc_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + security_group_name: + type: not_important + description: not impotrtant + cmaui_image: + type: string + description: Image for CMAUI server + abc_image: + type: string + description: Image for CMAUI server + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + cmaui_flavor: + type: string + description: Flavor for CMAUI server + abc_flavor: + type: string + description: Flavor for CMAUI server + cmaui_oam_ips: + type: string + abc_oam_ips: + type: string + oam_sec_group_name: + type: string + lb_st_interface_type_oam: + type: string + template_PortTuple_LB1: + type: string +resources: + + template_VMInt_OAM_lb_1: + type: OS::ContrailV2::VirtualMachineInterface + properties: + virtual_machine_interface_properties: + { + virtual_machine_interface_properties_service_interface_type: { get_param: lb_st_interface_type_oam }, + } + virtual_network_refs: [{ get_param: shared_network_id1 }] + port_tuple_refs: [{ get_param: template_PortTuple_LB1 }] + security_group_refs: [{ get_param: oam_sec_group_name}] + + template_VMInt_OAM_lb_2: + type: OS::ContrailV2::VirtualMachineInterface + properties: + virtual_machine_interface_properties: + { + virtual_machine_interface_properties_service_interface_type: { get_param: lb_st_interface_type_oam }, + } + virtual_network_refs: [{ get_param: p2 }] + port_tuple_refs: [{ get_param: template_PortTuple_LB1 }] + security_group_refs: [{ get_param: oam_sec_group_name}] + + template_VMInt_OAM_lb_3: + type: OS::ContrailV2::VirtualMachineInterface + properties: + virtual_machine_interface_properties: + { + virtual_machine_interface_properties_service_interface_type: { get_param: lb_st_interface_type_oam }, + } + virtual_network_refs: [{ get_param: p2 },{ get_param: shared_network_id1 }] + port_tuple_refs: [{ get_param: template_PortTuple_LB1 }] + security_group_refs: [{ get_param: oam_sec_group_name}] + + abc_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: p2 } + fixed_ips: [{"ip_address": {get_param: [abc_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_cmaui: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: template_VMInt_OAM_lb_1 } + - port: { get_resource: template_VMInt_OAM_lb_2 } + - port: { get_resource: template_VMInt_OAM_lb_3 } + + server_abc: + type: OS::Nova::Server + properties: + name: { get_param: [abc_names, 0]} + image: { get_param: abc_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: abc_flavor } + networks: + - port: { get_resource: abc_port_1 } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/inputfiles/nested2.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/inputfiles/nested2.yml new file mode 100644 index 0000000000..b09d3aff8e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/inputfiles/nested2.yml @@ -0,0 +1,48 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + p1: + type: string + description: UID of OAM network + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + security_group_name: + type: not_important + description: not impotrtant + cmaui_image: + type: string + description: Image for CMAUI server + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_oam_ips: + type: string + abc_oam_ips: + type: string + +resources: + + cmaui_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: p1 } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_cmaui: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_1 } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/baseResourceTranslation/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/baseResourceTranslation/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..983a71f3b7 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/baseResourceTranslation/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,215 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + cmaui_cinder_volume_size: + label: CMAUI Cinder volume size + hidden: false + immutable: false + type: float + description: the size of the CMAUI Cinder volume + timezone: + label: timezone + hidden: false + immutable: false + type: string + description: timezone + security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + oam_network_netmask: + label: oam network netmask + hidden: false + immutable: false + type: string + description: oam network gateway + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + vnf_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-CMAUI_id + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + oam_network_gateway: + label: oam network gateway + hidden: false + immutable: false + type: string + description: oam network gateway + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + cmaui_oam_ips: + label: CMAUI oam_net IP addresses + hidden: false + immutable: false + type: list + description: CMAUI oam_net IP addresses + entry_schema: + type: string + external_dns: + label: dns server + hidden: false + immutable: false + type: string + description: dns server + oam_net_name: + hidden: false + immutable: false + type: string + description: UID of OAM network + external_ntp: + label: ntp server + hidden: false + immutable: false + type: string + description: ntp server + CMAUI_volume_type: + label: CMAUI vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + node_templates: + server_dependOnString: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + name: + get_input: + - cmaui_names + - 0 + requirements: + - dependency: + capability: tosca.capabilities.Node + node: cmaui_volume + relationship: tosca.relationships.DependsOn + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + metadata: + vnf_id: + get_input: vnf_id + user_data_format: RAW + name: + get_input: + - cmaui_names + - 0 + requirements: + - dependency: + capability: tosca.capabilities.Node + node: cmaui_volume + relationship: tosca.relationships.DependsOn + - dependency: + capability: tosca.capabilities.Node + node: cmaui_port_0 + relationship: tosca.relationships.DependsOn + - local_storage: + capability: tosca.capabilities.Attachment + node: cmaui_volume + relationship: cmaui_volume_attachment + cmaui_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: CMAUI_volume_type + size: '(get_input : cmaui_cinder_volume_size) * 1024' + cmaui_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + relationship_templates: + cmaui_volume_attachment: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: cmaui_volume + instance_uuid: server_cmaui + groups: + hot_template: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/hot_template.yml + description: cmaui server template for vMMSC + members: + - server_dependOnString + - server_cmaui + - cmaui_volume + - cmaui_port_0 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/baseResourceTranslation/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/baseResourceTranslation/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..b2916ccf9c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/baseResourceTranslation/inputfiles/MANIFEST.json @@ -0,0 +1,11 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "hot_template.yml", + "type": "HEAT" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/baseResourceTranslation/inputfiles/hot_template.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/baseResourceTranslation/inputfiles/hot_template.yml new file mode 100644 index 0000000000..a3e343b033 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/baseResourceTranslation/inputfiles/hot_template.yml @@ -0,0 +1,131 @@ +heat_template_version: 2013-05-23 + +################################# +# +# Changes from MSO 01/26/2016 +# Updated per ECOMP feedback +# +################################# + +description: cmaui server template for vMMSC + +parameters: + vnf_id: + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-CMAUI_id + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_cinder_volume_size: + type: number + label: CMAUI Cinder volume size + description: the size of the CMAUI Cinder volume + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + oam_net_name: + type: string + description: UID of OAM network + oam_network_netmask: + type: string + label: oam network netmask + description: oam network gateway + oam_network_gateway: + type: string + label: oam network gateway + description: oam network gateway + external_dns: + type: string + label: dns server + description: dns server + external_ntp: + type: string + label: ntp server + description: ntp server + security_group_name: + type: string + label: security group name + description: the name of security group + timezone: + type: string + label: timezone + description: timezone + cmaui_oam_ips: + type: comma_delimited_list + label: CMAUI oam_net IP addresses + description: CMAUI oam_net IP addresses + CMAUI_volume_type: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + +resources: + + cmaui_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + cmaui_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: cmaui_cinder_volume_size} + volume_type: {get_param: CMAUI_volume_type} + + cmaui_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: cmaui_volume} + instance_uuid: {get_resource: server_cmaui} + + server_cmaui: + type: OS::Nova::Server + depends_on: [ cmaui_volume,cmaui_port_0] + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_0 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + cmaui.mgmt.ip=${cmaui.mgmt.ip} + cmaui.mgmt.netmask=${cmaui.mgmt.netmask} + cmaui.mgmt.gateway=${cmaui.mgmt.gateway} + cmaui.external.dns=${cmaui.external.dns} + cmaui.external.ntp=${cmaui.external.ntp} + cmaui.node=${cmaui.node} + cmaui.timezone=${cmaui.timezone} + params: + ${cmaui.mgmt.ip}: {get_param: [cmaui_oam_ips, 0]} + ${cmaui.mgmt.netmask}: {get_param: oam_network_netmask} + ${cmaui.mgmt.gateway}: {get_param: oam_network_gateway} + ${cmaui.external.dns}: {get_param: external_dns} + ${cmaui.external.ntp}: {get_param: external_ntp} + ${cmaui.node}: {get_param: [cmaui_names, 0]} + ${cmaui.timezone}: {get_param: timezone} + user_data_format: RAW + + server_dependOnString: + type: OS::Nova::Server + depends_on: cmaui_volume + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/cinder_volume_translation/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/cinder_volume_translation/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..fcd6db6103 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/cinder_volume_translation/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,131 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + volume_type: + label: volume type + hidden: false + immutable: false + type: string + description: volume type Gold + FSB1_volume_name: + label: FSB1_volume + hidden: false + immutable: false + type: string + description: FSB1_volume_1 + FSB_1_image: + label: MME_FSB1 + hidden: false + immutable: false + type: string + description: MME_FSB1_15B-CP04-r5a01 + volume_size: + label: volume size + hidden: false + immutable: false + type: float + description: my volume size 320GB + stam: + label: stam + hidden: false + immutable: false + type: float + description: stam + FSB_2_image: + label: MME_FSB2 + hidden: false + immutable: false + type: string + description: MME_FSB2_15B-CP04-r5a01 + FSB2_volume_name: + label: FSB2_volume + hidden: false + immutable: false + type: string + description: FSB2_volume_1 + node_templates: + FSB1_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + image: + get_input: FSB_1_image + volume_type: + get_input: volume_type + size: 3*1024 + read_only: + get_input: stam + name: + get_input: FSB1_volume_name + FSB2_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + image: + get_input: FSB_2_image + volume_type: + get_input: volume_type + size: '(get_input : volume_size) * 1024' + read_only: true + name: + get_input: FSB2_volume_name + FSB3_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + image: + get_input: FSB_1_image + volume_type: + get_input: volume_type + size: 3*1024 + read_only: true + name: + get_input: FSB1_volume_name + FSB4_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + image: + get_input: FSB_2_image + volume_type: + get_input: volume_type + size: '(get_input : volume_size) * 1024' + read_only: true + name: + get_input: FSB2_volume_name + groups: + hot_template: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/hot_template.yml + description: server template for vMME + members: + - FSB1_volume + - FSB2_volume + - FSB3_volume + - FSB4_volume \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/cinder_volume_translation/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/cinder_volume_translation/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..70cdc7d237 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/cinder_volume_translation/inputfiles/MANIFEST.json @@ -0,0 +1,11 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volumes", + "version": "2013-05-23", + "data": [ + { + "file": "hot_template.yml", + "type": "HEAT" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/cinder_volume_translation/inputfiles/hot_template.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/cinder_volume_translation/inputfiles/hot_template.yml new file mode 100644 index 0000000000..c1c6ebdc30 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/cinder_volume_translation/inputfiles/hot_template.yml @@ -0,0 +1,79 @@ +heat_template_version: 2013-05-23 + +description: server template for vMME + +parameters: + + volume_type: + type: string + label: volume type + description: volume type Gold + + volume_size: + type: number + label: volume size + description: my volume size 320GB + + FSB_1_image: + type: string + label: MME_FSB1 + description: MME_FSB1_15B-CP04-r5a01 + + FSB_2_image: + type: string + label: MME_FSB2 + description: MME_FSB2_15B-CP04-r5a01 + + FSB1_volume_name: + type: string + label: FSB1_volume + description: FSB1_volume_1 + + FSB2_volume_name: + type: string + label: FSB2_volume + description: FSB2_volume_1 + + stam: + type: number + label: stam + description: stam + +resources: + + FSB1_volume: + type: OS::Cinder::Volume + properties: + size: 3 + volume_type: {get_param: volume_type} + name: {get_param: FSB1_volume_name} + image: {get_param: FSB_1_image} + read_only: {get_param: stam} + + FSB2_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: volume_size} + volume_type: {get_param: volume_type} + name: {get_param: FSB2_volume_name} + image: {get_param: FSB_2_image} + read_only: 1 + + FSB3_volume: + type: OS::Cinder::Volume + properties: + size: 3 + volume_type: {get_param: volume_type} + name: {get_param: FSB1_volume_name} + image: {get_param: FSB_1_image} + read_only: t + + FSB4_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: volume_size} + volume_type: {get_param: volume_type} + name: {get_param: FSB2_volume_name} + image: {get_param: FSB_2_image} + read_only: true + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/diffServiceTemplate/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/diffServiceTemplate/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..d5a177bddb --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/diffServiceTemplate/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,83 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.compute_service_template_1: + derived_from: org.openecomp.resource.vfc.nodes.heat.contrail.Compute + org.openecomp.resource.abstract.nodes.heat.service_template_2: + derived_from: org.openecomp.resource.abstract.nodes.contrail.AbstractSubstitute + requirements: + - link_port_0: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_port_1: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + org.openecomp.resource.abstract.nodes.heat.service_template_1: + derived_from: org.openecomp.resource.abstract.nodes.contrail.AbstractSubstitute + requirements: + - link_port_0: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_port_1: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_port_2: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_port_3: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + org.openecomp.resource.vfc.nodes.heat.st: + derived_from: org.openecomp.resource.vfc.nodes.heat.contrail.Compute \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/diffServiceTemplate/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/diffServiceTemplate/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..a96c947d9d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/diffServiceTemplate/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,401 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + service_policy_name: + hidden: false + immutable: false + type: string + description: Policy Name + st_static_routes_list: + hidden: false + immutable: false + type: string + description: List of static routes enabled-disabled + st_type: + hidden: false + immutable: false + type: string + description: service type + st_service_interface_type_list: + hidden: false + immutable: false + type: string + description: List of interface types + st_mode: + hidden: false + immutable: false + type: string + description: service mode + Cricket_OCS_protected_net_id: + hidden: false + immutable: false + type: string + description: Name of Cricket OCS network + oam_mgmt_net_0_id: + hidden: false + immutable: false + type: string + description: Name of OAM network + start_dst_ports: + hidden: false + immutable: false + type: float + description: Start of dst port + st_flavor: + hidden: false + immutable: false + type: string + description: Flavor + availability_zone_1: + hidden: false + immutable: false + type: string + description: availability zone + service_instance_name: + hidden: false + immutable: false + type: string + description: Service instance name + st_scaling: + hidden: false + immutable: false + type: string + description: Indicates whether service scaling is enabled + max_num_fw_instances: + hidden: false + immutable: false + type: float + description: maximum number of firewall instances for scaling + start_src_ports: + hidden: false + immutable: false + type: float + description: Start of src port + service_policy_direction: + hidden: false + immutable: false + type: string + description: Direction of Policy + st_name: + hidden: false + immutable: false + type: string + description: Name of service template + count: + hidden: false + immutable: false + HSL_direct_net_gateway: + hidden: false + immutable: false + type: string + description: HSL (Logging) network gateway address + st_image: + hidden: false + immutable: false + type: string + description: Name of the image + st_shared_ip_list: + hidden: false + immutable: false + type: string + description: List of shared ip enabled-disabled + prefix_0: + hidden: false + immutable: false + type: string + Cricket_OCS_direct_net_id: + hidden: false + immutable: false + type: string + description: Name of Cricket OCS network + oam_mgmt_net_1_id: + hidden: false + immutable: false + type: string + description: Name of OAM network + prefix_1: + hidden: false + immutable: false + type: string + end_src_ports: + hidden: false + immutable: false + type: float + description: End of src port + prefix_2: + hidden: false + immutable: false + type: string + end_dst_ports: + hidden: false + immutable: false + type: float + description: End of dst port + st_image_name: + hidden: false + immutable: false + type: string + description: Name of the image + HSL_direct_net_id: + hidden: false + immutable: false + type: string + description: Name of HSL (Logging) network + HSL_direct_net_cidr: + hidden: false + immutable: false + type: string + description: HSL (Logging) network address (CIDR notation) + node_templates: + service_instance_1: + type: org.openecomp.resource.abstract.nodes.heat.service_template_1 + directives: + - substitutable + properties: + flavor: + get_input: st_flavor + availability_zone: + get_input: availability_zone_1 + image_name: + get_input: st_image + service_template_filter: + substitute_service_template: service_instance_1ServiceTemplate.yaml + count: + get_input: max_num_fw_instances + scaling_enabled: false + mandatory: false + service_type: + get_input: st_type + static_routes_list: + - token: + - get_input: st_static_routes_list + - ',' + - 0 + - token: + - get_input: st_static_routes_list + - ',' + - 1 + - token: + - get_input: st_static_routes_list + - ',' + - 2 + - token: + - get_input: st_static_routes_list + - ',' + - 3 + service_template_name: + get_input: st_name + service_interface_type_list: + - token: + - management,left,right,other + - ',' + - 0 + - token: + - management,left,right,other + - ',' + - 1 + - token: + - management,left,right,other + - ',' + - 2 + - token: + - management,left,right,other + - ',' + - 3 + interface_list: + - virtual_network: + get_input: oam_mgmt_net_0_id + - virtual_network: + get_input: Cricket_OCS_direct_net_id + - virtual_network: hsl_direct_net + - static_routes: + - prefix: + get_input: prefix_0 + - prefix: + get_input: prefix_1 + - prefix: + get_input: prefix_2 + virtual_network: + get_input: oam_mgmt_net_1_id + service_instance_name: + get_input: service_instance_name + service_mode: + get_input: st_mode + shared_ip_list: + - token: + - get_input: st_shared_ip_list + - ',' + - 0 + - token: + - get_input: st_shared_ip_list + - ',' + - 1 + - token: + - get_input: st_shared_ip_list + - ',' + - 2 + - token: + - get_input: st_shared_ip_list + - ',' + - 3 + requirements: + - link_port_2: + capability: tosca.capabilities.network.Linkable + node: hsl_direct_net + relationship: tosca.relationships.network.LinksTo + - dependency: + capability: tosca.capabilities.Node + node: hsl_direct_net + relationship: tosca.relationships.DependsOn + service_instance_2: + type: org.openecomp.resource.abstract.nodes.heat.service_template_2 + directives: + - substitutable + properties: + flavor: + get_input: st_flavor + availability_zone: + get_input: availability_zone_1 + image_name: + get_input: st_image_name + service_template_filter: + substitute_service_template: service_instance_2ServiceTemplate.yaml + count: 9 + mandatory: true + service_type: + get_input: st_type + static_routes_list: + - token: + - get_input: st_static_routes_list + - ',' + - 0 + - token: + - get_input: st_static_routes_list + - ',' + - 1 + service_template_name: + get_input: st_name + service_interface_type_list: + - token: + - get_input: st_service_interface_type_list + - ',' + - 0 + - token: + - get_input: st_service_interface_type_list + - ',' + - 1 + interface_list: + - virtual_network: + get_input: oam_mgmt_net_0_id + - virtual_network: + get_input: Cricket_OCS_direct_net_id + service_instance_name: + get_input: service_instance_name + service_mode: + get_input: st_mode + shared_ip_list: + - token: + - get_input: st_shared_ip_list + - ',' + - 0 + - token: + - get_input: st_shared_ip_list + - ',' + - 1 + requirements: + - dependency: + capability: tosca.capabilities.Node + node: hsl_direct_net + relationship: tosca.relationships.DependsOn + hsl_direct_net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + network_name: + get_input: HSL_direct_net_id + subnets: + hsl_ip_subnet: + cidr: + get_input: HSL_direct_net_cidr + gateway_ip: + get_input: HSL_direct_net_gateway + service_policy: + type: org.openecomp.resource.vfc.rules.nodes.heat.network.contrail.NetworkRules + properties: + entries: + policy_rule: + - src_ports: + - start_port: + get_input: start_src_ports + end_port: + get_input: end_src_ports + protocol: any + metadata: + get_attribute: + - service_instance_2 + - service_instance_name + action_list: + apply_service: + - service_instance_1 + dst_addresses: + - virtual_network: + get_input: Cricket_OCS_direct_net_id + dst_ports: + - start_port: + get_input: start_dst_ports + end_port: + get_input: end_dst_ports + src_addresses: + - virtual_network: + get_input: Cricket_OCS_protected_net_id + direction: + get_input: service_policy_direction + name: + get_input: service_policy_name + requirements: + - dependency: + capability: tosca.capabilities.Node + node: service_instance_1 + relationship: tosca.relationships.DependsOn + groups: + OCS-fw: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/OCS-fw.yml + description: | + Based on the following reference for the HOT-DMZ-FW template: Version 3.5 8-10-2015 (Authors: Art Mishurov,am254u & Johhny Chen, jc3066) - HOT-DMZ-FW template that creates two DMZ networks (direct and protected) with a scaled out firewall service between the two. + members: + - service_instance_1 + - service_instance_2 + - hsl_direct_net + - service_policy \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/diffServiceTemplate/expectedoutputfiles/service_instance_1ServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/diffServiceTemplate/expectedoutputfiles/service_instance_1ServiceTemplate.yaml new file mode 100644 index 0000000000..d84d6c6889 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/diffServiceTemplate/expectedoutputfiles/service_instance_1ServiceTemplate.yaml @@ -0,0 +1,407 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: service_instance_1 +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + availability_zone: + hidden: false + immutable: false + type: string + description: Availability zone to create servers in + required: false + status: SUPPORTED + static_routes_list: + hidden: false + immutable: false + type: list + description: Static routes enabled + required: false + status: SUPPORTED + entry_schema: + type: boolean + availability_zone_enable: + hidden: false + immutable: false + type: boolean + description: Indicates availability zone is enabled + required: false + default: false + status: SUPPORTED + service_template_name: + hidden: false + immutable: false + type: string + description: Service template name + required: false + status: SUPPORTED + ordered_interfaces: + hidden: false + immutable: false + type: boolean + description: Indicates if service interface are ordered + required: false + default: false + status: SUPPORTED + flavor: + hidden: false + immutable: false + type: string + description: flavor + required: false + status: SUPPORTED + image_name: + hidden: false + immutable: false + type: string + description: Image name + required: true + status: SUPPORTED + service_type: + hidden: false + immutable: false + type: string + description: Service type + required: true + status: SUPPORTED + constraints: + - valid_values: + - firewall + - analyzer + - source-nat + - loadbalancer + service_interface_type_list: + hidden: false + immutable: false + type: list + description: List of interface types + required: true + status: SUPPORTED + entry_schema: + type: string + constraints: + - valid_values: + - management + - left + - right + - other + service_instance_name: + hidden: false + immutable: false + type: string + description: Service instance name + required: true + status: SUPPORTED + interface_list: + hidden: false + immutable: false + type: list + description: List of interfaces + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.contrail.InterfaceData + service_mode: + hidden: false + immutable: false + type: string + description: Service mode + required: true + status: SUPPORTED + constraints: + - valid_values: + - transparent + - in-network + - in-network-nat + shared_ip_list: + hidden: false + immutable: false + type: list + description: Shared ips enabled + required: false + status: SUPPORTED + entry_schema: + type: boolean + node_templates: + service_instance_1: + type: org.openecomp.resource.vfc.nodes.heat.compute_service_template_1 + properties: + flavor: + get_input: flavor + image_name: + get_input: image_name + availability_zone: + get_input: availability_zone + service_type: + get_input: service_type + availability_zone_enable: + get_input: availability_zone_enable + service_template_name: + get_input: service_template_name + service_instance_name: + get_input: service_instance_name + service_mode: + get_input: service_mode + port_0: + type: org.openecomp.resource.cp.nodes.heat.network.contrail.Port + properties: + static_routes: + get_input: + - interface_list + - 0 + - static_routes + virtual_network: + get_input: + - interface_list + - 0 + - virtual_network + static_route: + get_input: + - static_routes_list + - 0 + allowed_address_pairs: + get_input: + - interface_list + - 0 + - allowed_address_pairs + shared_ip: + get_input: + - shared_ip_list + - 0 + ip_address: + get_input: + - interface_list + - 0 + - ip_address + interface_type: + get_input: + - service_interface_type_list + - 0 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: service_instance_1 + relationship: tosca.relationships.network.BindsTo + port_1: + type: org.openecomp.resource.cp.nodes.heat.network.contrail.Port + properties: + static_routes: + get_input: + - interface_list + - 1 + - static_routes + virtual_network: + get_input: + - interface_list + - 1 + - virtual_network + static_route: + get_input: + - static_routes_list + - 1 + allowed_address_pairs: + get_input: + - interface_list + - 1 + - allowed_address_pairs + shared_ip: + get_input: + - shared_ip_list + - 1 + ip_address: + get_input: + - interface_list + - 1 + - ip_address + interface_type: + get_input: + - service_interface_type_list + - 1 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: service_instance_1 + relationship: tosca.relationships.network.BindsTo + port_2: + type: org.openecomp.resource.cp.nodes.heat.network.contrail.Port + properties: + static_routes: + get_input: + - interface_list + - 2 + - static_routes + virtual_network: + get_input: + - interface_list + - 2 + - virtual_network + static_route: + get_input: + - static_routes_list + - 2 + allowed_address_pairs: + get_input: + - interface_list + - 2 + - allowed_address_pairs + shared_ip: + get_input: + - shared_ip_list + - 2 + ip_address: + get_input: + - interface_list + - 2 + - ip_address + interface_type: + get_input: + - service_interface_type_list + - 2 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: service_instance_1 + relationship: tosca.relationships.network.BindsTo + port_3: + type: org.openecomp.resource.cp.nodes.heat.network.contrail.Port + properties: + static_routes: + get_input: + - interface_list + - 3 + - static_routes + virtual_network: + get_input: + - interface_list + - 3 + - virtual_network + static_route: + get_input: + - static_routes_list + - 3 + allowed_address_pairs: + get_input: + - interface_list + - 3 + - allowed_address_pairs + shared_ip: + get_input: + - shared_ip_list + - 3 + ip_address: + get_input: + - interface_list + - 3 + - ip_address + interface_type: + get_input: + - service_interface_type_list + - 3 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: service_instance_1 + relationship: tosca.relationships.network.BindsTo + groups: + service_instance_1: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/OCS-fw.yml + members: + - service_instance_1 + - port_0 + - port_1 + - port_2 + - port_3 + outputs: + tenant_id: + description: Tenant id of the Service Instance + value: + get_attribute: + - service_instance_1 + - tenant_id + fq_name: + description: The FQ name of the service instance + value: + get_attribute: + - service_instance_1 + - fq_name + service_template_name: + description: Service Template of the Service Instance + value: + get_attribute: + - service_instance_1 + - service_template_name + show: + description: All attributes + value: + get_attribute: + - service_instance_1 + - show + active_vms: + description: Number of service VMs active for this Service Instance + value: + get_attribute: + - service_instance_1 + - active_vms + service_instance_name: + description: The name of the service instance + value: + get_attribute: + - service_instance_1 + - service_instance_name + virtual_machines: + description: Service VMs for the Service Instance + value: + get_attribute: + - service_instance_1 + - virtual_machines + status: + description: Status of the service instance + value: + get_attribute: + - service_instance_1 + - status + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.service_template_1 + requirements: + link_port_0: + - port_0 + - link + link_port_1: + - port_1 + - link + link_port_2: + - port_2 + - link + link_port_3: + - port_3 + - link \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/diffServiceTemplate/expectedoutputfiles/service_instance_2ServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/diffServiceTemplate/expectedoutputfiles/service_instance_2ServiceTemplate.yaml new file mode 100644 index 0000000000..3a2de0696f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/diffServiceTemplate/expectedoutputfiles/service_instance_2ServiceTemplate.yaml @@ -0,0 +1,319 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: service_instance_2 +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + availability_zone: + hidden: false + immutable: false + type: string + description: Availability zone to create servers in + required: false + status: SUPPORTED + static_routes_list: + hidden: false + immutable: false + type: list + description: Static routes enabled + required: false + status: SUPPORTED + entry_schema: + type: boolean + availability_zone_enable: + hidden: false + immutable: false + type: boolean + description: Indicates availability zone is enabled + required: false + default: false + status: SUPPORTED + service_template_name: + hidden: false + immutable: false + type: string + description: Service template name + required: false + status: SUPPORTED + ordered_interfaces: + hidden: false + immutable: false + type: boolean + description: Indicates if service interface are ordered + required: false + default: false + status: SUPPORTED + flavor: + hidden: false + immutable: false + type: string + description: flavor + required: false + status: SUPPORTED + image_name: + hidden: false + immutable: false + type: string + description: Image name + required: true + status: SUPPORTED + service_type: + hidden: false + immutable: false + type: string + description: Service type + required: true + status: SUPPORTED + constraints: + - valid_values: + - firewall + - analyzer + - source-nat + - loadbalancer + service_interface_type_list: + hidden: false + immutable: false + type: list + description: List of interface types + required: true + status: SUPPORTED + entry_schema: + type: string + constraints: + - valid_values: + - management + - left + - right + - other + service_instance_name: + hidden: false + immutable: false + type: string + description: Service instance name + required: true + status: SUPPORTED + interface_list: + hidden: false + immutable: false + type: list + description: List of interfaces + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.contrail.InterfaceData + service_mode: + hidden: false + immutable: false + type: string + description: Service mode + required: true + status: SUPPORTED + constraints: + - valid_values: + - transparent + - in-network + - in-network-nat + shared_ip_list: + hidden: false + immutable: false + type: list + description: Shared ips enabled + required: false + status: SUPPORTED + entry_schema: + type: boolean + node_templates: + service_instance_2: + type: org.openecomp.resource.vfc.nodes.heat.st + properties: + flavor: + get_input: flavor + image_name: + get_input: image_name + availability_zone: + get_input: availability_zone + service_type: + get_input: service_type + availability_zone_enable: + get_input: availability_zone_enable + service_template_name: + get_input: service_template_name + service_instance_name: + get_input: service_instance_name + service_mode: + get_input: service_mode + port_0: + type: org.openecomp.resource.cp.nodes.heat.network.contrail.Port + properties: + static_routes: + get_input: + - interface_list + - 0 + - static_routes + virtual_network: + get_input: + - interface_list + - 0 + - virtual_network + static_route: + get_input: + - static_routes_list + - 0 + allowed_address_pairs: + get_input: + - interface_list + - 0 + - allowed_address_pairs + shared_ip: + get_input: + - shared_ip_list + - 0 + ip_address: + get_input: + - interface_list + - 0 + - ip_address + interface_type: + get_input: + - service_interface_type_list + - 0 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: service_instance_2 + relationship: tosca.relationships.network.BindsTo + port_1: + type: org.openecomp.resource.cp.nodes.heat.network.contrail.Port + properties: + static_routes: + get_input: + - interface_list + - 1 + - static_routes + virtual_network: + get_input: + - interface_list + - 1 + - virtual_network + static_route: + get_input: + - static_routes_list + - 1 + allowed_address_pairs: + get_input: + - interface_list + - 1 + - allowed_address_pairs + shared_ip: + get_input: + - shared_ip_list + - 1 + ip_address: + get_input: + - interface_list + - 1 + - ip_address + interface_type: + get_input: + - service_interface_type_list + - 1 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: service_instance_2 + relationship: tosca.relationships.network.BindsTo + groups: + service_instance_2: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/OCS-fw.yml + members: + - service_instance_2 + - port_0 + - port_1 + outputs: + tenant_id: + description: Tenant id of the Service Instance + value: + get_attribute: + - service_instance_2 + - tenant_id + fq_name: + description: The FQ name of the service instance + value: + get_attribute: + - service_instance_2 + - fq_name + service_template_name: + description: Service Template of the Service Instance + value: + get_attribute: + - service_instance_2 + - service_template_name + show: + description: All attributes + value: + get_attribute: + - service_instance_2 + - show + active_vms: + description: Number of service VMs active for this Service Instance + value: + get_attribute: + - service_instance_2 + - active_vms + service_instance_name: + description: The name of the service instance + value: + get_attribute: + - service_instance_2 + - service_instance_name + virtual_machines: + description: Service VMs for the Service Instance + value: + get_attribute: + - service_instance_2 + - virtual_machines + status: + description: Status of the service instance + value: + get_attribute: + - service_instance_2 + - status + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.service_template_2 + requirements: + link_port_0: + - port_0 + - link + link_port_1: + - port_1 + - link \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/diffServiceTemplate/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/diffServiceTemplate/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..a26430ba72 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/diffServiceTemplate/inputfiles/MANIFEST.json @@ -0,0 +1,12 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "OCS-fw.yml", + "type": "HEAT", + "isBase": "false" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/diffServiceTemplate/inputfiles/OCS-fw.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/diffServiceTemplate/inputfiles/OCS-fw.yml new file mode 100644 index 0000000000..725ba49459 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/diffServiceTemplate/inputfiles/OCS-fw.yml @@ -0,0 +1,213 @@ +heat_template_version: 2013-05-23 + +description: > + Based on the following reference for the HOT-DMZ-FW template: + Version 3.5 8-10-2015 (Authors: Art Mishurov,am254u & Johhny Chen, jc3066) - HOT-DMZ-FW template that creates two DMZ networks (direct and protected) with a scaled out firewall service between the two. + +parameters: + HSL_direct_net_id: + type: string + description: Name of HSL (Logging) network + prefix_0: + type: string + prefix_1: + type: string + prefix_2: + type: string + HSL_direct_net_cidr: + type: string + description: HSL (Logging) network address (CIDR notation) + HSL_direct_net_gateway: + type: string + description: HSL (Logging) network gateway address + oam_mgmt_net_0_id: + type: string + description: Name of OAM network + oam_mgmt_net_1_id: + type: string + description: Name of OAM network + Cricket_OCS_direct_net_id: + type: string + description: Name of Cricket OCS network + Cricket_OCS_protected_net_id: + type: string + description: Name of Cricket OCS network + service_instance_name: + type: string + description: Service instance name + service_policy_name: + type: string + description: Policy Name + service_policy_direction: + type: string + description: Direction of Policy + start_src_ports: + type: number + description: Start of src port + end_src_ports: + type: number + description: End of src port + start_dst_ports: + type: number + description: Start of dst port + end_dst_ports: + type: number + description: End of dst port + st_name: + type: string + description: Name of service template + st_mode: + type: string + description: service mode + st_type: + type: string + description: service type + st_image: + type: string + description: Name of the image + st_image_name: + type: string + description: Name of the image + st_flavor: + type: string + description: Flavor + st_service_interface_type_list: + type: string + description: List of interface types + st_shared_ip_list: + type: string + description: List of shared ip enabled-disabled + st_static_routes_list: + type: string + description: List of static routes enabled-disabled + st_scaling: + type: string + description: Indicates whether service scaling is enabled + max_num_fw_instances: + type: number + description: maximum number of firewall instances for scaling + availability_zone_1: + type: string + description: availability zone + count: + type: integer + +resources: + + hsl_direct_net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: HSL_direct_net_id } +# external: True + + hsl_ip_subnet: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: hsl_direct_net } + cidr: { get_param: HSL_direct_net_cidr } + gateway_ip: { get_param: HSL_direct_net_gateway } + + service_template_1: + type: OS::Contrail::ServiceTemplate + properties: + name: { get_param: st_name } + service_mode: { get_param: st_mode } + service_type: { get_param: st_type } + image_name: { get_param: st_image } + flavor: { get_param: st_flavor } + service_interface_type_list: { "Fn::Split" : [ ",", "management,left,right,other" ] } + shared_ip_list: { "Fn::Split" : [ ",", Ref: st_shared_ip_list ] } + static_routes_list: { "Fn::Split" : [ ",", Ref: st_static_routes_list ] } + service_scaling: n + + service_instance_1: + type: OS::Contrail::ServiceInstance + depends_on: [ hsl_ip_subnet] + properties: + name: { get_param: service_instance_name } + availability_zone: { get_param: availability_zone_1 } + service_template: { get_resource: service_template_1 } + scale_out: + max_instances: {get_param: max_num_fw_instances} + interface_list: [ + { + virtual_network: { get_param: oam_mgmt_net_0_id } + }, + { + virtual_network: { get_param: Cricket_OCS_direct_net_id } + }, + { + virtual_network: { get_resource: hsl_direct_net } + }, + { + virtual_network: {get_param: oam_mgmt_net_1_id}, + static_routes: [ + { "prefix": {get_param: prefix_0} }, + { "prefix": {get_param: prefix_1} }, + { "prefix": {get_param: prefix_2} }, + ], + } + ] + + service_template_2: + type: OS::Contrail::ServiceTemplate + properties: + name: { get_param: st_name } + service_mode: { get_param: st_mode } + service_type: { get_param: st_type } + image_name: { get_param: st_image_name } + flavor: { get_param: st_flavor } + service_interface_type_list: { "Fn::Split" : [ ",", Ref: st_service_interface_type_list ] } + shared_ip_list: { "Fn::Split" : [ ",", Ref: st_shared_ip_list ] } + static_routes_list: { "Fn::Split" : [ ",", Ref: st_static_routes_list ] } + + service_instance_2: + type: OS::Contrail::ServiceInstance + depends_on: [ hsl_ip_subnet] + properties: + name: { get_param: service_instance_name } + availability_zone: { get_param: availability_zone_1 } + service_template: { get_resource: service_template_2 } + scale_out: + max_instances: 9 + interface_list: [ + { + virtual_network: { get_param: oam_mgmt_net_0_id } + }, + { + virtual_network: { get_param: Cricket_OCS_direct_net_id } + } + ] + + service_policy: + type: OS::Contrail::NetworkPolicy + depends_on: [ service_instance_1 ] + properties: + name: { get_param: service_policy_name } + entries: + policy_rule: [ + { + "direction": { get_param: service_policy_direction }, + "protocol": "any", + "src_ports": [{"start_port": {get_param: start_src_ports}, "end_port": {get_param: end_src_ports}}], + "dst_ports": [{"start_port": {get_param: start_dst_ports}, "end_port": {get_param: end_dst_ports}}], + "dst_addresses": [{ "virtual_network": { get_param: Cricket_OCS_direct_net_id }}], + "action_list": { "apply_service": [{ get_resource: service_instance_1 }]}, + "src_addresses": [{ "virtual_network": { get_param: Cricket_OCS_protected_net_id }}], + "metadata": {get_attr: [service_instance_2, name]} + }, + ] + + service_policy_attach_direct_net: + type: OS::Contrail::AttachPolicy + depends_on: [ service_policy ] + properties: + network: { get_param: Cricket_OCS_direct_net_id } + policy: { get_attr: [service_policy, fq_name] } + + service_policy_attach_protected_net: + type: OS::Contrail::AttachPolicy + depends_on: [ service_policy ] + properties: + network: { get_param: Cricket_OCS_protected_net_id } + policy: { get_attr: [service_policy, fq_name] } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/oneServiceInstance/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/oneServiceInstance/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..b00d3d8bc0 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/oneServiceInstance/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,64 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.service_template: + derived_from: org.openecomp.resource.abstract.nodes.contrail.AbstractSubstitute + requirements: + - link_port_0: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_port_1: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_port_2: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_port_3: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + org.openecomp.resource.vfc.nodes.heat.compute_service_template: + derived_from: org.openecomp.resource.vfc.nodes.heat.contrail.Compute \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/oneServiceInstance/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/oneServiceInstance/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..016e4d3f70 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/oneServiceInstance/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,300 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + protected_net: + hidden: false + immutable: false + type: string + service_policy_name: + hidden: false + immutable: false + type: string + description: Policy Name + default: MNS-25180-L-02Shared_policy_direct_fw_protected_oam_1 + oam_direct_net_id: + hidden: false + immutable: false + type: string + description: Name of private network to be created + st_static_routes_list: + hidden: false + immutable: false + type: string + description: List of static routes enabled-disabled + default: True,True,True,True + st_type: + hidden: false + immutable: false + type: string + description: service type + default: firewall + st_service_interface_type_list: + hidden: false + immutable: false + type: string + description: List of interface types + default: management,left,right,other + oam_protected_net_id: + hidden: false + immutable: false + type: string + description: Name of private network to be created + st_mode: + hidden: false + immutable: false + type: string + description: service mode + default: in-network-nat + static_prefix_3_1: + hidden: false + immutable: false + type: string + description: prefix for static route + default: 107.239.80.0/21 + oam_hsl_net_id: + hidden: false + immutable: false + type: string + description: Name of private network to be created + start_dst_ports: + hidden: false + immutable: false + type: float + description: Start of dst port + default: -1 + st_flavor: + hidden: false + immutable: false + type: string + description: Flavor + default: lc.medium + st_scaling: + hidden: false + immutable: false + type: string + description: Indicates whether service scaling is enabled + default: 'True' + service_instance_name: + hidden: false + immutable: false + type: string + description: service instance name + max_num_fw_instances: + hidden: false + immutable: false + type: float + description: maximum number of firewall instances for scaling + default: 8 + start_src_ports: + hidden: false + immutable: false + type: float + description: Start of src port + default: -1 + availability_zone: + hidden: false + immutable: false + type: string + description: availability zone in form of Zone:Host + service_policy_direction: + hidden: false + immutable: false + type: string + description: Direction of Policy + default: <> + st_name: + hidden: false + immutable: false + type: string + description: service template name or ID + default: MNS-25180-L-02Shared_oam_fw_template_1 + st_availability_zone_enable_flag: + hidden: false + immutable: false + type: string + description: service template availablity_zone feature enable flag + default: 'True' + st_image: + hidden: false + immutable: false + type: string + description: Name of the image + default: NIMBUS_SRX_151X49-D303 + st_shared_ip_list: + hidden: false + immutable: false + type: string + description: List of shared ip enabled-disabled + default: False,True,False,False + oam_mgmt_net_id: + hidden: false + immutable: false + type: string + description: Name of private network to be created + end_src_ports: + hidden: false + immutable: false + type: float + description: End of src port + default: -1 + end_dst_ports: + hidden: false + immutable: false + type: float + description: End of dst port + default: -1 + node_templates: + service_instance: + type: org.openecomp.resource.abstract.nodes.heat.service_template + directives: + - substitutable + properties: + availability_zone: + get_input: availability_zone + static_routes_list: + - token: + - false;false;false;false + - ; + - 0 + - token: + - false;false;false;false + - ; + - 1 + - token: + - false;false;false;false + - ; + - 2 + - token: + - false;false;false;false + - ; + - 3 + availability_zone_enable: + get_input: st_availability_zone_enable_flag + service_template_name: + get_input: st_name + ordered_interfaces: true + flavor: + get_input: st_flavor + image_name: + get_input: st_image + service_template_filter: + substitute_service_template: service_instanceServiceTemplate.yaml + count: 5 + scaling_enabled: + get_input: st_scaling + mandatory: true + service_type: + get_input: st_type + service_interface_type_list: + - token: + - get_input: st_service_interface_type_list + - ',' + - 0 + - token: + - get_input: st_service_interface_type_list + - ',' + - 1 + - token: + - get_input: st_service_interface_type_list + - ',' + - 2 + - token: + - get_input: st_service_interface_type_list + - ',' + - 3 + interface_list: + - virtual_network: + get_input: oam_mgmt_net_id + - virtual_network: + get_input: oam_protected_net_id + - static_routes: + - prefix: + get_input: static_prefix_3_1 + virtual_network: + get_input: oam_direct_net_id + - virtual_network: + get_input: oam_hsl_net_id + service_instance_name: + get_input: service_instance_name + service_mode: + get_input: st_mode + shared_ip_list: + - true + - true + - false + - false + service_policy: + type: org.openecomp.resource.vfc.rules.nodes.heat.network.contrail.NetworkRules + properties: + entries: + policy_rule: + - src_ports: + - start_port: + get_input: start_src_ports + end_port: + get_input: end_src_ports + protocol: any + action_list: + apply_service: + - service_instance + dst_addresses: + - virtual_network: + get_input: oam_direct_net_id + dst_ports: + - start_port: + get_input: start_dst_ports + end_port: + get_input: end_dst_ports + src_addresses: + - virtual_network: + get_input: protected_net + direction: + get_input: service_policy_direction + name: + get_input: service_policy_name + requirements: + - dependency: + capability: tosca.capabilities.Node + node: service_instance + relationship: tosca.relationships.DependsOn + groups: + lcp1_mss.oam-fw_si: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/lcp1_mss.oam-fw_si.yaml + description: | + Version 2.0 10-14-2015 (Authors: Art Mishurov,am254u & Johhny Chen, jc3066) - HOT-OAM-FW-SI template that creates two OAM networks (direct and protected) with a scaled out firewall service between the two. + members: + - service_instance + - service_policy \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/oneServiceInstance/expectedoutputfiles/service_instanceServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/oneServiceInstance/expectedoutputfiles/service_instanceServiceTemplate.yaml new file mode 100644 index 0000000000..e9f2511604 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/oneServiceInstance/expectedoutputfiles/service_instanceServiceTemplate.yaml @@ -0,0 +1,411 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: service_instance +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + availability_zone: + hidden: false + immutable: false + type: string + description: Availability zone to create servers in + required: false + status: SUPPORTED + static_routes_list: + hidden: false + immutable: false + type: list + description: Static routes enabled + required: false + status: SUPPORTED + entry_schema: + type: boolean + availability_zone_enable: + hidden: false + immutable: false + type: boolean + description: Indicates availability zone is enabled + required: false + default: false + status: SUPPORTED + service_template_name: + hidden: false + immutable: false + type: string + description: Service template name + required: false + status: SUPPORTED + ordered_interfaces: + hidden: false + immutable: false + type: boolean + description: Indicates if service interface are ordered + required: false + default: false + status: SUPPORTED + flavor: + hidden: false + immutable: false + type: string + description: flavor + required: false + status: SUPPORTED + image_name: + hidden: false + immutable: false + type: string + description: Image name + required: true + status: SUPPORTED + service_type: + hidden: false + immutable: false + type: string + description: Service type + required: true + status: SUPPORTED + constraints: + - valid_values: + - firewall + - analyzer + - source-nat + - loadbalancer + service_interface_type_list: + hidden: false + immutable: false + type: list + description: List of interface types + required: true + status: SUPPORTED + entry_schema: + type: string + constraints: + - valid_values: + - management + - left + - right + - other + service_instance_name: + hidden: false + immutable: false + type: string + description: Service instance name + required: true + status: SUPPORTED + interface_list: + hidden: false + immutable: false + type: list + description: List of interfaces + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.contrail.InterfaceData + service_mode: + hidden: false + immutable: false + type: string + description: Service mode + required: true + status: SUPPORTED + constraints: + - valid_values: + - transparent + - in-network + - in-network-nat + shared_ip_list: + hidden: false + immutable: false + type: list + description: Shared ips enabled + required: false + status: SUPPORTED + entry_schema: + type: boolean + node_templates: + port_0: + type: org.openecomp.resource.cp.nodes.heat.network.contrail.Port + properties: + static_routes: + get_input: + - interface_list + - 0 + - static_routes + virtual_network: + get_input: + - interface_list + - 0 + - virtual_network + static_route: + get_input: + - static_routes_list + - 0 + allowed_address_pairs: + get_input: + - interface_list + - 0 + - allowed_address_pairs + shared_ip: + get_input: + - shared_ip_list + - 0 + ip_address: + get_input: + - interface_list + - 0 + - ip_address + interface_type: + get_input: + - service_interface_type_list + - 0 + order: 0 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: service_instance + relationship: tosca.relationships.network.BindsTo + port_1: + type: org.openecomp.resource.cp.nodes.heat.network.contrail.Port + properties: + static_routes: + get_input: + - interface_list + - 1 + - static_routes + virtual_network: + get_input: + - interface_list + - 1 + - virtual_network + static_route: + get_input: + - static_routes_list + - 1 + allowed_address_pairs: + get_input: + - interface_list + - 1 + - allowed_address_pairs + shared_ip: + get_input: + - shared_ip_list + - 1 + ip_address: + get_input: + - interface_list + - 1 + - ip_address + interface_type: + get_input: + - service_interface_type_list + - 1 + order: 1 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: service_instance + relationship: tosca.relationships.network.BindsTo + port_2: + type: org.openecomp.resource.cp.nodes.heat.network.contrail.Port + properties: + static_routes: + get_input: + - interface_list + - 2 + - static_routes + virtual_network: + get_input: + - interface_list + - 2 + - virtual_network + static_route: + get_input: + - static_routes_list + - 2 + allowed_address_pairs: + get_input: + - interface_list + - 2 + - allowed_address_pairs + shared_ip: + get_input: + - shared_ip_list + - 2 + ip_address: + get_input: + - interface_list + - 2 + - ip_address + interface_type: + get_input: + - service_interface_type_list + - 2 + order: 2 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: service_instance + relationship: tosca.relationships.network.BindsTo + port_3: + type: org.openecomp.resource.cp.nodes.heat.network.contrail.Port + properties: + static_routes: + get_input: + - interface_list + - 3 + - static_routes + virtual_network: + get_input: + - interface_list + - 3 + - virtual_network + static_route: + get_input: + - static_routes_list + - 3 + allowed_address_pairs: + get_input: + - interface_list + - 3 + - allowed_address_pairs + shared_ip: + get_input: + - shared_ip_list + - 3 + ip_address: + get_input: + - interface_list + - 3 + - ip_address + interface_type: + get_input: + - service_interface_type_list + - 3 + order: 3 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: service_instance + relationship: tosca.relationships.network.BindsTo + service_instance: + type: org.openecomp.resource.vfc.nodes.heat.compute_service_template + properties: + flavor: + get_input: flavor + image_name: + get_input: image_name + availability_zone: + get_input: availability_zone + service_type: + get_input: service_type + availability_zone_enable: + get_input: availability_zone_enable + service_template_name: + get_input: service_template_name + service_instance_name: + get_input: service_instance_name + service_mode: + get_input: service_mode + groups: + service_instance: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/lcp1_mss.oam-fw_si.yaml + members: + - service_instance + - port_0 + - port_1 + - port_2 + - port_3 + outputs: + tenant_id: + description: Tenant id of the Service Instance + value: + get_attribute: + - service_instance + - tenant_id + fq_name: + description: The FQ name of the service instance + value: + get_attribute: + - service_instance + - fq_name + service_template_name: + description: Service Template of the Service Instance + value: + get_attribute: + - service_instance + - service_template_name + show: + description: All attributes + value: + get_attribute: + - service_instance + - show + active_vms: + description: Number of service VMs active for this Service Instance + value: + get_attribute: + - service_instance + - active_vms + service_instance_name: + description: The name of the service instance + value: + get_attribute: + - service_instance + - service_instance_name + virtual_machines: + description: Service VMs for the Service Instance + value: + get_attribute: + - service_instance + - virtual_machines + status: + description: Status of the service instance + value: + get_attribute: + - service_instance + - status + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.service_template + requirements: + link_port_0: + - port_0 + - link + link_port_1: + - port_1 + - link + link_port_2: + - port_2 + - link + link_port_3: + - port_3 + - link \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/oneServiceInstance/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/oneServiceInstance/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..63989f282b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/oneServiceInstance/inputfiles/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "vLCP", + "description": "", + "data": [ + { + "file": "lcp1_mss.oam-fw_si.yaml", + "type": "HEAT", + "isBase": "false", + "data": [ + { + "file": "lcp1_mss.oam-fw_si_with_comments.env", + "type": "HEAT_ENV" + } + ] + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/oneServiceInstance/inputfiles/lcp1_mss.oam-fw_si.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/oneServiceInstance/inputfiles/lcp1_mss.oam-fw_si.yaml new file mode 100644 index 0000000000..33620a9b91 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/oneServiceInstance/inputfiles/lcp1_mss.oam-fw_si.yaml @@ -0,0 +1,153 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 10-14-2015 (Authors: Art Mishurov,am254u & Johhny Chen, jc3066) - HOT-OAM-FW-SI template that creates two OAM networks (direct and protected) with a scaled out firewall service between the two. + +parameters: + service_policy_name: + type: string + description: Policy Name + service_policy_direction: + type: string + description: Direction of Policy + start_src_ports: + type: number + description: Start of src port + end_src_ports: + type: number + description: End of src port + start_dst_ports: + type: number + description: Start of dst port + end_dst_ports: + type: number + description: End of dst port + oam_mgmt_net_id: + type: string + description: Name of private network to be created + oam_protected_net_id: + type: string + description: Name of private network to be created + oam_direct_net_id: + type: string + description: Name of private network to be created + oam_hsl_net_id: + type: string + description: Name of private network to be created + st_name: + type: string + description: service template name or ID + st_type: + type: string + description: service type + st_image: + type: string + description: Name of the image + st_flavor: + type: string + description: Flavor + st_service_interface_type_list: + type: string + description: List of interface types + st_shared_ip_list: + type: string + description: List of shared ip enabled-disabled + st_static_routes_list: + type: string + description: List of static routes enabled-disabled + st_scaling: + type: string + description: Indicates whether service scaling is enabled + st_mode: + type: string + description: service mode + st_availability_zone_enable_flag: + type: string + description: service template availablity_zone feature enable flag + max_num_fw_instances: + type: number + description: maximum number of firewall instances for scaling + service_instance_name: + type: string + description: service instance name + availability_zone: + type: string + description: availability zone in form of Zone:Host + static_prefix_3_1: + type: string + description: prefix for static route + protected_net: + type: string + +resources: + service_template: + type: OS::Contrail::ServiceTemplate + properties: + name: { get_param: st_name } + service_mode: { get_param: st_mode } + service_type: { get_param: st_type } + image_name: { get_param: st_image } + flavor: { get_param: st_flavor } + service_interface_type_list: { "Fn::Split" : [ ",", Ref: st_service_interface_type_list ] } + shared_ip_list: [ true, on, no, 0 ] + static_routes_list: { "Fn::Split" : [ ";", "n;false;false;false" ] } + service_scaling: { get_param: st_scaling } + availability_zone_enable: { get_param: st_availability_zone_enable_flag } + ordered_interfaces: true + + service_instance: + type: OS::Contrail::ServiceInstance + properties: + name: { get_param: service_instance_name } + service_template: { get_resource: service_template } + availability_zone: { get_param: availability_zone } + scale_out: + max_instances: 5 + interface_list: [ + { + virtual_network: {get_param: oam_mgmt_net_id} + }, + { + virtual_network: {get_param: oam_protected_net_id} + }, + { + virtual_network: {get_param: oam_direct_net_id}, + static_routes: [ + { "prefix": {get_param: static_prefix_3_1} }, + ], + }, + { + virtual_network: {get_param: oam_hsl_net_id} + }, + ] + + service_policy: + type: OS::Contrail::NetworkPolicy + depends_on: [ service_instance ] + properties: + name: { get_param: service_policy_name } + entries: + policy_rule: [ + { + "direction": { get_param: service_policy_direction }, + "protocol": "any", + "src_ports": [{"start_port": {get_param: start_src_ports}, "end_port": {get_param: end_src_ports}}], + "dst_ports": [{"start_port": {get_param: start_dst_ports}, "end_port": {get_param: end_dst_ports}}], + "dst_addresses": [{ "virtual_network": {get_param: oam_direct_net_id}}], + "action_list": {"apply_service": [{get_resource: service_instance}]}, + "src_addresses": [{ "virtual_network": {get_param: protected_net}}] + }, + ] + service_policy_attach_direct_net: + type: OS::Contrail::AttachPolicy + depends_on: [ service_policy ] + properties: + network: { get_param: oam_direct_net_id } + policy: { get_attr: [service_policy, fq_name] } + + service_policy_attach_protected_net: + type: OS::Contrail::AttachPolicy + depends_on: [ service_policy ] + properties: + network: { get_param: oam_protected_net_id } + policy: { get_attr: [service_policy, fq_name] } diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/oneServiceInstance/inputfiles/lcp1_mss.oam-fw_si_with_comments.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/oneServiceInstance/inputfiles/lcp1_mss.oam-fw_si_with_comments.env new file mode 100644 index 0000000000..718c5dba17 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/oneServiceInstance/inputfiles/lcp1_mss.oam-fw_si_with_comments.env @@ -0,0 +1,26 @@ +parameters: + #service_instance_name: ZRDM1FRWL02OAM + service_policy_name: MNS-25180-L-02Shared_policy_direct_fw_protected_oam_1 + service_policy_direction: "<>" + start_src_ports: -1 + end_src_ports: -1 + start_dst_ports: -1 + end_dst_ports: -1 + st_name: MNS-25180-L-02Shared_oam_fw_template_1 + st_mode: in-network-nat + st_type: firewall + st_image: NIMBUS_SRX_151X49-D303 + st_flavor: lc.medium + st_service_interface_type_list: management,left,right,other + st_shared_ip_list: False,True,False,False + st_static_routes_list: True,True,True,True + st_scaling: "True" + st_availability_zone_enable_flag: "True" + #availability_zone: "nova" + max_num_fw_instances: 8 + #oam_mgmt_net_id: 'default-domain:MNS-25180-L-02Shared_oam_mgmt_net_1' + #oam_protected_net_id: 'default-domain:MNS-25180-L-02Shared_oam_protected_net_1' + #oam_direct_net_id: 'default-domain:MNS-25180-L-02Shared_oam_direct_net_1' + #oam_hsl_net_id: 'default-domain:MNS-25180-L-02Shared_oam_hsl_net_1' + static_prefix_3_1: 107.239.80.0/21 + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sameServiceTemplate/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sameServiceTemplate/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..b00d3d8bc0 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sameServiceTemplate/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,64 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.service_template: + derived_from: org.openecomp.resource.abstract.nodes.contrail.AbstractSubstitute + requirements: + - link_port_0: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_port_1: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_port_2: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_port_3: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + org.openecomp.resource.vfc.nodes.heat.compute_service_template: + derived_from: org.openecomp.resource.vfc.nodes.heat.contrail.Compute \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sameServiceTemplate/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sameServiceTemplate/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..942df0b120 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sameServiceTemplate/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,441 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + service_policy_name: + hidden: false + immutable: false + type: string + description: Policy Name + st_static_routes_list: + hidden: false + immutable: false + type: string + description: List of static routes enabled-disabled + st_type: + hidden: false + immutable: false + type: string + description: service type + st_service_interface_type_list: + hidden: false + immutable: false + type: string + description: List of interface types + st_mode: + hidden: false + immutable: false + type: string + description: service mode + Cricket_OCS_protected_net_id: + hidden: false + immutable: false + type: string + description: Name of Cricket OCS network + oam_mgmt_net_0_id: + hidden: false + immutable: false + type: string + description: Name of OAM network + start_dst_ports: + hidden: false + immutable: false + type: float + description: Start of dst port + st_flavor: + hidden: false + immutable: false + type: string + description: Flavor + availability_zone_1: + hidden: false + immutable: false + type: string + description: availability zone + service_instance_name: + hidden: false + immutable: false + type: string + description: Service instance name + st_scaling: + hidden: false + immutable: false + type: string + description: Indicates whether service scaling is enabled + max_num_fw_instances: + hidden: false + immutable: false + type: float + description: maximum number of firewall instances for scaling + start_src_ports: + hidden: false + immutable: false + type: float + description: Start of src port + service_policy_direction: + hidden: false + immutable: false + type: string + description: Direction of Policy + st_name: + hidden: false + immutable: false + type: string + description: Name of service template + HSL_direct_net_gateway: + hidden: false + immutable: false + type: string + description: HSL (Logging) network gateway address + st_image: + hidden: false + immutable: false + type: string + description: Name of the image + st_shared_ip_list: + hidden: false + immutable: false + type: string + description: List of shared ip enabled-disabled + prefix_0: + hidden: false + immutable: false + type: string + Cricket_OCS_direct_net_id: + hidden: false + immutable: false + type: string + description: Name of Cricket OCS network + oam_mgmt_net_1_id: + hidden: false + immutable: false + type: string + description: Name of OAM network + prefix_1: + hidden: false + immutable: false + type: string + end_src_ports: + hidden: false + immutable: false + type: float + description: End of src port + prefix_2: + hidden: false + immutable: false + type: string + end_dst_ports: + hidden: false + immutable: false + type: float + description: End of dst port + st_image_name: + hidden: false + immutable: false + type: string + description: Name of the image + HSL_direct_net_id: + hidden: false + immutable: false + type: string + description: Name of HSL (Logging) network + HSL_direct_net_cidr: + hidden: false + immutable: false + type: string + description: HSL (Logging) network address (CIDR notation) + node_templates: + service_instance_1: + type: org.openecomp.resource.abstract.nodes.heat.service_template + directives: + - substitutable + properties: + flavor: + get_input: st_flavor + availability_zone: + get_input: availability_zone_1 + image_name: + get_input: st_image + service_template_filter: + substitute_service_template: service_instance_1ServiceTemplate.yaml + count: 1 + scaling_enabled: + get_input: st_scaling + mandatory: true + service_type: + get_input: st_type + static_routes_list: + - token: + - get_input: st_static_routes_list + - ',' + - 0 + - token: + - get_input: st_static_routes_list + - ',' + - 1 + - token: + - get_input: st_static_routes_list + - ',' + - 2 + - token: + - get_input: st_static_routes_list + - ',' + - 3 + service_template_name: + get_input: st_name + service_interface_type_list: + - token: + - management,left,right,other + - ',' + - 0 + - token: + - management,left,right,other + - ',' + - 1 + - token: + - management,left,right,other + - ',' + - 2 + - token: + - management,left,right,other + - ',' + - 3 + interface_list: + - virtual_network: + get_input: oam_mgmt_net_0_id + - virtual_network: + get_input: Cricket_OCS_direct_net_id + - virtual_network: hsl_direct_net1 + - static_routes: + - prefix: + get_input: prefix_0 + - prefix: + get_input: prefix_1 + - prefix: + get_input: prefix_2 + virtual_network: + get_input: oam_mgmt_net_1_id + service_instance_name: + get_input: service_instance_name + service_mode: + get_input: st_mode + shared_ip_list: + - token: + - get_input: st_shared_ip_list + - ',' + - 0 + - token: + - get_input: st_shared_ip_list + - ',' + - 1 + - token: + - get_input: st_shared_ip_list + - ',' + - 2 + - token: + - get_input: st_shared_ip_list + - ',' + - 3 + requirements: + - link_port_2: + capability: tosca.capabilities.network.Linkable + node: hsl_direct_net1 + relationship: tosca.relationships.network.LinksTo + - dependency: + capability: tosca.capabilities.Node + node: hsl_direct_net1 + relationship: tosca.relationships.DependsOn + service_instance_2: + type: org.openecomp.resource.abstract.nodes.heat.service_template + directives: + - substitutable + properties: + flavor: + get_input: st_flavor + availability_zone: + get_input: availability_zone_1 + image_name: + get_input: st_image + service_template_filter: + substitute_service_template: service_instance_2ServiceTemplate.yaml + count: + get_input: max_num_fw_instances + scaling_enabled: + get_input: st_scaling + mandatory: false + service_type: + get_input: st_type + static_routes_list: + - token: + - get_input: st_static_routes_list + - ',' + - 0 + - token: + - get_input: st_static_routes_list + - ',' + - 1 + - token: + - get_input: st_static_routes_list + - ',' + - 2 + - token: + - get_input: st_static_routes_list + - ',' + - 3 + service_template_name: + get_input: st_name + service_interface_type_list: + - token: + - management,left,right,other + - ',' + - 0 + - token: + - management,left,right,other + - ',' + - 1 + - token: + - management,left,right,other + - ',' + - 2 + - token: + - management,left,right,other + - ',' + - 3 + interface_list: + - virtual_network: + get_input: oam_mgmt_net_0_id + - virtual_network: + get_input: Cricket_OCS_direct_net_id + - virtual_network: hsl_direct_net2 + - static_routes: + - prefix: + get_input: prefix_0 + - prefix: + get_input: prefix_1 + - prefix: + get_input: prefix_2 + virtual_network: + get_input: oam_mgmt_net_1_id + service_instance_name: + get_input: service_instance_name + service_mode: + get_input: st_mode + shared_ip_list: + - token: + - get_input: st_shared_ip_list + - ',' + - 0 + - token: + - get_input: st_shared_ip_list + - ',' + - 1 + - token: + - get_input: st_shared_ip_list + - ',' + - 2 + - token: + - get_input: st_shared_ip_list + - ',' + - 3 + requirements: + - link_port_2: + capability: tosca.capabilities.network.Linkable + node: hsl_direct_net2 + relationship: tosca.relationships.network.LinksTo + - dependency: + capability: tosca.capabilities.Node + node: hsl_direct_net1 + relationship: tosca.relationships.DependsOn + hsl_direct_net1: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + network_name: + get_input: HSL_direct_net_id + subnets: + hsl_ip_subnet: + cidr: + get_input: HSL_direct_net_cidr + gateway_ip: + get_input: HSL_direct_net_gateway + hsl_direct_net2: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + network_name: + get_input: HSL_direct_net_id + service_policy: + type: org.openecomp.resource.vfc.rules.nodes.heat.network.contrail.NetworkRules + properties: + entries: + policy_rule: + - src_ports: + - start_port: + get_input: start_src_ports + end_port: + get_input: end_src_ports + protocol: any + action_list: + apply_service: + - service_instance_1 + dst_addresses: + - virtual_network: + get_input: Cricket_OCS_direct_net_id + dst_ports: + - start_port: + get_input: start_dst_ports + end_port: + get_input: end_dst_ports + src_addresses: + - virtual_network: + get_input: Cricket_OCS_protected_net_id + direction: + get_input: service_policy_direction + name: + get_input: service_policy_name + requirements: + - dependency: + capability: tosca.capabilities.Node + node: service_instance_1 + relationship: tosca.relationships.DependsOn + groups: + OCS-fw: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/OCS-fw.yml + description: | + Based on the following reference for the HOT-DMZ-FW template: Version 3.5 8-10-2015 (Authors: Art Mishurov,am254u & Johhny Chen, jc3066) - HOT-DMZ-FW template that creates two DMZ networks (direct and protected) with a scaled out firewall service between the two. + members: + - service_instance_1 + - service_instance_2 + - hsl_direct_net1 + - hsl_direct_net2 + - service_policy \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sameServiceTemplate/expectedoutputfiles/service_instance_1ServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sameServiceTemplate/expectedoutputfiles/service_instance_1ServiceTemplate.yaml new file mode 100644 index 0000000000..4b53e28b6f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sameServiceTemplate/expectedoutputfiles/service_instance_1ServiceTemplate.yaml @@ -0,0 +1,407 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: service_instance_1 +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + availability_zone: + hidden: false + immutable: false + type: string + description: Availability zone to create servers in + required: false + status: SUPPORTED + static_routes_list: + hidden: false + immutable: false + type: list + description: Static routes enabled + required: false + status: SUPPORTED + entry_schema: + type: boolean + availability_zone_enable: + hidden: false + immutable: false + type: boolean + description: Indicates availability zone is enabled + required: false + default: false + status: SUPPORTED + service_template_name: + hidden: false + immutable: false + type: string + description: Service template name + required: false + status: SUPPORTED + ordered_interfaces: + hidden: false + immutable: false + type: boolean + description: Indicates if service interface are ordered + required: false + default: false + status: SUPPORTED + flavor: + hidden: false + immutable: false + type: string + description: flavor + required: false + status: SUPPORTED + image_name: + hidden: false + immutable: false + type: string + description: Image name + required: true + status: SUPPORTED + service_type: + hidden: false + immutable: false + type: string + description: Service type + required: true + status: SUPPORTED + constraints: + - valid_values: + - firewall + - analyzer + - source-nat + - loadbalancer + service_interface_type_list: + hidden: false + immutable: false + type: list + description: List of interface types + required: true + status: SUPPORTED + entry_schema: + type: string + constraints: + - valid_values: + - management + - left + - right + - other + service_instance_name: + hidden: false + immutable: false + type: string + description: Service instance name + required: true + status: SUPPORTED + interface_list: + hidden: false + immutable: false + type: list + description: List of interfaces + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.contrail.InterfaceData + service_mode: + hidden: false + immutable: false + type: string + description: Service mode + required: true + status: SUPPORTED + constraints: + - valid_values: + - transparent + - in-network + - in-network-nat + shared_ip_list: + hidden: false + immutable: false + type: list + description: Shared ips enabled + required: false + status: SUPPORTED + entry_schema: + type: boolean + node_templates: + service_instance_1: + type: org.openecomp.resource.vfc.nodes.heat.compute_service_template + properties: + flavor: + get_input: flavor + image_name: + get_input: image_name + availability_zone: + get_input: availability_zone + service_type: + get_input: service_type + availability_zone_enable: + get_input: availability_zone_enable + service_template_name: + get_input: service_template_name + service_instance_name: + get_input: service_instance_name + service_mode: + get_input: service_mode + port_0: + type: org.openecomp.resource.cp.nodes.heat.network.contrail.Port + properties: + static_routes: + get_input: + - interface_list + - 0 + - static_routes + virtual_network: + get_input: + - interface_list + - 0 + - virtual_network + static_route: + get_input: + - static_routes_list + - 0 + allowed_address_pairs: + get_input: + - interface_list + - 0 + - allowed_address_pairs + shared_ip: + get_input: + - shared_ip_list + - 0 + ip_address: + get_input: + - interface_list + - 0 + - ip_address + interface_type: + get_input: + - service_interface_type_list + - 0 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: service_instance_1 + relationship: tosca.relationships.network.BindsTo + port_1: + type: org.openecomp.resource.cp.nodes.heat.network.contrail.Port + properties: + static_routes: + get_input: + - interface_list + - 1 + - static_routes + virtual_network: + get_input: + - interface_list + - 1 + - virtual_network + static_route: + get_input: + - static_routes_list + - 1 + allowed_address_pairs: + get_input: + - interface_list + - 1 + - allowed_address_pairs + shared_ip: + get_input: + - shared_ip_list + - 1 + ip_address: + get_input: + - interface_list + - 1 + - ip_address + interface_type: + get_input: + - service_interface_type_list + - 1 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: service_instance_1 + relationship: tosca.relationships.network.BindsTo + port_2: + type: org.openecomp.resource.cp.nodes.heat.network.contrail.Port + properties: + static_routes: + get_input: + - interface_list + - 2 + - static_routes + virtual_network: + get_input: + - interface_list + - 2 + - virtual_network + static_route: + get_input: + - static_routes_list + - 2 + allowed_address_pairs: + get_input: + - interface_list + - 2 + - allowed_address_pairs + shared_ip: + get_input: + - shared_ip_list + - 2 + ip_address: + get_input: + - interface_list + - 2 + - ip_address + interface_type: + get_input: + - service_interface_type_list + - 2 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: service_instance_1 + relationship: tosca.relationships.network.BindsTo + port_3: + type: org.openecomp.resource.cp.nodes.heat.network.contrail.Port + properties: + static_routes: + get_input: + - interface_list + - 3 + - static_routes + virtual_network: + get_input: + - interface_list + - 3 + - virtual_network + static_route: + get_input: + - static_routes_list + - 3 + allowed_address_pairs: + get_input: + - interface_list + - 3 + - allowed_address_pairs + shared_ip: + get_input: + - shared_ip_list + - 3 + ip_address: + get_input: + - interface_list + - 3 + - ip_address + interface_type: + get_input: + - service_interface_type_list + - 3 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: service_instance_1 + relationship: tosca.relationships.network.BindsTo + groups: + service_instance_1: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/OCS-fw.yml + members: + - service_instance_1 + - port_0 + - port_1 + - port_2 + - port_3 + outputs: + tenant_id: + description: Tenant id of the Service Instance + value: + get_attribute: + - service_instance_1 + - tenant_id + fq_name: + description: The FQ name of the service instance + value: + get_attribute: + - service_instance_1 + - fq_name + service_template_name: + description: Service Template of the Service Instance + value: + get_attribute: + - service_instance_1 + - service_template_name + show: + description: All attributes + value: + get_attribute: + - service_instance_1 + - show + active_vms: + description: Number of service VMs active for this Service Instance + value: + get_attribute: + - service_instance_1 + - active_vms + service_instance_name: + description: The name of the service instance + value: + get_attribute: + - service_instance_1 + - service_instance_name + virtual_machines: + description: Service VMs for the Service Instance + value: + get_attribute: + - service_instance_1 + - virtual_machines + status: + description: Status of the service instance + value: + get_attribute: + - service_instance_1 + - status + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.service_template + requirements: + link_port_0: + - port_0 + - link + link_port_1: + - port_1 + - link + link_port_2: + - port_2 + - link + link_port_3: + - port_3 + - link \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sameServiceTemplate/expectedoutputfiles/service_instance_2ServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sameServiceTemplate/expectedoutputfiles/service_instance_2ServiceTemplate.yaml new file mode 100644 index 0000000000..f0e67ea99c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sameServiceTemplate/expectedoutputfiles/service_instance_2ServiceTemplate.yaml @@ -0,0 +1,407 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: service_instance_2 +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + availability_zone: + hidden: false + immutable: false + type: string + description: Availability zone to create servers in + required: false + status: SUPPORTED + static_routes_list: + hidden: false + immutable: false + type: list + description: Static routes enabled + required: false + status: SUPPORTED + entry_schema: + type: boolean + availability_zone_enable: + hidden: false + immutable: false + type: boolean + description: Indicates availability zone is enabled + required: false + default: false + status: SUPPORTED + service_template_name: + hidden: false + immutable: false + type: string + description: Service template name + required: false + status: SUPPORTED + ordered_interfaces: + hidden: false + immutable: false + type: boolean + description: Indicates if service interface are ordered + required: false + default: false + status: SUPPORTED + flavor: + hidden: false + immutable: false + type: string + description: flavor + required: false + status: SUPPORTED + image_name: + hidden: false + immutable: false + type: string + description: Image name + required: true + status: SUPPORTED + service_type: + hidden: false + immutable: false + type: string + description: Service type + required: true + status: SUPPORTED + constraints: + - valid_values: + - firewall + - analyzer + - source-nat + - loadbalancer + service_interface_type_list: + hidden: false + immutable: false + type: list + description: List of interface types + required: true + status: SUPPORTED + entry_schema: + type: string + constraints: + - valid_values: + - management + - left + - right + - other + service_instance_name: + hidden: false + immutable: false + type: string + description: Service instance name + required: true + status: SUPPORTED + interface_list: + hidden: false + immutable: false + type: list + description: List of interfaces + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.contrail.InterfaceData + service_mode: + hidden: false + immutable: false + type: string + description: Service mode + required: true + status: SUPPORTED + constraints: + - valid_values: + - transparent + - in-network + - in-network-nat + shared_ip_list: + hidden: false + immutable: false + type: list + description: Shared ips enabled + required: false + status: SUPPORTED + entry_schema: + type: boolean + node_templates: + service_instance_2: + type: org.openecomp.resource.vfc.nodes.heat.compute_service_template + properties: + flavor: + get_input: flavor + image_name: + get_input: image_name + availability_zone: + get_input: availability_zone + service_type: + get_input: service_type + availability_zone_enable: + get_input: availability_zone_enable + service_template_name: + get_input: service_template_name + service_instance_name: + get_input: service_instance_name + service_mode: + get_input: service_mode + port_0: + type: org.openecomp.resource.cp.nodes.heat.network.contrail.Port + properties: + static_routes: + get_input: + - interface_list + - 0 + - static_routes + virtual_network: + get_input: + - interface_list + - 0 + - virtual_network + static_route: + get_input: + - static_routes_list + - 0 + allowed_address_pairs: + get_input: + - interface_list + - 0 + - allowed_address_pairs + shared_ip: + get_input: + - shared_ip_list + - 0 + ip_address: + get_input: + - interface_list + - 0 + - ip_address + interface_type: + get_input: + - service_interface_type_list + - 0 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: service_instance_2 + relationship: tosca.relationships.network.BindsTo + port_1: + type: org.openecomp.resource.cp.nodes.heat.network.contrail.Port + properties: + static_routes: + get_input: + - interface_list + - 1 + - static_routes + virtual_network: + get_input: + - interface_list + - 1 + - virtual_network + static_route: + get_input: + - static_routes_list + - 1 + allowed_address_pairs: + get_input: + - interface_list + - 1 + - allowed_address_pairs + shared_ip: + get_input: + - shared_ip_list + - 1 + ip_address: + get_input: + - interface_list + - 1 + - ip_address + interface_type: + get_input: + - service_interface_type_list + - 1 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: service_instance_2 + relationship: tosca.relationships.network.BindsTo + port_2: + type: org.openecomp.resource.cp.nodes.heat.network.contrail.Port + properties: + static_routes: + get_input: + - interface_list + - 2 + - static_routes + virtual_network: + get_input: + - interface_list + - 2 + - virtual_network + static_route: + get_input: + - static_routes_list + - 2 + allowed_address_pairs: + get_input: + - interface_list + - 2 + - allowed_address_pairs + shared_ip: + get_input: + - shared_ip_list + - 2 + ip_address: + get_input: + - interface_list + - 2 + - ip_address + interface_type: + get_input: + - service_interface_type_list + - 2 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: service_instance_2 + relationship: tosca.relationships.network.BindsTo + port_3: + type: org.openecomp.resource.cp.nodes.heat.network.contrail.Port + properties: + static_routes: + get_input: + - interface_list + - 3 + - static_routes + virtual_network: + get_input: + - interface_list + - 3 + - virtual_network + static_route: + get_input: + - static_routes_list + - 3 + allowed_address_pairs: + get_input: + - interface_list + - 3 + - allowed_address_pairs + shared_ip: + get_input: + - shared_ip_list + - 3 + ip_address: + get_input: + - interface_list + - 3 + - ip_address + interface_type: + get_input: + - service_interface_type_list + - 3 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: service_instance_2 + relationship: tosca.relationships.network.BindsTo + groups: + service_instance_2: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/OCS-fw.yml + members: + - service_instance_2 + - port_0 + - port_1 + - port_2 + - port_3 + outputs: + tenant_id: + description: Tenant id of the Service Instance + value: + get_attribute: + - service_instance_2 + - tenant_id + fq_name: + description: The FQ name of the service instance + value: + get_attribute: + - service_instance_2 + - fq_name + service_template_name: + description: Service Template of the Service Instance + value: + get_attribute: + - service_instance_2 + - service_template_name + show: + description: All attributes + value: + get_attribute: + - service_instance_2 + - show + active_vms: + description: Number of service VMs active for this Service Instance + value: + get_attribute: + - service_instance_2 + - active_vms + service_instance_name: + description: The name of the service instance + value: + get_attribute: + - service_instance_2 + - service_instance_name + virtual_machines: + description: Service VMs for the Service Instance + value: + get_attribute: + - service_instance_2 + - virtual_machines + status: + description: Status of the service instance + value: + get_attribute: + - service_instance_2 + - status + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.service_template + requirements: + link_port_0: + - port_0 + - link + link_port_1: + - port_1 + - link + link_port_2: + - port_2 + - link + link_port_3: + - port_3 + - link \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sameServiceTemplate/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sameServiceTemplate/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..a26430ba72 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sameServiceTemplate/inputfiles/MANIFEST.json @@ -0,0 +1,12 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "OCS-fw.yml", + "type": "HEAT", + "isBase": "false" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sameServiceTemplate/inputfiles/OCS-fw.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sameServiceTemplate/inputfiles/OCS-fw.yml new file mode 100644 index 0000000000..0082148f77 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sameServiceTemplate/inputfiles/OCS-fw.yml @@ -0,0 +1,213 @@ +heat_template_version: 2013-05-23 + +description: > + Based on the following reference for the HOT-DMZ-FW template: + Version 3.5 8-10-2015 (Authors: Art Mishurov,am254u & Johhny Chen, jc3066) - HOT-DMZ-FW template that creates two DMZ networks (direct and protected) with a scaled out firewall service between the two. + +parameters: + HSL_direct_net_id: + type: string + description: Name of HSL (Logging) network + prefix_0: + type: string + prefix_1: + type: string + prefix_2: + type: string + HSL_direct_net_cidr: + type: string + description: HSL (Logging) network address (CIDR notation) + HSL_direct_net_gateway: + type: string + description: HSL (Logging) network gateway address + oam_mgmt_net_0_id: + type: string + description: Name of OAM network + oam_mgmt_net_1_id: + type: string + description: Name of OAM network + Cricket_OCS_direct_net_id: + type: string + description: Name of Cricket OCS network + Cricket_OCS_protected_net_id: + type: string + description: Name of Cricket OCS network + service_instance_name: + type: string + description: Service instance name + service_policy_name: + type: string + description: Policy Name + service_policy_direction: + type: string + description: Direction of Policy + start_src_ports: + type: number + description: Start of src port + end_src_ports: + type: number + description: End of src port + start_dst_ports: + type: number + description: Start of dst port + end_dst_ports: + type: number + description: End of dst port + st_name: + type: string + description: Name of service template + st_mode: + type: string + description: service mode + st_type: + type: string + description: service type + st_image: + type: string + description: Name of the image + st_image_name: + type: string + description: Name of the image + st_flavor: + type: string + description: Flavor + st_service_interface_type_list: + type: string + description: List of interface types + st_shared_ip_list: + type: string + description: List of shared ip enabled-disabled + st_static_routes_list: + type: string + description: List of static routes enabled-disabled + st_scaling: + type: string + description: Indicates whether service scaling is enabled + max_num_fw_instances: + type: number + description: maximum number of firewall instances for scaling + availability_zone_1: + type: string + description: availability zone + +resources: + + hsl_direct_net1: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: HSL_direct_net_id } +# external: True + + hsl_direct_net2: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: HSL_direct_net_id } +# external: True + + hsl_ip_subnet: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: hsl_direct_net1 } + cidr: { get_param: HSL_direct_net_cidr } + gateway_ip: { get_param: HSL_direct_net_gateway } + + service_template: + type: OS::Contrail::ServiceTemplate + properties: + name: { get_param: st_name } + service_mode: { get_param: st_mode } + service_type: { get_param: st_type } + image_name: { get_param: st_image } + flavor: { get_param: st_flavor } + service_interface_type_list: { "Fn::Split" : [ ",", "management,left,right,other" ] } + shared_ip_list: { "Fn::Split" : [ ",", Ref: st_shared_ip_list ] } + static_routes_list: { "Fn::Split" : [ ",", Ref: st_static_routes_list ] } + service_scaling: { get_param: st_scaling } + + service_instance_1: + type: OS::Contrail::ServiceInstance + depends_on: [ hsl_ip_subnet] + properties: + name: { get_param: service_instance_name } + availability_zone: { get_param: availability_zone_1 } + service_template: { get_resource: service_template } + interface_list: [ + { + virtual_network: { get_param: oam_mgmt_net_0_id } + }, + { + virtual_network: { get_param: Cricket_OCS_direct_net_id } + }, + { + virtual_network: { get_resource: hsl_direct_net1 } + }, + { + virtual_network: {get_param: oam_mgmt_net_1_id}, + static_routes: [ + { "prefix": {get_param: prefix_0} }, + { "prefix": {get_param: prefix_1} }, + { "prefix": {get_param: prefix_2} }, + ], + } + ] + + service_instance_2: + type: OS::Contrail::ServiceInstance + depends_on: [ hsl_ip_subnet] + properties: + name: { get_param: service_instance_name } + availability_zone: { get_param: availability_zone_1 } + service_template: { get_resource: service_template } + scale_out: + max_instances: {get_param: max_num_fw_instances} + interface_list: [ + { + virtual_network: { get_param: oam_mgmt_net_0_id } + }, + { + virtual_network: { get_param: Cricket_OCS_direct_net_id } + }, + { + virtual_network: { get_resource: hsl_direct_net2 } + }, + { + virtual_network: {get_param: oam_mgmt_net_1_id}, + static_routes: [ + { "prefix": {get_param: prefix_0} }, + { "prefix": {get_param: prefix_1} }, + { "prefix": {get_param: prefix_2} }, + ], + } + ] + + service_policy: + type: OS::Contrail::NetworkPolicy + depends_on: [ service_instance_1 ] + properties: + name: { get_param: service_policy_name } + entries: + policy_rule: [ + { + "direction": { get_param: service_policy_direction }, + "protocol": "any", + "src_ports": [{"start_port": {get_param: start_src_ports}, "end_port": {get_param: end_src_ports}}], + "dst_ports": [{"start_port": {get_param: start_dst_ports}, "end_port": {get_param: end_dst_ports}}], + "dst_addresses": [{ "virtual_network": { get_param: Cricket_OCS_direct_net_id }}], + "action_list": { "apply_service": [{ get_resource: service_instance_1 }]}, + "src_addresses": [{ "virtual_network": { get_param: Cricket_OCS_protected_net_id }}], + }, + ] + + service_policy_attach_direct_net: + type: OS::Contrail::AttachPolicy + depends_on: [ service_policy ] + properties: + network: { get_param: Cricket_OCS_direct_net_id } + policy: { get_attr: [service_policy, fq_name] } + + service_policy_attach_protected_net: + type: OS::Contrail::AttachPolicy + depends_on: [ service_policy ] + properties: + network: { get_param: Cricket_OCS_protected_net_id } + policy: { get_attr: [service_policy, fq_name] } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkMulti/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkMulti/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..73abe8ecb0 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkMulti/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,71 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.service_template: + derived_from: org.openecomp.resource.abstract.nodes.contrail.AbstractSubstitute + requirements: + - link_port_0: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_port_1: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_port_2: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_port_3: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_port_4: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + org.openecomp.resource.vfc.nodes.heat.compute_service_template: + derived_from: org.openecomp.resource.vfc.nodes.heat.contrail.Compute \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkMulti/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkMulti/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..c6a6364988 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkMulti/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,407 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + Internal1_shared: + hidden: false + immutable: false + type: string + service_policy_name: + hidden: false + immutable: false + type: string + description: Policy Name + st_static_routes_list: + hidden: false + immutable: false + type: string + description: List of static routes enabled-disabled + st_type: + hidden: false + immutable: false + type: string + description: service type + Internal2_forwarding_mode: + hidden: false + immutable: false + type: string + st_service_interface_type_list: + hidden: false + immutable: false + type: string + description: List of interface types + st_mode: + hidden: false + immutable: false + type: string + description: service mode + Cricket_OCS_protected_net_id: + hidden: false + immutable: false + type: string + description: Name of Cricket OCS network + oam_mgmt_net_0_id: + hidden: false + immutable: false + type: string + description: Name of OAM network + start_dst_ports: + hidden: false + immutable: false + type: float + description: Start of dst port + st_flavor: + hidden: false + immutable: false + type: string + description: Flavor + availability_zone_1: + hidden: false + immutable: false + type: string + description: availability zone + Internal2_shared: + hidden: false + immutable: false + type: string + service_instance_name: + hidden: false + immutable: false + type: string + description: Service instance name + st_scaling: + hidden: false + immutable: false + type: string + description: Indicates whether service scaling is enabled + max_num_fw_instances: + hidden: false + immutable: false + type: float + description: maximum number of firewall instances for scaling + Internal1_net_name: + hidden: false + immutable: false + type: string + start_src_ports: + hidden: false + immutable: false + type: float + description: Start of src port + service_policy_direction: + hidden: false + immutable: false + type: string + description: Direction of Policy + st_name: + hidden: false + immutable: false + type: string + description: Name of service template + Internal2_net_name: + hidden: false + immutable: false + type: string + hsl_direct_net3: + hidden: false + immutable: false + type: string + hsl_direct_net4: + hidden: false + immutable: false + type: string + HSL_direct_net_gateway: + hidden: false + immutable: false + type: string + description: HSL (Logging) network gateway address + hsl_direct_net1: + hidden: false + immutable: false + type: string + hsl_direct_net2: + hidden: false + immutable: false + type: string + st_image: + hidden: false + immutable: false + type: string + description: Name of the image + st_shared_ip_list: + hidden: false + immutable: false + type: string + description: List of shared ip enabled-disabled + Cricket_OCS_direct_net_id: + hidden: false + immutable: false + type: string + description: Name of Cricket OCS network + Internal1_forwarding_mode: + hidden: false + immutable: false + type: string + end_src_ports: + hidden: false + immutable: false + type: float + description: End of src port + end_dst_ports: + hidden: false + immutable: false + type: float + description: End of dst port + HSL_direct_net_id: + hidden: false + immutable: false + type: string + description: Name of HSL (Logging) network + HSL_direct_net_cidr: + hidden: false + immutable: false + type: string + description: HSL (Logging) network address (CIDR notation) + node_templates: + Internal2-net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + shared: + get_input: Internal1_shared + forwarding_mode: + get_input: Internal1_forwarding_mode + network_name: + get_input: Internal2_net_name + Internal1-net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + shared: + get_input: Internal1_shared + forwarding_mode: + get_input: Internal1_forwarding_mode + network_name: + get_input: Internal1_net_name + Internal3-net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + shared: + get_input: Internal1_shared + forwarding_mode: + get_input: Internal1_forwarding_mode + network_name: + get_input: Internal2_net_name + hsl_direct_net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + network_name: + get_input: HSL_direct_net_id + subnets: + hsl_ip_subnet: + cidr: + get_input: HSL_direct_net_cidr + gateway_ip: + get_input: HSL_direct_net_gateway + service_instance: + type: org.openecomp.resource.abstract.nodes.heat.service_template + directives: + - substitutable + properties: + flavor: + get_input: st_flavor + availability_zone: + get_input: availability_zone_1 + image_name: + get_input: st_image + service_template_filter: + substitute_service_template: service_instanceServiceTemplate.yaml + count: + get_input: max_num_fw_instances + scaling_enabled: + get_input: st_scaling + mandatory: false + service_type: + get_input: st_type + static_routes_list: + - token: + - get_input: st_static_routes_list + - ',' + - 0 + - token: + - get_input: st_static_routes_list + - ',' + - 1 + - token: + - get_input: st_static_routes_list + - ',' + - 2 + - token: + - get_input: st_static_routes_list + - ',' + - 3 + - token: + - get_input: st_static_routes_list + - ',' + - 4 + service_template_name: + get_input: st_name + service_interface_type_list: + - token: + - get_input: st_service_interface_type_list + - ',' + - 0 + - token: + - get_input: st_service_interface_type_list + - ',' + - 1 + - token: + - get_input: st_service_interface_type_list + - ',' + - 2 + - token: + - get_input: st_service_interface_type_list + - ',' + - 3 + - token: + - get_input: st_service_interface_type_list + - ',' + - 4 + interface_list: + - virtual_network: + get_input: hsl_direct_net1 + - virtual_network: + get_input: hsl_direct_net2 + - virtual_network: + get_input: hsl_direct_net3 + - virtual_network: + get_input: hsl_direct_net4 + - virtual_network: hsl_direct_net + service_instance_name: + get_input: service_instance_name + service_mode: + get_input: st_mode + shared_ip_list: + - token: + - get_input: st_shared_ip_list + - ',' + - 0 + - token: + - get_input: st_shared_ip_list + - ',' + - 1 + - token: + - get_input: st_shared_ip_list + - ',' + - 2 + - token: + - get_input: st_shared_ip_list + - ',' + - 3 + - token: + - get_input: st_shared_ip_list + - ',' + - 4 + requirements: + - link_port_0: + capability: tosca.capabilities.network.Linkable + node: Internal1-net + relationship: tosca.relationships.network.LinksTo + - link_port_1: + capability: tosca.capabilities.network.Linkable + node: Internal2-net + relationship: tosca.relationships.network.LinksTo + - link_port_2: + capability: tosca.capabilities.network.Linkable + node: Internal3-net + relationship: tosca.relationships.network.LinksTo + - link_port_4: + capability: tosca.capabilities.network.Linkable + node: hsl_direct_net + relationship: tosca.relationships.network.LinksTo + - dependency: + capability: tosca.capabilities.Node + node: hsl_direct_net + relationship: tosca.relationships.DependsOn + service_policy: + type: org.openecomp.resource.vfc.rules.nodes.heat.network.contrail.NetworkRules + properties: + entries: + policy_rule: + - src_ports: + - start_port: + get_input: start_src_ports + end_port: + get_input: end_src_ports + protocol: any + action_list: + apply_service: + - service_instance + dst_addresses: + - virtual_network: + get_input: Cricket_OCS_direct_net_id + dst_ports: + - start_port: + get_input: start_dst_ports + end_port: + get_input: end_dst_ports + src_addresses: + - virtual_network: + get_input: Cricket_OCS_protected_net_id + direction: + get_input: service_policy_direction + name: + get_input: service_policy_name + requirements: + - dependency: + capability: tosca.capabilities.Node + node: service_instance + relationship: tosca.relationships.DependsOn + groups: + OCS-fw: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/OCS-fw.yml + description: | + Based on the following reference for the HOT-DMZ-FW template: Version 3.5 8-10-2015 (Authors: Art Mishurov,am254u & Johhny Chen, jc3066) - HOT-DMZ-FW template that creates two DMZ networks (direct and protected) with a scaled out firewall service between the two. + members: + - hsl_direct_net + - service_instance + - service_policy + network_base: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/network_base.yml + description: ASC External Networks Template + members: + - Internal2-net + - Internal1-net + - Internal3-net \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkMulti/expectedoutputfiles/service_instanceServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkMulti/expectedoutputfiles/service_instanceServiceTemplate.yaml new file mode 100644 index 0000000000..1933f88f6c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkMulti/expectedoutputfiles/service_instanceServiceTemplate.yaml @@ -0,0 +1,451 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: service_instance +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + availability_zone: + hidden: false + immutable: false + type: string + description: Availability zone to create servers in + required: false + status: SUPPORTED + static_routes_list: + hidden: false + immutable: false + type: list + description: Static routes enabled + required: false + status: SUPPORTED + entry_schema: + type: boolean + availability_zone_enable: + hidden: false + immutable: false + type: boolean + description: Indicates availability zone is enabled + required: false + default: false + status: SUPPORTED + service_template_name: + hidden: false + immutable: false + type: string + description: Service template name + required: false + status: SUPPORTED + ordered_interfaces: + hidden: false + immutable: false + type: boolean + description: Indicates if service interface are ordered + required: false + default: false + status: SUPPORTED + flavor: + hidden: false + immutable: false + type: string + description: flavor + required: false + status: SUPPORTED + image_name: + hidden: false + immutable: false + type: string + description: Image name + required: true + status: SUPPORTED + service_type: + hidden: false + immutable: false + type: string + description: Service type + required: true + status: SUPPORTED + constraints: + - valid_values: + - firewall + - analyzer + - source-nat + - loadbalancer + service_interface_type_list: + hidden: false + immutable: false + type: list + description: List of interface types + required: true + status: SUPPORTED + entry_schema: + type: string + constraints: + - valid_values: + - management + - left + - right + - other + service_instance_name: + hidden: false + immutable: false + type: string + description: Service instance name + required: true + status: SUPPORTED + interface_list: + hidden: false + immutable: false + type: list + description: List of interfaces + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.contrail.InterfaceData + service_mode: + hidden: false + immutable: false + type: string + description: Service mode + required: true + status: SUPPORTED + constraints: + - valid_values: + - transparent + - in-network + - in-network-nat + shared_ip_list: + hidden: false + immutable: false + type: list + description: Shared ips enabled + required: false + status: SUPPORTED + entry_schema: + type: boolean + node_templates: + port_0: + type: org.openecomp.resource.cp.nodes.heat.network.contrail.Port + properties: + static_routes: + get_input: + - interface_list + - 0 + - static_routes + virtual_network: + get_input: + - interface_list + - 0 + - virtual_network + static_route: + get_input: + - static_routes_list + - 0 + allowed_address_pairs: + get_input: + - interface_list + - 0 + - allowed_address_pairs + shared_ip: + get_input: + - shared_ip_list + - 0 + ip_address: + get_input: + - interface_list + - 0 + - ip_address + interface_type: + get_input: + - service_interface_type_list + - 0 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: service_instance + relationship: tosca.relationships.network.BindsTo + port_1: + type: org.openecomp.resource.cp.nodes.heat.network.contrail.Port + properties: + static_routes: + get_input: + - interface_list + - 1 + - static_routes + virtual_network: + get_input: + - interface_list + - 1 + - virtual_network + static_route: + get_input: + - static_routes_list + - 1 + allowed_address_pairs: + get_input: + - interface_list + - 1 + - allowed_address_pairs + shared_ip: + get_input: + - shared_ip_list + - 1 + ip_address: + get_input: + - interface_list + - 1 + - ip_address + interface_type: + get_input: + - service_interface_type_list + - 1 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: service_instance + relationship: tosca.relationships.network.BindsTo + port_2: + type: org.openecomp.resource.cp.nodes.heat.network.contrail.Port + properties: + static_routes: + get_input: + - interface_list + - 2 + - static_routes + virtual_network: + get_input: + - interface_list + - 2 + - virtual_network + static_route: + get_input: + - static_routes_list + - 2 + allowed_address_pairs: + get_input: + - interface_list + - 2 + - allowed_address_pairs + shared_ip: + get_input: + - shared_ip_list + - 2 + ip_address: + get_input: + - interface_list + - 2 + - ip_address + interface_type: + get_input: + - service_interface_type_list + - 2 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: service_instance + relationship: tosca.relationships.network.BindsTo + port_3: + type: org.openecomp.resource.cp.nodes.heat.network.contrail.Port + properties: + static_routes: + get_input: + - interface_list + - 3 + - static_routes + virtual_network: + get_input: + - interface_list + - 3 + - virtual_network + static_route: + get_input: + - static_routes_list + - 3 + allowed_address_pairs: + get_input: + - interface_list + - 3 + - allowed_address_pairs + shared_ip: + get_input: + - shared_ip_list + - 3 + ip_address: + get_input: + - interface_list + - 3 + - ip_address + interface_type: + get_input: + - service_interface_type_list + - 3 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: service_instance + relationship: tosca.relationships.network.BindsTo + port_4: + type: org.openecomp.resource.cp.nodes.heat.network.contrail.Port + properties: + static_routes: + get_input: + - interface_list + - 4 + - static_routes + virtual_network: + get_input: + - interface_list + - 4 + - virtual_network + static_route: + get_input: + - static_routes_list + - 4 + allowed_address_pairs: + get_input: + - interface_list + - 4 + - allowed_address_pairs + shared_ip: + get_input: + - shared_ip_list + - 4 + ip_address: + get_input: + - interface_list + - 4 + - ip_address + interface_type: + get_input: + - service_interface_type_list + - 4 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: service_instance + relationship: tosca.relationships.network.BindsTo + service_instance: + type: org.openecomp.resource.vfc.nodes.heat.compute_service_template + properties: + flavor: + get_input: flavor + image_name: + get_input: image_name + availability_zone: + get_input: availability_zone + service_type: + get_input: service_type + availability_zone_enable: + get_input: availability_zone_enable + service_template_name: + get_input: service_template_name + service_instance_name: + get_input: service_instance_name + service_mode: + get_input: service_mode + groups: + service_instance: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/OCS-fw.yml + members: + - service_instance + - port_0 + - port_1 + - port_2 + - port_3 + - port_4 + outputs: + tenant_id: + description: Tenant id of the Service Instance + value: + get_attribute: + - service_instance + - tenant_id + fq_name: + description: The FQ name of the service instance + value: + get_attribute: + - service_instance + - fq_name + service_template_name: + description: Service Template of the Service Instance + value: + get_attribute: + - service_instance + - service_template_name + show: + description: All attributes + value: + get_attribute: + - service_instance + - show + active_vms: + description: Number of service VMs active for this Service Instance + value: + get_attribute: + - service_instance + - active_vms + service_instance_name: + description: The name of the service instance + value: + get_attribute: + - service_instance + - service_instance_name + virtual_machines: + description: Service VMs for the Service Instance + value: + get_attribute: + - service_instance + - virtual_machines + status: + description: Status of the service instance + value: + get_attribute: + - service_instance + - status + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.service_template + requirements: + link_port_0: + - port_0 + - link + link_port_1: + - port_1 + - link + link_port_2: + - port_2 + - link + link_port_3: + - port_3 + - link + link_port_4: + - port_4 + - link \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkMulti/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkMulti/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..b7969ccd71 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkMulti/inputfiles/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "OCS-fw.yml", + "type": "HEAT", + "isBase": "false" + }, + { + "file": "network_base.yml", + "type": "HEAT", + "isBase": "true" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkMulti/inputfiles/OCS-fw.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkMulti/inputfiles/OCS-fw.yml new file mode 100644 index 0000000000..dd578c2d8b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkMulti/inputfiles/OCS-fw.yml @@ -0,0 +1,173 @@ +heat_template_version: 2013-05-23 + +description: > + Based on the following reference for the HOT-DMZ-FW template: + Version 3.5 8-10-2015 (Authors: Art Mishurov,am254u & Johhny Chen, jc3066) - HOT-DMZ-FW template that creates two DMZ networks (direct and protected) with a scaled out firewall service between the two. + +parameters: + hsl_direct_net1: + type: string + hsl_direct_net2: + type: string + hsl_direct_net3: + type: string + hsl_direct_net4: + type: string + HSL_direct_net_id: + type: string + description: Name of HSL (Logging) network + HSL_direct_net_cidr: + type: string + description: HSL (Logging) network address (CIDR notation) + HSL_direct_net_gateway: + type: string + description: HSL (Logging) network gateway address + oam_mgmt_net_0_id: + type: string + description: Name of OAM network + Cricket_OCS_direct_net_id: + type: string + description: Name of Cricket OCS network + Cricket_OCS_protected_net_id: + type: string + description: Name of Cricket OCS network + service_instance_name: + type: string + description: Service instance name + service_policy_name: + type: string + description: Policy Name + service_policy_direction: + type: string + description: Direction of Policy + start_src_ports: + type: number + description: Start of src port + end_src_ports: + type: number + description: End of src port + start_dst_ports: + type: number + description: Start of dst port + end_dst_ports: + type: number + description: End of dst port + st_name: + type: string + description: Name of service template + st_mode: + type: string + description: service mode + st_type: + type: string + description: service type + st_image: + type: string + description: Name of the image + st_flavor: + type: string + description: Flavor + st_service_interface_type_list: + type: string + description: List of interface types + st_shared_ip_list: + type: string + description: List of shared ip enabled-disabled + st_static_routes_list: + type: string + description: List of static routes enabled-disabled + st_scaling: + type: string + description: Indicates whether service scaling is enabled + max_num_fw_instances: + type: number + description: maximum number of firewall instances for scaling + availability_zone_1: + type: string + description: availability zone + +resources: + + hsl_direct_net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: HSL_direct_net_id } + + hsl_ip_subnet: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: hsl_direct_net } + cidr: { get_param: HSL_direct_net_cidr } + gateway_ip: { get_param: HSL_direct_net_gateway } + + service_template: + type: OS::Contrail::ServiceTemplate + properties: + name: { get_param: st_name } + service_mode: { get_param: st_mode } + service_type: { get_param: st_type } + image_name: { get_param: st_image } + flavor: { get_param: st_flavor } + service_interface_type_list: { "Fn::Split" : [ ",", Ref: st_service_interface_type_list ] } + shared_ip_list: { "Fn::Split" : [ ",", Ref: st_shared_ip_list ] } + static_routes_list: { "Fn::Split" : [ ",", Ref: st_static_routes_list ] } + service_scaling: { get_param: st_scaling } + + service_instance: + type: OS::Contrail::ServiceInstance + depends_on: [ hsl_ip_subnet] + properties: + name: { get_param: service_instance_name } + availability_zone: { get_param: availability_zone_1 } + service_template: { get_resource: service_template } + scale_out: + max_instances: {get_param: max_num_fw_instances} + interface_list: [ + { + virtual_network: { get_param: hsl_direct_net1 } + }, + { + virtual_network: { get_param: hsl_direct_net2 } + }, + { + virtual_network: { get_param: hsl_direct_net3 } + }, + { + virtual_network: { get_param: hsl_direct_net4 } + }, + { + virtual_network: { get_resource: hsl_direct_net } + } + ] + + service_policy: + type: OS::Contrail::NetworkPolicy + depends_on: [ service_instance ] + properties: + name: { get_param: service_policy_name } + entries: + policy_rule: [ + { + "direction": { get_param: service_policy_direction }, + "protocol": "any", + "src_ports": [{"start_port": {get_param: start_src_ports}, "end_port": {get_param: end_src_ports}}], + "dst_ports": [{"start_port": {get_param: start_dst_ports}, "end_port": {get_param: end_dst_ports}}], + "dst_addresses": [{ "virtual_network": { get_param: Cricket_OCS_direct_net_id }}], + "action_list": { "apply_service": [{ get_resource: service_instance }]}, + "src_addresses": [{ "virtual_network": { get_param: Cricket_OCS_protected_net_id }}], + }, + ] + + service_policy_attach_direct_net: + type: OS::Contrail::AttachPolicy + depends_on: [ service_policy ] + properties: + network: { get_param: Cricket_OCS_direct_net_id } + policy: { get_attr: [service_policy, fq_name] } + + service_policy_attach_protected_net: + type: OS::Contrail::AttachPolicy + depends_on: [ service_policy ] + properties: + network: { get_param: Cricket_OCS_protected_net_id } + policy: { get_attr: [service_policy, fq_name] } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkMulti/inputfiles/network_base.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkMulti/inputfiles/network_base.yml new file mode 100644 index 0000000000..21fef30282 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkMulti/inputfiles/network_base.yml @@ -0,0 +1,47 @@ +heat_template_version: 2013-05-23 + +description: ASC External Networks Template + +parameters: + Internal1_net_name: + type: string + Internal2_net_name: + type: string + Internal1_forwarding_mode: + type: string + Internal2_forwarding_mode: + type: string + Internal1_shared: + type: string + Internal2_shared: + type: string + +resources: + Internal1-net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: Internal1_net_name } + forwarding_mode: { get_param: Internal1_forwarding_mode } + shared: { get_param: Internal1_shared } + + Internal2-net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: Internal2_net_name } + forwarding_mode: { get_param: Internal1_forwarding_mode } + shared: { get_param: Internal1_shared } + + Internal3-net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: Internal2_net_name } + forwarding_mode: { get_param: Internal1_forwarding_mode } + shared: { get_param: Internal1_shared } + +outputs: + hsl_direct_net1: + value: { list_join: [':', { get_attr: [ Internal1-net, fq_name ] } ] } + hsl_direct_net2: + value: { get_attr: [ Internal2-net, fq_name ] } + hsl_direct_net3: + value: {get_resource: Internal3-net} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkNested/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkNested/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..a11b54226b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkNested/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,154 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.st_image: + derived_from: org.openecomp.resource.vfc.nodes.heat.contrail.Compute + org.openecomp.resource.abstract.nodes.heat.service_template: + derived_from: org.openecomp.resource.abstract.nodes.contrail.AbstractSubstitute + requirements: + - link_port_0: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + org.openecomp.resource.abstract.nodes.heat.OCS-fw: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + service_policy_name: + type: string + description: Policy Name + st_static_routes_list: + type: string + description: List of static routes enabled-disabled + st_type: + type: string + description: service type + st_service_interface_type_list: + type: string + description: List of interface types + st_mode: + type: string + description: service mode + Cricket_OCS_protected_net_id: + type: string + description: Name of Cricket OCS network + oam_mgmt_net_0_id: + type: string + description: Name of OAM network + start_dst_ports: + type: float + description: Start of dst port + st_flavor: + type: string + description: Flavor + availability_zone_1: + type: string + description: availability zone + service_instance_name: + type: string + description: Service instance name + st_scaling: + type: string + description: Indicates whether service scaling is enabled + max_num_fw_instances: + type: float + description: maximum number of firewall instances for scaling + start_src_ports: + type: float + description: Start of src port + service_policy_direction: + type: string + description: Direction of Policy + st_name: + type: string + description: Name of service template + hsl_direct_net3: + type: string + hsl_direct_net4: + type: string + HSL_direct_net_gateway: + type: string + description: HSL (Logging) network gateway address + hsl_direct_net1: + type: string + hsl_direct_net2: + type: string + st_image: + type: string + description: Name of the image + st_shared_ip_list: + type: string + description: List of shared ip enabled-disabled + Cricket_OCS_direct_net_id: + type: string + description: Name of Cricket OCS network + network_param: + type: string + end_src_ports: + type: float + description: End of src port + end_dst_ports: + type: float + description: End of dst port + HSL_direct_net_id: + type: string + description: Name of HSL (Logging) network + HSL_direct_net_cidr: + type: string + description: HSL (Logging) network address (CIDR notation) + requirements: + - link_port_0_service_instance: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - network_service_policy: + capability: tosca.capabilities.Attachment + node: tosca.nodes.network.Network + relationship: org.openecomp.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + capabilities: + link_hsl_direct_net: + type: tosca.capabilities.network.Linkable + occurrences: + - 1 + - UNBOUNDED + attachment_hsl_direct_net: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkNested/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkNested/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..53ecba9888 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkNested/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,90 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + Internal1_shared: + hidden: false + immutable: false + type: string + Internal1_forwarding_mode: + hidden: false + immutable: false + type: string + Internal2_net_name: + hidden: false + immutable: false + type: string + Internal2_forwarding_mode: + hidden: false + immutable: false + type: string + Internal2_shared: + hidden: false + immutable: false + type: string + Internal1_net_name: + hidden: false + immutable: false + type: string + node_templates: + Internal1-net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + shared: + get_input: Internal1_shared + forwarding_mode: + get_input: Internal1_forwarding_mode + network_name: + get_input: Internal1_net_name + test_nested: + type: org.openecomp.resource.abstract.nodes.heat.OCS-fw + directives: + - substitutable + properties: + service_template_filter: + substitute_service_template: OCS-fwServiceTemplate.yaml + network_param: Internal1-net + requirements: + - link_port_0: + capability: tosca.capabilities.network.Linkable + node: Internal1-net + relationship: tosca.relationships.network.LinksTo + groups: + main: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/main.yml + description: ASC External Networks Template + members: + - Internal1-net + - test_nested \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkNested/expectedoutputfiles/OCS-fwServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkNested/expectedoutputfiles/OCS-fwServiceTemplate.yaml new file mode 100644 index 0000000000..1f504169ab --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkNested/expectedoutputfiles/OCS-fwServiceTemplate.yaml @@ -0,0 +1,294 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: OCS-fw +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + service_policy_name: + hidden: false + immutable: false + type: string + description: Policy Name + st_static_routes_list: + hidden: false + immutable: false + type: string + description: List of static routes enabled-disabled + st_type: + hidden: false + immutable: false + type: string + description: service type + st_service_interface_type_list: + hidden: false + immutable: false + type: string + description: List of interface types + st_mode: + hidden: false + immutable: false + type: string + description: service mode + Cricket_OCS_protected_net_id: + hidden: false + immutable: false + type: string + description: Name of Cricket OCS network + oam_mgmt_net_0_id: + hidden: false + immutable: false + type: string + description: Name of OAM network + start_dst_ports: + hidden: false + immutable: false + type: float + description: Start of dst port + st_flavor: + hidden: false + immutable: false + type: string + description: Flavor + availability_zone_1: + hidden: false + immutable: false + type: string + description: availability zone + service_instance_name: + hidden: false + immutable: false + type: string + description: Service instance name + st_scaling: + hidden: false + immutable: false + type: string + description: Indicates whether service scaling is enabled + max_num_fw_instances: + hidden: false + immutable: false + type: float + description: maximum number of firewall instances for scaling + start_src_ports: + hidden: false + immutable: false + type: float + description: Start of src port + service_policy_direction: + hidden: false + immutable: false + type: string + description: Direction of Policy + st_name: + hidden: false + immutable: false + type: string + description: Name of service template + hsl_direct_net3: + hidden: false + immutable: false + type: string + hsl_direct_net4: + hidden: false + immutable: false + type: string + HSL_direct_net_gateway: + hidden: false + immutable: false + type: string + description: HSL (Logging) network gateway address + hsl_direct_net1: + hidden: false + immutable: false + type: string + hsl_direct_net2: + hidden: false + immutable: false + type: string + st_image: + hidden: false + immutable: false + type: string + description: Name of the image + st_shared_ip_list: + hidden: false + immutable: false + type: string + description: List of shared ip enabled-disabled + Cricket_OCS_direct_net_id: + hidden: false + immutable: false + type: string + description: Name of Cricket OCS network + network_param: + hidden: false + immutable: false + type: string + end_src_ports: + hidden: false + immutable: false + type: float + description: End of src port + end_dst_ports: + hidden: false + immutable: false + type: float + description: End of dst port + HSL_direct_net_id: + hidden: false + immutable: false + type: string + description: Name of HSL (Logging) network + HSL_direct_net_cidr: + hidden: false + immutable: false + type: string + description: HSL (Logging) network address (CIDR notation) + node_templates: + hsl_direct_net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + network_name: + get_input: HSL_direct_net_id + subnets: + hsl_ip_subnet: + cidr: + get_input: HSL_direct_net_cidr + gateway_ip: + get_input: HSL_direct_net_gateway + service_instance: + type: org.openecomp.resource.abstract.nodes.heat.service_template + directives: + - substitutable + properties: + flavor: + get_input: st_flavor + availability_zone: + get_input: availability_zone_1 + image_name: + get_input: st_image + service_template_filter: + substitute_service_template: service_instanceServiceTemplate.yaml + count: + get_input: max_num_fw_instances + mandatory: false + service_type: + get_input: st_type + static_routes_list: + - token: + - get_input: st_static_routes_list + - ',' + - 0 + service_template_name: + get_input: st_name + service_interface_type_list: + - token: + - get_input: st_service_interface_type_list + - ',' + - 0 + interface_list: + - virtual_network: + get_input: network_param + service_instance_name: + get_input: service_instance_name + service_mode: + get_input: st_mode + shared_ip_list: + - token: + - get_input: st_shared_ip_list + - ',' + - 0 + requirements: + - dependency: + capability: tosca.capabilities.Node + node: hsl_direct_net + relationship: tosca.relationships.DependsOn + service_policy: + type: org.openecomp.resource.vfc.rules.nodes.heat.network.contrail.NetworkRules + properties: + entries: + policy_rule: + - src_ports: + - start_port: + get_input: start_src_ports + end_port: + get_input: end_src_ports + protocol: any + action_list: + apply_service: + - service_instance + dst_addresses: + - virtual_network: + get_input: Cricket_OCS_direct_net_id + dst_ports: + - start_port: + get_input: start_dst_ports + end_port: + get_input: end_dst_ports + src_addresses: + - virtual_network: + get_input: Cricket_OCS_protected_net_id + direction: + get_input: service_policy_direction + name: + get_input: service_policy_name + requirements: + - dependency: + capability: tosca.capabilities.Node + node: service_instance + relationship: tosca.relationships.DependsOn + groups: + OCS-fw: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/OCS-fw.yml + description: | + Based on the following reference for the HOT-DMZ-FW template: Version 3.5 8-10-2015 (Authors: Art Mishurov,am254u & Johhny Chen, jc3066) - HOT-DMZ-FW template that creates two DMZ networks (direct and protected) with a scaled out firewall service between the two. + members: + - hsl_direct_net + - service_instance + - service_policy + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.OCS-fw + capabilities: + link_hsl_direct_net: + - hsl_direct_net + - link + attachment_hsl_direct_net: + - hsl_direct_net + - attachment + requirements: + network_service_policy: + - service_policy + - network + link_port_0_service_instance: + - service_instance + - link_port_0 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkNested/expectedoutputfiles/service_instanceServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkNested/expectedoutputfiles/service_instanceServiceTemplate.yaml new file mode 100644 index 0000000000..bbc95728c9 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkNested/expectedoutputfiles/service_instanceServiceTemplate.yaml @@ -0,0 +1,275 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: service_instance +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + availability_zone: + hidden: false + immutable: false + type: string + description: Availability zone to create servers in + required: false + status: SUPPORTED + static_routes_list: + hidden: false + immutable: false + type: list + description: Static routes enabled + required: false + status: SUPPORTED + entry_schema: + type: boolean + availability_zone_enable: + hidden: false + immutable: false + type: boolean + description: Indicates availability zone is enabled + required: false + default: false + status: SUPPORTED + service_template_name: + hidden: false + immutable: false + type: string + description: Service template name + required: false + status: SUPPORTED + ordered_interfaces: + hidden: false + immutable: false + type: boolean + description: Indicates if service interface are ordered + required: false + default: false + status: SUPPORTED + flavor: + hidden: false + immutable: false + type: string + description: flavor + required: false + status: SUPPORTED + image_name: + hidden: false + immutable: false + type: string + description: Image name + required: true + status: SUPPORTED + service_type: + hidden: false + immutable: false + type: string + description: Service type + required: true + status: SUPPORTED + constraints: + - valid_values: + - firewall + - analyzer + - source-nat + - loadbalancer + service_interface_type_list: + hidden: false + immutable: false + type: list + description: List of interface types + required: true + status: SUPPORTED + entry_schema: + type: string + constraints: + - valid_values: + - management + - left + - right + - other + service_instance_name: + hidden: false + immutable: false + type: string + description: Service instance name + required: true + status: SUPPORTED + interface_list: + hidden: false + immutable: false + type: list + description: List of interfaces + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.contrail.InterfaceData + service_mode: + hidden: false + immutable: false + type: string + description: Service mode + required: true + status: SUPPORTED + constraints: + - valid_values: + - transparent + - in-network + - in-network-nat + shared_ip_list: + hidden: false + immutable: false + type: list + description: Shared ips enabled + required: false + status: SUPPORTED + entry_schema: + type: boolean + node_templates: + port_0: + type: org.openecomp.resource.cp.nodes.heat.network.contrail.Port + properties: + static_routes: + get_input: + - interface_list + - 0 + - static_routes + virtual_network: + get_input: + - interface_list + - 0 + - virtual_network + static_route: + get_input: + - static_routes_list + - 0 + allowed_address_pairs: + get_input: + - interface_list + - 0 + - allowed_address_pairs + shared_ip: + get_input: + - shared_ip_list + - 0 + ip_address: + get_input: + - interface_list + - 0 + - ip_address + interface_type: + get_input: + - service_interface_type_list + - 0 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: service_instance + relationship: tosca.relationships.network.BindsTo + service_instance: + type: org.openecomp.resource.vfc.nodes.heat.st_image + properties: + flavor: + get_input: flavor + image_name: + get_input: image_name + availability_zone: + get_input: availability_zone + service_type: + get_input: service_type + availability_zone_enable: + get_input: availability_zone_enable + service_template_name: + get_input: service_template_name + service_instance_name: + get_input: service_instance_name + service_mode: + get_input: service_mode + groups: + service_instance: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/OCS-fw.yml + members: + - service_instance + - port_0 + outputs: + tenant_id: + description: Tenant id of the Service Instance + value: + get_attribute: + - service_instance + - tenant_id + fq_name: + description: The FQ name of the service instance + value: + get_attribute: + - service_instance + - fq_name + service_template_name: + description: Service Template of the Service Instance + value: + get_attribute: + - service_instance + - service_template_name + show: + description: All attributes + value: + get_attribute: + - service_instance + - show + active_vms: + description: Number of service VMs active for this Service Instance + value: + get_attribute: + - service_instance + - active_vms + service_instance_name: + description: The name of the service instance + value: + get_attribute: + - service_instance + - service_instance_name + virtual_machines: + description: Service VMs for the Service Instance + value: + get_attribute: + - service_instance + - virtual_machines + status: + description: Status of the service instance + value: + get_attribute: + - service_instance + - status + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.service_template + requirements: + link_port_0: + - port_0 + - link \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkNested/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkNested/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..ba27604c3f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkNested/inputfiles/MANIFEST.json @@ -0,0 +1,16 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "OCS-fw.yml", + "type": "HEAT", + "isBase": "false" + }, + { + "file": "main.yml", + "type": "HEAT" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkNested/inputfiles/OCS-fw.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkNested/inputfiles/OCS-fw.yml new file mode 100644 index 0000000000..86c3fcadc8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkNested/inputfiles/OCS-fw.yml @@ -0,0 +1,163 @@ +heat_template_version: 2013-05-23 + +description: > + Based on the following reference for the HOT-DMZ-FW template: + Version 3.5 8-10-2015 (Authors: Art Mishurov,am254u & Johhny Chen, jc3066) - HOT-DMZ-FW template that creates two DMZ networks (direct and protected) with a scaled out firewall service between the two. + +parameters: + hsl_direct_net1: + type: string + hsl_direct_net2: + type: string + hsl_direct_net3: + type: string + hsl_direct_net4: + type: string + HSL_direct_net_id: + type: string + description: Name of HSL (Logging) network + HSL_direct_net_cidr: + type: string + description: HSL (Logging) network address (CIDR notation) + HSL_direct_net_gateway: + type: string + description: HSL (Logging) network gateway address + oam_mgmt_net_0_id: + type: string + description: Name of OAM network + Cricket_OCS_direct_net_id: + type: string + description: Name of Cricket OCS network + Cricket_OCS_protected_net_id: + type: string + description: Name of Cricket OCS network + service_instance_name: + type: string + description: Service instance name + service_policy_name: + type: string + description: Policy Name + service_policy_direction: + type: string + description: Direction of Policy + start_src_ports: + type: number + description: Start of src port + end_src_ports: + type: number + description: End of src port + start_dst_ports: + type: number + description: Start of dst port + end_dst_ports: + type: number + description: End of dst port + st_name: + type: string + description: Name of service template + st_mode: + type: string + description: service mode + st_type: + type: string + description: service type + st_image: + type: string + description: Name of the image + st_flavor: + type: string + description: Flavor + st_service_interface_type_list: + type: string + description: List of interface types + st_shared_ip_list: + type: string + description: List of shared ip enabled-disabled + st_static_routes_list: + type: string + description: List of static routes enabled-disabled + st_scaling: + type: string + description: Indicates whether service scaling is enabled + max_num_fw_instances: + type: number + description: maximum number of firewall instances for scaling + availability_zone_1: + type: string + description: availability zone + network_param: + type: string + +resources: + + hsl_direct_net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: HSL_direct_net_id } + + hsl_ip_subnet: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: hsl_direct_net } + cidr: { get_param: HSL_direct_net_cidr } + gateway_ip: { get_param: HSL_direct_net_gateway } + + service_template: + type: OS::Contrail::ServiceTemplate + properties: + name: { get_param: st_name } + service_mode: { get_param: st_mode } + service_type: { get_param: st_type } + image_name: { get_param: st_image } + flavor: { get_param: st_flavor } + service_interface_type_list: { "Fn::Split" : [ ",", Ref: st_service_interface_type_list ] } + shared_ip_list: { "Fn::Split" : [ ",", Ref: st_shared_ip_list ] } + static_routes_list: { "Fn::Split" : [ ",", Ref: st_static_routes_list ] } + service_scaling: { get_param: st_scaling } + + service_instance: + type: OS::Contrail::ServiceInstance + depends_on: [ hsl_ip_subnet] + properties: + name: { get_param: service_instance_name } + availability_zone: { get_param: availability_zone_1 } + service_template: { get_resource: service_template } + scale_out: + max_instances: {get_param: max_num_fw_instances} + interface_list: [ + { + virtual_network: { get_param: network_param } + } + ] + + service_policy: + type: OS::Contrail::NetworkPolicy + depends_on: [ service_instance ] + properties: + name: { get_param: service_policy_name } + entries: + policy_rule: [ + { + "direction": { get_param: service_policy_direction }, + "protocol": "any", + "src_ports": [{"start_port": {get_param: start_src_ports}, "end_port": {get_param: end_src_ports}}], + "dst_ports": [{"start_port": {get_param: start_dst_ports}, "end_port": {get_param: end_dst_ports}}], + "dst_addresses": [{ "virtual_network": { get_param: Cricket_OCS_direct_net_id }}], + "action_list": { "apply_service": [{ get_resource: service_instance }]}, + "src_addresses": [{ "virtual_network": { get_param: Cricket_OCS_protected_net_id }}], + }, + ] + + service_policy_attach_direct_net: + type: OS::Contrail::AttachPolicy + depends_on: [ service_policy ] + properties: + network: { get_param: Cricket_OCS_direct_net_id } + policy: { get_attr: [service_policy, fq_name] } + + service_policy_attach_protected_net: + type: OS::Contrail::AttachPolicy + depends_on: [ service_policy ] + properties: + network: { get_param: Cricket_OCS_protected_net_id } + policy: { get_attr: [service_policy, fq_name] } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkNested/inputfiles/main.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkNested/inputfiles/main.yml new file mode 100644 index 0000000000..a1f7dc932d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrail2serviceinstance/sharedNetworkNested/inputfiles/main.yml @@ -0,0 +1,30 @@ +heat_template_version: 2013-05-23 + +description: ASC External Networks Template + +parameters: + Internal1_net_name: + type: string + Internal2_net_name: + type: string + Internal1_forwarding_mode: + type: string + Internal2_forwarding_mode: + type: string + Internal1_shared: + type: string + Internal2_shared: + type: string + +resources: + Internal1-net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: Internal1_net_name } + forwarding_mode: { get_param: Internal1_forwarding_mode } + shared: { get_param: Internal1_shared } + + test_nested: + type: OCS-fw.yml + properties: + network_param: { get_resource: Internal1-net} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrailv2VMinterface/listNet/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrailv2VMinterface/listNet/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..23c2d851f7 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrailv2VMinterface/listNet/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,265 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + template_PortTuple_LB1: + hidden: false + immutable: false + type: string + description: dummy + lb_st_interface_type_oam: + hidden: false + immutable: false + type: string + description: dummy + oam_sec_group_name: + hidden: false + immutable: false + type: string + description: dummy + nems_traffic_name: + hidden: false + immutable: false + type: string + description: dummy + network_ipam_refs_data_ipam_subnets_addr_from_start_true: + hidden: false + immutable: false + type: string + description: dummy + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2: + hidden: false + immutable: false + type: string + description: dummy + jsa_net_name: + hidden: false + immutable: false + type: string + description: dummy + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2: + hidden: false + immutable: false + type: string + description: dummy + node_templates: + jsa_net3: + type: org.openecomp.resource.vl.nodes.heat.network.contrailV2.VirtualNetwork + properties: + network_ipam_refs_data: + - network_ipam_refs_data_ipam_subnets: + - network_ipam_refs_data_ipam_subnets_subnet: + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len: + get_input: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2 + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix: + get_input: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2 + network_ipam_refs_data_ipam_subnets_addr_from_start: + get_input: network_ipam_refs_data_ipam_subnets_addr_from_start_true + network_name: aaa + template_VMInt_OAM_lb_5: + type: org.openecomp.resource.cp.nodes.heat.contrailV2.VirtualMachineInterface + properties: + security_group_refs: + - get_input: oam_sec_group_name + virtual_network_refs: [ + ] + virtual_machine_interface_properties: + virtual_machine_interface_properties_service_interface_type: + get_input: lb_st_interface_type_oam + port_tuple_refs: + - get_input: template_PortTuple_LB1 + jsa_net2: + type: org.openecomp.resource.vl.nodes.heat.network.contrailV2.VirtualNetwork + properties: + network_ipam_refs_data: + - network_ipam_refs_data_ipam_subnets: + - network_ipam_refs_data_ipam_subnets_subnet: + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len: + get_input: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2 + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix: + get_input: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2 + network_ipam_refs_data_ipam_subnets_addr_from_start: + get_input: network_ipam_refs_data_ipam_subnets_addr_from_start_true + network_name: aaa + template_VMInt_OAM_lb_6: + type: org.openecomp.resource.cp.nodes.heat.contrailV2.VirtualMachineInterface + properties: + security_group_refs: + - get_input: oam_sec_group_name + virtual_network_refs: + get_attribute: + - jsa_net3 + - fq_name + virtual_machine_interface_properties: + virtual_machine_interface_properties_service_interface_type: + get_input: lb_st_interface_type_oam + port_tuple_refs: + - get_input: template_PortTuple_LB1 + template_VMInt_OAM_lb_7: + type: org.openecomp.resource.cp.nodes.heat.contrailV2.VirtualMachineInterface + properties: + security_group_refs: + - get_input: oam_sec_group_name + virtual_machine_interface_properties: + virtual_machine_interface_properties_service_interface_type: + get_input: lb_st_interface_type_oam + port_tuple_refs: + - get_input: template_PortTuple_LB1 + jsa_net5: + type: org.openecomp.resource.vl.nodes.heat.network.contrailV2.VirtualNetwork + properties: + network_ipam_refs_data: + - network_ipam_refs_data_ipam_subnets: + - network_ipam_refs_data_ipam_subnets_subnet: + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len: + get_input: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2 + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix: + get_input: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2 + network_ipam_refs_data_ipam_subnets_addr_from_start: + get_input: network_ipam_refs_data_ipam_subnets_addr_from_start_true + network_name: aaa + jsa_net4: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + network_name: + get_input: nems_traffic_name + template_VMInt_OAM_lb_1: + type: org.openecomp.resource.cp.nodes.heat.contrailV2.VirtualMachineInterface + properties: + security_group_refs: + - get_input: oam_sec_group_name + virtual_network_refs: + - jsa_net1 + - jsa_net5 + virtual_machine_interface_properties: + virtual_machine_interface_properties_service_interface_type: + get_input: lb_st_interface_type_oam + port_tuple_refs: + - get_input: template_PortTuple_LB1 + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: jsa_net1 + relationship: tosca.relationships.network.LinksTo + template_VMInt_OAM_lb_2: + type: org.openecomp.resource.cp.nodes.heat.contrailV2.VirtualMachineInterface + properties: + security_group_refs: + - get_input: oam_sec_group_name + virtual_network_refs: + - list_join: + - ':' + - get_attribute: + - jsa_net2 + - fq_name + - list_join: + - ':' + - get_attribute: + - jsa_net5 + - fq_name + virtual_machine_interface_properties: + virtual_machine_interface_properties_service_interface_type: + get_input: lb_st_interface_type_oam + port_tuple_refs: + - get_input: template_PortTuple_LB1 + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: jsa_net2 + relationship: tosca.relationships.network.LinksTo + jsa_net1: + type: org.openecomp.resource.vl.nodes.heat.network.contrailV2.VirtualNetwork + properties: + network_ipam_refs_data: + - network_ipam_refs_data_ipam_subnets: + - network_ipam_refs_data_ipam_subnets_subnet: + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len: + get_input: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2 + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix: + get_input: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2 + network_ipam_refs_data_ipam_subnets_addr_from_start: + get_input: network_ipam_refs_data_ipam_subnets_addr_from_start_true + network_name: aaa + template_VMInt_OAM_lb_3: + type: org.openecomp.resource.cp.nodes.heat.contrailV2.VirtualMachineInterface + properties: + security_group_refs: + - get_input: oam_sec_group_name + virtual_network_refs: + - get_attribute: + - jsa_net3 + - fq_name + - get_attribute: + - jsa_net5 + - fq_name + virtual_machine_interface_properties: + virtual_machine_interface_properties_service_interface_type: + get_input: lb_st_interface_type_oam + port_tuple_refs: + - get_input: template_PortTuple_LB1 + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: jsa_net3 + relationship: tosca.relationships.network.LinksTo + template_VMInt_OAM_lb_4: + type: org.openecomp.resource.cp.nodes.heat.contrailV2.VirtualMachineInterface + properties: + security_group_refs: + - get_input: oam_sec_group_name + virtual_network_refs: + - get_attribute: + - jsa_net4 + - fq_name + virtual_machine_interface_properties: + virtual_machine_interface_properties_service_interface_type: + get_input: lb_st_interface_type_oam + port_tuple_refs: + - get_input: template_PortTuple_LB1 + groups: + hot_template: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/hot_template.yml + description: cmaui server template for vMMSC + members: + - jsa_net3 + - template_VMInt_OAM_lb_5 + - jsa_net2 + - template_VMInt_OAM_lb_6 + - template_VMInt_OAM_lb_7 + - jsa_net5 + - jsa_net4 + - template_VMInt_OAM_lb_1 + - template_VMInt_OAM_lb_2 + - jsa_net1 + - template_VMInt_OAM_lb_3 + - template_VMInt_OAM_lb_4 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrailv2VMinterface/listNet/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrailv2VMinterface/listNet/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..70cdc7d237 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrailv2VMinterface/listNet/inputfiles/MANIFEST.json @@ -0,0 +1,11 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volumes", + "version": "2013-05-23", + "data": [ + { + "file": "hot_template.yml", + "type": "HEAT" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrailv2VMinterface/listNet/inputfiles/hot_template.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrailv2VMinterface/listNet/inputfiles/hot_template.yml new file mode 100644 index 0000000000..46e80667ab --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrailv2VMinterface/listNet/inputfiles/hot_template.yml @@ -0,0 +1,177 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + network_ipam_refs_data_ipam_subnets_addr_from_start_true: + description: dummy + type: string + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2: + description: dummy + type: string + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2: + description: dummy + type: string + lb_st_interface_type_oam: + description: dummy + type: string + template_PortTuple_LB1: + description: dummy + type: string + oam_sec_group_name: + description: dummy + type: string + jsa_net_name: + description: dummy + type: string + nems_traffic_name: + description: dummy + type: string + +resources: + template_VMInt_OAM_lb_1: + type: OS::ContrailV2::VirtualMachineInterface + properties: + virtual_machine_interface_properties: + { + virtual_machine_interface_properties_service_interface_type: { get_param: lb_st_interface_type_oam }, + } + virtual_network_refs: [{ get_resource: jsa_net1 },{ get_resource: jsa_net5 }] + port_tuple_refs: [{ get_param: template_PortTuple_LB1 }] + security_group_refs: [{ get_param: oam_sec_group_name}] + + jsa_net1: + properties: + name: aaa + network_ipam_refs_data: + - + network_ipam_refs_data_ipam_subnets: + - + network_ipam_refs_data_ipam_subnets_addr_from_start: + get_param: network_ipam_refs_data_ipam_subnets_addr_from_start_true + network_ipam_refs_data_ipam_subnets_subnet: + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix: + get_param: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2 + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len: + get_param: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2 + type: "OS::ContrailV2::VirtualNetwork" + + template_VMInt_OAM_lb_2: + type: OS::ContrailV2::VirtualMachineInterface + properties: + virtual_machine_interface_properties: + { + virtual_machine_interface_properties_service_interface_type: { get_param: lb_st_interface_type_oam }, + } + virtual_network_refs: [ { list_join: [':', { get_attr: [ jsa_net2, fq_name ] } ] },{ list_join: [':', { get_attr: [ jsa_net5, fq_name ] } ] }] + port_tuple_refs: [{ get_param: template_PortTuple_LB1 }] + security_group_refs: [{ get_param: oam_sec_group_name}] + + jsa_net2: + properties: + name: aaa + network_ipam_refs_data: + - + network_ipam_refs_data_ipam_subnets: + - + network_ipam_refs_data_ipam_subnets_addr_from_start: + get_param: network_ipam_refs_data_ipam_subnets_addr_from_start_true + network_ipam_refs_data_ipam_subnets_subnet: + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix: + get_param: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2 + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len: + get_param: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2 + type: "OS::ContrailV2::VirtualNetwork" + + template_VMInt_OAM_lb_3: + type: OS::ContrailV2::VirtualMachineInterface + properties: + virtual_machine_interface_properties: + { + virtual_machine_interface_properties_service_interface_type: { get_param: lb_st_interface_type_oam }, + } + virtual_network_refs: [{ get_attr: [ jsa_net3, fq_name ] } ,{ get_attr: [ jsa_net5, fq_name ] }] + port_tuple_refs: [{ get_param: template_PortTuple_LB1 }] + security_group_refs: [{ get_param: oam_sec_group_name}] + + jsa_net3: + properties: + name: aaa + network_ipam_refs_data: + - + network_ipam_refs_data_ipam_subnets: + - + network_ipam_refs_data_ipam_subnets_addr_from_start: + get_param: network_ipam_refs_data_ipam_subnets_addr_from_start_true + network_ipam_refs_data_ipam_subnets_subnet: + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix: + get_param: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2 + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len: + get_param: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2 + type: "OS::ContrailV2::VirtualNetwork" + + template_VMInt_OAM_lb_4: + type: OS::ContrailV2::VirtualMachineInterface + properties: + virtual_machine_interface_properties: + { + virtual_machine_interface_properties_service_interface_type: { get_param: lb_st_interface_type_oam }, + } + virtual_network_refs: [{ get_attr: [ jsa_net4, fq_name ] } ] # should not connect to contrail network + port_tuple_refs: [{ get_param: template_PortTuple_LB1 }] + security_group_refs: [{ get_param: oam_sec_group_name}] + + template_VMInt_OAM_lb_5: + type: OS::ContrailV2::VirtualMachineInterface + properties: + virtual_machine_interface_properties: + { + virtual_machine_interface_properties_service_interface_type: { get_param: lb_st_interface_type_oam }, + } + virtual_network_refs: [] + port_tuple_refs: [{ get_param: template_PortTuple_LB1 }] + security_group_refs: [{ get_param: oam_sec_group_name}] + + template_VMInt_OAM_lb_6: + type: OS::ContrailV2::VirtualMachineInterface + properties: + virtual_machine_interface_properties: + { + virtual_machine_interface_properties_service_interface_type: { get_param: lb_st_interface_type_oam }, + } + virtual_network_refs: { get_attr: [ jsa_net3, fq_name ] } + port_tuple_refs: [{ get_param: template_PortTuple_LB1 }] + security_group_refs: [{ get_param: oam_sec_group_name}] + + + + template_VMInt_OAM_lb_7: + type: OS::ContrailV2::VirtualMachineInterface + properties: + virtual_machine_interface_properties: + { + virtual_machine_interface_properties_service_interface_type: { get_param: lb_st_interface_type_oam }, + } + port_tuple_refs: [{ get_param: template_PortTuple_LB1 }] + security_group_refs: [{ get_param: oam_sec_group_name}] + + jsa_net4: + type: OS::Contrail::VirtualNetwork + properties: + name: {get_param: nems_traffic_name} + + jsa_net5: + properties: + name: aaa + network_ipam_refs_data: + - + network_ipam_refs_data_ipam_subnets: + - + network_ipam_refs_data_ipam_subnets_addr_from_start: + get_param: network_ipam_refs_data_ipam_subnets_addr_from_start_true + network_ipam_refs_data_ipam_subnets_subnet: + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix: + get_param: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2 + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len: + get_param: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2 + type: "OS::ContrailV2::VirtualNetwork" \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrailv2VMinterface/oneNet/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrailv2VMinterface/oneNet/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..71dbe1a8c6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrailv2VMinterface/oneNet/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,203 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + template_PortTuple_LB1: + hidden: false + immutable: false + type: string + description: dummy + lb_st_interface_type_oam: + hidden: false + immutable: false + type: string + description: dummy + oam_sec_group_name: + hidden: false + immutable: false + type: string + description: dummy + nems_traffic_name: + hidden: false + immutable: false + type: string + description: dummy + network_ipam_refs_data_ipam_subnets_addr_from_start_true: + hidden: false + immutable: false + type: string + description: dummy + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2: + hidden: false + immutable: false + type: string + description: dummy + jsa_net_name: + hidden: false + immutable: false + type: string + description: dummy + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2: + hidden: false + immutable: false + type: string + description: dummy + node_templates: + jsa_net3: + type: org.openecomp.resource.vl.nodes.heat.network.contrailV2.VirtualNetwork + properties: + network_ipam_refs_data: + - network_ipam_refs_data_ipam_subnets: + - network_ipam_refs_data_ipam_subnets_subnet: + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len: + get_input: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2 + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix: + get_input: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2 + network_ipam_refs_data_ipam_subnets_addr_from_start: + get_input: network_ipam_refs_data_ipam_subnets_addr_from_start_true + network_name: aaa + jsa_net2: + type: org.openecomp.resource.vl.nodes.heat.network.contrailV2.VirtualNetwork + properties: + network_ipam_refs_data: + - network_ipam_refs_data_ipam_subnets: + - network_ipam_refs_data_ipam_subnets_subnet: + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len: + get_input: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2 + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix: + get_input: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2 + network_ipam_refs_data_ipam_subnets_addr_from_start: + get_input: network_ipam_refs_data_ipam_subnets_addr_from_start_true + network_name: aaa + jsa_net4: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + network_name: + get_input: nems_traffic_name + template_VMInt_OAM_lb_1: + type: org.openecomp.resource.cp.nodes.heat.contrailV2.VirtualMachineInterface + properties: + security_group_refs: + - get_input: oam_sec_group_name + virtual_network_refs: + - jsa_net1 + virtual_machine_interface_properties: + virtual_machine_interface_properties_service_interface_type: + get_input: lb_st_interface_type_oam + port_tuple_refs: + - get_input: template_PortTuple_LB1 + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: jsa_net1 + relationship: tosca.relationships.network.LinksTo + template_VMInt_OAM_lb_2: + type: org.openecomp.resource.cp.nodes.heat.contrailV2.VirtualMachineInterface + properties: + security_group_refs: + - get_input: oam_sec_group_name + virtual_network_refs: + - list_join: + - ':' + - get_attribute: + - jsa_net2 + - fq_name + virtual_machine_interface_properties: + virtual_machine_interface_properties_service_interface_type: + get_input: lb_st_interface_type_oam + port_tuple_refs: + - get_input: template_PortTuple_LB1 + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: jsa_net2 + relationship: tosca.relationships.network.LinksTo + jsa_net1: + type: org.openecomp.resource.vl.nodes.heat.network.contrailV2.VirtualNetwork + properties: + network_ipam_refs_data: + - network_ipam_refs_data_ipam_subnets: + - network_ipam_refs_data_ipam_subnets_subnet: + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len: + get_input: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2 + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix: + get_input: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2 + network_ipam_refs_data_ipam_subnets_addr_from_start: + get_input: network_ipam_refs_data_ipam_subnets_addr_from_start_true + network_name: aaa + template_VMInt_OAM_lb_3: + type: org.openecomp.resource.cp.nodes.heat.contrailV2.VirtualMachineInterface + properties: + security_group_refs: + - get_input: oam_sec_group_name + virtual_network_refs: + - get_attribute: + - jsa_net3 + - fq_name + virtual_machine_interface_properties: + virtual_machine_interface_properties_service_interface_type: + get_input: lb_st_interface_type_oam + port_tuple_refs: + - get_input: template_PortTuple_LB1 + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: jsa_net3 + relationship: tosca.relationships.network.LinksTo + template_VMInt_OAM_lb_4: + type: org.openecomp.resource.cp.nodes.heat.contrailV2.VirtualMachineInterface + properties: + security_group_refs: + - get_input: oam_sec_group_name + virtual_network_refs: + - get_attribute: + - jsa_net4 + - fq_name + virtual_machine_interface_properties: + virtual_machine_interface_properties_service_interface_type: + get_input: lb_st_interface_type_oam + port_tuple_refs: + - get_input: template_PortTuple_LB1 + groups: + hot_template: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/hot_template.yml + description: cmaui server template for vMMSC + members: + - jsa_net3 + - jsa_net2 + - jsa_net4 + - template_VMInt_OAM_lb_1 + - template_VMInt_OAM_lb_2 + - jsa_net1 + - template_VMInt_OAM_lb_3 + - template_VMInt_OAM_lb_4 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrailv2VMinterface/oneNet/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrailv2VMinterface/oneNet/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..70cdc7d237 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrailv2VMinterface/oneNet/inputfiles/MANIFEST.json @@ -0,0 +1,11 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volumes", + "version": "2013-05-23", + "data": [ + { + "file": "hot_template.yml", + "type": "HEAT" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrailv2VMinterface/oneNet/inputfiles/hot_template.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrailv2VMinterface/oneNet/inputfiles/hot_template.yml new file mode 100644 index 0000000000..b771be1c0a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/contrailv2VMinterface/oneNet/inputfiles/hot_template.yml @@ -0,0 +1,128 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + network_ipam_refs_data_ipam_subnets_addr_from_start_true: + description: dummy + type: string + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2: + description: dummy + type: string + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2: + description: dummy + type: string + lb_st_interface_type_oam: + description: dummy + type: string + template_PortTuple_LB1: + description: dummy + type: string + oam_sec_group_name: + description: dummy + type: string + jsa_net_name: + description: dummy + type: string + nems_traffic_name: + description: dummy + type: string + +resources: + template_VMInt_OAM_lb_1: + type: OS::ContrailV2::VirtualMachineInterface + properties: + virtual_machine_interface_properties: + { + virtual_machine_interface_properties_service_interface_type: { get_param: lb_st_interface_type_oam }, + } + virtual_network_refs: [{ get_resource: jsa_net1 }] + port_tuple_refs: [{ get_param: template_PortTuple_LB1 }] + security_group_refs: [{ get_param: oam_sec_group_name}] + + jsa_net1: + properties: + name: aaa + network_ipam_refs_data: + - + network_ipam_refs_data_ipam_subnets: + - + network_ipam_refs_data_ipam_subnets_addr_from_start: + get_param: network_ipam_refs_data_ipam_subnets_addr_from_start_true + network_ipam_refs_data_ipam_subnets_subnet: + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix: + get_param: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2 + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len: + get_param: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2 + type: "OS::ContrailV2::VirtualNetwork" + + template_VMInt_OAM_lb_2: + type: OS::ContrailV2::VirtualMachineInterface + properties: + virtual_machine_interface_properties: + { + virtual_machine_interface_properties_service_interface_type: { get_param: lb_st_interface_type_oam }, + } + virtual_network_refs: [ { list_join: [':', { get_attr: [ jsa_net2, fq_name ] } ] }] + port_tuple_refs: [{ get_param: template_PortTuple_LB1 }] + security_group_refs: [{ get_param: oam_sec_group_name}] + + jsa_net2: + properties: + name: aaa + network_ipam_refs_data: + - + network_ipam_refs_data_ipam_subnets: + - + network_ipam_refs_data_ipam_subnets_addr_from_start: + get_param: network_ipam_refs_data_ipam_subnets_addr_from_start_true + network_ipam_refs_data_ipam_subnets_subnet: + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix: + get_param: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2 + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len: + get_param: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2 + type: "OS::ContrailV2::VirtualNetwork" + + template_VMInt_OAM_lb_3: + type: OS::ContrailV2::VirtualMachineInterface + properties: + virtual_machine_interface_properties: + { + virtual_machine_interface_properties_service_interface_type: { get_param: lb_st_interface_type_oam }, + } + virtual_network_refs: [{ get_attr: [ jsa_net3, fq_name ] } ] + port_tuple_refs: [{ get_param: template_PortTuple_LB1 }] + security_group_refs: [{ get_param: oam_sec_group_name}] + + jsa_net3: + properties: + name: aaa + network_ipam_refs_data: + - + network_ipam_refs_data_ipam_subnets: + - + network_ipam_refs_data_ipam_subnets_addr_from_start: + get_param: network_ipam_refs_data_ipam_subnets_addr_from_start_true + network_ipam_refs_data_ipam_subnets_subnet: + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix: + get_param: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2 + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len: + get_param: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2 + type: "OS::ContrailV2::VirtualNetwork" + + template_VMInt_OAM_lb_4: + type: OS::ContrailV2::VirtualMachineInterface + properties: + virtual_machine_interface_properties: + { + virtual_machine_interface_properties_service_interface_type: { get_param: lb_st_interface_type_oam }, + } + virtual_network_refs: [{ get_attr: [ jsa_net4, fq_name ] } ] # should not connect to contrail network + port_tuple_refs: [{ get_param: template_PortTuple_LB1 }] + security_group_refs: [{ get_param: oam_sec_group_name}] + + jsa_net4: + type: OS::Contrail::VirtualNetwork + properties: + name: {get_param: nems_traffic_name} + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/AbstractSubstituteGlobalTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/AbstractSubstituteGlobalTypesServiceTemplate.yaml new file mode 100644 index 0000000000..f94194186f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/AbstractSubstituteGlobalTypesServiceTemplate.yaml @@ -0,0 +1,88 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: AbstractSubstituteGlobalTypes + template_version: 1.0.0 +description: Abstract Substitute Global Types +imports: + common_definitions: + file: CommonGlobalTypesServiceTemplate.yaml +data_types: + org.openecomp.datatypes.heat.substitution.SubstitutionFiltering: + derived_from: tosca.datatypes.Root + description: Substitution Filter + properties: + substitute_service_template: + type: string + description: Substitute Service Template + required: true + status: SUPPORTED + index_value: + type: integer + description: Index value of the substitution service template runtime instance + required: false + default: 0 + status: SUPPORTED + constraints: + - greater_or_equal: 0 + count: + type: string + description: Count + required: false + default: 1 + status: SUPPORTED + scaling_enabled: + type: boolean + description: Indicates whether service scaling is enabled + required: false + default: true + status: SUPPORTED + mandatory: + type: boolean + description: Mandatory + required: false + default: true + status: SUPPORTED + org.openecomp.datatypes.heat.substitution.SubstitutionFilter: + derived_from: tosca.datatypes.Root + description: Substitution Filter + properties: + substitute_service_template: + type: string + description: Substitute Service Template + required: true + status: SUPPORTED + index_variable: + type: string + description: Index variable + required: false + default: '%index%' + status: SUPPORTED + constraints: + - min_length: 3 + count: + type: string + description: Count + required: false + default: 1 + status: SUPPORTED + scaling_enabled: + type: boolean + description: Indicates whether service scaling is enabled + required: false + default: true + status: SUPPORTED + mandatory: + type: boolean + description: Mandatory + required: false + default: true + status: SUPPORTED +node_types: + org.openecomp.resource.abstract.nodes.AbstractSubstitute: + derived_from: tosca.nodes.Root + properties: + service_template_filter: + type: org.openecomp.datatypes.heat.substitution.SubstitutionFiltering + description: Substitution Filter + required: true + status: SUPPORTED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/CinderVolumeGlobalTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/CinderVolumeGlobalTypesServiceTemplate.yaml new file mode 100644 index 0000000000..03add7648e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/CinderVolumeGlobalTypesServiceTemplate.yaml @@ -0,0 +1,178 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: CinderVolumeGlobalTypes + template_version: 1.0.0 +description: Cinder Volume TOSCA Global Types +relationship_types: + org.openecomp.relationships.heat.cinder.VolumeAttachesTo: + derived_from: tosca.relationships.AttachesTo + description: This type represents an attachment relationship for associating volume + properties: + volume_id: + type: string + description: The ID of the volume to be attached + required: true + status: SUPPORTED + location: + type: string + description: The location where the volume is exposed on the instance, mountpoint + required: false + status: SUPPORTED + instance_uuid: + type: string + description: The ID of the server to which the volume attaches + required: true + status: SUPPORTED + attributes: + show: + type: string + description: Detailed information about resource + status: SUPPORTED +node_types: + org.openecomp.resource.vfc.nodes.heat.cinder.Volume: + derived_from: tosca.nodes.BlockStorage + properties: + availability_zone: + type: string + description: The availability zone in which the volume will be created + required: false + status: SUPPORTED + image: + type: string + description: If specified, the name or ID of the image to create the volume from + required: false + status: SUPPORTED + metadata: + type: map + description: Key/value pairs to associate with the volume + required: false + status: SUPPORTED + entry_schema: + type: string + volume_type: + type: string + description: If specified, the type of volume to use, mapping to a specific backend + required: false + status: SUPPORTED + description: + type: string + description: A description of the volume + required: false + status: SUPPORTED + device_type: + type: string + description: Device type + required: false + status: SUPPORTED + constraints: + - valid_values: + - cdrom + - disk + disk_bus: + type: string + description: 'Bus of the device: hypervisor driver chooses a suitable default + if omitted' + required: false + status: SUPPORTED + constraints: + - valid_values: + - ide + - lame_bus + - scsi + - usb + - virtio + backup_id: + type: string + description: If specified, the backup to create the volume from + required: false + status: SUPPORTED + source_volid: + type: string + description: If specified, the volume to use as source + required: false + status: SUPPORTED + boot_index: + type: integer + description: Integer used for ordering the boot disks + required: false + status: SUPPORTED + size: + type: scalar-unit.size + description: The requested storage size (default unit is MB) + required: false + status: SUPPORTED + constraints: + - greater_or_equal: 1 GB + read_only: + type: boolean + description: Enables or disables read-only access mode of volume + required: false + status: SUPPORTED + name: + type: string + description: A name used to distinguish the volume + required: false + status: SUPPORTED + scheduler_hints: + type: map + description: Arbitrary key-value pairs specified by the client to help the Cinder scheduler creating a volume + required: false + status: SUPPORTED + entry_schema: + type: string + swap_size: + type: scalar-unit.size + description: The size of the swap, in MB + required: false + status: SUPPORTED + delete_on_termination: + type: boolean + description: Indicate whether the volume should be deleted when the server is terminated + required: false + status: SUPPORTED + multiattach: + type: boolean + description: Whether allow the volume to be attached more than once + required: false + status: SUPPORTED + attributes: + display_description: + type: string + description: Description of the volume + status: SUPPORTED + attachments: + type: string + description: The list of attachments of the volume + status: SUPPORTED + entry_schema: + type: string + encrypted: + type: boolean + description: Boolean indicating if the volume is encrypted or not + status: SUPPORTED + show: + type: string + description: Detailed information about resource + status: SUPPORTED + created_at: + type: timestamp + description: The timestamp indicating volume creation + status: SUPPORTED + display_name: + type: string + description: Name of the volume + status: SUPPORTED + metadata_values: + type: map + description: Key/value pairs associated with the volume in raw dict form + status: SUPPORTED + entry_schema: + type: string + bootable: + type: boolean + description: Boolean indicating if the volume can be booted or not + status: SUPPORTED + status: + type: string + description: The current status of the volume + status: SUPPORTED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/CommonGlobalTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/CommonGlobalTypesServiceTemplate.yaml new file mode 100644 index 0000000000..4feb78f371 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/CommonGlobalTypesServiceTemplate.yaml @@ -0,0 +1,354 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: CommonGlobalTypes + template_version: 1.0.0 +description: TOSCA Global Types +imports: + NativeTypesServiceTemplate: + file: NativeTypesServiceTemplateServiceTemplate.yaml +data_types: + org.openecomp.datatypes.heat.network.AddressPair: + derived_from: tosca.datatypes.Root + description: MAC/IP address pairs + properties: + mac_address: + type: string + description: MAC address + required: false + status: SUPPORTED + ip_address: + type: string + description: IP address + required: false + status: SUPPORTED + org.openecomp.datatypes.heat.network.AllocationPool: + derived_from: tosca.datatypes.Root + description: The start and end addresses for the allocation pool + properties: + start: + type: string + description: Start address for the allocation pool + required: false + status: SUPPORTED + end: + type: string + description: End address for the allocation pool + required: false + status: SUPPORTED + org.openecomp.datatypes.heat.network.contrail.AddressPair: + derived_from: tosca.datatypes.Root + description: Address Pair + properties: + address_mode: + type: string + description: Address mode active-active or active-standy + required: false + status: SUPPORTED + constraints: + - valid_values: + - active-active + - active-standby + prefix: + type: string + description: IP address prefix + required: false + status: SUPPORTED + mac_address: + type: string + description: Mac address + required: false + status: SUPPORTED + org.openecomp.datatypes.heat.network.subnet.HostRoute: + derived_from: tosca.datatypes.Root + description: Host route info for the subnet + properties: + destination: + type: string + description: The destination for static route + required: false + status: SUPPORTED + nexthop: + type: string + description: The next hop for the destination + required: false + status: SUPPORTED + org.openecomp.datatypes.heat.network.contrail.port.StaticRoute: + derived_from: tosca.datatypes.Root + description: static route + properties: + prefix: + type: string + description: Route prefix + required: false + status: SUPPORTED + next_hop: + type: string + description: Next hop + required: false + status: SUPPORTED + next_hop_type: + type: string + description: Next hop type + required: false + status: SUPPORTED + org.openecomp.datatypes.heat.network.neutron.Subnet: + derived_from: tosca.datatypes.Root + description: A subnet represents an IP address block that can be used for assigning IP addresses to virtual instances + properties: + tenant_id: + type: string + description: The ID of the tenant who owns the network + required: false + status: SUPPORTED + enable_dhcp: + type: boolean + description: Set to true if DHCP is enabled and false if DHCP is disabled + required: false + default: true + status: SUPPORTED + ipv6_address_mode: + type: string + description: IPv6 address mode + required: false + status: SUPPORTED + constraints: + - valid_values: + - dhcpv6-stateful + - dhcpv6-stateless + - slaac + ipv6_ra_mode: + type: string + description: IPv6 RA (Router Advertisement) mode + required: false + status: SUPPORTED + constraints: + - valid_values: + - dhcpv6-stateful + - dhcpv6-stateless + - slaac + value_specs: + type: map + description: Extra parameters to include in the request + required: false + default: { + } + status: SUPPORTED + entry_schema: + type: string + allocation_pools: + type: list + description: The start and end addresses for the allocation pools + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.AllocationPool + subnetpool: + type: string + description: The name or ID of the subnet pool + required: false + status: SUPPORTED + dns_nameservers: + type: list + description: A specified set of DNS name servers to be used + required: false + default: [ + ] + status: SUPPORTED + entry_schema: + type: string + host_routes: + type: list + description: The gateway IP address + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.subnet.HostRoute + ip_version: + type: integer + description: The gateway IP address + required: false + default: 4 + status: SUPPORTED + constraints: + - valid_values: + - '4' + - '6' + name: + type: string + description: The name of the subnet + required: false + status: SUPPORTED + prefixlen: + type: integer + description: Prefix length for subnet allocation from subnet pool + required: false + status: SUPPORTED + constraints: + - greater_or_equal: 0 + cidr: + type: string + description: The CIDR + required: false + status: SUPPORTED + gateway_ip: + type: string + description: The gateway IP address + required: false + status: SUPPORTED +capability_types: + org.openecomp.capabilities.metric.SnmpTrap: + derived_from: org.openecomp.capabilities.Metric + description: A node type that includes the Metric capability indicates that it can be monitored using snmp trap. + properties: + oid: + type: string + description: Object Id of the metric + required: true + status: SUPPORTED + org.openecomp.capabilities.metric.SnmpPolling: + derived_from: org.openecomp.capabilities.Metric + description: A node type that includes the Metric capability indicates that it can be monitored using snmp polling. + properties: + oid: + type: string + description: Object Id of the metric + required: true + status: SUPPORTED + org.openecomp.capabilities.metric.Ceilometer: + derived_from: org.openecomp.capabilities.Metric + description: A node type that includes the Metric capability indicates that it can be monitored using ceilometer. + properties: + name: + type: string + description: Ceilometer metric type name to monitor. (The name ceilometer is using) + required: true + status: SUPPORTED + org.openecomp.capabilities.Metric: + derived_from: tosca.capabilities.nfv.Metric + description: A node type that includes the Metric capability indicates that it can be monitored. + properties: + unit: + type: string + description: Unit of the metric value + required: true + status: SUPPORTED + description: + type: string + description: Description of the metric + required: false + status: SUPPORTED + type: + type: string + description: Type of the metric value, for an example, Cumulative, Delta, Gauge and etc. + required: true + status: SUPPORTED + category: + type: string + description: Category of the metric, for an example, compute, disk, network, storage and etc. + required: false + status: SUPPORTED + attributes: + value: + type: string + description: Runtime monitored value + status: SUPPORTED +relationship_types: + org.openecomp.relationships.AttachesTo: + derived_from: tosca.relationships.Root + description: This type represents an attachment relationship +group_types: + org.openecomp.groups.heat.HeatStack: + derived_from: tosca.groups.Root + description: Grouped all heat resources which are in the same heat stack + properties: + heat_file: + type: string + description: Heat file which associate to this group/heat stack + required: true + status: SUPPORTED + description: + type: string + description: Heat file description + required: false + status: SUPPORTED +policy_types: + org.openecomp.policies.placement.valet.Exclusivity: + derived_from: tosca.policy.placement + description: Valet Exclusivity + properties: + level: + type: string + description: exclusivity + required: false + default: host + status: SUPPORTED + constraints: + - valid_values: + - host + - rack + org.openecomp.policies.placement.valet.Diversity: + derived_from: tosca.policy.placement + description: Valet Diversity + properties: + level: + type: string + description: diversity + required: false + default: host + status: SUPPORTED + constraints: + - valid_values: + - host + - rack + org.openecomp.policies.placement.Colocate: + derived_from: tosca.policy.placement + description: Keep associated nodes (groups of nodes) based upon affinity value + properties: + name: + type: string + description: The name of the policy + required: false + status: SUPPORTED + affinity: + type: string + description: affinity + required: true + status: SUPPORTED + constraints: + - valid_values: + - host + - region + - compute + org.openecomp.policies.placement.valet.Affinity: + derived_from: tosca.policy.placement + description: Valet Affinity + properties: + level: + type: string + description: affinity + required: false + default: host + status: SUPPORTED + constraints: + - valid_values: + - host + - rack + org.openecomp.policies.placement.Antilocate: + derived_from: tosca.policy.placement + description: My placement policy for separation based upon container type value + properties: + name: + type: string + description: The name of the policy + required: false + status: SUPPORTED + container_type: + type: string + description: container type + required: false + status: SUPPORTED + constraints: + - valid_values: + - host + - region + - compute \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml new file mode 100644 index 0000000000..ae5430cf8d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml @@ -0,0 +1,166 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: ContrailAbstractSubstituteGlobalTypes + template_version: 1.0.0 +description: Contrail Abstract Substitute Global Types +imports: + common_definitions: + file: CommonGlobalTypesServiceTemplate.yaml +data_types: + org.openecomp.datatypes.heat.network.contrail.InterfaceData: + derived_from: tosca.datatypes.Root + description: Interface Data + properties: + static_routes: + type: list + description: An ordered list of static routes to be added to this interface + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.contrail.port.StaticRoute + virtual_network: + type: string + description: Virtual Network for this interface + required: true + status: SUPPORTED + allowed_address_pairs: + type: list + description: List of allowed address pair for this interface + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.contrail.AddressPair + ip_address: + type: string + description: IP for this interface + required: false + status: SUPPORTED +node_types: + org.openecomp.resource.abstract.nodes.contrail.AbstractSubstitute: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + availability_zone: + type: string + description: Availability zone to create servers in + required: false + status: SUPPORTED + static_routes_list: + type: list + description: Static routes enabled + required: false + status: SUPPORTED + entry_schema: + type: boolean + availability_zone_enable: + type: boolean + description: Indicates availability zone is enabled + required: false + default: false + status: SUPPORTED + service_template_name: + type: string + description: Service template name + required: false + status: SUPPORTED + ordered_interfaces: + type: boolean + description: Indicates if service interface are ordered + required: false + default: false + status: SUPPORTED + flavor: + type: string + description: flavor + required: false + status: SUPPORTED + image_name: + type: string + description: Image name + required: true + status: SUPPORTED + service_type: + type: string + description: Service type + required: true + status: SUPPORTED + constraints: + - valid_values: + - firewall + - analyzer + - source-nat + - loadbalancer + service_interface_type_list: + type: list + description: List of interface types + required: true + status: SUPPORTED + entry_schema: + type: string + constraints: + - valid_values: + - management + - left + - right + - other + service_instance_name: + type: string + description: Service instance name + required: true + status: SUPPORTED + interface_list: + type: list + description: List of interfaces + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.contrail.InterfaceData + service_mode: + type: string + description: Service mode + required: true + status: SUPPORTED + constraints: + - valid_values: + - transparent + - in-network + - in-network-nat + shared_ip_list: + type: list + description: Shared ips enabled + required: false + status: SUPPORTED + entry_schema: + type: boolean + attributes: + tenant_id: + type: string + description: Tenant id of the Service Instance + status: SUPPORTED + fq_name: + type: string + description: The FQ name of the service instance + status: SUPPORTED + service_template_name: + type: string + description: Service Template of the Service Instance + status: SUPPORTED + show: + type: string + description: All attributes + status: SUPPORTED + active_vms: + type: string + description: Number of service VMs active for this Service Instance + status: SUPPORTED + service_instance_name: + type: string + description: The name of the service instance + status: SUPPORTED + virtual_machines: + type: string + description: Service VMs for the Service Instance + status: SUPPORTED + status: + type: string + description: Status of the service instance + status: SUPPORTED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/ContrailComputeGlobalTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/ContrailComputeGlobalTypesServiceTemplate.yaml new file mode 100644 index 0000000000..d6ad4f953c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/ContrailComputeGlobalTypesServiceTemplate.yaml @@ -0,0 +1,89 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: ContrailComputeGlobalTypes + template_version: 1.0.0 +description: Contrail Compute TOSCA Global Types +imports: + common_definitions: + file: CommonGlobalTypesServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.contrail.Compute: + derived_from: tosca.nodes.Compute + properties: + flavor: + type: string + description: flavor + required: false + status: SUPPORTED + image_name: + type: string + description: Image name + required: true + status: SUPPORTED + availability_zone: + type: string + description: Availability zone to create servers in + required: false + status: SUPPORTED + service_type: + type: string + description: Service type + required: true + status: SUPPORTED + constraints: + - valid_values: + - firewall + - analyzer + - source-nat + - loadbalancer + availability_zone_enable: + type: boolean + description: Indicates availability zone is enabled + required: false + default: false + status: SUPPORTED + service_template_name: + type: string + description: Service template name + required: false + status: SUPPORTED + service_instance_name: + type: string + description: Service instance name + required: true + status: SUPPORTED + service_mode: + type: string + description: Service mode + required: true + status: SUPPORTED + constraints: + - valid_values: + - transparent + - in-network + - in-network-nat + attributes: + tenant_id: + type: string + description: Tenant id of the VM + status: SUPPORTED + fq_name: + type: string + description: fq_name + status: SUPPORTED + show: + type: string + description: All attributes + status: SUPPORTED + active_vms: + type: string + description: Number of active VMs + status: SUPPORTED + virtual_machines: + type: string + description: VMs of this compute + status: SUPPORTED + status: + type: string + description: status of the compute + status: SUPPORTED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/ContrailNetworkRuleGlobalTypeServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/ContrailNetworkRuleGlobalTypeServiceTemplate.yaml new file mode 100644 index 0000000000..1cbf435c53 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/ContrailNetworkRuleGlobalTypeServiceTemplate.yaml @@ -0,0 +1,131 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: ContrailNetworkRuleGlobalType + template_version: 1.0.0 +description: Contrail Network Rule Global Types +imports: + common_definitions: + file: CommonGlobalTypesServiceTemplate.yaml +data_types: + org.openecomp.datatypes.heat.contrail.network.rule.PortPairs: + derived_from: tosca.datatypes.Root + description: source and destination port pairs + properties: + start_port: + type: string + description: Start port + required: false + status: SUPPORTED + end_port: + type: string + description: End port + required: false + status: SUPPORTED + org.openecomp.datatypes.heat.contrail.network.rule.VirtualNetwork: + derived_from: tosca.datatypes.Root + description: source and destination addresses + properties: + virtual_network: + type: string + description: Virtual network + required: false + status: SUPPORTED + org.openecomp.datatypes.heat.contrail.network.rule.RuleList: + derived_from: tosca.datatypes.Root + description: list of policy rules + properties: + policy_rule: + type: list + description: Contrail network rule + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.contrail.network.rule.Rule + org.openecomp.datatypes.heat.contrail.network.rule.Rule: + derived_from: tosca.datatypes.Root + description: policy rule + properties: + src_ports: + type: list + description: Source ports + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.contrail.network.rule.PortPairs + protocol: + type: string + description: Protocol + required: false + status: SUPPORTED + dst_addresses: + type: list + description: Destination addresses + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.contrail.network.rule.VirtualNetwork + apply_service: + type: string + description: Service to apply + required: false + status: SUPPORTED + dst_ports: + type: list + description: Destination ports + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.contrail.network.rule.PortPairs + src_addresses: + type: list + description: Source addresses + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.contrail.network.rule.VirtualNetwork + direction: + type: string + description: Direction + required: false + status: SUPPORTED +node_types: + org.openecomp.resource.vfc.rules.nodes.heat.network.contrail.NetworkRules: + derived_from: tosca.nodes.Root + properties: + entries: + type: org.openecomp.datatypes.heat.contrail.network.rule.RuleList + description: A symbolic name for this contrail network rule + required: false + status: SUPPORTED + name: + type: string + description: A symbolic name for this contrail network rule + required: false + status: SUPPORTED + attributes: + tenant_id: + type: string + description: tenant_id + status: SUPPORTED + fq_name: + type: string + description: fq_name + status: SUPPORTED + show: + type: string + description: All attributes. + status: SUPPORTED + rules: + type: list + description: List of rules + status: SUPPORTED + entry_schema: + type: string + requirements: + - network: + capability: tosca.capabilities.Attachment + node: tosca.nodes.network.Network + relationship: org.openecomp.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/ContrailPortGlobalTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/ContrailPortGlobalTypesServiceTemplate.yaml new file mode 100644 index 0000000000..429ed9f6a1 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/ContrailPortGlobalTypesServiceTemplate.yaml @@ -0,0 +1,64 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: ContrailPortGlobalTypes + template_version: 1.0.0 +description: Contrail Port TOSCA Global Types +imports: + common_definitions: + file: CommonGlobalTypesServiceTemplate.yaml +node_types: + org.openecomp.resource.cp.nodes.heat.network.contrail.Port: + derived_from: tosca.nodes.network.Port + properties: + static_routes: + type: list + description: An ordered list of static routes to be added to this interface + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.contrail.port.StaticRoute + virtual_network: + type: string + description: Virtual Network for this interface + required: true + status: SUPPORTED + static_route: + type: boolean + description: Static route enabled + required: false + default: false + status: SUPPORTED + allowed_address_pairs: + type: list + description: List of allowed address pair for this interface + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.contrail.AddressPair + shared_ip: + type: boolean + description: Shared ip enabled + required: false + default: false + status: SUPPORTED + ip_address: + type: string + description: IP for this interface + required: false + status: SUPPORTED + interface_type: + type: string + description: Interface type + required: true + status: SUPPORTED + constraints: + - valid_values: + - management + - left + - right + - other + attributes: + fq_name: + type: string + description: fq_name + status: SUPPORTED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/ContrailV2NetworkRuleGlobalTypeServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/ContrailV2NetworkRuleGlobalTypeServiceTemplate.yaml new file mode 100644 index 0000000000..0526291005 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/ContrailV2NetworkRuleGlobalTypeServiceTemplate.yaml @@ -0,0 +1,156 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: ContrailV2NetworkRuleGlobalType + template_version: 1.0.0 +description: Contrail V2 Network Rule Global Types +imports: + common_definitions: + file: CommonGlobalTypesServiceTemplate.yaml +data_types: + org.openecomp.datatypes.heat.contrailV2.network.rule.DstPortPairs: + derived_from: tosca.datatypes.Root + description: destination port pairs + properties: + network_policy_entries_policy_rule_dst_ports_start_port: + type: string + description: Start port + required: false + status: SUPPORTED + network_policy_entries_policy_rule_dst_ports_end_port: + type: string + description: End port + required: false + status: SUPPORTED + org.openecomp.datatypes.heat.contrailV2.network.rule.RuleList: + derived_from: tosca.datatypes.Root + description: list of policy rules + properties: + network_policy_entries_policy_rule: + type: list + description: Contrail network rule + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.contrailV2.network.rule.Rule + org.openecomp.datatypes.heat.contrailV2.network.rule.SrcPortPairs: + derived_from: tosca.datatypes.Root + description: source port pairs + properties: + network_policy_entries_policy_rule_src_ports_start_port: + type: string + description: Start port + required: false + status: SUPPORTED + network_policy_entries_policy_rule_src_ports_end_port: + type: string + description: End port + required: false + status: SUPPORTED + org.openecomp.datatypes.heat.contrailV2.network.rule.SrcVirtualNetwork: + derived_from: tosca.datatypes.Root + description: source addresses + properties: + network_policy_entries_policy_rule_src_addresses_virtual_network: + type: string + description: Source addresses Virtual network + required: false + status: SUPPORTED + org.openecomp.datatypes.heat.contrailV2.network.rule.DstVirtualNetwork: + derived_from: tosca.datatypes.Root + description: destination addresses + properties: + network_policy_entries_policy_rule_dst_addresses_virtual_network: + type: string + description: Destination addresses Virtual network + required: false + status: SUPPORTED + org.openecomp.datatypes.heat.contrailV2.network.rule.ActionList: + derived_from: tosca.datatypes.Root + description: Action List + properties: + network_policy_entries_policy_rule_action_list_simple_action: + type: string + description: Simple Action + required: false + status: SUPPORTED + network_policy_entries_policy_rule_action_list_apply_service: + type: list + description: Apply Service + required: false + status: SUPPORTED + entry_schema: + type: string + org.openecomp.datatypes.heat.contrailV2.network.rule.Rule: + derived_from: tosca.datatypes.Root + description: policy rule + properties: + network_policy_entries_policy_rule_dst_addresses: + type: list + description: Destination addresses + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.contrailV2.network.rule.DstVirtualNetwork + network_policy_entries_policy_rule_dst_ports: + type: list + description: Destination ports + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.contrailV2.network.rule.DstPortPairs + network_policy_entries_policy_rule_protocol: + type: string + description: Protocol + required: false + status: SUPPORTED + network_policy_entries_policy_rule_src_addresses: + type: list + description: Source addresses + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.contrailV2.network.rule.SrcVirtualNetwork + network_policy_entries_policy_rule_direction: + type: string + description: Direction + required: false + status: SUPPORTED + network_policy_entries_policy_rule_src_ports: + type: list + description: Source ports + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.contrailV2.network.rule.SrcPortPairs + network_policy_entries_policy_rule_action_list: + type: org.openecomp.datatypes.heat.contrailV2.network.rule.ActionList + description: Action list + required: false + status: SUPPORTED +node_types: + org.openecomp.resource.vfc.rules.nodes.heat.network.contrailV2.NetworkRules: + derived_from: tosca.nodes.Root + properties: + name: + type: string + description: A symbolic name for this contrail v2 network rule + required: false + status: SUPPORTED + network_policy_entries: + type: org.openecomp.datatypes.heat.contrailV2.network.rule.RuleList + description: A symbolic name for this contrail v2 network rule + required: false + status: SUPPORTED + attributes: + fq_name: + type: string + description: fq_name + status: SUPPORTED + requirements: + - network: + capability: tosca.capabilities.Attachment + node: tosca.nodes.network.Network + relationship: org.openecomp.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml new file mode 100644 index 0000000000..5c4a58fb11 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml @@ -0,0 +1,69 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: ContrailV2VirtualMachineInterfaceGlobalType + template_version: 1.0.0 +description: Contrail Virtual Machine Interface TOSCA Global Types +imports: + common_definitions: + file: CommonGlobalTypesServiceTemplate.yaml +data_types: + org.openecomp.datatypes.heat.contrailV2.virtual.machine.interface.Properties: + derived_from: tosca.datatypes.Root + description: Virtual Machine Interface Properties. + properties: + virtual_machine_interface_properties_service_interface_type: + type: string + description: Service Interface Type. + required: false + status: SUPPORTED +node_types: + org.openecomp.resource.cp.nodes.heat.contrailV2.VirtualMachineInterface: + derived_from: tosca.nodes.network.Port + properties: + virtual_machine_intefrace_mac_addresses: + type: list + description: List of mac addresses. + required: false + status: SUPPORTED + entry_schema: + type: string + name: + type: string + description: Virtual Machine Interface name + required: false + status: SUPPORTED + security_group_refs: + type: list + description: List of security groups. + required: false + status: SUPPORTED + entry_schema: + type: string + virtual_network_refs: + type: list + description: List of virtual networks. + required: false + status: SUPPORTED + entry_schema: + type: string + virtual_machine_interface_properties: + type: org.openecomp.datatypes.heat.contrailV2.virtual.machine.interface.Properties + description: virtual machine interface properties. + required: false + status: SUPPORTED + port_tuple_refs: + type: list + description: List of port tuples. + required: false + status: SUPPORTED + entry_schema: + type: string + attributes: + fq_name: + type: string + description: The FQ name of the Virtual Network. + status: SUPPORTED + show: + type: string + description: All attributes. + status: SUPPORTED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/ContrailV2VirtualNetworkGlobalTypeServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/ContrailV2VirtualNetworkGlobalTypeServiceTemplate.yaml new file mode 100644 index 0000000000..b950edf79f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/ContrailV2VirtualNetworkGlobalTypeServiceTemplate.yaml @@ -0,0 +1,139 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: ContrailV2VirtualNetworkGlobalType + template_version: 1.0.0 +description: Contrail V2 Virtual Network Global Types +imports: + common_definitions: + file: CommonGlobalTypesServiceTemplate.yaml +data_types: + org.openecomp.datatypes.heat.contrailV2.virtual.network.rule.ref.data.IpamSubnet: + derived_from: tosca.datatypes.Root + description: Network Ipam Ref Data Subnet + properties: + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len: + type: string + description: Network ipam refs data ipam subnets ip prefix len + required: false + status: SUPPORTED + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix: + type: string + description: Network ipam refs data ipam subnets ip prefix + required: false + status: SUPPORTED + org.openecomp.datatypes.heat.contrailV2.virtual.network.rule.RefData: + derived_from: tosca.datatypes.Root + description: network policy refs data + properties: + network_policy_refs_data_sequence: + type: org.openecomp.datatypes.heat.contrailV2.virtual.network.rule.RefDataSequence + description: Network Policy ref data sequence + required: false + status: SUPPORTED + org.openecomp.datatypes.heat.contrailV2.virtual.network.rule.IpamRefData: + derived_from: tosca.datatypes.Root + description: Network Ipam Ref Data + properties: + network_ipam_refs_data_ipam_subnets: + type: list + description: Network ipam refs data ipam subnets + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.contrailV2.virtual.network.rule.ref.data.IpamSubnetList + org.openecomp.datatypes.heat.contrailV2.virtual.network.rule.ref.data.IpamSubnetList: + derived_from: tosca.datatypes.Root + description: Network Ipam Ref Data Subnet List + properties: + network_ipam_refs_data_ipam_subnets_subnet: + type: org.openecomp.datatypes.heat.contrailV2.virtual.network.rule.ref.data.IpamSubnet + description: Network ipam refs data ipam subnets + required: false + status: SUPPORTED + network_ipam_refs_data_ipam_subnets_addr_from_start: + type: string + description: Network ipam refs data ipam subnets addr from start + required: false + status: SUPPORTED + org.openecomp.datatypes.heat.contrailV2.virtual.network.rule.RefDataSequence: + derived_from: tosca.datatypes.Root + description: network policy refs data sequence + properties: + network_policy_refs_data_sequence_major: + type: integer + description: Network Policy ref data sequence Major + required: false + status: SUPPORTED + network_policy_refs_data_sequence_minor: + type: integer + description: Network Policy ref data sequence Minor + required: false + status: SUPPORTED +node_types: + org.openecomp.resource.vl.nodes.heat.network.contrailV2.VirtualNetwork: + derived_from: tosca.nodes.network.Network + properties: + network_ipam_refs_data: + type: list + description: IPAM references Data + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.contrailV2.virtual.network.rule.IpamRefData + network_policy_refs_data: + type: list + description: Policy references data + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.contrailV2.virtual.network.rule.RefData + network_ipam_refs: + type: list + description: IPAM references + required: false + status: SUPPORTED + entry_schema: + type: string + network_policy_refs: + type: list + description: Policy references + required: false + status: SUPPORTED + entry_schema: + type: string + subnets: + type: map + description: Network related subnets + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.neutron.Subnet + attributes: + fq_name: + type: string + description: fq_name + status: SUPPORTED + subnets_name: + type: list + description: Subnets name of this network + status: SUPPORTED + entry_schema: + type: string + subnets_show: + type: map + description: Detailed information about each subnet + status: SUPPORTED + entry_schema: + type: string + subnets: + type: map + description: Network related subnets + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.neutron.Subnet + capabilities: + attachment: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml new file mode 100644 index 0000000000..05ab81741d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml @@ -0,0 +1,84 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: ContrailVirtualNetworkGlobalType + template_version: 1.0.0 +description: Contrail Virtual Network Global Types +imports: + common_definitions: + file: CommonGlobalTypesServiceTemplate.yaml +node_types: + org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork: + derived_from: tosca.nodes.network.Network + properties: + shared: + type: string + description: Is virtual network shared + required: false + status: SUPPORTED + forwarding_mode: + type: string + description: forwarding mode of the virtual network + required: false + status: SUPPORTED + external: + type: string + description: Is virtual network external + required: false + status: SUPPORTED + allow_transit: + type: string + description: Whether this network should be transitive. + required: false + status: SUPPORTED + flood_unknown_unicast: + type: string + description: flood L2 packets on network + required: false + status: SUPPORTED + route_targets: + type: list + description: route targets associated with the virtual network + required: false + status: SUPPORTED + entry_schema: + type: string + subnets: + type: map + description: Network related subnets + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.neutron.Subnet + attributes: + fq_name: + type: string + description: fq_name + status: SUPPORTED + show: + type: string + description: All attributes. + status: SUPPORTED + subnets_name: + type: list + description: Subnets name of this network + status: SUPPORTED + entry_schema: + type: string + subnets_show: + type: map + description: Detailed information about each subnet + status: SUPPORTED + entry_schema: + type: string + subnets: + type: map + description: Network related subnets + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.neutron.Subnet + capabilities: + attachment: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..251525391b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,196 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + cmaui_cinder_volume_size: + label: CMAUI Cinder volume size + hidden: false + immutable: false + type: float + description: the size of the CMAUI Cinder volume + timezone: + label: timezone + hidden: false + immutable: false + type: string + description: timezone + security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + oam_network_netmask: + label: oam network netmask + hidden: false + immutable: false + type: string + description: oam network gateway + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + vnf_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-CMAUI_id + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + oam_network_gateway: + label: oam network gateway + hidden: false + immutable: false + type: string + description: oam network gateway + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + cmaui_oam_ips: + label: CMAUI oam_net IP addresses + hidden: false + immutable: false + type: list + description: CMAUI oam_net IP addresses + entry_schema: + type: string + external_dns: + label: dns server + hidden: false + immutable: false + type: string + description: dns server + oam_net_name: + hidden: false + immutable: false + type: string + description: UID of OAM network + external_ntp: + label: ntp server + hidden: false + immutable: false + type: string + description: ntp server + CMAUI_volume_type: + label: CMAUI vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + node_templates: + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + metadata: + vnf_id: + get_input: vnf_id + user_data_format: RAW + name: + get_input: + - cmaui_names + - 0 + requirements: + - dependency: + capability: tosca.capabilities.Node + node: cmaui_volume + relationship: tosca.relationships.DependsOn + - dependency: + capability: tosca.capabilities.Node + node: cmaui_port_0 + relationship: tosca.relationships.DependsOn + - local_storage: + capability: tosca.capabilities.Attachment + node: cmaui_volume + relationship: cmaui_volume_attachment + cmaui_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: CMAUI_volume_type + size: '(get_input : cmaui_cinder_volume_size) * 1024' + cmaui_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + relationship_templates: + cmaui_volume_attachment: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: cmaui_volume + instance_uuid: server_cmaui + groups: + hot_template: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/hot_template.yml + description: cmaui server template for vMMSC + members: + - server_cmaui + - cmaui_volume + - cmaui_port_0 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/NativeTypesServiceTemplateServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/NativeTypesServiceTemplateServiceTemplate.yaml new file mode 100644 index 0000000000..27c64039f1 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/NativeTypesServiceTemplateServiceTemplate.yaml @@ -0,0 +1,205 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: NativeTypesServiceTemplate + template_version: 1.0.0 +description: TOSCA Native Node Types +node_types: + tosca.nodes.Compute: + derived_from: tosca.nodes.Root + attributes: + private_address: + type: string + description: private address + status: SUPPORTED + public_address: + type: string + description: public_address + status: SUPPORTED + networks: + type: map + description: networks + status: SUPPORTED + entry_schema: + type: tosca.datatypes.network.NetworkInfo + ports: + type: map + description: ports + status: SUPPORTED + entry_schema: + type: tosca.datatypes.network.PortInfo + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + capabilities: + scalable: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + endpoint: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + os: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + host: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + binding: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + tosca.nodes.network.Port: + derived_from: tosca.nodes.Root + properties: + ip_range_end: + type: string + required: false + status: SUPPORTED + ip_range_start: + type: string + required: false + status: SUPPORTED + ip_address: + type: string + required: false + status: SUPPORTED + is_default: + type: boolean + required: false + default: false + status: SUPPORTED + order: + type: integer + required: true + default: 0 + status: SUPPORTED + constraints: + - greater_or_equal: 0 + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - binding: + capability: tosca.capabilities.network.Bindable + node: tosca.nodes.Root + relationship: tosca.relationships.network.BindsTo + occurrences: + - 1 + - 1 + tosca.nodes.Root: + attributes: + tosca_name: + type: string + description: tosca name + status: SUPPORTED + state: + type: string + description: state + status: SUPPORTED + tosca_id: + type: string + description: tosca id + status: SUPPORTED + interfaces: { + } + tosca.nodes.network.Network: + derived_from: tosca.nodes.Root + properties: + physical_network: + type: string + required: false + status: SUPPORTED + dhcp_enabled: + type: boolean + required: false + default: true + status: SUPPORTED + segmentation_id: + type: string + required: false + status: SUPPORTED + network_id: + type: string + required: false + status: SUPPORTED + ip_version: + type: integer + required: false + default: 4 + status: SUPPORTED + constraints: + - valid_values: + - 4 + - 6 + start_ip: + type: string + required: false + status: SUPPORTED + network_name: + type: string + required: false + status: SUPPORTED + cidr: + type: string + required: false + status: SUPPORTED + gateway_ip: + type: string + required: false + status: SUPPORTED + network_type: + type: string + required: false + status: SUPPORTED + end_ip: + type: string + required: false + status: SUPPORTED + capabilities: + link: + type: tosca.capabilities.network.Linkable + occurrences: + - 1 + - UNBOUNDED + tosca.nodes.BlockStorage: + derived_from: tosca.nodes.Root + properties: + size: + type: scalar-unit.size + required: false + status: SUPPORTED + constraints: + - greater_or_equal: 1 MB + volume_id: + type: string + required: false + status: SUPPORTED + snapshot_id: + type: string + required: false + status: SUPPORTED + capabilities: + attachment: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/NeutronNetGlobalTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/NeutronNetGlobalTypesServiceTemplate.yaml new file mode 100644 index 0000000000..e80e2727c7 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/NeutronNetGlobalTypesServiceTemplate.yaml @@ -0,0 +1,97 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: NeutronNetGlobalTypes + template_version: 1.0.0 +description: Neutron Network TOSCA Global Types +imports: + common_definitions: + file: CommonGlobalTypesServiceTemplate.yaml +node_types: + org.openecomp.resource.vl.nodes.heat.network.neutron.Net: + derived_from: tosca.nodes.network.Network + properties: + dhcp_agent_ids: + type: list + description: The IDs of the DHCP agent to schedule the network + required: false + status: SUPPORTED + entry_schema: + type: string + tenant_id: + type: string + description: The ID of the tenant which will own the network + required: false + status: SUPPORTED + port_security_enabled: + type: boolean + description: Flag to enable/disable port security on the network + required: false + status: SUPPORTED + shared: + type: boolean + description: Whether this network should be shared across all tenants + required: false + default: false + status: SUPPORTED + admin_state_up: + type: boolean + description: A boolean value specifying the administrative status of the network + required: false + default: true + status: SUPPORTED + qos_policy: + type: string + description: The name or ID of QoS policy to attach to this network + required: false + status: SUPPORTED + subnets: + type: map + description: Network related subnets + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.neutron.Subnet + value_specs: + type: map + description: Extra parameters to include in the request + required: false + default: { + } + status: SUPPORTED + entry_schema: + type: string + attributes: + qos_policy_id: + type: string + description: The QoS policy ID attached to this network + status: SUPPORTED + show: + type: string + description: Detailed information about resource + status: SUPPORTED + subnets_name: + type: list + description: Subnets name of this network + status: SUPPORTED + entry_schema: + type: string + subnets: + type: map + description: Network related subnets + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.neutron.Subnet + mtu: + type: scalar-unit.size + description: The maximum transmission unit size(in bytes) for the network + status: SUPPORTED + status: + type: string + description: The status of the network + status: SUPPORTED + capabilities: + attachment: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/NeutronPortGlobalTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/NeutronPortGlobalTypesServiceTemplate.yaml new file mode 100644 index 0000000000..a337d6ed18 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/NeutronPortGlobalTypesServiceTemplate.yaml @@ -0,0 +1,151 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: NeutronPortGlobalTypes + template_version: 1.0.0 +description: Neutron Port TOSCA Global Types +imports: + common_definitions: + file: CommonGlobalTypesServiceTemplate.yaml +data_types: + org.openecomp.datatypes.heat.neutron.port.FixedIps: + derived_from: tosca.datatypes.Root + description: subnet/ip_address + properties: + subnet: + type: string + description: Subnet in which to allocate the IP address for this port + required: false + status: SUPPORTED + ip_address: + type: string + description: IP address desired in the subnet for this port + required: false + status: SUPPORTED +node_types: + org.openecomp.resource.cp.nodes.heat.network.neutron.Port: + derived_from: tosca.nodes.network.Port + properties: + port_security_enabled: + type: boolean + description: Flag to enable/disable port security on the network + required: false + status: SUPPORTED + device_id: + type: string + description: Device ID of this port + required: false + status: SUPPORTED + qos_policy: + type: string + description: The name or ID of QoS policy to attach to this network + required: false + status: SUPPORTED + allowed_address_pairs: + type: list + description: Additional MAC/IP address pairs allowed to pass through the port + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.AddressPair + binding:vnic_type: + type: string + description: The vnic type to be bound on the neutron port + required: false + status: SUPPORTED + constraints: + - valid_values: + - macvtap + - direct + - normal + value_specs: + type: map + description: Extra parameters to include in the request + required: false + default: { + } + status: SUPPORTED + entry_schema: + type: string + device_owner: + type: string + description: Name of the network owning the port + required: false + status: SUPPORTED + network: + type: string + description: Network this port belongs to + required: false + status: SUPPORTED + replacement_policy: + type: string + description: Policy on how to respond to a stack-update for this resource + required: false + default: AUTO + status: SUPPORTED + constraints: + - valid_values: + - REPLACE_ALWAYS + - AUTO + security_groups: + type: list + description: List of security group names or IDs + required: false + status: SUPPORTED + entry_schema: + type: string + fixed_ips: + type: list + description: Desired IPs for this port + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.neutron.port.FixedIps + mac_address: + type: string + description: MAC address to give to this port + required: false + status: SUPPORTED + admin_state_up: + type: boolean + description: A boolean value specifying the administrative status of the network + required: false + default: true + status: SUPPORTED + name: + type: string + description: A symbolic name for this port + required: false + status: SUPPORTED + attributes: + tenant_id: + type: string + description: Tenant owning the port + status: SUPPORTED + network_id: + type: string + description: Unique identifier for the network owning the port + status: SUPPORTED + qos_policy_id: + type: string + description: The QoS policy ID attached to this network + status: SUPPORTED + show: + type: string + description: Detailed information about resource + status: SUPPORTED + subnets: + type: list + description: Subnets of this network + status: SUPPORTED + entry_schema: + type: string + status: + type: string + description: The status of the network + status: SUPPORTED + capabilities: + attachment: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/NeutronSecurityRulesGlobalTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/NeutronSecurityRulesGlobalTypesServiceTemplate.yaml new file mode 100644 index 0000000000..1cbef86d8d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/NeutronSecurityRulesGlobalTypesServiceTemplate.yaml @@ -0,0 +1,116 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: NeutronSecurityRulesGlobalTypes + template_version: 1.0.0 +description: Neutron Security Rules TOSCA Global Types +imports: + common_definitions: + file: CommonGlobalTypesServiceTemplate.yaml +data_types: + org.openecomp.datatypes.heat.network.neutron.SecurityRules.Rule: + derived_from: tosca.datatypes.Root + description: Rules Pairs + properties: + remote_group_id: + type: string + description: The remote group ID to be associated with this security group rule + required: false + status: SUPPORTED + protocol: + type: string + description: The protocol that is matched by the security group rule + required: false + status: SUPPORTED + constraints: + - valid_values: + - tcp + - udp + - icmp + ethertype: + type: string + description: Ethertype of the traffic + required: false + default: IPv4 + status: SUPPORTED + constraints: + - valid_values: + - IPv4 + - IPv6 + port_range_max: + type: integer + description: 'The maximum port number in the range that is matched by the + security group rule. ' + required: false + status: SUPPORTED + constraints: + - in_range: + - 0 + - 65535 + remote_ip_prefix: + type: string + description: The remote IP prefix (CIDR) to be associated with this security group rule + required: false + status: SUPPORTED + remote_mode: + type: string + description: Whether to specify a remote group or a remote IP prefix + required: false + default: remote_ip_prefix + status: SUPPORTED + constraints: + - valid_values: + - remote_ip_prefix + - remote_group_id + direction: + type: string + description: The direction in which the security group rule is applied + required: false + default: ingress + status: SUPPORTED + constraints: + - valid_values: + - egress + - ingress + port_range_min: + type: integer + description: The minimum port number in the range that is matched by the security group rule. + required: false + status: SUPPORTED + constraints: + - in_range: + - 0 + - 65535 +node_types: + org.openecomp.resource.vfc.rules.nodes.heat.network.neutron.SecurityRules: + derived_from: tosca.nodes.Root + properties: + name: + type: string + description: A symbolic name for this security group, which is not required to be unique. + required: false + status: SUPPORTED + description: + type: string + description: Description of the security group + required: false + status: SUPPORTED + rules: + type: list + description: List of security group rules + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.neutron.SecurityRules.Rule + attributes: + show: + type: string + description: Detailed information about resource + status: SUPPORTED + requirements: + - port: + capability: tosca.capabilities.Attachment + node: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + relationship: org.openecomp.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/NovaServerGlobalTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/NovaServerGlobalTypesServiceTemplate.yaml new file mode 100644 index 0000000000..0ec79f5229 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/expectedoutputfiles/NovaServerGlobalTypesServiceTemplate.yaml @@ -0,0 +1,249 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: NovaServerGlobalTypes + template_version: 1.0.0 +description: Nova Server TOSCA Global Types +imports: + common_definitions: + file: CommonGlobalTypesServiceTemplate.yaml +data_types: + org.openecomp.datatypes.heat.novaServer.network.PortExtraProperties: + derived_from: tosca.datatypes.Root + description: Nova server network expand properties for port + properties: + port_security_enabled: + type: boolean + description: Flag to enable/disable port security on the port + required: false + status: SUPPORTED + mac_address: + type: string + description: MAC address to give to this port + required: false + status: SUPPORTED + admin_state_up: + type: boolean + description: The administrative state of this port + required: false + default: true + status: SUPPORTED + qos_policy: + type: string + description: The name or ID of QoS policy to attach to this port + required: false + status: SUPPORTED + allowed_address_pairs: + type: list + description: Additional MAC/IP address pairs allowed to pass through the port + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.AddressPair + binding:vnic_type: + type: string + description: The vnic type to be bound on the neutron port + required: false + status: SUPPORTED + constraints: + - valid_values: + - macvtap + - direct + - normal + value_specs: + type: map + description: Extra parameters to include in the request + required: false + default: { + } + status: SUPPORTED + entry_schema: + type: string + org.openecomp.datatypes.heat.novaServer.network.AddressInfo: + derived_from: tosca.datatypes.network.NetworkInfo + description: Network addresses with corresponding port id + properties: + port_id: + type: string + description: Port id + required: false + status: SUPPORTED +node_types: + org.openecomp.resource.vfc.nodes.heat.nova.Server: + derived_from: tosca.nodes.Compute + properties: + admin_pass: + type: string + description: The administrator password for the server + required: false + status: SUPPORTED + availability_zone: + type: string + description: Availability zone to create servers in + required: false + status: SUPPORTED + image: + type: string + description: The ID or name of the image to boot with + required: false + status: SUPPORTED + image_update_policy: + type: string + description: Policy on how to apply an image-id update + required: false + default: REBUILD + status: SUPPORTED + constraints: + - valid_values: + - REBUILD_PRESERVE_EPHEMERAL + - REPLACE + - REBUILD + metadata: + type: json + description: Arbitrary JSON metadata to store for this server + required: false + status: SUPPORTED + contrail_service_instance_ind: + type: boolean + description: Nova server related to service instance indicator + required: false + default: false + status: SUPPORTED + user_data_update_policy: + type: string + description: Policy on how to apply a user_data update + required: false + default: REPLACE + status: SUPPORTED + constraints: + - valid_values: + - REPLACE + - IGNORE + flavor_update_policy: + type: string + description: Policy on how to apply a flavor update + required: false + default: RESIZE + status: SUPPORTED + constraints: + - valid_values: + - RESIZE + - REPLACE + user_data: + type: string + description: User data script to be executed by cloud-init + required: false + default: '' + status: SUPPORTED + flavor: + type: string + description: The ID or name of the flavor to boot onto + required: true + status: SUPPORTED + key_name: + type: string + description: Name of keypair to inject into the server + required: false + status: SUPPORTED + reservation_id: + type: string + description: A UUID for the set of servers being requested + required: false + status: SUPPORTED + security_groups: + type: list + description: List of security group names or IDs + required: false + default: [ + ] + status: SUPPORTED + entry_schema: + type: string + config_drive: + type: boolean + description: enable config drive on the server + required: false + status: SUPPORTED + personality: + type: map + description: A map of files to create/overwrite on the server upon boot + required: false + default: { + } + status: SUPPORTED + entry_schema: + type: string + software_config_transport: + type: string + description: How the server should receive the metadata required for software configuration + required: false + default: POLL_SERVER_CFN + status: SUPPORTED + constraints: + - valid_values: + - POLL_SERVER_CFN + - POLL_SERVER_HEAT + - POLL_TEMP_URL + - ZAQAR_MESSAGE + user_data_format: + type: string + description: How the user_data should be formatted for the server + required: false + default: HEAT_CFNTOOLS + status: SUPPORTED + constraints: + - valid_values: + - SOFTWARE_CONFIG + - RAW + - HEAT_CFNTOOLS + diskConfig: + type: string + description: Control how the disk is partitioned when the server is created + required: false + status: SUPPORTED + constraints: + - valid_values: + - AUTO + - MANUAL + name: + type: string + description: Server name + required: false + status: SUPPORTED + scheduler_hints: + type: map + description: Arbitrary key-value pairs specified by the client to help boot a server + required: false + status: SUPPORTED + entry_schema: + type: string + attributes: + accessIPv4: + type: string + description: The manually assigned alternative public IPv4 address of the server + status: SUPPORTED + addresses: + type: map + description: A dict of all network addresses with corresponding port_id + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.novaServer.network.AddressInfo + accessIPv6: + type: string + description: The manually assigned alternative public IPv6 address of the server + status: SUPPORTED + instance_name: + type: string + description: AWS compatible instance name + status: SUPPORTED + name: + type: string + description: Name of the server + status: SUPPORTED + show: + type: string + description: Detailed information about resource + status: SUPPORTED + console_urls: + type: string + description: URLs of servers consoles + status: SUPPORTED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..b2916ccf9c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/inputfiles/MANIFEST.json @@ -0,0 +1,11 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "hot_template.yml", + "type": "HEAT" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/inputfiles/hot_template.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/inputfiles/hot_template.yml new file mode 100644 index 0000000000..574c0ac118 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/global_types/inputfiles/hot_template.yml @@ -0,0 +1,122 @@ +heat_template_version: 2013-05-23 + +################################# +# +# Changes from MSO 01/26/2016 +# Updated per ECOMP feedback +# +################################# + +description: cmaui server template for vMMSC + +parameters: + vnf_id: + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-CMAUI_id + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_cinder_volume_size: + type: number + label: CMAUI Cinder volume size + description: the size of the CMAUI Cinder volume + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + oam_net_name: + type: string + description: UID of OAM network + oam_network_netmask: + type: string + label: oam network netmask + description: oam network gateway + oam_network_gateway: + type: string + label: oam network gateway + description: oam network gateway + external_dns: + type: string + label: dns server + description: dns server + external_ntp: + type: string + label: ntp server + description: ntp server + security_group_name: + type: string + label: security group name + description: the name of security group + timezone: + type: string + label: timezone + description: timezone + cmaui_oam_ips: + type: comma_delimited_list + label: CMAUI oam_net IP addresses + description: CMAUI oam_net IP addresses + CMAUI_volume_type: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + +resources: + + cmaui_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + cmaui_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: cmaui_cinder_volume_size} + volume_type: {get_param: CMAUI_volume_type} + + cmaui_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: cmaui_volume} + instance_uuid: {get_resource: server_cmaui} + + server_cmaui: + type: OS::Nova::Server + depends_on: [ cmaui_volume,cmaui_port_0] + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_0 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + cmaui.mgmt.ip=${cmaui.mgmt.ip} + cmaui.mgmt.netmask=${cmaui.mgmt.netmask} + cmaui.mgmt.gateway=${cmaui.mgmt.gateway} + cmaui.external.dns=${cmaui.external.dns} + cmaui.external.ntp=${cmaui.external.ntp} + cmaui.node=${cmaui.node} + cmaui.timezone=${cmaui.timezone} + params: + ${cmaui.mgmt.ip}: {get_param: [cmaui_oam_ips, 0]} + ${cmaui.mgmt.netmask}: {get_param: oam_network_netmask} + ${cmaui.mgmt.gateway}: {get_param: oam_network_gateway} + ${cmaui.external.dns}: {get_param: external_dns} + ${cmaui.external.ntp}: {get_param: external_ntp} + ${cmaui.node}: {get_param: [cmaui_names, 0]} + ${cmaui.timezone}: {get_param: timezone} + user_data_format: RAW \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-mog-0108-bs1271/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-mog-0108-bs1271/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..c60020d80c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-mog-0108-bs1271/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,1459 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.pd_server: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.ps_server: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.sm_server: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.cm_server: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.oam_server: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + pd_flavor_name: + label: PD flavor name + hidden: false + immutable: false + type: string + description: flavor name of PD instance + default: m3.xlarge + availabilityzone_name: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + default: nova + repl_net_ips: + label: repl network ips + hidden: false + immutable: false + type: list + description: ips of repl network + default: + - 107.239.33.57 + - 107.239.33.58 + entry_schema: + type: string + sl_net_name: + label: silver lining network name + hidden: false + immutable: false + type: string + description: id of the sl network + default: exn_protected_net_0 + pd_image_name: + label: image name + hidden: false + immutable: false + type: string + description: PD image name + default: MOG_BASE_8.0 + mog_script_name: + label: mog Config script name + hidden: false + immutable: false + type: string + description: Config script name + default: http://10.147.38.210:8080/v1/AUTH_8e501b8121f34a6eaaf526d3305985cc/mogtestcontainer/mog-cloudinit.sh + pd_server_names: + label: PD server names + hidden: false + immutable: false + type: list + description: name of the PD instance + default: + - ZRDM1MOGX01MPD001 + - ZRDM1MOGX01MPD002 + entry_schema: + type: string + sm_server_names: + label: SM server names + hidden: false + immutable: false + type: list + description: name of the SM instance + default: + - ZRDM1MOGX01MSM001 + - ZRDM1MOGX01MSM002 + entry_schema: + type: string + dummy_net_netmask_1: + hidden: false + immutable: false + type: string + description: CSB internal network subnet mask + default: 255.255.255.0 + dummy_net_netmask_0: + hidden: false + immutable: false + type: string + description: CSB internal network subnet mask + default: 255.255.255.0 + ran_net_floating_ip: + label: mog ran net virtual ip + hidden: false + immutable: false + type: string + description: mog ran net virtual ip + default: 107.239.36.5 + ran_net_ips: + label: RAN network ips + hidden: false + immutable: false + type: list + description: RAN network ip + default: + - 107.239.36.3 + - 107.239.36.4 + entry_schema: + type: string + dummy_net_end_0: + label: csb internal end + hidden: false + immutable: false + type: string + description: csb internal end + default: 169.254.1.254 + oam_image_name: + label: image name + hidden: false + immutable: false + type: string + description: OAM image name + default: MOG_BASE_8.0 + dummy_net_end_1: + label: csb internal end + hidden: false + immutable: false + type: string + description: csb internal end + default: 169.254.2.254 + oam_net_name: + label: oam network name + hidden: false + immutable: false + type: string + description: name of the oam network + default: oam_protected_net_0 + oam_net_ips: + label: internet network ips + hidden: false + immutable: false + type: list + description: ip of the OAM network + default: + - 107.250.172.213 + - 107.250.172.214 + - 107.250.172.215 + - 107.250.172.216 + - 107.250.172.217 + entry_schema: + type: string + ran_net_name: + label: RAN network name + hidden: false + immutable: false + type: string + description: RAN network name + default: gn_direct_net_0 + cluster-manager-vol-1: + label: mog-cm-vol-1 + hidden: false + immutable: false + type: string + description: Cluster Manager volume 1 + default: 43ccf5ba-2d50-427b-a38f-e8c7d8670eee + cluster-manager-vol-2: + label: mog-cm-vol-2 + hidden: false + immutable: false + type: string + description: Cluster Manager volume 2 with ISO image + default: 6f92e211-2d61-487d-8f84-d2d00cea3698 + csb_net_netmask: + hidden: false + immutable: false + type: string + description: CSB internal network subnet mask + default: 255.255.255.0 + oam_flavor_name: + label: OAM flavor name + hidden: false + immutable: false + type: string + description: flavor name of OAM instance + default: m3.xlarge + dummy_net_start_0: + label: csb internal start + hidden: false + immutable: false + type: string + description: csb internal start + default: 169.254.1.4 + dummy_net_start_1: + label: csb internal start + hidden: false + immutable: false + type: string + description: csb internal start + default: 169.254.2.4 + cm_flavor_name: + label: CM flavor name + hidden: false + immutable: false + type: string + description: flavor name of CM instance + default: m3.xlarge + sm_image_name: + label: image name + hidden: false + immutable: false + type: string + description: SM image name + default: MOG_BASE_8.0 + mog_parameter_name: + label: mog script parameter name + hidden: false + immutable: false + type: string + description: Config script parameter csv file name + default: http://10.147.38.210:8080/v1/AUTH_8e501b8121f34a6eaaf526d3305985cc/mogtestcontainer + ps_server_names: + label: PS server names + hidden: false + immutable: false + type: list + description: name of the PS instance + default: + - ZRDM1MOGX01MPS001 + - ZRDM1MOGX01MPS002 + - ZRDM1MOGX01MPS003 + - ZRDM1MOGX01MPS004 + entry_schema: + type: string + csb_net_ips: + hidden: false + immutable: false + type: list + description: mog_csb_net IP addresses + default: + - 172.26.0.10 + - 172.26.0.11 + - 172.26.0.12 + - 172.26.0.13 + - 172.26.0.14 + - 172.26.0.15 + - 172.26.0.16 + - 172.26.0.17 + - 172.26.0.18 + - 172.26.0.19 + - 172.26.0.20 + entry_schema: + type: string + ps_flavor_name: + label: PS flavor name + hidden: false + immutable: false + type: string + description: flavor name of PS instance + default: m3.xlarge + rx_net_ips: + label: Rx network ips + hidden: false + immutable: false + type: list + description: Rx network ips + default: + - 107.239.34.3 + - 107.239.34.4 + entry_schema: + type: string + dummy_net_name_1: + label: csb internal network name + hidden: false + immutable: false + type: string + description: csb internal network name + default: mog_dummy_1 + dummy_net_cidr_1: + label: csb ineternal cidr + hidden: false + immutable: false + type: string + description: csb internal cidr + default: 169.254.2.0/24 + dummy_net_name_0: + label: csb internal network name + hidden: false + immutable: false + type: string + description: csb internal network name + default: mog_dummy_0 + dummy_net_cidr_0: + label: csb ineternal cidr + hidden: false + immutable: false + type: string + description: csb internal cidr + default: 169.254.1.0/24 + mog_swift_container: + label: mog Config URL + hidden: false + immutable: false + type: string + description: Config URL + default: http://10.147.38.210:8080/v1/AUTH_8e501b8121f34a6eaaf526d3305985cc/mogtestcontainer + oam-vol-2: + label: mog-oam-vol-2 + hidden: false + immutable: false + type: string + description: OAM volume 2 + default: 6d169cb6-6ddc-41dc-920c-2839898a2924 + sl_net_floating_ip: + label: mog sl net virtual ip + hidden: false + immutable: false + type: string + description: mog sl net virtual ip + default: 107.239.45.6 + session-manager-vol-1: + label: mog-sm-vol-1 + hidden: false + immutable: false + type: string + description: Session Manager volume 1 + default: 49201898-333d-4c88-b58d-cf573b091633 + rx_net_floating_ip: + label: mog rx net virtual ip + hidden: false + immutable: false + type: string + description: mog rx net virtual ip + default: 107.239.34.5 + session-manager-vol-2: + label: mog-sm-vol-2 + hidden: false + immutable: false + type: string + description: Session Manager volume 2 + default: 4c35b5f1-ce99-4220-a6e2-cda6e2d713a0 + oam-vol-1: + label: mog-oam-vol-1 + hidden: false + immutable: false + type: string + description: OAM volume 1 + default: 0a7fcd9e-2624-401d-ac21-b0191f85ec77 + csb_net_start: + label: csb internal start + hidden: false + immutable: false + type: string + description: csb internal start + default: 172.26.0.1 + cm_image_name: + label: image name + hidden: false + immutable: false + type: string + description: CM image name + default: MOG_BASE_8.0 + sm_flavor_name: + label: SM flavor name + hidden: false + immutable: false + type: string + description: flavor name of SM instance + default: m2.xlarge4 + ps_image_name: + label: PS image name + hidden: false + immutable: false + type: string + description: PS image name + default: MOG_BASE_8.0 + oam_server_names: + label: OAM server names + hidden: false + immutable: false + type: list + description: name of the OAM instance + default: + - ZRDM1MOGX01OAM001 + - ZRDM1MOGX01OAM002 + entry_schema: + type: string + csb_net_cidr: + label: csb ineternal cidr + hidden: false + immutable: false + type: string + description: csb internal cidr + default: 172.26.0.0/24 + cm_server_names: + label: CM server names + hidden: false + immutable: false + type: list + description: name of the CM instance + default: + - ZRDM1MOGX01MCM001 + entry_schema: + type: string + sl_net_ips: + label: silver lining network ips + hidden: false + immutable: false + type: list + description: ips of the sl network + default: + - 107.239.45.4 + - 107.239.45.5 + entry_schema: + type: string + rx_net_name: + label: Rx network name + hidden: false + immutable: false + type: string + description: Rx network name + default: cor_direct_net_1 + repl_net_name: + label: Replication network name + hidden: false + immutable: false + type: string + description: name of the replication network + default: cor_direct_net_0 + security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + default: mog_security_group + csb_net_end: + label: csb internal end + hidden: false + immutable: false + type: string + description: csb internal end + default: 172.26.0.254 + csb_net_name: + label: csb internal network name + hidden: false + immutable: false + type: string + description: csb internal network name + default: int_mog_csb_net + mog_script_dir: + label: mog Config script directory + hidden: false + immutable: false + type: string + description: Config script directory + default: /root + node_templates: + cm01_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - mog_security_group + fixed_ips: + - ip_address: + get_input: + - oam_net_ips + - 4 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cm01 + relationship: tosca.relationships.network.BindsTo + cm01_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - mog_security_group + fixed_ips: + - ip_address: + get_input: + - csb_net_ips + - 10 + network: csb_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: csb_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cm01 + relationship: tosca.relationships.network.BindsTo + sm02_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - mog_security_group + network: csb_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: csb_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_sm02 + relationship: tosca.relationships.network.BindsTo + server_ps04: + type: org.openecomp.resource.vfc.nodes.heat.ps_server + properties: + flavor: + get_input: ps_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: ps_image_name + user_data_format: RAW + name: + get_input: + - ps_server_names + - 3 + scheduler_hints: + group: servergroup_mog03 + server_ps03: + type: org.openecomp.resource.vfc.nodes.heat.ps_server + properties: + flavor: + get_input: ps_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: ps_image_name + user_data_format: RAW + name: + get_input: + - ps_server_names + - 2 + scheduler_hints: + group: servergroup_mog03 + sm01_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - mog_security_group + network: csb_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: csb_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_sm01 + relationship: tosca.relationships.network.BindsTo + sm02_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - mog_security_group + fixed_ips: + - ip_address: + get_input: + - repl_net_ips + - 1 + network: + get_input: repl_net_name + server_ps02: + type: org.openecomp.resource.vfc.nodes.heat.ps_server + properties: + flavor: + get_input: ps_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: ps_image_name + user_data_format: RAW + name: + get_input: + - ps_server_names + - 1 + scheduler_hints: + group: servergroup_mog03 + sm01_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - mog_security_group + network: dummy_net_0 + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: dummy_net_0 + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_sm01 + relationship: tosca.relationships.network.BindsTo + sm02_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - mog_security_group + network: dummy_net_0 + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: dummy_net_0 + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_sm02 + relationship: tosca.relationships.network.BindsTo + server_ps01: + type: org.openecomp.resource.vfc.nodes.heat.ps_server + properties: + flavor: + get_input: ps_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: ps_image_name + user_data_format: RAW + name: + get_input: + - ps_server_names + - 0 + scheduler_hints: + group: servergroup_mog03 + csb_net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + dhcp_enabled: true + network_name: + get_input: csb_net_name + subnets: + csb_ip_subnet: + enable_dhcp: true + name: + get_input: csb_net_name + cidr: + get_input: csb_net_cidr + allocation_pools: + - start: + get_input: csb_net_start + end: + get_input: csb_net_end + sm01_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - mog_security_group + fixed_ips: + - ip_address: + get_input: + - repl_net_ips + - 0 + network: + get_input: repl_net_name + pd01_port_5: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - mog_security_group + fixed_ips: + - ip_address: + get_input: + - ran_net_ips + - 0 + allowed_address_pairs: + - ip_address: + get_input: ran_net_floating_ip + network: + get_input: ran_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_pd_01 + relationship: tosca.relationships.network.BindsTo + pd01_port_4: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - mog_security_group + network: dummy_net_1 + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: dummy_net_1 + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_pd_01 + relationship: tosca.relationships.network.BindsTo + pd02_port_5: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - mog_security_group + fixed_ips: + - ip_address: + get_input: + - ran_net_ips + - 1 + allowed_address_pairs: + - ip_address: + get_input: ran_net_floating_ip + network: + get_input: ran_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_pd_02 + relationship: tosca.relationships.network.BindsTo + pd01_port_6: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - mog_security_group + fixed_ips: + - ip_address: + get_input: + - sl_net_ips + - 0 + allowed_address_pairs: + - ip_address: + get_input: sl_net_floating_ip + network: + get_input: sl_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_pd_01 + relationship: tosca.relationships.network.BindsTo + pd02_port_6: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - mog_security_group + fixed_ips: + - ip_address: + get_input: + - sl_net_ips + - 1 + allowed_address_pairs: + - ip_address: + get_input: sl_net_floating_ip + network: + get_input: sl_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_pd_02 + relationship: tosca.relationships.network.BindsTo + server_sm02: + type: org.openecomp.resource.vfc.nodes.heat.sm_server + properties: + flavor: + get_input: sm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: sm_image_name + user_data_format: RAW + name: + get_input: + - sm_server_names + - 1 + scheduler_hints: + group: servergroup_mog02 + ps02_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - mog_security_group + network: csb_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: csb_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_ps02 + relationship: tosca.relationships.network.BindsTo + ps04_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - mog_security_group + network: csb_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: csb_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_ps04 + relationship: tosca.relationships.network.BindsTo + ps03_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - mog_security_group + network: csb_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: csb_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_ps03 + relationship: tosca.relationships.network.BindsTo + ps01_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - mog_security_group + network: csb_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: csb_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_ps01 + relationship: tosca.relationships.network.BindsTo + server_sm01: + type: org.openecomp.resource.vfc.nodes.heat.sm_server + properties: + flavor: + get_input: sm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: sm_image_name + user_data_format: RAW + name: + get_input: + - sm_server_names + - 0 + scheduler_hints: + group: servergroup_mog02 + dummy_net_0: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + dhcp_enabled: true + network_name: + get_input: dummy_net_name_0 + subnets: + dummy_ip_subnet_0: + enable_dhcp: true + name: + get_input: dummy_net_name_0 + cidr: + get_input: dummy_net_cidr_0 + allocation_pools: + - start: + get_input: dummy_net_start_0 + end: + get_input: dummy_net_end_0 + server_cm01: + type: org.openecomp.resource.vfc.nodes.heat.cm_server + properties: + flavor: + get_input: cm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: cm_image_name + user_data_format: RAW + name: + get_input: + - cm_server_names + - 0 + scheduler_hints: + group: servergroup_mog03 + server_pd_02: + type: org.openecomp.resource.vfc.nodes.heat.pd_server + properties: + flavor: + get_input: pd_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pd_image_name + user_data_format: RAW + name: + get_input: + - pd_server_names + - 1 + scheduler_hints: + group: servergroup_mog01 + server_pd_01: + type: org.openecomp.resource.vfc.nodes.heat.pd_server + properties: + flavor: + get_input: pd_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pd_image_name + user_data_format: RAW + name: + get_input: + - pd_server_names + - 0 + scheduler_hints: + group: servergroup_mog01 + server_oam01: + type: org.openecomp.resource.vfc.nodes.heat.oam_server + properties: + flavor: + get_input: oam_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: oam_image_name + user_data_format: RAW + name: + get_input: + - oam_server_names + - 0 + scheduler_hints: + group: servergroup_mog02 + server_oam02: + type: org.openecomp.resource.vfc.nodes.heat.oam_server + properties: + flavor: + get_input: oam_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: oam_image_name + user_data_format: RAW + name: + get_input: + - oam_server_names + - 1 + scheduler_hints: + group: servergroup_mog02 + dummy_net_1: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + dhcp_enabled: true + network_name: + get_input: dummy_net_name_1 + subnets: + dummy_ip_subnet_1: + enable_dhcp: true + name: + get_input: dummy_net_name_1 + cidr: + get_input: dummy_net_cidr_1 + allocation_pools: + - start: + get_input: dummy_net_start_1 + end: + get_input: dummy_net_end_1 + mog_security_group: + type: org.openecomp.resource.vfc.rules.nodes.heat.network.neutron.SecurityRules + properties: + name: + get_input: security_group_name + description: mog security group + rules: + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + requirements: + - port: + capability: tosca.capabilities.Attachment + node: pd01_port_0 + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: tosca.capabilities.Attachment + node: pd01_port_1 + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: tosca.capabilities.Attachment + node: pd01_port_2 + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: tosca.capabilities.Attachment + node: pd01_port_3 + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: tosca.capabilities.Attachment + node: pd01_port_4 + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: tosca.capabilities.Attachment + node: pd01_port_5 + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: tosca.capabilities.Attachment + node: pd01_port_6 + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: tosca.capabilities.Attachment + node: pd02_port_0 + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: tosca.capabilities.Attachment + node: pd02_port_1 + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: tosca.capabilities.Attachment + node: pd02_port_2 + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: tosca.capabilities.Attachment + node: pd02_port_3 + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: tosca.capabilities.Attachment + node: pd02_port_4 + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: tosca.capabilities.Attachment + node: pd02_port_5 + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: tosca.capabilities.Attachment + node: pd02_port_6 + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: tosca.capabilities.Attachment + node: oam01_port_0 + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: tosca.capabilities.Attachment + node: oam01_port_1 + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: tosca.capabilities.Attachment + node: oam02_port_0 + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: tosca.capabilities.Attachment + node: oam02_port_1 + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: tosca.capabilities.Attachment + node: sm01_port_0 + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: tosca.capabilities.Attachment + node: sm01_port_1 + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: tosca.capabilities.Attachment + node: sm01_port_2 + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: tosca.capabilities.Attachment + node: sm02_port_0 + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: tosca.capabilities.Attachment + node: sm02_port_1 + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: tosca.capabilities.Attachment + node: sm02_port_2 + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: tosca.capabilities.Attachment + node: ps01_port_0 + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: tosca.capabilities.Attachment + node: ps02_port_0 + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: tosca.capabilities.Attachment + node: ps03_port_0 + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: tosca.capabilities.Attachment + node: ps04_port_0 + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: tosca.capabilities.Attachment + node: cm01_port_0 + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: tosca.capabilities.Attachment + node: cm01_port_1 + relationship: org.openecomp.relationships.AttachesTo + pd01_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - mog_security_group + fixed_ips: + - ip_address: + get_input: + - oam_net_ips + - 0 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_pd_01 + relationship: tosca.relationships.network.BindsTo + pd02_port_3: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - mog_security_group + fixed_ips: + - ip_address: + get_input: + - rx_net_ips + - 1 + allowed_address_pairs: + - ip_address: + get_input: rx_net_floating_ip + network: + get_input: rx_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_pd_02 + relationship: tosca.relationships.network.BindsTo + pd01_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - mog_security_group + network: csb_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: csb_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_pd_01 + relationship: tosca.relationships.network.BindsTo + pd02_port_4: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - mog_security_group + network: dummy_net_1 + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: dummy_net_1 + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_pd_02 + relationship: tosca.relationships.network.BindsTo + pd01_port_3: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - mog_security_group + fixed_ips: + - ip_address: + get_input: + - rx_net_ips + - 0 + allowed_address_pairs: + - ip_address: + get_input: rx_net_floating_ip + network: + get_input: rx_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_pd_01 + relationship: tosca.relationships.network.BindsTo + pd02_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - mog_security_group + fixed_ips: + - ip_address: + get_input: + - oam_net_ips + - 1 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_pd_02 + relationship: tosca.relationships.network.BindsTo + pd01_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - mog_security_group + network: dummy_net_0 + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: dummy_net_0 + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_pd_01 + relationship: tosca.relationships.network.BindsTo + pd02_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - mog_security_group + network: dummy_net_0 + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: dummy_net_0 + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_pd_02 + relationship: tosca.relationships.network.BindsTo + oam01_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - mog_security_group + fixed_ips: + - ip_address: + get_input: + - oam_net_ips + - 2 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_oam01 + relationship: tosca.relationships.network.BindsTo + pd02_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - mog_security_group + network: csb_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: csb_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_pd_02 + relationship: tosca.relationships.network.BindsTo + oam02_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - mog_security_group + fixed_ips: + - ip_address: + get_input: + - oam_net_ips + - 3 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_oam02 + relationship: tosca.relationships.network.BindsTo + oam01_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - mog_security_group + network: csb_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: csb_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_oam01 + relationship: tosca.relationships.network.BindsTo + oam02_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - mog_security_group + network: csb_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: csb_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_oam02 + relationship: tosca.relationships.network.BindsTo + groups: + servergroup_mog01: + type: tosca.groups.Root + members: + - server_pd_01 + - server_pd_02 + servergroup_mog02: + type: tosca.groups.Root + members: + - server_oam01 + - server_oam02 + - server_sm01 + - server_sm02 + servergroup_mog03: + type: tosca.groups.Root + members: + - server_ps01 + - server_ps02 + - server_ps03 + - server_ps04 + - server_cm01 + hot-mog-0108-bs1271: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/hot-mog-0108-bs1271.yml + description: heat template that creates MOG stack + members: + - cm01_port_1 + - cm01_port_0 + - sm02_port_0 + - server_ps04 + - server_ps03 + - sm01_port_0 + - sm02_port_2 + - server_ps02 + - sm01_port_1 + - sm02_port_1 + - server_ps01 + - csb_net + - sm01_port_2 + - pd01_port_5 + - pd01_port_4 + - pd02_port_5 + - pd01_port_6 + - pd02_port_6 + - server_sm02 + - ps02_port_0 + - ps04_port_0 + - ps03_port_0 + - ps01_port_0 + - server_sm01 + - dummy_net_0 + - server_cm01 + - server_pd_02 + - server_pd_01 + - server_oam01 + - server_oam02 + - dummy_net_1 + - mog_security_group + - pd01_port_1 + - pd02_port_3 + - pd01_port_0 + - pd02_port_4 + - pd01_port_3 + - pd02_port_1 + - pd01_port_2 + - pd02_port_2 + - oam01_port_1 + - pd02_port_0 + - oam02_port_1 + - oam01_port_0 + - oam02_port_0 + policies: + servergroup_mog01: + type: org.openecomp.policies.placement.Antilocate + properties: + container_type: host + targets: + - servergroup_mog01 + servergroup_mog02: + type: org.openecomp.policies.placement.Antilocate + properties: + container_type: host + targets: + - servergroup_mog02 + servergroup_mog03: + type: org.openecomp.policies.placement.Antilocate + properties: + container_type: host + targets: + - servergroup_mog03 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-mog-0108-bs1271/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-mog-0108-bs1271/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..40c2b4c296 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-mog-0108-bs1271/inputfiles/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-mog-0108-bs1271.yml", + "type": "HEAT", + "data": [ + { + "file": "hot-mog-0108-bs1271.env", + "type": "HEAT_ENV" + } + ] + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-mog-0108-bs1271/inputfiles/hot-mog-0108-bs1271.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-mog-0108-bs1271/inputfiles/hot-mog-0108-bs1271.env new file mode 100644 index 0000000000..407bc8db30 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-mog-0108-bs1271/inputfiles/hot-mog-0108-bs1271.env @@ -0,0 +1,60 @@ +parameters: + pd_server_names: ZRDM1MOGX01MPD001,ZRDM1MOGX01MPD002 + pd_image_name: MOG_BASE_8.0 + pd_flavor_name: m3.xlarge + oam_server_names: ZRDM1MOGX01OAM001,ZRDM1MOGX01OAM002 + oam_image_name: MOG_BASE_8.0 + oam_flavor_name: m3.xlarge + sm_server_names: ZRDM1MOGX01MSM001,ZRDM1MOGX01MSM002 + sm_image_name: MOG_BASE_8.0 + sm_flavor_name: m2.xlarge4 + ps_server_names: ZRDM1MOGX01MPS001,ZRDM1MOGX01MPS002,ZRDM1MOGX01MPS003,ZRDM1MOGX01MPS004 + ps_image_name: MOG_BASE_8.0 + ps_flavor_name: m3.xlarge + cm_server_names: ZRDM1MOGX01MCM001 + cm_image_name: MOG_BASE_8.0 + cm_flavor_name: m3.xlarge + availabilityzone_name: nova + oam_net_name: oam_protected_net_0 + oam_net_ips: 107.250.172.213,107.250.172.214,107.250.172.215,107.250.172.216,107.250.172.217 + #internet_net_name: dmz_protected_net_0 + #internet_net_ips: 107.239.53.4,107.239.53.5 + # internet_net_floating_ip: 107.239.53.6 + sl_net_name: exn_protected_net_0 + sl_net_ips: 107.239.45.4,107.239.45.5 + sl_net_floating_ip: 107.239.45.6 + repl_net_name: cor_direct_net_0 + repl_net_ips: 107.239.33.57,107.239.33.58 + rx_net_name: cor_direct_net_1 + rx_net_ips: 107.239.34.3,107.239.34.4 + rx_net_floating_ip: 107.239.34.5 + ran_net_name: gn_direct_net_0 + ran_net_ips: 107.239.36.3,107.239.36.4 + ran_net_floating_ip: 107.239.36.5 + dummy_net_name_0: mog_dummy_0 + dummy_net_start_0: 169.254.1.4 + dummy_net_end_0: 169.254.1.254 + dummy_net_cidr_0: 169.254.1.0/24 + dummy_net_netmask_0: 255.255.255.0 + dummy_net_name_1: mog_dummy_1 + dummy_net_start_1: 169.254.2.4 + dummy_net_end_1: 169.254.2.254 + dummy_net_cidr_1: 169.254.2.0/24 + dummy_net_netmask_1: 255.255.255.0 + csb_net_name: int_mog_csb_net + csb_net_ips: 172.26.0.10,172.26.0.11,172.26.0.12,172.26.0.13,172.26.0.14,172.26.0.15,172.26.0.16,172.26.0.17,172.26.0.18,172.26.0.19,172.26.0.20 + csb_net_start: 172.26.0.1 + csb_net_end: 172.26.0.254 + csb_net_cidr: 172.26.0.0/24 + csb_net_netmask: 255.255.255.0 + security_group_name: mog_security_group + mog_swift_container: http://10.147.38.210:8080/v1/AUTH_8e501b8121f34a6eaaf526d3305985cc/mogtestcontainer + mog_script_dir: /root + mog_script_name: http://10.147.38.210:8080/v1/AUTH_8e501b8121f34a6eaaf526d3305985cc/mogtestcontainer/mog-cloudinit.sh + mog_parameter_name: http://10.147.38.210:8080/v1/AUTH_8e501b8121f34a6eaaf526d3305985cc/mogtestcontainer + cluster-manager-vol-1: 43ccf5ba-2d50-427b-a38f-e8c7d8670eee + session-manager-vol-1: 49201898-333d-4c88-b58d-cf573b091633 + session-manager-vol-2: 4c35b5f1-ce99-4220-a6e2-cda6e2d713a0 + oam-vol-1: 0a7fcd9e-2624-401d-ac21-b0191f85ec77 + oam-vol-2: 6d169cb6-6ddc-41dc-920c-2839898a2924 + cluster-manager-vol-2: 6f92e211-2d61-487d-8f84-d2d00cea3698 diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-mog-0108-bs1271/inputfiles/hot-mog-0108-bs1271.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-mog-0108-bs1271/inputfiles/hot-mog-0108-bs1271.yml new file mode 100644 index 0000000000..85ca654ce1 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-mog-0108-bs1271/inputfiles/hot-mog-0108-bs1271.yml @@ -0,0 +1,733 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates MOG stack + +parameters: + pd_server_names: + type: comma_delimited_list + label: PD server names + description: name of the PD instance + pd_image_name: + type: string + label: image name + description: PD image name + pd_flavor_name: + type: string + label: PD flavor name + description: flavor name of PD instance + oam_server_names: + type: comma_delimited_list + label: OAM server names + description: name of the OAM instance + oam_image_name: + type: string + label: image name + description: OAM image name + oam_flavor_name: + type: string + label: OAM flavor name + description: flavor name of OAM instance + sm_server_names: + type: comma_delimited_list + label: SM server names + description: name of the SM instance + sm_image_name: + type: string + label: image name + description: SM image name + sm_flavor_name: + type: string + label: SM flavor name + description: flavor name of SM instance + ps_server_names: + type: comma_delimited_list + label: PS server names + description: name of the PS instance + ps_image_name: + type: string + label: PS image name + description: PS image name + ps_flavor_name: + type: string + label: PS flavor name + description: flavor name of PS instance + cm_server_names: + type: comma_delimited_list + label: CM server names + description: name of the CM instance + cm_image_name: + type: string + label: image name + description: CM image name + cm_flavor_name: + type: string + label: CM flavor name + description: flavor name of CM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + oam_net_name: + type: string + label: oam network name + description: name of the oam network + oam_net_ips: + type: comma_delimited_list + label: internet network ips + description: ip of the OAM network + # internet_net_name: + # type: string + # label: internet network name + # description: id of the internet network + # internet_net_ips: + # type: comma_delimited_list + # label: internet network ips + # description: ip of the internet network + # internet_net_floating_ip: + # type: string + # label: mog internet virtual ip + # description: mog internet virtual ip + sl_net_name: + type: string + label: silver lining network name + description: id of the sl network + sl_net_ips: + type: comma_delimited_list + label: silver lining network ips + description: ips of the sl network + sl_net_floating_ip: + type: string + label: mog sl net virtual ip + description: mog sl net virtual ip + repl_net_name: + type: string + label: Replication network name + description: name of the replication network + repl_net_ips: + type: comma_delimited_list + label: repl network ips + description: ips of repl network + rx_net_name: + type: string + label: Rx network name + description: Rx network name + rx_net_ips: + type: comma_delimited_list + label: Rx network ips + description: Rx network ips + rx_net_floating_ip: + type: string + label: mog rx net virtual ip + description: mog rx net virtual ip + ran_net_name: + type: string + label: RAN network name + description: RAN network name + ran_net_ips: + type: comma_delimited_list + label: RAN network ips + description: RAN network ip + ran_net_floating_ip: + type: string + label: mog ran net virtual ip + description: mog ran net virtual ip + csb_net_name: + type: string + label: csb internal network name + description: csb internal network name + csb_net_start: + type: string + label: csb internal start + description: csb internal start + csb_net_end: + type: string + label: csb internal end + description: csb internal end + csb_net_cidr: + type: string + label: csb ineternal cidr + description: csb internal cidr + csb_net_netmask: + type: string + description: CSB internal network subnet mask + csb_net_ips: + type: comma_delimited_list + description: mog_csb_net IP addresses + dummy_net_name_0: + type: string + label: csb internal network name + description: csb internal network name + dummy_net_start_0: + type: string + label: csb internal start + description: csb internal start + dummy_net_end_0: + type: string + label: csb internal end + description: csb internal end + dummy_net_cidr_0: + type: string + label: csb ineternal cidr + description: csb internal cidr + dummy_net_netmask_0: + type: string + description: CSB internal network subnet mask + dummy_net_name_1: + type: string + label: csb internal network name + description: csb internal network name + dummy_net_start_1: + type: string + label: csb internal start + description: csb internal start + dummy_net_end_1: + type: string + label: csb internal end + description: csb internal end + dummy_net_cidr_1: + type: string + label: csb ineternal cidr + description: csb internal cidr + dummy_net_netmask_1: + type: string + description: CSB internal network subnet mask + + security_group_name: + type: string + label: security group name + description: the name of security group + cluster-manager-vol-1: + type: string + label: mog-cm-vol-1 + description: Cluster Manager volume 1 + session-manager-vol-1: + type: string + label: mog-sm-vol-1 + description: Session Manager volume 1 + session-manager-vol-2: + type: string + label: mog-sm-vol-2 + description: Session Manager volume 2 + oam-vol-1: + type: string + label: mog-oam-vol-1 + description: OAM volume 1 + oam-vol-2: + type: string + label: mog-oam-vol-2 + description: OAM volume 2 + mog_swift_container: + type: string + label: mog Config URL + description: Config URL + mog_script_dir: + type: string + label: mog Config script directory + description: Config script directory + mog_script_name: + type: string + label: mog Config script name + description: Config script name + mog_parameter_name: + type: string + label: mog script parameter name + description: Config script parameter csv file name + cluster-manager-vol-2: + type: string + label: mog-cm-vol-2 + description: Cluster Manager volume 2 with ISO image + +resources: + mog_security_group: + type: OS::Neutron::SecurityGroup + properties: + description: mog security group + name: {get_param: security_group_name} + rules: [{"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0} + ] + + csb_net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: csb_net_name} + + csb_ip_subnet: + type: OS::Neutron::Subnet + properties: + name: {get_param: csb_net_name} + network_id: { get_resource: csb_net } + cidr: { get_param: csb_net_cidr } + allocation_pools: [{"start": {get_param: csb_net_start}, "end": {get_param: csb_net_end}}] + enable_dhcp: true + + dummy_net_0: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: dummy_net_name_0} + + dummy_ip_subnet_0: + type: OS::Neutron::Subnet + properties: + name: {get_param: dummy_net_name_0} + network_id: { get_resource: dummy_net_0 } + cidr: { get_param: dummy_net_cidr_0 } + allocation_pools: [{"start": {get_param: dummy_net_start_0}, "end": {get_param: dummy_net_end_0}}] + enable_dhcp: true + + dummy_net_1: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: dummy_net_name_1} + + dummy_ip_subnet_1: + type: OS::Neutron::Subnet + properties: + name: {get_param: dummy_net_name_1} + network_id: { get_resource: dummy_net_1 } + cidr: { get_param: dummy_net_cidr_1 } + allocation_pools: [{"start": {get_param: dummy_net_start_1}, "end": {get_param: dummy_net_end_1}}] + enable_dhcp: true + + + mogconfig: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + template: | + #!/bin/bash + wget -P script_dir swift_container/script_name + wget -P script_dir swift_container/parameter_name + chmod 755 script_dir/script_name + script_dir/script_name + params: + swift_container: {get_param: mog_swift_container} + script_dir: {get_param: mog_script_dir} + script_name: {get_param: mog_script_name} + #parameter_name: {get_param: mog_parameter_name} + + + servergroup_mog01: + type: OS::Nova::ServerGroup + properties: + policies: + - anti-affinity + server_pd_01: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [pd_server_names, 0]} + image: {get_param: pd_image_name} + flavor: {get_param: pd_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: pd01_port_0} + - port: {get_resource: pd01_port_1} + - port: {get_resource: pd01_port_2} + - port: {get_resource: pd01_port_3} + - port: {get_resource: pd01_port_4} + - port: {get_resource: pd01_port_5} + - port: {get_resource: pd01_port_6} + # - port: {get_resource: pd01_port_7} + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog01}} + user_data_format: RAW + + + pd01_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + pd01_port_1: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [oam_net_ips, 0]}}] + security_groups: [{get_resource: mog_security_group}] + pd01_port_2: + type: OS::Neutron::Port + properties: + network: {get_resource: dummy_net_0} + security_groups: [{get_resource: mog_security_group}] + pd01_port_3: + type: OS::Neutron::Port + properties: + network: {get_param: rx_net_name} + fixed_ips: [{"ip_address": {get_param: [rx_net_ips, 0]}}] + allowed_address_pairs: [{"ip_address": {get_param: rx_net_floating_ip} }] + security_groups: [{get_resource: mog_security_group}] + pd01_port_4: + type: OS::Neutron::Port + properties: + network: {get_resource: dummy_net_1} + security_groups: [{get_resource: mog_security_group}] + pd01_port_5: + type: OS::Neutron::Port + properties: + network: {get_param: ran_net_name} + fixed_ips: [{"ip_address": {get_param: [ran_net_ips, 0]}}] + allowed_address_pairs: [{"ip_address": {get_param: ran_net_floating_ip} }] + security_groups: [{get_resource: mog_security_group}] + + pd01_port_6: + type: OS::Neutron::Port + properties: + network: {get_param: sl_net_name} + fixed_ips: [{"ip_address": {get_param: [sl_net_ips, 0]}}] + allowed_address_pairs: [{"ip_address": {get_param: sl_net_floating_ip}}] + security_groups: [{get_resource: mog_security_group}] + + # pd01_port_7: + #j type: OS::Neutron::Port + # properties: + # network: {get_param: internet_net_name} + # fixed_ips: [{"ip_address": {get_param: [internet_net_ips, 0]}}] + # allowed_address_pairs: [{"ip_address": {get_param: internet_net_floating_ip} }] + # security_groups: [{get_resource: mog_security_group}] + + server_pd_02: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [pd_server_names, 1]} + image: {get_param: pd_image_name} + flavor: {get_param: pd_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: pd02_port_0} + - port: {get_resource: pd02_port_1} + - port: {get_resource: pd02_port_2} + - port: {get_resource: pd02_port_3} + - port: {get_resource: pd02_port_4} + - port: {get_resource: pd02_port_5} + - port: {get_resource: pd02_port_6} + # - port: {get_resource: pd02_port_7} + + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog01}} + user_data_format: RAW + + pd02_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + pd02_port_1: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [oam_net_ips, 1]}}] + security_groups: [{get_resource: mog_security_group}] + + pd02_port_2: + type: OS::Neutron::Port + properties: + network: {get_resource: dummy_net_0} + security_groups: [{get_resource: mog_security_group}] + + pd02_port_3: + type: OS::Neutron::Port + properties: + network: {get_param: rx_net_name} + fixed_ips: [{"ip_address": {get_param: [rx_net_ips, 1]}}] + allowed_address_pairs: [{"ip_address": {get_param: rx_net_floating_ip} }] + security_groups: [{get_resource: mog_security_group}] + + pd02_port_4: + type: OS::Neutron::Port + properties: + network: {get_resource: dummy_net_1} + security_groups: [{get_resource: mog_security_group}] + + pd02_port_5: + type: OS::Neutron::Port + properties: + network: {get_param: ran_net_name} + fixed_ips: [{"ip_address": {get_param: [ran_net_ips, 1]}}] + allowed_address_pairs: [{"ip_address": {get_param: ran_net_floating_ip} }] + security_groups: [{get_resource: mog_security_group}] + + pd02_port_6: + type: OS::Neutron::Port + properties: + network: {get_param: sl_net_name} + fixed_ips: [{"ip_address": {get_param: [sl_net_ips, 1]}}] + allowed_address_pairs: [{"ip_address": {get_param: sl_net_floating_ip}}] + security_groups: [{get_resource: mog_security_group}] + + # pd02_port_7: + # type: OS::Neutron::Port + # properties: + # network: {get_param: internet_net_name} + # fixed_ips: [{"ip_address": {get_param: [internet_net_ips, 1]}}] + # allowed_address_pairs: [{"ip_address": {get_param: internet_net_floating_ip} }] + # security_groups: [{get_resource: mog_security_group}] + + servergroup_mog02: + type: OS::Nova::ServerGroup + properties: + policies: + - anti-affinity + server_oam01: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [oam_server_names, 0]} + image: {get_param: oam_image_name} + flavor: {get_param: oam_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: oam01_port_0} + - port: {get_resource: oam01_port_1} +# block_device_mapping: +# - device_name: vdd +# volume_id: { get_param: oam-vol-1 } + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog02}} + user_data_format: RAW + + oam01_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + oam01_port_1: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [oam_net_ips, 2]}}] + security_groups: [{get_resource: mog_security_group}] + + + server_oam02: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [oam_server_names, 1]} + image: {get_param: oam_image_name} + flavor: {get_param: oam_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: oam02_port_0} + - port: {get_resource: oam02_port_1} +# block_device_mapping: +# - device_name: vdd +# volume_id: { get_param: oam-vol-2 } + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog02}} + user_data_format: RAW + + oam02_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + oam02_port_1: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [oam_net_ips, 3]}}] + security_groups: [{get_resource: mog_security_group}] + + + server_sm01: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [sm_server_names, 0]} + image: {get_param: sm_image_name} + flavor: {get_param: sm_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: sm01_port_0} + - port: {get_resource: sm01_port_1} +# block_device_mapping: +# - device_name: vdd +# volume_id: { get_param: session-manager-vol-1 } + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog02}} + user_data_format: RAW + + sm01_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + sm01_port_1: + type: OS::Neutron::Port + properties: + network: {get_resource: dummy_net_0} + security_groups: [{get_resource: mog_security_group}] + + sm01_port_2: + type: OS::Neutron::Port + properties: + network: {get_param: repl_net_name} + fixed_ips: [{"ip_address": {get_param: [repl_net_ips, 0]}}] + security_groups: [{get_resource: mog_security_group}] + + server_sm02: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [sm_server_names, 1]} + image: {get_param: sm_image_name} + flavor: {get_param: sm_flavor_name} + availability_zone: {get_param: availabilityzone_name} +# block_device_mapping: +# - device_name: vdd +# volume_id: { get_param: session-manager-vol-2 } + networks: + - port: {get_resource: sm02_port_0} + - port: {get_resource: sm02_port_1} + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog02}} + user_data_format: RAW + + sm02_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + sm02_port_1: + type: OS::Neutron::Port + properties: + network: {get_resource: dummy_net_0} + security_groups: [{get_resource: mog_security_group}] + + sm02_port_2: + type: OS::Neutron::Port + properties: + network: {get_param: repl_net_name} + fixed_ips: [{"ip_address": {get_param: [repl_net_ips, 1]}}] + security_groups: [{get_resource: mog_security_group}] + + servergroup_mog03: + type: OS::Nova::ServerGroup + properties: + policies: + - anti-affinity + server_ps01: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [ps_server_names, 0]} + image: {get_param: ps_image_name} + flavor: {get_param: ps_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: ps01_port_0} + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog03}} + user_data_format: RAW + + ps01_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + server_ps02: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [ps_server_names, 1]} + image: {get_param: ps_image_name} + flavor: {get_param: ps_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: ps02_port_0} + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog03}} + user_data_format: RAW + + ps02_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + server_ps03: + type: OS::Nova::Server + properties: + name: {get_param: [ps_server_names, 2]} + image: {get_param: ps_image_name} + flavor: {get_param: ps_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: ps03_port_0} + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog03}} + user_data_format: RAW + + ps03_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + server_ps04: + type: OS::Nova::Server + properties: + name: {get_param: [ps_server_names, 3]} + image: {get_param: ps_image_name} + flavor: {get_param: ps_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: ps04_port_0} + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog03}} + user_data_format: RAW + + ps04_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + security_groups: [{get_resource: mog_security_group}] + + server_cm01: + type: OS::Nova::Server + properties: +# config_drive: "True" + name: {get_param: [cm_server_names, 0]} + image: {get_param: cm_image_name} + flavor: {get_param: cm_flavor_name} + availability_zone: {get_param: availabilityzone_name} + networks: + - port: {get_resource: cm01_port_0} + - port: {get_resource: cm01_port_1} +# block_device_mapping: +# - device_name: vdd +# volume_id: { get_param: cluster-manager-vol-2 } +# - device_name: vde +# volume_id: { get_param: cluster-manager-vol-1 } + user_data: + scheduler_hints: {group: {get_resource: servergroup_mog03}} + user_data_format: RAW + + cm01_port_0: + type: OS::Neutron::Port + properties: + network: {get_resource: csb_net} + fixed_ips: [{"ip_address": {get_param: [csb_net_ips, 10]}}] + security_groups: [{get_resource: mog_security_group}] + + cm01_port_1: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + fixed_ips: [{"ip_address": {get_param: [oam_net_ips, 4]}}] + security_groups: [{get_resource: mog_security_group}] + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..14c9a99cf7 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/MANIFEST.json @@ -0,0 +1,99 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-oam_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-oam_v1.0.env", + "type": "HEAT_ENV" + }, + { + "file": "hot-nimbus-oam-volumes_v1.0.yaml", + "type": "HEAT_VOL", + "data": [{ + "file": "hot-nimbus-oam-volumes_v1.0.env", + "type": "HEAT_ENV" + }] + } + ] + }, + { + "file": "hot-nimbus-pcm_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pcm_v1.0.env", + "type": "HEAT_ENV" + }, + { + "file": "hot-nimbus-pcm-volumes_v1.0.yaml", + "type": "HEAT_VOL", + "data": [{ + "file": "hot-nimbus-pcm-volumes_v1.0.env", + "type": "HEAT_ENV" + }] + } + ] + }, + { + "file": "hot-nimbus-ppd_v1.0.yaml", + "type": "HEAT", + "data": [{ + "file": "hot-nimbus-ppd_v1.1.env", + "type": "HEAT_ENV" + }] + }, + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT", + "data": [{ + "file": "hot-nimbus-pps_v1.0.env", + "type": "HEAT_ENV" + }] + }, + { + "file": "hot-nimbus-psm_v1.0.yaml", + "type": "HEAT", + "data": [{ + "file": "hot-nimbus-psm_v1.0.env", + "type": "HEAT_ENV" + }] + }, + { + "file": "nested-oam_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "nested-pcm_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "nested-ppd_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "nested-pps_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "nested-psm_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "cloud-nimbus.sh", + "type": "SHELL" + }, + { + "file": "nimbus-ethernet", + "type": "OTHER" + }, + { + "file": "nimbus-ethernet-gw", + "type": "OTHER" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/cloud-nimbus.sh b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/cloud-nimbus.sh new file mode 100644 index 0000000000..8e5a486289 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/cloud-nimbus.sh @@ -0,0 +1,12 @@ +#!/bin/bash +echo "Running first-boot script" +FLAG="first-boot.sh" +echo "First boot run" > ${FLAG} +echo "$vm_name" >> ${FLAG} +touch /var/lib/cloud/instance/payload/launch-params +chmod 644 /var/lib/cloud/instance/payload/launch-params +#for i in $(ls /sys/class/net); do +# echo "Restart $i" >> ${FLAG} +# ifdown ${i} +# ifup ${i} +#done diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-oam-volumes_v1.0.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-oam-volumes_v1.0.env new file mode 100644 index 0000000000..b494d8c270 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-oam-volumes_v1.0.env @@ -0,0 +1,6 @@ +parameters: + pcrf_oam_vol_size: 500 + pcrf_oam_volume_silver-1: Silver + pcrf_oam_volume_silver-2: Silver + pcrf_oam_vol_name_1: sde1-pcrfx01-oam001-vol-1 + pcrf_oam_vol_name_2: sde1-pcrfx01-oam001-vol-2 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-oam-volumes_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-oam-volumes_v1.0.yaml new file mode 100644 index 0000000000..3b05f6fc8b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-oam-volumes_v1.0.yaml @@ -0,0 +1,45 @@ +heat_template_version: 2013-05-23 + +parameters: + pcrf_oam_vol_size: + type: number + label: Cinder volume size + description: the size of the Cinder volume + pcrf_oam_vol_name_1: + type: string + label: OAM volume name 1 + description: Assigning name to volume + pcrf_oam_vol_name_2: + type: string + label: OAM volume name 2 + description: Assigning name to volume + pcrf_oam_volume_silver-1: + type: string + label: vm volume type + description: the name of the target volume backend for OAM1 + pcrf_oam_volume_silver-2: + type: string + label: vm volume type + description: the name of the target volume backend for OAM2 + +resources: + pcrf_oam_volume_id_11: + type: OS::Cinder::Volume + properties: + size: {get_param: pcrf_oam_vol_size} + volume_type: {get_param: pcrf_oam_volume_silver-1} + name: {get_param: pcrf_oam_vol_name_1} + + pcrf_oam_volume_id_22: + type: OS::Cinder::Volume + properties: + size: {get_param: pcrf_oam_vol_size} + volume_type: {get_param: pcrf_oam_volume_silver-2} + name: {get_param: pcrf_oam_vol_name_2} +outputs: + pcrf_oam_volume_id_1: + description: the oam 001 volume id + value: { get_resource: pcrf_oam_volume_id_11 } + pcrf_oam_volume_id_2: + description: the oam 002 volume id + value: { get_resource: pcrf_oam_volume_id_22 } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-oam_v1.0.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-oam_v1.0.env new file mode 100644 index 0000000000..138feb5822 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-oam_v1.0.env @@ -0,0 +1,18 @@ +parameters: + pcrf_oam_server_names: ZRDM1PCRF01OAM001,ZRDM1PCRF01OAM002 + pcrf_oam_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_oam_flavor_name: lc.4xlarge4 + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.111,172.26.16.112 + pcrf_arbiter_vip: 172.26.16.115 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_oam_net_name: MNS-25180-L-01_oam_protected_net_0 + pcrf_oam_net_ips: 107.239.64.117,107.239.64.118 + pcrf_oam_net_gw: 107.239.64.1 + pcrf_oam_net_mask: 255.255.248.0 + pcrf_oam_volume_id_1: a4aa05fb-fcdc-457b-8077-6845fdfc3257 + pcrf_oam_volume_id_2: 93d8fc1f-f1c3-4933-86b2-039881ee910f + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-oam_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-oam_v1.0.yaml new file mode 100644 index 0000000000..2aa1235de2 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-oam_v1.0.yaml @@ -0,0 +1,109 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates multiple PCRF OAM nodes stack + +parameters: + pcrf_oam_server_names: + type: comma_delimited_list + label: PCRF OAM server names + description: name of the PCRF OAM instance + pcrf_oam_image_name: + type: string + label: PCRF OAM image name + description: PCRF OAM image name + pcrf_oam_flavor_name: + type: string + label: PCRF OAM flavor name + description: flavor name of PCRF OAM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_arbiter_vip: + type: string + label: OAM Arbiter LB VIP + description: OAM Arbiter LB VIP + pcrf_oam_net_name: + type: string + label: OAM network name + description: OAM network name + pcrf_oam_net_ips: + type: comma_delimited_list + label: OAM network ips + description: OAM network ips + pcrf_oam_net_gw: + type: string + label: CPS network gateway + description: CPS network gateway + pcrf_oam_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_oam_volume_id_1: + type: string + label: CPS OAM 001 Cinder Volume + description: CPS OAM 001 Cinder Volumes + pcrf_oam_volume_id_2: + type: string + label: CPS OAM 002 Cinder Volume + description: CPS OAM 002 Cinder Volumes + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_oam_001: + type: nested-oam_v1.0.yaml + properties: + pcrf_oam_server_name: { get_param: [pcrf_oam_server_names, 0] } + pcrf_oam_image_name: { get_param: pcrf_oam_image_name } + pcrf_oam_flavor_name: { get_param: pcrf_oam_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_oam_volume_id: { get_param: pcrf_oam_volume_id_1 } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_oam_net_name: { get_param: pcrf_oam_net_name } + pcrf_oam_net_ip: { get_param: [pcrf_oam_net_ips, 0] } + pcrf_oam_net_mask: { get_param: pcrf_oam_net_mask } + pcrf_oam_net_gw: { get_param: pcrf_oam_net_gw } + pcrf_arbiter_vip: { get_param: pcrf_arbiter_vip } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_oam_002: + type: nested-oam_v1.0.yaml + depends_on: [server_pcrf_oam_001] + properties: + pcrf_oam_server_name: { get_param: [pcrf_oam_server_names, 1] } + pcrf_oam_image_name: { get_param: pcrf_oam_image_name } + pcrf_oam_flavor_name: { get_param: pcrf_oam_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_oam_volume_id: { get_param: pcrf_oam_volume_id_2 } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_oam_net_name: { get_param: pcrf_oam_net_name } + pcrf_oam_net_ip: { get_param: [pcrf_oam_net_ips, 1] } + pcrf_oam_net_mask: { get_param: pcrf_oam_net_mask } + pcrf_oam_net_gw: { get_param: pcrf_oam_net_gw } + pcrf_arbiter_vip: { get_param: pcrf_arbiter_vip } + pcrf_vnf_id: {get_param: pcrf_vnf_id} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-pcm-volumes_v1.0.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-pcm-volumes_v1.0.env new file mode 100644 index 0000000000..788365dcd3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-pcm-volumes_v1.0.env @@ -0,0 +1,4 @@ +parameters: + pcrf_pcm_vol_size: 50 + pcrf_pcm_volume_silver: Silver + pcrf_pcm_vol_name_1: sde1-pcrfx01-pcm001-vol-1 diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-pcm-volumes_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-pcm-volumes_v1.0.yaml new file mode 100644 index 0000000000..11a491164d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-pcm-volumes_v1.0.yaml @@ -0,0 +1,28 @@ +heat_template_version: 2013-05-23 + +parameters: + pcrf_pcm_vol_size: + type: number + label: Cinder volume size + description: the size of the Cinder volume + pcrf_pcm_vol_name_1: + type: string + label: PCM volume name + description: Assigning name to volume + pcrf_pcm_volume_silver: + type: string + label: vm volume type + description: the name of the target volume backend for PCM + +resources: + pcrf_pcm_volume_id_1: + type: OS::Cinder::Volume + properties: + size: { get_param: pcrf_pcm_vol_size } + volume_type: { get_param: pcrf_pcm_volume_silver } + name: { get_param: pcrf_pcm_vol_name_1 } + +outputs: + pcrf_pcm_volume_id_1: + description: the pcrf_pcm_volume_id + value: { get_resource: pcrf_pcm_volume_id_1 } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-pcm_v1.0.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-pcm_v1.0.env new file mode 100644 index 0000000000..82fb510291 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-pcm_v1.0.env @@ -0,0 +1,16 @@ +parameters: + pcrf_pcm_server_names: ZRDM1PCRF01PCM001 + pcrf_pcm_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pcm_flavor_name: lc.2xlarge4 + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.113 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_oam_net_name: MNS-25180-L-01_oam_protected_net_0 + pcrf_oam_net_ips: 107.239.64.121 + pcrf_oam_net_gw: 107.239.64.1 + pcrf_oam_net_mask: 255.255.248.0 + pcrf_pcm_volume_id_1: 3438a3fe-1241-4390-80f2-d0b86238c40e + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-pcm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-pcm_v1.0.yaml new file mode 100644 index 0000000000..2dd7480bfc --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-pcm_v1.0.yaml @@ -0,0 +1,80 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Cluman stack + +parameters: + pcrf_pcm_server_names: + type: comma_delimited_list + label: PCRF CM server names + description: name of the PCRF CM instance + pcrf_pcm_image_name: + type: string + label: PCRF CM image name + description: PCRF CM image name + pcrf_pcm_flavor_name: + type: string + label: PCRF CM flavor name + description: flavor name of PCRF CM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_oam_net_name: + type: string + label: OAM network name + description: OAM network name + pcrf_oam_net_ips: + type: comma_delimited_list + label: OAM network ips + description: OAM network ips + pcrf_oam_net_gw: + type: string + label: CPS network gateway + description: CPS network gateway + pcrf_oam_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_pcm_volume_id_1: + type: string + label: CPS Cluman Cinder Volume + description: CPS Cluman Cinder Volume + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_pcm_001: + type: nested-pcm_v1.0.yaml + properties: + pcrf_pcm_server_name: { get_param: [pcrf_pcm_server_names, 0] } + pcrf_pcm_image_name: { get_param: pcrf_pcm_image_name } + pcrf_pcm_flavor_name: { get_param: pcrf_pcm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_pcm_volume_id: { get_param: pcrf_pcm_volume_id_1 } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_oam_net_name: { get_param: pcrf_oam_net_name } + pcrf_oam_net_ip: { get_param: [pcrf_oam_net_ips, 0] } + pcrf_oam_net_mask: { get_param: pcrf_oam_net_mask } + pcrf_oam_net_gw: { get_param: pcrf_oam_net_gw } + pcrf_vnf_id: {get_param: pcrf_vnf_id} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-ppd_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-ppd_v1.0.yaml new file mode 100644 index 0000000000..2fffa0df8c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-ppd_v1.0.yaml @@ -0,0 +1,286 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Director stack + +parameters: + pcrf_ppd_server_names: + type: comma_delimited_list + label: PCRF PD server names + description: name of the PCRF PD instance + pcrf_ppd_image_name: + type: string + label: PCRF PD image name + description: PCRF PD image name + pcrf_ppd_flavor_name: + type: string + label: PCRF PD flavor name + description: flavor name of PCRF PD instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_lb_internal_vip: + type: string + label: CPS Internal LB VIP + description: CPS Internal LB VIP + pcrf_oam_net_name: + type: string + label: OAM network name + description: OAM network name + pcrf_oam_net_ips: + type: comma_delimited_list + label: OAM network ips + description: OAM network ips + pcrf_oam_net_gw: + type: string + label: CPS network gateway + description: CPS network gateway + pcrf_oam_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_lb_management_vip: + type: string + label: CPS OAM LB VIP + description: CPS OAM LB VIP + pcrf_gx_net_name: + type: string + label: Gx network name + description: Gx network name + pcrf_gx_net_ips: + type: comma_delimited_list + label: Gx network ips + description: Gx network ips + pcrf_gx_net_mask: + type: string + label: Gx network mask + description: Gx network mask + pcrf_sp_net_name: + type: string + label: Sp network name + description: Sp network name + pcrf_sp_net_ips: + type: comma_delimited_list + label: Sp network ips + description: Sp network ips + pcrf_sp_net_mask: + type: string + label: Sp network mask + description: Sp network mask + pcrf_sy_net_name: + type: string + label: Sy network name + description: Sy network name + pcrf_sy_net_ips: + type: comma_delimited_list + label: Sy network ips + description: Sy network ips + pcrf_sy_net_mask: + type: string + label: Sy network mask + description: Sy network mask + pcrf_rx_net_name: + type: string + label: Rx network name + description: Rx network name + pcrf_rx_net_ips: + type: comma_delimited_list + label: Rx network ips + description: Rx network ips + pcrf_rx_net_mask: + type: string + label: Rx network mask + description: Rx network mask + pcrf_sd_net_name: + type: string + label: Sd network name + description: Sd network name + pcrf_sd_net_ips: + type: comma_delimited_list + label: Sd network ips + description: Sd network ips + pcrf_sd_net_mask: + type: string + label: Sd network mask + description: Sd network mask + pcrf_sgi_sy_net_name: + type: string + label: Sgi Sy network name + description: Sgi Sy network name + pcrf_sgi_sy_net_ips: + type: comma_delimited_list + label: Sgi Sy network ips + description: Sgi Sy network ips + pcrf_sgi_sy_net_mask: + type: string + label: Sgi Sy network mask + description: Sgi Sy network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_ppd_001: + type: nested-ppd_v1.0.yaml + properties: + pcrf_ppd_server_name: { get_param: [pcrf_ppd_server_names, 0] } + pcrf_ppd_image_name: { get_param: pcrf_ppd_image_name } + pcrf_ppd_flavor_name: { get_param: pcrf_ppd_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_lb_internal_vip: { get_param: pcrf_lb_internal_vip } + pcrf_oam_net_name: { get_param: pcrf_oam_net_name } + pcrf_oam_net_ip: { get_param: [pcrf_oam_net_ips, 0] } + pcrf_oam_net_mask: { get_param: pcrf_oam_net_mask } + pcrf_oam_net_gw: { get_param: pcrf_oam_net_gw } + pcrf_lb_management_vip: { get_param: pcrf_lb_management_vip } + pcrf_gx_net_name: { get_param: pcrf_gx_net_name } + pcrf_gx_net_ip: { get_param: [pcrf_gx_net_ips, 0] } + pcrf_gx_net_mask: { get_param: pcrf_gx_net_mask } + pcrf_sp_net_name: { get_param: pcrf_sp_net_name } + pcrf_sp_net_ip: { get_param: [pcrf_sp_net_ips, 0] } + pcrf_sp_net_mask: { get_param: pcrf_sp_net_mask } + pcrf_sy_net_name: { get_param: pcrf_sy_net_name } + pcrf_sy_net_ip: { get_param: [pcrf_sy_net_ips, 0] } + pcrf_sy_net_mask: { get_param: pcrf_sy_net_mask } + pcrf_rx_net_name: { get_param: pcrf_rx_net_name } + pcrf_rx_net_ip: { get_param: [pcrf_rx_net_ips, 0] } + pcrf_rx_net_mask: { get_param: pcrf_rx_net_mask } + pcrf_sd_net_name: { get_param: pcrf_sd_net_name } + pcrf_sd_net_ip: { get_param: [pcrf_sd_net_ips, 0] } + pcrf_sd_net_mask: { get_param: pcrf_sd_net_mask } + pcrf_sgi_sy_net_name: { get_param: pcrf_sgi_sy_net_name } + pcrf_sgi_sy_net_ip: { get_param: [pcrf_sgi_sy_net_ips, 0] } + pcrf_sgi_sy_net_mask: { get_param: pcrf_sgi_sy_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_ppd_002: + type: nested-ppd_v1.0.yaml + properties: + pcrf_ppd_server_name: { get_param: [pcrf_ppd_server_names, 1] } + pcrf_ppd_image_name: { get_param: pcrf_ppd_image_name } + pcrf_ppd_flavor_name: { get_param: pcrf_ppd_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_lb_internal_vip: { get_param: pcrf_lb_internal_vip } + pcrf_oam_net_name: { get_param: pcrf_oam_net_name } + pcrf_oam_net_ip: { get_param: [pcrf_oam_net_ips, 1] } + pcrf_oam_net_mask: { get_param: pcrf_oam_net_mask } + pcrf_oam_net_gw: { get_param: pcrf_oam_net_gw } + pcrf_lb_management_vip: { get_param: pcrf_lb_management_vip } + pcrf_gx_net_name: { get_param: pcrf_gx_net_name } + pcrf_gx_net_ip: { get_param: [pcrf_gx_net_ips, 1] } + pcrf_gx_net_mask: { get_param: pcrf_gx_net_mask } + pcrf_sp_net_name: { get_param: pcrf_sp_net_name } + pcrf_sp_net_ip: { get_param: [pcrf_sp_net_ips, 1] } + pcrf_sp_net_mask: { get_param: pcrf_sp_net_mask } + pcrf_sy_net_name: { get_param: pcrf_sy_net_name } + pcrf_sy_net_ip: { get_param: [pcrf_sy_net_ips, 1] } + pcrf_sy_net_mask: { get_param: pcrf_sy_net_mask } + pcrf_rx_net_name: { get_param: pcrf_rx_net_name } + pcrf_rx_net_ip: { get_param: [pcrf_rx_net_ips, 1] } + pcrf_rx_net_mask: { get_param: pcrf_rx_net_mask } + pcrf_sd_net_name: { get_param: pcrf_sd_net_name } + pcrf_sd_net_ip: { get_param: [pcrf_sd_net_ips, 1] } + pcrf_sd_net_mask: { get_param: pcrf_sd_net_mask } + pcrf_sgi_sy_net_name: { get_param: pcrf_sgi_sy_net_name } + pcrf_sgi_sy_net_ip: { get_param: [pcrf_sgi_sy_net_ips, 1] } + pcrf_sgi_sy_net_mask: { get_param: pcrf_sgi_sy_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_ppd_003: + type: nested-ppd_v1.0.yaml + properties: + pcrf_ppd_server_name: { get_param: [pcrf_ppd_server_names, 2] } + pcrf_ppd_image_name: { get_param: pcrf_ppd_image_name } + pcrf_ppd_flavor_name: { get_param: pcrf_ppd_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_lb_internal_vip: { get_param: pcrf_lb_internal_vip } + pcrf_oam_net_name: { get_param: pcrf_oam_net_name } + pcrf_oam_net_ip: { get_param: [pcrf_oam_net_ips, 2] } + pcrf_oam_net_mask: { get_param: pcrf_oam_net_mask } + pcrf_oam_net_gw: { get_param: pcrf_oam_net_gw } + pcrf_lb_management_vip: { get_param: pcrf_lb_management_vip } + pcrf_gx_net_name: { get_param: pcrf_gx_net_name } + pcrf_gx_net_ip: { get_param: [pcrf_gx_net_ips, 2] } + pcrf_gx_net_mask: { get_param: pcrf_gx_net_mask } + pcrf_sp_net_name: { get_param: pcrf_sp_net_name } + pcrf_sp_net_ip: { get_param: [pcrf_sp_net_ips, 2] } + pcrf_sp_net_mask: { get_param: pcrf_sp_net_mask } + pcrf_sy_net_name: { get_param: pcrf_sy_net_name } + pcrf_sy_net_ip: { get_param: [pcrf_sy_net_ips, 2] } + pcrf_sy_net_mask: { get_param: pcrf_sy_net_mask } + pcrf_rx_net_name: { get_param: pcrf_rx_net_name } + pcrf_rx_net_ip: { get_param: [pcrf_rx_net_ips, 2] } + pcrf_rx_net_mask: { get_param: pcrf_rx_net_mask } + pcrf_sd_net_name: { get_param: pcrf_sd_net_name } + pcrf_sd_net_ip: { get_param: [pcrf_sd_net_ips, 2] } + pcrf_sd_net_mask: { get_param: pcrf_sd_net_mask } + pcrf_sgi_sy_net_name: { get_param: pcrf_sgi_sy_net_name } + pcrf_sgi_sy_net_ip: { get_param: [pcrf_sgi_sy_net_ips, 2] } + pcrf_sgi_sy_net_mask: { get_param: pcrf_sgi_sy_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_ppd_004: + type: nested-ppd_v1.0.yaml + properties: + pcrf_ppd_server_name: { get_param: [pcrf_ppd_server_names, 3] } + pcrf_ppd_image_name: { get_param: pcrf_ppd_image_name } + pcrf_ppd_flavor_name: { get_param: pcrf_ppd_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_lb_internal_vip: { get_param: pcrf_lb_internal_vip } + pcrf_oam_net_name: { get_param: pcrf_oam_net_name } + pcrf_oam_net_ip: { get_param: [pcrf_oam_net_ips, 3] } + pcrf_oam_net_mask: { get_param: pcrf_oam_net_mask } + pcrf_oam_net_gw: { get_param: pcrf_oam_net_gw } + pcrf_lb_management_vip: { get_param: pcrf_lb_management_vip } + pcrf_gx_net_name: { get_param: pcrf_gx_net_name } + pcrf_gx_net_ip: { get_param: [pcrf_gx_net_ips, 3] } + pcrf_gx_net_mask: { get_param: pcrf_gx_net_mask } + pcrf_sp_net_name: { get_param: pcrf_sp_net_name } + pcrf_sp_net_ip: { get_param: [pcrf_sp_net_ips, 3] } + pcrf_sp_net_mask: { get_param: pcrf_sp_net_mask } + pcrf_sy_net_name: { get_param: pcrf_sy_net_name } + pcrf_sy_net_ip: { get_param: [pcrf_sy_net_ips, 3] } + pcrf_sy_net_mask: { get_param: pcrf_sy_net_mask } + pcrf_rx_net_name: { get_param: pcrf_rx_net_name } + pcrf_rx_net_ip: { get_param: [pcrf_rx_net_ips, 3] } + pcrf_rx_net_mask: { get_param: pcrf_rx_net_mask } + pcrf_sd_net_name: { get_param: pcrf_sd_net_name } + pcrf_sd_net_ip: { get_param: [pcrf_sd_net_ips, 3] } + pcrf_sd_net_mask: { get_param: pcrf_sd_net_mask } + pcrf_sgi_sy_net_name: { get_param: pcrf_sgi_sy_net_name } + pcrf_sgi_sy_net_ip: { get_param: [pcrf_sgi_sy_net_ips, 3] } + pcrf_sgi_sy_net_mask: { get_param: pcrf_sgi_sy_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-ppd_v1.1.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-ppd_v1.1.env new file mode 100644 index 0000000000..bb6dfe468c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-ppd_v1.1.env @@ -0,0 +1,35 @@ +parameters: + pcrf_ppd_server_names: ZRDM1PCRF01PPD001,ZRDM1PCRF01PPD002,ZRDM1PCRF01PPD003,ZRDM1PCRF01PPD004 + pcrf_ppd_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_ppd_flavor_name: lc.4xlarge4 + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.3,172.26.16.4,172.26.16.5,172.26.16.6 + pcrf_lb_internal_vip: 172.26.16.114 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_oam_net_name: MNS-25180-L-01_oam_protected_net_0 + pcrf_oam_net_ips: 107.239.64.113,107.239.64.114,107.239.64.115,107.239.64.116 + pcrf_lb_management_vip: 107.239.64.123 + pcrf_oam_net_gw: 107.239.64.1 + pcrf_oam_net_mask: 255.255.248.0 + pcrf_gx_net_name: Mobisupport-25193-I-INT1_cor_pcrf_gx_net_0 + pcrf_gx_net_ips: 107.239.24.67,107.239.24.68,107.239.24.69,107.239.24.70 + pcrf_gx_net_mask: 255.255.255.248 + pcrf_sp_net_name: Mobisupport-25193-I-INT1_cor_pcrf_sp_net_0 + pcrf_sp_net_ips: 107.239.24.75,107.239.24.76,107.239.24.77,107.239.24.78 + pcrf_sp_net_mask: 255.255.255.248 + pcrf_sy_net_name: Mobisupport-25193-I-INT1_cor_pcrf_sy_net_0 + pcrf_sy_net_ips: 107.239.24.83,107.239.24.84,107.239.24.85,107.239.24.86 + pcrf_sy_net_mask: 255.255.255.248 + pcrf_rx_net_name: Mobisupport-25193-I-INT1_cor_pcrf_rx_net_0 + pcrf_rx_net_ips: 107.239.24.91,107.239.24.92,107.239.24.93,107.239.24.94 + pcrf_rx_net_mask: 255.255.255.248 + pcrf_sd_net_name: Mobisupport-25193-I-INT1_cor_pcrf_sd_net_0 + pcrf_sd_net_ips: 107.239.24.99,107.239.24.100,107.239.24.101,107.239.24.102 + pcrf_sd_net_mask: 255.255.255.248 + pcrf_sgi_sy_net_name: Mobisupport-25193-I-INT1_sgi_pcrf_sy_net_0 + pcrf_sgi_sy_net_ips: 107.239.26.131,107.239.26.132,107.239.26.133,107.239.26.134 + pcrf_sgi_sy_net_mask: 255.255.255.248 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-pps_v1.0.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-pps_v1.0.env new file mode 100644 index 0000000000..340be2b815 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-pps_v1.0.env @@ -0,0 +1,11 @@ +parameters: + pcrf_pps_server_names: ZRDM1PCRF01PPS001,ZRDM1PCRF01PPS002,ZRDM1PCRF01PPS003,ZRDM1PCRF01PPS004,ZRDM1PCRF01PPS005,ZRDM1PCRF01PPS006 + pcrf_pps_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pps_flavor_name: lc.3xlarge + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.7,172.26.16.8,172.26.16.9,172.26.16.10,172.26.16.11,172.26.16.12 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..05bd6c9318 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,121 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_pps_001: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_002: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 1] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_003: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 2] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_004: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 3] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_005: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 4] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_006: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 5] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-psm_v1.0.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-psm_v1.0.env new file mode 100644 index 0000000000..f24e4763c6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-psm_v1.0.env @@ -0,0 +1,10 @@ +parameters: + pcrf_psm_server_names: ZRDM1PCRF01PSM001,ZRDM1PCRF01PSM002,ZRDM1PCRF01PSM003,ZRDM1PCRF01PSM004,ZRDM1PCRF01PSM005,ZRDM1PCRF01PSM006,ZRDM1PCRF01PSM007,ZRDM1PCRF01PSM008,ZRDM1PCRF01PSM009,ZRDM1PCRF01PSM010,ZRDM1PCRF01PSM011,ZRDM1PCRF01PSM012 + pcrf_psm_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_psm_flavor_name: lc.4xlarge4 + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.63,172.26.16.64,172.26.16.65,172.26.16.66,172.26.16.67,172.26.16.68,172.26.16.69,172.26.16.70,172.26.16.71,172.26.16.72,172.26.16.73,172.26.16.74 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-psm_v1.0.yaml new file mode 100644 index 0000000000..c2d7b05ead --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/hot-nimbus-psm_v1.0.yaml @@ -0,0 +1,199 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_names: + type: comma_delimited_list + label: PCRF SM server names + description: name of the PCRF SM instance + pcrf_psm_image_name: + type: string + label: PCRF SM image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_psm_001: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 0] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_002: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 1] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_003: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 2] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_004: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 3] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_005: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 4] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_006: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 5] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_007: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 6] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 6] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_008: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 7] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 7] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_009: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 8] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 8] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_010: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 9] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 9] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_011: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 10] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 10] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_012: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 11] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 11] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/nested-oam_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/nested-oam_v1.0.yaml new file mode 100644 index 0000000000..a832498a6c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/nested-oam_v1.0.yaml @@ -0,0 +1,156 @@ +heat_template_version: 2013-05-23 + +description: nested heat template that creates a PCRF OAM node stack + +parameters: + pcrf_oam_server_name: + type: string + label: PCRF OAM server name + description: PCRF OAM server name + pcrf_oam_image_name: + type: string + label: image name + description: PCRF OAM image name + pcrf_oam_flavor_name: + type: string + label: PCRF OAM flavor name + description: flavor name of PCRF OAM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_arbiter_vip: + type: string + label: OAM Arbiter LB VIP + description: OAM Arbiter LB VIP + pcrf_oam_net_name: + type: string + label: OAM network name + description: OAM network name + pcrf_oam_net_ip: + type: string + label: OAM network ip + description: OAM network ip + pcrf_oam_net_gw: + type: string + label: CPS network gateway + description: CPS network gateway + pcrf_oam_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_oam_volume_id: + type: string + label: CPS OAM Cinder Volume + description: CPS OAM Cinder Volume + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + template: { get_file: "file:///nimbus-ethernet" } + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + - path: /etc/sysconfig/network-scripts/ifcfg-eth1 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet-gw } + params: + $dev: eth1 + $ip: { get_param: pcrf_oam_net_ip } + $netmask: { get_param: pcrf_oam_net_mask } + $gateway: { get_param: pcrf_oam_net_gw } + runcmd: + - ifdown eth0 && ifup eth0 + - ifdown eth1 && ifup eth1 + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + template: { get_file: cloud-nimbus.sh } + params: + $vm_name: { get_param: pcrf_oam_server_name } + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_oam: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_oam_server_name } + image: { get_param: pcrf_oam_image_name } + flavor: { get_param: pcrf_oam_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcrf_oam_port_0} + - port: { get_resource: pcrf_oam_port_1} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + + pcrf_oam_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + allowed_address_pairs: + - ip_address: { get_param: pcrf_arbiter_vip } + security_groups: [{ get_param: pcrf_security_group_name }] + + pcrf_oam_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_oam_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_oam_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] + + pcrf_oam_vol_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: { get_param: pcrf_oam_volume_id } + mountpoint: /dev/vdd + instance_uuid: { get_resource: pcrf_server_oam } + +outputs: + pcrf_oam_vol_attachment_id: + description: the pcrf_oam_vol_attachment_id id + value: { get_resource: pcrf_oam_vol_attachment } diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/nested-pcm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/nested-pcm_v1.0.yaml new file mode 100644 index 0000000000..820d09b3dc --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/nested-pcm_v1.0.yaml @@ -0,0 +1,150 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Cluman stack + +parameters: + pcrf_pcm_server_name: + type: string + label: PCRF CM server name + description: PCRF CM server name + pcrf_pcm_image_name: + type: string + label: image name + description: PCRF CM image name + pcrf_pcm_flavor_name: + type: string + label: PCRF CM flavor name + description: flavor name of PCRF CM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_oam_net_name: + type: string + label: OAM network name + description: OAM network name + pcrf_oam_net_ip: + type: string + label: OAM network ip + description: OAM network ip + pcrf_oam_net_gw: + type: string + label: CPS network gateway + description: CPS network gateway + pcrf_oam_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_pcm_volume_id: + type: string + label: CPS Cluman Cinder Volume + description: CPS Cluman Cinder Volume + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet } + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + - path: /etc/sysconfig/network-scripts/ifcfg-eth1 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet-gw } + params: + $dev: eth1 + $ip: { get_param: pcrf_oam_net_ip } + $netmask: { get_param: pcrf_oam_net_mask } + $gateway: { get_param: pcrf_oam_net_gw } + runcmd: + - ifdown eth0 && ifup eth0 + - ifdown eth1 && ifup eth1 + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + template: { get_file: cloud-nimbus.sh } + params: + $vm_name: { get_param: pcrf_pcm_server_name } + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_pcm: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_pcm_server_name } + image: { get_param: pcrf_pcm_image_name } + flavor: { get_param: pcrf_pcm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcrf_pcm_port_0} + - port: { get_resource: pcrf_pcm_port_1} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + + pcrf_pcm_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] + + pcrf_pcm_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_oam_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_oam_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] + + volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: { get_param: pcrf_pcm_volume_id } + mountpoint: /dev/vdd + instance_uuid: { get_resource: pcrf_server_pcm } + +outputs: + pcrf_server_pcm_id: + description: the pcm server id + value: { get_resource: pcrf_server_pcm } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/nested-ppd_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/nested-ppd_v1.0.yaml new file mode 100644 index 0000000000..397e85c252 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/nested-ppd_v1.0.yaml @@ -0,0 +1,333 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Director stack + +parameters: + pcrf_ppd_server_name: + type: string + label: PCRF PD server name + description: PCRF PD server name + pcrf_ppd_image_name: + type: string + label: image name + description: PCRF PD image name + pcrf_ppd_flavor_name: + type: string + label: PCRF PD flavor name + description: flavor name of PCRF PD instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_lb_internal_vip: + type: string + label: CPS Internal LB VIP + description: CPS Internal LB VIP + pcrf_oam_net_name: + type: string + label: OAM network name + description: OAM network name + pcrf_oam_net_ip: + type: string + label: OAM network ip + description: OAM network ip + pcrf_oam_net_gw: + type: string + label: CPS network gateway + description: CPS network gateway + pcrf_oam_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_lb_management_vip: + type: string + label: CPS OAM LB VIP + description: CPS OAM LB VIP + pcrf_gx_net_name: + type: string + label: Gx network name + description: Gx network name + pcrf_gx_net_ip: + type: string + label: Gx network ip + description: Gx network ip + pcrf_gx_net_mask: + type: string + label: Gx network mask + description: Gx network mask + pcrf_sp_net_name: + type: string + label: Sp network name + description: Sp network name + pcrf_sp_net_ip: + type: string + label: Sp network ip + description: Sp network ip + pcrf_sp_net_mask: + type: string + label: Sp network mask + description: Sp network mask + pcrf_sy_net_name: + type: string + label: Sy network name + description: Sy network name + pcrf_sy_net_ip: + type: string + label: Sy network ip + description: Sy network ip + pcrf_sy_net_mask: + type: string + label: Sy network mask + description: Sy network mask + pcrf_rx_net_name: + type: string + label: Rx network name + description: Rx network name + pcrf_rx_net_ip: + type: string + label: Rx network ip + description: Rx network ip + pcrf_rx_net_mask: + type: string + label: Rx network mask + description: Rx network mask + pcrf_sd_net_name: + type: string + label: Sd network name + description: Sd network name + pcrf_sd_net_ip: + type: string + label: Sd network ip + description: Sd network ip + pcrf_sd_net_mask: + type: string + label: Sd network mask + description: Sd network mask + pcrf_sgi_sy_net_name: + type: string + label: Sgi Sy network name + description: Sgi Sy network name + pcrf_sgi_sy_net_ip: + type: string + label: Sgi Sy network ip + description: Sgi Sy network ip + pcrf_sgi_sy_net_mask: + type: string + label: Sgi Sy network mask + description: Sgi Sy network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet } + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + - path: /etc/sysconfig/network-scripts/ifcfg-eth1 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet-gw } + params: + $dev: eth1 + $ip: { get_param: pcrf_oam_net_ip } + $netmask: { get_param: pcrf_oam_net_mask } + $gateway: { get_param: pcrf_oam_net_gw } + - path: /etc/sysconfig/network-scripts/ifcfg-eth2 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet } + params: + $dev: eth2 + $ip: { get_param: pcrf_gx_net_ip } + $netmask: { get_param: pcrf_gx_net_mask } + - path: /etc/sysconfig/network-scripts/ifcfg-eth3 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet } + params: + $dev: eth3 + $ip: { get_param: pcrf_sp_net_ip } + $netmask: { get_param: pcrf_sp_net_mask } + - path: /etc/sysconfig/network-scripts/ifcfg-eth4 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet } + params: + $dev: eth4 + $ip: { get_param: pcrf_sy_net_ip } + $netmask: { get_param: pcrf_sy_net_mask } + - path: /etc/sysconfig/network-scripts/ifcfg-eth5 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet } + params: + $dev: eth5 + $ip: { get_param: pcrf_rx_net_ip } + $netmask: { get_param: pcrf_rx_net_mask } + - path: /etc/sysconfig/network-scripts/ifcfg-eth6 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet } + params: + $dev: eth6 + $ip: { get_param: pcrf_sd_net_ip } + $netmask: { get_param: pcrf_sd_net_mask } + - path: /etc/sysconfig/network-scripts/ifcfg-eth7 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet } + params: + $dev: eth7 + $ip: { get_param: pcrf_sgi_sy_net_ip } + $netmask: { get_param: pcrf_sgi_sy_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + - ifdown eth1 && ifup eth1 + - ifdown eth2 && ifup eth2 + - ifdown eth3 && ifup eth3 + - ifdown eth4 && ifup eth4 + - ifdown eth5 && ifup eth5 + - ifdown eth6 && ifup eth6 + - ifdown eth7 && ifup eth7 + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + template: { get_file: cloud-nimbus.sh } + params: + $vm_name: { get_param: pcrf_ppd_server_name } + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_ppd: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_ppd_server_name } + image: { get_param: pcrf_ppd_image_name } + flavor: { get_param: pcrf_ppd_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcrf_ppd_port_0} + - port: { get_resource: pcrf_ppd_port_1} + - port: { get_resource: pcrf_ppd_port_2} + - port: { get_resource: pcrf_ppd_port_3} + - port: { get_resource: pcrf_ppd_port_4} + - port: { get_resource: pcrf_ppd_port_5} + - port: { get_resource: pcrf_ppd_port_6} + - port: { get_resource: pcrf_ppd_port_7} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + + pcrf_ppd_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] + allowed_address_pairs: + - ip_address: { get_param: pcrf_lb_internal_vip } + + pcrf_ppd_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_oam_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_oam_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] + allowed_address_pairs: + - ip_address: { get_param: pcrf_lb_management_vip } + + pcrf_ppd_port_2: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_gx_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_gx_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] + + pcrf_ppd_port_3: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_sp_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_sp_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] + + pcrf_ppd_port_4: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_sy_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_sy_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] + + pcrf_ppd_port_5: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_rx_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_rx_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] + + pcrf_ppd_port_6: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_sd_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_sd_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] + + pcrf_ppd_port_7: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_sgi_sy_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_sgi_sy_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/nested-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/nested-pps_v1.0.yaml new file mode 100644 index 0000000000..fc5b6f74c3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/nested-pps_v1.0.yaml @@ -0,0 +1,99 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_name: + type: string + label: PCRF PS server name + description: PCRF PS server name + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + template: { get_file: cloud-nimbus.sh } + params: + $vm_name: { get_param: pcrf_pps_server_name } + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet } + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_pps: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_pps_server_name } + image: { get_param: pcrf_pps_image_name } + flavor: { get_param: pcrf_pps_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcrf_pps_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + + pcrf_pps_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/nested-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/nested-psm_v1.0.yaml new file mode 100644 index 0000000000..c86aa34713 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/nested-psm_v1.0.yaml @@ -0,0 +1,99 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_name: + type: string + label: PCRF SM server name + description: PCRF SM server name + pcrf_psm_image_name: + type: string + label: image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet } + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + template: { get_file: cloud-nimbus.sh } + params: + $vm_name: { get_param: pcrf_psm_server_name } + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_psm: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_psm_server_name } + image: { get_param: pcrf_psm_image_name } + flavor: { get_param: pcrf_psm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: psm01_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + #scheduler_hints: {group: { get_resource: servergroup_nimbus }} + + psm01_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/nimbus-ethernet b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/nimbus-ethernet new file mode 100644 index 0000000000..51250a7b82 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/nimbus-ethernet @@ -0,0 +1,5 @@ +DEVICE=$dev +BOOTPROTO=none +NM_CONTROLLED=no +IPADDR=$ip +NETMASK=$netmask diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/nimbus-ethernet-gw b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/nimbus-ethernet-gw new file mode 100644 index 0000000000..3e08d643bb --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/inputfiles/nimbus-ethernet-gw @@ -0,0 +1,6 @@ +DEVICE=$dev +BOOTPROTO=none +NM_CONTROLLED=no +IPADDR=$ip +NETMASK=$netmask +GATEWAY=$gateway diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/out/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/out/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..e04c27f8fc --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/out/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,642 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.nested-pps_v1.0: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + pcrf_cps_net_ip: + type: string + description: CPS network ip + availabilityzone_name: + type: string + description: availabilityzone name + pcrf_vnf_id: + type: string + description: PCRF VNF Id + pcrf_cps_net_name: + type: string + description: CPS network name + pcrf_cps_net_mask: + type: string + description: CPS network mask + pcrf_pps_image_name: + type: string + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + description: flavor name of PCRF PS instance + pcrf_pps_server_name: + type: string + description: PCRF PS server name + pcrf_security_group_name: + type: string + description: the name of security group + requirements: + - link_pcrf_pps_port_0: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - local_storage_pcrf_server_pps: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + capabilities: + binding_pcrf_server_pps: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + attachment_pcrf_pps_port_0: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + scalable_pcrf_server_pps: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + os_pcrf_server_pps: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + endpoint_pcrf_server_pps: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + host_pcrf_server_pps: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + org.openecomp.resource.abstract.nodes.heat.nested-ppd_v1.0: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + pcrf_ppd_image_name: + type: string + description: PCRF PD image name + availabilityzone_name: + type: string + description: availabilityzone name + pcrf_sp_net_ip: + type: string + description: Sp network ip + pcrf_ppd_server_name: + type: string + description: PCRF PD server name + pcrf_gx_net_ip: + type: string + description: Gx network ip + pcrf_sy_net_name: + type: string + description: Sy network name + pcrf_sp_net_mask: + type: string + description: Sp network mask + pcrf_sd_net_ip: + type: string + description: Sd network ip + pcrf_vnf_id: + type: string + description: PCRF VNF Id + pcrf_oam_net_name: + type: string + description: OAM network name + pcrf_oam_net_ip: + type: string + description: OAM network ip + pcrf_cps_net_mask: + type: string + description: CPS network mask + pcrf_gx_net_mask: + type: string + description: Gx network mask + pcrf_sgi_sy_net_name: + type: string + description: Sgi Sy network name + pcrf_sd_net_name: + type: string + description: Sd network name + pcrf_oam_net_gw: + type: string + description: CPS network gateway + pcrf_rx_net_name: + type: string + description: Rx network name + pcrf_rx_net_ip: + type: string + description: Rx network ip + pcrf_sy_net_ip: + type: string + description: Sy network ip + pcrf_sgi_sy_net_ip: + type: string + description: Sgi Sy network ip + pcrf_ppd_flavor_name: + type: string + description: flavor name of PCRF PD instance + pcrf_cps_net_ip: + type: string + description: CPS network ip + pcrf_sy_net_mask: + type: string + description: Sy network mask + pcrf_cps_net_name: + type: string + description: CPS network name + pcrf_oam_net_mask: + type: string + description: CPS network mask + pcrf_lb_management_vip: + type: string + description: CPS OAM LB VIP + pcrf_sgi_sy_net_mask: + type: string + description: Sgi Sy network mask + pcrf_lb_internal_vip: + type: string + description: CPS Internal LB VIP + pcrf_sd_net_mask: + type: string + description: Sd network mask + pcrf_gx_net_name: + type: string + description: Gx network name + pcrf_sp_net_name: + type: string + description: Sp network name + pcrf_rx_net_mask: + type: string + description: Rx network mask + pcrf_security_group_name: + type: string + description: the name of security group + requirements: + - link_pcrf_ppd_port_5: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_pcrf_ppd_port_6: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_pcrf_ppd_port_3: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - local_storage_pcrf_server_ppd: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_pcrf_ppd_port_4: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_pcrf_ppd_port_7: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_pcrf_ppd_port_1: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_pcrf_ppd_port_2: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_pcrf_ppd_port_0: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + attachment_pcrf_ppd_port_1: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + attachment_pcrf_ppd_port_2: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + binding_pcrf_server_ppd: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + attachment_pcrf_ppd_port_0: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + attachment_pcrf_ppd_port_5: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + attachment_pcrf_ppd_port_6: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + attachment_pcrf_ppd_port_3: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + os_pcrf_server_ppd: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + attachment_pcrf_ppd_port_4: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + endpoint_pcrf_server_ppd: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + scalable_pcrf_server_ppd: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + attachment_pcrf_ppd_port_7: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + host_pcrf_server_ppd: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + org.openecomp.resource.abstract.nodes.heat.nested-pcm_v1.0: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + pcrf_pcm_flavor_name: + type: string + description: flavor name of PCRF CM instance + availabilityzone_name: + type: string + description: availabilityzone name + pcrf_cps_net_ip: + type: string + description: CPS network ip + pcrf_pcm_image_name: + type: string + description: PCRF CM image name + pcrf_vnf_id: + type: string + description: PCRF VNF Id + pcrf_oam_net_name: + type: string + description: OAM network name + pcrf_cps_net_name: + type: string + description: CPS network name + pcrf_oam_net_ip: + type: string + description: OAM network ip + pcrf_oam_net_mask: + type: string + description: CPS network mask + pcrf_cps_net_mask: + type: string + description: CPS network mask + pcrf_pcm_server_name: + type: string + description: PCRF CM server name + pcrf_oam_net_gw: + type: string + description: CPS network gateway + pcrf_pcm_volume_id: + type: string + description: CPS Cluman Cinder Volume + pcrf_security_group_name: + type: string + description: the name of security group + attributes: + pcrf_server_pcm_id: + type: string + description: the pcm server id + requirements: + - link_pcrf_pcm_port_0: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - local_storage_pcrf_server_pcm: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_pcrf_pcm_port_1: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + endpoint_pcrf_server_pcm: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + attachment_pcrf_pcm_port_0: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + binding_pcrf_server_pcm: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + os_pcrf_server_pcm: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + host_pcrf_server_pcm: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + scalable_pcrf_server_pcm: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + attachment_pcrf_pcm_port_1: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + org.openecomp.resource.abstract.nodes.heat.nested-oam_v1.0: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + availabilityzone_name: + type: string + description: availabilityzone name + pcrf_oam_flavor_name: + type: string + description: flavor name of PCRF OAM instance + pcrf_oam_server_name: + type: string + description: PCRF OAM server name + pcrf_cps_net_ip: + type: string + description: CPS network ip + pcrf_vnf_id: + type: string + description: PCRF VNF Id + pcrf_oam_net_name: + type: string + description: OAM network name + pcrf_cps_net_name: + type: string + description: CPS network name + pcrf_arbiter_vip: + type: string + description: OAM Arbiter LB VIP + pcrf_oam_net_ip: + type: string + description: OAM network ip + pcrf_oam_net_mask: + type: string + description: CPS network mask + pcrf_cps_net_mask: + type: string + description: CPS network mask + pcrf_oam_volume_id: + type: string + description: CPS OAM Cinder Volume + pcrf_oam_net_gw: + type: string + description: CPS network gateway + pcrf_oam_image_name: + type: string + description: PCRF OAM image name + pcrf_security_group_name: + type: string + description: the name of security group + attributes: + pcrf_oam_vol_attachment_id: + type: string + description: the pcrf_oam_vol_attachment_id id + requirements: + - local_storage_pcrf_server_oam: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_pcrf_oam_port_1: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_pcrf_oam_port_0: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + endpoint_pcrf_server_oam: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + host_pcrf_server_oam: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + binding_pcrf_server_oam: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + attachment_pcrf_oam_port_1: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + attachment_pcrf_oam_port_0: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + scalable_pcrf_server_oam: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + os_pcrf_server_oam: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + org.openecomp.resource.abstract.nodes.heat.nested-psm_v1.0: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + pcrf_cps_net_ip: + type: string + description: CPS network ip + pcrf_psm_flavor_name: + type: string + description: flavor name of PCRF SM instance + pcrf_psm_image_name: + type: string + description: PCRF SM image name + availabilityzone_name: + type: string + description: availabilityzone name + pcrf_vnf_id: + type: string + description: PCRF VNF Id + pcrf_cps_net_name: + type: string + description: CPS network name + pcrf_cps_net_mask: + type: string + description: CPS network mask + pcrf_psm_server_name: + type: string + description: PCRF SM server name + pcrf_security_group_name: + type: string + description: the name of security group + requirements: + - local_storage_pcrf_server_psm: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_psm01_port_0: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + endpoint_pcrf_server_psm: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + binding_pcrf_server_psm: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + os_pcrf_server_psm: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + attachment_psm01_port_0: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + host_pcrf_server_psm: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + scalable_pcrf_server_psm: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/out/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/out/MainServiceTemplate.yaml new file mode 100644 index 0000000000..d6c309eb24 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/out/MainServiceTemplate.yaml @@ -0,0 +1,1646 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + availabilityzone_name: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + default: nova + pcrf_sgi_sy_net_ips: + label: Sgi Sy network ips + hidden: false + immutable: false + type: list + description: Sgi Sy network ips + default: + - 107.239.26.131 + - 107.239.26.132 + - 107.239.26.133 + - 107.239.26.134 + entry_schema: + type: string + pcrf_ppd_server_names: + label: PCRF PD server names + hidden: false + immutable: false + type: list + description: name of the PCRF PD instance + default: + - ZRDM1PCRF01PPD001 + - ZRDM1PCRF01PPD002 + - ZRDM1PCRF01PPD003 + - ZRDM1PCRF01PPD004 + entry_schema: + type: string + pcrf_oam_vol_size: + label: Cinder volume size + hidden: false + immutable: false + type: float + description: the size of the Cinder volume + default: 500 + pcrf_oam_vol_name_2: + label: OAM volume name 2 + hidden: false + immutable: false + type: string + description: Assigning name to volume + default: sde1-pcrfx01-oam001-vol-2 + pcrf_pps_flavor_name: + label: PCRF PS flavor name + hidden: false + immutable: false + type: string + description: flavor name of PCRF PS instance + default: lc.3xlarge + pcrf_psm_server_names: + label: PCRF SM server names + hidden: false + immutable: false + type: list + description: name of the PCRF SM instance + default: + - ZRDM1PCRF01PSM001 + - ZRDM1PCRF01PSM002 + - ZRDM1PCRF01PSM003 + - ZRDM1PCRF01PSM004 + - ZRDM1PCRF01PSM005 + - ZRDM1PCRF01PSM006 + - ZRDM1PCRF01PSM007 + - ZRDM1PCRF01PSM008 + - ZRDM1PCRF01PSM009 + - ZRDM1PCRF01PSM010 + - ZRDM1PCRF01PSM011 + - ZRDM1PCRF01PSM012 + entry_schema: + type: string + pcrf_oam_vol_name_1: + label: OAM volume name 1 + hidden: false + immutable: false + type: string + description: Assigning name to volume + default: sde1-pcrfx01-oam001-vol-1 + pcrf_sy_net_name: + label: Sy network name + hidden: false + immutable: false + type: string + description: Sy network name + default: Mobisupport-25193-I-INT1_cor_pcrf_sy_net_0 + pcrf_pcm_vol_size: + label: Cinder volume size + hidden: false + immutable: false + type: float + description: the size of the Cinder volume + default: 50 + pcrf_vnf_id: + label: PCRF VNF Id + hidden: false + immutable: false + type: string + description: PCRF VNF Id + default: 730797234b4a40aa99335157b02871cd + pcrf_pcm_image_name: + label: PCRF CM image name + hidden: false + immutable: false + type: string + description: PCRF CM image name + default: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_oam_net_name: + label: OAM network name + hidden: false + immutable: false + type: string + description: OAM network name + default: MNS-25180-L-01_oam_protected_net_0 + pcrf_sd_net_ips: + label: Sd network ips + hidden: false + immutable: false + type: list + description: Sd network ips + default: + - 107.239.24.99 + - 107.239.24.100 + - 107.239.24.101 + - 107.239.24.102 + entry_schema: + type: string + pcrf_sp_net_ips: + label: Sp network ips + hidden: false + immutable: false + type: list + description: Sp network ips + default: + - 107.239.24.75 + - 107.239.24.76 + - 107.239.24.77 + - 107.239.24.78 + entry_schema: + type: string + pcrf_cps_net_mask: + label: CPS network mask + hidden: false + immutable: false + type: string + description: CPS network mask + default: 255.255.255.0 + pcrf_pcm_volume_silver: + label: vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend for PCM + default: Silver + pcrf_rx_net_ips: + label: Rx network ips + hidden: false + immutable: false + type: list + description: Rx network ips + default: + - 107.239.24.91 + - 107.239.24.92 + - 107.239.24.93 + - 107.239.24.94 + entry_schema: + type: string + pcrf_sgi_sy_net_name: + label: Sgi Sy network name + hidden: false + immutable: false + type: string + description: Sgi Sy network name + default: Mobisupport-25193-I-INT1_sgi_pcrf_sy_net_0 + pcrf_sd_net_name: + label: Sd network name + hidden: false + immutable: false + type: string + description: Sd network name + default: Mobisupport-25193-I-INT1_cor_pcrf_sd_net_0 + pcrf_pcm_volume_id_1: + label: CPS Cluman Cinder Volume + hidden: false + immutable: false + type: string + description: CPS Cluman Cinder Volume + default: 3438a3fe-1241-4390-80f2-d0b86238c40e + pcrf_oam_volume_silver-2: + label: vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend for OAM2 + default: Silver + pcrf_oam_volume_silver-1: + label: vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend for OAM1 + default: Silver + pcrf_oam_flavor_name: + label: PCRF OAM flavor name + hidden: false + immutable: false + type: string + description: flavor name of PCRF OAM instance + default: lc.4xlarge4 + pcrf_pcm_server_names: + label: PCRF CM server names + hidden: false + immutable: false + type: list + description: name of the PCRF CM instance + default: + - ZRDM1PCRF01PCM001 + entry_schema: + type: string + pcrf_cps_net_name: + label: CPS network name + hidden: false + immutable: false + type: string + description: CPS network name + default: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_oam_net_mask: + label: CPS network mask + hidden: false + immutable: false + type: string + description: CPS network mask + default: 255.255.248.0 + pcrf_sgi_sy_net_mask: + label: Sgi Sy network mask + hidden: false + immutable: false + type: string + description: Sgi Sy network mask + default: 255.255.255.248 + pcrf_pps_image_name: + label: PCRF PS image name + hidden: false + immutable: false + type: string + description: PCRF PS image name + default: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_lb_internal_vip: + label: CPS Internal LB VIP + hidden: false + immutable: false + type: string + description: CPS Internal LB VIP + default: 172.26.16.114 + pcrf_pcm_flavor_name: + label: PCRF CM flavor name + hidden: false + immutable: false + type: string + description: flavor name of PCRF CM instance + default: lc.2xlarge4 + pcrf_ppd_image_name: + label: PCRF PD image name + hidden: false + immutable: false + type: string + description: PCRF PD image name + default: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pcm_vol_name_1: + label: PCM volume name + hidden: false + immutable: false + type: string + description: Assigning name to volume + default: sde1-pcrfx01-pcm001-vol-1 + pcrf_sp_net_mask: + label: Sp network mask + hidden: false + immutable: false + type: string + description: Sp network mask + default: 255.255.255.248 + pcrf_psm_flavor_name: + label: PCRF SM flavor name + hidden: false + immutable: false + type: string + description: flavor name of PCRF SM instance + default: lc.4xlarge4 + pcrf_psm_image_name: + label: PCRF SM image name + hidden: false + immutable: false + type: string + description: PCRF SM image name + default: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_oam_net_ips: + label: OAM network ips + hidden: false + immutable: false + type: list + description: OAM network ips + default: + - 107.239.64.121 + entry_schema: + type: string + pcrf_gx_net_mask: + label: Gx network mask + hidden: false + immutable: false + type: string + description: Gx network mask + default: 255.255.255.248 + pcrf_oam_net_gw: + label: CPS network gateway + hidden: false + immutable: false + type: string + description: CPS network gateway + default: 107.239.64.1 + pcrf_gx_net_ips: + label: Gx network ips + hidden: false + immutable: false + type: list + description: Gx network ips + default: + - 107.239.24.67 + - 107.239.24.68 + - 107.239.24.69 + - 107.239.24.70 + entry_schema: + type: string + pcrf_rx_net_name: + label: Rx network name + hidden: false + immutable: false + type: string + description: Rx network name + default: Mobisupport-25193-I-INT1_cor_pcrf_rx_net_0 + pcrf_oam_image_name: + label: PCRF OAM image name + hidden: false + immutable: false + type: string + description: PCRF OAM image name + default: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_cps_net_ips: + label: CPS network ips + hidden: false + immutable: false + type: list + description: CPS network ips + default: + - 172.26.16.113 + entry_schema: + type: string + pcrf_oam_volume_id_1: + label: CPS OAM 001 Cinder Volume + hidden: false + immutable: false + type: string + description: CPS OAM 001 Cinder Volumes + default: a4aa05fb-fcdc-457b-8077-6845fdfc3257 + pcrf_oam_volume_id_2: + label: CPS OAM 002 Cinder Volume + hidden: false + immutable: false + type: string + description: CPS OAM 002 Cinder Volumes + default: 93d8fc1f-f1c3-4933-86b2-039881ee910f + pcrf_pps_server_names: + label: PCRF PS server names + hidden: false + immutable: false + type: list + description: PCRF PS server names + default: + - ZRDM1PCRF01PPS001 + - ZRDM1PCRF01PPS002 + - ZRDM1PCRF01PPS003 + - ZRDM1PCRF01PPS004 + - ZRDM1PCRF01PPS005 + - ZRDM1PCRF01PPS006 + entry_schema: + type: string + pcrf_ppd_flavor_name: + label: PCRF PD flavor name + hidden: false + immutable: false + type: string + description: flavor name of PCRF PD instance + default: lc.4xlarge4 + pcrf_sy_net_mask: + label: Sy network mask + hidden: false + immutable: false + type: string + description: Sy network mask + default: 255.255.255.248 + pcrf_arbiter_vip: + label: OAM Arbiter LB VIP + hidden: false + immutable: false + type: string + description: OAM Arbiter LB VIP + default: 172.26.16.115 + pcrf_lb_management_vip: + label: CPS OAM LB VIP + hidden: false + immutable: false + type: string + description: CPS OAM LB VIP + default: 107.239.64.123 + pcrf_sy_net_ips: + label: Sy network ips + hidden: false + immutable: false + type: list + description: Sy network ips + default: + - 107.239.24.83 + - 107.239.24.84 + - 107.239.24.85 + - 107.239.24.86 + entry_schema: + type: string + pcrf_sd_net_mask: + label: Sd network mask + hidden: false + immutable: false + type: string + description: Sd network mask + default: 255.255.255.248 + pcrf_gx_net_name: + label: Gx network name + hidden: false + immutable: false + type: string + description: Gx network name + default: Mobisupport-25193-I-INT1_cor_pcrf_gx_net_0 + pcrf_sp_net_name: + label: Sp network name + hidden: false + immutable: false + type: string + description: Sp network name + default: Mobisupport-25193-I-INT1_cor_pcrf_sp_net_0 + pcrf_oam_server_names: + label: PCRF OAM server names + hidden: false + immutable: false + type: list + description: name of the PCRF OAM instance + default: + - ZRDM1PCRF01OAM001 + - ZRDM1PCRF01OAM002 + entry_schema: + type: string + pcrf_security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + default: nimbus_security_group + pcrf_rx_net_mask: + label: Rx network mask + hidden: false + immutable: false + type: string + description: Rx network mask + default: 255.255.255.248 + node_templates: + server_pcrf_psm_012: + type: org.openecomp.resource.abstract.nodes.heat.nested-psm_v1.0 + directives: + - substitutable + properties: + pcrf_cps_net_ip: + get_input: + - pcrf_cps_net_ips + - 11 + service_template_filter: + substitute_service_template: nested-psm_v1.0ServiceTemplate.yaml + pcrf_psm_flavor_name: + get_input: pcrf_psm_flavor_name + pcrf_psm_image_name: + get_input: pcrf_psm_image_name + availabilityzone_name: + get_input: availabilityzone_name + pcrf_vnf_id: + get_input: pcrf_vnf_id + pcrf_cps_net_name: + get_input: pcrf_cps_net_name + pcrf_cps_net_mask: + get_input: pcrf_cps_net_mask + pcrf_psm_server_name: + get_input: + - pcrf_psm_server_names + - 11 + pcrf_security_group_name: + get_input: pcrf_security_group_name + server_pcrf_pcm_001: + type: org.openecomp.resource.abstract.nodes.heat.nested-pcm_v1.0 + directives: + - substitutable + properties: + pcrf_pcm_flavor_name: + get_input: pcrf_pcm_flavor_name + availabilityzone_name: + get_input: availabilityzone_name + pcrf_cps_net_ip: + get_input: + - pcrf_cps_net_ips + - 0 + service_template_filter: + substitute_service_template: nested-pcm_v1.0ServiceTemplate.yaml + pcrf_pcm_image_name: + get_input: pcrf_pcm_image_name + pcrf_vnf_id: + get_input: pcrf_vnf_id + pcrf_oam_net_name: + get_input: pcrf_oam_net_name + pcrf_cps_net_name: + get_input: pcrf_cps_net_name + pcrf_oam_net_ip: + get_input: + - pcrf_oam_net_ips + - 0 + pcrf_oam_net_mask: + get_input: pcrf_oam_net_mask + pcrf_cps_net_mask: + get_input: pcrf_cps_net_mask + pcrf_pcm_server_name: + get_input: + - pcrf_pcm_server_names + - 0 + pcrf_pcm_volume_id: + get_input: pcrf_pcm_volume_id_1 + pcrf_oam_net_gw: + get_input: pcrf_oam_net_gw + pcrf_security_group_name: + get_input: pcrf_security_group_name + requirements: + - local_storage_pcrf_server_pcm: + capability: tosca.capabilities.Attachment + node: pcrf_pcm_volume_id_1 + relationship: tosca.relationships.AttachesTo + pcrf_oam_volume_id_11: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: pcrf_oam_volume_silver-1 + size: '(get_input : pcrf_oam_vol_size) * 1024' + name: + get_input: pcrf_oam_vol_name_1 + server_pcrf_oam_001: + type: org.openecomp.resource.abstract.nodes.heat.nested-oam_v1.0 + directives: + - substitutable + properties: + availabilityzone_name: + get_input: availabilityzone_name + pcrf_oam_flavor_name: + get_input: pcrf_oam_flavor_name + pcrf_oam_server_name: + get_input: + - pcrf_oam_server_names + - 0 + pcrf_cps_net_ip: + get_input: + - pcrf_cps_net_ips + - 0 + service_template_filter: + substitute_service_template: nested-oam_v1.0ServiceTemplate.yaml + pcrf_vnf_id: + get_input: pcrf_vnf_id + pcrf_oam_net_name: + get_input: pcrf_oam_net_name + pcrf_cps_net_name: + get_input: pcrf_cps_net_name + pcrf_oam_net_ip: + get_input: + - pcrf_oam_net_ips + - 0 + pcrf_oam_net_mask: + get_input: pcrf_oam_net_mask + pcrf_arbiter_vip: + get_input: pcrf_arbiter_vip + pcrf_cps_net_mask: + get_input: pcrf_cps_net_mask + pcrf_oam_volume_id: + get_input: pcrf_oam_volume_id_1 + pcrf_oam_net_gw: + get_input: pcrf_oam_net_gw + pcrf_oam_image_name: + get_input: pcrf_oam_image_name + pcrf_security_group_name: + get_input: pcrf_security_group_name + requirements: + - local_storage_pcrf_server_oam: + capability: tosca.capabilities.Attachment + node: pcrf_oam_volume_id_11 + relationship: tosca.relationships.AttachesTo + server_pcrf_oam_002: + type: org.openecomp.resource.abstract.nodes.heat.nested-oam_v1.0 + directives: + - substitutable + properties: + availabilityzone_name: + get_input: availabilityzone_name + pcrf_oam_flavor_name: + get_input: pcrf_oam_flavor_name + pcrf_oam_server_name: + get_input: + - pcrf_oam_server_names + - 1 + pcrf_cps_net_ip: + get_input: + - pcrf_cps_net_ips + - 1 + service_template_filter: + substitute_service_template: nested-oam_v1.0ServiceTemplate.yaml + pcrf_vnf_id: + get_input: pcrf_vnf_id + pcrf_oam_net_name: + get_input: pcrf_oam_net_name + pcrf_cps_net_name: + get_input: pcrf_cps_net_name + pcrf_oam_net_ip: + get_input: + - pcrf_oam_net_ips + - 1 + pcrf_oam_net_mask: + get_input: pcrf_oam_net_mask + pcrf_arbiter_vip: + get_input: pcrf_arbiter_vip + pcrf_cps_net_mask: + get_input: pcrf_cps_net_mask + pcrf_oam_volume_id: + get_input: pcrf_oam_volume_id_2 + pcrf_oam_net_gw: + get_input: pcrf_oam_net_gw + pcrf_oam_image_name: + get_input: pcrf_oam_image_name + pcrf_security_group_name: + get_input: pcrf_security_group_name + requirements: + - local_storage_pcrf_server_oam: + capability: tosca.capabilities.Attachment + node: pcrf_oam_volume_id_22 + relationship: tosca.relationships.AttachesTo + - dependency: + capability: tosca.capabilities.Node + node: server_pcrf_oam_001 + relationship: tosca.relationships.DependsOn + server_pcrf_ppd_003: + type: org.openecomp.resource.abstract.nodes.heat.nested-ppd_v1.0 + directives: + - substitutable + properties: + pcrf_ppd_image_name: + get_input: pcrf_ppd_image_name + availabilityzone_name: + get_input: availabilityzone_name + pcrf_sp_net_ip: + get_input: + - pcrf_sp_net_ips + - 2 + pcrf_ppd_server_name: + get_input: + - pcrf_ppd_server_names + - 2 + pcrf_gx_net_ip: + get_input: + - pcrf_gx_net_ips + - 2 + pcrf_sy_net_name: + get_input: pcrf_sy_net_name + pcrf_sp_net_mask: + get_input: pcrf_sp_net_mask + service_template_filter: + substitute_service_template: nested-ppd_v1.0ServiceTemplate.yaml + pcrf_sd_net_ip: + get_input: + - pcrf_sd_net_ips + - 2 + pcrf_vnf_id: + get_input: pcrf_vnf_id + pcrf_oam_net_name: + get_input: pcrf_oam_net_name + pcrf_oam_net_ip: + get_input: + - pcrf_oam_net_ips + - 2 + pcrf_cps_net_mask: + get_input: pcrf_cps_net_mask + pcrf_gx_net_mask: + get_input: pcrf_gx_net_mask + pcrf_sgi_sy_net_name: + get_input: pcrf_sgi_sy_net_name + pcrf_sd_net_name: + get_input: pcrf_sd_net_name + pcrf_oam_net_gw: + get_input: pcrf_oam_net_gw + pcrf_rx_net_name: + get_input: pcrf_rx_net_name + pcrf_rx_net_ip: + get_input: + - pcrf_rx_net_ips + - 2 + pcrf_sy_net_ip: + get_input: + - pcrf_sy_net_ips + - 2 + pcrf_sgi_sy_net_ip: + get_input: + - pcrf_sgi_sy_net_ips + - 2 + pcrf_ppd_flavor_name: + get_input: pcrf_ppd_flavor_name + pcrf_cps_net_ip: + get_input: + - pcrf_cps_net_ips + - 2 + pcrf_sy_net_mask: + get_input: pcrf_sy_net_mask + pcrf_cps_net_name: + get_input: pcrf_cps_net_name + pcrf_oam_net_mask: + get_input: pcrf_oam_net_mask + pcrf_lb_management_vip: + get_input: pcrf_lb_management_vip + pcrf_sgi_sy_net_mask: + get_input: pcrf_sgi_sy_net_mask + pcrf_lb_internal_vip: + get_input: pcrf_lb_internal_vip + pcrf_sd_net_mask: + get_input: pcrf_sd_net_mask + pcrf_gx_net_name: + get_input: pcrf_gx_net_name + pcrf_sp_net_name: + get_input: pcrf_sp_net_name + pcrf_security_group_name: + get_input: pcrf_security_group_name + pcrf_rx_net_mask: + get_input: pcrf_rx_net_mask + server_pcrf_ppd_004: + type: org.openecomp.resource.abstract.nodes.heat.nested-ppd_v1.0 + directives: + - substitutable + properties: + pcrf_ppd_image_name: + get_input: pcrf_ppd_image_name + availabilityzone_name: + get_input: availabilityzone_name + pcrf_sp_net_ip: + get_input: + - pcrf_sp_net_ips + - 3 + pcrf_ppd_server_name: + get_input: + - pcrf_ppd_server_names + - 3 + pcrf_gx_net_ip: + get_input: + - pcrf_gx_net_ips + - 3 + pcrf_sy_net_name: + get_input: pcrf_sy_net_name + pcrf_sp_net_mask: + get_input: pcrf_sp_net_mask + service_template_filter: + substitute_service_template: nested-ppd_v1.0ServiceTemplate.yaml + pcrf_sd_net_ip: + get_input: + - pcrf_sd_net_ips + - 3 + pcrf_vnf_id: + get_input: pcrf_vnf_id + pcrf_oam_net_name: + get_input: pcrf_oam_net_name + pcrf_oam_net_ip: + get_input: + - pcrf_oam_net_ips + - 3 + pcrf_cps_net_mask: + get_input: pcrf_cps_net_mask + pcrf_gx_net_mask: + get_input: pcrf_gx_net_mask + pcrf_sgi_sy_net_name: + get_input: pcrf_sgi_sy_net_name + pcrf_sd_net_name: + get_input: pcrf_sd_net_name + pcrf_oam_net_gw: + get_input: pcrf_oam_net_gw + pcrf_rx_net_name: + get_input: pcrf_rx_net_name + pcrf_rx_net_ip: + get_input: + - pcrf_rx_net_ips + - 3 + pcrf_sy_net_ip: + get_input: + - pcrf_sy_net_ips + - 3 + pcrf_sgi_sy_net_ip: + get_input: + - pcrf_sgi_sy_net_ips + - 3 + pcrf_ppd_flavor_name: + get_input: pcrf_ppd_flavor_name + pcrf_cps_net_ip: + get_input: + - pcrf_cps_net_ips + - 3 + pcrf_sy_net_mask: + get_input: pcrf_sy_net_mask + pcrf_cps_net_name: + get_input: pcrf_cps_net_name + pcrf_oam_net_mask: + get_input: pcrf_oam_net_mask + pcrf_lb_management_vip: + get_input: pcrf_lb_management_vip + pcrf_sgi_sy_net_mask: + get_input: pcrf_sgi_sy_net_mask + pcrf_lb_internal_vip: + get_input: pcrf_lb_internal_vip + pcrf_sd_net_mask: + get_input: pcrf_sd_net_mask + pcrf_gx_net_name: + get_input: pcrf_gx_net_name + pcrf_sp_net_name: + get_input: pcrf_sp_net_name + pcrf_security_group_name: + get_input: pcrf_security_group_name + pcrf_rx_net_mask: + get_input: pcrf_rx_net_mask + pcrf_pcm_volume_id_1: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: pcrf_pcm_volume_silver + size: '(get_input : pcrf_pcm_vol_size) * 1024' + name: + get_input: pcrf_pcm_vol_name_1 + server_pcrf_ppd_001: + type: org.openecomp.resource.abstract.nodes.heat.nested-ppd_v1.0 + directives: + - substitutable + properties: + pcrf_ppd_image_name: + get_input: pcrf_ppd_image_name + availabilityzone_name: + get_input: availabilityzone_name + pcrf_sp_net_ip: + get_input: + - pcrf_sp_net_ips + - 0 + pcrf_ppd_server_name: + get_input: + - pcrf_ppd_server_names + - 0 + pcrf_gx_net_ip: + get_input: + - pcrf_gx_net_ips + - 0 + pcrf_sy_net_name: + get_input: pcrf_sy_net_name + pcrf_sp_net_mask: + get_input: pcrf_sp_net_mask + service_template_filter: + substitute_service_template: nested-ppd_v1.0ServiceTemplate.yaml + pcrf_sd_net_ip: + get_input: + - pcrf_sd_net_ips + - 0 + pcrf_vnf_id: + get_input: pcrf_vnf_id + pcrf_oam_net_name: + get_input: pcrf_oam_net_name + pcrf_oam_net_ip: + get_input: + - pcrf_oam_net_ips + - 0 + pcrf_cps_net_mask: + get_input: pcrf_cps_net_mask + pcrf_gx_net_mask: + get_input: pcrf_gx_net_mask + pcrf_sgi_sy_net_name: + get_input: pcrf_sgi_sy_net_name + pcrf_sd_net_name: + get_input: pcrf_sd_net_name + pcrf_oam_net_gw: + get_input: pcrf_oam_net_gw + pcrf_rx_net_name: + get_input: pcrf_rx_net_name + pcrf_rx_net_ip: + get_input: + - pcrf_rx_net_ips + - 0 + pcrf_sy_net_ip: + get_input: + - pcrf_sy_net_ips + - 0 + pcrf_sgi_sy_net_ip: + get_input: + - pcrf_sgi_sy_net_ips + - 0 + pcrf_ppd_flavor_name: + get_input: pcrf_ppd_flavor_name + pcrf_cps_net_ip: + get_input: + - pcrf_cps_net_ips + - 0 + pcrf_sy_net_mask: + get_input: pcrf_sy_net_mask + pcrf_cps_net_name: + get_input: pcrf_cps_net_name + pcrf_oam_net_mask: + get_input: pcrf_oam_net_mask + pcrf_lb_management_vip: + get_input: pcrf_lb_management_vip + pcrf_sgi_sy_net_mask: + get_input: pcrf_sgi_sy_net_mask + pcrf_lb_internal_vip: + get_input: pcrf_lb_internal_vip + pcrf_sd_net_mask: + get_input: pcrf_sd_net_mask + pcrf_gx_net_name: + get_input: pcrf_gx_net_name + pcrf_sp_net_name: + get_input: pcrf_sp_net_name + pcrf_security_group_name: + get_input: pcrf_security_group_name + pcrf_rx_net_mask: + get_input: pcrf_rx_net_mask + server_pcrf_ppd_002: + type: org.openecomp.resource.abstract.nodes.heat.nested-ppd_v1.0 + directives: + - substitutable + properties: + pcrf_ppd_image_name: + get_input: pcrf_ppd_image_name + availabilityzone_name: + get_input: availabilityzone_name + pcrf_sp_net_ip: + get_input: + - pcrf_sp_net_ips + - 1 + pcrf_ppd_server_name: + get_input: + - pcrf_ppd_server_names + - 1 + pcrf_gx_net_ip: + get_input: + - pcrf_gx_net_ips + - 1 + pcrf_sy_net_name: + get_input: pcrf_sy_net_name + pcrf_sp_net_mask: + get_input: pcrf_sp_net_mask + service_template_filter: + substitute_service_template: nested-ppd_v1.0ServiceTemplate.yaml + pcrf_sd_net_ip: + get_input: + - pcrf_sd_net_ips + - 1 + pcrf_vnf_id: + get_input: pcrf_vnf_id + pcrf_oam_net_name: + get_input: pcrf_oam_net_name + pcrf_oam_net_ip: + get_input: + - pcrf_oam_net_ips + - 1 + pcrf_cps_net_mask: + get_input: pcrf_cps_net_mask + pcrf_gx_net_mask: + get_input: pcrf_gx_net_mask + pcrf_sgi_sy_net_name: + get_input: pcrf_sgi_sy_net_name + pcrf_sd_net_name: + get_input: pcrf_sd_net_name + pcrf_oam_net_gw: + get_input: pcrf_oam_net_gw + pcrf_rx_net_name: + get_input: pcrf_rx_net_name + pcrf_rx_net_ip: + get_input: + - pcrf_rx_net_ips + - 1 + pcrf_sy_net_ip: + get_input: + - pcrf_sy_net_ips + - 1 + pcrf_sgi_sy_net_ip: + get_input: + - pcrf_sgi_sy_net_ips + - 1 + pcrf_ppd_flavor_name: + get_input: pcrf_ppd_flavor_name + pcrf_cps_net_ip: + get_input: + - pcrf_cps_net_ips + - 1 + pcrf_sy_net_mask: + get_input: pcrf_sy_net_mask + pcrf_cps_net_name: + get_input: pcrf_cps_net_name + pcrf_oam_net_mask: + get_input: pcrf_oam_net_mask + pcrf_lb_management_vip: + get_input: pcrf_lb_management_vip + pcrf_sgi_sy_net_mask: + get_input: pcrf_sgi_sy_net_mask + pcrf_lb_internal_vip: + get_input: pcrf_lb_internal_vip + pcrf_sd_net_mask: + get_input: pcrf_sd_net_mask + pcrf_gx_net_name: + get_input: pcrf_gx_net_name + pcrf_sp_net_name: + get_input: pcrf_sp_net_name + pcrf_security_group_name: + get_input: pcrf_security_group_name + pcrf_rx_net_mask: + get_input: pcrf_rx_net_mask + server_pcrf_psm_003: + type: org.openecomp.resource.abstract.nodes.heat.nested-psm_v1.0 + directives: + - substitutable + properties: + pcrf_cps_net_ip: + get_input: + - pcrf_cps_net_ips + - 2 + service_template_filter: + substitute_service_template: nested-psm_v1.0ServiceTemplate.yaml + pcrf_psm_flavor_name: + get_input: pcrf_psm_flavor_name + pcrf_psm_image_name: + get_input: pcrf_psm_image_name + availabilityzone_name: + get_input: availabilityzone_name + pcrf_vnf_id: + get_input: pcrf_vnf_id + pcrf_cps_net_name: + get_input: pcrf_cps_net_name + pcrf_cps_net_mask: + get_input: pcrf_cps_net_mask + pcrf_psm_server_name: + get_input: + - pcrf_psm_server_names + - 2 + pcrf_security_group_name: + get_input: pcrf_security_group_name + server_pcrf_psm_004: + type: org.openecomp.resource.abstract.nodes.heat.nested-psm_v1.0 + directives: + - substitutable + properties: + pcrf_cps_net_ip: + get_input: + - pcrf_cps_net_ips + - 3 + service_template_filter: + substitute_service_template: nested-psm_v1.0ServiceTemplate.yaml + pcrf_psm_flavor_name: + get_input: pcrf_psm_flavor_name + pcrf_psm_image_name: + get_input: pcrf_psm_image_name + availabilityzone_name: + get_input: availabilityzone_name + pcrf_vnf_id: + get_input: pcrf_vnf_id + pcrf_cps_net_name: + get_input: pcrf_cps_net_name + pcrf_cps_net_mask: + get_input: pcrf_cps_net_mask + pcrf_psm_server_name: + get_input: + - pcrf_psm_server_names + - 3 + pcrf_security_group_name: + get_input: pcrf_security_group_name + server_pcrf_psm_001: + type: org.openecomp.resource.abstract.nodes.heat.nested-psm_v1.0 + directives: + - substitutable + properties: + pcrf_cps_net_ip: + get_input: + - pcrf_cps_net_ips + - 0 + service_template_filter: + substitute_service_template: nested-psm_v1.0ServiceTemplate.yaml + pcrf_psm_flavor_name: + get_input: pcrf_psm_flavor_name + pcrf_psm_image_name: + get_input: pcrf_psm_image_name + availabilityzone_name: + get_input: availabilityzone_name + pcrf_vnf_id: + get_input: pcrf_vnf_id + pcrf_cps_net_name: + get_input: pcrf_cps_net_name + pcrf_cps_net_mask: + get_input: pcrf_cps_net_mask + pcrf_psm_server_name: + get_input: + - pcrf_psm_server_names + - 0 + pcrf_security_group_name: + get_input: pcrf_security_group_name + server_pcrf_psm_002: + type: org.openecomp.resource.abstract.nodes.heat.nested-psm_v1.0 + directives: + - substitutable + properties: + pcrf_cps_net_ip: + get_input: + - pcrf_cps_net_ips + - 1 + service_template_filter: + substitute_service_template: nested-psm_v1.0ServiceTemplate.yaml + pcrf_psm_flavor_name: + get_input: pcrf_psm_flavor_name + pcrf_psm_image_name: + get_input: pcrf_psm_image_name + availabilityzone_name: + get_input: availabilityzone_name + pcrf_vnf_id: + get_input: pcrf_vnf_id + pcrf_cps_net_name: + get_input: pcrf_cps_net_name + pcrf_cps_net_mask: + get_input: pcrf_cps_net_mask + pcrf_psm_server_name: + get_input: + - pcrf_psm_server_names + - 1 + pcrf_security_group_name: + get_input: pcrf_security_group_name + server_pcrf_psm_007: + type: org.openecomp.resource.abstract.nodes.heat.nested-psm_v1.0 + directives: + - substitutable + properties: + pcrf_cps_net_ip: + get_input: + - pcrf_cps_net_ips + - 6 + service_template_filter: + substitute_service_template: nested-psm_v1.0ServiceTemplate.yaml + pcrf_psm_flavor_name: + get_input: pcrf_psm_flavor_name + pcrf_psm_image_name: + get_input: pcrf_psm_image_name + availabilityzone_name: + get_input: availabilityzone_name + pcrf_vnf_id: + get_input: pcrf_vnf_id + pcrf_cps_net_name: + get_input: pcrf_cps_net_name + pcrf_cps_net_mask: + get_input: pcrf_cps_net_mask + pcrf_psm_server_name: + get_input: + - pcrf_psm_server_names + - 6 + pcrf_security_group_name: + get_input: pcrf_security_group_name + server_pcrf_psm_008: + type: org.openecomp.resource.abstract.nodes.heat.nested-psm_v1.0 + directives: + - substitutable + properties: + pcrf_cps_net_ip: + get_input: + - pcrf_cps_net_ips + - 7 + service_template_filter: + substitute_service_template: nested-psm_v1.0ServiceTemplate.yaml + pcrf_psm_flavor_name: + get_input: pcrf_psm_flavor_name + pcrf_psm_image_name: + get_input: pcrf_psm_image_name + availabilityzone_name: + get_input: availabilityzone_name + pcrf_vnf_id: + get_input: pcrf_vnf_id + pcrf_cps_net_name: + get_input: pcrf_cps_net_name + pcrf_cps_net_mask: + get_input: pcrf_cps_net_mask + pcrf_psm_server_name: + get_input: + - pcrf_psm_server_names + - 7 + pcrf_security_group_name: + get_input: pcrf_security_group_name + server_pcrf_psm_005: + type: org.openecomp.resource.abstract.nodes.heat.nested-psm_v1.0 + directives: + - substitutable + properties: + pcrf_cps_net_ip: + get_input: + - pcrf_cps_net_ips + - 4 + service_template_filter: + substitute_service_template: nested-psm_v1.0ServiceTemplate.yaml + pcrf_psm_flavor_name: + get_input: pcrf_psm_flavor_name + pcrf_psm_image_name: + get_input: pcrf_psm_image_name + availabilityzone_name: + get_input: availabilityzone_name + pcrf_vnf_id: + get_input: pcrf_vnf_id + pcrf_cps_net_name: + get_input: pcrf_cps_net_name + pcrf_cps_net_mask: + get_input: pcrf_cps_net_mask + pcrf_psm_server_name: + get_input: + - pcrf_psm_server_names + - 4 + pcrf_security_group_name: + get_input: pcrf_security_group_name + server_pcrf_psm_006: + type: org.openecomp.resource.abstract.nodes.heat.nested-psm_v1.0 + directives: + - substitutable + properties: + pcrf_cps_net_ip: + get_input: + - pcrf_cps_net_ips + - 5 + service_template_filter: + substitute_service_template: nested-psm_v1.0ServiceTemplate.yaml + pcrf_psm_flavor_name: + get_input: pcrf_psm_flavor_name + pcrf_psm_image_name: + get_input: pcrf_psm_image_name + availabilityzone_name: + get_input: availabilityzone_name + pcrf_vnf_id: + get_input: pcrf_vnf_id + pcrf_cps_net_name: + get_input: pcrf_cps_net_name + pcrf_cps_net_mask: + get_input: pcrf_cps_net_mask + pcrf_psm_server_name: + get_input: + - pcrf_psm_server_names + - 5 + pcrf_security_group_name: + get_input: pcrf_security_group_name + pcrf_oam_volume_id_22: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: pcrf_oam_volume_silver-2 + size: '(get_input : pcrf_oam_vol_size) * 1024' + name: + get_input: pcrf_oam_vol_name_2 + server_pcrf_psm_009: + type: org.openecomp.resource.abstract.nodes.heat.nested-psm_v1.0 + directives: + - substitutable + properties: + pcrf_cps_net_ip: + get_input: + - pcrf_cps_net_ips + - 8 + service_template_filter: + substitute_service_template: nested-psm_v1.0ServiceTemplate.yaml + pcrf_psm_flavor_name: + get_input: pcrf_psm_flavor_name + pcrf_psm_image_name: + get_input: pcrf_psm_image_name + availabilityzone_name: + get_input: availabilityzone_name + pcrf_vnf_id: + get_input: pcrf_vnf_id + pcrf_cps_net_name: + get_input: pcrf_cps_net_name + pcrf_cps_net_mask: + get_input: pcrf_cps_net_mask + pcrf_psm_server_name: + get_input: + - pcrf_psm_server_names + - 8 + pcrf_security_group_name: + get_input: pcrf_security_group_name + server_pcrf_pps_001: + type: org.openecomp.resource.abstract.nodes.heat.nested-pps_v1.0 + directives: + - substitutable + properties: + pcrf_cps_net_ip: + get_input: + - pcrf_cps_net_ips + - 0 + service_template_filter: + substitute_service_template: nested-pps_v1.0ServiceTemplate.yaml + availabilityzone_name: + get_input: availabilityzone_name + pcrf_vnf_id: + get_input: pcrf_vnf_id + pcrf_cps_net_name: + get_input: pcrf_cps_net_name + pcrf_cps_net_mask: + get_input: pcrf_cps_net_mask + pcrf_pps_image_name: + get_input: pcrf_pps_image_name + pcrf_pps_flavor_name: + get_input: pcrf_pps_flavor_name + pcrf_pps_server_name: + get_input: + - pcrf_pps_server_names + - 0 + pcrf_security_group_name: + get_input: pcrf_security_group_name + server_pcrf_pps_002: + type: org.openecomp.resource.abstract.nodes.heat.nested-pps_v1.0 + directives: + - substitutable + properties: + pcrf_cps_net_ip: + get_input: + - pcrf_cps_net_ips + - 1 + service_template_filter: + substitute_service_template: nested-pps_v1.0ServiceTemplate.yaml + availabilityzone_name: + get_input: availabilityzone_name + pcrf_vnf_id: + get_input: pcrf_vnf_id + pcrf_cps_net_name: + get_input: pcrf_cps_net_name + pcrf_cps_net_mask: + get_input: pcrf_cps_net_mask + pcrf_pps_image_name: + get_input: pcrf_pps_image_name + pcrf_pps_flavor_name: + get_input: pcrf_pps_flavor_name + pcrf_pps_server_name: + get_input: + - pcrf_pps_server_names + - 1 + pcrf_security_group_name: + get_input: pcrf_security_group_name + server_pcrf_pps_003: + type: org.openecomp.resource.abstract.nodes.heat.nested-pps_v1.0 + directives: + - substitutable + properties: + pcrf_cps_net_ip: + get_input: + - pcrf_cps_net_ips + - 2 + service_template_filter: + substitute_service_template: nested-pps_v1.0ServiceTemplate.yaml + availabilityzone_name: + get_input: availabilityzone_name + pcrf_vnf_id: + get_input: pcrf_vnf_id + pcrf_cps_net_name: + get_input: pcrf_cps_net_name + pcrf_cps_net_mask: + get_input: pcrf_cps_net_mask + pcrf_pps_image_name: + get_input: pcrf_pps_image_name + pcrf_pps_flavor_name: + get_input: pcrf_pps_flavor_name + pcrf_pps_server_name: + get_input: + - pcrf_pps_server_names + - 2 + pcrf_security_group_name: + get_input: pcrf_security_group_name + server_pcrf_pps_004: + type: org.openecomp.resource.abstract.nodes.heat.nested-pps_v1.0 + directives: + - substitutable + properties: + pcrf_cps_net_ip: + get_input: + - pcrf_cps_net_ips + - 3 + service_template_filter: + substitute_service_template: nested-pps_v1.0ServiceTemplate.yaml + availabilityzone_name: + get_input: availabilityzone_name + pcrf_vnf_id: + get_input: pcrf_vnf_id + pcrf_cps_net_name: + get_input: pcrf_cps_net_name + pcrf_cps_net_mask: + get_input: pcrf_cps_net_mask + pcrf_pps_image_name: + get_input: pcrf_pps_image_name + pcrf_pps_flavor_name: + get_input: pcrf_pps_flavor_name + pcrf_pps_server_name: + get_input: + - pcrf_pps_server_names + - 3 + pcrf_security_group_name: + get_input: pcrf_security_group_name + server_pcrf_pps_005: + type: org.openecomp.resource.abstract.nodes.heat.nested-pps_v1.0 + directives: + - substitutable + properties: + pcrf_cps_net_ip: + get_input: + - pcrf_cps_net_ips + - 4 + service_template_filter: + substitute_service_template: nested-pps_v1.0ServiceTemplate.yaml + availabilityzone_name: + get_input: availabilityzone_name + pcrf_vnf_id: + get_input: pcrf_vnf_id + pcrf_cps_net_name: + get_input: pcrf_cps_net_name + pcrf_cps_net_mask: + get_input: pcrf_cps_net_mask + pcrf_pps_image_name: + get_input: pcrf_pps_image_name + pcrf_pps_flavor_name: + get_input: pcrf_pps_flavor_name + pcrf_pps_server_name: + get_input: + - pcrf_pps_server_names + - 4 + pcrf_security_group_name: + get_input: pcrf_security_group_name + server_pcrf_pps_006: + type: org.openecomp.resource.abstract.nodes.heat.nested-pps_v1.0 + directives: + - substitutable + properties: + pcrf_cps_net_ip: + get_input: + - pcrf_cps_net_ips + - 5 + service_template_filter: + substitute_service_template: nested-pps_v1.0ServiceTemplate.yaml + availabilityzone_name: + get_input: availabilityzone_name + pcrf_vnf_id: + get_input: pcrf_vnf_id + pcrf_cps_net_name: + get_input: pcrf_cps_net_name + pcrf_cps_net_mask: + get_input: pcrf_cps_net_mask + pcrf_pps_image_name: + get_input: pcrf_pps_image_name + pcrf_pps_flavor_name: + get_input: pcrf_pps_flavor_name + pcrf_pps_server_name: + get_input: + - pcrf_pps_server_names + - 5 + pcrf_security_group_name: + get_input: pcrf_security_group_name + server_pcrf_psm_010: + type: org.openecomp.resource.abstract.nodes.heat.nested-psm_v1.0 + directives: + - substitutable + properties: + pcrf_cps_net_ip: + get_input: + - pcrf_cps_net_ips + - 9 + service_template_filter: + substitute_service_template: nested-psm_v1.0ServiceTemplate.yaml + pcrf_psm_flavor_name: + get_input: pcrf_psm_flavor_name + pcrf_psm_image_name: + get_input: pcrf_psm_image_name + availabilityzone_name: + get_input: availabilityzone_name + pcrf_vnf_id: + get_input: pcrf_vnf_id + pcrf_cps_net_name: + get_input: pcrf_cps_net_name + pcrf_cps_net_mask: + get_input: pcrf_cps_net_mask + pcrf_psm_server_name: + get_input: + - pcrf_psm_server_names + - 9 + pcrf_security_group_name: + get_input: pcrf_security_group_name + server_pcrf_psm_011: + type: org.openecomp.resource.abstract.nodes.heat.nested-psm_v1.0 + directives: + - substitutable + properties: + pcrf_cps_net_ip: + get_input: + - pcrf_cps_net_ips + - 10 + service_template_filter: + substitute_service_template: nested-psm_v1.0ServiceTemplate.yaml + pcrf_psm_flavor_name: + get_input: pcrf_psm_flavor_name + pcrf_psm_image_name: + get_input: pcrf_psm_image_name + availabilityzone_name: + get_input: availabilityzone_name + pcrf_vnf_id: + get_input: pcrf_vnf_id + pcrf_cps_net_name: + get_input: pcrf_cps_net_name + pcrf_cps_net_mask: + get_input: pcrf_cps_net_mask + pcrf_psm_server_name: + get_input: + - pcrf_psm_server_names + - 10 + pcrf_security_group_name: + get_input: pcrf_security_group_name + groups: + hot-nimbus-ppd_v1.0: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/hot-nimbus-ppd_v1.0.yaml + description: heat template that creates PCRF Policy Director stack + members: + - server_pcrf_ppd_003 + - server_pcrf_ppd_004 + - server_pcrf_ppd_001 + - server_pcrf_ppd_002 + hot-nimbus-pcm_v1.0: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/hot-nimbus-pcm_v1.0.yaml + description: heat template that creates PCRF Cluman stack + members: + - server_pcrf_pcm_001 + hot-nimbus-oam_v1.0: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/hot-nimbus-oam_v1.0.yaml + description: heat template that creates multiple PCRF OAM nodes stack + members: + - server_pcrf_oam_001 + - server_pcrf_oam_002 + hot-nimbus-oam-volumes_v1.0: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/hot-nimbus-oam-volumes_v1.0.yaml + members: + - pcrf_oam_volume_id_11 + - pcrf_oam_volume_id_22 + hot-nimbus-psm_v1.0: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/hot-nimbus-psm_v1.0.yaml + description: heat template that creates PCRF Session Manager stack + members: + - server_pcrf_psm_003 + - server_pcrf_psm_004 + - server_pcrf_psm_001 + - server_pcrf_psm_012 + - server_pcrf_psm_002 + - server_pcrf_psm_007 + - server_pcrf_psm_008 + - server_pcrf_psm_005 + - server_pcrf_psm_006 + - server_pcrf_psm_009 + - server_pcrf_psm_010 + - server_pcrf_psm_011 + hot-nimbus-pcm-volumes_v1.0: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/hot-nimbus-pcm-volumes_v1.0.yaml + members: + - pcrf_pcm_volume_id_1 + hot-nimbus-pps_v1.0: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/hot-nimbus-pps_v1.0.yaml + description: heat template that creates PCRF Policy Server stack + members: + - server_pcrf_pps_001 + - server_pcrf_pps_002 + - server_pcrf_pps_003 + - server_pcrf_pps_004 + - server_pcrf_pps_005 + - server_pcrf_pps_006 + outputs: + pcrf_oam_volume_id_1: + description: the oam 001 volume id + value: pcrf_oam_volume_id_11 + pcrf_oam_volume_id_2: + description: the oam 002 volume id + value: pcrf_oam_volume_id_22 + pcrf_pcm_volume_id_1: + description: the pcrf_pcm_volume_id + value: pcrf_pcm_volume_id_1 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/out/nested-oam_v1.0ServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/out/nested-oam_v1.0ServiceTemplate.yaml new file mode 100644 index 0000000000..59b9cde00c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/out/nested-oam_v1.0ServiceTemplate.yaml @@ -0,0 +1,225 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested-oam_v1.0 +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.pcrf_oam_server: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + availabilityzone_name: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + pcrf_oam_flavor_name: + label: PCRF OAM flavor name + hidden: false + immutable: false + type: string + description: flavor name of PCRF OAM instance + pcrf_oam_server_name: + label: PCRF OAM server name + hidden: false + immutable: false + type: string + description: PCRF OAM server name + pcrf_cps_net_ip: + label: CPS network ip + hidden: false + immutable: false + type: string + description: CPS network ip + pcrf_vnf_id: + label: PCRF VNF Id + hidden: false + immutable: false + type: string + description: PCRF VNF Id + pcrf_oam_net_name: + label: OAM network name + hidden: false + immutable: false + type: string + description: OAM network name + pcrf_cps_net_name: + label: CPS network name + hidden: false + immutable: false + type: string + description: CPS network name + pcrf_arbiter_vip: + label: OAM Arbiter LB VIP + hidden: false + immutable: false + type: string + description: OAM Arbiter LB VIP + pcrf_oam_net_ip: + label: OAM network ip + hidden: false + immutable: false + type: string + description: OAM network ip + pcrf_oam_net_mask: + label: CPS network mask + hidden: false + immutable: false + type: string + description: CPS network mask + pcrf_cps_net_mask: + label: CPS network mask + hidden: false + immutable: false + type: string + description: CPS network mask + pcrf_oam_volume_id: + label: CPS OAM Cinder Volume + hidden: false + immutable: false + type: string + description: CPS OAM Cinder Volume + pcrf_oam_net_gw: + label: CPS network gateway + hidden: false + immutable: false + type: string + description: CPS network gateway + pcrf_oam_image_name: + label: image name + hidden: false + immutable: false + type: string + description: PCRF OAM image name + pcrf_security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + node_templates: + pcrf_server_oam: + type: org.openecomp.resource.vfc.nodes.heat.pcrf_oam_server + properties: + flavor: + get_input: pcrf_oam_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcrf_oam_image_name + config_drive: 'True' + metadata: + vnf_id: + get_input: pcrf_vnf_id + user_data_format: RAW + name: + get_input: pcrf_oam_server_name + pcrf_oam_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: pcrf_security_group_name + fixed_ips: + - ip_address: + get_input: pcrf_oam_net_ip + network: + get_input: pcrf_oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: pcrf_server_oam + relationship: tosca.relationships.network.BindsTo + pcrf_oam_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: pcrf_security_group_name + fixed_ips: + - ip_address: + get_input: pcrf_cps_net_ip + allowed_address_pairs: + - ip_address: + get_input: pcrf_arbiter_vip + network: + get_input: pcrf_cps_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: pcrf_server_oam + relationship: tosca.relationships.network.BindsTo + groups: + nested-oam_v1.0: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested-oam_v1.0.yaml + description: nested heat template that creates a PCRF OAM node stack + members: + - pcrf_server_oam + - pcrf_oam_port_1 + - pcrf_oam_port_0 + outputs: + pcrf_oam_vol_attachment_id: + description: the pcrf_oam_vol_attachment_id id + value: pcrf_oam_vol_attachment + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested-oam_v1.0 + capabilities: + endpoint_pcrf_server_oam: + - pcrf_server_oam + - endpoint + host_pcrf_server_oam: + - pcrf_server_oam + - host + binding_pcrf_server_oam: + - pcrf_server_oam + - binding + attachment_pcrf_oam_port_1: + - pcrf_oam_port_1 + - attachment + attachment_pcrf_oam_port_0: + - pcrf_oam_port_0 + - attachment + scalable_pcrf_server_oam: + - pcrf_server_oam + - scalable + os_pcrf_server_oam: + - pcrf_server_oam + - os + requirements: + local_storage_pcrf_server_oam: + - pcrf_server_oam + - local_storage + link_pcrf_oam_port_1: + - pcrf_oam_port_1 + - link + link_pcrf_oam_port_0: + - pcrf_oam_port_0 + - link \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/out/nested-pcm_v1.0ServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/out/nested-pcm_v1.0ServiceTemplate.yaml new file mode 100644 index 0000000000..86a37e4e55 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/out/nested-pcm_v1.0ServiceTemplate.yaml @@ -0,0 +1,216 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested-pcm_v1.0 +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.pcrf_pcm_server: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + pcrf_pcm_flavor_name: + label: PCRF CM flavor name + hidden: false + immutable: false + type: string + description: flavor name of PCRF CM instance + availabilityzone_name: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + pcrf_cps_net_ip: + label: CPS network ip + hidden: false + immutable: false + type: string + description: CPS network ip + pcrf_pcm_image_name: + label: image name + hidden: false + immutable: false + type: string + description: PCRF CM image name + pcrf_vnf_id: + label: PCRF VNF Id + hidden: false + immutable: false + type: string + description: PCRF VNF Id + pcrf_oam_net_name: + label: OAM network name + hidden: false + immutable: false + type: string + description: OAM network name + pcrf_cps_net_name: + label: CPS network name + hidden: false + immutable: false + type: string + description: CPS network name + pcrf_oam_net_ip: + label: OAM network ip + hidden: false + immutable: false + type: string + description: OAM network ip + pcrf_oam_net_mask: + label: CPS network mask + hidden: false + immutable: false + type: string + description: CPS network mask + pcrf_cps_net_mask: + label: CPS network mask + hidden: false + immutable: false + type: string + description: CPS network mask + pcrf_pcm_server_name: + label: PCRF CM server name + hidden: false + immutable: false + type: string + description: PCRF CM server name + pcrf_oam_net_gw: + label: CPS network gateway + hidden: false + immutable: false + type: string + description: CPS network gateway + pcrf_pcm_volume_id: + label: CPS Cluman Cinder Volume + hidden: false + immutable: false + type: string + description: CPS Cluman Cinder Volume + pcrf_security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + node_templates: + pcrf_pcm_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: pcrf_security_group_name + fixed_ips: + - ip_address: + get_input: pcrf_cps_net_ip + network: + get_input: pcrf_cps_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: pcrf_server_pcm + relationship: tosca.relationships.network.BindsTo + pcrf_server_pcm: + type: org.openecomp.resource.vfc.nodes.heat.pcrf_pcm_server + properties: + flavor: + get_input: pcrf_pcm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcrf_pcm_image_name + config_drive: 'True' + metadata: + vnf_id: + get_input: pcrf_vnf_id + user_data_format: RAW + name: + get_input: pcrf_pcm_server_name + pcrf_pcm_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: pcrf_security_group_name + fixed_ips: + - ip_address: + get_input: pcrf_oam_net_ip + network: + get_input: pcrf_oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: pcrf_server_pcm + relationship: tosca.relationships.network.BindsTo + groups: + nested-pcm_v1.0: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested-pcm_v1.0.yaml + description: heat template that creates PCRF Cluman stack + members: + - pcrf_pcm_port_0 + - pcrf_server_pcm + - pcrf_pcm_port_1 + outputs: + pcrf_server_pcm_id: + description: the pcm server id + value: pcrf_server_pcm + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested-pcm_v1.0 + capabilities: + endpoint_pcrf_server_pcm: + - pcrf_server_pcm + - endpoint + attachment_pcrf_pcm_port_0: + - pcrf_pcm_port_0 + - attachment + binding_pcrf_server_pcm: + - pcrf_server_pcm + - binding + os_pcrf_server_pcm: + - pcrf_server_pcm + - os + host_pcrf_server_pcm: + - pcrf_server_pcm + - host + scalable_pcrf_server_pcm: + - pcrf_server_pcm + - scalable + attachment_pcrf_pcm_port_1: + - pcrf_pcm_port_1 + - attachment + requirements: + local_storage_pcrf_server_pcm: + - pcrf_server_pcm + - local_storage + link_pcrf_pcm_port_0: + - pcrf_pcm_port_0 + - link + link_pcrf_pcm_port_1: + - pcrf_pcm_port_1 + - link \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/out/nested-ppd_v1.0ServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/out/nested-ppd_v1.0ServiceTemplate.yaml new file mode 100644 index 0000000000..976cbebf83 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/out/nested-ppd_v1.0ServiceTemplate.yaml @@ -0,0 +1,464 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested-ppd_v1.0 +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.pcrf_ppd_server: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + pcrf_ppd_image_name: + label: image name + hidden: false + immutable: false + type: string + description: PCRF PD image name + availabilityzone_name: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + pcrf_sp_net_ip: + label: Sp network ip + hidden: false + immutable: false + type: string + description: Sp network ip + pcrf_ppd_server_name: + label: PCRF PD server name + hidden: false + immutable: false + type: string + description: PCRF PD server name + pcrf_gx_net_ip: + label: Gx network ip + hidden: false + immutable: false + type: string + description: Gx network ip + pcrf_sy_net_name: + label: Sy network name + hidden: false + immutable: false + type: string + description: Sy network name + pcrf_sp_net_mask: + label: Sp network mask + hidden: false + immutable: false + type: string + description: Sp network mask + pcrf_sd_net_ip: + label: Sd network ip + hidden: false + immutable: false + type: string + description: Sd network ip + pcrf_vnf_id: + label: PCRF VNF Id + hidden: false + immutable: false + type: string + description: PCRF VNF Id + pcrf_oam_net_name: + label: OAM network name + hidden: false + immutable: false + type: string + description: OAM network name + pcrf_oam_net_ip: + label: OAM network ip + hidden: false + immutable: false + type: string + description: OAM network ip + pcrf_cps_net_mask: + label: CPS network mask + hidden: false + immutable: false + type: string + description: CPS network mask + pcrf_gx_net_mask: + label: Gx network mask + hidden: false + immutable: false + type: string + description: Gx network mask + pcrf_sgi_sy_net_name: + label: Sgi Sy network name + hidden: false + immutable: false + type: string + description: Sgi Sy network name + pcrf_sd_net_name: + label: Sd network name + hidden: false + immutable: false + type: string + description: Sd network name + pcrf_oam_net_gw: + label: CPS network gateway + hidden: false + immutable: false + type: string + description: CPS network gateway + pcrf_rx_net_name: + label: Rx network name + hidden: false + immutable: false + type: string + description: Rx network name + pcrf_rx_net_ip: + label: Rx network ip + hidden: false + immutable: false + type: string + description: Rx network ip + pcrf_sy_net_ip: + label: Sy network ip + hidden: false + immutable: false + type: string + description: Sy network ip + pcrf_sgi_sy_net_ip: + label: Sgi Sy network ip + hidden: false + immutable: false + type: string + description: Sgi Sy network ip + pcrf_ppd_flavor_name: + label: PCRF PD flavor name + hidden: false + immutable: false + type: string + description: flavor name of PCRF PD instance + pcrf_cps_net_ip: + label: CPS network ip + hidden: false + immutable: false + type: string + description: CPS network ip + pcrf_sy_net_mask: + label: Sy network mask + hidden: false + immutable: false + type: string + description: Sy network mask + pcrf_cps_net_name: + label: CPS network name + hidden: false + immutable: false + type: string + description: CPS network name + pcrf_oam_net_mask: + label: CPS network mask + hidden: false + immutable: false + type: string + description: CPS network mask + pcrf_lb_management_vip: + label: CPS OAM LB VIP + hidden: false + immutable: false + type: string + description: CPS OAM LB VIP + pcrf_sgi_sy_net_mask: + label: Sgi Sy network mask + hidden: false + immutable: false + type: string + description: Sgi Sy network mask + pcrf_lb_internal_vip: + label: CPS Internal LB VIP + hidden: false + immutable: false + type: string + description: CPS Internal LB VIP + pcrf_sd_net_mask: + label: Sd network mask + hidden: false + immutable: false + type: string + description: Sd network mask + pcrf_gx_net_name: + label: Gx network name + hidden: false + immutable: false + type: string + description: Gx network name + pcrf_sp_net_name: + label: Sp network name + hidden: false + immutable: false + type: string + description: Sp network name + pcrf_rx_net_mask: + label: Rx network mask + hidden: false + immutable: false + type: string + description: Rx network mask + pcrf_security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + node_templates: + pcrf_ppd_port_5: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: pcrf_security_group_name + fixed_ips: + - ip_address: + get_input: pcrf_rx_net_ip + network: + get_input: pcrf_rx_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: pcrf_server_ppd + relationship: tosca.relationships.network.BindsTo + pcrf_ppd_port_6: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: pcrf_security_group_name + fixed_ips: + - ip_address: + get_input: pcrf_sd_net_ip + network: + get_input: pcrf_sd_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: pcrf_server_ppd + relationship: tosca.relationships.network.BindsTo + pcrf_ppd_port_3: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: pcrf_security_group_name + fixed_ips: + - ip_address: + get_input: pcrf_sp_net_ip + network: + get_input: pcrf_sp_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: pcrf_server_ppd + relationship: tosca.relationships.network.BindsTo + pcrf_server_ppd: + type: org.openecomp.resource.vfc.nodes.heat.pcrf_ppd_server + properties: + flavor: + get_input: pcrf_ppd_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcrf_ppd_image_name + config_drive: 'True' + metadata: + vnf_id: + get_input: pcrf_vnf_id + user_data_format: RAW + name: + get_input: pcrf_ppd_server_name + pcrf_ppd_port_4: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: pcrf_security_group_name + fixed_ips: + - ip_address: + get_input: pcrf_sy_net_ip + network: + get_input: pcrf_sy_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: pcrf_server_ppd + relationship: tosca.relationships.network.BindsTo + pcrf_ppd_port_7: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: pcrf_security_group_name + fixed_ips: + - ip_address: + get_input: pcrf_sgi_sy_net_ip + network: + get_input: pcrf_sgi_sy_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: pcrf_server_ppd + relationship: tosca.relationships.network.BindsTo + pcrf_ppd_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: pcrf_security_group_name + fixed_ips: + - ip_address: + get_input: pcrf_oam_net_ip + allowed_address_pairs: + - ip_address: + get_input: pcrf_lb_management_vip + network: + get_input: pcrf_oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: pcrf_server_ppd + relationship: tosca.relationships.network.BindsTo + pcrf_ppd_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: pcrf_security_group_name + fixed_ips: + - ip_address: + get_input: pcrf_gx_net_ip + network: + get_input: pcrf_gx_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: pcrf_server_ppd + relationship: tosca.relationships.network.BindsTo + pcrf_ppd_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: pcrf_security_group_name + fixed_ips: + - ip_address: + get_input: pcrf_cps_net_ip + allowed_address_pairs: + - ip_address: + get_input: pcrf_lb_internal_vip + network: + get_input: pcrf_cps_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: pcrf_server_ppd + relationship: tosca.relationships.network.BindsTo + groups: + nested-ppd_v1.0: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested-ppd_v1.0.yaml + description: heat template that creates PCRF Policy Director stack + members: + - pcrf_ppd_port_5 + - pcrf_ppd_port_6 + - pcrf_ppd_port_3 + - pcrf_server_ppd + - pcrf_ppd_port_4 + - pcrf_ppd_port_7 + - pcrf_ppd_port_1 + - pcrf_ppd_port_2 + - pcrf_ppd_port_0 + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested-ppd_v1.0 + capabilities: + attachment_pcrf_ppd_port_1: + - pcrf_ppd_port_1 + - attachment + attachment_pcrf_ppd_port_2: + - pcrf_ppd_port_2 + - attachment + binding_pcrf_server_ppd: + - pcrf_server_ppd + - binding + attachment_pcrf_ppd_port_0: + - pcrf_ppd_port_0 + - attachment + attachment_pcrf_ppd_port_5: + - pcrf_ppd_port_5 + - attachment + attachment_pcrf_ppd_port_6: + - pcrf_ppd_port_6 + - attachment + attachment_pcrf_ppd_port_3: + - pcrf_ppd_port_3 + - attachment + os_pcrf_server_ppd: + - pcrf_server_ppd + - os + attachment_pcrf_ppd_port_4: + - pcrf_ppd_port_4 + - attachment + endpoint_pcrf_server_ppd: + - pcrf_server_ppd + - endpoint + scalable_pcrf_server_ppd: + - pcrf_server_ppd + - scalable + attachment_pcrf_ppd_port_7: + - pcrf_ppd_port_7 + - attachment + host_pcrf_server_ppd: + - pcrf_server_ppd + - host + requirements: + link_pcrf_ppd_port_3: + - pcrf_ppd_port_3 + - link + link_pcrf_ppd_port_2: + - pcrf_ppd_port_2 + - link + local_storage_pcrf_server_ppd: + - pcrf_server_ppd + - local_storage + link_pcrf_ppd_port_1: + - pcrf_ppd_port_1 + - link + link_pcrf_ppd_port_0: + - pcrf_ppd_port_0 + - link + link_pcrf_ppd_port_7: + - pcrf_ppd_port_7 + - link + link_pcrf_ppd_port_6: + - pcrf_ppd_port_6 + - link + link_pcrf_ppd_port_5: + - pcrf_ppd_port_5 + - link + link_pcrf_ppd_port_4: + - pcrf_ppd_port_4 + - link \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/out/nested-pps_v1.0ServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/out/nested-pps_v1.0ServiceTemplate.yaml new file mode 100644 index 0000000000..692a2f0d4b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/out/nested-pps_v1.0ServiceTemplate.yaml @@ -0,0 +1,160 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested-pps_v1.0 +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.pcrf_pps_server: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + pcrf_cps_net_ip: + label: CPS network ip + hidden: false + immutable: false + type: string + description: CPS network ip + availabilityzone_name: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + pcrf_vnf_id: + label: PCRF VNF Id + hidden: false + immutable: false + type: string + description: PCRF VNF Id + pcrf_cps_net_name: + label: CPS network name + hidden: false + immutable: false + type: string + description: CPS network name + pcrf_cps_net_mask: + label: CPS network mask + hidden: false + immutable: false + type: string + description: CPS network mask + pcrf_pps_image_name: + label: PCRF PS image name + hidden: false + immutable: false + type: string + description: PCRF PS image name + pcrf_pps_flavor_name: + label: PCRF PS flavor name + hidden: false + immutable: false + type: string + description: flavor name of PCRF PS instance + pcrf_pps_server_name: + label: PCRF PS server name + hidden: false + immutable: false + type: string + description: PCRF PS server name + pcrf_security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + node_templates: + pcrf_pps_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: pcrf_security_group_name + fixed_ips: + - ip_address: + get_input: pcrf_cps_net_ip + network: + get_input: pcrf_cps_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: pcrf_server_pps + relationship: tosca.relationships.network.BindsTo + pcrf_server_pps: + type: org.openecomp.resource.vfc.nodes.heat.pcrf_pps_server + properties: + flavor: + get_input: pcrf_pps_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcrf_pps_image_name + config_drive: 'True' + metadata: + vnf_id: + get_input: pcrf_vnf_id + user_data_format: RAW + name: + get_input: pcrf_pps_server_name + groups: + nested-pps_v1.0: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested-pps_v1.0.yaml + description: heat template that creates PCRF Policy Server stack + members: + - pcrf_pps_port_0 + - pcrf_server_pps + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested-pps_v1.0 + capabilities: + binding_pcrf_server_pps: + - pcrf_server_pps + - binding + attachment_pcrf_pps_port_0: + - pcrf_pps_port_0 + - attachment + scalable_pcrf_server_pps: + - pcrf_server_pps + - scalable + os_pcrf_server_pps: + - pcrf_server_pps + - os + endpoint_pcrf_server_pps: + - pcrf_server_pps + - endpoint + host_pcrf_server_pps: + - pcrf_server_pps + - host + requirements: + link_pcrf_pps_port_0: + - pcrf_pps_port_0 + - link + local_storage_pcrf_server_pps: + - pcrf_server_pps + - local_storage \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/out/nested-psm_v1.0ServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/out/nested-psm_v1.0ServiceTemplate.yaml new file mode 100644 index 0000000000..770e1dceb8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/hot-nimbus-oam-volumes_v1.0/out/nested-psm_v1.0ServiceTemplate.yaml @@ -0,0 +1,160 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested-psm_v1.0 +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.pcrf_psm_server: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + pcrf_cps_net_ip: + label: CPS network ip + hidden: false + immutable: false + type: string + description: CPS network ip + pcrf_psm_flavor_name: + label: PCRF SM flavor name + hidden: false + immutable: false + type: string + description: flavor name of PCRF SM instance + pcrf_psm_image_name: + label: image name + hidden: false + immutable: false + type: string + description: PCRF SM image name + availabilityzone_name: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + pcrf_vnf_id: + label: PCRF VNF Id + hidden: false + immutable: false + type: string + description: PCRF VNF Id + pcrf_cps_net_name: + label: CPS network name + hidden: false + immutable: false + type: string + description: CPS network name + pcrf_cps_net_mask: + label: CPS network mask + hidden: false + immutable: false + type: string + description: CPS network mask + pcrf_psm_server_name: + label: PCRF SM server name + hidden: false + immutable: false + type: string + description: PCRF SM server name + pcrf_security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + node_templates: + pcrf_server_psm: + type: org.openecomp.resource.vfc.nodes.heat.pcrf_psm_server + properties: + flavor: + get_input: pcrf_psm_flavor_name + availability_zone: + get_input: availabilityzone_name + image: + get_input: pcrf_psm_image_name + config_drive: 'True' + metadata: + vnf_id: + get_input: pcrf_vnf_id + user_data_format: RAW + name: + get_input: pcrf_psm_server_name + psm01_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - get_input: pcrf_security_group_name + fixed_ips: + - ip_address: + get_input: pcrf_cps_net_ip + network: + get_input: pcrf_cps_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: pcrf_server_psm + relationship: tosca.relationships.network.BindsTo + groups: + nested-psm_v1.0: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested-psm_v1.0.yaml + description: heat template that creates PCRF Session Manager stack + members: + - pcrf_server_psm + - psm01_port_0 + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested-psm_v1.0 + capabilities: + endpoint_pcrf_server_psm: + - pcrf_server_psm + - endpoint + binding_pcrf_server_psm: + - pcrf_server_psm + - binding + os_pcrf_server_psm: + - pcrf_server_psm + - os + attachment_psm01_port_0: + - psm01_port_0 + - attachment + host_pcrf_server_psm: + - pcrf_server_psm + - host + scalable_pcrf_server_psm: + - pcrf_server_psm + - scalable + requirements: + local_storage_pcrf_server_psm: + - pcrf_server_psm + - local_storage + link_psm01_port_0: + - psm01_port_0 + - link \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/neutron_port_translation/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/neutron_port_translation/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..8f3b23b959 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/neutron_port_translation/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,115 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + node_templates: + jsa_net: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + shared: true + network_name: + get_input: jsa_net_name + jsa_net1: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + shared: true + network_name: + get_input: jsa_net_name + cmaui1_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 1 + network: + get_input: oam_net_name + cmaui1_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - subnet: subnetNameVal + ip_address: + get_input: + - cmaui_oam_ips + - 1 + - subnet: subnetNameVal2 + ip_address: + get_input: + - cmaui_oam_ips + - 1 + network: jsa_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: jsa_net + relationship: tosca.relationships.network.LinksTo + cmaui1_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - subnet: subnetNameVal + ip_address: + get_input: + - cmaui_oam_ips + - 1 + - subnet: subnetNameVal2 + ip_address: + get_input: + - cmaui_oam_ips + - 1 + network: jsa_net1 + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: jsa_net1 + relationship: tosca.relationships.network.LinksTo + groups: + hot_template: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/hot_template.yml + description: cmaui server template for vMMSC + members: + - jsa_net + - jsa_net1 + - cmaui1_port_0 + - cmaui1_port_1 + - cmaui1_port_2 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/neutron_port_translation/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/neutron_port_translation/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..70cdc7d237 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/neutron_port_translation/inputfiles/MANIFEST.json @@ -0,0 +1,11 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volumes", + "version": "2013-05-23", + "data": [ + { + "file": "hot_template.yml", + "type": "HEAT" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/neutron_port_translation/inputfiles/hot_template.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/neutron_port_translation/inputfiles/hot_template.yml new file mode 100644 index 0000000000..47ba8fcb2a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/neutron_port_translation/inputfiles/hot_template.yml @@ -0,0 +1,49 @@ +heat_template_version: 2013-05-23 + +################################# +# +# Changes from MSO 01/26/2016 +# Updated per ECOMP feedback +# +################################# + +description: cmaui server template for vMMSC + +resources: + cmaui1_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 1]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + cmaui1_port_1: + type: OS::Neutron::Port + properties: + network_id: { get_resource: jsa_net } + fixed_ips: [{"subnet": subnetNameVal, "ip_address": {get_param: [cmaui_oam_ips, 1]}}, {"subnet": subnetNameVal2, "ip_address": {get_param: [cmaui_oam_ips, 1]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + jsa_net: + type: OS::Neutron::Net + properties: + name: {get_param: jsa_net_name} + shared: True + + cmaui1_port_2: + type: OS::Neutron::Port + properties: + network: { get_resource: jsa_net1 } + fixed_ips: [{"subnet": subnetNameVal, "ip_address": {get_param: [cmaui_oam_ips, 1]}}, {"subnet": subnetNameVal2, "ip_address": {get_param: [cmaui_oam_ips, 1]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + jsa_net1: + type: OS::Neutron::Net + properties: + name: {get_param: jsa_net_name} + shared: True + + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/neutron_security_group_translation/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/neutron_security_group_translation/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..f6a55b2d14 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/neutron_security_group_translation/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,169 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.MASTER: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + MASTER_image_name: + hidden: false + immutable: false + type: string + description: JSA MASTER instance image name + MASTER_names: + hidden: false + immutable: false + type: string + description: JSA MASTER instance name + security_group_name: + hidden: false + immutable: false + type: string + description: security group name of JSA + MASTER_flavor_name: + hidden: false + immutable: false + type: string + description: the flavor name of JSA MASTER instance + oam_net_name: + hidden: false + immutable: false + type: string + description: network name of OAM network + node_templates: + jsa_security_group: + type: org.openecomp.resource.vfc.rules.nodes.heat.network.neutron.SecurityRules + properties: + name: + get_input: security_group_name + description: ems security group + rules: + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + - protocol: tcp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv6 + remote_ip_prefix: ::/0 + direction: egress + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + - protocol: tcp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv6 + remote_ip_prefix: ::/0 + direction: ingress + requirements: + - port: + capability: tosca.capabilities.Attachment + node: MASTER_mgmt_port + relationship: org.openecomp.relationships.AttachesTo + MASTER_mgmt_port: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + security_groups: + - jsa_security_group + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: MASTER_instance + relationship: tosca.relationships.network.BindsTo + MASTER_instance: + type: org.openecomp.resource.vfc.nodes.heat.MASTER + properties: + flavor: + get_input: MASTER_flavor_name + image: + get_input: MASTER_image_name + name: + get_input: MASTER_names + groups: + hot_template: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/hot_template.yml + description: | + Version 2.0 02-11-2016 (Authors: John Doe, user PROD) + members: + - jsa_security_group + - MASTER_mgmt_port + - MASTER_instance \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/neutron_security_group_translation/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/neutron_security_group_translation/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..70cdc7d237 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/neutron_security_group_translation/inputfiles/MANIFEST.json @@ -0,0 +1,11 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volumes", + "version": "2013-05-23", + "data": [ + { + "file": "hot_template.yml", + "type": "HEAT" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/neutron_security_group_translation/inputfiles/hot_template.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/neutron_security_group_translation/inputfiles/hot_template.yml new file mode 100644 index 0000000000..6c6f52a681 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/neutron_security_group_translation/inputfiles/hot_template.yml @@ -0,0 +1,57 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-11-2016 (Authors: John Doe, user PROD) + +parameters: + oam_net_name: + type: string + description: network name of OAM network + security_group_name: + type: string + description: security group name of JSA + MASTER_names: + type: string + description: JSA MASTER instance name + MASTER_image_name: + type: string + description: JSA MASTER instance image name + MASTER_flavor_name: + type: string + description: the flavor name of JSA MASTER instance + +resources: + jsa_security_group: + type: OS::Neutron::SecurityGroup + properties: + description: ems security group + name: {get_param: security_group_name} + rules: [{"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": "::/0"}, + {"direction": egress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": "::/0"}, + {"direction": egress, "ethertype": IPv6, "protocol": icmp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv6, "protocol": icmp, "remote_ip_prefix": "::/0"} + ] + + + MASTER_instance: + type: OS::Nova::Server + properties: + name: {get_param: MASTER_names} + image: {get_param: MASTER_image_name} + flavor: {get_param: MASTER_flavor_name} + networks: + - port: {get_resource: MASTER_mgmt_port} + + MASTER_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: oam_net_name} + security_groups: [{get_resource: jsa_security_group}] diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novaservergroups/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novaservergroups/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..94f731985b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novaservergroups/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,603 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.smp: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + hostid_fe1: + hidden: false + immutable: false + type: string + description: FE1 Hostid (from Ulticom license) + ip_address_stp2: + hidden: false + immutable: false + type: string + description: STP2 IP address + Mobility_OAM_protected_net_id: + hidden: false + immutable: false + type: string + description: Network name for OAM + hostid_fe2: + hidden: false + immutable: false + type: string + description: FE2 Hostid (from Ulticom license) + flavor_scp_fe_name: + hidden: false + immutable: false + type: string + description: SCP FE Flavor + default: a1.Small + ip_address_stp1: + hidden: false + immutable: false + type: string + description: STP1 IP address + int_vscp_ce_network_net_id: + hidden: false + immutable: false + type: string + description: Inter-CE Network + int_vscp_ce_network_cidr: + hidden: false + immutable: false + type: string + description: Private Network Address (CIDR notation) + cluster_type: + hidden: false + immutable: false + type: string + constraints: + - valid_values: + - Test + - Prod + be_Mobility_OAM_protected_ip_1: + label: be_1 OAM ip address + hidden: false + immutable: false + type: string + description: be_1 OAM ip address + be_Mobility_OAM_protected_ip_2: + label: be_2 OAM ip address + hidden: false + immutable: false + type: string + description: be_2 OAM ip address + be_Mobility_OAM_protected_ip_0: + label: be_0 OAM ip address + hidden: false + immutable: false + type: string + description: be_0 OAM ip address + ip_address_dra: + hidden: false + immutable: false + type: string + description: DRA VIP address + image_smp_name: + hidden: false + immutable: false + type: string + description: SCP SMP image + default: asc_base_image_smp + fe_connectivity: + hidden: false + immutable: false + type: string + constraints: + - valid_values: + - NEE + - STP + lab_name: + hidden: false + immutable: false + type: string + description: Lab name + smp_Mobility_OAM_protected_ip_1: + label: smp_1 OAM ip address + hidden: false + immutable: false + type: string + description: smp_1 OAM ip address + fe_SIGNET_vrf_B1_direct_ip_0: + label: fe1 SIGTRAN ip address + hidden: false + immutable: false + type: string + description: fe1 SIGTRAN ip address + smp_Mobility_OAM_protected_ip_0: + label: smp_0 OAM ip address + hidden: false + immutable: false + type: string + description: smp_0 OAM ip address + int_vscp_cluster_net_id: + hidden: false + immutable: false + type: string + description: LAN3 Cluster + be_Mobility_OAM_protected_ip_3: + label: be_3 OAM ip address + hidden: false + immutable: false + type: string + description: be_3 OAM ip address + be_Mobility_OAM_protected_ip_4: + label: be_4 OAM ip address + hidden: false + immutable: false + type: string + description: be_4 OAM ip address + hostname_nee1: + hidden: false + immutable: false + type: string + description: NEE1 Hostname (from Ulticom license) + int_vscp_fe_cluster_net_id: + hidden: false + immutable: false + type: string + description: LAN2 FE Cluster/KA + SIGNET_vrf_A1_direct_net_id: + hidden: false + immutable: false + type: string + description: Network name for SIGTRAN_A + key_name: + hidden: false + immutable: false + type: string + description: keypair to enable SSH access to the instance. + default: vSCP-keypair + int_vscp_fe_cluster_cidr: + hidden: false + immutable: false + type: string + description: Private Network2 Address (CIDR notation) + fe_name_1: + hidden: false + immutable: false + type: string + description: name of VM + default: vSCP_FE2 + fe_name_0: + hidden: false + immutable: false + type: string + description: name of VM + default: vSCP_FE1 + be_name_0: + hidden: false + immutable: false + type: string + description: name of VM + default: vSCP_BE1 + int_vscp_cluster_cidr: + hidden: false + immutable: false + type: string + description: Private Network3 Address (CIDR notation) + be_name_1: + hidden: false + immutable: false + type: string + description: name of VM + default: vSCP_BE2 + be_name_2: + hidden: false + immutable: false + type: string + description: name of VM + default: vSCP_BE3 + point_code_stp: + hidden: false + immutable: false + type: string + description: STP virtual point code (in "zone-cluster-member" format) + be_name_3: + hidden: false + immutable: false + type: string + description: name of VM + default: vSCP_BE4 + be_name_4: + hidden: false + immutable: false + type: string + description: name of VM + default: vSCP_BE5 + global_title_scp: + hidden: false + immutable: false + type: string + description: vSCP Global Title address + vnf_name: + hidden: false + immutable: false + type: string + description: Unique name for this VNF instance + default: This_is_the_SCP_name + be_Cricket_OCS_protected_ip_2: + label: be3 Cricket_OCS ip address + hidden: false + immutable: false + type: string + description: be3 Cricket_OCS ip address + fe_Mobility_OAM_protected_ip_0: + label: fe_0 OAM ip address + hidden: false + immutable: false + type: string + description: fe_0 OAM ip address + hostname_fe1: + hidden: false + immutable: false + type: string + description: FE1 Hostname (from Ulticom license) + be_Cricket_OCS_protected_ip_1: + label: be2 Cricket_OCS ip address + hidden: false + immutable: false + type: string + description: be2 Cricket_OCS ip address + hostname_fe2: + hidden: false + immutable: false + type: string + description: FE2 Hostname (from Ulticom license) + be_Cricket_OCS_protected_ip_4: + label: be5 Cricket_OCS ip address + hidden: false + immutable: false + type: string + description: be5 Cricket_OCS ip address + be_Cricket_OCS_protected_ip_3: + label: be4 Cricket_OCS ip address + hidden: false + immutable: false + type: string + description: be4 Cricket_OCS ip address + fe_Mobility_OAM_protected_ip_1: + label: fe_1 OAM ip address + hidden: false + immutable: false + type: string + description: fe_1 OAM ip address + be_Cricket_OCS_protected_ip_0: + label: be1 Cricket_OCS ip address + hidden: false + immutable: false + type: string + description: be1 Cricket_OCS ip address + route_table_fe1: + hidden: false + immutable: false + type: string + description: Additional route table for FE1 + Cricket_OCS_protected_net_id: + hidden: false + immutable: false + type: string + description: Network name for CRICKET_OCS + smp_name_2: + hidden: false + immutable: false + type: string + description: name of VM + default: vSMP2 + vnf_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VNF instance + default: This_is_ths_SCP_id + smp_name_1: + hidden: false + immutable: false + type: string + description: name of VM + default: vSMP2 + flavor_smp_name: + hidden: false + immutable: false + type: string + description: SCP SMP Flavor + default: a1.Small + image_scp_be_name: + hidden: false + immutable: false + type: string + description: SCP BE image + default: asc_base_image_be + smp_name_0: + hidden: false + immutable: false + type: string + description: name of VM + default: vSMP1 + route_table_fe2: + hidden: false + immutable: false + type: string + description: Additional route table for FE2 + hostid_nee1: + hidden: false + immutable: false + type: string + description: NEE1 Hostid (from Ulticom license) + SIGNET_vrf_B1_direct_net_id: + hidden: false + immutable: false + type: string + description: Network name for SIGTRAN_B + fe_SIGNET_vrf_A1_direct_ip_0: + label: fe2 SIGTRAN ip address + hidden: false + immutable: false + type: string + description: fe2 SIGTRAN ip address + availability_zone_0: + hidden: false + immutable: false + type: string + nee_name_0: + hidden: false + immutable: false + type: string + description: name of VM + default: vNEE + ip_port_stp1: + hidden: false + immutable: false + type: string + description: STP1 IP port + ip_port_stp2: + hidden: false + immutable: false + type: string + description: STP2 IP port + image_scp_fe_name: + hidden: false + immutable: false + type: string + description: SCP FE image + default: asc_base_image_fe + flavor_scp_be_name: + hidden: false + immutable: false + type: string + description: SCP BE Flavor + default: a1.Small + security_group_name: + label: vSCP security group name + hidden: false + immutable: false + type: string + description: vSCP security group name + ip_port_fe2: + hidden: false + immutable: false + type: string + description: FE2 IP port in SIGTRAN network + route_table_be: + hidden: false + immutable: false + type: string + description: Additional route table for BEs + ip_port_fe1: + hidden: false + immutable: false + type: string + description: FE1 IP port in SIGTRAN network + port_name: + hidden: false + immutable: false + type: string + description: port name + default: port_name + point_code_scp: + hidden: false + immutable: false + type: string + description: vSCP point code (in "zone-cluster-member" format) + global_title_stp: + hidden: false + immutable: false + type: string + description: STP Global Title address + point_code_stp1: + hidden: false + immutable: false + type: string + description: STP1 point code (in "zone-cluster-member" format) + point_code_stp2: + hidden: false + immutable: false + type: string + description: STP2 point code (in "zone-cluster-member" format) + node_templates: + server_smp2: + type: org.openecomp.resource.vfc.nodes.heat.smp + properties: + flavor: + get_input: flavor_smp_name + availability_zone: + get_input: availability_zone_0 + image: + get_input: image_smp_name + metadata: + jx_vm_role: smp2 + vnf_id: + get_input: vnf_id + jx_lab_name: + get_input: lab_name + user_data_format: RAW + name: + get_input: smp_name_2 + scheduler_hints: + group: FE_SMP_Affinity + server_smp3: + type: org.openecomp.resource.vfc.nodes.heat.smp + properties: + flavor: + get_input: flavor_smp_name + availability_zone: + get_input: availability_zone_0 + image: + get_input: image_smp_name + metadata: + jx_vm_role: smp2 + vnf_id: + get_input: vnf_id + jx_lab_name: + get_input: lab_name + user_data_format: RAW + name: + get_input: smp_name_2 + scheduler_hints: + group2: Multi_Anti_Affinity + group1: FE_SMP_Affinity + port3: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + network: + get_input: port_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_smp3 + relationship: tosca.relationships.network.BindsTo + port4: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + network: + get_input: port_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_smp3 + relationship: tosca.relationships.network.BindsTo + port1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + network: + get_input: port_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_smp1 + relationship: tosca.relationships.network.BindsTo + server_smp1: + type: org.openecomp.resource.vfc.nodes.heat.smp + properties: + flavor: + get_input: flavor_smp_name + availability_zone: + get_input: availability_zone_0 + image: + get_input: image_smp_name + metadata: + jx_vm_role: smp2 + vnf_id: + get_input: vnf_id + jx_lab_name: + get_input: lab_name + user_data_format: RAW + name: + get_input: smp_name_1 + scheduler_hints: + group: BE_Affinity + port2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + network: + get_input: port_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_smp2 + relationship: tosca.relationships.network.BindsTo + groups: + FE_SMP_Affinity: + type: tosca.groups.Root + members: + - server_smp2 + - server_smp3 + Multi_Anti_Affinity: + type: tosca.groups.Root + members: + - server_smp3 + hot_template: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/hot_template.yml + description: ASC Template + members: + - server_smp2 + - server_smp3 + - port3 + - port4 + - port1 + - server_smp1 + - port2 + BE_Affinity: + type: tosca.groups.Root + members: + - server_smp1 + policies: + FE_SMP_Affinity: + type: org.openecomp.policies.placement.Colocate + properties: + name: abc + affinity: host + targets: + - FE_SMP_Affinity + Multi_Anti_Affinity: + type: org.openecomp.policies.placement.Antilocate + properties: + name: def + container_type: host + targets: + - Multi_Anti_Affinity + BE_Affinity: + type: org.openecomp.policies.placement.Colocate + properties: + name: def + affinity: host + targets: + - BE_Affinity \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novaservergroups/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novaservergroups/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..b2916ccf9c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novaservergroups/inputfiles/MANIFEST.json @@ -0,0 +1,11 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "hot_template.yml", + "type": "HEAT" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novaservergroups/inputfiles/hot_template.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novaservergroups/inputfiles/hot_template.yml new file mode 100644 index 0000000000..8dcbe20043 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novaservergroups/inputfiles/hot_template.yml @@ -0,0 +1,383 @@ +heat_template_version: 2013-05-23 + +description: ASC Template + +parameters: + cluster_type: + type: string + constraints: + - allowed_values: [ Test, Prod ] + fe_connectivity: + type: string + constraints: + - allowed_values: [ NEE, STP ] + key_name: + type: string + description: keypair to enable SSH access to the instance. + default: vSCP-keypair + +# Availability Zone information may need to be updated and the specifications under Nova server capabilities uncommented + availability_zone_0: + type: string + + vnf_name: + type: string + description: Unique name for this VNF instance + default: This_is_the_SCP_name + vnf_id: + type: string + description: Unique ID for this VNF instance + default: This_is_ths_SCP_id + + port_name: + type: string + description: port name + default: port_name + + flavor_scp_be_name: + type: string + description: SCP BE Flavor + default: a1.Small + flavor_scp_fe_name: + type: string + description: SCP FE Flavor + default: a1.Small + flavor_smp_name: + type: string + description: SCP SMP Flavor + default: a1.Small + image_scp_be_name: + type: string + description: SCP BE image + default: asc_base_image_be + image_scp_fe_name: + type: string + description: SCP FE image + default: asc_base_image_fe + image_smp_name: + type: string + description: SCP SMP image + default: asc_base_image_smp + int_vscp_fe_cluster_net_id: + type: string + description: LAN2 FE Cluster/KA + int_vscp_fe_cluster_cidr: + type: string + description: Private Network2 Address (CIDR notation) + int_vscp_cluster_net_id: + type: string + description: LAN3 Cluster + int_vscp_cluster_cidr: + type: string + description: Private Network3 Address (CIDR notation) + int_vscp_ce_network_net_id: + type: string + description: Inter-CE Network + int_vscp_ce_network_cidr: + type: string + description: Private Network Address (CIDR notation) + SIGNET_vrf_A1_direct_net_id: + type: string + description: Network name for SIGTRAN_A + SIGNET_vrf_B1_direct_net_id: + type: string + description: Network name for SIGTRAN_B + Cricket_OCS_protected_net_id: + type: string + description: Network name for CRICKET_OCS + Mobility_OAM_protected_net_id: + type: string + description: Network name for OAM + be_Cricket_OCS_protected_ip_0: + type: string + label: be1 Cricket_OCS ip address + description: be1 Cricket_OCS ip address + be_Cricket_OCS_protected_ip_1: + type: string + label: be2 Cricket_OCS ip address + description: be2 Cricket_OCS ip address + be_Cricket_OCS_protected_ip_2: + type: string + label: be3 Cricket_OCS ip address + description: be3 Cricket_OCS ip address + be_Cricket_OCS_protected_ip_3: + type: string + label: be4 Cricket_OCS ip address + description: be4 Cricket_OCS ip address + be_Cricket_OCS_protected_ip_4: + type: string + label: be5 Cricket_OCS ip address + description: be5 Cricket_OCS ip address + fe_SIGNET_vrf_B1_direct_ip_0: + type: string + label: fe1 SIGTRAN ip address + description: fe1 SIGTRAN ip address + fe_SIGNET_vrf_A1_direct_ip_0: + type: string + label: fe2 SIGTRAN ip address + description: fe2 SIGTRAN ip address + be_Mobility_OAM_protected_ip_0: + type: string + label: be_0 OAM ip address + description: be_0 OAM ip address + be_Mobility_OAM_protected_ip_1: + type: string + label: be_1 OAM ip address + description: be_1 OAM ip address + be_Mobility_OAM_protected_ip_2: + type: string + label: be_2 OAM ip address + description: be_2 OAM ip address + be_Mobility_OAM_protected_ip_3: + type: string + label: be_3 OAM ip address + description: be_3 OAM ip address + be_Mobility_OAM_protected_ip_4: + type: string + label: be_4 OAM ip address + description: be_4 OAM ip address + fe_Mobility_OAM_protected_ip_0: + type: string + label: fe_0 OAM ip address + description: fe_0 OAM ip address + fe_Mobility_OAM_protected_ip_1: + type: string + label: fe_1 OAM ip address + description: fe_1 OAM ip address + smp_Mobility_OAM_protected_ip_0: + type: string + label: smp_0 OAM ip address + description: smp_0 OAM ip address + smp_Mobility_OAM_protected_ip_1: + type: string + label: smp_1 OAM ip address + description: smp_1 OAM ip address + be_name_0: + type: string + default: vSCP_BE1 + description: name of VM + be_name_1: + type: string + default: vSCP_BE2 + description: name of VM + be_name_2: + type: string + default: vSCP_BE3 + description: name of VM + be_name_3: + type: string + default: vSCP_BE4 + description: name of VM + be_name_4: + type: string + default: vSCP_BE5 + description: name of VM + fe_name_0: + type: string + default: vSCP_FE1 + description: name of VM + fe_name_1: + type: string + default: vSCP_FE2 + description: name of VM + smp_name_0: + type: string + default: vSMP1 + description: name of VM + smp_name_1: + type: string + default: vSMP2 + description: name of VM + smp_name_2: + type: string + default: vSMP2 + description: name of VM + ##smp_name_2: + ##type: string + ##default: vSMP2 + ##description: name of VM + nee_name_0: + type: string + default: vNEE + description: name of VM + + hostname_fe1: + type: string + description: FE1 Hostname (from Ulticom license) + hostid_fe1: + type: string + description: FE1 Hostid (from Ulticom license) + + hostname_fe2: + type: string + description: FE2 Hostname (from Ulticom license) + hostid_fe2: + type: string + description: FE2 Hostid (from Ulticom license) + + hostname_nee1: + type: string + description: NEE1 Hostname (from Ulticom license) + hostid_nee1: + type: string + description: NEE1 Hostid (from Ulticom license) + + point_code_scp: + type: string + description: vSCP point code (in "zone-cluster-member" format) + point_code_stp: + type: string + description: STP virtual point code (in "zone-cluster-member" format) + point_code_stp1: + type: string + description: STP1 point code (in "zone-cluster-member" format) + point_code_stp2: + type: string + description: STP2 point code (in "zone-cluster-member" format) + ip_address_stp1: + type: string + description: STP1 IP address + ip_port_stp1: + type: string + description: STP1 IP port + ip_address_stp2: + type: string + description: STP2 IP address + ip_port_stp2: + type: string + description: STP2 IP port + ip_port_fe1: + type: string + description: FE1 IP port in SIGTRAN network + ip_port_fe2: + type: string + description: FE2 IP port in SIGTRAN network + + global_title_scp: + type: string + description: vSCP Global Title address + global_title_stp: + type: string + description: STP Global Title address + + security_group_name: + type: string + label: vSCP security group name + description: vSCP security group name + + route_table_be: + type: string + description: Additional route table for BEs + + route_table_fe1: + type: string + description: Additional route table for FE1 + + route_table_fe2: + type: string + description: Additional route table for FE2 + + ip_address_dra: + type: string + description: DRA VIP address + + lab_name: + type: string + description: Lab name + +resources: + + server_smp1: + type: OS::Nova::Server + properties: + name: { get_param: smp_name_1 } + image: { get_param: image_smp_name } + # key_name: { get_param: key_name } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: flavor_smp_name } + scheduler_hints: { group: { get_resource: BE_Affinity } } + networks: + - port: { get_resource: port1 } + metadata: + vnf_id: { get_param: vnf_id } + jx_lab_name: {get_param: lab_name} + jx_vm_role: smp2 + user_data_format: RAW + server_smp2: + type: OS::Nova::Server + properties: + name: { get_param: smp_name_2 } + image: { get_param: image_smp_name } + # key_name: { get_param: key_name } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: flavor_smp_name } + scheduler_hints: { group: { get_resource: FE_SMP_Affinity } } + networks: + - port: { get_resource: port2 } + metadata: + vnf_id: { get_param: vnf_id } + jx_lab_name: {get_param: lab_name} + jx_vm_role: smp2 + user_data_format: RAW + + server_smp3: + type: OS::Nova::Server + properties: + name: { get_param: smp_name_2 } + image: { get_param: image_smp_name } + # key_name: { get_param: key_name } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: flavor_smp_name } + scheduler_hints: { group1: { get_resource: FE_SMP_Affinity }, group2: { get_resource: Multi_Anti_Affinity } } + networks: + - port: { get_resource: port3 } + - port: { get_resource: port4 } + metadata: + vnf_id: { get_param: vnf_id } + jx_lab_name: {get_param: lab_name} + jx_vm_role: smp2 + user_data_format: RAW + + port1: + type: OS::Neutron::Port + properties: + network: {get_param: port_name} + replacement_policy: AUTO + + port2: + type: OS::Neutron::Port + properties: + network: {get_param: port_name} + replacement_policy: AUTO + + port3: + type: OS::Neutron::Port + properties: + network: {get_param: port_name} + replacement_policy: AUTO + + port4: + type: OS::Neutron::Port + properties: + network: {get_param: port_name} + replacement_policy: AUTO + + FE_SMP_Affinity: + type: OS::Nova::ServerGroup + properties: + policies: ["affinity"] + name: abc + BE_Affinity: + type: OS::Nova::ServerGroup + properties: + policies: ["affinity"] + name: def + Multi_Anti_Affinity: + type: OS::Nova::ServerGroup + properties: + policies: ["anti-affinity"] + name: def + + + + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/innernestedconnection/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/innernestedconnection/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..e77677efb7 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/innernestedconnection/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,187 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.nested: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + cmaui_names: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + cmaui_cinder_volume_size: + type: float + description: the size of the CMAUI Cinder volume + timezone: + type: string + description: timezone + security_group_name: + type: string + description: the name of security group + cmaui_volume: + type: string + description: Volume for CMAUI server + oam_network_netmask: + type: string + description: oam network gateway + cmaui_image: + type: string + description: Image for CMAUI server + vnf_id: + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-CMAUI_id + cmaui_flavor: + type: string + description: Flavor for CMAUI server + oam_network_gateway: + type: string + description: oam network gateway + availability_zone_0: + type: string + description: availabilityzone name + cmaui_oam_ips: + type: list + description: CMAUI oam_net IP addresses + entry_schema: + type: string + inner_cmaui_volume_a1: + type: string + description: the name of the target volume backend + inner_cmaui_volume_b2: + type: string + description: the name of the target volume backend + external_dns: + type: string + description: dns server + oam_net_name: + type: string + description: UID of OAM network + external_ntp: + type: string + description: ntp server + CMAUI_volume_type: + type: string + description: the name of the target volume backend + requirements: + - link_cmaui_port_2: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - local_storage_server_cmaui2: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - local_storage_server_cmaui1: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_cmaui_port_0: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + scalable_server_cmaui1: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + endpoint_server_cmaui1: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + os_server_cmaui1: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + scalable_server_cmaui2: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + endpoint_server_cmaui2: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_2: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + host_server_cmaui1: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + os_server_cmaui2: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + binding_server_cmaui2: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_0: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + host_server_cmaui2: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + binding_server_cmaui1: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/innernestedconnection/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/innernestedconnection/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..4507d8f8b2 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/innernestedconnection/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,194 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + cmaui_cinder_volume_size: + label: CMAUI Cinder volume size + hidden: false + immutable: false + type: float + description: the size of the CMAUI Cinder volume + timezone: + label: timezone + hidden: false + immutable: false + type: string + description: timezone + security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + oam_network_netmask: + label: oam network netmask + hidden: false + immutable: false + type: string + description: oam network gateway + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + vnf_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-CMAUI_id + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + oam_network_gateway: + label: oam network gateway + hidden: false + immutable: false + type: string + description: oam network gateway + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + inner_cmaui_volume_a2: + hidden: false + immutable: false + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-CMAUI_id + inner_cmaui_volume_a1: + hidden: false + immutable: false + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-CMAUI_id + cmaui_oam_ips: + label: CMAUI oam_net IP addresses + hidden: false + immutable: false + type: list + description: CMAUI oam_net IP addresses + entry_schema: + type: string + external_dns: + label: dns server + hidden: false + immutable: false + type: string + description: dns server + oam_net_name: + hidden: false + immutable: false + type: string + description: UID of OAM network + external_ntp: + label: ntp server + hidden: false + immutable: false + type: string + description: ntp server + CMAUI_volume_type: + label: CMAUI vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + node_templates: + stam_nested: + type: org.openecomp.resource.abstract.nodes.heat.nested + directives: + - substitutable + properties: + service_template_filter: + substitute_service_template: nestedServiceTemplate.yaml + inner_cmaui_volume_a1: + get_input: inner_cmaui_volume_a1 + inner_cmaui_volume_b2: + get_input: inner_cmaui_volume_a2 + requirements: + - local_storage_server_cmaui2: + capability: tosca.capabilities.Attachment + node: cmaui_volume2 + relationship: tosca.relationships.AttachesTo + - local_storage_server_cmaui1: + capability: tosca.capabilities.Attachment + node: inner_cmaui_volume_a1 + relationship: tosca.relationships.AttachesTo + - local_storage_server_cmaui1: + capability: tosca.capabilities.Attachment + node: cmaui_volume2 + relationship: tosca.relationships.AttachesTo + inner_cmaui_volume_a1: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: CMAUI_volume_type + size: '(get_input : cmaui_cinder_volume_size) * 1024' + cmaui_volume2: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: CMAUI_volume_type + size: '(get_input : cmaui_cinder_volume_size) * 1024' + groups: + a_vol: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/a_vol.yml + description: volume + members: + - inner_cmaui_volume_a1 + - cmaui_volume2 + main: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/main.yml + description: cmaui server template for vMMSC + members: + - stam_nested + outputs: + inner_cmaui_volume_a2: + value: cmaui_volume2 + inner_cmaui_volume_a1: + value: inner_cmaui_volume_a1 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/innernestedconnection/expectedoutputfiles/nestedServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/innernestedconnection/expectedoutputfiles/nestedServiceTemplate.yaml new file mode 100644 index 0000000000..a9ec66bf29 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/innernestedconnection/expectedoutputfiles/nestedServiceTemplate.yaml @@ -0,0 +1,279 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + cmaui_cinder_volume_size: + label: CMAUI Cinder volume size + hidden: false + immutable: false + type: float + description: the size of the CMAUI Cinder volume + timezone: + label: timezone + hidden: false + immutable: false + type: string + description: timezone + security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + cmaui_volume: + label: CMAUI volume size + hidden: false + immutable: false + type: string + description: Volume for CMAUI server + oam_network_netmask: + label: oam network netmask + hidden: false + immutable: false + type: string + description: oam network gateway + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + vnf_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-CMAUI_id + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + oam_network_gateway: + label: oam network gateway + hidden: false + immutable: false + type: string + description: oam network gateway + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + cmaui_oam_ips: + label: CMAUI oam_net IP addresses + hidden: false + immutable: false + type: list + description: CMAUI oam_net IP addresses + entry_schema: + type: string + inner_cmaui_volume_a1: + label: CMAUI vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + inner_cmaui_volume_b2: + label: CMAUI vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + external_dns: + label: dns server + hidden: false + immutable: false + type: string + description: dns server + oam_net_name: + hidden: false + immutable: false + type: string + description: UID of OAM network + external_ntp: + label: ntp server + hidden: false + immutable: false + type: string + description: ntp server + CMAUI_volume_type: + label: CMAUI vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + node_templates: + cmaui_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui2 + relationship: tosca.relationships.network.BindsTo + server_cmaui2: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + metadata: + vnf_id: + get_input: vnf_id + user_data_format: RAW + name: + get_input: + - cmaui_names + - 0 + server_cmaui1: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + metadata: + vnf_id: + get_input: vnf_id + user_data_format: RAW + name: + get_input: + - cmaui_names + - 0 + cmaui_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui1 + relationship: tosca.relationships.network.BindsTo + groups: + nested: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested.yml + description: cmaui server template for vMMSC + members: + - cmaui_port_2 + - server_cmaui2 + - server_cmaui1 + - cmaui_port_0 + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested + capabilities: + scalable_server_cmaui1: + - server_cmaui1 + - scalable + endpoint_server_cmaui1: + - server_cmaui1 + - endpoint + os_server_cmaui1: + - server_cmaui1 + - os + scalable_server_cmaui2: + - server_cmaui2 + - scalable + endpoint_server_cmaui2: + - server_cmaui2 + - endpoint + attachment_cmaui_port_2: + - cmaui_port_2 + - attachment + host_server_cmaui1: + - server_cmaui1 + - host + os_server_cmaui2: + - server_cmaui2 + - os + binding_server_cmaui2: + - server_cmaui2 + - binding + attachment_cmaui_port_0: + - cmaui_port_0 + - attachment + host_server_cmaui2: + - server_cmaui2 + - host + binding_server_cmaui1: + - server_cmaui1 + - binding + requirements: + link_cmaui_port_0: + - cmaui_port_0 + - link + link_cmaui_port_2: + - cmaui_port_2 + - link + local_storage_server_cmaui2: + - server_cmaui2 + - local_storage + local_storage_server_cmaui1: + - server_cmaui1 + - local_storage \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/innernestedconnection/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/innernestedconnection/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..0aa103e5b8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/innernestedconnection/inputfiles/MANIFEST.json @@ -0,0 +1,24 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "nested.yml", + "type": "HEAT", + "isBase": "false" + }, + { + "file": "main.yml", + "type": "HEAT", + "isBase": "false", + "data":[ + { + "file": "a_vol.yml", + "type": "HEAT_VOL", + "isBase": "false" + } + ] + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/innernestedconnection/inputfiles/a_vol.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/innernestedconnection/inputfiles/a_vol.yml new file mode 100644 index 0000000000..df5be20848 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/innernestedconnection/inputfiles/a_vol.yml @@ -0,0 +1,32 @@ +heat_template_version: 2013-05-23 + +description: volume + +parameters: + cmaui_cinder_volume_size: + type: number + label: CMAUI Cinder volume size + description: the size of the CMAUI Cinder volume + CMAUI_volume_type: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + +resources: + inner_cmaui_volume_a1: + type: OS::Cinder::Volume + properties: + size: {get_param: cmaui_cinder_volume_size} + volume_type: {get_param: CMAUI_volume_type} + + cmaui_volume2: + type: OS::Cinder::Volume + properties: + size: {get_param: cmaui_cinder_volume_size} + volume_type: {get_param: CMAUI_volume_type} + +outputs: + inner_cmaui_volume_a1: + value: {get_resource: inner_cmaui_volume_a1} + inner_cmaui_volume_a2: + value: {get_resource: cmaui_volume2} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/innernestedconnection/inputfiles/main.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/innernestedconnection/inputfiles/main.yml new file mode 100644 index 0000000000..7994b332df --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/innernestedconnection/inputfiles/main.yml @@ -0,0 +1,77 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + vnf_id: + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-CMAUI_id + inner_cmaui_volume_a1: + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-CMAUI_id + inner_cmaui_volume_a2: + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-CMAUI_id + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_cinder_volume_size: + type: number + label: CMAUI Cinder volume size + description: the size of the CMAUI Cinder volume + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + oam_net_name: + type: string + description: UID of OAM network + oam_network_netmask: + type: string + label: oam network netmask + description: oam network gateway + oam_network_gateway: + type: string + label: oam network gateway + description: oam network gateway + external_dns: + type: string + label: dns server + description: dns server + external_ntp: + type: string + label: ntp server + description: ntp server + security_group_name: + type: string + label: security group name + description: the name of security group + timezone: + type: string + label: timezone + description: timezone + cmaui_oam_ips: + type: comma_delimited_list + label: CMAUI oam_net IP addresses + description: CMAUI oam_net IP addresses + CMAUI_volume_type: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + +resources: + + stam_nested: + type: nested.yml + properties: + inner_cmaui_volume_a1: { get_param: inner_cmaui_volume_a1} + inner_cmaui_volume_b2: { get_param: inner_cmaui_volume_a2} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/innernestedconnection/inputfiles/nested.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/innernestedconnection/inputfiles/nested.yml new file mode 100644 index 0000000000..078b228d29 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/innernestedconnection/inputfiles/nested.yml @@ -0,0 +1,170 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + vnf_id: + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-CMAUI_id + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_volume: + type: string + label: CMAUI volume size + description: Volume for CMAUI server + cmaui_cinder_volume_size: + type: number + label: CMAUI Cinder volume size + description: the size of the CMAUI Cinder volume + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + oam_net_name: + type: string + description: UID of OAM network + oam_network_netmask: + type: string + label: oam network netmask + description: oam network gateway + oam_network_gateway: + type: string + label: oam network gateway + description: oam network gateway + external_dns: + type: string + label: dns server + description: dns server + external_ntp: + type: string + label: ntp server + description: ntp server + security_group_name: + type: string + label: security group name + description: the name of security group + timezone: + type: string + label: timezone + description: timezone + cmaui_oam_ips: + type: comma_delimited_list + label: CMAUI oam_net IP addresses + description: CMAUI oam_net IP addresses + CMAUI_volume_type: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + inner_cmaui_volume_a1: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + inner_cmaui_volume_b2: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + +resources: + + cmaui_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + cmaui_port_2: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + cmaui_volume_attachment1: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_param: inner_cmaui_volume_a1} + instance_uuid: {get_resource: server_cmaui1} + + cmaui_volume_attachment2: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_param: inner_cmaui_volume_b2} + instance_uuid: {get_resource: server_cmaui1} + + cmaui_volume_attachment3: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_param: inner_cmaui_volume_b2} + instance_uuid: {get_resource: server_cmaui2} + + server_cmaui1: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_0 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + cmaui.mgmt.ip=${cmaui.mgmt.ip} + cmaui.mgmt.netmask=${cmaui.mgmt.netmask} + cmaui.mgmt.gateway=${cmaui.mgmt.gateway} + cmaui.external.dns=${cmaui.external.dns} + cmaui.external.ntp=${cmaui.external.ntp} + cmaui.node=${cmaui.node} + cmaui.timezone=${cmaui.timezone} + params: + ${cmaui.mgmt.ip}: {get_param: [cmaui_oam_ips, 0]} + ${cmaui.mgmt.netmask}: {get_param: oam_network_netmask} + ${cmaui.mgmt.gateway}: {get_param: oam_network_gateway} + ${cmaui.external.dns}: {get_param: external_dns} + ${cmaui.external.ntp}: {get_param: external_ntp} + ${cmaui.node}: {get_param: [cmaui_names, 0]} + ${cmaui.timezone}: {get_param: timezone} + user_data_format: RAW + + server_cmaui2: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + cmaui.mgmt.ip=${cmaui.mgmt.ip} + cmaui.mgmt.netmask=${cmaui.mgmt.netmask} + cmaui.mgmt.gateway=${cmaui.mgmt.gateway} + cmaui.external.dns=${cmaui.external.dns} + cmaui.external.ntp=${cmaui.external.ntp} + cmaui.node=${cmaui.node} + cmaui.timezone=${cmaui.timezone} + params: + ${cmaui.mgmt.ip}: {get_param: [cmaui_oam_ips, 0]} + ${cmaui.mgmt.netmask}: {get_param: oam_network_netmask} + ${cmaui.mgmt.gateway}: {get_param: oam_network_gateway} + ${cmaui.external.dns}: {get_param: external_dns} + ${cmaui.external.ntp}: {get_param: external_ntp} + ${cmaui.node}: {get_param: [cmaui_names, 0]} + ${cmaui.timezone}: {get_param: timezone} + user_data_format: RAW \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/multiconnection/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/multiconnection/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..dc3e231da4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/multiconnection/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,276 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + cmaui_cinder_volume_size: + label: CMAUI Cinder volume size + hidden: false + immutable: false + type: float + description: the size of the CMAUI Cinder volume + timezone: + label: timezone + hidden: false + immutable: false + type: string + description: timezone + security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + cmaui_volume: + label: CMAUI vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + oam_network_netmask: + label: oam network netmask + hidden: false + immutable: false + type: string + description: oam network gateway + cmaui_volume_param1: + hidden: false + immutable: false + type: string + description: nova server id + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + vnf_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-CMAUI_id + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + oam_network_gateway: + label: oam network gateway + hidden: false + immutable: false + type: string + description: oam network gateway + cmaui_volume_param2: + hidden: false + immutable: false + type: string + description: nova server id + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + cmaui_oam_ips: + label: CMAUI oam_net IP addresses + hidden: false + immutable: false + type: list + description: CMAUI oam_net IP addresses + entry_schema: + type: string + external_dns: + label: dns server + hidden: false + immutable: false + type: string + description: dns server + oam_net_name: + hidden: false + immutable: false + type: string + description: UID of OAM network + CMAUI_volume_type: + label: CMAUI vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + external_ntp: + label: ntp server + hidden: false + immutable: false + type: string + description: ntp server + node_templates: + cmaui_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui2 + relationship: tosca.relationships.network.BindsTo + server_cmaui2: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + metadata: + vnf_id: + get_input: vnf_id + user_data_format: RAW + name: + get_input: + - cmaui_names + - 0 + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: cmaui_volume2 + relationship: cmaui_volume_attachment3 + server_cmaui1: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + metadata: + vnf_id: + get_input: vnf_id + user_data_format: RAW + name: + get_input: + - cmaui_names + - 0 + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: cmaui_volume1 + relationship: cmaui_volume_attachment1 + - local_storage: + capability: tosca.capabilities.Attachment + node: cmaui_volume2 + relationship: cmaui_volume_attachment2 + cmaui_volume1: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: CMAUI_volume_type + size: '(get_input : cmaui_cinder_volume_size) * 1024' + cmaui_volume2: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: CMAUI_volume_type + size: '(get_input : cmaui_cinder_volume_size) * 1024' + cmaui_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui1 + relationship: tosca.relationships.network.BindsTo + relationship_templates: + cmaui_volume_attachment2: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: + get_input: cmaui_volume_param2 + instance_uuid: server_cmaui1 + cmaui_volume_attachment3: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: + get_input: cmaui_volume_param2 + instance_uuid: server_cmaui2 + cmaui_volume_attachment1: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: + get_input: cmaui_volume_param1 + instance_uuid: server_cmaui1 + groups: + addOn: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/addOn.yml + description: cmaui server template for vMMSC + members: + - cmaui_port_2 + - server_cmaui2 + - server_cmaui1 + - cmaui_port_1 + main: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/main.yml + description: volume + members: + - cmaui_volume1 + - cmaui_volume2 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/multiconnection/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/multiconnection/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..1f762d0ccc --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/multiconnection/inputfiles/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "main.yml", + "type": "HEAT", + "isBase": "true" + }, + { + "file": "addOn.yml", + "type": "HEAT", + "isBase": "false" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/multiconnection/inputfiles/addOn.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/multiconnection/inputfiles/addOn.yml new file mode 100644 index 0000000000..1083268acf --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/multiconnection/inputfiles/addOn.yml @@ -0,0 +1,168 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + cmaui_volume_param1: + type: string + description: nova server id + cmaui_volume_param2: + type: string + description: nova server id + vnf_id: + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-CMAUI_id + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_cinder_volume_size: + type: number + label: CMAUI Cinder volume size + description: the size of the CMAUI Cinder volume + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + oam_net_name: + type: string + description: UID of OAM network + oam_network_netmask: + type: string + label: oam network netmask + description: oam network gateway + oam_network_gateway: + type: string + label: oam network gateway + description: oam network gateway + external_dns: + type: string + label: dns server + description: dns server + external_ntp: + type: string + label: ntp server + description: ntp server + security_group_name: + type: string + label: security group name + description: the name of security group + timezone: + type: string + label: timezone + description: timezone + cmaui_oam_ips: + type: comma_delimited_list + label: CMAUI oam_net IP addresses + description: CMAUI oam_net IP addresses + CMAUI_volume_type: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + cmaui_volume: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + +resources: + + cmaui_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + cmaui_port_2: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + cmaui_volume_attachment1: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_param: cmaui_volume_param1} + instance_uuid: {get_resource: server_cmaui1} + + cmaui_volume_attachment2: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_param: cmaui_volume_param2} + instance_uuid: {get_resource: server_cmaui1} + + cmaui_volume_attachment3: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_param: cmaui_volume_param2} + instance_uuid: {get_resource: server_cmaui2} + + server_cmaui1: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_1 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + cmaui.mgmt.ip=${cmaui.mgmt.ip} + cmaui.mgmt.netmask=${cmaui.mgmt.netmask} + cmaui.mgmt.gateway=${cmaui.mgmt.gateway} + cmaui.external.dns=${cmaui.external.dns} + cmaui.external.ntp=${cmaui.external.ntp} + cmaui.node=${cmaui.node} + cmaui.timezone=${cmaui.timezone} + params: + ${cmaui.mgmt.ip}: {get_param: [cmaui_oam_ips, 0]} + ${cmaui.mgmt.netmask}: {get_param: oam_network_netmask} + ${cmaui.mgmt.gateway}: {get_param: oam_network_gateway} + ${cmaui.external.dns}: {get_param: external_dns} + ${cmaui.external.ntp}: {get_param: external_ntp} + ${cmaui.node}: {get_param: [cmaui_names, 0]} + ${cmaui.timezone}: {get_param: timezone} + user_data_format: RAW + + server_cmaui2: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + cmaui.mgmt.ip=${cmaui.mgmt.ip} + cmaui.mgmt.netmask=${cmaui.mgmt.netmask} + cmaui.mgmt.gateway=${cmaui.mgmt.gateway} + cmaui.external.dns=${cmaui.external.dns} + cmaui.external.ntp=${cmaui.external.ntp} + cmaui.node=${cmaui.node} + cmaui.timezone=${cmaui.timezone} + params: + ${cmaui.mgmt.ip}: {get_param: [cmaui_oam_ips, 0]} + ${cmaui.mgmt.netmask}: {get_param: oam_network_netmask} + ${cmaui.mgmt.gateway}: {get_param: oam_network_gateway} + ${cmaui.external.dns}: {get_param: external_dns} + ${cmaui.external.ntp}: {get_param: external_ntp} + ${cmaui.node}: {get_param: [cmaui_names, 0]} + ${cmaui.timezone}: {get_param: timezone} + user_data_format: RAW \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/multiconnection/inputfiles/main.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/multiconnection/inputfiles/main.yml new file mode 100644 index 0000000000..89734ad14b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/multiconnection/inputfiles/main.yml @@ -0,0 +1,31 @@ +heat_template_version: 2013-05-23 + +description: volume + +parameters: + cmaui_cinder_volume_size: + type: number + label: CMAUI Cinder volume size + description: the size of the CMAUI Cinder volume + CMAUI_volume_type: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + +resources: + cmaui_volume1: + type: OS::Cinder::Volume + properties: + size: {get_param: cmaui_cinder_volume_size} + volume_type: {get_param: CMAUI_volume_type} + cmaui_volume2: + type: OS::Cinder::Volume + properties: + size: {get_param: cmaui_cinder_volume_size} + volume_type: {get_param: CMAUI_volume_type} + +outputs: + cmaui_volume_param1: + value: {get_resource: cmaui_volume1} + cmaui_volume_param2: + value: {get_resource: cmaui_volume2} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/multinotconnected/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/multinotconnected/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..0d723c6e6f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/multinotconnected/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,314 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + availability_zone_10: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + cmaui_cinder_volume_size: + label: CMAUI Cinder volume size + hidden: false + immutable: false + type: float + description: the size of the CMAUI Cinder volume + timezone: + label: timezone + hidden: false + immutable: false + type: string + description: timezone + security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + cmaui_volume: + label: CMAUI vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + oam_network_netmask: + label: oam network netmask + hidden: false + immutable: false + type: string + description: oam network gateway + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + cmaui_volume_param1: + hidden: false + immutable: false + type: string + description: nova server id + vnf_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-CMAUI_id + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + oam_network_gateway: + label: oam network gateway + hidden: false + immutable: false + type: string + description: oam network gateway + cmaui_volume_param2: + hidden: false + immutable: false + type: string + description: nova server id + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + cmaui_oam_ips: + label: CMAUI oam_net IP addresses + hidden: false + immutable: false + type: list + description: CMAUI oam_net IP addresses + entry_schema: + type: string + external_dns: + label: dns server + hidden: false + immutable: false + type: string + description: dns server + server_cmaui21: + hidden: false + immutable: false + type: string + description: nova server id + oam_net_name: + hidden: false + immutable: false + type: string + description: UID of OAM network + CMAUI_volume_type: + label: CMAUI vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + external_ntp: + label: ntp server + hidden: false + immutable: false + type: string + description: ntp server + node_templates: + cmaui_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui2 + relationship: tosca.relationships.network.BindsTo + cmaui_port_11: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui21 + relationship: tosca.relationships.network.BindsTo + server_cmaui2: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + metadata: + vnf_id: + get_input: vnf_id + user_data_format: RAW + name: + get_input: + - cmaui_names + - 0 + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: cmaui_volume2 + relationship: cmaui_volume_attachment3 + server_cmaui1: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + metadata: + vnf_id: + get_input: vnf_id + user_data_format: RAW + name: + get_input: + - cmaui_names + - 0 + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: cmaui_volume2 + relationship: cmaui_volume_attachment2 + cmaui_volume1: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: CMAUI_volume_type + size: '(get_input : cmaui_cinder_volume_size) * 1024' + server_cmaui21: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_10 + image: + get_input: cmaui_image + metadata: + vnf_id: + get_input: vnf_id + user_data_format: RAW + name: + get_input: + - cmaui_names + - 0 + cmaui_volume2: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: CMAUI_volume_type + size: '(get_input : cmaui_cinder_volume_size) * 1024' + cmaui_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui1 + relationship: tosca.relationships.network.BindsTo + relationship_templates: + cmaui_volume_attachment2: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: + get_input: cmaui_volume_param2 + instance_uuid: server_cmaui1 + cmaui_volume_attachment3: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: + get_input: cmaui_volume_param2 + instance_uuid: server_cmaui2 + groups: + addOn: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/addOn.yml + description: cmaui server template for vMMSC + members: + - cmaui_port_2 + - server_cmaui2 + - server_cmaui1 + - cmaui_port_1 + main: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/main.yml + description: volume + members: + - cmaui_port_11 + - cmaui_volume1 + - server_cmaui21 + - cmaui_volume2 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/multinotconnected/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/multinotconnected/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..1f762d0ccc --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/multinotconnected/inputfiles/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "main.yml", + "type": "HEAT", + "isBase": "true" + }, + { + "file": "addOn.yml", + "type": "HEAT", + "isBase": "false" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/multinotconnected/inputfiles/addOn.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/multinotconnected/inputfiles/addOn.yml new file mode 100644 index 0000000000..9716dc2f20 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/multinotconnected/inputfiles/addOn.yml @@ -0,0 +1,171 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + cmaui_volume_param1: + type: string + description: nova server id + server_cmaui21: + type: string + description: nova server id + cmaui_volume_param2: + type: string + description: nova server id + vnf_id: + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-CMAUI_id + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_cinder_volume_size: + type: number + label: CMAUI Cinder volume size + description: the size of the CMAUI Cinder volume + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + oam_net_name: + type: string + description: UID of OAM network + oam_network_netmask: + type: string + label: oam network netmask + description: oam network gateway + oam_network_gateway: + type: string + label: oam network gateway + description: oam network gateway + external_dns: + type: string + label: dns server + description: dns server + external_ntp: + type: string + label: ntp server + description: ntp server + security_group_name: + type: string + label: security group name + description: the name of security group + timezone: + type: string + label: timezone + description: timezone + cmaui_oam_ips: + type: comma_delimited_list + label: CMAUI oam_net IP addresses + description: CMAUI oam_net IP addresses + CMAUI_volume_type: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + cmaui_volume: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + +resources: + + cmaui_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + cmaui_port_2: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + cmaui_volume_attachment1: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_param: server_cmaui21} + instance_uuid: {get_resource: server_cmaui1} + + cmaui_volume_attachment2: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_param: cmaui_volume_param2} + instance_uuid: {get_resource: server_cmaui1} + + cmaui_volume_attachment3: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_param: cmaui_volume_param2} + instance_uuid: {get_resource: server_cmaui2} + + server_cmaui1: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_1 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + cmaui.mgmt.ip=${cmaui.mgmt.ip} + cmaui.mgmt.netmask=${cmaui.mgmt.netmask} + cmaui.mgmt.gateway=${cmaui.mgmt.gateway} + cmaui.external.dns=${cmaui.external.dns} + cmaui.external.ntp=${cmaui.external.ntp} + cmaui.node=${cmaui.node} + cmaui.timezone=${cmaui.timezone} + params: + ${cmaui.mgmt.ip}: {get_param: [cmaui_oam_ips, 0]} + ${cmaui.mgmt.netmask}: {get_param: oam_network_netmask} + ${cmaui.mgmt.gateway}: {get_param: oam_network_gateway} + ${cmaui.external.dns}: {get_param: external_dns} + ${cmaui.external.ntp}: {get_param: external_ntp} + ${cmaui.node}: {get_param: [cmaui_names, 0]} + ${cmaui.timezone}: {get_param: timezone} + user_data_format: RAW + + server_cmaui2: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_2 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + cmaui.mgmt.ip=${cmaui.mgmt.ip} + cmaui.mgmt.netmask=${cmaui.mgmt.netmask} + cmaui.mgmt.gateway=${cmaui.mgmt.gateway} + cmaui.external.dns=${cmaui.external.dns} + cmaui.external.ntp=${cmaui.external.ntp} + cmaui.node=${cmaui.node} + cmaui.timezone=${cmaui.timezone} + params: + ${cmaui.mgmt.ip}: {get_param: [cmaui_oam_ips, 0]} + ${cmaui.mgmt.netmask}: {get_param: oam_network_netmask} + ${cmaui.mgmt.gateway}: {get_param: oam_network_gateway} + ${cmaui.external.dns}: {get_param: external_dns} + ${cmaui.external.ntp}: {get_param: external_ntp} + ${cmaui.node}: {get_param: [cmaui_names, 0]} + ${cmaui.timezone}: {get_param: timezone} + user_data_format: RAW \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/multinotconnected/inputfiles/main.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/multinotconnected/inputfiles/main.yml new file mode 100644 index 0000000000..d81d9d8aed --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/multinotconnected/inputfiles/main.yml @@ -0,0 +1,128 @@ +heat_template_version: 2013-05-23 + +description: volume + +parameters: + availability_zone_10: + type: string + label: availabilityzone name + description: availabilityzone name + cmaui_cinder_volume_size: + type: number + label: CMAUI Cinder volume size + description: the size of the CMAUI Cinder volume + CMAUI_volume_type: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + vnf_id: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + oam_net_name: + type: string + description: UID of OAM network + oam_network_netmask: + type: string + label: oam network netmask + description: oam network gateway + oam_network_gateway: + type: string + label: oam network gateway + description: oam network gateway + external_dns: + type: string + label: dns server + description: dns server + external_ntp: + type: string + label: ntp server + description: ntp server + security_group_name: + type: string + label: security group name + description: the name of security group + timezone: + type: string + label: timezone + description: timezone + cmaui_oam_ips: + type: comma_delimited_list + label: CMAUI oam_net IP addresses + description: CMAUI oam_net IP addresses + cmaui_volume: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + +resources: + cmaui_volume1: + type: OS::Cinder::Volume + properties: + size: {get_param: cmaui_cinder_volume_size} + volume_type: {get_param: CMAUI_volume_type} + cmaui_volume2: + type: OS::Cinder::Volume + properties: + size: {get_param: cmaui_cinder_volume_size} + volume_type: {get_param: CMAUI_volume_type} + + server_cmaui21: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_10 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_11 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + cmaui.mgmt.ip=${cmaui.mgmt.ip} + cmaui.mgmt.netmask=${cmaui.mgmt.netmask} + cmaui.mgmt.gateway=${cmaui.mgmt.gateway} + cmaui.external.dns=${cmaui.external.dns} + cmaui.external.ntp=${cmaui.external.ntp} + cmaui.node=${cmaui.node} + cmaui.timezone=${cmaui.timezone} + params: + ${cmaui.mgmt.ip}: {get_param: [cmaui_oam_ips, 0]} + ${cmaui.mgmt.netmask}: {get_param: oam_network_netmask} + ${cmaui.mgmt.gateway}: {get_param: oam_network_gateway} + ${cmaui.external.dns}: {get_param: external_dns} + ${cmaui.external.ntp}: {get_param: external_ntp} + ${cmaui.node}: {get_param: [cmaui_names, 0]} + ${cmaui.timezone}: {get_param: timezone} + user_data_format: RAW + + cmaui_port_11: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + +outputs: + cmaui_volume_param1: + value: {get_resource: cmaui_volume1} + cmaui_volume_param2: + value: {get_resource: cmaui_volume2} + cmaui_volume_param3: + value: {get_resource: server_cmaui21} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestedconnection/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestedconnection/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..889961bd45 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestedconnection/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,109 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.nested: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + cmaui_names: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p1: + type: string + description: UID of OAM network + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_volume_param: + type: string + description: nova server id + cmaui_flavor: + type: string + description: Flavor for CMAUI server + security_group_name: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + availability_zone_0: + type: string + description: availabilityzone name + cmaui_oam_ips: + type: string + requirements: + - local_storage_server_cmaui: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_cmaui_port_0: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + host_server_cmaui: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + os_server_cmaui: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + endpoint_server_cmaui: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + binding_server_cmaui: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + scalable_server_cmaui: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_0: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestedconnection/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestedconnection/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..2b09784a72 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestedconnection/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,76 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + cmaui_cinder_volume_size: + label: CMAUI Cinder volume size + hidden: false + immutable: false + type: float + description: the size of the CMAUI Cinder volume + CMAUI_volume_type: + label: CMAUI vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + node_templates: + test_vol: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: CMAUI_volume_type + size: '(get_input : cmaui_cinder_volume_size) * 1024' + test_nested: + type: org.openecomp.resource.abstract.nodes.heat.nested + directives: + - substitutable + properties: + service_template_filter: + substitute_service_template: nestedServiceTemplate.yaml + cmaui_volume_param: test_vol + requirements: + - local_storage_server_cmaui: + capability: tosca.capabilities.Attachment + node: test_vol + relationship: tosca.relationships.AttachesTo + groups: + main: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/main.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - test_vol + - test_nested \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestedconnection/expectedoutputfiles/nestedServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestedconnection/expectedoutputfiles/nestedServiceTemplate.yaml new file mode 100644 index 0000000000..485e7031b4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestedconnection/expectedoutputfiles/nestedServiceTemplate.yaml @@ -0,0 +1,150 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p1: + hidden: false + immutable: false + type: string + description: UID of OAM network + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + cmaui_volume_param: + hidden: false + immutable: false + type: string + description: nova server id + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + cmaui_oam_ips: + hidden: false + immutable: false + type: string + node_templates: + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + name: + get_input: + - cmaui_names + - 0 + cmaui_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: p1 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + groups: + nested: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested.yml + description: cmaui server template for vMMSC + members: + - server_cmaui + - cmaui_port_0 + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested + capabilities: + host_server_cmaui: + - server_cmaui + - host + os_server_cmaui: + - server_cmaui + - os + endpoint_server_cmaui: + - server_cmaui + - endpoint + binding_server_cmaui: + - server_cmaui + - binding + scalable_server_cmaui: + - server_cmaui + - scalable + attachment_cmaui_port_0: + - cmaui_port_0 + - attachment + requirements: + local_storage_server_cmaui: + - server_cmaui + - local_storage + link_cmaui_port_0: + - cmaui_port_0 + - link \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestedconnection/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestedconnection/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..aca75b5055 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestedconnection/inputfiles/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "main.yml", + "type": "HEAT", + "isBase": "true" + }, + { + "file": "nested.yml", + "type": "HEAT", + "isBase": "false" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestedconnection/inputfiles/main.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestedconnection/inputfiles/main.yml new file mode 100644 index 0000000000..b016f53d5b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestedconnection/inputfiles/main.yml @@ -0,0 +1,26 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + cmaui_cinder_volume_size: + type: number + label: CMAUI Cinder volume size + description: the size of the CMAUI Cinder volume + CMAUI_volume_type: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + +resources: + test_vol: + type: OS::Cinder::Volume + properties: + size: {get_param: cmaui_cinder_volume_size} + volume_type: {get_param: CMAUI_volume_type} + + test_nested: + type: nested.yml + properties: + cmaui_volume_param: { get_resource: test_vol} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestedconnection/inputfiles/nested.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestedconnection/inputfiles/nested.yml new file mode 100644 index 0000000000..922c4d1613 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestedconnection/inputfiles/nested.yml @@ -0,0 +1,55 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + cmaui_volume_param: + type: string + description: nova server id + p1: + type: string + description: UID of OAM network + security_group_name: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_oam_ips: + type: string + +resources: + + cmaui_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: p1 } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_cmaui: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_0 } + + cmaui_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_param: cmaui_volume_param} + instance_uuid: {get_resource: server_cmaui} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestednotconnected/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestednotconnected/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..889961bd45 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestednotconnected/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,109 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.nested: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + cmaui_names: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p1: + type: string + description: UID of OAM network + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_volume_param: + type: string + description: nova server id + cmaui_flavor: + type: string + description: Flavor for CMAUI server + security_group_name: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + availability_zone_0: + type: string + description: availabilityzone name + cmaui_oam_ips: + type: string + requirements: + - local_storage_server_cmaui: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_cmaui_port_0: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + host_server_cmaui: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + os_server_cmaui: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + endpoint_server_cmaui: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + binding_server_cmaui: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + scalable_server_cmaui: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_0: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestednotconnected/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestednotconnected/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..9722ae1b16 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestednotconnected/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,146 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p1: + hidden: false + immutable: false + type: string + description: UID of OAM network + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + cmaui_cinder_volume_size: + label: CMAUI Cinder volume size + hidden: false + immutable: false + type: float + description: the size of the CMAUI Cinder volume + security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + cmaui_oam_ips: + hidden: false + immutable: false + type: string + CMAUI_volume_type: + label: CMAUI vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + node_templates: + server_cmaui1: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + name: + get_input: + - cmaui_names + - 0 + test_vol: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: CMAUI_volume_type + size: '(get_input : cmaui_cinder_volume_size) * 1024' + cmaui_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: p1 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui1 + relationship: tosca.relationships.network.BindsTo + test_nested: + type: org.openecomp.resource.abstract.nodes.heat.nested + directives: + - substitutable + properties: + service_template_filter: + substitute_service_template: nestedServiceTemplate.yaml + cmaui_volume_param: server_cmaui1 + groups: + main: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/main.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - server_cmaui1 + - test_vol + - cmaui_port_1 + - test_nested \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestednotconnected/expectedoutputfiles/nestedServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestednotconnected/expectedoutputfiles/nestedServiceTemplate.yaml new file mode 100644 index 0000000000..485e7031b4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestednotconnected/expectedoutputfiles/nestedServiceTemplate.yaml @@ -0,0 +1,150 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p1: + hidden: false + immutable: false + type: string + description: UID of OAM network + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + cmaui_volume_param: + hidden: false + immutable: false + type: string + description: nova server id + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + cmaui_oam_ips: + hidden: false + immutable: false + type: string + node_templates: + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + name: + get_input: + - cmaui_names + - 0 + cmaui_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: p1 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + groups: + nested: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested.yml + description: cmaui server template for vMMSC + members: + - server_cmaui + - cmaui_port_0 + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested + capabilities: + host_server_cmaui: + - server_cmaui + - host + os_server_cmaui: + - server_cmaui + - os + endpoint_server_cmaui: + - server_cmaui + - endpoint + binding_server_cmaui: + - server_cmaui + - binding + scalable_server_cmaui: + - server_cmaui + - scalable + attachment_cmaui_port_0: + - cmaui_port_0 + - attachment + requirements: + local_storage_server_cmaui: + - server_cmaui + - local_storage + link_cmaui_port_0: + - cmaui_port_0 + - link \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestednotconnected/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestednotconnected/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..aca75b5055 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestednotconnected/inputfiles/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "main.yml", + "type": "HEAT", + "isBase": "true" + }, + { + "file": "nested.yml", + "type": "HEAT", + "isBase": "false" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestednotconnected/inputfiles/main.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestednotconnected/inputfiles/main.yml new file mode 100644 index 0000000000..46c2d64d8e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestednotconnected/inputfiles/main.yml @@ -0,0 +1,64 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + cmaui_cinder_volume_size: + type: number + label: CMAUI Cinder volume size + description: the size of the CMAUI Cinder volume + CMAUI_volume_type: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + security_group_name: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_oam_ips: + type: string + p1: + type: string + description: UID of OAM network + +resources: + test_vol: + type: OS::Cinder::Volume + properties: + size: {get_param: cmaui_cinder_volume_size} + volume_type: {get_param: CMAUI_volume_type} + cmaui_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: p1 } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_cmaui1: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_1 } + + test_nested: + type: nested.yml + properties: + cmaui_volume_param: { get_resource: server_cmaui1} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestednotconnected/inputfiles/nested.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestednotconnected/inputfiles/nested.yml new file mode 100644 index 0000000000..922c4d1613 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/nestednotconnected/inputfiles/nested.yml @@ -0,0 +1,55 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + cmaui_volume_param: + type: string + description: nova server id + p1: + type: string + description: UID of OAM network + security_group_name: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_oam_ips: + type: string + +resources: + + cmaui_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: p1 } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_cmaui: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_0 } + + cmaui_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_param: cmaui_volume_param} + instance_uuid: {get_resource: server_cmaui} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestedconnection/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestedconnection/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..fd5eae6858 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestedconnection/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,158 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.nested: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + cmaui_names: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p1: + type: string + description: UID of OAM network + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_volume_param2: + type: string + description: nova server id + security_group_name: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + availability_zone_0: + type: string + description: availabilityzone name + shared_vol1: + type: string + description: nova server id + cmaui_oam_ips: + type: string + requirements: + - link_cmaui_port_2: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - local_storage_server_cmaui2: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - local_storage_server_cmaui1: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_cmaui_port_1: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + scalable_server_cmaui1: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + endpoint_server_cmaui1: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + os_server_cmaui1: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + scalable_server_cmaui2: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + endpoint_server_cmaui2: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_2: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + host_server_cmaui1: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + os_server_cmaui2: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + binding_server_cmaui2: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + host_server_cmaui2: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + binding_server_cmaui1: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_1: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestedconnection/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestedconnection/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..383ef54a4e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestedconnection/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,114 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + cmaui_cinder_volume_size: + label: CMAUI Cinder volume size + hidden: false + immutable: false + type: float + description: the size of the CMAUI Cinder volume + shared_vol1: + hidden: false + immutable: false + type: string + description: volume name + shared_vol2: + hidden: false + immutable: false + type: string + description: volume name + CMAUI_volume_type: + label: CMAUI vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + node_templates: + test_vol1: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: CMAUI_volume_type + size: '(get_input : cmaui_cinder_volume_size) * 1024' + test_vol2: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: CMAUI_volume_type + size: '(get_input : cmaui_cinder_volume_size) * 1024' + test_nested: + type: org.openecomp.resource.abstract.nodes.heat.nested + directives: + - substitutable + properties: + service_template_filter: + substitute_service_template: nestedServiceTemplate.yaml + cmaui_volume_param2: + get_input: shared_vol2 + shared_vol1: + get_input: shared_vol1 + requirements: + - local_storage_server_cmaui2: + capability: tosca.capabilities.Attachment + node: test_vol1 + relationship: tosca.relationships.AttachesTo + - local_storage_server_cmaui1: + capability: tosca.capabilities.Attachment + node: test_vol1 + relationship: tosca.relationships.AttachesTo + - local_storage_server_cmaui1: + capability: tosca.capabilities.Attachment + node: test_vol2 + relationship: tosca.relationships.AttachesTo + groups: + addOn: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/addOn.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - test_nested + main: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/main.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - test_vol1 + - test_vol2 + outputs: + out1_not_shared: + value: test_nested \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestedconnection/expectedoutputfiles/nestedServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestedconnection/expectedoutputfiles/nestedServiceTemplate.yaml new file mode 100644 index 0000000000..68a602e14a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestedconnection/expectedoutputfiles/nestedServiceTemplate.yaml @@ -0,0 +1,212 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p1: + hidden: false + immutable: false + type: string + description: UID of OAM network + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + cmaui_volume_param2: + hidden: false + immutable: false + type: string + description: nova server id + security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + shared_vol1: + hidden: false + immutable: false + type: string + description: nova server id + cmaui_oam_ips: + hidden: false + immutable: false + type: string + node_templates: + cmaui_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: p1 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui2 + relationship: tosca.relationships.network.BindsTo + server_cmaui2: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + name: + get_input: + - cmaui_names + - 0 + server_cmaui1: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + name: + get_input: + - cmaui_names + - 0 + cmaui_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: p1 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui1 + relationship: tosca.relationships.network.BindsTo + groups: + nested: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested.yml + description: cmaui server template for vMMSC + members: + - cmaui_port_2 + - server_cmaui2 + - server_cmaui1 + - cmaui_port_1 + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested + capabilities: + scalable_server_cmaui1: + - server_cmaui1 + - scalable + endpoint_server_cmaui1: + - server_cmaui1 + - endpoint + os_server_cmaui1: + - server_cmaui1 + - os + scalable_server_cmaui2: + - server_cmaui2 + - scalable + endpoint_server_cmaui2: + - server_cmaui2 + - endpoint + attachment_cmaui_port_2: + - cmaui_port_2 + - attachment + host_server_cmaui1: + - server_cmaui1 + - host + os_server_cmaui2: + - server_cmaui2 + - os + binding_server_cmaui2: + - server_cmaui2 + - binding + host_server_cmaui2: + - server_cmaui2 + - host + binding_server_cmaui1: + - server_cmaui1 + - binding + attachment_cmaui_port_1: + - cmaui_port_1 + - attachment + requirements: + link_cmaui_port_2: + - cmaui_port_2 + - link + link_cmaui_port_1: + - cmaui_port_1 + - link + local_storage_server_cmaui2: + - server_cmaui2 + - local_storage + local_storage_server_cmaui1: + - server_cmaui1 + - local_storage \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestedconnection/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestedconnection/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..8ba5fc48f4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestedconnection/inputfiles/MANIFEST.json @@ -0,0 +1,22 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "main.yml", + "type": "HEAT", + "isBase": "true" + }, + { + "file": "nested.yml", + "type": "HEAT", + "isBase": "false" + }, + { + "file": "addOn.yml", + "type": "HEAT", + "isBase": "false" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestedconnection/inputfiles/addOn.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestedconnection/inputfiles/addOn.yml new file mode 100644 index 0000000000..20fb8c92d8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestedconnection/inputfiles/addOn.yml @@ -0,0 +1,30 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + shared_vol1: + type: string + description: volume name + shared_vol2: + type: string + description: volume name + cmaui_cinder_volume_size: + type: number + label: CMAUI Cinder volume size + description: the size of the CMAUI Cinder volume + CMAUI_volume_type: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + +resources: + test_nested: + type: nested.yml + properties: + shared_vol1: { get_param: shared_vol1} + cmaui_volume_param2: { get_param: shared_vol2} +outputs: + out1_not_shared: + value: {get_resource: test_nested} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestedconnection/inputfiles/main.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestedconnection/inputfiles/main.yml new file mode 100644 index 0000000000..e32c24e200 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestedconnection/inputfiles/main.yml @@ -0,0 +1,32 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + cmaui_cinder_volume_size: + type: number + label: CMAUI Cinder volume size + description: the size of the CMAUI Cinder volume + CMAUI_volume_type: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + +resources: + test_vol1: + type: OS::Cinder::Volume + properties: + size: {get_param: cmaui_cinder_volume_size} + volume_type: {get_param: CMAUI_volume_type} + test_vol2: + type: OS::Cinder::Volume + properties: + size: {get_param: cmaui_cinder_volume_size} + volume_type: {get_param: CMAUI_volume_type} + +outputs: + shared_vol1: + value: {get_resource: test_vol1} + shared_vol2: + value: {get_resource: test_vol2} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestedconnection/inputfiles/nested.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestedconnection/inputfiles/nested.yml new file mode 100644 index 0000000000..b5c913c48d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestedconnection/inputfiles/nested.yml @@ -0,0 +1,87 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + shared_vol1: + type: string + description: nova server id + cmaui_volume_param2: + type: string + description: nova server id + p1: + type: string + description: UID of OAM network + security_group_name: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_oam_ips: + type: string +resources: + + cmaui_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: p1 } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + cmaui_port_2: + type: OS::Neutron::Port + properties: + network: { get_param: p1 } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_cmaui1: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_1 } + + server_cmaui2: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_2 } + + cmaui_volume_attachment1: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_param: shared_vol1} + instance_uuid: {get_resource: server_cmaui1} + + cmaui_volume_attachment2: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_param: cmaui_volume_param2} + instance_uuid: {get_resource: server_cmaui1} + + cmaui_volume_attachment3: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_param: shared_vol1} + instance_uuid: {get_resource: server_cmaui2} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestednotconnected/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestednotconnected/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..fd5eae6858 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestednotconnected/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,158 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.nested: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + cmaui_names: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p1: + type: string + description: UID of OAM network + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_volume_param2: + type: string + description: nova server id + security_group_name: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + availability_zone_0: + type: string + description: availabilityzone name + shared_vol1: + type: string + description: nova server id + cmaui_oam_ips: + type: string + requirements: + - link_cmaui_port_2: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - local_storage_server_cmaui2: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - local_storage_server_cmaui1: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_cmaui_port_1: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + scalable_server_cmaui1: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + endpoint_server_cmaui1: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + os_server_cmaui1: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + scalable_server_cmaui2: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + endpoint_server_cmaui2: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_2: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + host_server_cmaui1: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + os_server_cmaui2: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + binding_server_cmaui2: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + host_server_cmaui2: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + binding_server_cmaui1: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_1: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestednotconnected/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestednotconnected/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..f279e7f83d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestednotconnected/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,181 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p1: + hidden: false + immutable: false + type: string + description: UID of OAM network + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + cmaui_cinder_volume_size: + label: CMAUI Cinder volume size + hidden: false + immutable: false + type: float + description: the size of the CMAUI Cinder volume + security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + shared_vol1: + hidden: false + immutable: false + type: string + description: volume name + cmaui_oam_ips: + hidden: false + immutable: false + type: string + shared_vol2: + hidden: false + immutable: false + type: string + description: volume name + CMAUI_volume_type: + label: CMAUI vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + node_templates: + test_vol1: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: CMAUI_volume_type + size: '(get_input : cmaui_cinder_volume_size) * 1024' + test_vol2: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: CMAUI_volume_type + size: '(get_input : cmaui_cinder_volume_size) * 1024' + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + name: + get_input: + - cmaui_names + - 0 + cmaui_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: p1 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + test_nested: + type: org.openecomp.resource.abstract.nodes.heat.nested + directives: + - substitutable + properties: + service_template_filter: + substitute_service_template: nestedServiceTemplate.yaml + cmaui_volume_param2: + get_input: shared_vol2 + shared_vol1: + get_input: shared_vol1 + requirements: + - local_storage_server_cmaui1: + capability: tosca.capabilities.Attachment + node: test_vol2 + relationship: tosca.relationships.AttachesTo + groups: + addOn: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/addOn.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - test_nested + main: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/main.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - test_vol1 + - test_vol2 + - server_cmaui + - cmaui_port_0 + outputs: + out1_not_shared: + value: test_nested \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestednotconnected/expectedoutputfiles/nestedServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestednotconnected/expectedoutputfiles/nestedServiceTemplate.yaml new file mode 100644 index 0000000000..68a602e14a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestednotconnected/expectedoutputfiles/nestedServiceTemplate.yaml @@ -0,0 +1,212 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p1: + hidden: false + immutable: false + type: string + description: UID of OAM network + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + cmaui_volume_param2: + hidden: false + immutable: false + type: string + description: nova server id + security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + shared_vol1: + hidden: false + immutable: false + type: string + description: nova server id + cmaui_oam_ips: + hidden: false + immutable: false + type: string + node_templates: + cmaui_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: p1 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui2 + relationship: tosca.relationships.network.BindsTo + server_cmaui2: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + name: + get_input: + - cmaui_names + - 0 + server_cmaui1: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + name: + get_input: + - cmaui_names + - 0 + cmaui_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: p1 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui1 + relationship: tosca.relationships.network.BindsTo + groups: + nested: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested.yml + description: cmaui server template for vMMSC + members: + - cmaui_port_2 + - server_cmaui2 + - server_cmaui1 + - cmaui_port_1 + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested + capabilities: + scalable_server_cmaui1: + - server_cmaui1 + - scalable + endpoint_server_cmaui1: + - server_cmaui1 + - endpoint + os_server_cmaui1: + - server_cmaui1 + - os + scalable_server_cmaui2: + - server_cmaui2 + - scalable + endpoint_server_cmaui2: + - server_cmaui2 + - endpoint + attachment_cmaui_port_2: + - cmaui_port_2 + - attachment + host_server_cmaui1: + - server_cmaui1 + - host + os_server_cmaui2: + - server_cmaui2 + - os + binding_server_cmaui2: + - server_cmaui2 + - binding + host_server_cmaui2: + - server_cmaui2 + - host + binding_server_cmaui1: + - server_cmaui1 + - binding + attachment_cmaui_port_1: + - cmaui_port_1 + - attachment + requirements: + link_cmaui_port_2: + - cmaui_port_2 + - link + link_cmaui_port_1: + - cmaui_port_1 + - link + local_storage_server_cmaui2: + - server_cmaui2 + - local_storage + local_storage_server_cmaui1: + - server_cmaui1 + - local_storage \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestednotconnected/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestednotconnected/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..8ba5fc48f4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestednotconnected/inputfiles/MANIFEST.json @@ -0,0 +1,22 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "main.yml", + "type": "HEAT", + "isBase": "true" + }, + { + "file": "nested.yml", + "type": "HEAT", + "isBase": "false" + }, + { + "file": "addOn.yml", + "type": "HEAT", + "isBase": "false" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestednotconnected/inputfiles/addOn.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestednotconnected/inputfiles/addOn.yml new file mode 100644 index 0000000000..20fb8c92d8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestednotconnected/inputfiles/addOn.yml @@ -0,0 +1,30 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + shared_vol1: + type: string + description: volume name + shared_vol2: + type: string + description: volume name + cmaui_cinder_volume_size: + type: number + label: CMAUI Cinder volume size + description: the size of the CMAUI Cinder volume + CMAUI_volume_type: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + +resources: + test_nested: + type: nested.yml + properties: + shared_vol1: { get_param: shared_vol1} + cmaui_volume_param2: { get_param: shared_vol2} +outputs: + out1_not_shared: + value: {get_resource: test_nested} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestednotconnected/inputfiles/main.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestednotconnected/inputfiles/main.yml new file mode 100644 index 0000000000..2e272bf42f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestednotconnected/inputfiles/main.yml @@ -0,0 +1,70 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + cmaui_cinder_volume_size: + type: number + label: CMAUI Cinder volume size + description: the size of the CMAUI Cinder volume + CMAUI_volume_type: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + p1: + type: string + description: UID of OAM network + security_group_name: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_oam_ips: + type: string + +resources: + test_vol1: + type: OS::Cinder::Volume + properties: + size: {get_param: cmaui_cinder_volume_size} + volume_type: {get_param: CMAUI_volume_type} + test_vol2: + type: OS::Cinder::Volume + properties: + size: {get_param: cmaui_cinder_volume_size} + volume_type: {get_param: CMAUI_volume_type} + cmaui_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: p1 } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_cmaui: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_0 } + +outputs: + shared_vol1: + value: {get_resource: server_cmaui} + shared_vol2: + value: {get_resource: test_vol2} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestednotconnected/inputfiles/nested.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestednotconnected/inputfiles/nested.yml new file mode 100644 index 0000000000..b5c913c48d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumeconnection/sharednestednotconnected/inputfiles/nested.yml @@ -0,0 +1,87 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + shared_vol1: + type: string + description: nova server id + cmaui_volume_param2: + type: string + description: nova server id + p1: + type: string + description: UID of OAM network + security_group_name: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_oam_ips: + type: string +resources: + + cmaui_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: p1 } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + cmaui_port_2: + type: OS::Neutron::Port + properties: + network: { get_param: p1 } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_cmaui1: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_1 } + + server_cmaui2: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_2 } + + cmaui_volume_attachment1: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_param: shared_vol1} + instance_uuid: {get_resource: server_cmaui1} + + cmaui_volume_attachment2: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_param: cmaui_volume_param2} + instance_uuid: {get_resource: server_cmaui1} + + cmaui_volume_attachment3: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_param: shared_vol1} + instance_uuid: {get_resource: server_cmaui2} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumemulticonnection/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumemulticonnection/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..8a24ebce83 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumemulticonnection/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,326 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui_image: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + cmaui_cinder_volume_size: + label: CMAUI Cinder volume size + hidden: false + immutable: false + type: float + description: the size of the CMAUI Cinder volume + timezone: + label: timezone + hidden: false + immutable: false + type: string + description: timezone + security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + cmaui_volume: + label: CMAUI vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + oam_network_netmask: + label: oam network netmask + hidden: false + immutable: false + type: string + description: oam network gateway + cmaui_volume_param1: + hidden: false + immutable: false + type: string + description: nova server id + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + vnf_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-CMAUI_id + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + oam_network_gateway: + label: oam network gateway + hidden: false + immutable: false + type: string + description: oam network gateway + cmaui_volume_param2: + hidden: false + immutable: false + type: string + description: nova server id + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + cmaui_oam_ips: + label: CMAUI oam_net IP addresses + hidden: false + immutable: false + type: list + description: CMAUI oam_net IP addresses + entry_schema: + type: String + external_dns: + label: dns server + hidden: false + immutable: false + type: string + description: dns server + oam_net_name: + hidden: false + immutable: false + type: string + description: UID of OAM network + CMAUI_volume_type: + label: CMAUI vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + external_ntp: + label: ntp server + hidden: false + immutable: false + type: string + description: ntp server + node_templates: + cmaui_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui2 + relationship: tosca.relationships.network.BindsTo + server_cmaui2: + type: org.openecomp.resource.vfc.nodes.heat.cmaui_image + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + metadata: + vnf_id: + get_input: vnf_id + user_data_format: RAW + name: + get_input: + - cmaui_names + - 0 + user_data: + str_replace: + template: | + cmaui.mgmt.ip=${cmaui.mgmt.ip} + cmaui.mgmt.netmask=${cmaui.mgmt.netmask} + cmaui.mgmt.gateway=${cmaui.mgmt.gateway} + cmaui.external.dns=${cmaui.external.dns} + cmaui.external.ntp=${cmaui.external.ntp} + cmaui.node=${cmaui.node} + cmaui.timezone=${cmaui.timezone} + params: + ${cmaui.mgmt.netmask}: + get_input: oam_network_netmask + ${cmaui.node}: + get_input: + - cmaui_names + - 0 + ${cmaui.mgmt.gateway}: + get_input: oam_network_gateway + ${cmaui.mgmt.ip}: + get_input: + - cmaui_oam_ips + - 0 + ${cmaui.external.ntp}: + get_input: external_ntp + ${cmaui.timezone}: + get_input: timezone + ${cmaui.external.dns}: + get_input: external_dns + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: cmaui_volume2 + relationship: cmaui_volume_attachment3 + server_cmaui1: + type: org.openecomp.resource.vfc.nodes.heat.cmaui_image + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + metadata: + vnf_id: + get_input: vnf_id + user_data_format: RAW + name: + get_input: + - cmaui_names + - 0 + user_data: + str_replace: + template: | + cmaui.mgmt.ip=${cmaui.mgmt.ip} + cmaui.mgmt.netmask=${cmaui.mgmt.netmask} + cmaui.mgmt.gateway=${cmaui.mgmt.gateway} + cmaui.external.dns=${cmaui.external.dns} + cmaui.external.ntp=${cmaui.external.ntp} + cmaui.node=${cmaui.node} + cmaui.timezone=${cmaui.timezone} + params: + ${cmaui.mgmt.netmask}: + get_input: oam_network_netmask + ${cmaui.node}: + get_input: + - cmaui_names + - 0 + ${cmaui.mgmt.gateway}: + get_input: oam_network_gateway + ${cmaui.mgmt.ip}: + get_input: + - cmaui_oam_ips + - 0 + ${cmaui.external.ntp}: + get_input: external_ntp + ${cmaui.timezone}: + get_input: timezone + ${cmaui.external.dns}: + get_input: external_dns + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: cmaui_volume1 + relationship: cmaui_volume_attachment1 + - local_storage: + capability: tosca.capabilities.Attachment + node: cmaui_volume2 + relationship: cmaui_volume_attachment2 + cmaui_volume1: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: CMAUI_volume_type + size: '(get_input : cmaui_cinder_volume_size) * 1024' + cmaui_volume2: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: CMAUI_volume_type + size: '(get_input : cmaui_cinder_volume_size) * 1024' + cmaui_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui1 + relationship: tosca.relationships.network.BindsTo + relationship_templates: + cmaui_volume_attachment2: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: + get_input: cmaui_volume_param2 + instance_uuid: server_cmaui1 + cmaui_volume_attachment3: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: + get_input: cmaui_volume_param2 + instance_uuid: server_cmaui2 + cmaui_volume_attachment1: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: + get_input: cmaui_volume_param1 + instance_uuid: server_cmaui1 + groups: + addOn: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/addOn.yml + description: cmaui server template for vMMSC + members: + - cmaui_port_2 + - server_cmaui2 + - server_cmaui1 + - cmaui_port_1 + main: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/main.yml + description: volume + members: + - cmaui_volume1 + - cmaui_volume2 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumesharednestedconnection/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumesharednestedconnection/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..5e78625e01 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumesharednestedconnection/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,104 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml +topology_template: + inputs: + cmaui_cinder_volume_size: + label: CMAUI Cinder volume size + hidden: false + immutable: false + type: float + description: the size of the CMAUI Cinder volume + shared_vol1: + hidden: false + immutable: false + type: string + description: volume name + shared_vol2: + hidden: false + immutable: false + type: string + description: volume name + CMAUI_volume_type: + label: CMAUI vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + node_templates: + test_vol1: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: CMAUI_volume_type + size: '(get_input : cmaui_cinder_volume_size) * 1024' + test_vol2: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: CMAUI_volume_type + size: '(get_input : cmaui_cinder_volume_size) * 1024' + test_nested: + type: org.openecomp.resource.abstract.nodes.heat.nested + directives: + - substitutable + properties: + service_template_filter: + substitute_service_template: nestedServiceTemplate.yaml + cmaui_volume_param1: + get_input: shared_vol1 + cmaui_volume_param2: + get_input: shared_vol2 + requirements: + - local_storage_server_cmaui2: + capability: tosca.capabilities.Attachment + node: test_vol1 + relationship: tosca.relationships.AttachesTo + - local_storage_server_cmaui1: + capability: tosca.capabilities.Attachment + node: test_vol1 + relationship: tosca.relationships.AttachesTo + - local_storage_server_cmaui1: + capability: tosca.capabilities.Attachment + node: test_vol2 + relationship: tosca.relationships.AttachesTo + groups: + addOn: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/addOn.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - test_nested + main: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/main.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - test_vol1 + - test_vol2 + outputs: + out1_not_shared: + value: test_nested \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumesharednestedconnection/inputfiles/addOn.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumesharednestedconnection/inputfiles/addOn.yml new file mode 100644 index 0000000000..3114081d2b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/novatovolumesharednestedconnection/inputfiles/addOn.yml @@ -0,0 +1,30 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + shared_vol1: + type: string + description: volume name + shared_vol2: + type: string + description: volume name + cmaui_cinder_volume_size: + type: number + label: CMAUI Cinder volume size + description: the size of the CMAUI Cinder volume + CMAUI_volume_type: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + +resources: + test_nested: + type: nested.yml + properties: + cmaui_volume_param1: { get_param: shared_vol1} + cmaui_volume_param2: { get_param: shared_vol2} +outputs: + out1_not_shared: + value: {get_resource: test_nested} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/multi/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/multi/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..641b84337f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/multi/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,143 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p1: + hidden: false + immutable: false + type: string + description: UID of OAM network + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + cmaui_oam_ips: + hidden: false + immutable: false + type: string + shared_network_id: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + jsa_net_name: + hidden: false + immutable: false + type: string + description: network name of jsa log network + node_templates: + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + name: + get_input: + - cmaui_names + - 0 + test_net: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + shared: true + network_name: + get_input: jsa_net_name + cmaui_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: shared_network_id + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: test_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + groups: + addOn: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/addOn.yml + description: cmaui server template for vMMSC + members: + - server_cmaui + - cmaui_port_0 + main: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/main.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - test_net \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/multi/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/multi/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..1f762d0ccc --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/multi/inputfiles/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "main.yml", + "type": "HEAT", + "isBase": "true" + }, + { + "file": "addOn.yml", + "type": "HEAT", + "isBase": "false" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/multi/inputfiles/addOn.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/multi/inputfiles/addOn.yml new file mode 100644 index 0000000000..e6c5954fb0 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/multi/inputfiles/addOn.yml @@ -0,0 +1,48 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + p1: + type: string + description: UID of OAM network + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + security_group_name: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + cmaui_flavor: + type: string + description: Flavor for CMAUI server + shared_network_id: + type: string + description: Flavor for CMAUI server + cmaui_oam_ips: + type: string +resources: + + cmaui_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: shared_network_id } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_cmaui: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_0 } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/multi/inputfiles/main.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/multi/inputfiles/main.yml new file mode 100644 index 0000000000..73a2e3b45c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/multi/inputfiles/main.yml @@ -0,0 +1,20 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + jsa_net_name: + type: string + description: network name of jsa log network + +resources: + test_net: + type: OS::Neutron::Net + properties: + name: {get_param: jsa_net_name} + shared: True + +outputs: + shared_network_id: + value: {get_resource: test_net} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/nested/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/nested/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..44aca0ee4d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/nested/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,106 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.nested: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + cmaui_names: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p1: + type: string + description: UID of OAM network + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + security_group_name: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + availability_zone_0: + type: string + description: availabilityzone name + cmaui_oam_ips: + type: string + requirements: + - local_storage_server_cmaui: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_cmaui_port_0: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + host_server_cmaui: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + os_server_cmaui: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + endpoint_server_cmaui: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + binding_server_cmaui: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + scalable_server_cmaui: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_0: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/nested/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/nested/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..052286f8a9 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/nested/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,225 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + left_vn_fqdn: + hidden: false + immutable: false + type: string + description: dummy + Internal1_cidr: + hidden: false + immutable: false + type: string + src_port_start: + hidden: false + immutable: false + type: string + description: dummy + Internal1_default_gateway: + hidden: false + immutable: false + type: string + Internal1_dhcp: + hidden: false + immutable: false + type: string + src_port_end: + hidden: false + immutable: false + type: string + description: dummy + policy_name: + hidden: false + immutable: false + type: string + description: dummy + dst_port_end: + hidden: false + immutable: false + type: string + description: dummy + simple_action: + hidden: false + immutable: false + type: string + description: dummy + service_instance_fq_name: + hidden: false + immutable: false + type: string + Internal2_cidr: + hidden: false + immutable: false + type: string + protocol: + hidden: false + immutable: false + type: string + description: dummy + Internal2_dhcp: + hidden: false + immutable: false + type: string + dst_port_start: + hidden: false + immutable: false + type: string + description: dummy + network_ipam_refs_data_ipam_subnets_addr_from_start_true: + hidden: false + immutable: false + type: string + description: dummy + Internal2_default_gateway: + hidden: false + immutable: false + type: string + right_vn_fqdn: + hidden: false + immutable: false + type: string + description: dummy + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2: + hidden: false + immutable: false + type: string + description: dummy + left_vn: + hidden: false + immutable: false + type: string + description: dummy + direction: + hidden: false + immutable: false + type: string + description: dummy + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2: + hidden: false + immutable: false + type: string + description: dummy + node_templates: + template_NetworkPolicy: + type: org.openecomp.resource.vfc.rules.nodes.heat.network.contrailV2.NetworkRules + properties: + name: + get_input: policy_name + network_policy_entries: + network_policy_entries_policy_rule: + - network_policy_entries_policy_rule_dst_addresses: + - network_policy_entries_policy_rule_dst_addresses_virtual_network: + get_input: right_vn_fqdn + network_policy_entries_policy_rule_dst_ports: + - network_policy_entries_policy_rule_dst_ports_start_port: + get_input: dst_port_start + network_policy_entries_policy_rule_dst_ports_end_port: + get_input: dst_port_end + network_policy_entries_policy_rule_protocol: + get_input: protocol + network_policy_entries_policy_rule_src_addresses: + - network_policy_entries_policy_rule_src_addresses_virtual_network: + get_input: left_vn_fqdn + network_policy_entries_policy_rule_direction: + get_input: direction + network_policy_entries_policy_rule_src_ports: + - network_policy_entries_policy_rule_src_ports_start_port: + get_input: src_port_start + network_policy_entries_policy_rule_src_ports_end_port: + get_input: src_port_end + network_policy_entries_policy_rule_action_list: + network_policy_entries_policy_rule_action_list_simple_action: + get_input: simple_action + network_policy_entries_policy_rule_action_list_apply_service: + - get_input: service_instance_fq_name + requirements: + - network: + capability: tosca.capabilities.Attachment + node: test_net + relationship: org.openecomp.relationships.AttachesTo + test_net: + type: org.openecomp.resource.vl.nodes.heat.network.contrailV2.VirtualNetwork + properties: + network_ipam_refs_data: + - network_ipam_refs_data_ipam_subnets: + - network_ipam_refs_data_ipam_subnets_subnet: + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len: + get_input: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2 + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix: + get_input: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2 + network_ipam_refs_data_ipam_subnets_addr_from_start: + get_input: network_ipam_refs_data_ipam_subnets_addr_from_start_true + network_policy_refs_data: + - network_policy_refs_data_sequence: + network_policy_refs_data_sequence_major: 0 + network_policy_refs_data_sequence_minor: 0 + network_name: + get_input: left_vn + network_ipam_refs: + - UNSUPPORTED_RESOURCE_template_NetworkIpam_2 + network_policy_refs: + - list_join: + - ':' + - get_attribute: + - template_NetworkPolicy + - fq_name + requirements: + - dependency: + capability: tosca.capabilities.Node + node: template_NetworkPolicy + relationship: tosca.relationships.DependsOn + test_nested: + type: org.openecomp.resource.abstract.nodes.heat.nested + directives: + - substitutable + properties: + p1: test_net + service_template_filter: + substitute_service_template: nestedServiceTemplate.yaml + requirements: + - link_cmaui_port_0: + capability: tosca.capabilities.network.Linkable + node: test_net + relationship: tosca.relationships.network.LinksTo + groups: + main: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/main.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - template_NetworkPolicy + - test_net + - test_nested \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/nested/expectedoutputfiles/nestedServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/nested/expectedoutputfiles/nestedServiceTemplate.yaml new file mode 100644 index 0000000000..cfe7f567c5 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/nested/expectedoutputfiles/nestedServiceTemplate.yaml @@ -0,0 +1,145 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p1: + hidden: false + immutable: false + type: string + description: UID of OAM network + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + cmaui_oam_ips: + hidden: false + immutable: false + type: string + node_templates: + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + name: + get_input: + - cmaui_names + - 0 + cmaui_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: p1 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + groups: + nested: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested.yml + description: cmaui server template for vMMSC + members: + - server_cmaui + - cmaui_port_0 + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested + capabilities: + host_server_cmaui: + - server_cmaui + - host + os_server_cmaui: + - server_cmaui + - os + endpoint_server_cmaui: + - server_cmaui + - endpoint + binding_server_cmaui: + - server_cmaui + - binding + scalable_server_cmaui: + - server_cmaui + - scalable + attachment_cmaui_port_0: + - cmaui_port_0 + - attachment + requirements: + local_storage_server_cmaui: + - server_cmaui + - local_storage + link_cmaui_port_0: + - cmaui_port_0 + - link \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/nested/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/nested/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..aca75b5055 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/nested/inputfiles/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "main.yml", + "type": "HEAT", + "isBase": "true" + }, + { + "file": "nested.yml", + "type": "HEAT", + "isBase": "false" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/nested/inputfiles/main.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/nested/inputfiles/main.yml new file mode 100644 index 0000000000..30e107dec7 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/nested/inputfiles/main.yml @@ -0,0 +1,140 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + Internal1_cidr: + type: string + Internal2_cidr: + type: string + Internal1_default_gateway: + type: string + Internal2_default_gateway: + type: string + Internal1_dhcp: + type: string + Internal2_dhcp: + type: string + direction: + description: dummy + type: string + dst_port_end: + description: dummy + type: string + dst_port_start: + description: dummy + type: string + left_vn: + description: dummy + type: string + left_vn_fqdn: + description: dummy + type: string + network_ipam_refs_data_ipam_subnets_addr_from_start_true: + description: dummy + type: string + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2: + description: dummy + type: string + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2: + description: dummy + type: string + policy_name: + description: dummy + type: string + protocol: + description: dummy + type: string + right_vn_fqdn: + description: dummy + type: string + simple_action: + description: dummy + type: string + src_port_end: + description: dummy + type: string + src_port_start: + description: dummy + type: string + service_instance_fq_name: + type: string + +resources: + template_NetworkIpam_2: + properties: + name: + get_param: left_vn + type: "OS::ContrailV2::NetworkIpam" + template_NetworkPolicy: + properties: + name: + get_param: policy_name + network_policy_entries: + network_policy_entries_policy_rule: + - + network_policy_entries_policy_rule_action_list: + network_policy_entries_policy_rule_action_list_apply_service: + - + get_param: service_instance_fq_name + network_policy_entries_policy_rule_action_list_simple_action: + get_param: simple_action + network_policy_entries_policy_rule_direction: + get_param: direction + network_policy_entries_policy_rule_dst_addresses: + - + network_policy_entries_policy_rule_dst_addresses_virtual_network: + get_param: right_vn_fqdn + network_policy_entries_policy_rule_dst_ports: + - + network_policy_entries_policy_rule_dst_ports_end_port: + get_param: dst_port_end + network_policy_entries_policy_rule_dst_ports_start_port: + get_param: dst_port_start + network_policy_entries_policy_rule_protocol: + get_param: protocol + network_policy_entries_policy_rule_src_addresses: + - + network_policy_entries_policy_rule_src_addresses_virtual_network: + get_param: left_vn_fqdn + network_policy_entries_policy_rule_src_ports: + - + network_policy_entries_policy_rule_src_ports_end_port: + get_param: src_port_end + network_policy_entries_policy_rule_src_ports_start_port: + get_param: src_port_start + type: "OS::ContrailV2::NetworkPolicy" + test_net: + depends_on: + - template_NetworkIpam_2 + - template_NetworkPolicy + properties: + name: + get_param: left_vn + network_ipam_refs: + - + get_resource: template_NetworkIpam_2 + network_ipam_refs_data: + - + network_ipam_refs_data_ipam_subnets: + - + network_ipam_refs_data_ipam_subnets_addr_from_start: + get_param: network_ipam_refs_data_ipam_subnets_addr_from_start_true + network_ipam_refs_data_ipam_subnets_subnet: + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix: + get_param: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2 + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len: + get_param: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2 + network_policy_refs: [ { list_join: [':', { get_attr: [ template_NetworkPolicy, fq_name ] } ] } ] + network_policy_refs_data: + - + network_policy_refs_data_sequence: + network_policy_refs_data_sequence_major: 0 + network_policy_refs_data_sequence_minor: 0 + type: "OS::ContrailV2::VirtualNetwork" + + test_nested: + type: nested.yml + properties: + p1: { get_resource: test_net} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/nested/inputfiles/nested.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/nested/inputfiles/nested.yml new file mode 100644 index 0000000000..56a099500b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/nested/inputfiles/nested.yml @@ -0,0 +1,45 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + p1: + type: string + description: UID of OAM network + security_group_name: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_oam_ips: + type: string +resources: + + cmaui_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: p1 } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_cmaui: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_0 } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..351b12fd58 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,251 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.nested1: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + cmaui_names: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p1: + type: string + description: UID of OAM network + p2: + type: string + description: UID of OAM network + abc_flavor: + type: string + description: Flavor for CMAUI server + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + abc_names: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + security_group_name: + description: not impotrtant + availability_zone_0: + type: string + description: availabilityzone name + abc_oam_ips: + type: string + cmaui_oam_ips: + type: string + abc_image: + type: string + description: Image for CMAUI server + requirements: + - link_cmaui_port_2: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - local_storage_server_cmaui: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - local_storage_server_abc: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_abc_port_1: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_cmaui_port_1: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + scalable_server_abc: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + os_server_cmaui: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + attachment_abc_port_1: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + scalable_server_cmaui: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + host_server_abc: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + os_server_abc: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + host_server_cmaui: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + binding_server_abc: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + endpoint_server_cmaui: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + binding_server_cmaui: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + endpoint_server_abc: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_2: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_1: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + org.openecomp.resource.abstract.nodes.heat.nested2: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + cmaui_names: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p1: + type: string + description: UID of OAM network + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + security_group_name: + description: not impotrtant + availability_zone_0: + type: string + description: availabilityzone name + abc_oam_ips: + type: string + cmaui_oam_ips: + type: string + requirements: + - local_storage_server_cmaui: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_cmaui_port_1: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + host_server_cmaui: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + os_server_cmaui: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + endpoint_server_cmaui: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + binding_server_cmaui: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + scalable_server_cmaui: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_1: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..427e7be436 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,334 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + left_vn_fqdn: + hidden: false + immutable: false + type: string + description: dummy + Internal1_cidr: + hidden: false + immutable: false + type: string + src_port_start: + hidden: false + immutable: false + type: string + description: dummy + Internal1_default_gateway: + hidden: false + immutable: false + type: string + Internal1_dhcp: + hidden: false + immutable: false + type: string + src_port_end: + hidden: false + immutable: false + type: string + description: dummy + policy_name: + hidden: false + immutable: false + type: string + description: dummy + dst_port_end: + hidden: false + immutable: false + type: string + description: dummy + simple_action: + hidden: false + immutable: false + type: string + description: dummy + service_instance_fq_name: + hidden: false + immutable: false + type: string + jsa_net_name: + hidden: false + immutable: false + type: string + description: network name of jsa log network + Internal2_cidr: + hidden: false + immutable: false + type: string + protocol: + hidden: false + immutable: false + type: string + description: dummy + shared_network_id1: + hidden: false + immutable: false + type: string + description: network name of jsa log network + Internal2_dhcp: + hidden: false + immutable: false + type: string + shared_network_id2: + hidden: false + immutable: false + type: string + description: network name of jsa log network + dst_port_start: + hidden: false + immutable: false + type: string + description: dummy + network_ipam_refs_data_ipam_subnets_addr_from_start_true: + hidden: false + immutable: false + type: string + description: dummy + Internal2_default_gateway: + hidden: false + immutable: false + type: string + right_vn_fqdn: + hidden: false + immutable: false + type: string + description: dummy + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2: + hidden: false + immutable: false + type: string + description: dummy + left_vn: + hidden: false + immutable: false + type: string + description: dummy + direction: + hidden: false + immutable: false + type: string + description: dummy + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2: + hidden: false + immutable: false + type: string + description: dummy + node_templates: + template_NetworkPolicy: + type: org.openecomp.resource.vfc.rules.nodes.heat.network.contrailV2.NetworkRules + properties: + name: + get_input: policy_name + network_policy_entries: + network_policy_entries_policy_rule: + - network_policy_entries_policy_rule_dst_addresses: + - network_policy_entries_policy_rule_dst_addresses_virtual_network: + get_input: right_vn_fqdn + network_policy_entries_policy_rule_dst_ports: + - network_policy_entries_policy_rule_dst_ports_start_port: + get_input: dst_port_start + network_policy_entries_policy_rule_dst_ports_end_port: + get_input: dst_port_end + network_policy_entries_policy_rule_protocol: + get_input: protocol + network_policy_entries_policy_rule_src_addresses: + - network_policy_entries_policy_rule_src_addresses_virtual_network: + get_input: left_vn_fqdn + network_policy_entries_policy_rule_direction: + get_input: direction + network_policy_entries_policy_rule_src_ports: + - network_policy_entries_policy_rule_src_ports_start_port: + get_input: src_port_start + network_policy_entries_policy_rule_src_ports_end_port: + get_input: src_port_end + network_policy_entries_policy_rule_action_list: + network_policy_entries_policy_rule_action_list_simple_action: + get_input: simple_action + network_policy_entries_policy_rule_action_list_apply_service: + - get_input: service_instance_fq_name + requirements: + - network: + capability: tosca.capabilities.Attachment + node: test_net1 + relationship: org.openecomp.relationships.AttachesTo + - network: + capability: tosca.capabilities.Attachment + node: test_net2 + relationship: org.openecomp.relationships.AttachesTo + test_net2: + type: org.openecomp.resource.vl.nodes.heat.network.contrailV2.VirtualNetwork + properties: + network_ipam_refs_data: + - network_ipam_refs_data_ipam_subnets: + - network_ipam_refs_data_ipam_subnets_subnet: + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len: + get_input: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2 + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix: + get_input: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2 + network_ipam_refs_data_ipam_subnets_addr_from_start: + get_input: network_ipam_refs_data_ipam_subnets_addr_from_start_true + network_policy_refs_data: + - network_policy_refs_data_sequence: + network_policy_refs_data_sequence_major: 0 + network_policy_refs_data_sequence_minor: 0 + network_name: + get_input: left_vn + network_ipam_refs: + - UNSUPPORTED_RESOURCE_template_NetworkIpam_2 + network_policy_refs: + - list_join: + - ':' + - get_attribute: + - template_NetworkPolicy + - fq_name + requirements: + - dependency: + capability: tosca.capabilities.Node + node: template_NetworkPolicy + relationship: tosca.relationships.DependsOn + test_nested2: + type: org.openecomp.resource.abstract.nodes.heat.nested2 + directives: + - substitutable + properties: + p1: + get_input: shared_network_id1 + service_template_filter: + substitute_service_template: nested2ServiceTemplate.yaml + requirements: + - link_cmaui_port_1: + capability: tosca.capabilities.network.Linkable + node: test_net1 + relationship: tosca.relationships.network.LinksTo + test_nested3: + type: org.openecomp.resource.abstract.nodes.heat.nested1 + directives: + - substitutable + properties: + p1: + get_input: shared_network_id1 + service_template_filter: + substitute_service_template: nested1ServiceTemplate.yaml + p2: + get_input: shared_network_id2 + requirements: + - link_cmaui_port_2: + capability: tosca.capabilities.network.Linkable + node: test_net2 + relationship: tosca.relationships.network.LinksTo + - link_abc_port_1: + capability: tosca.capabilities.network.Linkable + node: test_net2 + relationship: tosca.relationships.network.LinksTo + - link_cmaui_port_1: + capability: tosca.capabilities.network.Linkable + node: test_net1 + relationship: tosca.relationships.network.LinksTo + test_net1: + type: org.openecomp.resource.vl.nodes.heat.network.contrailV2.VirtualNetwork + properties: + network_ipam_refs_data: + - network_ipam_refs_data_ipam_subnets: + - network_ipam_refs_data_ipam_subnets_subnet: + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len: + get_input: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2 + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix: + get_input: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2 + network_ipam_refs_data_ipam_subnets_addr_from_start: + get_input: network_ipam_refs_data_ipam_subnets_addr_from_start_true + network_policy_refs_data: + - network_policy_refs_data_sequence: + network_policy_refs_data_sequence_major: 0 + network_policy_refs_data_sequence_minor: 0 + network_name: + get_input: left_vn + network_ipam_refs: + - UNSUPPORTED_RESOURCE_template_NetworkIpam_2 + network_policy_refs: + - list_join: + - ':' + - get_attribute: + - template_NetworkPolicy + - fq_name + requirements: + - dependency: + capability: tosca.capabilities.Node + node: template_NetworkPolicy + relationship: tosca.relationships.DependsOn + test_nested1: + type: org.openecomp.resource.abstract.nodes.heat.nested1 + directives: + - substitutable + properties: + p1: + get_input: shared_network_id1 + service_template_filter: + substitute_service_template: nested1ServiceTemplate.yaml + p2: + get_input: shared_network_id2 + requirements: + - link_cmaui_port_2: + capability: tosca.capabilities.network.Linkable + node: test_net2 + relationship: tosca.relationships.network.LinksTo + - link_abc_port_1: + capability: tosca.capabilities.network.Linkable + node: test_net2 + relationship: tosca.relationships.network.LinksTo + - link_cmaui_port_1: + capability: tosca.capabilities.network.Linkable + node: test_net1 + relationship: tosca.relationships.network.LinksTo + groups: + addOn: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/addOn.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - test_nested2 + - test_nested3 + - test_nested1 + main: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/main.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - template_NetworkPolicy + - test_net2 + - test_net1 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/expectedoutputfiles/nested1ServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/expectedoutputfiles/nested1ServiceTemplate.yaml new file mode 100644 index 0000000000..cd5b767492 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/expectedoutputfiles/nested1ServiceTemplate.yaml @@ -0,0 +1,252 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested1 +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.abc: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p1: + hidden: false + immutable: false + type: string + description: UID of OAM network + p2: + hidden: false + immutable: false + type: string + description: UID of OAM network + abc_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + abc_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + security_group_name: + hidden: false + immutable: false + description: not impotrtant + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + abc_oam_ips: + hidden: false + immutable: false + type: string + cmaui_oam_ips: + hidden: false + immutable: false + type: string + abc_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + node_templates: + cmaui_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: p2 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + name: + get_input: + - cmaui_names + - 0 + server_abc: + type: org.openecomp.resource.vfc.nodes.heat.abc + properties: + flavor: + get_input: abc_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: abc_image + name: + get_input: + - abc_names + - 0 + abc_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - abc_oam_ips + - 0 + network: + get_input: p2 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_abc + relationship: tosca.relationships.network.BindsTo + cmaui_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: p1 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + groups: + nested1: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested1.yml + description: cmaui server template for vMMSC + members: + - cmaui_port_2 + - server_cmaui + - server_abc + - abc_port_1 + - cmaui_port_1 + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested1 + capabilities: + scalable_server_abc: + - server_abc + - scalable + os_server_cmaui: + - server_cmaui + - os + attachment_abc_port_1: + - abc_port_1 + - attachment + scalable_server_cmaui: + - server_cmaui + - scalable + host_server_abc: + - server_abc + - host + os_server_abc: + - server_abc + - os + host_server_cmaui: + - server_cmaui + - host + binding_server_abc: + - server_abc + - binding + endpoint_server_cmaui: + - server_cmaui + - endpoint + binding_server_cmaui: + - server_cmaui + - binding + endpoint_server_abc: + - server_abc + - endpoint + attachment_cmaui_port_2: + - cmaui_port_2 + - attachment + attachment_cmaui_port_1: + - cmaui_port_1 + - attachment + requirements: + local_storage_server_cmaui: + - server_cmaui + - local_storage + link_abc_port_1: + - abc_port_1 + - link + link_cmaui_port_2: + - cmaui_port_2 + - link + link_cmaui_port_1: + - cmaui_port_1 + - link + local_storage_server_abc: + - server_abc + - local_storage \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/expectedoutputfiles/nested2ServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/expectedoutputfiles/nested2ServiceTemplate.yaml new file mode 100644 index 0000000000..992e1c017c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/expectedoutputfiles/nested2ServiceTemplate.yaml @@ -0,0 +1,146 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested2 +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p1: + hidden: false + immutable: false + type: string + description: UID of OAM network + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + security_group_name: + hidden: false + immutable: false + description: not impotrtant + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + abc_oam_ips: + hidden: false + immutable: false + type: string + cmaui_oam_ips: + hidden: false + immutable: false + type: string + node_templates: + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + name: + get_input: + - cmaui_names + - 0 + cmaui_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: p1 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + groups: + nested2: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested2.yml + description: cmaui server template for vMMSC + members: + - server_cmaui + - cmaui_port_1 + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested2 + capabilities: + host_server_cmaui: + - server_cmaui + - host + os_server_cmaui: + - server_cmaui + - os + endpoint_server_cmaui: + - server_cmaui + - endpoint + binding_server_cmaui: + - server_cmaui + - binding + scalable_server_cmaui: + - server_cmaui + - scalable + attachment_cmaui_port_1: + - cmaui_port_1 + - attachment + requirements: + local_storage_server_cmaui: + - server_cmaui + - local_storage + link_cmaui_port_1: + - cmaui_port_1 + - link \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..e593097c44 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/inputfiles/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "main.yml", + "type": "HEAT", + "isBase": "true" + }, + { + "file": "nested1.yml", + "type": "HEAT", + "isBase": "false" + }, + { + "file": "nested2.yml", + "type": "HEAT", + "isBase": "false" + }, + { + "file": "addOn.yml", + "type": "HEAT", + "isBase": "false" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/inputfiles/addOn.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/inputfiles/addOn.yml new file mode 100644 index 0000000000..d956043627 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/inputfiles/addOn.yml @@ -0,0 +1,32 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + shared_network_id1: + type: string + description: network name of jsa log network + + shared_network_id2: + type: string + description: network name of jsa log network + +resources: + + test_nested1: + type: nested1.yml + properties: + p1: { get_param: shared_network_id1} + p2: { get_param: shared_network_id2} + + test_nested2: + type: nested2.yml + properties: + p1: { get_param: shared_network_id1} + + test_nested3: + type: nested1.yml + properties: + p1: { get_param: shared_network_id1} + p2: { get_param: shared_network_id2} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/inputfiles/main.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/inputfiles/main.yml new file mode 100644 index 0000000000..65d1a21a47 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/inputfiles/main.yml @@ -0,0 +1,174 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + jsa_net_name: + type: string + description: network name of jsa log network + Internal1_cidr: + type: string + Internal2_cidr: + type: string + Internal1_default_gateway: + type: string + Internal2_default_gateway: + type: string + Internal1_dhcp: + type: string + Internal2_dhcp: + type: string + direction: + description: dummy + type: string + dst_port_end: + description: dummy + type: string + dst_port_start: + description: dummy + type: string + left_vn: + description: dummy + type: string + left_vn_fqdn: + description: dummy + type: string + network_ipam_refs_data_ipam_subnets_addr_from_start_true: + description: dummy + type: string + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2: + description: dummy + type: string + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2: + description: dummy + type: string + policy_name: + description: dummy + type: string + protocol: + description: dummy + type: string + right_vn_fqdn: + description: dummy + type: string + simple_action: + description: dummy + type: string + src_port_end: + description: dummy + type: string + src_port_start: + description: dummy + type: string + service_instance_fq_name: + type: string + +resources: + template_NetworkIpam_2: + properties: + name: + get_param: left_vn + type: "OS::ContrailV2::NetworkIpam" + template_NetworkPolicy: + properties: + name: + get_param: policy_name + network_policy_entries: + network_policy_entries_policy_rule: + - + network_policy_entries_policy_rule_action_list: + network_policy_entries_policy_rule_action_list_apply_service: + - + get_param: service_instance_fq_name + network_policy_entries_policy_rule_action_list_simple_action: + get_param: simple_action + network_policy_entries_policy_rule_direction: + get_param: direction + network_policy_entries_policy_rule_dst_addresses: + - + network_policy_entries_policy_rule_dst_addresses_virtual_network: + get_param: right_vn_fqdn + network_policy_entries_policy_rule_dst_ports: + - + network_policy_entries_policy_rule_dst_ports_end_port: + get_param: dst_port_end + network_policy_entries_policy_rule_dst_ports_start_port: + get_param: dst_port_start + network_policy_entries_policy_rule_protocol: + get_param: protocol + network_policy_entries_policy_rule_src_addresses: + - + network_policy_entries_policy_rule_src_addresses_virtual_network: + get_param: left_vn_fqdn + network_policy_entries_policy_rule_src_ports: + - + network_policy_entries_policy_rule_src_ports_end_port: + get_param: src_port_end + network_policy_entries_policy_rule_src_ports_start_port: + get_param: src_port_start + type: "OS::ContrailV2::NetworkPolicy" + test_net1: + depends_on: + - template_NetworkIpam_2 + - template_NetworkPolicy + properties: + name: + get_param: left_vn + network_ipam_refs: + - + get_resource: template_NetworkIpam_2 + network_ipam_refs_data: + - + network_ipam_refs_data_ipam_subnets: + - + network_ipam_refs_data_ipam_subnets_addr_from_start: + get_param: network_ipam_refs_data_ipam_subnets_addr_from_start_true + network_ipam_refs_data_ipam_subnets_subnet: + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix: + get_param: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2 + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len: + get_param: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2 + network_policy_refs: [ { list_join: [':', { get_attr: [ template_NetworkPolicy, fq_name ] } ] } ] + network_policy_refs_data: + - + network_policy_refs_data_sequence: + network_policy_refs_data_sequence_major: 0 + network_policy_refs_data_sequence_minor: 0 + type: "OS::ContrailV2::VirtualNetwork" + + test_net2: + depends_on: + - template_NetworkIpam_2 + - template_NetworkPolicy + properties: + name: + get_param: left_vn + network_ipam_refs: + - + get_resource: template_NetworkIpam_2 + network_ipam_refs_data: + - + network_ipam_refs_data_ipam_subnets: + - + network_ipam_refs_data_ipam_subnets_addr_from_start: + get_param: network_ipam_refs_data_ipam_subnets_addr_from_start_true + network_ipam_refs_data_ipam_subnets_subnet: + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix: + get_param: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_2 + network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len: + get_param: network_ipam_refs_data_ipam_subnets_subnet_ip_prefix_len_2 + network_policy_refs: [ { list_join: [':', { get_attr: [ template_NetworkPolicy, fq_name ] } ] } ] + network_policy_refs_data: + - + network_policy_refs_data_sequence: + network_policy_refs_data_sequence_major: 0 + network_policy_refs_data_sequence_minor: 0 + type: "OS::ContrailV2::VirtualNetwork" + +outputs: + shared_network_id1: + value: {get_resource: test_net1} + + shared_network_id2: + value: {get_resource: test_net2} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/inputfiles/nested1.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/inputfiles/nested1.yml new file mode 100644 index 0000000000..66a15d0440 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/inputfiles/nested1.yml @@ -0,0 +1,86 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + p1: + type: string + description: UID of OAM network + p2: + type: string + description: UID of OAM network + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + abc_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + security_group_name: + type: not_important + description: not impotrtant + cmaui_image: + type: string + description: Image for CMAUI server + abc_image: + type: string + description: Image for CMAUI server + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + cmaui_flavor: + type: string + description: Flavor for CMAUI server + abc_flavor: + type: string + description: Flavor for CMAUI server + cmaui_oam_ips: + type: string + abc_oam_ips: + type: string +resources: + + cmaui_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: p1 } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + cmaui_port_2: + type: OS::Neutron::Port + properties: + network: { get_param: p2 } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + abc_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: p2 } + fixed_ips: [{"ip_address": {get_param: [abc_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_cmaui: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_1 } + - port: { get_resource: cmaui_port_2 } + + server_abc: + type: OS::Nova::Server + properties: + name: { get_param: [abc_names, 0]} + image: { get_param: abc_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: abc_flavor } + networks: + - port: { get_resource: abc_port_1 } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/inputfiles/nested2.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/inputfiles/nested2.yml new file mode 100644 index 0000000000..b09d3aff8e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttocontrailv2virtualnetworkconnection/shared/inputfiles/nested2.yml @@ -0,0 +1,48 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + p1: + type: string + description: UID of OAM network + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + security_group_name: + type: not_important + description: not impotrtant + cmaui_image: + type: string + description: Image for CMAUI server + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_oam_ips: + type: string + abc_oam_ips: + type: string + +resources: + + cmaui_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: p1 } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_cmaui: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_1 } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/multi/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/multi/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..641b84337f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/multi/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,143 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p1: + hidden: false + immutable: false + type: string + description: UID of OAM network + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + cmaui_oam_ips: + hidden: false + immutable: false + type: string + shared_network_id: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + jsa_net_name: + hidden: false + immutable: false + type: string + description: network name of jsa log network + node_templates: + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + name: + get_input: + - cmaui_names + - 0 + test_net: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + shared: true + network_name: + get_input: jsa_net_name + cmaui_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: shared_network_id + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: test_net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + groups: + addOn: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/addOn.yml + description: cmaui server template for vMMSC + members: + - server_cmaui + - cmaui_port_0 + main: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/main.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - test_net \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/multi/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/multi/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..1f762d0ccc --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/multi/inputfiles/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "main.yml", + "type": "HEAT", + "isBase": "true" + }, + { + "file": "addOn.yml", + "type": "HEAT", + "isBase": "false" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/multi/inputfiles/addOn.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/multi/inputfiles/addOn.yml new file mode 100644 index 0000000000..e6c5954fb0 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/multi/inputfiles/addOn.yml @@ -0,0 +1,48 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + p1: + type: string + description: UID of OAM network + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + security_group_name: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + cmaui_flavor: + type: string + description: Flavor for CMAUI server + shared_network_id: + type: string + description: Flavor for CMAUI server + cmaui_oam_ips: + type: string +resources: + + cmaui_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: shared_network_id } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_cmaui: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_0 } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/multi/inputfiles/main.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/multi/inputfiles/main.yml new file mode 100644 index 0000000000..73a2e3b45c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/multi/inputfiles/main.yml @@ -0,0 +1,20 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + jsa_net_name: + type: string + description: network name of jsa log network + +resources: + test_net: + type: OS::Neutron::Net + properties: + name: {get_param: jsa_net_name} + shared: True + +outputs: + shared_network_id: + value: {get_resource: test_net} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/nested/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/nested/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..8db67317a4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/nested/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,134 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.nested: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + cmaui_names: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p1: + type: string + description: UID of OAM network + p2: + type: string + p3: + type: string + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + security_group_name: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + availability_zone_0: + type: string + description: availabilityzone name + cmaui_oam_ips: + type: string + requirements: + - link_cmaui_port_2: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - local_storage_server_cmaui: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_cmaui_port_1: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_cmaui_port_0: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + host_server_cmaui: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + os_server_cmaui: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + endpoint_server_cmaui: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + binding_server_cmaui: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_2: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + scalable_server_cmaui: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_0: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_1: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/nested/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/nested/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..db605c9de0 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/nested/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,110 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.jsa: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + contrail_net_name: + hidden: false + immutable: false + type: string + jsa_net_name: + hidden: false + immutable: false + type: string + description: network name of jsa log network + jsa_name: + hidden: false + immutable: false + type: string + node_templates: + test_nestedInvalidConnectionToNetwork: + type: org.openecomp.resource.abstract.nodes.heat.nested + directives: + - substitutable + properties: + p1: test_nova + service_template_filter: + substitute_service_template: nestedServiceTemplate.yaml + test_contrailV2_net: + type: org.openecomp.resource.vl.nodes.heat.network.contrailV2.VirtualNetwork + properties: + network_name: + get_input: contrail_net_name + test_net: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + shared: true + network_name: + get_input: jsa_net_name + test_nova: + type: org.openecomp.resource.vfc.nodes.heat.jsa + properties: + image: image + name: + get_input: jsa_name + test_nested: + type: org.openecomp.resource.abstract.nodes.heat.nested + directives: + - substitutable + properties: + p1: test_net + service_template_filter: + substitute_service_template: nestedServiceTemplate.yaml + p2: + get_attribute: + - test_contrailV2_net + - fq_name + requirements: + - link_cmaui_port_1: + capability: tosca.capabilities.network.Linkable + node: test_contrailV2_net + relationship: tosca.relationships.network.LinksTo + - link_cmaui_port_0: + capability: tosca.capabilities.network.Linkable + node: test_net + relationship: tosca.relationships.network.LinksTo + groups: + main: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/main.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - test_nestedInvalidConnectionToNetwork + - test_contrailV2_net + - test_net + - test_nova + - test_nested \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/nested/expectedoutputfiles/nestedServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/nested/expectedoutputfiles/nestedServiceTemplate.yaml new file mode 100644 index 0000000000..12cfaca893 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/nested/expectedoutputfiles/nestedServiceTemplate.yaml @@ -0,0 +1,203 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p1: + hidden: false + immutable: false + type: string + description: UID of OAM network + p2: + hidden: false + immutable: false + type: string + p3: + hidden: false + immutable: false + type: string + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + cmaui_oam_ips: + hidden: false + immutable: false + type: string + node_templates: + cmaui_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: p3 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + name: + get_input: + - cmaui_names + - 0 + cmaui_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: p2 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + cmaui_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: p1 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + groups: + nested: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested.yml + description: cmaui server template for vMMSC + members: + - cmaui_port_2 + - server_cmaui + - cmaui_port_1 + - cmaui_port_0 + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested + capabilities: + host_server_cmaui: + - server_cmaui + - host + os_server_cmaui: + - server_cmaui + - os + endpoint_server_cmaui: + - server_cmaui + - endpoint + binding_server_cmaui: + - server_cmaui + - binding + attachment_cmaui_port_2: + - cmaui_port_2 + - attachment + scalable_server_cmaui: + - server_cmaui + - scalable + attachment_cmaui_port_0: + - cmaui_port_0 + - attachment + attachment_cmaui_port_1: + - cmaui_port_1 + - attachment + requirements: + local_storage_server_cmaui: + - server_cmaui + - local_storage + link_cmaui_port_0: + - cmaui_port_0 + - link + link_cmaui_port_2: + - cmaui_port_2 + - link + link_cmaui_port_1: + - cmaui_port_1 + - link \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/nested/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/nested/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..aca75b5055 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/nested/inputfiles/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "main.yml", + "type": "HEAT", + "isBase": "true" + }, + { + "file": "nested.yml", + "type": "HEAT", + "isBase": "false" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/nested/inputfiles/main.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/nested/inputfiles/main.yml new file mode 100644 index 0000000000..3d23ff660a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/nested/inputfiles/main.yml @@ -0,0 +1,42 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + jsa_net_name: + type: string + description: network name of jsa log network + contrail_net_name: + type: string + jsa_name: + type: string + +resources: + test_nova: + type: OS::Nova::Server + properties: + name: {get_param: jsa_name} + image: image + + test_net: + type: OS::Neutron::Net + properties: + name: {get_param: jsa_net_name} + shared: True + + test_contrailV2_net: + type: OS::ContrailV2::VirtualNetwork + properties: + name: { get_param: contrail_net_name } + + test_nested: + type: nested.yml + properties: + p1: { get_resource: test_net} + p2: { get_attr: [ test_contrailV2_net, fq_name ] } + + test_nestedInvalidConnectionToNetwork: + type: nested.yml + properties: + p1: { get_resource: test_nova} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/nested/inputfiles/nested.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/nested/inputfiles/nested.yml new file mode 100644 index 0000000000..fb2c8e12e5 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/nested/inputfiles/nested.yml @@ -0,0 +1,67 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + p1: + type: string + description: UID of OAM network + p2: + type: string + p3: + type: string + security_group_name: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_oam_ips: + type: string +resources: + + cmaui_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: p1 } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + cmaui_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: p2 } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + cmaui_port_2: + type: OS::Neutron::Port + properties: + network: { get_param: p3 } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_cmaui: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_0 } + - port: { get_resource: cmaui_port_1 } + - port: { get_resource: cmaui_port_2 } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..edb1307945 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,251 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.nested1: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + cmaui_names: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + shared_network_id1: + type: string + description: UID of OAM network + p2: + type: string + description: UID of OAM network + abc_flavor: + type: string + description: Flavor for CMAUI server + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + abc_names: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + security_group_name: + description: not impotrtant + availability_zone_0: + type: string + description: availabilityzone name + abc_oam_ips: + type: string + cmaui_oam_ips: + type: string + abc_image: + type: string + description: Image for CMAUI server + requirements: + - link_cmaui_port_2: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - local_storage_server_cmaui: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - local_storage_server_abc: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_abc_port_1: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_cmaui_port_1: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + scalable_server_abc: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + os_server_cmaui: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + attachment_abc_port_1: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + scalable_server_cmaui: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + host_server_abc: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + os_server_abc: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + host_server_cmaui: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + binding_server_abc: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + endpoint_server_cmaui: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + binding_server_cmaui: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + endpoint_server_abc: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_2: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_1: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + org.openecomp.resource.abstract.nodes.heat.nested2: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + cmaui_names: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p1: + type: string + description: UID of OAM network + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + security_group_name: + description: not impotrtant + availability_zone_0: + type: string + description: availabilityzone name + abc_oam_ips: + type: string + cmaui_oam_ips: + type: string + requirements: + - local_storage_server_cmaui: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_cmaui_port_1: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + host_server_cmaui: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + os_server_cmaui: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + endpoint_server_cmaui: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + binding_server_cmaui: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + scalable_server_cmaui: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_1: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..a762422392 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,172 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.jsa: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + shared_test_nova: + hidden: false + immutable: false + type: string + shared_network_id1: + hidden: false + immutable: false + type: string + description: network name of jsa log network + shared_network_id2: + hidden: false + immutable: false + type: string + description: network name of jsa log network + jsa_net_name: + hidden: false + immutable: false + type: string + description: network name of jsa log network + jsa_name: + hidden: false + immutable: false + type: string + node_templates: + test_nestedInvalidConnectionToNetwork: + type: org.openecomp.resource.abstract.nodes.heat.nested1 + directives: + - substitutable + properties: + service_template_filter: + substitute_service_template: nested1ServiceTemplate.yaml + shared_network_id1: + get_input: shared_test_nova + test_net2: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + shared: true + network_name: + get_input: jsa_net_name + test_nested2: + type: org.openecomp.resource.abstract.nodes.heat.nested2 + directives: + - substitutable + properties: + p1: + get_input: shared_network_id1 + service_template_filter: + substitute_service_template: nested2ServiceTemplate.yaml + requirements: + - link_cmaui_port_1: + capability: tosca.capabilities.network.Linkable + node: test_net1 + relationship: tosca.relationships.network.LinksTo + test_nested3: + type: org.openecomp.resource.abstract.nodes.heat.nested1 + directives: + - substitutable + properties: + service_template_filter: + substitute_service_template: nested1ServiceTemplate.yaml + shared_network_id1: + get_input: shared_network_id1 + p2: + get_input: shared_network_id2 + requirements: + - link_cmaui_port_2: + capability: tosca.capabilities.network.Linkable + node: test_net2 + relationship: tosca.relationships.network.LinksTo + - link_abc_port_1: + capability: tosca.capabilities.network.Linkable + node: test_net2 + relationship: tosca.relationships.network.LinksTo + - link_cmaui_port_1: + capability: tosca.capabilities.network.Linkable + node: test_net1 + relationship: tosca.relationships.network.LinksTo + test_net1: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + shared: true + network_name: + get_input: jsa_net_name + test_nested1: + type: org.openecomp.resource.abstract.nodes.heat.nested1 + directives: + - substitutable + properties: + service_template_filter: + substitute_service_template: nested1ServiceTemplate.yaml + shared_network_id1: + get_input: shared_network_id1 + p2: + get_input: shared_network_id2 + requirements: + - link_cmaui_port_2: + capability: tosca.capabilities.network.Linkable + node: test_net2 + relationship: tosca.relationships.network.LinksTo + - link_abc_port_1: + capability: tosca.capabilities.network.Linkable + node: test_net2 + relationship: tosca.relationships.network.LinksTo + - link_cmaui_port_1: + capability: tosca.capabilities.network.Linkable + node: test_net1 + relationship: tosca.relationships.network.LinksTo + test_nova: + type: org.openecomp.resource.vfc.nodes.heat.jsa + properties: + image: image + name: + get_input: jsa_name + groups: + addOn: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/addOn.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - test_nestedInvalidConnectionToNetwork + - test_nested2 + - test_nested3 + - test_nested1 + main: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/main.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - test_net2 + - test_net1 + - test_nova \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/expectedoutputfiles/nested1ServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/expectedoutputfiles/nested1ServiceTemplate.yaml new file mode 100644 index 0000000000..2096251177 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/expectedoutputfiles/nested1ServiceTemplate.yaml @@ -0,0 +1,252 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested1 +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.abc: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + shared_network_id1: + hidden: false + immutable: false + type: string + description: UID of OAM network + p2: + hidden: false + immutable: false + type: string + description: UID of OAM network + abc_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + abc_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + security_group_name: + hidden: false + immutable: false + description: not impotrtant + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + abc_oam_ips: + hidden: false + immutable: false + type: string + cmaui_oam_ips: + hidden: false + immutable: false + type: string + abc_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + node_templates: + cmaui_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: p2 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + name: + get_input: + - cmaui_names + - 0 + server_abc: + type: org.openecomp.resource.vfc.nodes.heat.abc + properties: + flavor: + get_input: abc_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: abc_image + name: + get_input: + - abc_names + - 0 + abc_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - abc_oam_ips + - 0 + network: + get_input: p2 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_abc + relationship: tosca.relationships.network.BindsTo + cmaui_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: shared_network_id1 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + groups: + nested1: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested1.yml + description: cmaui server template for vMMSC + members: + - cmaui_port_2 + - server_cmaui + - server_abc + - abc_port_1 + - cmaui_port_1 + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested1 + capabilities: + scalable_server_abc: + - server_abc + - scalable + os_server_cmaui: + - server_cmaui + - os + attachment_abc_port_1: + - abc_port_1 + - attachment + scalable_server_cmaui: + - server_cmaui + - scalable + host_server_abc: + - server_abc + - host + os_server_abc: + - server_abc + - os + host_server_cmaui: + - server_cmaui + - host + binding_server_abc: + - server_abc + - binding + endpoint_server_cmaui: + - server_cmaui + - endpoint + binding_server_cmaui: + - server_cmaui + - binding + endpoint_server_abc: + - server_abc + - endpoint + attachment_cmaui_port_2: + - cmaui_port_2 + - attachment + attachment_cmaui_port_1: + - cmaui_port_1 + - attachment + requirements: + local_storage_server_cmaui: + - server_cmaui + - local_storage + link_abc_port_1: + - abc_port_1 + - link + link_cmaui_port_2: + - cmaui_port_2 + - link + link_cmaui_port_1: + - cmaui_port_1 + - link + local_storage_server_abc: + - server_abc + - local_storage \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/expectedoutputfiles/nested2ServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/expectedoutputfiles/nested2ServiceTemplate.yaml new file mode 100644 index 0000000000..992e1c017c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/expectedoutputfiles/nested2ServiceTemplate.yaml @@ -0,0 +1,146 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested2 +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p1: + hidden: false + immutable: false + type: string + description: UID of OAM network + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + security_group_name: + hidden: false + immutable: false + description: not impotrtant + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + abc_oam_ips: + hidden: false + immutable: false + type: string + cmaui_oam_ips: + hidden: false + immutable: false + type: string + node_templates: + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + name: + get_input: + - cmaui_names + - 0 + cmaui_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: p1 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + groups: + nested2: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested2.yml + description: cmaui server template for vMMSC + members: + - server_cmaui + - cmaui_port_1 + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested2 + capabilities: + host_server_cmaui: + - server_cmaui + - host + os_server_cmaui: + - server_cmaui + - os + endpoint_server_cmaui: + - server_cmaui + - endpoint + binding_server_cmaui: + - server_cmaui + - binding + scalable_server_cmaui: + - server_cmaui + - scalable + attachment_cmaui_port_1: + - cmaui_port_1 + - attachment + requirements: + local_storage_server_cmaui: + - server_cmaui + - local_storage + link_cmaui_port_1: + - cmaui_port_1 + - link \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..e593097c44 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/inputfiles/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "main.yml", + "type": "HEAT", + "isBase": "true" + }, + { + "file": "nested1.yml", + "type": "HEAT", + "isBase": "false" + }, + { + "file": "nested2.yml", + "type": "HEAT", + "isBase": "false" + }, + { + "file": "addOn.yml", + "type": "HEAT", + "isBase": "false" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/inputfiles/addOn.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/inputfiles/addOn.yml new file mode 100644 index 0000000000..ca1cf7d31d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/inputfiles/addOn.yml @@ -0,0 +1,38 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + shared_network_id1: + type: string + description: network name of jsa log network + + shared_network_id2: + type: string + description: network name of jsa log network + shared_test_nova: + type: string +resources: + + test_nested1: + type: nested1.yml + properties: + shared_network_id1: { get_param: shared_network_id1} + p2: { get_param: shared_network_id2} + + test_nested2: + type: nested2.yml + properties: + p1: { get_param: shared_network_id1} + + test_nested3: + type: nested1.yml + properties: + shared_network_id1: { get_param: shared_network_id1} + p2: { get_param: shared_network_id2} + + test_nestedInvalidConnectionToNetwork: + type: nested1.yml + properties: + shared_network_id1: { get_param: shared_test_nova} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/inputfiles/main.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/inputfiles/main.yml new file mode 100644 index 0000000000..3c015747ff --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/inputfiles/main.yml @@ -0,0 +1,39 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + jsa_net_name: + type: string + description: network name of jsa log network + + jsa_name: + type: string + +resources: + test_net1: + type: OS::Neutron::Net + properties: + name: {get_param: jsa_net_name} + shared: True + + test_net2: + type: OS::Neutron::Net + properties: + name: {get_param: jsa_net_name} + shared: True + + test_nova: + type: OS::Nova::Server + properties: + name: {get_param: jsa_name} + image: image + +outputs: + shared_network_id1: + value: {get_resource: test_net1} + shared_network_id2: + value: {get_resource: test_net2} + shared_test_nova: + value: {get_resource: test_nova} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/inputfiles/nested1.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/inputfiles/nested1.yml new file mode 100644 index 0000000000..9ad6c61f17 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/inputfiles/nested1.yml @@ -0,0 +1,86 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + shared_network_id1: + type: string + description: UID of OAM network + p2: + type: string + description: UID of OAM network + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + abc_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + security_group_name: + type: not_important + description: not impotrtant + cmaui_image: + type: string + description: Image for CMAUI server + abc_image: + type: string + description: Image for CMAUI server + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + cmaui_flavor: + type: string + description: Flavor for CMAUI server + abc_flavor: + type: string + description: Flavor for CMAUI server + cmaui_oam_ips: + type: string + abc_oam_ips: + type: string +resources: + + cmaui_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: shared_network_id1 } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + cmaui_port_2: + type: OS::Neutron::Port + properties: + network: { get_param: p2 } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + abc_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: p2 } + fixed_ips: [{"ip_address": {get_param: [abc_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_cmaui: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_1 } + - port: { get_resource: cmaui_port_2 } + + server_abc: + type: OS::Nova::Server + properties: + name: { get_param: [abc_names, 0]} + image: { get_param: abc_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: abc_flavor } + networks: + - port: { get_resource: abc_port_1 } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/inputfiles/nested2.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/inputfiles/nested2.yml new file mode 100644 index 0000000000..b09d3aff8e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetconnection/shared/inputfiles/nested2.yml @@ -0,0 +1,48 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + p1: + type: string + description: UID of OAM network + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + security_group_name: + type: not_important + description: not impotrtant + cmaui_image: + type: string + description: Image for CMAUI server + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_oam_ips: + type: string + abc_oam_ips: + type: string + +resources: + + cmaui_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: p1 } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_cmaui: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_1 } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetresourcegroupconnection/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetresourcegroupconnection/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..44aca0ee4d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetresourcegroupconnection/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,106 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.nested: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + cmaui_names: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p1: + type: string + description: UID of OAM network + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + security_group_name: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + availability_zone_0: + type: string + description: availabilityzone name + cmaui_oam_ips: + type: string + requirements: + - local_storage_server_cmaui: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_cmaui_port_0: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + host_server_cmaui: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + os_server_cmaui: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + endpoint_server_cmaui: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + binding_server_cmaui: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + scalable_server_cmaui: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_0: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetresourcegroupconnection/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetresourcegroupconnection/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..c364c62d6d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetresourcegroupconnection/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,85 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + jsa_net_name: + hidden: false + immutable: false + type: string + description: network name of jsa log network + node_templates: + mvs_modules: + type: org.openecomp.resource.abstract.nodes.heat.nested + directives: + - substitutable + properties: + p1: test_net + service_template_filter: + substitute_service_template: nestedServiceTemplate.yaml + count: 3 + mandatory: true + requirements: + - link_cmaui_port_0: + capability: tosca.capabilities.network.Linkable + node: test_net + relationship: tosca.relationships.network.LinksTo + test_net: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + shared: true + network_name: + get_input: jsa_net_name + test_nested: + type: org.openecomp.resource.abstract.nodes.heat.nested + directives: + - substitutable + properties: + p1: test_net + service_template_filter: + substitute_service_template: nestedServiceTemplate.yaml + requirements: + - link_cmaui_port_0: + capability: tosca.capabilities.network.Linkable + node: test_net + relationship: tosca.relationships.network.LinksTo + groups: + main: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/main.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - mvs_modules + - test_net + - test_nested \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetresourcegroupconnection/expectedoutputfiles/nestedServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetresourcegroupconnection/expectedoutputfiles/nestedServiceTemplate.yaml new file mode 100644 index 0000000000..cfe7f567c5 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetresourcegroupconnection/expectedoutputfiles/nestedServiceTemplate.yaml @@ -0,0 +1,145 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p1: + hidden: false + immutable: false + type: string + description: UID of OAM network + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + security_group_name: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + cmaui_oam_ips: + hidden: false + immutable: false + type: string + node_templates: + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + name: + get_input: + - cmaui_names + - 0 + cmaui_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: p1 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + groups: + nested: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested.yml + description: cmaui server template for vMMSC + members: + - server_cmaui + - cmaui_port_0 + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested + capabilities: + host_server_cmaui: + - server_cmaui + - host + os_server_cmaui: + - server_cmaui + - os + endpoint_server_cmaui: + - server_cmaui + - endpoint + binding_server_cmaui: + - server_cmaui + - binding + scalable_server_cmaui: + - server_cmaui + - scalable + attachment_cmaui_port_0: + - cmaui_port_0 + - attachment + requirements: + local_storage_server_cmaui: + - server_cmaui + - local_storage + link_cmaui_port_0: + - cmaui_port_0 + - link \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetresourcegroupconnection/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetresourcegroupconnection/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..aca75b5055 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetresourcegroupconnection/inputfiles/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "main.yml", + "type": "HEAT", + "isBase": "true" + }, + { + "file": "nested.yml", + "type": "HEAT", + "isBase": "false" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetresourcegroupconnection/inputfiles/main.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetresourcegroupconnection/inputfiles/main.yml new file mode 100644 index 0000000000..eaedecd792 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetresourcegroupconnection/inputfiles/main.yml @@ -0,0 +1,31 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + jsa_net_name: + type: string + description: network name of jsa log network + +resources: + test_net: + type: OS::Neutron::Net + properties: + name: {get_param: jsa_net_name} + shared: True + + test_nested: + type: nested.yml + properties: + p1: { get_resource: test_net} + + mvs_modules: + type: OS::Heat::ResourceGroup + properties: + count: 3 + index_var: "%index%" + resource_def: + type: nested.yml + properties: + p1: { get_resource: test_net} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetresourcegroupconnection/inputfiles/nested.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetresourcegroupconnection/inputfiles/nested.yml new file mode 100644 index 0000000000..56a099500b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttonetresourcegroupconnection/inputfiles/nested.yml @@ -0,0 +1,45 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + p1: + type: string + description: UID of OAM network + security_group_name: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_oam_ips: + type: string +resources: + + cmaui_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: p1 } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_cmaui: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_0 } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttosharednetresourcegrouplinking/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttosharednetresourcegrouplinking/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..8744a29bc3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttosharednetresourcegrouplinking/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,177 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.nested1: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + cmaui_names: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p1: + type: string + description: UID of OAM network + p2: + type: string + description: UID of OAM network + abc_flavor: + type: string + description: Flavor for CMAUI server + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + abc_names: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + security_group_name: + description: not impotrtant + availability_zone_0: + type: string + description: availabilityzone name + abc_oam_ips: + type: string + cmaui_oam_ips: + type: string + abc_image: + type: string + description: Image for CMAUI server + requirements: + - link_cmaui_port_2: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - local_storage_server_cmaui: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - local_storage_server_abc: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_abc_port_1: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - link_cmaui_port_1: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + scalable_server_abc: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + os_server_cmaui: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + attachment_abc_port_1: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + scalable_server_cmaui: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + host_server_abc: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + os_server_abc: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + host_server_cmaui: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + binding_server_abc: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + endpoint_server_cmaui: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + binding_server_cmaui: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + endpoint_server_abc: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_2: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_1: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttosharednetresourcegrouplinking/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttosharednetresourcegrouplinking/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..5a6dfd9376 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttosharednetresourcegrouplinking/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,131 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + shared_network_id1: + hidden: false + immutable: false + type: string + description: network name of jsa log network + shared_network_id2: + hidden: false + immutable: false + type: string + description: network name of jsa log network + jsa_net_name: + hidden: false + immutable: false + type: string + description: network name of jsa log network + node_templates: + mvs_modules: + type: org.openecomp.resource.abstract.nodes.heat.nested1 + directives: + - substitutable + properties: + p1: + get_input: shared_network_id1 + service_template_filter: + substitute_service_template: nested1ServiceTemplate.yaml + count: 3 + mandatory: true + p2: + get_input: shared_network_id2 + requirements: + - link_cmaui_port_2: + capability: tosca.capabilities.network.Linkable + node: test_net2 + relationship: tosca.relationships.network.LinksTo + - link_abc_port_1: + capability: tosca.capabilities.network.Linkable + node: test_net2 + relationship: tosca.relationships.network.LinksTo + - link_cmaui_port_1: + capability: tosca.capabilities.network.Linkable + node: test_net1 + relationship: tosca.relationships.network.LinksTo + test_net2: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + shared: true + network_name: + get_input: jsa_net_name + test_net1: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + shared: true + network_name: + get_input: jsa_net_name + test_nested1: + type: org.openecomp.resource.abstract.nodes.heat.nested1 + directives: + - substitutable + properties: + p1: + get_input: shared_network_id1 + service_template_filter: + substitute_service_template: nested1ServiceTemplate.yaml + p2: + get_input: shared_network_id2 + requirements: + - link_cmaui_port_2: + capability: tosca.capabilities.network.Linkable + node: test_net2 + relationship: tosca.relationships.network.LinksTo + - link_abc_port_1: + capability: tosca.capabilities.network.Linkable + node: test_net2 + relationship: tosca.relationships.network.LinksTo + - link_cmaui_port_1: + capability: tosca.capabilities.network.Linkable + node: test_net1 + relationship: tosca.relationships.network.LinksTo + groups: + addOn: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/addOn.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - mvs_modules + - test_nested1 + main: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/main.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - test_net2 + - test_net1 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttosharednetresourcegrouplinking/expectedoutputfiles/nested1ServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttosharednetresourcegrouplinking/expectedoutputfiles/nested1ServiceTemplate.yaml new file mode 100644 index 0000000000..cd5b767492 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttosharednetresourcegrouplinking/expectedoutputfiles/nested1ServiceTemplate.yaml @@ -0,0 +1,252 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested1 +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.abc: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p1: + hidden: false + immutable: false + type: string + description: UID of OAM network + p2: + hidden: false + immutable: false + type: string + description: UID of OAM network + abc_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + abc_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + security_group_name: + hidden: false + immutable: false + description: not impotrtant + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + abc_oam_ips: + hidden: false + immutable: false + type: string + cmaui_oam_ips: + hidden: false + immutable: false + type: string + abc_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + node_templates: + cmaui_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: p2 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + name: + get_input: + - cmaui_names + - 0 + server_abc: + type: org.openecomp.resource.vfc.nodes.heat.abc + properties: + flavor: + get_input: abc_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: abc_image + name: + get_input: + - abc_names + - 0 + abc_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - abc_oam_ips + - 0 + network: + get_input: p2 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_abc + relationship: tosca.relationships.network.BindsTo + cmaui_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: p1 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + groups: + nested1: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested1.yml + description: cmaui server template for vMMSC + members: + - cmaui_port_2 + - server_cmaui + - server_abc + - abc_port_1 + - cmaui_port_1 + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested1 + capabilities: + scalable_server_abc: + - server_abc + - scalable + os_server_cmaui: + - server_cmaui + - os + attachment_abc_port_1: + - abc_port_1 + - attachment + scalable_server_cmaui: + - server_cmaui + - scalable + host_server_abc: + - server_abc + - host + os_server_abc: + - server_abc + - os + host_server_cmaui: + - server_cmaui + - host + binding_server_abc: + - server_abc + - binding + endpoint_server_cmaui: + - server_cmaui + - endpoint + binding_server_cmaui: + - server_cmaui + - binding + endpoint_server_abc: + - server_abc + - endpoint + attachment_cmaui_port_2: + - cmaui_port_2 + - attachment + attachment_cmaui_port_1: + - cmaui_port_1 + - attachment + requirements: + local_storage_server_cmaui: + - server_cmaui + - local_storage + link_abc_port_1: + - abc_port_1 + - link + link_cmaui_port_2: + - cmaui_port_2 + - link + link_cmaui_port_1: + - cmaui_port_1 + - link + local_storage_server_abc: + - server_abc + - local_storage \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttosharednetresourcegrouplinking/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttosharednetresourcegrouplinking/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..4f3d9058b2 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttosharednetresourcegrouplinking/inputfiles/MANIFEST.json @@ -0,0 +1,22 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "main.yml", + "type": "HEAT", + "isBase": "true" + }, + { + "file": "nested1.yml", + "type": "HEAT", + "isBase": "false" + }, + { + "file": "addOn.yml", + "type": "HEAT", + "isBase": "false" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttosharednetresourcegrouplinking/inputfiles/addOn.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttosharednetresourcegrouplinking/inputfiles/addOn.yml new file mode 100644 index 0000000000..10e477919f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttosharednetresourcegrouplinking/inputfiles/addOn.yml @@ -0,0 +1,32 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + shared_network_id1: + type: string + description: network name of jsa log network + + shared_network_id2: + type: string + description: network name of jsa log network + +resources: + + test_nested1: + type: nested1.yml + properties: + p1: { get_param: shared_network_id1} + p2: { get_param: shared_network_id2} + + mvs_modules: + type: OS::Heat::ResourceGroup + properties: + count: 3 + index_var: "%index%" + resource_def: + type: nested1.yml + properties: + p1: { get_param: shared_network_id1} + p2: { get_param: shared_network_id2} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttosharednetresourcegrouplinking/inputfiles/main.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttosharednetresourcegrouplinking/inputfiles/main.yml new file mode 100644 index 0000000000..9601c0f86d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttosharednetresourcegrouplinking/inputfiles/main.yml @@ -0,0 +1,29 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + jsa_net_name: + type: string + description: network name of jsa log network + +resources: + test_net1: + type: OS::Neutron::Net + properties: + name: {get_param: jsa_net_name} + shared: True + + test_net2: + type: OS::Neutron::Net + properties: + name: {get_param: jsa_net_name} + shared: True + +outputs: + shared_network_id1: + value: {get_resource: test_net1} + + shared_network_id2: + value: {get_resource: test_net2} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttosharednetresourcegrouplinking/inputfiles/nested1.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttosharednetresourcegrouplinking/inputfiles/nested1.yml new file mode 100644 index 0000000000..f46cf21121 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/porttosharednetresourcegrouplinking/inputfiles/nested1.yml @@ -0,0 +1,86 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + p1: + type: string + description: UID of OAM network + p2: + type: string + description: UID of OAM network + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + abc_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + security_group_name: + type: not_important + description: not impotrtant + cmaui_image: + type: string + description: Image for CMAUI server + abc_image: + type: string + description: Image for CMAUI server + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + cmaui_flavor: + type: string + description: Flavor for CMAUI server + abc_flavor: + type: string + description: Flavor for CMAUI server + cmaui_oam_ips: + type: string + abc_oam_ips: + type: string +resources: + + cmaui_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: p1 } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + cmaui_port_2: + type: OS::Neutron::Port + properties: + network: { get_param: p2 } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + abc_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: p2 } + fixed_ips: [{"ip_address": {get_param: [abc_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + server_cmaui: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_1 } + - port: { get_resource: cmaui_port_2 } + + server_abc: + type: OS::Nova::Server + properties: + name: { get_param: [abc_names, 0]} + image: { get_param: abc_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: abc_flavor } + networks: + - port: { get_resource: abc_port_1 } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securitygrouptonovaconnectionmulti/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securitygrouptonovaconnectionmulti/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..c253158ad4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securitygrouptonovaconnectionmulti/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,634 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.smp: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + hostid_fe1: + hidden: false + immutable: false + type: string + description: FE1 Hostid (from Ulticom license) + ip_address_stp2: + hidden: false + immutable: false + type: string + description: STP2 IP address + Mobility_OAM_protected_net_id: + hidden: false + immutable: false + type: string + description: Network name for OAM + hostid_fe2: + hidden: false + immutable: false + type: string + description: FE2 Hostid (from Ulticom license) + flavor_scp_fe_name: + hidden: false + immutable: false + type: string + description: SCP FE Flavor + default: a1.Small + ip_address_stp1: + hidden: false + immutable: false + type: string + description: STP1 IP address + int_vscp_ce_network_net_id: + hidden: false + immutable: false + type: string + description: Inter-CE Network + int_vscp_ce_network_cidr: + hidden: false + immutable: false + type: string + description: Private Network Address (CIDR notation) + cluster_type: + hidden: false + immutable: false + type: string + constraints: + - valid_values: + - Test + - Prod + be_Mobility_OAM_protected_ip_1: + label: be_1 OAM ip address + hidden: false + immutable: false + type: string + description: be_1 OAM ip address + be_Mobility_OAM_protected_ip_2: + label: be_2 OAM ip address + hidden: false + immutable: false + type: string + description: be_2 OAM ip address + be_Mobility_OAM_protected_ip_0: + label: be_0 OAM ip address + hidden: false + immutable: false + type: string + description: be_0 OAM ip address + ip_address_dra: + hidden: false + immutable: false + type: string + description: DRA VIP address + image_smp_name: + hidden: false + immutable: false + type: string + description: SCP SMP image + default: asc_base_image_smp + fe_connectivity: + hidden: false + immutable: false + type: string + constraints: + - valid_values: + - NEE + - STP + lab_name: + hidden: false + immutable: false + type: string + description: Lab name + smp_Mobility_OAM_protected_ip_1: + label: smp_1 OAM ip address + hidden: false + immutable: false + type: string + description: smp_1 OAM ip address + fe_SIGNET_vrf_B1_direct_ip_0: + label: fe1 SIGTRAN ip address + hidden: false + immutable: false + type: string + description: fe1 SIGTRAN ip address + smp_Mobility_OAM_protected_ip_0: + label: smp_0 OAM ip address + hidden: false + immutable: false + type: string + description: smp_0 OAM ip address + int_vscp_cluster_net_id: + hidden: false + immutable: false + type: string + description: LAN3 Cluster + be_Mobility_OAM_protected_ip_3: + label: be_3 OAM ip address + hidden: false + immutable: false + type: string + description: be_3 OAM ip address + be_Mobility_OAM_protected_ip_4: + label: be_4 OAM ip address + hidden: false + immutable: false + type: string + description: be_4 OAM ip address + hostname_nee1: + hidden: false + immutable: false + type: string + description: NEE1 Hostname (from Ulticom license) + int_vscp_fe_cluster_net_id: + hidden: false + immutable: false + type: string + description: LAN2 FE Cluster/KA + SIGNET_vrf_A1_direct_net_id: + hidden: false + immutable: false + type: string + description: Network name for SIGTRAN_A + key_name: + hidden: false + immutable: false + type: string + description: keypair to enable SSH access to the instance. + default: vSCP-keypair + int_vscp_fe_cluster_cidr: + hidden: false + immutable: false + type: string + description: Private Network2 Address (CIDR notation) + fe_name_1: + hidden: false + immutable: false + type: string + description: name of VM + default: vSCP_FE2 + fe_name_0: + hidden: false + immutable: false + type: string + description: name of VM + default: vSCP_FE1 + be_name_0: + hidden: false + immutable: false + type: string + description: name of VM + default: vSCP_BE1 + int_vscp_cluster_cidr: + hidden: false + immutable: false + type: string + description: Private Network3 Address (CIDR notation) + be_name_1: + hidden: false + immutable: false + type: string + description: name of VM + default: vSCP_BE2 + be_name_2: + hidden: false + immutable: false + type: string + description: name of VM + default: vSCP_BE3 + point_code_stp: + hidden: false + immutable: false + type: string + description: STP virtual point code (in "zone-cluster-member" format) + be_name_3: + hidden: false + immutable: false + type: string + description: name of VM + default: vSCP_BE4 + be_name_4: + hidden: false + immutable: false + type: string + description: name of VM + default: vSCP_BE5 + global_title_scp: + hidden: false + immutable: false + type: string + description: vSCP Global Title address + vnf_name: + hidden: false + immutable: false + type: string + description: Unique name for this VNF instance + default: This_is_the_SCP_name + be_Cricket_OCS_protected_ip_2: + label: be3 Cricket_OCS ip address + hidden: false + immutable: false + type: string + description: be3 Cricket_OCS ip address + fe_Mobility_OAM_protected_ip_0: + label: fe_0 OAM ip address + hidden: false + immutable: false + type: string + description: fe_0 OAM ip address + hostname_fe1: + hidden: false + immutable: false + type: string + description: FE1 Hostname (from Ulticom license) + be_Cricket_OCS_protected_ip_1: + label: be2 Cricket_OCS ip address + hidden: false + immutable: false + type: string + description: be2 Cricket_OCS ip address + hostname_fe2: + hidden: false + immutable: false + type: string + description: FE2 Hostname (from Ulticom license) + be_Cricket_OCS_protected_ip_4: + label: be5 Cricket_OCS ip address + hidden: false + immutable: false + type: string + description: be5 Cricket_OCS ip address + be_Cricket_OCS_protected_ip_3: + label: be4 Cricket_OCS ip address + hidden: false + immutable: false + type: string + description: be4 Cricket_OCS ip address + fe_Mobility_OAM_protected_ip_1: + label: fe_1 OAM ip address + hidden: false + immutable: false + type: string + description: fe_1 OAM ip address + be_Cricket_OCS_protected_ip_0: + label: be1 Cricket_OCS ip address + hidden: false + immutable: false + type: string + description: be1 Cricket_OCS ip address + route_table_fe1: + hidden: false + immutable: false + type: string + description: Additional route table for FE1 + Cricket_OCS_protected_net_id: + hidden: false + immutable: false + type: string + description: Network name for CRICKET_OCS + smp_name_2: + hidden: false + immutable: false + type: string + description: name of VM + default: vSMP2 + vnf_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VNF instance + default: This_is_ths_SCP_id + smp_name_1: + hidden: false + immutable: false + type: string + description: name of VM + default: vSMP2 + flavor_smp_name: + hidden: false + immutable: false + type: string + description: SCP SMP Flavor + default: a1.Small + image_scp_be_name: + hidden: false + immutable: false + type: string + description: SCP BE image + default: asc_base_image_be + smp_name_0: + hidden: false + immutable: false + type: string + description: name of VM + default: vSMP1 + route_table_fe2: + hidden: false + immutable: false + type: string + description: Additional route table for FE2 + hostid_nee1: + hidden: false + immutable: false + type: string + description: NEE1 Hostid (from Ulticom license) + SIGNET_vrf_B1_direct_net_id: + hidden: false + immutable: false + type: string + description: Network name for SIGTRAN_B + fe_SIGNET_vrf_A1_direct_ip_0: + label: fe2 SIGTRAN ip address + hidden: false + immutable: false + type: string + description: fe2 SIGTRAN ip address + availability_zone_0: + hidden: false + immutable: false + type: string + nee_name_0: + hidden: false + immutable: false + type: string + description: name of VM + default: vNEE + fe_smp_affinity_param: + hidden: false + immutable: false + type: string + description: be affinity param + ip_port_stp1: + hidden: false + immutable: false + type: string + description: STP1 IP port + ip_port_stp2: + hidden: false + immutable: false + type: string + description: STP2 IP port + image_scp_fe_name: + hidden: false + immutable: false + type: string + description: SCP FE image + default: asc_base_image_fe + flavor_scp_be_name: + hidden: false + immutable: false + type: string + description: SCP BE Flavor + default: a1.Small + security_group_name: + label: vSCP security group name + hidden: false + immutable: false + type: string + description: vSCP security group name + ip_port_fe2: + hidden: false + immutable: false + type: string + description: FE2 IP port in SIGTRAN network + route_table_be: + hidden: false + immutable: false + type: string + description: Additional route table for BEs + ip_port_fe1: + hidden: false + immutable: false + type: string + description: FE1 IP port in SIGTRAN network + port_name: + hidden: false + immutable: false + type: string + description: port name + default: port_name + be_affinity_param: + hidden: false + immutable: false + type: string + description: be affinity param + point_code_scp: + hidden: false + immutable: false + type: string + description: vSCP point code (in "zone-cluster-member" format) + global_title_stp: + hidden: false + immutable: false + type: string + description: STP Global Title address + point_code_stp1: + hidden: false + immutable: false + type: string + description: STP1 point code (in "zone-cluster-member" format) + point_code_stp2: + hidden: false + immutable: false + type: string + description: STP2 point code (in "zone-cluster-member" format) + multi_anti_affinity_param: + hidden: false + immutable: false + type: string + description: be affinity param + node_templates: + server_smp2: + type: org.openecomp.resource.vfc.nodes.heat.smp + properties: + flavor: + get_input: flavor_smp_name + availability_zone: + get_input: availability_zone_0 + image: + get_input: image_smp_name + metadata: + jx_vm_role: smp2 + vnf_id: + get_input: vnf_id + jx_lab_name: + get_input: lab_name + user_data_format: RAW + name: + get_input: smp_name_2 + scheduler_hints: + group: + get_input: fe_smp_affinity_param + server_smp3: + type: org.openecomp.resource.vfc.nodes.heat.smp + properties: + flavor: + get_input: flavor_smp_name + availability_zone: + get_input: availability_zone_0 + image: + get_input: image_smp_name + metadata: + jx_vm_role: smp2 + vnf_id: + get_input: vnf_id + jx_lab_name: + get_input: lab_name + user_data_format: RAW + name: + get_input: smp_name_2 + scheduler_hints: + group2: + get_input: multi_anti_affinity_param + group1: + get_input: fe_smp_affinity_param + port3: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + network: + get_input: port_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_smp3 + relationship: tosca.relationships.network.BindsTo + port4: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + network: + get_input: port_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_smp3 + relationship: tosca.relationships.network.BindsTo + port1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + network: + get_input: port_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_smp1 + relationship: tosca.relationships.network.BindsTo + port2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + network: + get_input: port_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_smp2 + relationship: tosca.relationships.network.BindsTo + server_smp1: + type: org.openecomp.resource.vfc.nodes.heat.smp + properties: + flavor: + get_input: flavor_smp_name + availability_zone: + get_input: availability_zone_0 + image: + get_input: image_smp_name + metadata: + jx_vm_role: smp2 + vnf_id: + get_input: vnf_id + jx_lab_name: + get_input: lab_name + user_data_format: RAW + name: + get_input: smp_name_1 + scheduler_hints: + group: + get_input: be_affinity_param + groups: + FE_SMP_Affinity: + type: tosca.groups.Root + members: + - server_smp2 + - server_smp3 + Multi_Anti_Affinity: + type: tosca.groups.Root + members: + - server_smp3 + addOn1: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/addOn1.yml + description: ASC Template + members: + - port1 + - server_smp1 + addOn3: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/addOn3.yml + description: ASC Template + members: + - server_smp3 + - port3 + - port4 + addOn2: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/addOn2.yml + description: ASC Template + members: + - server_smp2 + - port2 + BE_Affinity: + type: tosca.groups.Root + members: + - server_smp1 + policies: + FE_SMP_Affinity: + type: org.openecomp.policies.placement.Colocate + properties: + name: abc + affinity: host + targets: + - FE_SMP_Affinity + Multi_Anti_Affinity: + type: org.openecomp.policies.placement.Antilocate + properties: + name: def + container_type: host + targets: + - Multi_Anti_Affinity + BE_Affinity: + type: org.openecomp.policies.placement.Colocate + properties: + name: def + affinity: host + targets: + - BE_Affinity \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securitygrouptonovaconnectionmulti/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securitygrouptonovaconnectionmulti/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..bcc4ef51b1 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securitygrouptonovaconnectionmulti/inputfiles/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "main.yml", + "type": "HEAT", + "isBase": "true" + }, + { + "file": "addOn1.yml", + "type": "HEAT", + "isBase": "false" + }, + { + "file": "addOn2.yml", + "type": "HEAT", + "isBase": "false" + }, + { + "file": "addOn3.yml", + "type": "HEAT", + "isBase": "false" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securitygrouptonovaconnectionmulti/inputfiles/addOn1.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securitygrouptonovaconnectionmulti/inputfiles/addOn1.yml new file mode 100644 index 0000000000..79306fe04e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securitygrouptonovaconnectionmulti/inputfiles/addOn1.yml @@ -0,0 +1,57 @@ +heat_template_version: 2013-05-23 + +description: ASC Template + +parameters: + be_affinity_param: + type: string + description: be affinity param + availability_zone_0: + type: string + vnf_id: + type: string + description: Unique ID for this VNF instance + default: This_is_ths_SCP_id + port_name: + type: string + description: port name + default: port_name + flavor_smp_name: + type: string + description: SCP SMP Flavor + default: a1.Small + image_smp_name: + type: string + description: SCP SMP image + default: asc_base_image_smp + smp_name_1: + type: string + default: vSMP2 + description: name of VM + lab_name: + type: string + description: Lab name + +resources: + + server_smp1: + type: OS::Nova::Server + properties: + name: { get_param: smp_name_1 } + image: { get_param: image_smp_name } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: flavor_smp_name } + scheduler_hints: { group: { get_param: be_affinity_param} } + networks: + - port: { get_resource: port1 } + metadata: + vnf_id: { get_param: vnf_id } + jx_lab_name: {get_param: lab_name} + jx_vm_role: smp2 + user_data_format: RAW + + port1: + type: OS::Neutron::Port + properties: + network: {get_param: port_name} + replacement_policy: AUTO diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securitygrouptonovaconnectionmulti/inputfiles/addOn2.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securitygrouptonovaconnectionmulti/inputfiles/addOn2.yml new file mode 100644 index 0000000000..9918c0bfda --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securitygrouptonovaconnectionmulti/inputfiles/addOn2.yml @@ -0,0 +1,57 @@ +heat_template_version: 2013-05-23 + +description: ASC Template + +parameters: + fe_smp_affinity_param: + type: string + description: be affinity param + availability_zone_0: + type: string + vnf_id: + type: string + description: Unique ID for this VNF instance + default: This_is_ths_SCP_id + port_name: + type: string + description: port name + default: port_name + flavor_smp_name: + type: string + description: SCP SMP Flavor + default: a1.Small + image_smp_name: + type: string + description: SCP SMP image + default: asc_base_image_smp + smp_name_2: + type: string + default: vSMP2 + description: name of VM + lab_name: + type: string + description: Lab name + +resources: + server_smp2: + type: OS::Nova::Server + properties: + name: { get_param: smp_name_2 } + image: { get_param: image_smp_name } + # key_name: { get_param: key_name } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: flavor_smp_name } + scheduler_hints: { group: { get_param: fe_smp_affinity_param } } + networks: + - port: { get_resource: port2 } + metadata: + vnf_id: { get_param: vnf_id } + jx_lab_name: {get_param: lab_name} + jx_vm_role: smp2 + user_data_format: RAW + + port2: + type: OS::Neutron::Port + properties: + network: {get_param: port_name} + replacement_policy: AUTO diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securitygrouptonovaconnectionmulti/inputfiles/addOn3.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securitygrouptonovaconnectionmulti/inputfiles/addOn3.yml new file mode 100644 index 0000000000..95382efb69 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securitygrouptonovaconnectionmulti/inputfiles/addOn3.yml @@ -0,0 +1,67 @@ +heat_template_version: 2013-05-23 + +description: ASC Template + +parameters: + fe_smp_affinity_param: + type: string + description: be affinity param + multi_anti_affinity_param: + type: string + description: be affinity param + availability_zone_0: + type: string + vnf_id: + type: string + description: Unique ID for this VNF instance + default: This_is_ths_SCP_id + port_name: + type: string + description: port name + default: port_name + flavor_smp_name: + type: string + description: SCP SMP Flavor + default: a1.Small + image_smp_name: + type: string + description: SCP SMP image + default: asc_base_image_smp + smp_name_2: + type: string + default: vSMP2 + description: name of VM + lab_name: + type: string + description: Lab name + +resources: + server_smp3: + type: OS::Nova::Server + properties: + name: { get_param: smp_name_2 } + image: { get_param: image_smp_name } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: flavor_smp_name } + scheduler_hints: { group1: { get_param: fe_smp_affinity_param }, group2: { get_param: multi_anti_affinity_param } } + networks: + - port: { get_resource: port3 } + - port: { get_resource: port4 } + metadata: + vnf_id: { get_param: vnf_id } + jx_lab_name: {get_param: lab_name} + jx_vm_role: smp2 + user_data_format: RAW + + port3: + type: OS::Neutron::Port + properties: + network: {get_param: port_name} + replacement_policy: AUTO + + port4: + type: OS::Neutron::Port + properties: + network: {get_param: port_name} + replacement_policy: AUTO + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securitygrouptonovaconnectionmulti/inputfiles/main.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securitygrouptonovaconnectionmulti/inputfiles/main.yml new file mode 100644 index 0000000000..cc814efbd9 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securitygrouptonovaconnectionmulti/inputfiles/main.yml @@ -0,0 +1,311 @@ +heat_template_version: 2013-05-23 + +description: ASC Template + +parameters: + cluster_type: + type: string + constraints: + - allowed_values: [ Test, Prod ] + fe_connectivity: + type: string + constraints: + - allowed_values: [ NEE, STP ] + key_name: + type: string + description: keypair to enable SSH access to the instance. + default: vSCP-keypair + +# Availability Zone information may need to be updated and the specifications under Nova server capabilities uncommented + availability_zone_0: + type: string + + vnf_name: + type: string + description: Unique name for this VNF instance + default: This_is_the_SCP_name + vnf_id: + type: string + description: Unique ID for this VNF instance + default: This_is_ths_SCP_id + + port_name: + type: string + description: port name + default: port_name + + flavor_scp_be_name: + type: string + description: SCP BE Flavor + default: a1.Small + flavor_scp_fe_name: + type: string + description: SCP FE Flavor + default: a1.Small + flavor_smp_name: + type: string + description: SCP SMP Flavor + default: a1.Small + image_scp_be_name: + type: string + description: SCP BE image + default: asc_base_image_be + image_scp_fe_name: + type: string + description: SCP FE image + default: asc_base_image_fe + image_smp_name: + type: string + description: SCP SMP image + default: asc_base_image_smp + int_vscp_fe_cluster_net_id: + type: string + description: LAN2 FE Cluster/KA + int_vscp_fe_cluster_cidr: + type: string + description: Private Network2 Address (CIDR notation) + int_vscp_cluster_net_id: + type: string + description: LAN3 Cluster + int_vscp_cluster_cidr: + type: string + description: Private Network3 Address (CIDR notation) + int_vscp_ce_network_net_id: + type: string + description: Inter-CE Network + int_vscp_ce_network_cidr: + type: string + description: Private Network Address (CIDR notation) + SIGNET_vrf_A1_direct_net_id: + type: string + description: Network name for SIGTRAN_A + SIGNET_vrf_B1_direct_net_id: + type: string + description: Network name for SIGTRAN_B + Cricket_OCS_protected_net_id: + type: string + description: Network name for CRICKET_OCS + Mobility_OAM_protected_net_id: + type: string + description: Network name for OAM + be_Cricket_OCS_protected_ip_0: + type: string + label: be1 Cricket_OCS ip address + description: be1 Cricket_OCS ip address + be_Cricket_OCS_protected_ip_1: + type: string + label: be2 Cricket_OCS ip address + description: be2 Cricket_OCS ip address + be_Cricket_OCS_protected_ip_2: + type: string + label: be3 Cricket_OCS ip address + description: be3 Cricket_OCS ip address + be_Cricket_OCS_protected_ip_3: + type: string + label: be4 Cricket_OCS ip address + description: be4 Cricket_OCS ip address + be_Cricket_OCS_protected_ip_4: + type: string + label: be5 Cricket_OCS ip address + description: be5 Cricket_OCS ip address + fe_SIGNET_vrf_B1_direct_ip_0: + type: string + label: fe1 SIGTRAN ip address + description: fe1 SIGTRAN ip address + fe_SIGNET_vrf_A1_direct_ip_0: + type: string + label: fe2 SIGTRAN ip address + description: fe2 SIGTRAN ip address + be_Mobility_OAM_protected_ip_0: + type: string + label: be_0 OAM ip address + description: be_0 OAM ip address + be_Mobility_OAM_protected_ip_1: + type: string + label: be_1 OAM ip address + description: be_1 OAM ip address + be_Mobility_OAM_protected_ip_2: + type: string + label: be_2 OAM ip address + description: be_2 OAM ip address + be_Mobility_OAM_protected_ip_3: + type: string + label: be_3 OAM ip address + description: be_3 OAM ip address + be_Mobility_OAM_protected_ip_4: + type: string + label: be_4 OAM ip address + description: be_4 OAM ip address + fe_Mobility_OAM_protected_ip_0: + type: string + label: fe_0 OAM ip address + description: fe_0 OAM ip address + fe_Mobility_OAM_protected_ip_1: + type: string + label: fe_1 OAM ip address + description: fe_1 OAM ip address + smp_Mobility_OAM_protected_ip_0: + type: string + label: smp_0 OAM ip address + description: smp_0 OAM ip address + smp_Mobility_OAM_protected_ip_1: + type: string + label: smp_1 OAM ip address + description: smp_1 OAM ip address + be_name_0: + type: string + default: vSCP_BE1 + description: name of VM + be_name_1: + type: string + default: vSCP_BE2 + description: name of VM + be_name_2: + type: string + default: vSCP_BE3 + description: name of VM + be_name_3: + type: string + default: vSCP_BE4 + description: name of VM + be_name_4: + type: string + default: vSCP_BE5 + description: name of VM + fe_name_0: + type: string + default: vSCP_FE1 + description: name of VM + fe_name_1: + type: string + default: vSCP_FE2 + description: name of VM + smp_name_0: + type: string + default: vSMP1 + description: name of VM + smp_name_1: + type: string + default: vSMP2 + description: name of VM + smp_name_2: + type: string + default: vSMP2 + description: name of VM + ##smp_name_2: + ##type: string + ##default: vSMP2 + ##description: name of VM + nee_name_0: + type: string + default: vNEE + description: name of VM + + hostname_fe1: + type: string + description: FE1 Hostname (from Ulticom license) + hostid_fe1: + type: string + description: FE1 Hostid (from Ulticom license) + + hostname_fe2: + type: string + description: FE2 Hostname (from Ulticom license) + hostid_fe2: + type: string + description: FE2 Hostid (from Ulticom license) + + hostname_nee1: + type: string + description: NEE1 Hostname (from Ulticom license) + hostid_nee1: + type: string + description: NEE1 Hostid (from Ulticom license) + + point_code_scp: + type: string + description: vSCP point code (in "zone-cluster-member" format) + point_code_stp: + type: string + description: STP virtual point code (in "zone-cluster-member" format) + point_code_stp1: + type: string + description: STP1 point code (in "zone-cluster-member" format) + point_code_stp2: + type: string + description: STP2 point code (in "zone-cluster-member" format) + ip_address_stp1: + type: string + description: STP1 IP address + ip_port_stp1: + type: string + description: STP1 IP port + ip_address_stp2: + type: string + description: STP2 IP address + ip_port_stp2: + type: string + description: STP2 IP port + ip_port_fe1: + type: string + description: FE1 IP port in SIGTRAN network + ip_port_fe2: + type: string + description: FE2 IP port in SIGTRAN network + + global_title_scp: + type: string + description: vSCP Global Title address + global_title_stp: + type: string + description: STP Global Title address + + security_group_name: + type: string + label: vSCP security group name + description: vSCP security group name + + route_table_be: + type: string + description: Additional route table for BEs + + route_table_fe1: + type: string + description: Additional route table for FE1 + + route_table_fe2: + type: string + description: Additional route table for FE2 + + ip_address_dra: + type: string + description: DRA VIP address + + lab_name: + type: string + description: Lab name + +resources: + FE_SMP_Affinity: + type: OS::Nova::ServerGroup + properties: + policies: ["affinity"] + name: abc + BE_Affinity: + type: OS::Nova::ServerGroup + properties: + policies: ["affinity"] + name: def + Multi_Anti_Affinity: + type: OS::Nova::ServerGroup + properties: + policies: ["anti-affinity"] + name: def + +outputs: + fe_smp_affinity_param: + value: {get_resource: FE_SMP_Affinity} + be_affinity_param: + value: {get_resource: BE_Affinity} + multi_anti_affinity_param: + value: {get_resource: Multi_Anti_Affinity} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..eb63b32fdf --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,1077 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + vprobe_volume_type_0: + hidden: false + immutable: false + type: string + description: The type of the volume mapping to a backend + default: volumes_ceph + vprobe_volume_type_1: + hidden: false + immutable: false + type: string + description: The type of the volume mapping to a backend + default: volumes_ceph + vprobe_volume_type_2: + hidden: false + immutable: false + type: string + description: The type of the volume mapping to a backend + default: volumes_ceph + oam_private_net_name: + hidden: false + immutable: false + type: string + description: A string specifying a symbolic name for the network + vProbe_cluster_name: + hidden: false + immutable: false + type: string + description: The component cluster name + default: vProbe_cluster + qrouter_flavor_name: + hidden: false + immutable: false + type: string + description: The ID or name of the flavor to boot onto + default: m1.large + version_number: + hidden: false + immutable: false + type: string + description: The version number of the component + default: 11.1.5 + vLB_version_name: + hidden: false + immutable: false + type: string + description: The version name of the component. + default: vProbe.r.11.1.e._08_16-12_53 + vprobe_flavor_name: + hidden: false + immutable: false + type: string + description: The name of the flavor to boot onto + default: m1.large + domain_name: + hidden: false + immutable: false + type: string + description: The servers domain + ntp_timezone: + hidden: false + immutable: false + type: string + description: Name of NTP Time zone to be used + default: UTC + packet_mirror_network_subnet_cidr: + hidden: false + immutable: false + type: string + description: The Classless Inter-Domain Routing + default: 20.20.5.0/24 + vLBAgent_cluster_name: + hidden: false + immutable: false + type: string + description: The component cluster name + default: vLBAgent_cluster + vLB_type: + hidden: false + immutable: false + type: string + description: The type of VLB. MME or SGW. + default: mme + qrouter_names: + hidden: false + immutable: false + type: list + description: VM Names for QRouter VMs + entry_schema: + type: string + win_domain_name: + hidden: false + immutable: false + type: string + description: Windows servers' domain + tenant_name: + hidden: false + immutable: false + type: string + description: Name of tenant to be used + vLB_names: + hidden: false + immutable: false + type: list + description: VM Names for vLB VMs + entry_schema: + type: string + vprobe_volume_size_2: + hidden: false + immutable: false + type: float + description: The size of the volume in GB + default: 1 + vLBAgent_flavor_name: + hidden: false + immutable: false + type: string + description: The ID or name of the flavor to boot onto + default: m1.large + vprobe_volume_name_0: + hidden: false + immutable: false + type: string + description: The name of the volume + default: data + vprobe_volume_size_0: + hidden: false + immutable: false + type: float + description: The size of the volume in GB + default: 100 + vprobe_volume_name_1: + hidden: false + immutable: false + type: string + description: The name of the volume + default: log + vprobe_volume_size_1: + hidden: false + immutable: false + type: float + description: The size of the volume in GB + default: 5 + vprobe_volume_name_2: + hidden: false + immutable: false + type: string + description: The name of the volume + default: config + packet_mirror_network_subnet_alloc_start: + hidden: false + immutable: false + type: string + description: Start address for the allocation pool + default: 20.20.5.2 + vLBAgent_version_name: + hidden: false + immutable: false + type: string + description: The version name of the component + default: vProbe.r.11.1.e._08_16-12_53 + vLB_volume_name_2: + hidden: false + immutable: false + type: string + description: The name of the volume + default: config + cdr_network: + hidden: false + immutable: false + type: string + description: A string specifying a symbolic name for the network + vLBAgent_type: + hidden: false + immutable: false + type: string + description: vLBAgent Type. mme or sgw + default: mme + vProbe_node_count: + hidden: false + immutable: false + type: float + description: The number of nodes to create + default: 1 + packet_internal_network_subnet_alloc_end: + hidden: false + immutable: false + type: string + description: End address for the allocation pool + default: 192.0.6.250 + vLBAgent_volume_type_0: + hidden: false + immutable: false + type: string + description: The type of the volume mapping to a backend + default: volumes_ceph + vLBAgent_volume_type_1: + hidden: false + immutable: false + type: string + description: The type of the volume mapping to a backend + default: volumes_ceph + vLBAgent_volume_size_1: + hidden: false + immutable: false + type: float + description: The size of the volume in GB + default: 1 + vLBAgent_volume_type_2: + hidden: false + immutable: false + type: string + description: The Cinder volume type. Used to specify the backend. + default: volumes_ceph + vLB_volume_name_0: + hidden: false + immutable: false + type: string + description: The name of the volume + default: data + vLB_volume_type_1: + hidden: false + immutable: false + type: string + description: The type of the volume mapping to a backend + default: volumes_ceph + vLBAgent_volume_size_2: + hidden: false + immutable: false + type: float + description: The size of the volume in Gigabytes. + default: 1 + vLB_volume_name_1: + hidden: false + immutable: false + type: string + description: The name of the volume + default: log + vLB_volume_type_2: + hidden: false + immutable: false + type: string + description: The type of the volume mapping to a backend + default: volumes_ceph + vLBAgent_volume_size_0: + hidden: false + immutable: false + type: float + description: The size of the volume in GB + default: 15 + vLB_volume_type_0: + hidden: false + immutable: false + type: string + description: The type of the volume mapping to a backend + default: volumes_ceph + vLBAgent_volume_name_2: + hidden: false + immutable: false + type: string + description: The name of the volume + default: config + vLBAgent_volume_name_1: + hidden: false + immutable: false + type: string + description: The name of the volume + default: log + vLBAgent_volume_name_0: + hidden: false + immutable: false + type: string + description: The name of the volume + default: data + vLB_volume_size_1: + hidden: false + immutable: false + type: float + description: The size of the volume in GB. + default: 1 + vLB_volume_size_0: + hidden: false + immutable: false + type: float + description: The size of the volume in GB. + default: 10 + packet_mirror_network_subnet_name: + hidden: false + immutable: false + type: string + description: The name of the subnet + default: rprb_26071_mme_int_pktmirror_net_1_subnet + vLB_volume_size_2: + hidden: false + immutable: false + type: float + description: The size of the volume in GB. + default: 1 + vf_module_id: + hidden: false + immutable: false + type: string + description: The VF MODULE ID of the RADCOM System. + qrouter_cluster_name: + hidden: false + immutable: false + type: string + description: The component cluster name + default: qrouter_cluster + vprobe_type: + hidden: false + immutable: false + type: string + description: The type of vProbe. MME or SGW. + default: mme + base_image_name: + hidden: false + immutable: false + type: string + description: The base ID or name of the image to boot with + default: rprb_centos_6_7_05_24_2016 + vf_module_name: + hidden: false + immutable: false + type: string + description: The VNF module name for vProbe elements. + vLB_node_count: + hidden: false + immutable: false + type: float + description: The number of nodes to create. + default: 1 + packet_mirror_network_subnet_alloc_end: + hidden: false + immutable: false + type: string + description: End address for the allocation pool + default: 20.20.5.250 + packet_internal_network_subnet_name: + hidden: false + immutable: false + type: string + description: The name of the subnet + default: rprb_26071_mme_int_pktinternal_net_1_subnet + vProbe_version_name: + hidden: false + immutable: false + type: string + description: The version name of the component + default: vProbe.r.11.1.e._08_16-12_53 + vnf_id: + hidden: false + immutable: false + type: string + description: The VNF ID of the RADCOM System. + availability_zone_0: + hidden: false + immutable: false + type: string + description: Name of the availability zone for server placement + region_name: + hidden: false + immutable: false + type: string + description: Name of region to be used + availability_zone_1: + hidden: false + immutable: false + type: string + description: Name of the availability zone for server placement + qtrace_name_0: + hidden: false + immutable: false + type: string + description: VM Name for QRouter VMs + availability_zone_2: + hidden: false + immutable: false + type: string + description: Name of the availability zone for server placement. + vprobe_AppDependenciesMachineType: + hidden: false + immutable: false + type: string + description: The application dependencies + default: DatabaseUpgrade + manager_name_0: + hidden: false + immutable: false + type: string + description: VM Name for Manager VM 0 + availability_zone_3: + hidden: false + immutable: false + type: string + description: Name of the availability zone for server placement + vLB_cluster_name: + hidden: false + immutable: false + type: string + description: The component cluster name. + default: vLB_cluster + packet_internal_network_name: + hidden: false + immutable: false + type: string + description: A string specifying a symbolic name for the network + default: rprb_26071_mme_int_pktinternal_net_1 + packet_mirror_network_name: + hidden: false + immutable: false + type: string + description: A string specifying a symbolic name for the network + default: rprb_26071_mme_int_pktmirror_net_1 + packet_internal_network_subnet_alloc_start: + hidden: false + immutable: false + type: string + description: Start address for the allocation pool + default: 192.0.6.2 + qrouter_volume_type_1: + hidden: false + immutable: false + type: string + description: The type of the volume mapping to a backend + default: volumes_ceph + vLBAgent_node_count: + hidden: false + immutable: false + type: float + description: The number of nodes to create + default: 1 + qrouter_volume_type_2: + hidden: false + immutable: false + type: string + description: The type of the volume mapping to a backend + default: volumes_ceph + vprobe_names: + hidden: false + immutable: false + type: list + description: VM Names for vProbe VMs + entry_schema: + type: string + qrouter_node_count: + hidden: false + immutable: false + type: float + description: The number of nodes to create + default: 1 + qrouter_volume_name_2: + hidden: false + immutable: false + type: string + description: The name of the volume + default: config + vLBAgent_names: + hidden: false + immutable: false + type: list + description: VM Names for vLBAgent VMs + entry_schema: + type: string + vLB_flavor_name: + hidden: false + immutable: false + type: string + description: The name of the flavor to boot onto. + default: m1.large + qrouter_volume_name_1: + hidden: false + immutable: false + type: string + description: The name of the volume + default: log + qrouter_volume_name_0: + hidden: false + immutable: false + type: string + description: The name of the volume + default: data + qrouter_volume_type_0: + hidden: false + immutable: false + type: string + description: The type of the volume mapping to a backend + default: volumes_ceph + qrouter_volume_size_0: + hidden: false + immutable: false + type: float + description: The size of the volume in GB + default: 1 + qrouter_volume_size_1: + hidden: false + immutable: false + type: float + description: The size of the volume in GB + default: 1 + packet_internal_network_subnet_cidr: + hidden: false + immutable: false + type: string + description: The Classless Inter-Domain Routing + default: 192.0.6.0/24 + manager_oam_direct_ip_0: + hidden: false + immutable: false + type: string + description: The public ip address of the manager + qrouter_volume_size_2: + hidden: false + immutable: false + type: float + description: The size of the volume in GB + default: 1 + rpmrepository_ip_0: + hidden: false + immutable: false + type: string + description: The public ip address of the repository + node_templates: + vLBAgent: + type: org.openecomp.resource.abstract.nodes.heat.FEAdd_On_Module_vLBAgentTemplate + directives: + - substitutable + properties: + vf_module_id: + get_input: vf_module_id + packet_mirror_network: packet_mirror_network + oam_private_net_name: + get_input: oam_private_net_name + vProbe_cluster_name: + get_input: vProbe_cluster_name + vlb_agent_image_name: + get_input: base_image_name + vf_module_name: + get_input: vf_module_name + vLB_node_count: + get_input: vLB_node_count + service_template_filter: + substitute_service_template: FEAdd_On_Module_vLBAgentTemplateServiceTemplate.yaml + domain_name: + get_input: domain_name + ntp_timezone: + get_input: ntp_timezone + packet_internal_network: packet_internal_network + vnf_id: + get_input: vnf_id + vLBAgent_cluster_name: + get_input: vLBAgent_cluster_name + availability_zone_0: + get_input: availability_zone_2 + region_name: + get_input: region_name + manager_name_0: + get_input: manager_name_0 + vLB_cluster_name: + get_input: vLB_cluster_name + tenant_name: + get_input: tenant_name + vLBAgent_flavor_name: + get_input: vLBAgent_flavor_name + security_group: security_group + vLBAgent_version_name: + get_input: vLBAgent_version_name + vLBAgent_type: + get_input: vLBAgent_type + vLBAgent_node_count: + get_input: vLBAgent_node_count + vLBAgent_volume_type_0: + get_input: vLBAgent_volume_type_0 + vLBAgent_volume_type_1: + get_input: vLBAgent_volume_type_1 + vLBAgent_volume_size_1: + get_input: vLBAgent_volume_size_1 + vLBAgent_volume_type_2: + get_input: vLBAgent_volume_type_2 + vLBAgent_names: + get_input: vLBAgent_names + vLBAgent_volume_size_2: + get_input: vLBAgent_volume_size_2 + vLBAgent_volume_size_0: + get_input: vLBAgent_volume_size_0 + vLBAgent_volume_name_2: + get_input: vLBAgent_volume_name_2 + vLBAgent_volume_name_1: + get_input: vLBAgent_volume_name_1 + vLBAgent_volume_name_0: + get_input: vLBAgent_volume_name_0 + manager_oam_direct_ip_0: + get_input: manager_oam_direct_ip_0 + rpmrepository_ip_0: + get_input: rpmrepository_ip_0 + requirements: + - link_packet_mirror_network_port: + capability: tosca.capabilities.network.Linkable + node: packet_mirror_network + relationship: tosca.relationships.network.LinksTo + - link_packet_internal_network_port: + capability: tosca.capabilities.network.Linkable + node: packet_internal_network + relationship: tosca.relationships.network.LinksTo + - dependency: + capability: tosca.capabilities.Node + node: security_group + relationship: tosca.relationships.DependsOn + - dependency: + capability: tosca.capabilities.Node + node: packet_mirror_network + relationship: tosca.relationships.DependsOn + - dependency: + capability: tosca.capabilities.Node + node: packet_mirror_network + relationship: tosca.relationships.DependsOn + - dependency: + capability: tosca.capabilities.Node + node: packet_internal_network + relationship: tosca.relationships.DependsOn + - dependency: + capability: tosca.capabilities.Node + node: packet_internal_network + relationship: tosca.relationships.DependsOn + vProbe: + type: org.openecomp.resource.abstract.nodes.heat.FEAdd_On_Module_vProbeTemplate + directives: + - substitutable + properties: + vf_module_id: + get_input: vf_module_id + vprobe_volume_type_0: + get_input: vprobe_volume_type_0 + vprobe_volume_type_1: + get_input: vprobe_volume_type_1 + qrouter_cluster_name: + get_input: qrouter_cluster_name + vprobe_volume_type_2: + get_input: vprobe_volume_type_2 + oam_private_net_name: + get_input: oam_private_net_name + vProbe_cluster_name: + get_input: vProbe_cluster_name + vprobe_type: + get_input: vprobe_type + vprobe_image_name: + get_input: base_image_name + vprobe_flavor_name: + get_input: vprobe_flavor_name + vf_module_name: + get_input: vf_module_name + vLB_node_count: + get_input: vLB_node_count + service_template_filter: + substitute_service_template: FEAdd_On_Module_vProbeTemplateServiceTemplate.yaml + domain_name: + get_input: domain_name + ntp_timezone: + get_input: ntp_timezone + packet_internal_network: packet_internal_network + vProbe_version_name: + get_input: vProbe_version_name + vnf_id: + get_input: vnf_id + availability_zone_0: + get_input: availability_zone_3 + region_name: + get_input: region_name + qtrace_name_0: + get_input: qtrace_name_0 + vprobe_AppDependenciesMachineType: + get_input: vprobe_AppDependenciesMachineType + manager_name_0: + get_input: manager_name_0 + win_domain_name: + get_input: win_domain_name + tenant_name: + get_input: tenant_name + vprobe_volume_size_2: + get_input: vprobe_volume_size_2 + vprobe_volume_name_0: + get_input: vprobe_volume_name_0 + vprobe_volume_size_0: + get_input: vprobe_volume_size_0 + vprobe_volume_name_1: + get_input: vprobe_volume_name_1 + vprobe_volume_size_1: + get_input: vprobe_volume_size_1 + vprobe_volume_name_2: + get_input: vprobe_volume_name_2 + security_group: security_group + cdr_network: + get_input: cdr_network + vProbe_node_count: + get_input: vProbe_node_count + vprobe_names: + get_input: vprobe_names + manager_oam_direct_ip_0: + get_input: manager_oam_direct_ip_0 + rpmrepository_ip_0: + get_input: rpmrepository_ip_0 + requirements: + - link_packet_internal_network_port: + capability: tosca.capabilities.network.Linkable + node: packet_internal_network + relationship: tosca.relationships.network.LinksTo + - dependency: + capability: tosca.capabilities.Node + node: security_group + relationship: tosca.relationships.DependsOn + - dependency: + capability: tosca.capabilities.Node + node: packet_mirror_network + relationship: tosca.relationships.DependsOn + - dependency: + capability: tosca.capabilities.Node + node: packet_mirror_network + relationship: tosca.relationships.DependsOn + - dependency: + capability: tosca.capabilities.Node + node: packet_internal_network + relationship: tosca.relationships.DependsOn + - dependency: + capability: tosca.capabilities.Node + node: packet_internal_network + relationship: tosca.relationships.DependsOn + QRouter: + type: org.openecomp.resource.abstract.nodes.heat.FEAdd_On_Module_QRouterTemplate + directives: + - substitutable + properties: + vf_module_id: + get_input: vf_module_id + qrouter_cluster_name: + get_input: qrouter_cluster_name + oam_private_net_name: + get_input: oam_private_net_name + qrouter_flavor_name: + get_input: qrouter_flavor_name + version_number: + get_input: version_number + vf_module_name: + get_input: vf_module_name + service_template_filter: + substitute_service_template: FEAdd_On_Module_QRouterTemplateServiceTemplate.yaml + domain_name: + get_input: domain_name + ntp_timezone: + get_input: ntp_timezone + vnf_id: + get_input: vnf_id + availability_zone_0: + get_input: availability_zone_0 + region_name: + get_input: region_name + manager_name_0: + get_input: manager_name_0 + qrouter_names: + get_input: qrouter_names + tenant_name: + get_input: tenant_name + security_group: security_group + cdr_network: + get_input: cdr_network + qrouter_image_name: + get_input: base_image_name + qrouter_volume_type_1: + get_input: qrouter_volume_type_1 + qrouter_volume_type_2: + get_input: qrouter_volume_type_2 + qrouter_node_count: + get_input: qrouter_node_count + qrouter_volume_name_2: + get_input: qrouter_volume_name_2 + qrouter_volume_name_1: + get_input: qrouter_volume_name_1 + qrouter_volume_name_0: + get_input: qrouter_volume_name_0 + qrouter_volume_type_0: + get_input: qrouter_volume_type_0 + qrouter_volume_size_0: + get_input: qrouter_volume_size_0 + qrouter_volume_size_1: + get_input: qrouter_volume_size_1 + manager_oam_direct_ip_0: + get_input: manager_oam_direct_ip_0 + qrouter_volume_size_2: + get_input: qrouter_volume_size_2 + rpmrepository_ip_0: + get_input: rpmrepository_ip_0 + requirements: + - dependency: + capability: tosca.capabilities.Node + node: security_group + relationship: tosca.relationships.DependsOn + packet_mirror_network: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + dhcp_enabled: true + network_name: + get_input: packet_mirror_network_name + subnets: + packet_mirror_network_subnet: + enable_dhcp: true + name: + get_input: packet_mirror_network_subnet_name + cidr: + get_input: packet_mirror_network_subnet_cidr + allocation_pools: + - start: + get_input: packet_mirror_network_subnet_alloc_start + end: + get_input: packet_mirror_network_subnet_alloc_end + packet_internal_network: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + dhcp_enabled: true + network_name: + get_input: packet_internal_network_name + subnets: + packet_internal_network_subnet: + enable_dhcp: true + name: + get_input: packet_internal_network_subnet_name + cidr: + get_input: packet_internal_network_subnet_cidr + allocation_pools: + - start: + get_input: packet_internal_network_subnet_alloc_start + end: + get_input: packet_internal_network_subnet_alloc_end + security_group: + type: org.openecomp.resource.vfc.rules.nodes.heat.network.neutron.SecurityRules + properties: + name: FE_radcom_security_group + rules: + - protocol: tcp + port_range_max: 23 + port_range_min: 23 + - protocol: tcp + port_range_max: 123 + port_range_min: 123 + - protocol: tcp + port_range_max: 3389 + port_range_min: 3389 + - protocol: udp + port_range_max: 5434 + port_range_min: 5434 + - protocol: tcp + port_range_max: 5443 + port_range_min: 5435 + - protocol: tcp + port_range_max: 8000 + port_range_min: 8000 + - protocol: tcp + port_range_max: 9900 + port_range_min: 9900 + - protocol: tcp + port_range_max: 12050 + port_range_min: 12000 + - protocol: tcp + port_range_max: 161 + port_range_min: 161 + - protocol: udp + port_range_max: 8000 + port_range_min: 8000 + - protocol: icmp + - protocol: 47 + - protocol: tcp + port_range_max: 22 + port_range_min: 22 + - protocol: tcp + port_range_max: 3050 + port_range_min: 3000 + - protocol: tcp + port_range_max: 8081 + port_range_min: 8080 + - protocol: tcp + port_range_max: 8084 + port_range_min: 8084 + - protocol: tcp + port_range_max: 4000 + port_range_min: 4000 + - protocol: tcp + port_range_max: 33000 + port_range_min: 33000 + - protocol: tcp + port_range_max: 8082 + port_range_min: 8082 + requirements: + - port: + capability: attachment_oam_private_net_network_port + node: QRouter + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: attachment_cdr_network_port + node: QRouter + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: attachment_oam_private_net_network_port + node: vLB + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: attachment_packet_mirror_network_port + node: vLB + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: attachment_packet_internal_network_port + node: vLB + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: attachment_oam_private_net_network_port + node: vLBAgent + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: attachment_packet_mirror_network_port + node: vLBAgent + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: attachment_packet_internal_network_port + node: vLBAgent + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: attachment_oam_private_net_network_port + node: vProbe + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: attachment_cdr_network_port + node: vProbe + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: attachment_packet_internal_network_port + node: vProbe + relationship: org.openecomp.relationships.AttachesTo + vLB: + type: org.openecomp.resource.abstract.nodes.heat.FEAdd_On_Module_vLBTemplate + directives: + - substitutable + properties: + vf_module_id: + get_input: vf_module_id + packet_mirror_network: packet_mirror_network + oam_private_net_name: + get_input: oam_private_net_name + vProbe_cluster_name: + get_input: vProbe_cluster_name + vLB_version_name: + get_input: vLB_version_name + vf_module_name: + get_input: vf_module_name + vLB_node_count: + get_input: vLB_node_count + service_template_filter: + substitute_service_template: FEAdd_On_Module_vLBTemplateServiceTemplate.yaml + domain_name: + get_input: domain_name + ntp_timezone: + get_input: ntp_timezone + packet_internal_network: packet_internal_network + vnf_id: + get_input: vnf_id + vLB_type: + get_input: vLB_type + availability_zone_0: + get_input: availability_zone_1 + region_name: + get_input: region_name + manager_name_0: + get_input: manager_name_0 + vLB_cluster_name: + get_input: vLB_cluster_name + tenant_name: + get_input: tenant_name + vLB_names: + get_input: vLB_names + security_group: security_group + vLB_volume_name_2: + get_input: vLB_volume_name_2 + vLB_volume_name_0: + get_input: vLB_volume_name_0 + vLB_volume_type_1: + get_input: vLB_volume_type_1 + vLB_flavor_name: + get_input: vLB_flavor_name + vLB_volume_name_1: + get_input: vLB_volume_name_1 + vLB_volume_type_2: + get_input: vLB_volume_type_2 + vLB_volume_type_0: + get_input: vLB_volume_type_0 + vLB_volume_size_1: + get_input: vLB_volume_size_1 + vlb_image_name: + get_input: base_image_name + vLB_volume_size_0: + get_input: vLB_volume_size_0 + manager_oam_direct_ip_0: + get_input: manager_oam_direct_ip_0 + rpmrepository_ip_0: + get_input: rpmrepository_ip_0 + vLB_volume_size_2: + get_input: vLB_volume_size_2 + requirements: + - link_packet_mirror_network_port: + capability: tosca.capabilities.network.Linkable + node: packet_mirror_network + relationship: tosca.relationships.network.LinksTo + - link_packet_internal_network_port: + capability: tosca.capabilities.network.Linkable + node: packet_internal_network + relationship: tosca.relationships.network.LinksTo + - dependency: + capability: tosca.capabilities.Node + node: security_group + relationship: tosca.relationships.DependsOn + - dependency: + capability: tosca.capabilities.Node + node: packet_mirror_network + relationship: tosca.relationships.DependsOn + - dependency: + capability: tosca.capabilities.Node + node: packet_mirror_network + relationship: tosca.relationships.DependsOn + - dependency: + capability: tosca.capabilities.Node + node: packet_internal_network + relationship: tosca.relationships.DependsOn + - dependency: + capability: tosca.capabilities.Node + node: packet_internal_network + relationship: tosca.relationships.DependsOn + groups: + FEBase_Module: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/FEBase_Module.yaml + members: + - vLBAgent + - vProbe + - QRouter + - packet_mirror_network + - packet_internal_network + - security_group + - vLB \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEAdd_On_Module_QRouterCloudConfig b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEAdd_On_Module_QRouterCloudConfig new file mode 100644 index 0000000000..51c7176ee6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEAdd_On_Module_QRouterCloudConfig @@ -0,0 +1,39 @@ +#cloud-config + manage_etc_hosts: true + yum_repos: + Base_Repo: + baseurl: "https://%rpm_repo_ip_0%/repo/base" + enabled: true + gpgcheck: false + name: "Base Repo" + sslverify: 0 + sslclientcert: /var/lib/yum/yum.cert + sslclientkey: /var/lib/yum/yum.key + Radcom: + baseurl: "https://%rpm_repo_ip_0%/repo/radcom" + enabled: true + gpgcheck: false + name: "Radcom Repo" + sslverify: 0 + sslclientcert: /var/lib/yum/yum.cert + sslclientkey: /var/lib/yum/yum.key + package_upgrade: false + ssh_authorized_keys: + - "ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAQEAnuJOkl2iGaFB+BCeRak67Chy+cATmvsqLPDYQ6GMRrGg0kBMcIRExshmTJQFGC+m2xiXeo41pSLaR1vt5fDB+3ewUSBcNtZrr5VxzBWzOab1VO+sCx4f8gOkSJ7plRJ/8xZqyhV+jTkb02peWbqtW+WqERTIyGul/eMNCDnwDNxznb8jMI3KWUd3ujWgFnk8EJ9c41y2unvk42XDOUlnuvR1/FW/qPRSNwPQGLEDlDje29xB3yaMQuJRL4Z86GWb1ZVeVh/+mIO1R4Ayj0HYspDruvFa9mECR4K1QhCN9mRE5sGBMiEOK0O/pf8Y3K2J9LQ6UYAt2yHzL7fAMAKOOw==" + runcmd: + - "sed -i \"s/GSSAPIAuthentication yes/GSSAPIAuthentication no/g\" /etc/ssh/sshd_config" + - "sed -i \"s/#UseDNS yes/UseDNS no/g\" /etc/ssh/sshd_config" + - "passwd -d deployment" + - "mkdir -pv /mnt/config" + - "mount /dev/disk/by-label/config-2 /mnt/config" + - "a=($(cat /mnt/config/openstack/latest/meta_data.json | /usr/local/bin/python2.7 -c 'import json,sys;obj=json.load(sys.stdin); print json.dumps(obj[\"files\"]);'));paths=0; values=0;counter=0;function remove_json_chars() { input=$1; echo $1 | sed 's/\\}//g' | sed 's/,//g' | sed 's/]//g' | sed 's/\"//g'; };for data in ${a[@]} ; do index=$(( $counter % 4 )); if [[ \"$index\" == 1 ]];then b[$paths]=$(remove_json_chars $data); paths=$(( $paths + 1 )) ; fi; if [[ \"$index\" == 3 ]];then c[$values]=$(remove_json_chars $data); values=$(( $values + 1 )) ; fi; counter=$(( $counter + 1 )) ; done; path_counter=0; for file in ${c[@]} ; do cp /mnt/config/openstack${file} ${b[$path_counter]}; path_counter=$(( ${path_counter} + 1 )) ; done" + - "cat /mnt/config/openstack/latest/meta_data.json | /usr/local/bin/python2.7 -c 'import json,sys;obj=json.load(sys.stdin); print json.dumps(obj[\"meta\"]);' > /meta.js" + - "sed -i 's|_colon_|:|g' /meta.js" + - "sed -i 's|_slash_|/|g' /meta.js" + - "/usr/local/bin/python2.7 /tmp/wait_for_resources.py -m %manager_oam_direct_ip_0%" + - "chmod 0754 /root/call_home.py /root/RegisterStatus/register_status.py /root/CheckAvailability/check_availability.py" + - "sed -i 's/QROUTER_CLUSTER_NAME/%qrouter_cluster_name%/g' /root/dependencies.json" + - "sed -i 's/QROUTER_NODE_COUNT/%qrouter_node_count%/g' /root/dependencies.json" + - "sed -i 's/MANAGER_INSTANCE_NAME/%manager_hostname%.%domain_name%/g' /root/dependencies.json" + - "/usr/local/bin/python2.7 /root/CheckAvailability/check_availability.py %manager_oam_direct_ip_0%" + - "/usr/local/bin/python2.7 /root/call_home.py %manager_oam_direct_ip_0%" diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEAdd_On_Module_QRouterTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEAdd_On_Module_QRouterTemplate.yaml new file mode 100644 index 0000000000..aae1455919 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEAdd_On_Module_QRouterTemplate.yaml @@ -0,0 +1,216 @@ +heat_template_version: 2014-10-16 + +parameters: + cdr_network: + type: string + domain_name: + type: string + qrouter_image_name: + type: string + manager_name_0: + type: string + manager_oam_direct_ip_0: + type: string + ntp_timezone: + type: string + oam_private_net_name: + type: string + availability_zone_0: + type: string + qrouter_cluster_name: + type: string + qrouter_flavor_name: + type: string + qrouter_index: + type: number + qrouter_names: + type: comma_delimited_list + qrouter_node_count: + type: number + qrouter_volume_name_0: + type: string + qrouter_volume_name_1: + type: string + qrouter_volume_name_2: + type: string + qrouter_volume_size_0: + type: number + qrouter_volume_size_1: + type: number + qrouter_volume_size_2: + type: number + qrouter_volume_type_0: + type: string + qrouter_volume_type_1: + type: string + qrouter_volume_type_2: + type: string + region_name: + type: string + rpmrepository_ip_0: + type: string + security_group: + type: string + tenant_name: + type: string + version_number: + type: string + vf_module_id: + type: string + vf_module_name: + type: string + vnf_id: + type: string +resources: + QRouter: + properties: + availability_zone: + get_param: availability_zone_0 + config_drive: true + flavor: + get_param: qrouter_flavor_name + image: + get_param: qrouter_image_name + metadata: + cdr_network_ip_0: + get_attr: + - cdr_network_port + - fixed_ip_0s + - 0 + - ip_address + cluster_name: + get_param: qrouter_cluster_name + machine_name: + get_param: + - qrouter_names + - get_param: qrouter_index + machine_type: qrouter + mount_colon__slash_config: + get_resource: qrouter_volume_2 + mount_colon__slash_data: + get_resource: qrouter_volume_0 + mount_colon__slash_log: + get_resource: qrouter_volume_1 + ntp_timezone: + get_param: ntp_timezone + oam_private_network_ip_0: + get_attr: + - oam_private_net_network_port + - fixed_ip_0s + - 0 + - ip_address + region: + get_param: region_name + repo_ip_0: + get_param: rpmrepository_ip_0 + tenant: + get_param: tenant_name + version_number: + get_param: version_number + vf_module_id: + get_param: vf_module_id + vf_module_name: + get_param: vf_module_name + vnf_id: + get_param: vnf_id + name: + get_param: + - qrouter_names + - get_param: qrouter_index + networks: + - port: + get_resource: oam_private_net_network_port + - port: + get_resource: cdr_network_port + personality: + /root/CheckAvailability/check_availability.py: + get_file: check_availability.py + /root/RegisterStatus/register_status.py: + get_file: register_status.py + /root/call_home.py: + get_file: call_home.py + /root/dependencies.json: + get_file: qrouterdependencies.json + /tmp/wait_for_resources.py: + get_file: wait_for_resources.py + user_data: + str_replace: + params: + '%domain_name%': + get_param: domain_name + '%manager_hostname%': + get_param: manager_name_0 + '%manager_oam_direct_ip_0%': + get_param: manager_oam_direct_ip_0 + '%qrouter_cluster_name%': + get_param: qrouter_cluster_name + '%qrouter_node_count%': + get_param: qrouter_node_count + '%rpm_repo_ip_0%': + get_param: rpmrepository_ip_0 + template: + get_file: FEAdd_On_Module_QRouterCloudConfig + user_data_format: RAW + type: OS::Nova::Server + cdr_network_port: + properties: + network: + get_param: cdr_network + security_groups: + - get_param: security_group + type: OS::Neutron::Port + oam_private_net_network_port: + properties: + network: + get_param: oam_private_net_name + security_groups: + - get_param: security_group + type: OS::Neutron::Port + qrouter_volume_0: + properties: + description: + get_param: qrouter_volume_name_0 + size: + get_param: qrouter_volume_size_0 + volume_type: + get_param: qrouter_volume_type_0 + type: OS::Cinder::Volume + qrouter_volume_0_att: + properties: + instance_uuid: + get_resource: QRouter + volume_id: + get_resource: qrouter_volume_0 + type: OS::Cinder::VolumeAttachment + qrouter_volume_1: + properties: + description: + get_param: qrouter_volume_name_1 + size: + get_param: qrouter_volume_size_1 + volume_type: + get_param: qrouter_volume_type_1 + type: OS::Cinder::Volume + qrouter_volume_1_att: + properties: + instance_uuid: + get_resource: QRouter + volume_id: + get_resource: qrouter_volume_1 + type: OS::Cinder::VolumeAttachment + qrouter_volume_2: + properties: + description: + get_param: qrouter_volume_name_2 + size: + get_param: qrouter_volume_size_2 + volume_type: + get_param: qrouter_volume_type_2 + type: OS::Cinder::Volume + qrouter_volume_2_att: + properties: + instance_uuid: + get_resource: QRouter + volume_id: + get_resource: qrouter_volume_2 + type: OS::Cinder::VolumeAttachment \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEAdd_On_Module_vLBAgentCloudConfig b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEAdd_On_Module_vLBAgentCloudConfig new file mode 100644 index 0000000000..83f57aceb8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEAdd_On_Module_vLBAgentCloudConfig @@ -0,0 +1,53 @@ +#cloud-config + manage_etc_hosts: false + yum_repos: + Base_Repo: + baseurl: "https://%rpm_repo_ip_0%/repo/base" + enabled: true + gpgcheck: false + name: "Base Repo" + sslverify: 0 + sslclientcert: /var/lib/yum/yum.cert + sslclientkey: /var/lib/yum/yum.key + Radcom: + baseurl: "https://%rpm_repo_ip_0%/repo/radcom" + enabled: true + gpgcheck: false + name: "Radcom Repo" + sslverify: 0 + sslclientcert: /var/lib/yum/yum.cert + sslclientkey: /var/lib/yum/yum.key + package_upgrade: false + ssh_authorized_keys: + - "ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAQEAnuJOkl2iGaFB+BCeRak67Chy+cATmvsqLPDYQ6GMRrGg0kBMcIRExshmTJQFGC+m2xiXeo41pSLaR1vt5fDB+3ewUSBcNtZrr5VxzBWzOab1VO+sCx4f8gOkSJ7plRJ/8xZqyhV+jTkb02peWbqtW+WqERTIyGul/eMNCDnwDNxznb8jMI3KWUd3ujWgFnk8EJ9c41y2unvk42XDOUlnuvR1/FW/qPRSNwPQGLEDlDje29xB3yaMQuJRL4Z86GWb1ZVeVh/+mIO1R4Ayj0HYspDruvFa9mECR4K1QhCN9mRE5sGBMiEOK0O/pf8Y3K2J9LQ6UYAt2yHzL7fAMAKOOw==" + runcmd: + - "sed -i \"s/GSSAPIAuthentication yes/GSSAPIAuthentication no/g\" /etc/ssh/sshd_config" + - "sed -i \"s/#UseDNS yes/UseDNS no/g\" /etc/ssh/sshd_config" + - "passwd -d deployment" + - "mkdir -pv /mnt/config" + - "mount /dev/disk/by-label/config-2 /mnt/config" + - "a=($(cat /mnt/config/openstack/latest/meta_data.json | /usr/local/bin/python2.7 -c 'import json,sys;obj=json.load(sys.stdin); print json.dumps(obj[\"files\"]);'));paths=0; values=0;counter=0;function remove_json_chars() { input=$1; echo $1 | sed 's/\\}//g' | sed 's/,//g' | sed 's/]//g' | sed 's/\"//g'; };for data in ${a[@]} ; do index=$(( $counter % 4 )); if [[ \"$index\" == 1 ]];then b[$paths]=$(remove_json_chars $data); paths=$(( $paths + 1 )) ; fi; if [[ \"$index\" == 3 ]];then c[$values]=$(remove_json_chars $data); values=$(( $values + 1 )) ; fi; counter=$(( $counter + 1 )) ; done; path_counter=0; for file in ${c[@]} ; do cp /mnt/config/openstack${file} ${b[$path_counter]}; path_counter=$(( ${path_counter} + 1 )) ; done" + - "cat /mnt/config/openstack/latest/meta_data.json | /usr/local/bin/python2.7 -c 'import json,sys;obj=json.load(sys.stdin); print json.dumps(obj[\"meta\"]);' > /meta.js" + - "sed -i 's|_colon_|:|g' /meta.js" + - "sed -i 's|_slash_|/|g' /meta.js" + - "/usr/local/bin/python2.7 /tmp/wait_for_resources.py -m %manager_oam_direct_ip_0%" + - "chmod 0754 /root/call_home.py /root/RegisterStatus/register_status.py /root/CheckAvailability/check_availability.py" + - "/usr/local/bin/python2.7 /root/CheckAvailability/check_availability.py %manager_oam_direct_ip_0%" + - "echo MH vLBAgent_id_number %vLBAgent_id_number%" + - "echo MH probe_data %probe_data%" + - "echo MH probe_log %probe_log%" + - "echo MH probe_config %probe_config%" + - "echo MH vLBAgent_id_number %vLBAgent_id_number%" + - "probe_id=`echo %vLBAgent_id_number%`" + - "vLB_n_count=`echo %vLB_node_count%`" + - "echo vLB_n_count=$vLB_n_count" + - "if [[ \"$vLB_n_count\" == 0 ]];then cp -p /root/dependencies_without_vLB.json /root/dependencies.json; fi;" + - "if [[ \"$vLB_n_count\" > 0 ]];then cp -p /root/dependencies_with_vLB.json /root/dependencies.json; fi;" + - "sed -i 's/VLBAGENT_CLUSTER_NAME/%vLBAgent_cluster_name%/g' /root/dependencies.json" + - "sed -i 's/VPROBE_CLUSTER_NAME/%vProbe_cluster_name%/g' /root/dependencies.json" + - "sed -i 's/VLB_CLUSTER_NAME/%vLB_cluster_name%/g' /root/dependencies.json" + - "sed -i 's/VLBAGENT_NODE_COUNT/%vLBAgent_node_count%/g' /root/dependencies.json" + - "sed -i 's/MANAGER_INSTANCE_NAME/%manager_hostname%.%domain_name%/g' /root/dependencies.json" + - "echo \"${probe_id}\" > /etc/hostname" + - "mkdir -pv /radcom/software" + - "/usr/local/bin/python2.7 /root/call_home.py %manager_oam_direct_ip_0%" diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEAdd_On_Module_vLBAgentTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEAdd_On_Module_vLBAgentTemplate.yaml new file mode 100644 index 0000000000..80a65d17fc --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEAdd_On_Module_vLBAgentTemplate.yaml @@ -0,0 +1,303 @@ +heat_template_version: 2014-10-16 + +parameters: + domain_name: + type: string + vlb_agent_image_name: + type: string + manager_name_0: + type: string + manager_oam_direct_ip_0: + type: string + ntp_timezone: + type: string + oam_private_net_name: + type: string + packet_internal_network: + type: string + packet_mirror_network: + type: string + region_name: + type: string + rpmrepository_ip_0: + type: string + security_group: + type: string + tenant_name: + type: string + availability_zone_0: + type: string + vLBAgent_cluster_name: + type: string + vLBAgent_flavor_name: + type: string + vLBAgent_index: + type: number + vLBAgent_names: + type: comma_delimited_list + vLBAgent_node_count: + type: number + vLBAgent_type: + type: string + vLBAgent_version_name: + type: string + vLBAgent_volume_name_0: + type: string + vLBAgent_volume_name_1: + type: string + vLBAgent_volume_name_2: + type: string + vLBAgent_volume_size_0: + type: number + vLBAgent_volume_size_1: + type: number + vLBAgent_volume_size_2: + type: number + vLBAgent_volume_type_0: + type: string + vLBAgent_volume_type_1: + type: string + vLBAgent_volume_type_2: + type: string + vLB_cluster_name: + type: string + vLB_node_count: + type: number + vProbe_cluster_name: + type: string + vf_module_id: + type: string + vf_module_name: + type: string + vnf_id: + type: string +resources: + oam_private_net_network_port: + properties: + network: + get_param: oam_private_net_name + security_groups: + - get_param: security_group + type: OS::Neutron::Port + packet_internal_network_port: + properties: + network: + get_param: packet_internal_network + security_groups: + - get_param: security_group + type: OS::Neutron::Port + packet_mirror_network_port: + properties: + network: + get_param: packet_mirror_network + security_groups: + - get_param: security_group + type: OS::Neutron::Port + vLBAgentInstance: + properties: + availability_zone: + get_param: availability_zone_0 + config_drive: true + flavor: + get_param: vLBAgent_flavor_name + image: + get_param: vlb_agent_image_name + metadata: + DPDK: DPDK_IP + cluster_name: + get_param: vLBAgent_cluster_name + machine_name: + get_param: + - vLBAgent_names + - get_param: vLBAgent_index + machine_type: vLBAgent + manager_oam_direct_ip_0: + get_param: manager_oam_direct_ip_0 + mount_colon__slash_config: + get_resource: vLBAgent_volume_2 + mount_colon__slash_data: + get_resource: vLBAgent_volume_0 + mount_colon__slash_log: + get_resource: vLBAgent_volume_1 + ntp_timezone: + get_param: ntp_timezone + oam_private_network_cidr: + get_attr: + - oam_private_net_network_port + - subnets + - 0 + - cidr + oam_private_network_ip_0: + get_attr: + - oam_private_net_network_port + - fixed_ip_0s + - 0 + - ip_address + packet_internal_network_cidr: + get_attr: + - packet_internal_network_port + - subnets + - 0 + - cidr + packet_internal_network_ip_0: + get_attr: + - packet_internal_network_port + - fixed_ip_0s + - 0 + - ip_address + packet_mirror_network_cidr: + get_attr: + - packet_mirror_network_port + - subnets + - 0 + - cidr + packet_mirror_network_ip_0: + get_attr: + - packet_mirror_network_port + - fixed_ip_0s + - 0 + - ip_address + region: + get_param: region_name + repo_ip_0: + get_param: rpmrepository_ip_0 + tenant: + get_param: tenant_name + vLBAgentInstance: + get_param: vLBAgent_index + vLBAgent_id: + get_attr: + - vLBAgent_id + - value + vLBAgent_name: + get_param: + - vLBAgent_names + - get_param: vLBAgent_index + vLBAgent_type: + get_param: vLBAgent_type + vLBAgent_version_name: + get_param: vLBAgent_version_name + vLB_node_count: + get_param: vLB_node_count + version_number: + get_param: vLBAgent_version_name + vf_module_id: + get_param: vf_module_id + vf_module_name: + get_param: vf_module_name + vnf_id: + get_param: vnf_id + name: + get_param: + - vLBAgent_names + - get_param: vLBAgent_index + networks: + - port: + get_resource: oam_private_net_network_port + - port: + get_resource: packet_mirror_network_port + - port: + get_resource: packet_internal_network_port + personality: + /root/CheckAvailability/check_availability.py: + get_file: check_availability.py + /root/RegisterStatus/register_status.py: + get_file: register_status.py + /root/call_home.py: + get_file: call_home.py + /root/dependencies_with_vLB.json: + get_file: vlbagentdependencies_with_vLB.json + /root/dependencies_without_vLB.json: + get_file: vlbagentdependencies_without_vLB.json + /tmp/wait_for_resources.py: + get_file: wait_for_resources.py + user_data: + str_replace: + params: + '%domain_name%': + get_param: domain_name + '%manager_hostname%': + get_param: manager_name_0 + '%manager_oam_direct_ip_0%': + get_param: manager_oam_direct_ip_0 + '%rpm_repo_ip_0%': + get_param: rpmrepository_ip_0 + '%vLBAgent_cluster_name%': + get_param: vLBAgent_cluster_name + '%vLBAgent_config%': + get_resource: vLBAgent_volume_2 + '%vLBAgent_data%': + get_resource: vLBAgent_volume_0 + '%vLBAgent_id_number%': + get_attr: + - vLBAgent_id + - value + '%vLBAgent_log%': + get_resource: vLBAgent_volume_1 + '%vLBAgent_node_count%': + get_param: vLBAgent_node_count + '%vLBAgent_version_name%': + get_param: vLBAgent_version_name + '%vLB_cluster_name%': + get_param: vLB_cluster_name + '%vLB_node_count%': + get_param: vLB_node_count + '%vProbe_cluster_name%': + get_param: vProbe_cluster_name + template: + get_file: FEAdd_On_Module_vLBAgentCloudConfig + user_data_format: RAW + type: OS::Nova::Server + vLBAgent_id: + properties: + length: 4 + sequence: digits + type: OS::Heat::RandomString + vLBAgent_volume_0: + properties: + description: + get_param: vLBAgent_volume_name_0 + size: + get_param: vLBAgent_volume_size_0 + volume_type: + get_param: vLBAgent_volume_type_0 + type: OS::Cinder::Volume + vLBAgent_volume_0_att: + properties: + instance_uuid: + get_resource: vLBAgentInstance + volume_id: + get_resource: vLBAgent_volume_0 + type: OS::Cinder::VolumeAttachment + vLBAgent_volume_1: + properties: + description: + get_param: vLBAgent_volume_name_1 + size: + get_param: vLBAgent_volume_size_1 + volume_type: + get_param: vLBAgent_volume_type_1 + type: OS::Cinder::Volume + vLBAgent_volume_1_att: + properties: + instance_uuid: + get_resource: vLBAgentInstance + volume_id: + get_resource: vLBAgent_volume_1 + type: OS::Cinder::VolumeAttachment + vLBAgent_volume_2: + properties: + description: + get_param: vLBAgent_volume_name_2 + size: + get_param: vLBAgent_volume_size_2 + volume_type: + get_param: vLBAgent_volume_type_2 + type: OS::Cinder::Volume + vLBAgent_volume_2_att: + properties: + instance_uuid: + get_resource: vLBAgentInstance + volume_id: + get_resource: vLBAgent_volume_2 + type: OS::Cinder::VolumeAttachment diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEAdd_On_Module_vLBCloudConfig b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEAdd_On_Module_vLBCloudConfig new file mode 100644 index 0000000000..78b6c652ce --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEAdd_On_Module_vLBCloudConfig @@ -0,0 +1,41 @@ +#cloud-config + manage_etc_hosts: false + yum_repos: + Base_Repo: + baseurl: "https://%rpm_repo_ip_0%/repo/base" + enabled: true + gpgcheck: false + name: "Base Repo" + sslverify: 0 + sslclientcert: /var/lib/yum/yum.cert + sslclientkey: /var/lib/yum/yum.key + ssh_authorized_keys: + - "ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAQEAnuJOkl2iGaFB+BCeRak67Chy+cATmvsqLPDYQ6GMRrGg0kBMcIRExshmTJQFGC+m2xiXeo41pSLaR1vt5fDB+3ewUSBcNtZrr5VxzBWzOab1VO+sCx4f8gOkSJ7plRJ/8xZqyhV+jTkb02peWbqtW+WqERTIyGul/eMNCDnwDNxznb8jMI3KWUd3ujWgFnk8EJ9c41y2unvk42XDOUlnuvR1/FW/qPRSNwPQGLEDlDje29xB3yaMQuJRL4Z86GWb1ZVeVh/+mIO1R4Ayj0HYspDruvFa9mECR4K1QhCN9mRE5sGBMiEOK0O/pf8Y3K2J9LQ6UYAt2yHzL7fAMAKOOw==" + runcmd: + - "sed -i \"s/GSSAPIAuthentication yes/GSSAPIAuthentication no/g\" /etc/ssh/sshd_config" + - "sed -i \"s/#UseDNS yes/UseDNS no/g\" /etc/ssh/sshd_config" + - "passwd -d deployment" + - "mkdir -pv /mnt/config" + - "mount /dev/disk/by-label/config-2 /mnt/config" + - "a=($(cat /mnt/config/openstack/latest/meta_data.json | /usr/local/bin/python2.7 -c 'import json,sys;obj=json.load(sys.stdin); print json.dumps(obj[\"files\"]);'));paths=0; values=0;counter=0;function remove_json_chars() { input=$1; echo $1 | sed 's/\\}//g' | sed 's/,//g' | sed 's/]//g' | sed 's/\"//g'; };for data in ${a[@]} ; do index=$(( $counter % 4 )); if [[ \"$index\" == 1 ]];then b[$paths]=$(remove_json_chars $data); paths=$(( $paths + 1 )) ; fi; if [[ \"$index\" == 3 ]];then c[$values]=$(remove_json_chars $data); values=$(( $values + 1 )) ; fi; counter=$(( $counter + 1 )) ; done; path_counter=0; for file in ${c[@]} ; do cp /mnt/config/openstack${file} ${b[$path_counter]}; path_counter=$(( ${path_counter} + 1 )) ; done" + - "cat /mnt/config/openstack/latest/meta_data.json | /usr/local/bin/python2.7 -c 'import json,sys;obj=json.load(sys.stdin); print json.dumps(obj[\"meta\"]);' > /meta.js" + - "sed -i 's|_colon_|:|g' /meta.js" + - "sed -i 's|_slash_|/|g' /meta.js" + - "/usr/local/bin/python2.7 /tmp/wait_for_resources.py -m %manager_oam_direct_ip_0%" + - "chmod 0754 /root/call_home.py /root/RegisterStatus/register_status.py /root/CheckAvailability/check_availability.py" + - "/usr/local/bin/python2.7 /root/CheckAvailability/check_availability.py %manager_oam_direct_ip_0%" + - "echo MH vLB_id_number %vLB_id_number%" + - "echo MH probe_data %vLB_id_number%" + - "echo MH probe_log %vLB_log%" + - "echo MH probe_config %vLB_config%" + - "probe_id=`echo %vLB_id_number%`" + - "echo vLB_cluster_name %vLB_cluster_name%" + - "echo vLB_node_count %vLB_node_count%" + - "sed -i 's/VLB_CLUSTER_NAME/%vLB_cluster_name%/g' /root/dependencies.json" + - "sed -i 's/VPROBE_CLUSTER_NAME/%vProbe_cluster_name%/g' /root/dependencies.json" + - "sed -i 's/VLB_NODE_COUNT/%vLB_node_count%/g' /root/dependencies.json" + - "sed -i 's/MANAGER_INSTANCE_NAME/%manager_hostname%.%domain_name%/g' /root/dependencies.json" + - "sed -i 's/VLB_INSTANCE/%vLBInstance%/g' /root/dependencies.json" + - "echo \"${probe_id}\" > /etc/hostname" + - "mkdir -pv /radcom/software" + - "/usr/local/bin/python2.7 /root/call_home.py %manager_oam_direct_ip_0%" diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEAdd_On_Module_vLBTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEAdd_On_Module_vLBTemplate.yaml new file mode 100644 index 0000000000..afc435adaf --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEAdd_On_Module_vLBTemplate.yaml @@ -0,0 +1,287 @@ +heat_template_version: 2014-10-16 + +parameters: + domain_name: + type: string + vlb_image_name: + type: string + manager_name_0: + type: string + manager_oam_direct_ip_0: + type: string + ntp_timezone: + type: string + oam_private_net_name: + type: string + packet_internal_network: + type: string + packet_mirror_network: + type: string + region_name: + type: string + rpmrepository_ip_0: + type: string + security_group: + type: string + tenant_name: + type: string + availability_zone_0: + type: string + vLB_cluster_name: + type: string + vLB_flavor_name: + type: string + vLB_index: + type: number + vLB_names: + type: comma_delimited_list + vLB_node_count: + type: number + vLB_type: + type: string + vLB_version_name: + type: string + vLB_volume_name_0: + type: string + vLB_volume_name_1: + type: string + vLB_volume_name_2: + type: string + vLB_volume_size_0: + type: number + vLB_volume_size_1: + type: number + vLB_volume_size_2: + type: number + vLB_volume_type_0: + type: string + vLB_volume_type_1: + type: string + vLB_volume_type_2: + type: string + vProbe_cluster_name: + type: string + vf_module_id: + type: string + vf_module_name: + type: string + vnf_id: + type: string +resources: + oam_private_net_network_port: + properties: + network: + get_param: oam_private_net_name + security_groups: + - get_param: security_group + type: OS::Neutron::Port + packet_internal_network_port: + properties: + network: + get_param: packet_internal_network + security_groups: + - get_param: security_group + type: OS::Neutron::Port + packet_mirror_network_port: + properties: + network: + get_param: packet_mirror_network + security_groups: + - get_param: security_group + type: OS::Neutron::Port + vLBInstance: + properties: + availability_zone: + get_param: availability_zone_0 + config_drive: true + flavor: + get_param: vLB_flavor_name + image: + get_param: vlb_image_name + metadata: + DPDK: DPDK_IP + cluster_name: + get_param: vLB_cluster_name + machine_name: + get_param: + - vLB_names + - get_param: vLB_index + machine_type: vLB + manager_oam_direct_ip_0: + get_param: manager_oam_direct_ip_0 + mount_colon__slash_config: + get_resource: vLB_volume_2 + mount_colon__slash_data: + get_resource: vLB_volume_0 + mount_colon__slash_log: + get_resource: vLB_volume_1 + ntp_timezone: + get_param: ntp_timezone + oam_private_network_cidr: + get_attr: + - oam_private_net_network_port + - subnets + - 0 + - cidr + oam_private_network_ip_0: + get_attr: + - oam_private_net_network_port + - fixed_ip_0s + - 0 + - ip_address + packet_internal_network_cidr: + get_attr: + - packet_internal_network_port + - subnets + - 0 + - cidr + packet_internal_network_ip_0: + get_attr: + - packet_internal_network_port + - fixed_ip_0s + - 0 + - ip_address + packet_mirror_network_cidr: + get_attr: + - packet_mirror_network_port + - subnets + - 0 + - cidr + packet_mirror_network_ip_0: + get_attr: + - packet_mirror_network_port + - fixed_ip_0s + - 0 + - ip_address + region: + get_param: region_name + repo_ip_0: + get_param: rpmrepository_ip_0 + tenant: + get_param: tenant_name + vLBAgentInstance: + get_param: vLB_index + vLBAgent_id: + get_attr: + - vLB_id + - value + vLBAgent_name: + get_param: + - vLB_names + - get_param: vLB_index + vLBAgent_type: + get_param: vLB_type + vLBAgent_version_name: + get_param: vLB_version_name + version_number: + get_param: vLB_version_name + vf_module_id: + get_param: vf_module_id + vf_module_name: + get_param: vf_module_name + vnf_id: + get_param: vnf_id + name: + get_param: + - vLB_names + - get_param: vLB_index + networks: + - port: + get_resource: oam_private_net_network_port + - port: + get_resource: packet_mirror_network_port + - port: + get_resource: packet_internal_network_port + personality: + /root/CheckAvailability/check_availability.py: + get_file: check_availability.py + /root/RegisterStatus/register_status.py: + get_file: register_status.py + /root/call_home.py: + get_file: call_home.py + /root/dependencies.json: + get_file: vlbdependencies.json + /tmp/wait_for_resources.py: + get_file: wait_for_resources.py + user_data: + str_replace: + params: + '%domain_name%': + get_param: domain_name + '%manager_hostname%': + get_param: manager_name_0 + '%manager_oam_direct_ip_0%': + get_param: manager_oam_direct_ip_0 + '%rpm_repo_ip_0%': + get_param: rpmrepository_ip_0 + '%vLBInstance%': + get_param: vLB_index + '%vLB_cluster_name%': + get_param: vLB_cluster_name + '%vLB_config%': + get_resource: vLB_volume_2 + '%vLB_data%': + get_resource: vLB_volume_0 + '%vLB_id_number%': + get_attr: + - vLB_id + - value + '%vLB_log%': + get_resource: vLB_volume_1 + '%vLB_node_count%': + get_param: vLB_node_count + '%vLB_version_name%': + get_param: vLB_version_name + '%vProbe_cluster_name%': + get_param: vProbe_cluster_name + template: + get_file: FEAdd_On_Module_vLBCloudConfig + user_data_format: RAW + type: OS::Nova::Server + vLB_id: + properties: + length: 4 + sequence: digits + type: OS::Heat::RandomString + vLB_volume_0: + properties: + size: + get_param: vLB_volume_size_0 + volume_type: + get_param: vLB_volume_type_0 + type: OS::Cinder::Volume + vLB_volume_0_att: + properties: + instance_uuid: + get_resource: vLBInstance + volume_id: + get_resource: vLB_volume_0 + type: OS::Cinder::VolumeAttachment + vLB_volume_1: + properties: + size: + get_param: vLB_volume_size_1 + volume_type: + get_param: vLB_volume_type_1 + type: OS::Cinder::Volume + vLB_volume_1_att: + properties: + instance_uuid: + get_resource: vLBInstance + volume_id: + get_resource: vLB_volume_1 + type: OS::Cinder::VolumeAttachment + vLB_volume_2: + properties: + size: + get_param: vLB_volume_size_2 + volume_type: + get_param: vLB_volume_type_2 + type: OS::Cinder::Volume + vLB_volume_2_att: + properties: + instance_uuid: + get_resource: vLBInstance + volume_id: + get_resource: vLB_volume_2 + type: OS::Cinder::VolumeAttachment diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEAdd_On_Module_vProbeCloudConfig b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEAdd_On_Module_vProbeCloudConfig new file mode 100644 index 0000000000..f31b3dde85 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEAdd_On_Module_vProbeCloudConfig @@ -0,0 +1,50 @@ +#cloud-config + manage_etc_hosts: true + yum_repos: + Base_Repo: + baseurl: "https://%rpm_repo_ip_0%/repo/base" + enabled: true + gpgcheck: false + name: "Base Repo" + sslverify: 0 + sslclientcert: /var/lib/yum/yum.cert + sslclientkey: /var/lib/yum/yum.key + Radcom: + baseurl: "https://%rpm_repo_ip_0%/repo/radcom" + enabled: true + gpgcheck: false + name: "Radcom Repo" + sslverify: 0 + sslclientcert: /var/lib/yum/yum.cert + sslclientkey: /var/lib/yum/yum.key + package_upgrade: false + ssh_authorized_keys: + - "ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAQEAnuJOkl2iGaFB+BCeRak67Chy+cATmvsqLPDYQ6GMRrGg0kBMcIRExshmTJQFGC+m2xiXeo41pSLaR1vt5fDB+3ewUSBcNtZrr5VxzBWzOab1VO+sCx4f8gOkSJ7plRJ/8xZqyhV+jTkb02peWbqtW+WqERTIyGul/eMNCDnwDNxznb8jMI3KWUd3ujWgFnk8EJ9c41y2unvk42XDOUlnuvR1/FW/qPRSNwPQGLEDlDje29xB3yaMQuJRL4Z86GWb1ZVeVh/+mIO1R4Ayj0HYspDruvFa9mECR4K1QhCN9mRE5sGBMiEOK0O/pf8Y3K2J9LQ6UYAt2yHzL7fAMAKOOw==" + runcmd: + - "sed -i \"s/GSSAPIAuthentication yes/GSSAPIAuthentication no/g\" /etc/ssh/sshd_config" + - "sed -i \"s/#UseDNS yes/UseDNS no/g\" /etc/ssh/sshd_config" + - "passwd -d deployment" + - "mkdir -pv /mnt/config" + - "mount /dev/disk/by-label/config-2 /mnt/config" + - "a=($(cat /mnt/config/openstack/latest/meta_data.json | /usr/local/bin/python2.7 -c 'import json,sys;obj=json.load(sys.stdin); print json.dumps(obj[\"files\"]);'));paths=0; values=0;counter=0;function remove_json_chars() { input=$1; echo $1 | sed 's/\\}//g' | sed 's/,//g' | sed 's/]//g' | sed 's/\"//g'; };for data in ${a[@]} ; do index=$(( $counter % 4 )); if [[ \"$index\" == 1 ]];then b[$paths]=$(remove_json_chars $data); paths=$(( $paths + 1 )) ; fi; if [[ \"$index\" == 3 ]];then c[$values]=$(remove_json_chars $data); values=$(( $values + 1 )) ; fi; counter=$(( $counter + 1 )) ; done; path_counter=0; for file in ${c[@]} ; do cp /mnt/config/openstack${file} ${b[$path_counter]}; path_counter=$(( ${path_counter} + 1 )) ; done" + - "cat /mnt/config/openstack/latest/meta_data.json | /usr/local/bin/python2.7 -c 'import json,sys;obj=json.load(sys.stdin); print json.dumps(obj[\"meta\"]);' > /meta.js" + - "sed -i 's|_colon_|:|g' /meta.js" + - "sed -i 's|_slash_|/|g' /meta.js" + - "/usr/local/bin/python2.7 /tmp/wait_for_resources.py -m %manager_oam_direct_ip_0%" + - "chmod 0754 /root/call_home.py /root/RegisterStatus/register_status.py /root/CheckAvailability/check_availability.py" + - "/usr/local/bin/python2.7 /root/CheckAvailability/check_availability.py %manager_oam_direct_ip_0%" + - "echo MH probe_data %probe_data%" + - "echo MH probe_log %probe_log%" + - "echo MH probe_config %probe_config%" + - "sed -i 's/QROUTER_CLUSTER_NAME/%qrouter_cluster_name%/g' /root/dependencies.json" + - "sed -i 's/VPROBE_CLUSTER_NAME/%vProbe_cluster_name%/g' /root/dependencies.json" + - "sed -i 's/VPROBE_NODE_COUNT/%vProbe_node_count%/g' /root/dependencies.json" + - "sed -i 's/MANAGER_INSTANCE_NAME/%manager_hostname%.%domain_name%/g' /root/dependencies.json" + - "sed -i 's/QTRACE_HOST_NAME/%qtrace_hostname%.%win_domain_name%/g' /root/dependencies.json" + - "sed -i 's/PROBE_INSTANCE/%ProbeInstance%/g' /root/dependencies.json" + - "probe_id=$(($RANDOM%8999+1000))" + - "echo $probe_id > /etc/hostname" + - "sed -i 's/P_ID/'$probe_id'/g' /meta.js" + - "echo MH probe_id=$probe_id" + - "mkdir -pv /radcom/software" + - "/usr/local/bin/python2.7 /root/call_home.py %manager_oam_direct_ip_0%" diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEAdd_On_Module_vProbeTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEAdd_On_Module_vProbeTemplate.yaml new file mode 100644 index 0000000000..d343ee5595 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEAdd_On_Module_vProbeTemplate.yaml @@ -0,0 +1,308 @@ +heat_template_version: 2014-10-16 + +parameters: + cdr_network: + type: string + domain_name: + type: string + vprobe_image_name: + type: string + manager_name_0: + type: string + manager_oam_direct_ip_0: + type: string + ntp_timezone: + type: string + oam_private_net_name: + type: string + packet_internal_network: + type: string + qrouter_cluster_name: + type: string + qtrace_name_0: + type: string + region_name: + type: string + rpmrepository_ip_0: + type: string + security_group: + type: string + tenant_name: + type: string + vLB_node_count: + type: number + vProbe_cluster_name: + type: string + vProbe_node_count: + type: number + vProbe_version_name: + type: string + vf_module_id: + type: string + vf_module_name: + type: string + vnf_id: + type: string + vprobe_AppDependenciesMachineType: + type: string + availability_zone_0: + type: string + vprobe_flavor_name: + type: string + vprobe_index: + type: number + vprobe_names: + type: comma_delimited_list + vprobe_type: + type: string + vprobe_volume_name_0: + type: string + vprobe_volume_name_1: + type: string + vprobe_volume_name_2: + type: string + vprobe_volume_size_0: + type: number + vprobe_volume_size_1: + type: number + vprobe_volume_size_2: + type: number + vprobe_volume_type_0: + type: string + vprobe_volume_type_1: + type: string + vprobe_volume_type_2: + type: string + win_domain_name: + type: string +resources: + ProbeInstance: + properties: + availability_zone: + get_param: availability_zone_0 + config_drive: true + flavor: + get_param: vprobe_flavor_name + image: + get_param: vprobe_image_name + metadata: + AppDependencies: + get_param: vprobe_AppDependenciesMachineType + DPDK: DPDK_IP + ProbeInstance: + get_param: vprobe_index + cdr_network_cidr: + get_attr: + - cdr_network_port + - subnets + - 0 + - cidr + cdr_network_ip_0: + get_attr: + - cdr_network_port + - fixed_ip_0s + - 0 + - ip_address + cluster_name: + get_param: vProbe_cluster_name + machine_name: + get_param: + - vprobe_names + - get_param: vprobe_index + machine_type: vProbe + manager_oam_direct_ip_0: + get_param: manager_oam_direct_ip_0 + mount_colon__slash_config: + get_resource: vprobe_volume_2 + mount_colon__slash_data: + get_resource: vprobe_volume_0 + mount_colon__slash_log: + get_resource: vprobe_volume_1 + ntp_timezone: + get_param: ntp_timezone + oam_private_network_cidr: + get_attr: + - oam_private_net_network_port + - subnets + - 0 + - cidr + oam_private_network_ip_0: + get_attr: + - oam_private_net_network_port + - fixed_ip_0s + - 0 + - ip_address + packet_internal_network_cidr: + get_attr: + - packet_internal_network_port + - subnets + - 0 + - cidr + packet_internal_network_ip_0: + get_attr: + - packet_internal_network_port + - fixed_ip_0s + - 0 + - ip_address + probe_id: P_ID + probe_name: + get_param: + - vprobe_names + - get_param: vprobe_index + region: + get_param: region_name + repo_ip_0: + get_param: rpmrepository_ip_0 + tenant: + get_param: tenant_name + vLB_node_count: + get_param: vLB_node_count + vProbe_node_count: + get_param: vProbe_node_count + vProbe_version_name: + get_param: vProbe_version_name + version_number: + get_param: vProbe_version_name + vf_module_id: + get_param: vf_module_id + vf_module_name: + get_param: vf_module_name + vnf_id: + get_param: vnf_id + vprobe_type: + get_param: vprobe_type + name: + get_param: + - vprobe_names + - get_param: vprobe_index + networks: + - port: + get_resource: oam_private_net_network_port + - port: + get_resource: cdr_network_port + - port: + get_resource: packet_internal_network_port + personality: + /root/CheckAvailability/check_availability.py: + get_file: check_availability.py + /root/RegisterStatus/register_status.py: + get_file: register_status.py + /root/call_home.py: + get_file: call_home.py + /root/dependencies.json: + get_file: vprobedependencies.json + /tmp/wait_for_resources.py: + get_file: wait_for_resources.py + user_data: + str_replace: + params: + '%ProbeInstance%': + get_param: vprobe_index + '%domain_name%': + get_param: domain_name + '%manager_hostname%': + get_param: manager_name_0 + '%manager_oam_direct_ip_0%': + get_param: manager_oam_direct_ip_0 + '%probe_config%': + get_resource: vprobe_volume_2 + '%probe_data%': + get_resource: vprobe_volume_0 + '%probe_id_number%': + get_attr: + - vprobe_id + - value + '%probe_log%': + get_resource: vprobe_volume_1 + '%qrouter_cluster_name%': + get_param: qrouter_cluster_name + '%qtrace_hostname%': + get_param: qtrace_name_0 + '%rpm_repo_ip_0%': + get_param: rpmrepository_ip_0 + '%vProbe_cluster_name%': + get_param: vProbe_cluster_name + '%vProbe_node_count%': + get_param: vProbe_node_count + '%vProbe_version_name%': + get_param: vProbe_version_name + '%win_domain_name%': + get_param: win_domain_name + template: + get_file: FEAdd_On_Module_vProbeCloudConfig + user_data_format: RAW + type: OS::Nova::Server + cdr_network_port: + properties: + network: + get_param: cdr_network + security_groups: + - get_param: security_group + type: OS::Neutron::Port + oam_private_net_network_port: + properties: + network: + get_param: oam_private_net_name + security_groups: + - get_param: security_group + type: OS::Neutron::Port + packet_internal_network_port: + properties: + network: + get_param: packet_internal_network + security_groups: + - get_param: security_group + type: OS::Neutron::Port + vprobe_id: + properties: + length: 4 + sequence: digits + type: OS::Heat::RandomString + vprobe_volume_0: + properties: + description: + get_param: vprobe_volume_name_0 + size: + get_param: vprobe_volume_size_0 + volume_type: + get_param: vprobe_volume_type_0 + type: OS::Cinder::Volume + vprobe_volume_0_att: + properties: + instance_uuid: + get_resource: ProbeInstance + volume_id: + get_resource: vprobe_volume_0 + type: OS::Cinder::VolumeAttachment + vprobe_volume_1: + properties: + description: + get_param: vprobe_volume_name_1 + size: + get_param: vprobe_volume_size_1 + volume_type: + get_param: vprobe_volume_type_1 + type: OS::Cinder::Volume + vprobe_volume_1_att: + properties: + instance_uuid: + get_resource: ProbeInstance + volume_id: + get_resource: vprobe_volume_1 + type: OS::Cinder::VolumeAttachment + vprobe_volume_2: + properties: + description: + get_param: vprobe_volume_name_2 + size: + get_param: vprobe_volume_size_2 + volume_type: + get_param: vprobe_volume_type_2 + type: OS::Cinder::Volume + vprobe_volume_2_att: + properties: + instance_uuid: + get_resource: ProbeInstance + volume_id: + get_resource: vprobe_volume_2 + type: OS::Cinder::VolumeAttachment \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEBase_Module.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEBase_Module.env new file mode 100644 index 0000000000..76907855eb --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEBase_Module.env @@ -0,0 +1,91 @@ +parameters: + base_image_name: rprb_centos_6_7_05_24_2016 + #domain_name: novalocal + #manager_name_0: zrsrv01qmn001 + #manager_oam_direct_ip_0: null + ntp_timezone: UTC + packet_internal_network_name: rprb_26071_mme_int_pktinternal_net_1 + packet_internal_network_subnet_alloc_end: 192.0.6.250 + packet_internal_network_subnet_alloc_start: 192.0.6.2 + packet_internal_network_subnet_cidr: 192.0.6.0/24 + packet_internal_network_subnet_name: rprb_26071_mme_int_pktinternal_net_1_subnet + packet_mirror_network_name: rprb_26071_mme_int_pktmirror_net_1 + packet_mirror_network_subnet_alloc_end: 20.20.5.250 + packet_mirror_network_subnet_alloc_start: 20.20.5.2 + packet_mirror_network_subnet_cidr: 20.20.5.0/24 + packet_mirror_network_subnet_name: rprb_26071_mme_int_pktmirror_net_1_subnet +# availability_zone_0: nova + qrouter_cluster_name: qrouter_cluster + qrouter_flavor_name: m1.large +# qrouter_names: zrsrv01xlb000,zrsrv01xlb001,zrsrv01xlb002,zrsrv01xlb003,zrsrv01xlb004 + qrouter_node_count: 1 + #qrouter_vnf_module_name: QRouter + qrouter_volume_name_0: data + qrouter_volume_name_1: log + qrouter_volume_name_2: config + qrouter_volume_size_0: 1 + qrouter_volume_size_1: 1 + qrouter_volume_size_2: 1 + qrouter_volume_type_0: volumes_ceph + qrouter_volume_type_1: volumes_ceph + qrouter_volume_type_2: volumes_ceph + #qtrace_name_0: zrsrv01qtr001 + #region_name: Tel Aviv + rpmrepository_ip_0: null + #tenant_name: RADCOM +# availability_zone_1: nova + vLBAgent_cluster_name: vLBAgent_cluster + vLBAgent_flavor_name: m1.large +# vLBAgent_names: zrvlb01mme000,zrvlb01mme001,zrvlb01mme002,zrvlb01mme003,zrvlb01mme004 + vLBAgent_node_count: 1 + vLBAgent_type: mme + vLBAgent_version_name: vProbe.r.11.1.e._08_16-12_53 + vLBAgent_volume_name_0: data + vLBAgent_volume_name_1: log + vLBAgent_volume_name_2: config + vLBAgent_volume_size_0: 15 + vLBAgent_volume_size_1: 1 + vLBAgent_volume_size_2: 1 + vLBAgent_volume_type_0: volumes_ceph + vLBAgent_volume_type_1: volumes_ceph + vLBAgent_volume_type_2: volumes_ceph +# availability_zone_2: nova + vLB_cluster_name: vLB_cluster + vLB_flavor_name: m1.large +# vLB_names: zrvlb01gtp000,zrvlb01gtp001,zrvlb01gtp002,zrvlb01gtp003,zrvlb01gtp004 + vLB_node_count: 1 + vLB_type: mme + vLB_version_name: vProbe.r.11.1.e._08_16-12_53 + vLB_volume_name_0: data + vLB_volume_name_1: log + vLB_volume_name_2: config + vLB_volume_size_0: 10 + vLB_volume_size_1: 1 + vLB_volume_size_2: 1 + vLB_volume_type_0: volumes_ceph + vLB_volume_type_1: volumes_ceph + vLB_volume_type_2: volumes_ceph + vProbe_cluster_name: vProbe_cluster + vProbe_node_count: 1 + vProbe_version_name: vProbe.r.11.1.e._08_16-12_53 + version_number: 11.1.5 + #vf_module_id: 0bb8ee04-c9aa-4b51-8aa6-763343d25692 + #vlb_vnf_module_name: vLB + #vlbagent_vnf_module_name: vLBAgent + #vnf_id: df9ad862-763e-463b-a761-eba2077f9930 + vprobe_AppDependenciesMachineType: DatabaseUpgrade +# availability_zone_3: nova + vprobe_flavor_name: m1.large +# vprobe_names: zrprb01mme000,zrprb01mme001,zrprb01mme002,zrprb01mme003,zrprb01mme004 + vprobe_type: mme + #vf_module_name: vProbe + vprobe_volume_name_0: data + vprobe_volume_name_1: log + vprobe_volume_name_2: config + vprobe_volume_size_0: 100 + vprobe_volume_size_1: 5 + vprobe_volume_size_2: 1 + vprobe_volume_type_0: volumes_ceph + vprobe_volume_type_1: volumes_ceph + vprobe_volume_type_2: volumes_ceph + #win_domain_name: openstacklocal diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEBase_Module.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEBase_Module.yaml new file mode 100644 index 0000000000..5d0a5457ca --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/FEBase_Module.yaml @@ -0,0 +1,670 @@ +heat_template_version: '2014-10-16' + +parameters: + base_image_name: + description: The base ID or name of the image to boot with + type: string + cdr_network: + description: A string specifying a symbolic name for the network + type: string + domain_name: + description: The servers domain + type: string + manager_name_0: + description: VM Name for Manager VM 0 + type: string + manager_oam_direct_ip_0: + description: The public ip address of the manager + type: string + ntp_timezone: + description: Name of NTP Time zone to be used + type: string + oam_private_net_name: + description: A string specifying a symbolic name for the network + type: string + packet_internal_network_name: + description: A string specifying a symbolic name for the network + type: string + packet_internal_network_subnet_alloc_end: + description: End address for the allocation pool + type: string + packet_internal_network_subnet_alloc_start: + description: Start address for the allocation pool + type: string + packet_internal_network_subnet_cidr: + description: The Classless Inter-Domain Routing + type: string + packet_internal_network_subnet_name: + description: The name of the subnet + type: string + packet_mirror_network_name: + description: A string specifying a symbolic name for the network + type: string + packet_mirror_network_subnet_alloc_end: + description: End address for the allocation pool + type: string + packet_mirror_network_subnet_alloc_start: + description: Start address for the allocation pool + type: string + packet_mirror_network_subnet_cidr: + description: The Classless Inter-Domain Routing + type: string + packet_mirror_network_subnet_name: + description: The name of the subnet + type: string + availability_zone_0: + description: Name of the availability zone for server placement + type: string + qrouter_cluster_name: + description: The component cluster name + type: string + qrouter_flavor_name: + description: The ID or name of the flavor to boot onto + type: string + qrouter_names: + description: VM Names for QRouter VMs + type: comma_delimited_list + qrouter_node_count: + description: The number of nodes to create + type: number + qrouter_volume_name_0: + description: The name of the volume + type: string + qrouter_volume_name_1: + description: The name of the volume + type: string + qrouter_volume_name_2: + description: The name of the volume + type: string + qrouter_volume_size_0: + description: The size of the volume in GB + type: number + qrouter_volume_size_1: + description: The size of the volume in GB + type: number + qrouter_volume_size_2: + description: The size of the volume in GB + type: number + qrouter_volume_type_0: + description: The type of the volume mapping to a backend + type: string + qrouter_volume_type_1: + description: The type of the volume mapping to a backend + type: string + qrouter_volume_type_2: + description: The type of the volume mapping to a backend + type: string + qtrace_name_0: + description: VM Name for QRouter VMs + type: string + region_name: + description: Name of region to be used + type: string + rpmrepository_ip_0: + description: The public ip address of the repository + type: string + tenant_name: + description: Name of tenant to be used + type: string + availability_zone_1: + description: Name of the availability zone for server placement + type: string + vLBAgent_cluster_name: + description: The component cluster name + type: string + vLBAgent_flavor_name: + description: The ID or name of the flavor to boot onto + type: string + vLBAgent_names: + description: VM Names for vLBAgent VMs + type: comma_delimited_list + vLBAgent_node_count: + description: The number of nodes to create + type: number + vLBAgent_type: + description: vLBAgent Type. mme or sgw + type: string + vLBAgent_version_name: + description: The version name of the component + type: string + vLBAgent_volume_name_0: + description: The name of the volume + type: string + vLBAgent_volume_name_1: + description: The name of the volume + type: string + vLBAgent_volume_name_2: + description: The name of the volume + type: string + vLBAgent_volume_size_0: + description: The size of the volume in GB + type: number + vLBAgent_volume_size_1: + description: The size of the volume in GB + type: number + vLBAgent_volume_size_2: + description: The size of the volume in Gigabytes. + type: number + vLBAgent_volume_type_0: + description: The type of the volume mapping to a backend + type: string + vLBAgent_volume_type_1: + description: The type of the volume mapping to a backend + type: string + vLBAgent_volume_type_2: + description: The Cinder volume type. Used to specify the backend. + type: string + availability_zone_2: + description: Name of the availability zone for server placement. + type: string + vLB_cluster_name: + description: The component cluster name. + type: string + vLB_flavor_name: + description: The name of the flavor to boot onto. + type: string + vLB_names: + description: VM Names for vLB VMs + type: comma_delimited_list + vLB_node_count: + description: The number of nodes to create. + type: number + vLB_type: + description: The type of VLB. MME or SGW. + type: string + vLB_version_name: + description: The version name of the component. + type: string + vLB_volume_name_0: + description: The name of the volume + type: string + vLB_volume_name_1: + description: The name of the volume + type: string + vLB_volume_name_2: + description: The name of the volume + type: string + vLB_volume_size_0: + description: The size of the volume in GB. + type: number + vLB_volume_size_1: + description: The size of the volume in GB. + type: number + vLB_volume_size_2: + description: The size of the volume in GB. + type: number + vLB_volume_type_0: + description: The type of the volume mapping to a backend + type: string + vLB_volume_type_1: + description: The type of the volume mapping to a backend + type: string + vLB_volume_type_2: + description: The type of the volume mapping to a backend + type: string + vProbe_cluster_name: + description: The component cluster name + type: string + vProbe_node_count: + description: The number of nodes to create + type: number + vProbe_version_name: + description: The version name of the component + type: string + version_number: + description: The version number of the component + type: string + vf_module_id: + description: The VF MODULE ID of the RADCOM System. + type: string + vnf_id: + description: The VNF ID of the RADCOM System. + type: string + vprobe_AppDependenciesMachineType: + description: The application dependencies + type: string + availability_zone_3: + description: Name of the availability zone for server placement + type: string + vprobe_flavor_name: + description: The name of the flavor to boot onto + type: string + vprobe_names: + description: VM Names for vProbe VMs + type: comma_delimited_list + vprobe_type: + description: The type of vProbe. MME or SGW. + type: string + vf_module_name: + description: The VNF module name for vProbe elements. + type: string + vprobe_volume_name_0: + description: The name of the volume + type: string + vprobe_volume_name_1: + description: The name of the volume + type: string + vprobe_volume_name_2: + description: The name of the volume + type: string + vprobe_volume_size_0: + description: The size of the volume in GB + type: number + vprobe_volume_size_1: + description: The size of the volume in GB + type: number + vprobe_volume_size_2: + description: The size of the volume in GB + type: number + vprobe_volume_type_0: + description: The type of the volume mapping to a backend + type: string + vprobe_volume_type_1: + description: The type of the volume mapping to a backend + type: string + vprobe_volume_type_2: + description: The type of the volume mapping to a backend + type: string + win_domain_name: + description: Windows servers' domain + type: string +resources: + QRouter: + depends_on: + - security_group + - packet_mirror_network + - packet_mirror_network_subnet + - packet_internal_network + - packet_internal_network_subnet + properties: + cdr_network: + get_param: cdr_network + domain_name: + get_param: domain_name + qrouter_image_name: + get_param: base_image_name + manager_name_0: + get_param: manager_name_0 + manager_oam_direct_ip_0: + get_param: manager_oam_direct_ip_0 + ntp_timezone: + get_param: ntp_timezone + oam_private_net_name: + get_param: oam_private_net_name + availability_zone_0: + get_param: availability_zone_0 + qrouter_cluster_name: + get_param: qrouter_cluster_name + qrouter_flavor_name: + get_param: qrouter_flavor_name + qrouter_names: + get_param: qrouter_names + qrouter_node_count: + get_param: qrouter_node_count + qrouter_volume_name_0: + get_param: qrouter_volume_name_0 + qrouter_volume_name_1: + get_param: qrouter_volume_name_1 + qrouter_volume_name_2: + get_param: qrouter_volume_name_2 + qrouter_volume_size_0: + get_param: qrouter_volume_size_0 + qrouter_volume_size_1: + get_param: qrouter_volume_size_1 + qrouter_volume_size_2: + get_param: qrouter_volume_size_2 + qrouter_volume_type_0: + get_param: qrouter_volume_type_0 + qrouter_volume_type_1: + get_param: qrouter_volume_type_1 + qrouter_volume_type_2: + get_param: qrouter_volume_type_2 + region_name: + get_param: region_name + rpmrepository_ip_0: + get_param: rpmrepository_ip_0 + security_group: + get_resource: security_group + tenant_name: + get_param: tenant_name + version_number: + get_param: version_number + vf_module_id: + get_param: vf_module_id + vf_module_name: + get_param: vf_module_name + vnf_id: + get_param: vnf_id + type: FEAdd_On_Module_QRouterTemplate.yaml + packet_internal_network: + properties: + name: + get_param: packet_internal_network_name + type: OS::Neutron::Net + packet_internal_network_subnet: + properties: + allocation_pools: + - end: + get_param: packet_internal_network_subnet_alloc_end + start: + get_param: packet_internal_network_subnet_alloc_start + cidr: + get_param: packet_internal_network_subnet_cidr + enable_dhcp: true + gateway_ip_0: null + name: + get_param: packet_internal_network_subnet_name + network_id: + get_resource: packet_internal_network + type: OS::Neutron::Subnet + packet_mirror_network: + properties: + name: + get_param: packet_mirror_network_name + type: OS::Neutron::Net + packet_mirror_network_subnet: + properties: + allocation_pools: + - end: + get_param: packet_mirror_network_subnet_alloc_end + start: + get_param: packet_mirror_network_subnet_alloc_start + cidr: + get_param: packet_mirror_network_subnet_cidr + enable_dhcp: true + gateway_ip_0: null + name: + get_param: packet_mirror_network_subnet_name + network_id: + get_resource: packet_mirror_network + type: OS::Neutron::Subnet + security_group: + properties: + name: FE_radcom_security_group + rules: + - port_range_max: 23 + port_range_min: 23 + protocol: tcp + - port_range_max: 123 + port_range_min: 123 + protocol: tcp + - port_range_max: 3389 + port_range_min: 3389 + protocol: tcp + - port_range_max: 5434 + port_range_min: 5434 + protocol: udp + - port_range_max: 5443 + port_range_min: 5435 + protocol: tcp + - port_range_max: 8000 + port_range_min: 8000 + protocol: tcp + - port_range_max: 9900 + port_range_min: 9900 + protocol: tcp + - port_range_max: 12050 + port_range_min: 12000 + protocol: tcp + - port_range_max: 161 + port_range_min: 161 + protocol: tcp + - port_range_max: 8000 + port_range_min: 8000 + protocol: udp + - protocol: icmp + - protocol: 47 + - port_range_max: 22 + port_range_min: 22 + protocol: tcp + - port_range_max: 3050 + port_range_min: 3000 + protocol: tcp + - port_range_max: 8081 + port_range_min: 8080 + protocol: tcp + - port_range_max: 8084 + port_range_min: 8084 + protocol: tcp + - port_range_max: 4000 + port_range_min: 4000 + protocol: tcp + - port_range_max: 33000 + port_range_min: 33000 + protocol: tcp + - port_range_max: 8082 + port_range_min: 8082 + protocol: tcp + type: OS::Neutron::SecurityGroup + vLB: + depends_on: + - security_group + - packet_mirror_network + - packet_mirror_network_subnet + - packet_internal_network + - packet_internal_network_subnet + properties: + domain_name: + get_param: domain_name + vlb_image_name: + get_param: base_image_name + manager_name_0: + get_param: manager_name_0 + manager_oam_direct_ip_0: + get_param: manager_oam_direct_ip_0 + ntp_timezone: + get_param: ntp_timezone + oam_private_net_name: + get_param: oam_private_net_name + packet_internal_network: + get_resource: packet_internal_network + packet_mirror_network: + get_resource: packet_mirror_network + region_name: + get_param: region_name + rpmrepository_ip_0: + get_param: rpmrepository_ip_0 + security_group: + get_resource: security_group + tenant_name: + get_param: tenant_name + availability_zone_0: + get_param: availability_zone_1 + vLB_cluster_name: + get_param: vLB_cluster_name + vLB_flavor_name: + get_param: vLB_flavor_name + vLB_names: + get_param: vLB_names + vLB_node_count: + get_param: vLB_node_count + vLB_type: + get_param: vLB_type + vLB_version_name: + get_param: vLB_version_name + vLB_volume_name_0: + get_param: vLB_volume_name_0 + vLB_volume_name_1: + get_param: vLB_volume_name_1 + vLB_volume_name_2: + get_param: vLB_volume_name_2 + vLB_volume_size_0: + get_param: vLB_volume_size_0 + vLB_volume_size_1: + get_param: vLB_volume_size_1 + vLB_volume_size_2: + get_param: vLB_volume_size_2 + vLB_volume_type_0: + get_param: vLB_volume_type_0 + vLB_volume_type_1: + get_param: vLB_volume_type_1 + vLB_volume_type_2: + get_param: vLB_volume_type_2 + vProbe_cluster_name: + get_param: vProbe_cluster_name + vf_module_id: + get_param: vf_module_id + vf_module_name: + get_param: vf_module_name + vnf_id: + get_param: vnf_id + type: FEAdd_On_Module_vLBTemplate.yaml + vLBAgent: + depends_on: + - security_group + - packet_mirror_network + - packet_mirror_network_subnet + - packet_internal_network + - packet_internal_network_subnet + properties: + domain_name: + get_param: domain_name + vlb_agent_image_name: + get_param: base_image_name + manager_name_0: + get_param: manager_name_0 + manager_oam_direct_ip_0: + get_param: manager_oam_direct_ip_0 + ntp_timezone: + get_param: ntp_timezone + oam_private_net_name: + get_param: oam_private_net_name + packet_internal_network: + get_resource: packet_internal_network + packet_mirror_network: + get_resource: packet_mirror_network + region_name: + get_param: region_name + rpmrepository_ip_0: + get_param: rpmrepository_ip_0 + security_group: + get_resource: security_group + tenant_name: + get_param: tenant_name + availability_zone_0: + get_param: availability_zone_2 + vLBAgent_cluster_name: + get_param: vLBAgent_cluster_name + vLBAgent_flavor_name: + get_param: vLBAgent_flavor_name + vLBAgent_names: + get_param: vLBAgent_names + vLBAgent_node_count: + get_param: vLBAgent_node_count + vLBAgent_type: + get_param: vLBAgent_type + vLBAgent_version_name: + get_param: vLBAgent_version_name + vLBAgent_volume_name_0: + get_param: vLBAgent_volume_name_0 + vLBAgent_volume_name_1: + get_param: vLBAgent_volume_name_1 + vLBAgent_volume_name_2: + get_param: vLBAgent_volume_name_2 + vLBAgent_volume_size_0: + get_param: vLBAgent_volume_size_0 + vLBAgent_volume_size_1: + get_param: vLBAgent_volume_size_1 + vLBAgent_volume_size_2: + get_param: vLBAgent_volume_size_2 + vLBAgent_volume_type_0: + get_param: vLBAgent_volume_type_0 + vLBAgent_volume_type_1: + get_param: vLBAgent_volume_type_1 + vLBAgent_volume_type_2: + get_param: vLBAgent_volume_type_2 + vLB_cluster_name: + get_param: vLB_cluster_name + vLB_node_count: + get_param: vLB_node_count + vProbe_cluster_name: + get_param: vProbe_cluster_name + vf_module_id: + get_param: vf_module_id + vf_module_name: + get_param: vf_module_name + vnf_id: + get_param: vnf_id + type: FEAdd_On_Module_vLBAgentTemplate.yaml + vProbe: + depends_on: + - security_group + - packet_mirror_network + - packet_mirror_network_subnet + - packet_internal_network + - packet_internal_network_subnet + properties: + cdr_network: + get_param: cdr_network + domain_name: + get_param: domain_name + vprobe_image_name: + get_param: base_image_name + manager_name_0: + get_param: manager_name_0 + manager_oam_direct_ip_0: + get_param: manager_oam_direct_ip_0 + ntp_timezone: + get_param: ntp_timezone + oam_private_net_name: + get_param: oam_private_net_name + packet_internal_network: + get_resource: packet_internal_network + qrouter_cluster_name: + get_param: qrouter_cluster_name + qtrace_name_0: + get_param: qtrace_name_0 + region_name: + get_param: region_name + rpmrepository_ip_0: + get_param: rpmrepository_ip_0 + security_group: + get_resource: security_group + tenant_name: + get_param: tenant_name + vLB_node_count: + get_param: vLB_node_count + vProbe_cluster_name: + get_param: vProbe_cluster_name + vProbe_node_count: + get_param: vProbe_node_count + vProbe_version_name: + get_param: vProbe_version_name + vf_module_id: + get_param: vf_module_id + vf_module_name: + get_param: vf_module_name + vnf_id: + get_param: vnf_id + vprobe_AppDependenciesMachineType: + get_param: vprobe_AppDependenciesMachineType + availability_zone_0: + get_param: availability_zone_3 + vprobe_flavor_name: + get_param: vprobe_flavor_name + vprobe_names: + get_param: vprobe_names + vprobe_type: + get_param: vprobe_type + vprobe_volume_name_0: + get_param: vprobe_volume_name_0 + vprobe_volume_name_1: + get_param: vprobe_volume_name_1 + vprobe_volume_name_2: + get_param: vprobe_volume_name_2 + vprobe_volume_size_0: + get_param: vprobe_volume_size_0 + vprobe_volume_size_1: + get_param: vprobe_volume_size_1 + vprobe_volume_size_2: + get_param: vprobe_volume_size_2 + vprobe_volume_type_0: + get_param: vprobe_volume_type_0 + vprobe_volume_type_1: + get_param: vprobe_volume_type_1 + vprobe_volume_type_2: + get_param: vprobe_volume_type_2 + win_domain_name: + get_param: win_domain_name + type: FEAdd_On_Module_vProbeTemplate.yaml + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..1daa39bfdc --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/MANIFEST.json @@ -0,0 +1,89 @@ +{ + "name": "", + "description": "", + "data": [ + { + "file": "FEAdd_On_Module_vLBTemplate.yaml", + "type": "HEAT", + "isBase": "false" + }, + { + "file": "FEAdd_On_Module_QRouterTemplate.yaml", + "type": "HEAT", + "isBase": "false" + }, + { + "file": "FEBase_Module.yaml", + "type": "HEAT", + "isBase": "true", + "data": [ + { + "file": "FEBase_Module.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "FEAdd_On_Module_vLBAgentTemplate.yaml", + "type": "HEAT", + "isBase": "false" + }, + { + "file": "FEAdd_On_Module_vProbeTemplate.yaml", + "type": "HEAT", + "isBase": "false" + }, + { + "file": "qrouterdependencies.json", + "type": "OTHER" + }, + { + "file": "vlbagentdependencies_with_vLB.json", + "type": "OTHER" + }, + { + "file": "wait_for_resources.py", + "type": "OTHER" + }, + { + "file": "vprobedependencies.json", + "type": "OTHER" + }, + { + "file": "FEAdd_On_Module_vProbeCloudConfig", + "type": "OTHER" + }, + { + "file": "call_home.py", + "type": "OTHER" + }, + { + "file": "check_availability.py", + "type": "OTHER" + }, + { + "file": "vlbdependencies.json", + "type": "OTHER" + }, + { + "file": "FEAdd_On_Module_QRouterCloudConfig", + "type": "OTHER" + }, + { + "file": "vlbagentdependencies_without_vLB.json", + "type": "OTHER" + }, + { + "file": "FEAdd_On_Module_vLBAgentCloudConfig", + "type": "OTHER" + }, + { + "file": "register_status.py", + "type": "OTHER" + }, + { + "file": "FEAdd_On_Module_vLBCloudConfig", + "type": "OTHER" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/call_home.py b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/call_home.py new file mode 100644 index 0000000000..54f2a69c09 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/call_home.py @@ -0,0 +1,97 @@ +import argparse +import json +import re +import requests +from socket import getfqdn +from sys import platform +from time import sleep + + +PARSER = argparse.ArgumentParser() +PARSER.add_argument("manager_ip", help="The IPv4 Address where one can read the MaveriQConductor.") +PARSER.add_argument("--mockupfile", type=str, help="The path of the json mockupfile to use.") +ARGS = PARSER.parse_args() + +URL = "http://{0}:8084/MaveriQConductor/machine/create".format(ARGS.manager_ip) +URL_AVAIL = "http://{0}:8084/MaveriQConductor/isReady".format(ARGS.manager_ip) +HEADERS = { + 'Accept': 'text/plain', + 'Content-type': 'application/json', + 'Connection': 'close' +} + +NETWORK_MAP = { + "$$OAM_NET_IP$$": "oam_private_network_ip", + "$$BACKEND_NET_IP$$": "backend_interconnect_network_ip", + "$$PACKET_MIRROR_NET_IP$$": "packet_mirror_network_ip", + "$$CDR_NET_IP$$": "cdr_network_ip", + "$$VERTICA_NET_IP$$": "vertica_private_network_ip", + "$$PACKET_INTERNAL_NET_IP$$": "packet_internal_network_ip", + "$$OAM_PROTECTED_NET_IP$$": "oam_protected_network_ip" +} + + +def map_ips_to_networks(p_meta_data): + network_to_ip = {} + for network_name in NETWORK_MAP.keys(): + if NETWORK_MAP[network_name] in p_meta_data: + network_to_ip[network_name] = str(p_meta_data[NETWORK_MAP[network_name]]) + return network_to_ip + + +def check_availability(): + is_connected = False + while is_connected is False: + try: + if requests.get(URL_AVAIL, headers={'Connection': 'close'}).status_code is 200: + is_connected = True + sleep(2) + except requests.exceptions.ConnectionError: + sleep(2) + + +def post_request(p_json_data, p_headers): + req = requests.post(url=URL, data=p_json_data, headers=p_headers) + return req.status_code + + +def multiple_replace(regex_dictionary, text): + regex = re.compile("(%s)" % "|".join(map(re.escape, regex_dictionary.keys()))) + return regex.sub( + lambda x: regex_dictionary[x.string[x.start():x.end()]], text + ) + + +def main(): + # Depending on platform, load the dependencies and meta.js files. + if ARGS.mockupfile: + with open(ARGS.mockupfile, 'r') as mockup_file: + mockup_file_data = mockup_file.read() + return post_request(mockup_file_data, HEADERS) + else: + if platform.startswith('linux'): + with open(r'/root/dependencies.json', 'r') as json_file: + json_data = json_file.read() + with open(r'/meta.js', 'r') as json_file: + meta_data = json.load(json_file) + + elif platform == 'cygwin' or platform == 'win32': + with open(r'c:\\dependencies.json', 'r') as json_file: + json_data = json_file.read() + with open(r'c:\\meta.js', 'r') as json_file: + meta_data = json.load(json_file) + else: + json_data = {} + meta_data = {} + raise Exception('Unsupported platform') + # Build dictionary mapping each IP to network. + regex_dict = map_ips_to_networks(meta_data) + regex_dict['$$HOSTNAME$$'] = getfqdn() + + # Perform any replacement needed. + json_data = multiple_replace(regex_dict, json_data) + print json_data + check_availability() + return post_request(p_json_data=json_data, p_headers=HEADERS) + +print main() diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/check_availability.py b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/check_availability.py new file mode 100644 index 0000000000..e93b372f15 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/check_availability.py @@ -0,0 +1,34 @@ +#!/usr/local/bin/python2.7 +import argparse +import requests +import sys +from time import sleep + +conductor_url = "http://{0}:8084/MaveriQConductor/isReady" +check_api = "http://{0}:8084/MaveriQManager/api/Inventory/isReady" +check_user = "omniq" +check_password = "radcom" + + +PARSER = argparse.ArgumentParser() +PARSER.add_argument("ScribeIP", type=str, + help="The Stage the application is currently in") +ARGS = PARSER.parse_args() + +print "Begining check availability check!" +isConnected = False +while isConnected is False: + try: + sys.stdout.write('.') + sleep(2) + if requests.get(conductor_url.format(ARGS.ScribeIP), + headers={'Connection': 'close'}).status_code is 200 and requests.get( + check_api.format(ARGS.ScribeIP, + headers={'Connection': 'close'}), + auth=requests.auth.HTTPBasicAuth(check_user, + check_password)).status_code is 200: + isConnected = True + except requests.exceptions.ConnectionError as e: + sleep(2) + +print 'Conductor and Scribe are ready!' diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/qrouterdependencies.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/qrouterdependencies.json new file mode 100644 index 0000000000..0a570b612b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/qrouterdependencies.json @@ -0,0 +1,35 @@ +{ + "name": "$$HOSTNAME$$", + "type": "qrouter", + "cluster": "QROUTER_CLUSTER_NAME", + "node_count": "QROUTER_NODE_COUNT", + "attributes": [ + { + "name": "ip-eth0", + "value": "$$OAM_NET_IP$$" + }, + { + "name": "rprb_26071_oam_direct_net_1", + "value": "$$OAM_NET_IP$$" + }, + { + "name": "rprb_26071_cdr_direct_net_1", + "value": "$$CDR_NET_IP$$" + } + ], + "dependencies": [ + { + "resource_name": "ProcessingCluster", + "resource_type": "cluster", + "attribute": "rprb_26071_cdr_direct_net_1", + "role": "processing_ip", + "format": "all" + }, + { + "resource_name": "MANAGER_INSTANCE_NAME", + "resource_type": "machine", + "attribute": "rprb_26071_oam_direct_net_1", + "role": "manager_oam_direct_ip" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/register_status.py b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/register_status.py new file mode 100644 index 0000000000..98adafaf2f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/register_status.py @@ -0,0 +1,126 @@ +#!/usr/local/bin/python2.7 +""" +This script is a combination of the AddComponentScript and the OnBoardingStatus +scripts. Depending on the arguments given, it will either post an +"addMachineCommand" or an "logOnBoardingInfo" request. +""" +import argparse +import json +import netifaces +import requests +from socket import getfqdn +import sys +from time import time + + +parser = argparse.ArgumentParser() +parser.add_argument("scribe_ip", type=str, + help="The IP where the Scribe can be reached.") +parser.add_argument("--component-type", type=str, + help="The component type.", required=False) +parser.add_argument("--component-version", type=str, + help="The component version.", required=False) +parser.add_argument("--stage", type=str, required=False) +parser.add_argument("--status", required=False, + choices=["WARNING", "INFO", "ERROR", "OK", "FAILURE"]) +parser.add_argument("--description", type=str, required=False) +args = parser.parse_args() + +add_machine_ip = "http://{0}:8084/MaveriQManager/api/Inventory/addComponent".format(args.scribe_ip) +log_onboarding_info_ip = "http://{0}:8084/MaveriQManager/api/Inventory/logOnBoardingInfo".format(args.scribe_ip) +user = 'omniq' +password = 'radcom' + +REGION = "" +TENANT = "" +CLUSTER_NAME = "" +VERSION_NUMBER = "" +PROBE_ID = "" +OAM_DIRECT_IP = "" +MACHINE_TYPE = args.component_type +MACHINE_NAME = getfqdn() +HEALTH_STATUS = {} +ADD_COMPONENT_BODY = {} + + +def read_metadata(): + """Read the instance metadata""" + global REGION + global TENANT + global CLUSTER_NAME + global VERSION_NUMBER + global PROBE_ID + global OAM_DIRECT_IP + with open('/meta.js', 'r') as json_file: + json_data = json.loads(json_file.read()) + TENANT = json_data["tenant"] + REGION = json_data["region"] + CLUSTER_NAME = json_data["cluster_name"] + VERSION_NUMBER = json_data["version_number"] + OAM_DIRECT_IP = json_data["oam_private_network_ip"] + if MACHINE_TYPE == 'vProbe': + PROBE_ID = json_data["probe_id"] + + +def build_health_json(): + """Builds the actual health status""" + HEALTH_STATUS["Region"] = REGION + HEALTH_STATUS["Tenant"] = TENANT + HEALTH_STATUS["MachineType"] = args.component_type + HEALTH_STATUS["MachineName"] = getfqdn() + HEALTH_STATUS["MachineIP"] = OAM_DIRECT_IP + HEALTH_STATUS["Time"] = long(time()) + HEALTH_STATUS["Description"] = args.description + HEALTH_STATUS["Status"] = args.status + HEALTH_STATUS["Stage"] = args.stage + return HEALTH_STATUS + + +def build_add_json(): + """Builds the actual health status""" + ADD_COMPONENT_BODY["region"] = REGION + ADD_COMPONENT_BODY["tenant"] = TENANT + ADD_COMPONENT_BODY["componentType"] = args.component_type + ADD_COMPONENT_BODY["clusterName"] = CLUSTER_NAME + ADD_COMPONENT_BODY["componentVersionNumber"] = VERSION_NUMBER + ADD_COMPONENT_BODY["machineName"] = MACHINE_NAME + ADD_COMPONENT_BODY["machineNetworkInterfaces"] = [] + ADD_COMPONENT_BODY["OAM_IP"] = OAM_DIRECT_IP + + for interface in netifaces.interfaces(): + ADD_COMPONENT_BODY["machineNetworkInterfaces"].append({"name": interface, "value": netifaces.ifaddresses(interface)[2][0]['addr']}) + + if PROBE_ID is not "": + ADD_COMPONENT_BODY["machineID"] = REGION + '_' + TENANT + '_' +\ + CLUSTER_NAME + '_' + MACHINE_NAME + '_' + PROBE_ID + else: + ADD_COMPONENT_BODY["machineID"] = REGION + '_' + TENANT + '_' +\ + CLUSTER_NAME + '_' + MACHINE_NAME + return ADD_COMPONENT_BODY + + +def send_postage(p_url, p_url_user, p_url_password, p_json_data): + json_header = {'Content-type': 'application/json'} + request = requests.post(p_url, json.dumps(p_json_data), json_header, auth=requests.auth.HTTPBasicAuth(p_url_user, p_url_password)) + print request.status_code + if (request.status_code != 200): + sys.exit(1) + return request.status_code + + +def post_health(): + read_metadata() + return send_postage(log_onboarding_info_ip, user, password, + build_health_json()) + + +def post_add_machine(): + read_metadata() + return send_postage(add_machine_ip, user, password, build_add_json()) + +if args.stage is None and args.status is None and args.description is None: + print "adding machine" + print post_add_machine() +else: + print "logging health" + print post_health() diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/vlbagentdependencies_with_vLB.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/vlbagentdependencies_with_vLB.json new file mode 100644 index 0000000000..0304a18f0e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/vlbagentdependencies_with_vLB.json @@ -0,0 +1,46 @@ +{ + "name": "$$HOSTNAME$$", + "type": "vLBAgent", + "cluster": "VLBAGENT_CLUSTER_NAME", + "node_count": "VLBAGENT_NODE_COUNT", + "attributes": [ + { + "name": "ip-eth0", + "value": "$$OAM_NET_IP$$" + }, + { + "name": "rprb_26071_oam_direct_net_1", + "value": "$$OAM_NET_IP$$" + }, + { + "name": "rprb_26071_mme_int_pktmirror_net_1", + "value": "$$PACKET_MIRROR_NET_IP$$" + }, + { + "name": "rprb_26071_mme_int_pktinternal_net_1", + "value": "$$PACKET_INTERNAL_NET_IP$$" + } + ], + "dependencies": [ + { + "resource_name": "VPROBE_CLUSTER_NAME", + "resource_type": "cluster", + "attribute": "eth0-eth2-and-ProbeInstance", + "role": "vProbe_cluster", + "format": "all" + }, + { + "resource_name": "VLB_CLUSTER_NAME", + "resource_type": "cluster", + "attribute": "eth1-eth2-and-vLBInstance", + "role": "vLB_cluster", + "format": "all" + }, + { + "resource_name": "MANAGER_INSTANCE_NAME", + "resource_type": "machine", + "attribute": "rprb_26071_oam_direct_net_1", + "role": "manager_oam_direct_ip" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/vlbagentdependencies_without_vLB.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/vlbagentdependencies_without_vLB.json new file mode 100644 index 0000000000..1af6af96c5 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/vlbagentdependencies_without_vLB.json @@ -0,0 +1,39 @@ +{ + "name": "$$HOSTNAME$$", + "type": "vLBAgent", + "cluster": "VLBAGENT_CLUSTER_NAME", + "node_count": "VLBAGENT_NODE_COUNT", + "attributes": [ + { + "name": "ip-eth0", + "value": "$$OAM_NET_IP$$" + }, + { + "name": "rprb_26071_oam_direct_net_1", + "value": "$$OAM_NET_IP$$" + }, + { + "name": "rprb_26071_mme_int_pktmirror_net_1", + "value": "$$PACKET_MIRROR_NET_IP$$" + }, + { + "name": "rprb_26071_mme_int_pktinternal_net_1", + "value": "$$PACKET_INTERNAL_NET_IP$$" + } + ], + "dependencies": [ + { + "resource_name": "VPROBE_CLUSTER_NAME", + "resource_type": "cluster", + "attribute": "eth0-eth2-and-ProbeInstance", + "role": "vProbe_cluster", + "format": "all" + }, + { + "resource_name": "MANAGER_INSTANCE_NAME", + "resource_type": "machine", + "attribute": "rprb_26071_oam_direct_net_1", + "role": "manager_oam_direct_ip" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/vlbdependencies.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/vlbdependencies.json new file mode 100644 index 0000000000..b0a0da7b52 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/vlbdependencies.json @@ -0,0 +1,43 @@ +{ + "name": "$$HOSTNAME$$", + "type": "vLB", + "cluster": "VLB_CLUSTER_NAME", + "node_count": "VLB_NODE_COUNT", + "attributes": [ + { + "name": "ip-eth0", + "value": "$$OAM_NET_IP$$" + }, + { + "name": "rprb_26071_oam_direct_net_1", + "value": "$$OAM_NET_IP$$" + }, + { + "name": "rprb_26071_mme_int_pktmirror_net_1", + "value": "$$PACKET_MIRROR_NET_IP$$" + }, + { + "name": "rprb_26071_mme_int_pktinternal_net_1", + "value": "$$PACKET_INTERNAL_NET_IP$$" + }, + { + "name": "eth1-eth2-and-vLBInstance", + "value": "$$OAM_NET_IP$$@$$PACKET_INTERNAL_NET_IP$$@VLB_INSTANCE" + } + ], + "dependencies": [ + { + "resource_name": "VPROBE_CLUSTER_NAME", + "resource_type": "cluster", + "attribute": "eth0-eth2-and-ProbeInstance", + "role": "vProbe_cluster", + "format": "all" + }, + { + "resource_name": "MANAGER_INSTANCE_NAME", + "resource_type": "machine", + "attribute": "rprb_26071_oam_direct_net_1", + "role": "manager_oam_direct_ip" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/vprobedependencies.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/vprobedependencies.json new file mode 100644 index 0000000000..78768cf545 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/vprobedependencies.json @@ -0,0 +1,49 @@ +{ + "name": "$$HOSTNAME$$", + "type": "vprobe", + "cluster": "VPROBE_CLUSTER_NAME", + "node_count": "VPROBE_NODE_COUNT", + "attributes": [ + { + "name": "ip-eth0", + "value": "$$OAM_NET_IP$$" + }, + { + "name": "rprb_26071_oam_direct_net_1", + "value": "$$OAM_NET_IP$$" + }, + { + "name": "rprb_26071_cdr_direct_net_1", + "value": "$$CDR_NET_IP$$" + }, + { + "name": "rprb_26071_mme_int_pktinternal_net_1", + "value": "$$PACKET_INTERNAL_NET_IP$$" + }, + { + "name": "eth0-eth2-and-ProbeInstance", + "value": "$$OAM_NET_IP$$@$$PACKET_INTERNAL_NET_IP$$@PROBE_INSTANCE" + } + ], + "dependencies": [ + { + "resource_name": "QROUTER_CLUSTER_NAME", + "resource_type": "cluster", + "attribute": "rprb_26071_cdr_direct_net_1", + "role": "qrouter_cluster", + "format": "all" + }, + { + "resource_name": "QTRACE_HOST_NAME", + "resource_type": "machine", + "attribute": "rprb_26071_oam_direct_net_1", + "role": "qtrace_public_ip" + }, + { + "resource_name": "MANAGER_INSTANCE_NAME", + "resource_type": "machine", + "attribute": "rprb_26071_oam_direct_net_1", + "role": "manager_oam_direct_ip" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/wait_for_resources.py b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/wait_for_resources.py new file mode 100644 index 0000000000..5d960d659e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectiongetresource/inputfiles/wait_for_resources.py @@ -0,0 +1,84 @@ +import argparse +import json +import netifaces +import os +import sys +import time + +TIME_INTERVAL = 10 + + +def parse_json_file(json_path): + with open(json_path, 'r') as json_file: + data = json.load(json_file) + return data + + +def check_network_interfaces(): + for interface in netifaces.interfaces(): + if(sys.platform != 'win32' or netifaces.ifaddresses(interface)[-1000][0]['addr'] != '00:00:00:00:00:00:00:e0'): + while 2 not in netifaces.ifaddresses(interface).keys() and 23 not in netifaces.ifaddresses(interface).keys(): + print "Still waiting for interface:", interface + time.sleep(TIME_INTERVAL) + + +def check_connectivity(): + if sys.platform.startswith('linux'): + ping_str = "ping -c 1 " + elif sys.platform == 'cygwin' or sys.platform == 'win32': + ping_str = "ping -n 1 " + + while os.system(ping_str + component_ip) != 0: + print "No connectivity to", component_ip, "waiting", TIME_INTERVAL, "seconds" + time.sleep(TIME_INTERVAL) + + +def check_cinder_mounts(): + if sys.platform.startswith('linux'): + meta_data = parse_json_file('/meta.js') + elif sys.platform == 'cygwin' or sys.platform == 'win32': + meta_data = parse_json_file('c:\\meta.js') + + cinder_count = 0 + + for info in meta_data: + if info.startswith('mount'): + cinder_count += 1 + + if sys.platform.startswith('linux'): + cinder_attached = os.popen('ls /dev/disk/by-id/virtio* | wc -l').read() + elif sys.platform == 'cygwin' or sys.platform == 'win32': + cinder_attached = os.popen("wmic diskdrive get DeviceID | find /i \"PHYSICALDRIVE\" | find /V \"0\" /C").read() + + while (int(cinder_attached) < cinder_count) and (cinder_count != 0): + print "Missing a cinder mount, waiting", TIME_INTERVAL, "seconds" + time.sleep(TIME_INTERVAL) + + if sys.platform.startswith('linux'): + cinder_attached = os.popen('ls /dev/disk/by-id/virtio* | wc -l').read() + + elif sys.platform == 'cygwin' or sys.platform == 'win32': + cinder_attached = os.popen( + "wmic diskdrive get DeviceID | find /i \"PHYSICALDRIVE\" | find /V \"0\" /C").read() + + if int(cinder_attached) == cinder_count: + print "All cinder are attached and ready to be formatted and mounted" + + +def main(): + check_network_interfaces() + check_cinder_mounts() + + if component_ip is not None: + check_connectivity() + + print "All resources are ready" + + +if __name__ == "__main__": + parser = argparse.ArgumentParser(description='This script is waiting for network and volume resources to come up') + parser.add_argument('-m', '--component_ip', metavar='component_ip', type=str, help='The component ip', required=False) + args = parser.parse_args() + component_ip = args.component_ip + globals().update(args.__dict__) + main() diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectionmulti/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectionmulti/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..72905b3b21 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectionmulti/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,340 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + security_group_id1: + hidden: false + immutable: false + type: string + description: UID of OAM network + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + security_group_id: + hidden: false + immutable: false + type: string + description: UID of OAM network + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + cmaui_oam_ips: + hidden: false + immutable: false + type: string + description: cmaui_oam_ips + shared_network_id: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + jsa_net_name: + hidden: false + immutable: false + type: string + description: network name of jsa log network + security_group_id3: + hidden: false + immutable: false + type: string + description: UID of OAM network + security_group_id2: + hidden: false + immutable: false + type: string + description: UID of OAM network + node_templates: + cmaui_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_id + - get_input: security_group_id3 + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: shared_network_id + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + name: + get_input: + - cmaui_names + - 0 + jsa_security_group1: + type: org.openecomp.resource.vfc.rules.nodes.heat.network.neutron.SecurityRules + properties: + name: + get_input: security_group_name + description: ems security group + rules: + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + - protocol: tcp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv6 + remote_ip_prefix: ::/0 + direction: egress + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + - protocol: tcp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv6 + remote_ip_prefix: ::/0 + direction: ingress + requirements: + - port: + capability: tosca.capabilities.Attachment + node: cmaui_port_0 + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: tosca.capabilities.Attachment + node: cmaui_port_1 + relationship: org.openecomp.relationships.AttachesTo + jsa_security_group2: + type: org.openecomp.resource.vfc.rules.nodes.heat.network.neutron.SecurityRules + properties: + name: + get_input: security_group_name + description: ems security group + rules: + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + - protocol: tcp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv6 + remote_ip_prefix: ::/0 + direction: egress + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + - protocol: tcp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv6 + remote_ip_prefix: ::/0 + direction: ingress + requirements: + - port: + capability: tosca.capabilities.Attachment + node: cmaui_port_1 + relationship: org.openecomp.relationships.AttachesTo + cmaui_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_id1 + - get_input: security_group_id2 + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: shared_network_id + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + cmaui_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_id1 + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: shared_network_id + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + groups: + addOn: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/addOn.yml + description: cmaui server template for vMMSC + members: + - cmaui_port_2 + - server_cmaui + - cmaui_port_1 + - cmaui_port_0 + main: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/main.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - jsa_security_group1 + - jsa_security_group2 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectionmulti/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectionmulti/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..1f762d0ccc --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectionmulti/inputfiles/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "main.yml", + "type": "HEAT", + "isBase": "true" + }, + { + "file": "addOn.yml", + "type": "HEAT", + "isBase": "false" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectionmulti/inputfiles/addOn.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectionmulti/inputfiles/addOn.yml new file mode 100644 index 0000000000..24dc9d7678 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectionmulti/inputfiles/addOn.yml @@ -0,0 +1,72 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + security_group_id1: + type: string + description: UID of OAM network + security_group_id2: + type: string + description: UID of OAM network + security_group_id: + type: string + description: UID of OAM network + security_group_id3: + type: string + description: UID of OAM network + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + cmaui_flavor: + type: string + description: Flavor for CMAUI server + shared_network_id: + type: string + description: Flavor for CMAUI server + cmaui_oam_ips: + type: string + description: cmaui_oam_ips +resources: + + cmaui_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: shared_network_id } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_id1}] + replacement_policy: AUTO + + cmaui_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: shared_network_id } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_id1},{get_param: security_group_id2}] + replacement_policy: AUTO + + cmaui_port_2: + type: OS::Neutron::Port + properties: + network: { get_param: shared_network_id } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_id},{get_param: security_group_id3}] + replacement_policy: AUTO + + server_cmaui: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_0 } + - port: { get_resource: cmaui_port_1 } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectionmulti/inputfiles/main.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectionmulti/inputfiles/main.yml new file mode 100644 index 0000000000..8a6e72c1ba --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportconnectionmulti/inputfiles/main.yml @@ -0,0 +1,58 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + security_group_name: + type: string + label: security group name + description: the name of security group + jsa_net_name: + type: string + description: network name of jsa log network + +resources: + jsa_security_group1: + type: OS::Neutron::SecurityGroup + properties: + description: ems security group + name: {get_param: security_group_name} + rules: [{"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": "::/0"}, + {"direction": egress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": "::/0"}, + {"direction": egress, "ethertype": IPv6, "protocol": icmp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv6, "protocol": icmp, "remote_ip_prefix": "::/0"} + ] + + jsa_security_group2: + type: OS::Neutron::SecurityGroup + properties: + description: ems security group + name: {get_param: security_group_name} + rules: [{"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": "::/0"}, + {"direction": egress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": "::/0"}, + {"direction": egress, "ethertype": IPv6, "protocol": icmp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv6, "protocol": icmp, "remote_ip_prefix": "::/0"} + ] + +outputs: + security_group_id1: + value: {get_resource: jsa_security_group1} + security_group_id2: + value: {get_resource: jsa_security_group2} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportnestedconnection/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportnestedconnection/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..21e8ec8cdb --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportnestedconnection/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,222 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + jsa_net_name: + hidden: false + immutable: false + type: string + description: network name of jsa log network + node_templates: + jsa_security_group1: + type: org.openecomp.resource.vfc.rules.nodes.heat.network.neutron.SecurityRules + properties: + name: + get_input: security_group_name + description: ems security group + rules: + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + - protocol: tcp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv6 + remote_ip_prefix: ::/0 + direction: egress + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + - protocol: tcp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv6 + remote_ip_prefix: ::/0 + direction: ingress + requirements: + - port: + capability: attachment_cmaui_port_0 + node: test_nested + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: attachment_cmaui_port_1 + node: test_nested + relationship: org.openecomp.relationships.AttachesTo + jsa_security_group2: + type: org.openecomp.resource.vfc.rules.nodes.heat.network.neutron.SecurityRules + properties: + name: + get_input: security_group_name + description: ems security group + rules: + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + - protocol: tcp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv6 + remote_ip_prefix: ::/0 + direction: egress + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + - protocol: tcp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv6 + remote_ip_prefix: ::/0 + direction: ingress + requirements: + - port: + capability: attachment_cmaui_port_0 + node: test_nested + relationship: org.openecomp.relationships.AttachesTo + test_nested: + type: org.openecomp.resource.abstract.nodes.heat.nested + directives: + - substitutable + properties: + p1: jsa_security_group1 + service_template_filter: + substitute_service_template: nestedServiceTemplate.yaml + p2: jsa_security_group2 + groups: + main: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/main.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - jsa_security_group1 + - jsa_security_group2 + - test_nested \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportnestedconnection/expectedoutputfiles/nestedServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportnestedconnection/expectedoutputfiles/nestedServiceTemplate.yaml new file mode 100644 index 0000000000..c41ad87568 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportnestedconnection/expectedoutputfiles/nestedServiceTemplate.yaml @@ -0,0 +1,175 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p1: + hidden: false + immutable: false + type: string + description: UID of OAM network + p2: + hidden: false + immutable: false + type: string + description: UID of OAM network + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + cmaui_oam_ips: + hidden: false + immutable: false + type: string + description: cmaui_oam_ips + net: + hidden: false + immutable: false + type: string + description: UID of OAM network + node_templates: + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + name: + get_input: + - cmaui_names + - 0 + cmaui_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: p1 + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: net + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + cmaui_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: p1 + - get_input: p2 + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: net + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + groups: + nested: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested.yml + description: cmaui server template for vMMSC + members: + - server_cmaui + - cmaui_port_1 + - cmaui_port_0 + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested + capabilities: + host_server_cmaui: + - server_cmaui + - host + os_server_cmaui: + - server_cmaui + - os + endpoint_server_cmaui: + - server_cmaui + - endpoint + binding_server_cmaui: + - server_cmaui + - binding + scalable_server_cmaui: + - server_cmaui + - scalable + attachment_cmaui_port_0: + - cmaui_port_0 + - attachment + attachment_cmaui_port_1: + - cmaui_port_1 + - attachment + requirements: + local_storage_server_cmaui: + - server_cmaui + - local_storage + link_cmaui_port_0: + - cmaui_port_0 + - link + link_cmaui_port_1: + - cmaui_port_1 + - link \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportnestedconnection/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportnestedconnection/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..aca75b5055 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportnestedconnection/inputfiles/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "main.yml", + "type": "HEAT", + "isBase": "true" + }, + { + "file": "nested.yml", + "type": "HEAT", + "isBase": "false" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportnestedconnection/inputfiles/main.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportnestedconnection/inputfiles/main.yml new file mode 100644 index 0000000000..bcd542b66d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportnestedconnection/inputfiles/main.yml @@ -0,0 +1,58 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + jsa_net_name: + type: string + description: network name of jsa log network + security_group_name: + type: string + label: security group name + description: the name of security group + +resources: + jsa_security_group1: + type: OS::Neutron::SecurityGroup + properties: + description: ems security group + name: {get_param: security_group_name} + rules: [{"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": "::/0"}, + {"direction": egress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": "::/0"}, + {"direction": egress, "ethertype": IPv6, "protocol": icmp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv6, "protocol": icmp, "remote_ip_prefix": "::/0"} + ] + + jsa_security_group2: + type: OS::Neutron::SecurityGroup + properties: + description: ems security group + name: {get_param: security_group_name} + rules: [{"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": "::/0"}, + {"direction": egress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": "::/0"}, + {"direction": egress, "ethertype": IPv6, "protocol": icmp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv6, "protocol": icmp, "remote_ip_prefix": "::/0"} + ] + + test_nested: + type: nested.yml + properties: + p1: { get_resource: jsa_security_group1} + p2: { get_resource: jsa_security_group2} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportnestedconnection/inputfiles/nested.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportnestedconnection/inputfiles/nested.yml new file mode 100644 index 0000000000..7708565ef1 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityrulestoportnestedconnection/inputfiles/nested.yml @@ -0,0 +1,58 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + p1: + type: string + description: UID of OAM network + p2: + type: string + description: UID of OAM network + net: + type: string + description: UID of OAM network + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_oam_ips: + type: string + description: cmaui_oam_ips +resources: + + cmaui_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: net } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: p1},{get_param: p2}] + replacement_policy: AUTO + + cmaui_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: net } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: p1}] + replacement_policy: AUTO + + server_cmaui: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_0 } + - port: { get_resource: cmaui_port_1 } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityruletosharedportlinking/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityruletosharedportlinking/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..dc4eb45cda --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityruletosharedportlinking/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,241 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + shared_security_group_id2: + hidden: false + immutable: false + type: string + description: network name of jsa log network + jsa_net_name: + hidden: false + immutable: false + type: string + description: network name of jsa log network + shared_security_group_id1: + hidden: false + immutable: false + type: string + description: network name of jsa log network + node_templates: + jsa_security_group1: + type: org.openecomp.resource.vfc.rules.nodes.heat.network.neutron.SecurityRules + properties: + name: + get_input: security_group_name + description: ems security group + rules: + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + - protocol: tcp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv6 + remote_ip_prefix: ::/0 + direction: egress + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + - protocol: tcp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv6 + remote_ip_prefix: ::/0 + direction: ingress + requirements: + - port: + capability: attachment_cmaui_port_2 + node: test_nested + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: attachment_cmaui_port_1 + node: test_nested + relationship: org.openecomp.relationships.AttachesTo + jsa_security_group2: + type: org.openecomp.resource.vfc.rules.nodes.heat.network.neutron.SecurityRules + properties: + name: + get_input: security_group_name + description: ems security group + rules: + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + - protocol: tcp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv6 + remote_ip_prefix: ::/0 + direction: egress + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + - protocol: tcp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv6 + remote_ip_prefix: ::/0 + direction: ingress + requirements: + - port: + capability: attachment_cmaui_port_1 + node: test_nested + relationship: org.openecomp.relationships.AttachesTo + test_nested: + type: org.openecomp.resource.abstract.nodes.heat.nested + directives: + - substitutable + properties: + service_template_filter: + substitute_service_template: nestedServiceTemplate.yaml + p2: + get_input: shared_security_group_id2 + shared_security_group_id1: + get_input: shared_security_group_id1 + groups: + addOn: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/addOn.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - test_nested + main: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/main.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - jsa_security_group1 + - jsa_security_group2 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityruletosharedportlinking/expectedoutputfiles/nestedServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityruletosharedportlinking/expectedoutputfiles/nestedServiceTemplate.yaml new file mode 100644 index 0000000000..491e691e80 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityruletosharedportlinking/expectedoutputfiles/nestedServiceTemplate.yaml @@ -0,0 +1,175 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p2: + hidden: false + immutable: false + type: string + description: UID of OAM network + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + cmaui_oam_ips: + hidden: false + immutable: false + type: string + description: cmaui_port_1 + net: + hidden: false + immutable: false + type: string + description: UID of OAM network + shared_security_group_id1: + hidden: false + immutable: false + type: string + description: UID of OAM network + node_templates: + cmaui_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: shared_security_group_id1 + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: net + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + name: + get_input: + - cmaui_names + - 0 + cmaui_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: shared_security_group_id1 + - get_input: p2 + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: net + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + groups: + nested: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested.yml + description: cmaui server template for vMMSC + members: + - cmaui_port_2 + - server_cmaui + - cmaui_port_1 + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested + capabilities: + host_server_cmaui: + - server_cmaui + - host + os_server_cmaui: + - server_cmaui + - os + endpoint_server_cmaui: + - server_cmaui + - endpoint + binding_server_cmaui: + - server_cmaui + - binding + attachment_cmaui_port_2: + - cmaui_port_2 + - attachment + scalable_server_cmaui: + - server_cmaui + - scalable + attachment_cmaui_port_1: + - cmaui_port_1 + - attachment + requirements: + local_storage_server_cmaui: + - server_cmaui + - local_storage + link_cmaui_port_2: + - cmaui_port_2 + - link + link_cmaui_port_1: + - cmaui_port_1 + - link \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityruletosharedportlinking/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityruletosharedportlinking/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..8ba5fc48f4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityruletosharedportlinking/inputfiles/MANIFEST.json @@ -0,0 +1,22 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "main.yml", + "type": "HEAT", + "isBase": "true" + }, + { + "file": "nested.yml", + "type": "HEAT", + "isBase": "false" + }, + { + "file": "addOn.yml", + "type": "HEAT", + "isBase": "false" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityruletosharedportlinking/inputfiles/addOn.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityruletosharedportlinking/inputfiles/addOn.yml new file mode 100644 index 0000000000..0e7619a478 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityruletosharedportlinking/inputfiles/addOn.yml @@ -0,0 +1,26 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + shared_security_group_id1: + type: string + description: network name of jsa log network + shared_security_group_id2: + type: string + description: network name of jsa log network + jsa_net_name: + type: string + description: network name of jsa log network + security_group_name: + type: string + label: security group name + description: the name of security group + +resources: + test_nested: + type: nested.yml + properties: + shared_security_group_id1: { get_param: shared_security_group_id1} + p2: { get_param: shared_security_group_id2} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityruletosharedportlinking/inputfiles/main.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityruletosharedportlinking/inputfiles/main.yml new file mode 100644 index 0000000000..9167ffbafd --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityruletosharedportlinking/inputfiles/main.yml @@ -0,0 +1,58 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + jsa_net_name: + type: string + description: network name of jsa log network + security_group_name: + type: string + label: security group name + description: the name of security group + +resources: + jsa_security_group1: + type: OS::Neutron::SecurityGroup + properties: + description: ems security group + name: {get_param: security_group_name} + rules: [{"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": "::/0"}, + {"direction": egress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": "::/0"}, + {"direction": egress, "ethertype": IPv6, "protocol": icmp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv6, "protocol": icmp, "remote_ip_prefix": "::/0"} + ] + + jsa_security_group2: + type: OS::Neutron::SecurityGroup + properties: + description: ems security group + name: {get_param: security_group_name} + rules: [{"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": "::/0"}, + {"direction": egress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": "::/0"}, + {"direction": egress, "ethertype": IPv6, "protocol": icmp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv6, "protocol": icmp, "remote_ip_prefix": "::/0"} + ] +outputs: + shared_security_group_id1: + value: {get_resource: jsa_security_group1} + + shared_security_group_id2: + value: {get_resource: jsa_security_group2} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityruletosharedportlinking/inputfiles/nested.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityruletosharedportlinking/inputfiles/nested.yml new file mode 100644 index 0000000000..a5a74e9d2e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnection/securityruletosharedportlinking/inputfiles/nested.yml @@ -0,0 +1,59 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + shared_security_group_id1: + type: string + description: UID of OAM network + p2: + type: string + description: UID of OAM network + net: + type: string + description: UID of OAM network + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_oam_ips: + type: string + description: cmaui_port_1 + +resources: + + cmaui_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: net } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: shared_security_group_id1}, {get_param: p2}] + replacement_policy: AUTO + + cmaui_port_2: + type: OS::Neutron::Port + properties: + network: { get_param: net } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: shared_security_group_id1}] + replacement_policy: AUTO + + server_cmaui: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_1 } + - port: { get_resource: cmaui_port_2 } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnectionmulti/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnectionmulti/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..1696e6ea39 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityrulestoportconnectionmulti/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,332 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui_image: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + security_group_id1: + hidden: false + immutable: false + type: string + description: UID of OAM network + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + security_group_id: + hidden: false + immutable: false + type: string + description: UID of OAM network + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + cmaui_oam_ips: + hidden: false + immutable: false + type: string + description: cmaui_oam_ips + shared_network_id: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + jsa_net_name: + hidden: false + immutable: false + type: string + description: network name of jsa log network + security_group_id3: + hidden: false + immutable: false + type: string + description: UID of OAM network + security_group_id2: + hidden: false + immutable: false + type: string + description: UID of OAM network + node_templates: + cmaui_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_id + - get_input: security_group_id3 + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: shared_network_id + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui_image + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + name: + get_input: + - cmaui_names + - 0 + jsa_security_group1: + type: org.openecomp.resource.nodes.heat.network.neutron.SecurityRules + properties: + name: + get_input: security_group_name + description: ems security group + rules: + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + - protocol: tcp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv6 + remote_ip_prefix: ::/0 + direction: egress + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + - protocol: tcp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv6 + remote_ip_prefix: ::/0 + direction: ingress + requirements: + - port: + capability: tosca.capabilities.Attachment + node: cmaui_port_0 + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: tosca.capabilities.Attachment + node: cmaui_port_1 + relationship: org.openecomp.relationships.AttachesTo + jsa_security_group2: + type: org.openecomp.resource.nodes.heat.network.neutron.SecurityRules + properties: + name: + get_input: security_group_name + description: ems security group + rules: + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + - protocol: tcp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv6 + remote_ip_prefix: ::/0 + direction: egress + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + - protocol: tcp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv6 + remote_ip_prefix: ::/0 + direction: ingress + requirements: + - port: + capability: tosca.capabilities.Attachment + node: cmaui_port_1 + relationship: org.openecomp.relationships.AttachesTo + cmaui_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_id1 + - get_input: security_group_id2 + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: shared_network_id + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + cmaui_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_id1 + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: shared_network_id + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + groups: + addOn: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/addOn.yml + description: cmaui server template for vMMSC + members: + - cmaui_port_2 + - server_cmaui + - cmaui_port_1 + - cmaui_port_0 + main: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/main.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - jsa_security_group1 + - jsa_security_group2 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportlinking/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportlinking/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..5ed12af4ae --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportlinking/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,231 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml +topology_template: + inputs: + security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + shared_security_group_id2: + hidden: false + immutable: false + type: string + description: network name of jsa log network + jsa_net_name: + hidden: false + immutable: false + type: string + description: network name of jsa log network + shared_security_group_id1: + hidden: false + immutable: false + type: string + description: network name of jsa log network + node_templates: + jsa_security_group1: + type: org.openecomp.resource.nodes.heat.network.neutron.SecurityRules + properties: + name: + get_input: security_group_name + description: ems security group + rules: + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + - protocol: tcp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv6 + remote_ip_prefix: ::/0 + direction: egress + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + - protocol: tcp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv6 + remote_ip_prefix: ::/0 + direction: ingress + requirements: + - port: + capability: attachment_cmaui_port_2 + node: test_nested + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: attachment_cmaui_port_1 + node: test_nested + relationship: org.openecomp.relationships.AttachesTo + jsa_security_group2: + type: org.openecomp.resource.nodes.heat.network.neutron.SecurityRules + properties: + name: + get_input: security_group_name + description: ems security group + rules: + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + - protocol: tcp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv6 + remote_ip_prefix: ::/0 + direction: egress + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + - protocol: tcp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv6 + remote_ip_prefix: ::/0 + direction: ingress + requirements: + - port: + capability: attachment_cmaui_port_1 + node: test_nested + relationship: org.openecomp.relationships.AttachesTo + test_nested: + type: org.openecomp.resource.abstract.nodes.heat.nested + directives: + - substitutable + properties: + service_template_filter: + substitute_service_template: nestedServiceTemplate.yaml + p2: + get_input: shared_security_group_id2 + shared_security_group_id1: + get_input: shared_security_group_id1 + groups: + addOn: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/addOn.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - test_nested + main: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/main.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - jsa_security_group1 + - jsa_security_group2 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportlinking/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportlinking/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..8ba5fc48f4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportlinking/inputfiles/MANIFEST.json @@ -0,0 +1,22 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "main.yml", + "type": "HEAT", + "isBase": "true" + }, + { + "file": "nested.yml", + "type": "HEAT", + "isBase": "false" + }, + { + "file": "addOn.yml", + "type": "HEAT", + "isBase": "false" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportresourcegrouplinking/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportresourcegrouplinking/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..267fa61cd4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportresourcegrouplinking/expectedoutputfiles/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,119 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.nested: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + cmaui_names: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p1: + type: string + description: UID of OAM network + p2: + type: string + description: UID of OAM network + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + availability_zone_0: + type: string + description: availabilityzone name + cmaui_oam_ips: + type: string + net: + type: string + description: UID of OAM network + requirements: + - link_cmaui_port_2: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + - local_storage_server_cmaui: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_cmaui_port_1: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + host_server_cmaui: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + os_server_cmaui: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + endpoint_server_cmaui: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + binding_server_cmaui: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_2: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + scalable_server_cmaui: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_1: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportresourcegrouplinking/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportresourcegrouplinking/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..9466ebff85 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportresourcegrouplinking/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,243 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + shared_security_group_id2: + hidden: false + immutable: false + type: string + description: network name of jsa log network + jsa_net_name: + hidden: false + immutable: false + type: string + description: network name of jsa log network + shared_security_group_id1: + hidden: false + immutable: false + type: string + description: network name of jsa log network + node_templates: + mvs_modules: + type: org.openecomp.resource.abstract.nodes.heat.nested + directives: + - substitutable + properties: + p1: + get_input: shared_security_group_id1 + service_template_filter: + substitute_service_template: nestedServiceTemplate.yaml + count: 3 + mandatory: true + p2: + get_input: shared_security_group_id2 + jsa_security_group1: + type: org.openecomp.resource.vfc.rules.nodes.heat.network.neutron.SecurityRules + properties: + name: + get_input: security_group_name + description: ems security group + rules: + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + - protocol: tcp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv6 + remote_ip_prefix: ::/0 + direction: egress + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + - protocol: tcp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv6 + remote_ip_prefix: ::/0 + direction: ingress + requirements: + - port: + capability: attachment_cmaui_port_2 + node: mvs_modules + relationship: org.openecomp.relationships.AttachesTo + - port: + capability: attachment_cmaui_port_1 + node: mvs_modules + relationship: org.openecomp.relationships.AttachesTo + jsa_security_group2: + type: org.openecomp.resource.vfc.rules.nodes.heat.network.neutron.SecurityRules + properties: + name: + get_input: security_group_name + description: ems security group + rules: + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: egress + - protocol: tcp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: egress + port_range_min: 1 + - protocol: udp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: egress + port_range_min: 1 + - protocol: icmp + ethertype: IPv6 + remote_ip_prefix: ::/0 + direction: egress + - protocol: tcp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv4 + port_range_max: 65535 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + direction: ingress + - protocol: tcp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: ingress + port_range_min: 1 + - protocol: udp + ethertype: IPv6 + port_range_max: 65535 + remote_ip_prefix: ::/0 + direction: ingress + port_range_min: 1 + - protocol: icmp + ethertype: IPv6 + remote_ip_prefix: ::/0 + direction: ingress + requirements: + - port: + capability: attachment_cmaui_port_1 + node: mvs_modules + relationship: org.openecomp.relationships.AttachesTo + groups: + addOn: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/addOn.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - mvs_modules + main: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/main.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - jsa_security_group1 + - jsa_security_group2 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportresourcegrouplinking/expectedoutputfiles/nestedServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportresourcegrouplinking/expectedoutputfiles/nestedServiceTemplate.yaml new file mode 100644 index 0000000000..729e969c0c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportresourcegrouplinking/expectedoutputfiles/nestedServiceTemplate.yaml @@ -0,0 +1,174 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + p1: + hidden: false + immutable: false + type: string + description: UID of OAM network + p2: + hidden: false + immutable: false + type: string + description: UID of OAM network + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + cmaui_oam_ips: + hidden: false + immutable: false + type: string + net: + hidden: false + immutable: false + type: string + description: UID of OAM network + node_templates: + cmaui_port_2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: p1 + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: net + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + name: + get_input: + - cmaui_names + - 0 + cmaui_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: p1 + - get_input: p2 + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: net + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + groups: + nested: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested.yml + description: cmaui server template for vMMSC + members: + - cmaui_port_2 + - server_cmaui + - cmaui_port_1 + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested + capabilities: + host_server_cmaui: + - server_cmaui + - host + os_server_cmaui: + - server_cmaui + - os + endpoint_server_cmaui: + - server_cmaui + - endpoint + binding_server_cmaui: + - server_cmaui + - binding + attachment_cmaui_port_2: + - cmaui_port_2 + - attachment + scalable_server_cmaui: + - server_cmaui + - scalable + attachment_cmaui_port_1: + - cmaui_port_1 + - attachment + requirements: + local_storage_server_cmaui: + - server_cmaui + - local_storage + link_cmaui_port_2: + - cmaui_port_2 + - link + link_cmaui_port_1: + - cmaui_port_1 + - link \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportresourcegrouplinking/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportresourcegrouplinking/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..8ba5fc48f4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportresourcegrouplinking/inputfiles/MANIFEST.json @@ -0,0 +1,22 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "main.yml", + "type": "HEAT", + "isBase": "true" + }, + { + "file": "nested.yml", + "type": "HEAT", + "isBase": "false" + }, + { + "file": "addOn.yml", + "type": "HEAT", + "isBase": "false" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportresourcegrouplinking/inputfiles/addOn.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportresourcegrouplinking/inputfiles/addOn.yml new file mode 100644 index 0000000000..39c34742a4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportresourcegrouplinking/inputfiles/addOn.yml @@ -0,0 +1,31 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + shared_security_group_id1: + type: string + description: network name of jsa log network + shared_security_group_id2: + type: string + description: network name of jsa log network + jsa_net_name: + type: string + description: network name of jsa log network + security_group_name: + type: string + label: security group name + description: the name of security group + +resources: + mvs_modules: + type: OS::Heat::ResourceGroup + properties: + count: 3 + index_var: "%index%" + resource_def: + type: nested.yml + properties: + p1: { get_param: shared_security_group_id1} + p2: { get_param: shared_security_group_id2} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportresourcegrouplinking/inputfiles/main.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportresourcegrouplinking/inputfiles/main.yml new file mode 100644 index 0000000000..9167ffbafd --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportresourcegrouplinking/inputfiles/main.yml @@ -0,0 +1,58 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + jsa_net_name: + type: string + description: network name of jsa log network + security_group_name: + type: string + label: security group name + description: the name of security group + +resources: + jsa_security_group1: + type: OS::Neutron::SecurityGroup + properties: + description: ems security group + name: {get_param: security_group_name} + rules: [{"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": "::/0"}, + {"direction": egress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": "::/0"}, + {"direction": egress, "ethertype": IPv6, "protocol": icmp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv6, "protocol": icmp, "remote_ip_prefix": "::/0"} + ] + + jsa_security_group2: + type: OS::Neutron::SecurityGroup + properties: + description: ems security group + name: {get_param: security_group_name} + rules: [{"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": egress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": "::/0"}, + {"direction": egress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": "::/0"}, + {"direction": egress, "ethertype": IPv6, "protocol": icmp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv4, "protocol": icmp, "remote_ip_prefix": 0.0.0.0/0}, + {"direction": ingress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": tcp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv6, "port_range_min": 1, "port_range_max": 65535, "protocol": udp, "remote_ip_prefix": "::/0"}, + {"direction": ingress, "ethertype": IPv6, "protocol": icmp, "remote_ip_prefix": "::/0"} + ] +outputs: + shared_security_group_id1: + value: {get_resource: jsa_security_group1} + + shared_security_group_id2: + value: {get_resource: jsa_security_group2} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportresourcegrouplinking/inputfiles/nested.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportresourcegrouplinking/inputfiles/nested.yml new file mode 100644 index 0000000000..597ca0219c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/securityruletosharedportresourcegrouplinking/inputfiles/nested.yml @@ -0,0 +1,58 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + p1: + type: string + description: UID of OAM network + p2: + type: string + description: UID of OAM network + net: + type: string + description: UID of OAM network + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_oam_ips: + type: string + +resources: + + cmaui_port_1: + type: OS::Neutron::Port + properties: + network: { get_param: net } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: p1}, {get_param: p2}] + replacement_policy: AUTO + + cmaui_port_2: + type: OS::Neutron::Port + properties: + network: { get_param: net } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: p1}] + replacement_policy: AUTO + + server_cmaui: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_1 } + - port: { get_resource: cmaui_port_2 } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vmme_small/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vmme_small/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..9885c31b1c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vmme_small/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,1267 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.NCB1: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.GPB2: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.NCB2: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.GPB1: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.FSB2: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.VLC1: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.FSB1: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server + org.openecomp.resource.vfc.nodes.heat.VLC2: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + Internal2_name: + hidden: false + immutable: false + type: string + default: Internal2-subnet + vlc2-Internal2-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to vlc2-Internal2 + default: 00:81:37:0E:02:12 + epc-sctp-a-net-rt: + hidden: false + immutable: false + type: string + description: epc-sctp-a route target + default: 13979:105717 + epc-sctp-b-net-rt: + hidden: false + immutable: false + type: string + description: epc-sctp-b route target + default: 13979:105719 + gpb-flavor: + hidden: false + immutable: false + type: string + description: Flavor to use for servers gpb + default: m4.xlarge4 + Internal1_cidr: + hidden: false + immutable: false + type: string + default: 169.253.0.0/17 + epc-sctp-a-pool-start: + hidden: false + immutable: false + type: string + description: epc-sctp-a-net network ip pool start IP address + default: 107.243.37.3 + Internal2_subnet_name: + hidden: false + immutable: false + type: string + default: vmme_int_int_sub_2 + Internal1_subnet_name: + hidden: false + immutable: false + type: string + default: vmme_int_int_sub_1 + gpb1-Internal1-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to gpb1-Internal1 + default: 00:80:37:0E:01:22 + gpb1-Internal1-ip: + hidden: false + immutable: false + type: string + default: 169.254.0.101 + FSB_1_image: + label: MME_FSB1 + hidden: false + immutable: false + type: string + description: MME_FSB1_15B-CP04-r5a01 + default: MME_FSB1_15B-CP04-r5a01 + fsb1-Internal2-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to fsb1-Internal2 + default: 00:81:37:0E:0B:12 + ncb_zone: + hidden: false + immutable: false + type: string + description: cluster for spawnning ncb instances + default: nova + Internal2_net_name: + hidden: false + immutable: false + type: string + default: vmme_int_int_2 + epc-sctp-a-pool-end: + hidden: false + immutable: false + type: string + description: epc-sctp-a-net network ip pool end IP address + default: 107.243.37.30 + Internal1_name: + hidden: false + immutable: false + type: string + default: Internal1-subnet + gpb2-name: + hidden: false + immutable: false + type: string + description: Name of gpb2 + default: ZRDM1MMEX33GPB002 + fsb2-Internal1-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to fsb2-Internal1 + default: 00:80:37:0E:0D:12 + fsb2-name: + hidden: false + immutable: false + type: string + description: Name of fsb1 + default: ZRDM1MMEX33FSB002 + static_prefix_sctp_b_1: + hidden: false + immutable: false + type: string + description: Static Prefix + default: 107.239.40.64/30 + fsb2-oam-ip: + hidden: false + immutable: false + type: string + default: 107.250.172.222 + fsb2-flavor: + hidden: false + immutable: false + type: string + description: Flavor to use for servers fsb2 + default: m4.xlarge4 + fsb2-Internal2-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to fsb2-Internal2 + default: 00:81:37:0E:0D:12 + ncb2-Internal1-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to ncb2-Internal1 + default: 00:80:37:0E:0F:12 + ncb2-name: + hidden: false + immutable: false + type: string + description: Name of ncb2 + default: ZRDM1MMEX33NCB002 + epc-sctp-b-pool-end: + hidden: false + immutable: false + type: string + description: epc-sctp-b-net network ip pool end IP address + default: 107.243.37.62 + vlc1-gtp-ip: + hidden: false + immutable: false + type: string + default: 107.243.37.67 + epc-sctp-b-pool-start: + hidden: false + immutable: false + type: string + description: epc-sctp-b-net network ip pool start IP address + default: 107.243.37.35 + Internal2_shared: + hidden: false + immutable: false + type: string + default: 'False' + Internal1_net_name: + hidden: false + immutable: false + type: string + default: vmme_int_int_1 + vlc2-name: + hidden: false + immutable: false + type: string + description: Name of vlc2 + default: ZRDM1MMEX33VLC002 + Internal2_ipam_name: + hidden: false + immutable: false + type: string + default: vmme_ipam_int2 + vlc1-sctp-b-ip: + hidden: false + immutable: false + type: string + default: 107.243.37.35 + Internal1_net_pool_end: + hidden: false + immutable: false + type: string + default: 169.253.0.254 + Internal1_default_gateway: + hidden: false + immutable: false + type: string + default: 169.253.0.3 + ncb1-Internal1-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to ncb1-Internal1 + default: 00:80:37:0E:09:12 + epc-gtp-net-name: + hidden: false + immutable: false + type: string + description: gtp net name + default: EPC-GTP + vlc1-Internal1-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to vlc1-Internal1 + default: 00:80:37:0E:01:12 + gpb2-Internal1-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to gpb2-Internal1 + default: 00:80:37:0E:02:22 + epc-gtp-net-cidr: + hidden: false + immutable: false + type: string + description: gtp stubnet + default: 107.243.37.64/27 + oam_net_id: + hidden: false + immutable: false + type: string + description: uuid of oam network + default: 47bf4cca-0961-422f-bcd6-d5a4fbb1a351 + vlc_zone: + hidden: false + immutable: false + type: string + description: cluster for spawnning vlc instances + default: nova + vlc2-Internal1-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to vlc2-Internal1 + default: 00:80:37:0E:02:12 + epc-sctp-a-net-cidr: + hidden: false + immutable: false + type: string + description: epc-sctp-a subnet + default: 107.243.37.0/27 + Internal1_forwarding_mode: + hidden: false + immutable: false + type: string + default: l2 + Internal2_dhcp: + hidden: false + immutable: false + type: boolean + default: false + fsb1-oam-ip: + hidden: false + immutable: false + type: string + default: 107.250.172.221 + FSB_2_image: + label: MME_FSB2 + hidden: false + immutable: false + type: string + description: MME_FSB2_15B-CP04-r5a01 + default: MME_FSB2_15B-CP04-r5a01 + vlc1-oam-ip: + hidden: false + immutable: false + type: string + default: 107.250.172.227 + epc-sctp-a-net-name: + hidden: false + immutable: false + type: string + description: epc-sctp-a net name + default: EPC-SCTP-A + vlc2-oam-ip: + hidden: false + immutable: false + type: string + default: 107.250.172.228 + Internal2_net_pool_start: + hidden: false + immutable: false + type: string + default: 169.255.0.100 + FSB1_volume_name: + label: FSB1_volume + hidden: false + immutable: false + type: string + description: FSB1_volume_1 + default: vFSB1_1_Vol_1 + vlc1-sctp-a-ip: + hidden: false + immutable: false + type: string + default: 107.243.37.3 + Internal1_ipam_name: + hidden: false + immutable: false + type: string + default: vmme_ipam_int1 + Internal1_dhcp: + hidden: false + immutable: false + type: boolean + default: false + Internal2_external: + hidden: false + immutable: false + type: string + default: 'False' + Internal2_forwarding_mode: + hidden: false + immutable: false + type: string + default: l2 + vlc1-name: + hidden: false + immutable: false + type: string + description: Name of vlc1 + default: ZRDM1MMEX33VLC002 + vlc-flavor: + hidden: false + immutable: false + type: string + description: Flavor to use for servers vlc + default: m4.xlarge4 + epc-gtp-net-rt: + hidden: false + immutable: false + type: string + description: gtp route target + default: 13979:105715 + gpb_zone: + hidden: false + immutable: false + type: string + description: cluster for spawnning gpb instances + default: nova + gpb1-Internal2-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to gpb1-Internal2 + default: 00:81:37:0E:01:22 + fsb1-Internal1-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to fsb1-Internal1 + default: 00:80:37:0E:0B:12 + FSB2_volume_name: + label: FSB2_volume + hidden: false + immutable: false + type: string + description: FSB2_volume_1 + default: vFSB2_1_Vol_1 + VMME_FSB2_boot_volume: + hidden: false + immutable: false + type: string + default: 089a0d11-4b15-4370-8343-3f90907b1221 + fsb_zone: + hidden: false + immutable: false + type: string + description: cluster for spawnning fsb instances + default: nova + VMME_FSB1_boot_volume: + hidden: false + immutable: false + type: string + default: 8248e794-6173-4b49-b9c3-8219b0b56f4e + Internal2_default_gateway: + hidden: false + immutable: false + type: string + default: 169.255.0.3 + Internal1_external: + hidden: false + immutable: false + type: string + default: 'False' + vlc2-sctp-a-ip: + hidden: false + immutable: false + type: string + default: 107.243.37.4 + ncb-flavor: + hidden: false + immutable: false + type: string + description: Flavor to use for servers ncb + default: m4.xlarge4 + Internal1_shared: + hidden: false + immutable: false + type: string + default: 'False' + fsb1-name: + hidden: false + immutable: false + type: string + description: Name of fsb1 + default: ZRDM1MMEX33FSB001 + static_prefix_gtp_1: + hidden: false + immutable: false + type: string + description: Static Prefix + default: 107.239.40.96/30 + epc-sctp-b-net-gateway: + hidden: false + immutable: false + type: string + description: epc-sctp-b-net network gateway + default: 107.243.37.33 + epc-sctp-b-net-cidr: + hidden: false + immutable: false + type: string + description: epc-sctp-b subnet + default: 107.243.37.32/24 + epc-gtp-pool-end: + hidden: false + immutable: false + type: string + description: gtp network ip pool end IP address + default: 107.243.37.94 + epc-sctp-a-net-gateway: + hidden: false + immutable: false + type: string + description: epc-sctp-a-net network gateway + default: 107.243.37.1 + vlc2-gtp-ip: + hidden: false + immutable: false + type: string + default: 107.243.37.68 + vlc2-sctp-b-ip: + hidden: false + immutable: false + type: string + default: 107.243.37.36 + Internal1_net_pool_start: + hidden: false + immutable: false + type: string + default: 169.253.0.100 + volume_size: + label: volume size + hidden: false + immutable: false + type: float + description: my volume size 320GB + default: 320 + fsb2-image: + hidden: false + immutable: false + type: string + description: Name of image to use for server fsb2 + default: MME_FSB2_15B-CP04-r5a01 + ncb2-Internal2-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to ncb2-Internal2 + default: 00:81:37:0E:0F:12 + ncb1-name: + hidden: false + immutable: false + type: string + description: Name of ncb1 + default: ZRDM1MMEX33NCB001 + fsb1-image: + hidden: false + immutable: false + type: string + description: Name of image to use for server fsb1 + default: MME_FSB1_15B-CP04-r5a01 + fsb1-flavor: + hidden: false + immutable: false + type: string + description: Flavor to use for servers fsb1 + default: m4.xlarge4 + volume_type: + label: volume type + hidden: false + immutable: false + type: string + description: volume type Gold + default: Gold + Internal2_net_pool_end: + hidden: false + immutable: false + type: string + default: 169.255.0.254 + epc-sctp-b-net-name: + hidden: false + immutable: false + type: string + description: epc-sctp-b net name + default: EPC-SCTP-B + Internal2_cidr: + hidden: false + immutable: false + type: string + default: 169.255.0.0/17 + epc-gtp-net-gateway: + hidden: false + immutable: false + type: string + description: gtp network gateway + default: 107.243.37.65 + gpb2-Internal2-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to gpb2-Internal2 + default: 00:81:37:0E:02:22 + ncb1-Internal2-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to ncb1-Internal2 + default: 00:81:37:0E:09:12 + epc-gtp-pool-start: + hidden: false + immutable: false + type: string + description: gtp network ip pool start IP address + default: 107.243.37.67 + static_prefix_sctp_a_1: + hidden: false + immutable: false + type: string + description: Static Prefix + default: 107.239.40.32/30 + gpb1-name: + hidden: false + immutable: false + type: string + description: Name of gpb1 + default: ZRDM1MMEX33GPB001 + pxe-image: + hidden: false + immutable: false + type: string + description: Name of image to use for server ncb + default: MME_PXE-BOOT_cxp9025898_2r5a01.qcow2 + vlc1-Internal2-mac: + hidden: false + immutable: false + type: string + description: static mac address assigned to vlc1-Internal2 + default: 00:81:37:0E:01:12 + node_templates: + NCB1: + type: org.openecomp.resource.vfc.nodes.heat.NCB1 + properties: + flavor: + get_input: ncb-flavor + availability_zone: + get_input: ncb_zone + image: + get_input: pxe-image + name: + get_input: ncb1-name + NCB2: + type: org.openecomp.resource.vfc.nodes.heat.NCB2 + properties: + flavor: + get_input: ncb-flavor + availability_zone: + get_input: ncb_zone + image: + get_input: pxe-image + name: + get_input: ncb2-name + VLC2_OAM: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + fixed_ips: + - ip_address: + get_input: vlc2-oam-ip + network: + get_input: oam_net_id + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: VLC2 + relationship: tosca.relationships.network.BindsTo + epc-gtp-net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + route_targets: + - get_input: epc-gtp-net-rt + network_name: + get_input: epc-gtp-net-name + subnets: + epc-gtp-subnet: + cidr: + get_input: epc-gtp-net-cidr + gateway_ip: + get_input: epc-gtp-net-gateway + allocation_pools: + - start: + get_input: epc-gtp-pool-start + end: + get_input: epc-gtp-pool-end + NCB1_Internal1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: ncb1-Internal1-mac + network: Internal1-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal1-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: NCB1 + relationship: tosca.relationships.network.BindsTo + VLC2_Internal2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: vlc2-Internal2-mac + network: Internal2-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal2-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: VLC2 + relationship: tosca.relationships.network.BindsTo + NCB1_Internal2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: ncb1-Internal2-mac + network: Internal2-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal2-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: NCB1 + relationship: tosca.relationships.network.BindsTo + VLC2_Internal1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: vlc2-Internal1-mac + network: Internal1-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal1-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: VLC2 + relationship: tosca.relationships.network.BindsTo + VLC2_GTP: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + fixed_ips: + - ip_address: + get_input: vlc2-gtp-ip + network: epc-gtp-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: epc-gtp-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: VLC2 + relationship: tosca.relationships.network.BindsTo + FSB1_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + image: + get_input: FSB_1_image + volume_type: + get_input: volume_type + size: '(get_input : volume_size) * 1024' + name: + get_input: FSB1_volume_name + FSB1_OAM: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + fixed_ips: + - ip_address: + get_input: fsb1-oam-ip + network: + get_input: oam_net_id + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: FSB1 + relationship: tosca.relationships.network.BindsTo + FSB2_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + image: + get_input: FSB_2_image + volume_type: + get_input: volume_type + size: '(get_input : volume_size) * 1024' + name: + get_input: FSB2_volume_name + Internal1-net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + dhcp_enabled: + get_input: Internal1_dhcp + shared: + get_input: Internal1_shared + forwarding_mode: + get_input: Internal1_forwarding_mode + external: + get_input: Internal1_external + network_name: + get_input: Internal1_net_name + subnets: + Internal1-subnet: + enable_dhcp: + get_input: Internal1_dhcp + cidr: + get_input: Internal1_cidr + gateway_ip: + get_input: Internal1_default_gateway + GPB2_Internal1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: gpb2-Internal1-mac + network: Internal1-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal1-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: GPB2 + relationship: tosca.relationships.network.BindsTo + GPB2_Internal2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: gpb2-Internal2-mac + network: Internal2-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal2-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: GPB2 + relationship: tosca.relationships.network.BindsTo + NCB2_Internal2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: ncb2-Internal2-mac + network: Internal2-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal2-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: NCB2 + relationship: tosca.relationships.network.BindsTo + NCB2_Internal1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: ncb2-Internal1-mac + network: Internal1-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal1-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: NCB2 + relationship: tosca.relationships.network.BindsTo + FSB2: + type: org.openecomp.resource.vfc.nodes.heat.FSB2 + properties: + flavor: + get_input: fsb2-flavor + availability_zone: + get_input: fsb_zone + name: + get_input: fsb2-name + FSB1: + type: org.openecomp.resource.vfc.nodes.heat.FSB1 + properties: + flavor: + get_input: fsb1-flavor + availability_zone: + get_input: fsb_zone + name: + get_input: fsb1-name + Internal2-net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + dhcp_enabled: + get_input: Internal2_dhcp + shared: + get_input: Internal2_shared + forwarding_mode: + get_input: Internal2_forwarding_mode + external: + get_input: Internal2_external + network_name: + get_input: Internal2_name + subnets: + Internal2-subnet: + enable_dhcp: + get_input: Internal2_dhcp + cidr: + get_input: Internal2_cidr + gateway_ip: + get_input: Internal2_default_gateway + VLC1_Internal1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: vlc1-Internal1-mac + network: Internal1-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal1-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: VLC1 + relationship: tosca.relationships.network.BindsTo + epc-sctp-a-net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + route_targets: + - get_input: epc-sctp-a-net-rt + network_name: + get_input: epc-sctp-a-net-name + subnets: + epc-sctp-a-subnet: + cidr: + get_input: epc-sctp-a-net-cidr + gateway_ip: + get_input: epc-sctp-a-net-gateway + allocation_pools: + - start: + get_input: epc-sctp-a-pool-start + end: + get_input: epc-sctp-a-pool-end + VLC1_Internal2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: vlc1-Internal2-mac + network: Internal2-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal2-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: VLC1 + relationship: tosca.relationships.network.BindsTo + VLC1_SCTP_B: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + fixed_ips: + - ip_address: + get_input: vlc1-sctp-b-ip + network: epc-sctp-b-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: epc-sctp-b-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: VLC1 + relationship: tosca.relationships.network.BindsTo + VLC2_SCTP_B: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + fixed_ips: + - ip_address: + get_input: vlc2-sctp-b-ip + network: epc-sctp-b-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: epc-sctp-b-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: VLC2 + relationship: tosca.relationships.network.BindsTo + VLC1_SCTP_A: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + fixed_ips: + - ip_address: + get_input: vlc1-sctp-a-ip + network: epc-sctp-a-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: epc-sctp-a-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: VLC1 + relationship: tosca.relationships.network.BindsTo + VLC2_SCTP_A: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + fixed_ips: + - ip_address: + get_input: vlc2-sctp-a-ip + network: epc-sctp-a-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: epc-sctp-a-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: VLC2 + relationship: tosca.relationships.network.BindsTo + VLC1: + type: org.openecomp.resource.vfc.nodes.heat.VLC1 + properties: + flavor: + get_input: vlc-flavor + availability_zone: + get_input: vlc_zone + image: + get_input: pxe-image + name: + get_input: vlc1-name + FSB1_Internal2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: fsb1-Internal2-mac + network: Internal2-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal2-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: FSB1 + relationship: tosca.relationships.network.BindsTo + VLC2: + type: org.openecomp.resource.vfc.nodes.heat.VLC2 + properties: + flavor: + get_input: vlc-flavor + availability_zone: + get_input: vlc_zone + image: + get_input: pxe-image + name: + get_input: vlc2-name + FSB1_Internal1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: fsb1-Internal1-mac + network: Internal1-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal1-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: FSB1 + relationship: tosca.relationships.network.BindsTo + FSB2_Internal2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: fsb2-Internal2-mac + network: Internal2-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal2-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: FSB2 + relationship: tosca.relationships.network.BindsTo + FSB2_Internal1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: fsb2-Internal1-mac + network: Internal1-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal1-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: FSB2 + relationship: tosca.relationships.network.BindsTo + VLC1_OAM: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + fixed_ips: + - ip_address: + get_input: vlc1-oam-ip + network: + get_input: oam_net_id + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: VLC1 + relationship: tosca.relationships.network.BindsTo + epc-sctp-b-net: + type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork + properties: + route_targets: + - get_input: epc-sctp-b-net-rt + network_name: + get_input: epc-sctp-b-net-name + subnets: + epc-sctp-b-subnet: + cidr: + get_input: epc-sctp-b-net-cidr + gateway_ip: + get_input: epc-sctp-b-net-gateway + allocation_pools: + - start: + get_input: epc-sctp-b-pool-start + end: + get_input: epc-sctp-b-pool-end + GPB2: + type: org.openecomp.resource.vfc.nodes.heat.GPB2 + properties: + flavor: + get_input: gpb-flavor + availability_zone: + get_input: gpb_zone + image: + get_input: pxe-image + name: + get_input: gpb2-name + GPB1: + type: org.openecomp.resource.vfc.nodes.heat.GPB1 + properties: + flavor: + get_input: gpb-flavor + availability_zone: + get_input: gpb_zone + image: + get_input: pxe-image + name: + get_input: gpb1-name + VLC1_GTP: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + fixed_ips: + - ip_address: + get_input: vlc1-gtp-ip + network: epc-gtp-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: epc-gtp-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: VLC1 + relationship: tosca.relationships.network.BindsTo + FSB2_OAM: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + fixed_ips: + - ip_address: + get_input: fsb2-oam-ip + network: + get_input: oam_net_id + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: FSB2 + relationship: tosca.relationships.network.BindsTo + GPB1_Internal2: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: gpb1-Internal2-mac + network: Internal2-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal2-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: GPB1 + relationship: tosca.relationships.network.BindsTo + GPB1_Internal1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + mac_address: + get_input: gpb1-Internal1-mac + network: Internal1-net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: Internal1-net + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: GPB1 + relationship: tosca.relationships.network.BindsTo + groups: + vmme_small: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/vmme_small.yml + description: HOT template to create vmme 2 fsb 2 ncb 2 gbp 2 vlc + members: + - NCB1 + - NCB2 + - VLC2_OAM + - epc-gtp-net + - NCB1_Internal1 + - VLC2_Internal2 + - NCB1_Internal2 + - VLC2_Internal1 + - VLC2_GTP + - FSB1_OAM + - Internal1-net + - GPB2_Internal1 + - GPB2_Internal2 + - NCB2_Internal2 + - NCB2_Internal1 + - FSB2 + - FSB1 + - Internal2-net + - VLC1_Internal1 + - epc-sctp-a-net + - VLC1_Internal2 + - VLC1_SCTP_B + - VLC2_SCTP_B + - VLC1_SCTP_A + - VLC2_SCTP_A + - VLC1 + - FSB1_Internal2 + - VLC2 + - FSB1_Internal1 + - FSB2_Internal2 + - FSB2_Internal1 + - VLC1_OAM + - epc-sctp-b-net + - GPB2 + - GPB1 + - VLC1_GTP + - FSB2_OAM + - GPB1_Internal2 + - GPB1_Internal1 + vmme_small_create_fsb: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/vmme_small_create_fsb.yml + description: server template for vMME + members: + - FSB1_volume + - FSB2_volume \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vmme_small/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vmme_small/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..71259e1116 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vmme_small/inputfiles/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "vmme_small.yml", + "type": "HEAT", + "data": [ + { + "file": "vmme_small.env", + "type": "HEAT_ENV" + }, + { + "file": "vmme_small_create_fsb.yml", + "type": "HEAT_VOL", + "data": [ + { + "file": "vmme_small_create_fsb.env", + "type": "HEAT_ENV" + } + ] + } + ] + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vmme_small/inputfiles/vmme_small.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vmme_small/inputfiles/vmme_small.env new file mode 100644 index 0000000000..e46cfd2a2d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vmme_small/inputfiles/vmme_small.env @@ -0,0 +1,97 @@ +parameters: + oam_net_id: 47bf4cca-0961-422f-bcd6-d5a4fbb1a351 + fsb1-name: ZRDM1MMEX33FSB001 + fsb2-name: ZRDM1MMEX33FSB002 + ncb1-name: ZRDM1MMEX33NCB001 + ncb2-name: ZRDM1MMEX33NCB002 + vlc1-name: ZRDM1MMEX33VLC002 + vlc2-name: ZRDM1MMEX33VLC002 + gpb1-name: ZRDM1MMEX33GPB001 + gpb2-name: ZRDM1MMEX33GPB002 + epc-sctp-a-net-name: EPC-SCTP-A + epc-sctp-a-net-rt: 13979:105717 + epc-sctp-a-net-cidr: 107.243.37.0/27 + epc-sctp-a-net-gateway: 107.243.37.1 + epc-sctp-a-pool-start: 107.243.37.3 + epc-sctp-a-pool-end: 107.243.37.30 + epc-sctp-b-net-name: EPC-SCTP-B + epc-sctp-b-net-rt: 13979:105719 + epc-sctp-b-net-cidr: 107.243.37.32/24 + epc-sctp-b-net-gateway: 107.243.37.33 + epc-sctp-b-pool-start: 107.243.37.35 + epc-sctp-b-pool-end: 107.243.37.62 + epc-gtp-net-name: EPC-GTP + epc-gtp-net-rt: 13979:105715 + epc-gtp-net-cidr: 107.243.37.64/27 + epc-gtp-net-gateway: 107.243.37.65 + epc-gtp-pool-start: 107.243.37.67 + epc-gtp-pool-end: 107.243.37.94 + fsb1-image: MME_FSB1_15B-CP04-r5a01 + fsb2-image: MME_FSB2_15B-CP04-r5a01 + fsb1-flavor: m4.xlarge4 + fsb2-flavor: m4.xlarge4 + fsb_zone: nova + fsb1-Internal1-mac: 00:80:37:0E:0B:12 + fsb1-Internal2-mac: 00:81:37:0E:0B:12 + fsb1-oam-ip: 107.250.172.221 + fsb2-Internal1-mac: 00:80:37:0E:0D:12 + fsb2-Internal2-mac: 00:81:37:0E:0D:12 + fsb2-oam-ip: 107.250.172.222 + pxe-image: MME_PXE-BOOT_cxp9025898_2r5a01.qcow2 + ncb-flavor: m4.xlarge4 + ncb_zone: nova + ncb1-Internal1-mac: 00:80:37:0E:09:12 + ncb1-Internal2-mac: 00:81:37:0E:09:12 + ncb2-Internal1-mac: 00:80:37:0E:0F:12 + ncb2-Internal2-mac: 00:81:37:0E:0F:12 + gpb-flavor: m4.xlarge4 + gpb_zone: nova + gpb1-Internal1-mac: 00:80:37:0E:01:22 + gpb1-Internal1-ip: 169.254.0.101 + gpb1-Internal2-mac: 00:81:37:0E:01:22 + gpb2-Internal1-mac: 00:80:37:0E:02:22 + gpb2-Internal2-mac: 00:81:37:0E:02:22 + vlc-flavor: m4.xlarge4 + vlc_zone: nova + vlc1-sctp-a-ip: 107.243.37.3 + vlc1-sctp-b-ip: 107.243.37.35 + vlc1-gtp-ip: 107.243.37.67 + vlc1-oam-ip: 107.250.172.227 + vlc2-sctp-a-ip: 107.243.37.4 + vlc2-sctp-b-ip: 107.243.37.36 + vlc2-gtp-ip: 107.243.37.68 + vlc2-oam-ip: 107.250.172.228 + vlc1-Internal1-mac: 00:80:37:0E:01:12 + vlc1-Internal2-mac: 00:81:37:0E:01:12 + vlc2-Internal1-mac: 00:80:37:0E:02:12 + vlc2-Internal2-mac: 00:81:37:0E:02:12 + Internal1_net_name: vmme_int_int_1 + Internal1_subnet_name: vmme_int_int_sub_1 + Internal1_ipam_name: vmme_ipam_int1 + Internal1_cidr: 169.253.0.0/17 + Internal1_forwarding_mode: "l2" + Internal1_dhcp: "False" + Internal1_shared: "False" + Internal1_external: "False" + Internal1_name: "Internal1-subnet" + Internal1_default_gateway: 169.253.0.3 + Internal1_net_pool_start: 169.253.0.100 + Internal1_net_pool_end: 169.253.0.254 + Internal2_net_name: vmme_int_int_2 + Internal2_subnet_name: vmme_int_int_sub_2 + Internal2_ipam_name: vmme_ipam_int2 + Internal2_cidr: 169.255.0.0/17 + Internal2_shared: "False" + Internal2_external: "False" + Internal2_forwarding_mode: "l2" + Internal2_dhcp: "False" + Internal2_name: "Internal2-subnet" + Internal2_default_gateway: 169.255.0.3 + Internal2_net_pool_start: 169.255.0.100 + Internal2_net_pool_end: 169.255.0.254 + static_prefix_sctp_a_1: 107.239.40.32/30 + static_prefix_gtp_1: 107.239.40.96/30 + static_prefix_sctp_b_1: 107.239.40.64/30 + VMME_FSB1_boot_volume: 8248e794-6173-4b49-b9c3-8219b0b56f4e + VMME_FSB2_boot_volume: 089a0d11-4b15-4370-8343-3f90907b1221 + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vmme_small/inputfiles/vmme_small.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vmme_small/inputfiles/vmme_small.yml new file mode 100644 index 0000000000..d7ad9a84d0 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vmme_small/inputfiles/vmme_small.yml @@ -0,0 +1,644 @@ +heat_template_version: 2013-05-23 + +description: HOT template to create vmme 2 fsb 2 ncb 2 gbp 2 vlc + +parameters: + fsb1-oam-ip: + type: string + fsb2-oam-ip: + type: string + vlc1-oam-ip: + type: string + vlc2-oam-ip: + type: string + Internal1_net_pool_start: + type: string + Internal1_net_pool_end: + type: string + Internal2_net_pool_start: + type: string + Internal2_net_pool_end: + type: string + Internal1_default_gateway: + type: string + Internal2_default_gateway: + type: string + Internal1_shared: + type: string + Internal1_external: + type: string + Internal1_net_name: + type: string + Internal1_subnet_name: + type: string + Internal1_ipam_name: + type: string + Internal1_cidr: + type: string + Internal1_forwarding_mode: + type: string + Internal1_dhcp: + type: string + Internal1_name: + type: string + Internal2_net_name: + type: string + Internal2_subnet_name: + type: string + Internal2_ipam_name: + type: string + Internal2_cidr: + type: string + Internal2_forwarding_mode: + type: string + Internal2_dhcp: + type: string + Internal2_name: + type: string + Internal2_shared: + type: string + Internal2_external: + type: string + vlc1-sctp-a-ip: + type: string + vlc1-sctp-b-ip: + type: string + vlc1-gtp-ip: + type: string + vlc2-sctp-a-ip: + type: string + vlc2-sctp-b-ip: + type: string + vlc2-gtp-ip: + type: string + fsb1-name: + type: string + description: Name of fsb1 + fsb2-name: + type: string + description: Name of fsb1 + ncb1-name: + type: string + description: Name of ncb1 + ncb2-name: + type: string + description: Name of ncb2 + vlc1-name: + type: string + description: Name of vlc1 + vlc2-name: + type: string + description: Name of vlc2 + gpb1-name: + type: string + description: Name of gpb1 + gpb2-name: + type: string + description: Name of gpb2 + fsb_zone: + type: string + description: cluster for spawnning fsb instances + fsb1-image: + type: string + description: Name of image to use for server fsb1 + fsb1-flavor: + type: string + description: Flavor to use for servers fsb1 + oam_net_id: + type: string + description: uuid of oam network + fsb1-Internal1-mac: + type: string + description: static mac address assigned to fsb1-Internal1 + fsb1-Internal2-mac: + type: string + description: static mac address assigned to fsb1-Internal2 + fsb2-image: + type: string + description: Name of image to use for server fsb2 + fsb2-flavor: + type: string + description: Flavor to use for servers fsb2 + fsb2-Internal1-mac: + type: string + description: static mac address assigned to fsb2-Internal1 + fsb2-Internal2-mac: + type: string + description: static mac address assigned to fsb2-Internal2 + pxe-image: + type: string + description: Name of image to use for server ncb + ncb-flavor: + type: string + description: Flavor to use for servers ncb + ncb_zone: + type: string + description: cluster for spawnning ncb instances + ncb1-Internal1-mac: + type: string + description: static mac address assigned to ncb1-Internal1 + ncb1-Internal2-mac: + type: string + description: static mac address assigned to ncb1-Internal2 + ncb2-Internal1-mac: + type: string + description: static mac address assigned to ncb2-Internal1 + ncb2-Internal2-mac: + type: string + description: static mac address assigned to ncb2-Internal2 + gpb-flavor: + type: string + description: Flavor to use for servers gpb + gpb_zone: + type: string + description: cluster for spawnning gpb instances + gpb1-Internal1-ip: + type: string + gpb1-Internal1-mac: + type: string + description: static mac address assigned to gpb1-Internal1 + gpb1-Internal2-mac: + type: string + description: static mac address assigned to gpb1-Internal2 + gpb2-Internal1-mac: + type: string + description: static mac address assigned to gpb2-Internal1 + gpb2-Internal2-mac: + type: string + description: static mac address assigned to gpb2-Internal2 + vlc-flavor: + type: string + description: Flavor to use for servers vlc + vlc_zone: + type: string + description: cluster for spawnning vlc instances + vlc1-Internal1-mac: + type: string + description: static mac address assigned to vlc1-Internal1 + vlc1-Internal2-mac: + type: string + description: static mac address assigned to vlc1-Internal2 + vlc2-Internal1-mac: + type: string + description: static mac address assigned to vlc2-Internal1 + vlc2-Internal2-mac: + type: string + description: static mac address assigned to vlc2-Internal2 + epc-sctp-a-net-name: + type: string + description: epc-sctp-a net name + epc-sctp-a-net-rt: + type: string + description: epc-sctp-a route target + epc-sctp-a-net-cidr: + type: string + description: epc-sctp-a subnet + epc-sctp-a-net-gateway: + type: string + description: epc-sctp-a-net network gateway + epc-sctp-a-pool-start: + type: string + description: epc-sctp-a-net network ip pool start IP address + epc-sctp-a-pool-end: + type: string + description: epc-sctp-a-net network ip pool end IP address + epc-sctp-b-net-name: + type: string + description: epc-sctp-b net name + epc-sctp-b-net-rt: + type: string + description: epc-sctp-b route target + epc-sctp-b-net-cidr: + type: string + description: epc-sctp-b subnet + epc-sctp-b-net-gateway: + type: string + description: epc-sctp-b-net network gateway + epc-sctp-b-pool-start: + type: string + description: epc-sctp-b-net network ip pool start IP address + epc-sctp-b-pool-end: + type: string + description: epc-sctp-b-net network ip pool end IP address + epc-gtp-net-name: + type: string + description: gtp net name + epc-gtp-net-rt: + type: string + description: gtp route target + epc-gtp-net-cidr: + type: string + description: gtp stubnet + epc-gtp-net-gateway: + type: string + description: gtp network gateway + epc-gtp-pool-start: + type: string + description: gtp network ip pool start IP address + epc-gtp-pool-end: + type: string + description: gtp network ip pool end IP address + static_prefix_sctp_a_1: + type: string + description: Static Prefix + static_prefix_sctp_b_1: + type: string + description: Static Prefix + static_prefix_gtp_1: + type: string + description: Static Prefix + VMME_FSB1_boot_volume: + type: string + VMME_FSB2_boot_volume: + type: string + +resources: + + Internal1_ipam: + type: OS::Contrail::NetworkIpam + properties: + name: { get_param: Internal1_ipam_name } + + Internal2_ipam: + type: OS::Contrail::NetworkIpam + properties: + name: { get_param: Internal2_ipam_name } + + Internal1-net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: Internal1_net_name } + forwarding_mode: { get_param: Internal1_forwarding_mode } + shared: { get_param: Internal1_shared } + external: { get_param: Internal1_external } +# route_targets: { "Fn::Split" : [ ",", Ref: route_targets ] } + + Internal1-subnet: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: Internal1-net } + cidr: { get_param: Internal1_cidr } + gateway_ip: { get_param: Internal1_default_gateway } + enable_dhcp: { get_param: Internal1_dhcp } + + +# Internal1-subnet: +# type: OS::Contrail::VnSubnet +# properties: +# name: { get_param: Internal1_subnet_name } +# network: { get_resource: Internal1-net } +# ip_prefix: { get_param: Internal1_cidr } + # ipam: { get_resource: Internal1_ipam } + # enable_dhcp: { get_param: Internal1_dhcp } + # default_gateway: { get_param: Internal1_default_gateway } + # allocation_pools: + # - start: { get_param: Internal1_net_pool_start } + # end: { get_param: Internal1_net_pool_end } + + + + Internal2-net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: Internal2_name } + forwarding_mode: { get_param: Internal2_forwarding_mode } + shared: { get_param: Internal2_shared } + external: { get_param: Internal2_external } +# route_targets: { "Fn::Split" : [ ",", Ref: route_targets ] } + +# Internal2-subnet: +# type: OS::Contrail::VnSubnet +# properties: +# name: { get_param: Internal2_subnet_name } +# network: { get_resource: Internal2-net } +# ip_prefix: { get_param: Internal2_cidr } +# ipam: { get_resource: Internal2_ipam } +# enable_dhcp: { get_param: Internal2_dhcp } +# default_gateway: { get_param: Internal2_default_gateway } +# allocation_pools: +# - start: { get_param: Internal2_net_pool_start } +# end: { get_param: Internal2_net_pool_end } + + Internal2-subnet: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: Internal2-net } + cidr: { get_param: Internal2_cidr } + gateway_ip: { get_param: Internal2_default_gateway } + enable_dhcp: { get_param: Internal2_dhcp } + + epc-sctp-a-net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: epc-sctp-a-net-name } + route_targets: [ get_param: epc-sctp-a-net-rt ] + + + epc-sctp-a-subnet: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: epc-sctp-a-net } + cidr: { get_param: epc-sctp-a-net-cidr } + gateway_ip: { get_param: epc-sctp-a-net-gateway } + allocation_pools: + - start: { get_param: epc-sctp-a-pool-start } + end: { get_param: epc-sctp-a-pool-end } + + epc-sctp-b-net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: epc-sctp-b-net-name } + route_targets: [ get_param: epc-sctp-b-net-rt ] + + epc-sctp-b-subnet: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: epc-sctp-b-net } + cidr: { get_param: epc-sctp-b-net-cidr } + gateway_ip: { get_param: epc-sctp-b-net-gateway } + allocation_pools: + - start: { get_param: epc-sctp-b-pool-start } + end: { get_param: epc-sctp-b-pool-end } + + epc-gtp-net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: epc-gtp-net-name } + route_targets: [ get_param: epc-gtp-net-rt ] + + epc-gtp-subnet: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: epc-gtp-net } + cidr: { get_param: epc-gtp-net-cidr } + gateway_ip: { get_param: epc-gtp-net-gateway } + allocation_pools: + - start: { get_param: epc-gtp-pool-start } + end: { get_param: epc-gtp-pool-end } + + FSB1: + type: OS::Nova::Server + properties: + name: { get_param: fsb1-name } + block_device_mapping: [{device_name: "vda", volume_id : {get_param: VMME_FSB1_boot_volume }, delete_on_termination: "false" }] + flavor: { get_param: fsb1-flavor } + availability_zone: { get_param: fsb_zone } + networks: + - port: { get_resource: FSB1_Internal1 } + - port: { get_resource: FSB1_Internal2 } + - port: { get_resource: FSB1_OAM } + + FSB1_Internal1: + type: OS::Neutron::Port + properties: + network_id: { get_resource: Internal1-net } + mac_address: { get_param: fsb1-Internal1-mac } + + FSB1_Internal2: + type: OS::Neutron::Port + properties: + network: { get_resource: Internal2-net } + mac_address: { get_param: fsb1-Internal2-mac } + + FSB1_OAM: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_id } + fixed_ips: + - ip_address: { get_param: fsb1-oam-ip } + + FSB2: + type: OS::Nova::Server + properties: + name: { get_param: fsb2-name } + block_device_mapping: [{device_name: "vda", volume_id : {get_param: VMME_FSB2_boot_volume }, delete_on_termination: "false" }] + flavor: { get_param: fsb2-flavor } + availability_zone: { get_param: fsb_zone } + networks: + - port: { get_resource: FSB2_Internal1 } + - port: { get_resource: FSB2_Internal2 } + - port: { get_resource: FSB2_OAM } + + FSB2_Internal1: + type: OS::Neutron::Port + properties: + network: { get_resource: Internal1-net } + mac_address: { get_param: fsb2-Internal1-mac } + + + FSB2_Internal2: + type: OS::Neutron::Port + properties: + network: { get_resource: Internal2-net } + mac_address: { get_param: fsb2-Internal2-mac } + + FSB2_OAM: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_id } + fixed_ips: + - ip_address: { get_param: fsb2-oam-ip } + + NCB1: + type: OS::Nova::Server + properties: + name: { get_param: ncb1-name } + image: { get_param: pxe-image } + flavor: { get_param: ncb-flavor } + availability_zone: { get_param: ncb_zone } + networks: + - port: { get_resource: NCB1_Internal1 } + - port: { get_resource: NCB1_Internal2 } + + NCB1_Internal1: + type: OS::Neutron::Port + properties: + network: { get_resource: Internal1-net } + mac_address: { get_param: ncb1-Internal1-mac } + + NCB1_Internal2: + type: OS::Neutron::Port + properties: + network: { get_resource: Internal2-net } + mac_address: { get_param: ncb1-Internal2-mac } + + NCB2: + type: OS::Nova::Server + properties: + name: { get_param: ncb2-name } + image: { get_param: pxe-image } + flavor: { get_param: ncb-flavor } + availability_zone: { get_param: ncb_zone } + networks: + - port: { get_resource: NCB2_Internal1 } + - port: { get_resource: NCB2_Internal2 } + + NCB2_Internal1: + type: OS::Neutron::Port + properties: + network: { get_resource: Internal1-net } + mac_address: { get_param: ncb2-Internal1-mac } + + NCB2_Internal2: + type: OS::Neutron::Port + properties: + network: { get_resource: Internal2-net } + mac_address: { get_param: ncb2-Internal2-mac } + + GPB1: + type: OS::Nova::Server + properties: + name: { get_param: gpb1-name } + image: { get_param: pxe-image } + flavor: { get_param: gpb-flavor } + availability_zone: { get_param: gpb_zone } + networks: + - port: { get_resource: GPB1_Internal1 } + - port: { get_resource: GPB1_Internal2 } + + GPB1_Internal1: + type: OS::Neutron::Port + properties: + network: { get_resource: Internal1-net } + mac_address: { get_param: gpb1-Internal1-mac } + + GPB1_Internal2: + type: OS::Neutron::Port + properties: + network: { get_resource: Internal2-net } + mac_address: { get_param: gpb1-Internal2-mac } + + GPB2: + type: OS::Nova::Server + properties: + name: { get_param: gpb2-name } + image: { get_param: pxe-image } + flavor: { get_param: gpb-flavor } + availability_zone: { get_param: gpb_zone } + networks: + - port: { get_resource: GPB2_Internal1 } + - port: { get_resource: GPB2_Internal2 } + + GPB2_Internal1: + type: OS::Neutron::Port + properties: + network: { get_resource: Internal1-net } + mac_address: { get_param: gpb2-Internal1-mac } + + GPB2_Internal2: + type: OS::Neutron::Port + properties: + network: { get_resource: Internal2-net } + mac_address: { get_param: gpb2-Internal2-mac } + + VLC1: + type: OS::Nova::Server + properties: + name: { get_param: vlc1-name } + image: { get_param: pxe-image } + flavor: { get_param: vlc-flavor } + availability_zone: { get_param: vlc_zone } + networks: + - port: { get_resource: VLC1_Internal1 } + - port: { get_resource: VLC1_Internal2 } + - port: { get_resource: VLC1_OAM } + - port: { get_resource: VLC1_SCTP_A } + - port: { get_resource: VLC1_SCTP_B } + - port: { get_resource: VLC1_GTP } + + VLC1_Internal1: + type: OS::Neutron::Port + properties: + network: { get_resource: Internal1-net } + mac_address: { get_param: vlc1-Internal1-mac } + + VLC1_Internal2: + type: OS::Neutron::Port + properties: + network: { get_resource: Internal2-net } + mac_address: { get_param: vlc1-Internal2-mac } + + VLC1_OAM: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_id } + fixed_ips: + - ip_address: { get_param: vlc1-oam-ip } + + VLC1_SCTP_A: + type: OS::Neutron::Port + properties: + network: { get_resource: epc-sctp-a-net } + fixed_ips: + - ip_address: { get_param: vlc1-sctp-a-ip } + + VLC1_SCTP_B: + type: OS::Neutron::Port + properties: + network: { get_resource: epc-sctp-b-net } + fixed_ips: + - ip_address: { get_param: vlc1-sctp-b-ip } + + VLC1_GTP: + type: OS::Neutron::Port + properties: + network: { get_resource: epc-gtp-net } + fixed_ips: + - ip_address: { get_param: vlc1-gtp-ip } + + VLC2: + type: OS::Nova::Server + properties: + name: { get_param: vlc2-name } + image: { get_param: pxe-image } + flavor: { get_param: vlc-flavor } + availability_zone: { get_param: vlc_zone } + networks: + - port: { get_resource: VLC2_Internal1 } + - port: { get_resource: VLC2_Internal2 } + - port: { get_resource: VLC2_OAM } + - port: { get_resource: VLC2_SCTP_A } + - port: { get_resource: VLC2_SCTP_B } + - port: { get_resource: VLC2_GTP } + + + VLC2_Internal1: + type: OS::Neutron::Port + properties: + network: { get_resource: Internal1-net } + mac_address: { get_param: vlc2-Internal1-mac } + + VLC2_OAM: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_id } + fixed_ips: + - ip_address: { get_param: vlc2-oam-ip } + + VLC2_Internal2: + type: OS::Neutron::Port + properties: + network: { get_resource: Internal2-net } + mac_address: { get_param: vlc2-Internal2-mac } + + VLC2_SCTP_A: + type: OS::Neutron::Port + properties: + network: { get_resource: epc-sctp-a-net } + fixed_ips: + - ip_address: { get_param: vlc2-sctp-a-ip } + + VLC2_SCTP_B: + type: OS::Neutron::Port + properties: + network: { get_resource: epc-sctp-b-net } + fixed_ips: + - ip_address: { get_param: vlc2-sctp-b-ip } + + VLC2_GTP: + type: OS::Neutron::Port + properties: + network: { get_resource: epc-gtp-net } + fixed_ips: + - ip_address: { get_param: vlc2-gtp-ip } + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vmme_small/inputfiles/vmme_small_create_fsb.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vmme_small/inputfiles/vmme_small_create_fsb.env new file mode 100644 index 0000000000..750bb2dd44 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vmme_small/inputfiles/vmme_small_create_fsb.env @@ -0,0 +1,8 @@ +parameters: + volume_type: Gold + volume_size: 320 + FSB_1_image: MME_FSB1_15B-CP04-r5a01 + FSB_2_image: MME_FSB2_15B-CP04-r5a01 + FSB1_volume_name: vFSB1_1_Vol_1 + FSB2_volume_name: vFSB2_1_Vol_1 + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vmme_small/inputfiles/vmme_small_create_fsb.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vmme_small/inputfiles/vmme_small_create_fsb.yml new file mode 100644 index 0000000000..2d695a50c1 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vmme_small/inputfiles/vmme_small_create_fsb.yml @@ -0,0 +1,54 @@ +heat_template_version: 2013-05-23 + +description: server template for vMME + +parameters: + + volume_type: + type: string + label: volume type + description: volume type Gold + + volume_size: + type: number + label: volume size + description: my volume size 320GB + + FSB_1_image: + type: string + label: MME_FSB1 + description: MME_FSB1_15B-CP04-r5a01 + + FSB_2_image: + type: string + label: MME_FSB2 + description: MME_FSB2_15B-CP04-r5a01 + + FSB1_volume_name: + type: string + label: FSB1_volume + description: FSB1_volume_1 + + FSB2_volume_name: + type: string + label: FSB2_volume + description: FSB2_volume_1 + +resources: + + FSB1_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: volume_size} + volume_type: {get_param: volume_type} + name: {get_param: FSB1_volume_name} + image: {get_param: FSB_1_image} + + FSB2_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: volume_size} + volume_type: {get_param: volume_type} + name: {get_param: FSB2_volume_name} + image: {get_param: FSB_2_image} + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/nested_with_inner_vol/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/nested_with_inner_vol/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..a44e7921f8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/nested_with_inner_vol/inputfiles/MANIFEST.json @@ -0,0 +1,24 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "nested.yml", + "type": "HEAT", + "isBase": "false", + "data":[ + { + "file": "a_vol.yml", + "type": "HEAT_VOL", + "isBase": "false" + } + ] + }, + { + "file": "main.yml", + "type": "HEAT", + "isBase": "false" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/nested_with_inner_vol/inputfiles/a_vol.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/nested_with_inner_vol/inputfiles/a_vol.yml new file mode 100644 index 0000000000..a9f72bcecf --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/nested_with_inner_vol/inputfiles/a_vol.yml @@ -0,0 +1,24 @@ +heat_template_version: 2013-05-23 + +description: volume + +parameters: + cmaui_cinder_volume_size: + type: number + label: CMAUI Cinder volume size + description: the size of the CMAUI Cinder volume + CMAUI_volume_type: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + +resources: + cmaui_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: cmaui_cinder_volume_size} + volume_type: {get_param: CMAUI_volume_type} + +outputs: + out_cmaui_volume: + value: {get_resource: cmaui_volume} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/nested_with_inner_vol/inputfiles/main.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/nested_with_inner_vol/inputfiles/main.yml new file mode 100644 index 0000000000..b97dd4b535 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/nested_with_inner_vol/inputfiles/main.yml @@ -0,0 +1,71 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + vnf_id: + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-CMAUI_id + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_cinder_volume_size: + type: number + label: CMAUI Cinder volume size + description: the size of the CMAUI Cinder volume + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + oam_net_name: + type: string + description: UID of OAM network + oam_network_netmask: + type: string + label: oam network netmask + description: oam network gateway + oam_network_gateway: + type: string + label: oam network gateway + description: oam network gateway + external_dns: + type: string + label: dns server + description: dns server + external_ntp: + type: string + label: ntp server + description: ntp server + security_group_name: + type: string + label: security group name + description: the name of security group + timezone: + type: string + label: timezone + description: timezone + cmaui_oam_ips: + type: comma_delimited_list + label: CMAUI oam_net IP addresses + description: CMAUI oam_net IP addresses + CMAUI_volume_type: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + +resources: + + server_cmaui: + type: nested.yml + properties: + cmaui_names: { get_param: [cmaui_names, 0]} + cmaui_image: { get_param: cmaui_image } + availability_zone_0: { get_param: availability_zone_0 } + cmaui_flavor: { get_param: cmaui_flavor } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/nested_with_inner_vol/inputfiles/nested.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/nested_with_inner_vol/inputfiles/nested.yml new file mode 100644 index 0000000000..cdaf251b85 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/nested_with_inner_vol/inputfiles/nested.yml @@ -0,0 +1,116 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + vnf_id: + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-CMAUI_id + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_volume: + type: string + label: CMAUI volume size + description: Volume for CMAUI server + cmaui_cinder_volume_size: + type: number + label: CMAUI Cinder volume size + description: the size of the CMAUI Cinder volume + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + oam_net_name: + type: string + description: UID of OAM network + oam_network_netmask: + type: string + label: oam network netmask + description: oam network gateway + oam_network_gateway: + type: string + label: oam network gateway + description: oam network gateway + external_dns: + type: string + label: dns server + description: dns server + external_ntp: + type: string + label: ntp server + description: ntp server + security_group_name: + type: string + label: security group name + description: the name of security group + timezone: + type: string + label: timezone + description: timezone + cmaui_oam_ips: + type: comma_delimited_list + label: CMAUI oam_net IP addresses + description: CMAUI oam_net IP addresses + CMAUI_volume_type: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + out_cmaui_volume: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + +resources: + + cmaui_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + cmaui_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_param: out_cmaui_volume} + instance_uuid: {get_resource: server_cmaui} + + server_cmaui: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_0 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + cmaui.mgmt.ip=${cmaui.mgmt.ip} + cmaui.mgmt.netmask=${cmaui.mgmt.netmask} + cmaui.mgmt.gateway=${cmaui.mgmt.gateway} + cmaui.external.dns=${cmaui.external.dns} + cmaui.external.ntp=${cmaui.external.ntp} + cmaui.node=${cmaui.node} + cmaui.timezone=${cmaui.timezone} + params: + ${cmaui.mgmt.ip}: {get_param: [cmaui_oam_ips, 0]} + ${cmaui.mgmt.netmask}: {get_param: oam_network_netmask} + ${cmaui.mgmt.gateway}: {get_param: oam_network_gateway} + ${cmaui.external.dns}: {get_param: external_dns} + ${cmaui.external.ntp}: {get_param: external_ntp} + ${cmaui.node}: {get_param: [cmaui_names, 0]} + ${cmaui.timezone}: {get_param: timezone} + user_data_format: RAW \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/nested_with_inner_vol/out/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/nested_with_inner_vol/out/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..0a5e36edaf --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/nested_with_inner_vol/out/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,146 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.nested: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + cmaui_names: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + cmaui_cinder_volume_size: + type: float + description: the size of the CMAUI Cinder volume + timezone: + type: string + description: timezone + security_group_name: + type: string + description: the name of security group + cmaui_volume: + type: string + description: Volume for CMAUI server + oam_network_netmask: + type: string + description: oam network gateway + cmaui_image: + type: string + description: Image for CMAUI server + vnf_id: + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-CMAUI_id + cmaui_flavor: + type: string + description: Flavor for CMAUI server + oam_network_gateway: + type: string + description: oam network gateway + out_cmaui_volume: + type: string + description: the name of the target volume backend + availability_zone_0: + type: string + description: availabilityzone name + cmaui_oam_ips: + type: list + description: CMAUI oam_net IP addresses + entry_schema: + type: string + external_dns: + type: string + description: dns server + oam_net_name: + type: string + description: UID of OAM network + external_ntp: + type: string + description: ntp server + CMAUI_volume_type: + type: string + description: the name of the target volume backend + attributes: + out_cmaui_volume: + type: string + requirements: + - local_storage_server_cmaui: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_cmaui_port_0: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + host_server_cmaui: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + os_server_cmaui: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + endpoint_server_cmaui: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + binding_server_cmaui: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + scalable_server_cmaui: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_volume: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_0: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/nested_with_inner_vol/out/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/nested_with_inner_vol/out/MainServiceTemplate.yaml new file mode 100644 index 0000000000..72b2c18882 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/nested_with_inner_vol/out/MainServiceTemplate.yaml @@ -0,0 +1,150 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + cmaui_cinder_volume_size: + label: CMAUI Cinder volume size + hidden: false + immutable: false + type: float + description: the size of the CMAUI Cinder volume + timezone: + label: timezone + hidden: false + immutable: false + type: string + description: timezone + security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + oam_network_netmask: + label: oam network netmask + hidden: false + immutable: false + type: string + description: oam network gateway + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + vnf_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-CMAUI_id + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + oam_network_gateway: + label: oam network gateway + hidden: false + immutable: false + type: string + description: oam network gateway + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + cmaui_oam_ips: + label: CMAUI oam_net IP addresses + hidden: false + immutable: false + type: list + description: CMAUI oam_net IP addresses + entry_schema: + type: string + external_dns: + label: dns server + hidden: false + immutable: false + type: string + description: dns server + oam_net_name: + hidden: false + immutable: false + type: string + description: UID of OAM network + external_ntp: + label: ntp server + hidden: false + immutable: false + type: string + description: ntp server + CMAUI_volume_type: + label: CMAUI vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + node_templates: + server_cmaui: + type: org.openecomp.resource.abstract.nodes.heat.nested + directives: + - substitutable + properties: + cmaui_names: + get_input: + - cmaui_names + - 0 + service_template_filter: + substitute_service_template: nestedServiceTemplate.yaml + cmaui_image: + get_input: cmaui_image + cmaui_flavor: + get_input: cmaui_flavor + availability_zone_0: + get_input: availability_zone_0 + groups: + main: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/main.yml + description: cmaui server template for vMMSC + members: + - server_cmaui \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/nested_with_inner_vol/out/nestedServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/nested_with_inner_vol/out/nestedServiceTemplate.yaml new file mode 100644 index 0000000000..242feead83 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/nested_with_inner_vol/out/nestedServiceTemplate.yaml @@ -0,0 +1,242 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + GlobalSubstitutionTypes: + file: GlobalSubstitutionTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + cmaui_cinder_volume_size: + label: CMAUI Cinder volume size + hidden: false + immutable: false + type: float + description: the size of the CMAUI Cinder volume + timezone: + label: timezone + hidden: false + immutable: false + type: string + description: timezone + security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + cmaui_volume: + label: CMAUI volume size + hidden: false + immutable: false + type: string + description: Volume for CMAUI server + oam_network_netmask: + label: oam network netmask + hidden: false + immutable: false + type: string + description: oam network gateway + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + vnf_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-CMAUI_id + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + oam_network_gateway: + label: oam network gateway + hidden: false + immutable: false + type: string + description: oam network gateway + out_cmaui_volume: + label: CMAUI vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + cmaui_oam_ips: + label: CMAUI oam_net IP addresses + hidden: false + immutable: false + type: list + description: CMAUI oam_net IP addresses + entry_schema: + type: string + external_dns: + label: dns server + hidden: false + immutable: false + type: string + description: dns server + oam_net_name: + hidden: false + immutable: false + type: string + description: UID of OAM network + external_ntp: + label: ntp server + hidden: false + immutable: false + type: string + description: ntp server + CMAUI_volume_type: + label: CMAUI vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + node_templates: + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + metadata: + vnf_id: + get_input: vnf_id + user_data_format: RAW + name: + get_input: + - cmaui_names + - 0 + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: cmaui_volume + relationship: cmaui_volume_attachment + cmaui_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: CMAUI_volume_type + size: '(get_input : cmaui_cinder_volume_size) * 1024' + cmaui_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + relationship_templates: + cmaui_volume_attachment: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: cmaui_volume + instance_uuid: server_cmaui + groups: + a_vol: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/a_vol.yml + description: volume + members: + - cmaui_volume + nested: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested.yml + description: cmaui server template for vMMSC + members: + - server_cmaui + - cmaui_port_0 + outputs: + out_cmaui_volume: + value: cmaui_volume + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested + capabilities: + host_server_cmaui: + - server_cmaui + - host + os_server_cmaui: + - server_cmaui + - os + endpoint_server_cmaui: + - server_cmaui + - endpoint + binding_server_cmaui: + - server_cmaui + - binding + scalable_server_cmaui: + - server_cmaui + - scalable + attachment_cmaui_volume: + - cmaui_volume + - attachment + attachment_cmaui_port_0: + - cmaui_port_0 + - attachment + requirements: + local_storage_server_cmaui: + - server_cmaui + - local_storage + link_cmaui_port_0: + - cmaui_port_0 + - link \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_and_attach_one_file/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_and_attach_one_file/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..25cae6bdeb --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_and_attach_one_file/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,194 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + cmaui_cinder_volume_size: + label: CMAUI Cinder volume size + hidden: false + immutable: false + type: float + description: the size of the CMAUI Cinder volume + timezone: + label: timezone + hidden: false + immutable: false + type: string + description: timezone + security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + server_cmaui: + label: CMAUI server name + hidden: false + immutable: false + type: string + description: the name of the cmaui server + oam_network_netmask: + label: oam network netmask + hidden: false + immutable: false + type: string + description: oam network gateway + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + vnf_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-CMAUI_id + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + oam_network_gateway: + label: oam network gateway + hidden: false + immutable: false + type: string + description: oam network gateway + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + cmaui_oam_ips: + label: CMAUI oam_net IP addresses + hidden: false + immutable: false + type: list + description: CMAUI oam_net IP addresses + entry_schema: + type: string + external_dns: + label: dns server + hidden: false + immutable: false + type: string + description: dns server + oam_net_name: + hidden: false + immutable: false + type: string + description: UID of OAM network + external_ntp: + label: ntp server + hidden: false + immutable: false + type: string + description: ntp server + CMAUI_volume_type: + label: CMAUI vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + node_templates: + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + metadata: + vnf_id: + get_input: vnf_id + user_data_format: RAW + name: + get_input: + - cmaui_names + - 0 + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: cmaui_volume + relationship: cmaui_volume_attachment + cmaui_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: CMAUI_volume_type + size: '(get_input : cmaui_cinder_volume_size) * 1024' + cmaui_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + relationship_templates: + cmaui_volume_attachment: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: cmaui_volume + instance_uuid: server_cmaui + groups: + hot_template: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/hot_template.yml + description: cmaui server template for vMMSC + members: + - server_cmaui + - cmaui_volume + - cmaui_port_0 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_and_attach_one_file/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_and_attach_one_file/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..b2916ccf9c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_and_attach_one_file/inputfiles/MANIFEST.json @@ -0,0 +1,11 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "hot_template.yml", + "type": "HEAT" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_and_attach_one_file/inputfiles/hot_template.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_and_attach_one_file/inputfiles/hot_template.yml new file mode 100644 index 0000000000..a0f9b45478 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_and_attach_one_file/inputfiles/hot_template.yml @@ -0,0 +1,131 @@ +heat_template_version: 2013-05-23 + +################################# +# +# Changes from MSO 01/26/2016 +# Updated per ECOMP feedback +# +################################# + +description: cmaui server template for vMMSC + +parameters: + vnf_id: + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-CMAUI_id + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_cinder_volume_size: + type: number + label: CMAUI Cinder volume size + description: the size of the CMAUI Cinder volume + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + oam_net_name: + type: string + description: UID of OAM network + oam_network_netmask: + type: string + label: oam network netmask + description: oam network gateway + oam_network_gateway: + type: string + label: oam network gateway + description: oam network gateway + external_dns: + type: string + label: dns server + description: dns server + external_ntp: + type: string + label: ntp server + description: ntp server + security_group_name: + type: string + label: security group name + description: the name of security group + timezone: + type: string + label: timezone + description: timezone + cmaui_oam_ips: + type: comma_delimited_list + label: CMAUI oam_net IP addresses + description: CMAUI oam_net IP addresses + CMAUI_volume_type: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + server_cmaui: + type: string + label: CMAUI server name + description: the name of the cmaui server + +resources: + + cmaui_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + cmaui_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: cmaui_cinder_volume_size} + volume_type: {get_param: CMAUI_volume_type} + + cmaui_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: cmaui_volume} + instance_uuid: {get_resource: server_cmaui} + + cmaui_volume_attachment_empty_nova: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_resource: cmaui_volume} + instance_uuid: {get_param: server_cmaui} + + server_cmaui: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_0 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + cmaui.mgmt.ip=${cmaui.mgmt.ip} + cmaui.mgmt.netmask=${cmaui.mgmt.netmask} + cmaui.mgmt.gateway=${cmaui.mgmt.gateway} + cmaui.external.dns=${cmaui.external.dns} + cmaui.external.ntp=${cmaui.external.ntp} + cmaui.node=${cmaui.node} + cmaui.timezone=${cmaui.timezone} + params: + ${cmaui.mgmt.ip}: {get_param: [cmaui_oam_ips, 0]} + ${cmaui.mgmt.netmask}: {get_param: oam_network_netmask} + ${cmaui.mgmt.gateway}: {get_param: oam_network_gateway} + ${cmaui.external.dns}: {get_param: external_dns} + ${cmaui.external.ntp}: {get_param: external_ntp} + ${cmaui.node}: {get_param: [cmaui_names, 0]} + ${cmaui.timezone}: {get_param: timezone} + user_data_format: RAW \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_file_nested_in_main_file_in_manifest/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_file_nested_in_main_file_in_manifest/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..0291368d24 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_file_nested_in_main_file_in_manifest/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,203 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + exposed_cmaui_volume: + label: CMAUI volume size + hidden: false + immutable: false + type: float + description: the size of the CMAUI volume + cmaui_cinder_volume_size: + label: CMAUI Cinder volume size + hidden: false + immutable: false + type: float + description: the size of the CMAUI Cinder volume + timezone: + label: timezone + hidden: false + immutable: false + type: string + description: timezone + security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + oam_network_netmask: + label: oam network netmask + hidden: false + immutable: false + type: string + description: oam network gateway + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + vnf_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-CMAUI_id + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + oam_network_gateway: + label: oam network gateway + hidden: false + immutable: false + type: string + description: oam network gateway + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + cmaui_oam_ips: + label: CMAUI oam_net IP addresses + hidden: false + immutable: false + type: list + description: CMAUI oam_net IP addresses + entry_schema: + type: string + external_dns: + label: dns server + hidden: false + immutable: false + type: string + description: dns server + oam_net_name: + hidden: false + immutable: false + type: string + description: UID of OAM network + external_ntp: + label: ntp server + hidden: false + immutable: false + type: string + description: ntp server + CMAUI_volume_type: + label: CMAUI vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + node_templates: + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + metadata: + vnf_id: + get_input: vnf_id + user_data_format: RAW + name: + get_input: + - cmaui_names + - 0 + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: cmaui_volume + relationship: cmaui_volume_attachment + cmaui_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: CMAUI_volume_type + size: '(get_input : cmaui_cinder_volume_size) * 1024' + cmaui_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + relationship_templates: + cmaui_volume_attachment: + type: org.openecomp.relationships.heat.cinder.VolumeAttachesTo + properties: + volume_id: cmaui_volume + instance_uuid: server_cmaui + groups: + a_vol: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/a_vol.yml + description: volume + members: + - cmaui_volume + hot_template: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/hot_template.yml + description: cmaui server template for vMMSC + members: + - server_cmaui + - cmaui_port_0 + outputs: + exposed_cmaui_volume: + value: cmaui_volume \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_file_nested_in_main_file_in_manifest/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_file_nested_in_main_file_in_manifest/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..5804dbdf5e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_file_nested_in_main_file_in_manifest/inputfiles/MANIFEST.json @@ -0,0 +1,19 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "hot_template.yml", + "type": "HEAT", + "isBase": "false", + "data":[ + { + "file": "a_vol.yml", + "type": "HEAT_VOL", + "isBase": "false" + } + ] + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_file_nested_in_main_file_in_manifest/inputfiles/a_vol.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_file_nested_in_main_file_in_manifest/inputfiles/a_vol.yml new file mode 100644 index 0000000000..78c2ee12c4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_file_nested_in_main_file_in_manifest/inputfiles/a_vol.yml @@ -0,0 +1,24 @@ +heat_template_version: 2013-05-23 + +description: volume + +parameters: + cmaui_cinder_volume_size: + type: number + label: CMAUI Cinder volume size + description: the size of the CMAUI Cinder volume + CMAUI_volume_type: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + +resources: + cmaui_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: cmaui_cinder_volume_size} + volume_type: {get_param: CMAUI_volume_type} + +outputs: + exposed_cmaui_volume: + value: {get_resource: cmaui_volume} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_file_nested_in_main_file_in_manifest/inputfiles/hot_template.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_file_nested_in_main_file_in_manifest/inputfiles/hot_template.yml new file mode 100644 index 0000000000..ead437747d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_file_nested_in_main_file_in_manifest/inputfiles/hot_template.yml @@ -0,0 +1,112 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + vnf_id: + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-CMAUI_id + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + exposed_cmaui_volume: + type: number + label: CMAUI volume size + description: the size of the CMAUI volume + cmaui_cinder_volume_size: + type: number + label: CMAUI Cinder volume size + description: the size of the CMAUI Cinder volume + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + oam_net_name: + type: string + description: UID of OAM network + oam_network_netmask: + type: string + label: oam network netmask + description: oam network gateway + oam_network_gateway: + type: string + label: oam network gateway + description: oam network gateway + external_dns: + type: string + label: dns server + description: dns server + external_ntp: + type: string + label: ntp server + description: ntp server + security_group_name: + type: string + label: security group name + description: the name of security group + timezone: + type: string + label: timezone + description: timezone + cmaui_oam_ips: + type: comma_delimited_list + label: CMAUI oam_net IP addresses + description: CMAUI oam_net IP addresses + CMAUI_volume_type: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + +resources: + + cmaui_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + cmaui_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_param: exposed_cmaui_volume} + instance_uuid: {get_resource: server_cmaui} + + server_cmaui: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_0 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + cmaui.mgmt.ip=${cmaui.mgmt.ip} + cmaui.mgmt.netmask=${cmaui.mgmt.netmask} + cmaui.mgmt.gateway=${cmaui.mgmt.gateway} + cmaui.external.dns=${cmaui.external.dns} + cmaui.external.ntp=${cmaui.external.ntp} + cmaui.node=${cmaui.node} + cmaui.timezone=${cmaui.timezone} + params: + ${cmaui.mgmt.ip}: {get_param: [cmaui_oam_ips, 0]} + ${cmaui.mgmt.netmask}: {get_param: oam_network_netmask} + ${cmaui.mgmt.gateway}: {get_param: oam_network_gateway} + ${cmaui.external.dns}: {get_param: external_dns} + ${cmaui.external.ntp}: {get_param: external_ntp} + ${cmaui.node}: {get_param: [cmaui_names, 0]} + ${cmaui.timezone}: {get_param: timezone} + user_data_format: RAW \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_file_parallel_to_main_file/expectedoutputfiles/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_file_parallel_to_main_file/expectedoutputfiles/MainServiceTemplate.yaml new file mode 100644 index 0000000000..09919379e0 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_file_parallel_to_main_file/expectedoutputfiles/MainServiceTemplate.yaml @@ -0,0 +1,189 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + ContrailComputeGlobalTypes: + file: ContrailComputeGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailPortGlobalTypes: + file: ContrailPortGlobalTypesServiceTemplate.yaml + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + ContrailAbstractSubstituteGlobalTypes: + file: ContrailAbstractSubstituteGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailV2VirtualMachineInterfaceGlobalType: + file: ContrailV2VirtualMachineInterfaceGlobalTypeServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: string + cmaui_cinder_volume_size: + label: CMAUI Cinder volume size + hidden: false + immutable: false + type: float + description: the size of the CMAUI Cinder volume + timezone: + label: timezone + hidden: false + immutable: false + type: string + description: timezone + security_group_name: + label: security group name + hidden: false + immutable: false + type: string + description: the name of security group + cmaui_volume: + label: CMAUI vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + oam_network_netmask: + label: oam network netmask + hidden: false + immutable: false + type: string + description: oam network gateway + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + vnf_id: + hidden: false + immutable: false + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-CMAUI_id + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + oam_network_gateway: + label: oam network gateway + hidden: false + immutable: false + type: string + description: oam network gateway + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + cmaui_oam_ips: + label: CMAUI oam_net IP addresses + hidden: false + immutable: false + type: list + description: CMAUI oam_net IP addresses + entry_schema: + type: string + external_dns: + label: dns server + hidden: false + immutable: false + type: string + description: dns server + oam_net_name: + hidden: false + immutable: false + type: string + description: UID of OAM network + external_ntp: + label: ntp server + hidden: false + immutable: false + type: string + description: ntp server + CMAUI_volume_type: + label: CMAUI vm volume type + hidden: false + immutable: false + type: string + description: the name of the target volume backend + node_templates: + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + metadata: + vnf_id: + get_input: vnf_id + user_data_format: RAW + name: + get_input: + - cmaui_names + - 0 + cmaui_volume: + type: org.openecomp.resource.vfc.nodes.heat.cinder.Volume + properties: + volume_type: + get_input: CMAUI_volume_type + size: '(get_input : cmaui_cinder_volume_size) * 1024' + cmaui_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: oam_net_name + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + groups: + a_vol: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/a_vol.yml + description: volume + members: + - cmaui_volume + hot_template: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/hot_template.yml + description: cmaui server template for vMMSC + members: + - server_cmaui + - cmaui_port_0 \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_file_parallel_to_main_file/inputfiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_file_parallel_to_main_file/inputfiles/MANIFEST.json new file mode 100644 index 0000000000..e35976356f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_file_parallel_to_main_file/inputfiles/MANIFEST.json @@ -0,0 +1,16 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create 2 cinder volume attachment", + "version": "2013-05-23", + "data": [ + { + "file": "hot_template.yml", + "isBase": true, + "type": "HEAT" + }, + { + "file": "a_vol.yml", + "type": "HEAT_VOL" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_file_parallel_to_main_file/inputfiles/a_vol.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_file_parallel_to_main_file/inputfiles/a_vol.yml new file mode 100644 index 0000000000..c32b9461eb --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_file_parallel_to_main_file/inputfiles/a_vol.yml @@ -0,0 +1,20 @@ +heat_template_version: 2013-05-23 + +description: volume + +parameters: + cmaui_cinder_volume_size: + type: number + label: CMAUI Cinder volume size + description: the size of the CMAUI Cinder volume + CMAUI_volume_type: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + +resources: + cmaui_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: cmaui_cinder_volume_size} + volume_type: {get_param: CMAUI_volume_type} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_file_parallel_to_main_file/inputfiles/hot_template.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_file_parallel_to_main_file/inputfiles/hot_template.yml new file mode 100644 index 0000000000..2d0ed3c426 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/services/heattotosca/vol_att/volume_file_parallel_to_main_file/inputfiles/hot_template.yml @@ -0,0 +1,112 @@ +heat_template_version: 2013-05-23 + +description: cmaui server template for vMMSC + +parameters: + vnf_id: + type: string + description: Unique ID for this VNF instance + default: This_is_ths_MMSC-CMAUI_id + cmaui_names: + type: comma_delimited_list + description: CMAUI1, CMAUI2 server names + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + cmaui_cinder_volume_size: + type: number + label: CMAUI Cinder volume size + description: the size of the CMAUI Cinder volume + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + oam_net_name: + type: string + description: UID of OAM network + oam_network_netmask: + type: string + label: oam network netmask + description: oam network gateway + oam_network_gateway: + type: string + label: oam network gateway + description: oam network gateway + external_dns: + type: string + label: dns server + description: dns server + external_ntp: + type: string + label: ntp server + description: ntp server + security_group_name: + type: string + label: security group name + description: the name of security group + timezone: + type: string + label: timezone + description: timezone + cmaui_oam_ips: + type: comma_delimited_list + label: CMAUI oam_net IP addresses + description: CMAUI oam_net IP addresses + CMAUI_volume_type: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + cmaui_volume: + type: string + label: CMAUI vm volume type + description: the name of the target volume backend + +resources: + + cmaui_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: oam_net_name } + fixed_ips: [{"ip_address": {get_param: [cmaui_oam_ips, 0]}}] + security_groups: [{get_param: security_group_name}] + replacement_policy: AUTO + + cmaui_volume_attachment: + type: OS::Cinder::VolumeAttachment + properties: + volume_id: {get_param: cmaui_volume} + instance_uuid: {get_resource: server_cmaui} + + server_cmaui: + type: OS::Nova::Server + properties: + name: { get_param: [cmaui_names, 0]} + image: { get_param: cmaui_image } + availability_zone: { get_param: availability_zone_0 } + flavor: { get_param: cmaui_flavor } + networks: + - port: { get_resource: cmaui_port_0 } + metadata: + vnf_id: { get_param: vnf_id } + user_data: + str_replace: + template: | + cmaui.mgmt.ip=${cmaui.mgmt.ip} + cmaui.mgmt.netmask=${cmaui.mgmt.netmask} + cmaui.mgmt.gateway=${cmaui.mgmt.gateway} + cmaui.external.dns=${cmaui.external.dns} + cmaui.external.ntp=${cmaui.external.ntp} + cmaui.node=${cmaui.node} + cmaui.timezone=${cmaui.timezone} + params: + ${cmaui.mgmt.ip}: {get_param: [cmaui_oam_ips, 0]} + ${cmaui.mgmt.netmask}: {get_param: oam_network_netmask} + ${cmaui.mgmt.gateway}: {get_param: oam_network_gateway} + ${cmaui.external.dns}: {get_param: external_dns} + ${cmaui.external.ntp}: {get_param: external_ntp} + ${cmaui.node}: {get_param: [cmaui_names, 0]} + ${cmaui.timezone}: {get_param: timezone} + user_data_format: RAW \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/testManifestFormat.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/testManifestFormat.json new file mode 100644 index 0000000000..38073c6742 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/testManifestFormat.json @@ -0,0 +1,59 @@ +{ + "name": "vSRX", + "description": "juniper firewall", + "version": "0.1", + "data": [ + { + "file": "vSRX.yml", + "type": "HEAT", + "data": [ + { + "file": "bella.env", + "type": "HEAT_ENV" + }, + { + "file": "im_network_heat.yml", + "type": "HEAT_NET" + }, + { + "file": "im_volume_heat.yml", + "type": "HEAT_VOL" + } + ] + }, + { + "file": "im_nested_heat.yml", + "type": "HEAT", + "data": [{ + "file": "alpha.env", + "type": "HEAT_ENV" + }] + }, + { + "file": "vSRX_VM.yml", + "type": "HEAT", + "data": [ + { + "file": "bella_vm.env", + "type": "HEAT_ENV" + }, + { + "file": "im_network_heat.yml", + "type": "HEAT_NET", + "data": [{ + "file": "mika.env", + "type": "HEAT_ENV" + }] + }, + { + "file": "im_volume_heat.yml", + "type": "HEAT_VOL" + } + ] + }, + { + "file": "im_artifact.yml", + "type": "CHEF" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/vmme_small_create_fsb/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/vmme_small_create_fsb/MANIFEST.json new file mode 100644 index 0000000000..02733a6e3f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/vmme_small_create_fsb/MANIFEST.json @@ -0,0 +1,29 @@ +{ + "name": "vMME_Small", + "description": "HOT template to create vmme 2 fsb 2 ncb 2 gbp 2 vlc", + "version": "2013-05-23", + "data": [ + { + "file": "vmme_small.yml", + "type": "HEAT", + "data": [ + { + "file": "vmme_small.env", + "type": "HEAT_ENV" + },{ + "file": "vmme_small_create_fsb.yml", + "type": "HEAT_NET", + "data":[ + { + "file": "vmme_small_create_fsb.env", + "type": "HEAT_ENV" + } + ] + } + ] + },{ + "file": "create_stack.sh", + "type": "SHELL" + } + ] +} diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/vmme_small_create_fsb/create_stack.sh b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/vmme_small_create_fsb/create_stack.sh new file mode 100644 index 0000000000..186d1c34fb --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/vmme_small_create_fsb/create_stack.sh @@ -0,0 +1 @@ +heat stack-create vMME -e vmme_small.env -f vmme_small.yml diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/vmme_small_create_fsb/vmme_small.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/vmme_small_create_fsb/vmme_small.env new file mode 100644 index 0000000000..e46cfd2a2d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/vmme_small_create_fsb/vmme_small.env @@ -0,0 +1,97 @@ +parameters: + oam_net_id: 47bf4cca-0961-422f-bcd6-d5a4fbb1a351 + fsb1-name: ZRDM1MMEX33FSB001 + fsb2-name: ZRDM1MMEX33FSB002 + ncb1-name: ZRDM1MMEX33NCB001 + ncb2-name: ZRDM1MMEX33NCB002 + vlc1-name: ZRDM1MMEX33VLC002 + vlc2-name: ZRDM1MMEX33VLC002 + gpb1-name: ZRDM1MMEX33GPB001 + gpb2-name: ZRDM1MMEX33GPB002 + epc-sctp-a-net-name: EPC-SCTP-A + epc-sctp-a-net-rt: 13979:105717 + epc-sctp-a-net-cidr: 107.243.37.0/27 + epc-sctp-a-net-gateway: 107.243.37.1 + epc-sctp-a-pool-start: 107.243.37.3 + epc-sctp-a-pool-end: 107.243.37.30 + epc-sctp-b-net-name: EPC-SCTP-B + epc-sctp-b-net-rt: 13979:105719 + epc-sctp-b-net-cidr: 107.243.37.32/24 + epc-sctp-b-net-gateway: 107.243.37.33 + epc-sctp-b-pool-start: 107.243.37.35 + epc-sctp-b-pool-end: 107.243.37.62 + epc-gtp-net-name: EPC-GTP + epc-gtp-net-rt: 13979:105715 + epc-gtp-net-cidr: 107.243.37.64/27 + epc-gtp-net-gateway: 107.243.37.65 + epc-gtp-pool-start: 107.243.37.67 + epc-gtp-pool-end: 107.243.37.94 + fsb1-image: MME_FSB1_15B-CP04-r5a01 + fsb2-image: MME_FSB2_15B-CP04-r5a01 + fsb1-flavor: m4.xlarge4 + fsb2-flavor: m4.xlarge4 + fsb_zone: nova + fsb1-Internal1-mac: 00:80:37:0E:0B:12 + fsb1-Internal2-mac: 00:81:37:0E:0B:12 + fsb1-oam-ip: 107.250.172.221 + fsb2-Internal1-mac: 00:80:37:0E:0D:12 + fsb2-Internal2-mac: 00:81:37:0E:0D:12 + fsb2-oam-ip: 107.250.172.222 + pxe-image: MME_PXE-BOOT_cxp9025898_2r5a01.qcow2 + ncb-flavor: m4.xlarge4 + ncb_zone: nova + ncb1-Internal1-mac: 00:80:37:0E:09:12 + ncb1-Internal2-mac: 00:81:37:0E:09:12 + ncb2-Internal1-mac: 00:80:37:0E:0F:12 + ncb2-Internal2-mac: 00:81:37:0E:0F:12 + gpb-flavor: m4.xlarge4 + gpb_zone: nova + gpb1-Internal1-mac: 00:80:37:0E:01:22 + gpb1-Internal1-ip: 169.254.0.101 + gpb1-Internal2-mac: 00:81:37:0E:01:22 + gpb2-Internal1-mac: 00:80:37:0E:02:22 + gpb2-Internal2-mac: 00:81:37:0E:02:22 + vlc-flavor: m4.xlarge4 + vlc_zone: nova + vlc1-sctp-a-ip: 107.243.37.3 + vlc1-sctp-b-ip: 107.243.37.35 + vlc1-gtp-ip: 107.243.37.67 + vlc1-oam-ip: 107.250.172.227 + vlc2-sctp-a-ip: 107.243.37.4 + vlc2-sctp-b-ip: 107.243.37.36 + vlc2-gtp-ip: 107.243.37.68 + vlc2-oam-ip: 107.250.172.228 + vlc1-Internal1-mac: 00:80:37:0E:01:12 + vlc1-Internal2-mac: 00:81:37:0E:01:12 + vlc2-Internal1-mac: 00:80:37:0E:02:12 + vlc2-Internal2-mac: 00:81:37:0E:02:12 + Internal1_net_name: vmme_int_int_1 + Internal1_subnet_name: vmme_int_int_sub_1 + Internal1_ipam_name: vmme_ipam_int1 + Internal1_cidr: 169.253.0.0/17 + Internal1_forwarding_mode: "l2" + Internal1_dhcp: "False" + Internal1_shared: "False" + Internal1_external: "False" + Internal1_name: "Internal1-subnet" + Internal1_default_gateway: 169.253.0.3 + Internal1_net_pool_start: 169.253.0.100 + Internal1_net_pool_end: 169.253.0.254 + Internal2_net_name: vmme_int_int_2 + Internal2_subnet_name: vmme_int_int_sub_2 + Internal2_ipam_name: vmme_ipam_int2 + Internal2_cidr: 169.255.0.0/17 + Internal2_shared: "False" + Internal2_external: "False" + Internal2_forwarding_mode: "l2" + Internal2_dhcp: "False" + Internal2_name: "Internal2-subnet" + Internal2_default_gateway: 169.255.0.3 + Internal2_net_pool_start: 169.255.0.100 + Internal2_net_pool_end: 169.255.0.254 + static_prefix_sctp_a_1: 107.239.40.32/30 + static_prefix_gtp_1: 107.239.40.96/30 + static_prefix_sctp_b_1: 107.239.40.64/30 + VMME_FSB1_boot_volume: 8248e794-6173-4b49-b9c3-8219b0b56f4e + VMME_FSB2_boot_volume: 089a0d11-4b15-4370-8343-3f90907b1221 + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/vmme_small_create_fsb/vmme_small.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/vmme_small_create_fsb/vmme_small.yml new file mode 100644 index 0000000000..1050166050 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/vmme_small_create_fsb/vmme_small.yml @@ -0,0 +1,676 @@ +heat_template_version: 2013-05-23 + +description: > + HOT template to create vmme 2 fsb 2 ncb 2 gbp 2 vlc + +parameters: + fsb1-oam-ip: + type: string + fsb2-oam-ip: + type: string + vlc1-oam-ip: + type: string + vlc2-oam-ip: + type: string + Internal1_net_pool_start: + type: string + Internal1_net_pool_end: + type: string + Internal2_net_pool_start: + type: string + Internal2_net_pool_end: + type: string + Internal1_default_gateway: + type: string + Internal2_default_gateway: + type: string + Internal1_shared: + type: string + Internal1_external: + type: string + Internal1_net_name: + type: string + Internal1_subnet_name: + type: string + Internal1_ipam_name: + type: string + Internal1_cidr: + type: string + Internal1_forwarding_mode: + type: string + Internal1_dhcp: + type: string + Internal1_name: + type: string + Internal2_net_name: + type: string + Internal2_subnet_name: + type: string + Internal2_ipam_name: + type: string + Internal2_cidr: + type: string + Internal2_forwarding_mode: + type: string + Internal2_dhcp: + type: string + Internal2_name: + type: string + Internal2_shared: + type: string + Internal2_external: + type: string + vlc1-sctp-a-ip: + type: string + vlc1-sctp-b-ip: + type: string + vlc1-gtp-ip: + type: string + vlc2-sctp-a-ip: + type: string + vlc2-sctp-b-ip: + type: string + vlc2-gtp-ip: + type: string + fsb1-name: + type: string + description: Name of fsb1 + fsb2-name: + type: string + description: Name of fsb1 + ncb1-name: + type: string + description: Name of ncb1 + ncb2-name: + type: string + description: Name of ncb2 + vlc1-name: + type: string + description: Name of vlc1 + vlc2-name: + type: string + description: Name of vlc2 + gpb1-name: + type: string + description: Name of gpb1 + gpb2-name: + type: string + description: Name of gpb2 + fsb_zone: + type: string + description: cluster for spawnning fsb instances + fsb1-image: + type: string + description: Name of image to use for server fsb1 + fsb1-flavor: + type: string + description: Flavor to use for servers fsb1 + oam_net_id: + type: string + description: uuid of oam network + fsb1-Internal1-mac: + type: string + description: static mac address assigned to fsb1-Internal1 + fsb1-Internal2-mac: + type: string + description: static mac address assigned to fsb1-Internal2 + fsb2-image: + type: string + description: Name of image to use for server fsb2 + fsb2-flavor: + type: string + description: Flavor to use for servers fsb2 + fsb2-Internal1-mac: + type: string + description: static mac address assigned to fsb2-Internal1 + fsb2-Internal2-mac: + type: string + description: static mac address assigned to fsb2-Internal2 + pxe-image: + type: string + description: Name of image to use for server ncb + ncb-flavor: + type: string + description: Flavor to use for servers ncb + ncb_zone: + type: string + description: cluster for spawnning ncb instances + ncb1-Internal1-mac: + type: string + description: static mac address assigned to ncb1-Internal1 + ncb1-Internal2-mac: + type: string + description: static mac address assigned to ncb1-Internal2 + ncb2-Internal1-mac: + type: string + description: static mac address assigned to ncb2-Internal1 + ncb2-Internal2-mac: + type: string + description: static mac address assigned to ncb2-Internal2 + gpb-flavor: + type: string + description: Flavor to use for servers gpb + gpb_zone: + type: string + description: cluster for spawnning gpb instances + gpb1-Internal1-ip: + type: string + gpb1-Internal1-mac: + type: string + description: static mac address assigned to gpb1-Internal1 + gpb1-Internal2-mac: + type: string + description: static mac address assigned to gpb1-Internal2 + gpb2-Internal1-mac: + type: string + description: static mac address assigned to gpb2-Internal1 + gpb2-Internal2-mac: + type: string + description: static mac address assigned to gpb2-Internal2 + vlc-flavor: + type: string + description: Flavor to use for servers vlc + vlc_zone: + type: string + description: cluster for spawnning vlc instances + vlc1-Internal1-mac: + type: string + description: static mac address assigned to vlc1-Internal1 + vlc1-Internal2-mac: + type: string + description: static mac address assigned to vlc1-Internal2 + vlc2-Internal1-mac: + type: string + description: static mac address assigned to vlc2-Internal1 + vlc2-Internal2-mac: + type: string + description: static mac address assigned to vlc2-Internal2 + epc-sctp-a-net-name: + type: string + description: epc-sctp-a net name + epc-sctp-a-net-rt: + type: string + description: epc-sctp-a route target + epc-sctp-a-net-cidr: + type: string + description: epc-sctp-a subnet + epc-sctp-a-net-gateway: + type: string + description: epc-sctp-a-net network gateway + epc-sctp-a-pool-start: + type: string + description: epc-sctp-a-net network ip pool start IP address + epc-sctp-a-pool-end: + type: string + description: epc-sctp-a-net network ip pool end IP address + epc-sctp-b-net-name: + type: string + description: epc-sctp-b net name + epc-sctp-b-net-rt: + type: string + description: epc-sctp-b route target + epc-sctp-b-net-cidr: + type: string + description: epc-sctp-b subnet + epc-sctp-b-net-gateway: + type: string + description: epc-sctp-b-net network gateway + epc-sctp-b-pool-start: + type: string + description: epc-sctp-b-net network ip pool start IP address + epc-sctp-b-pool-end: + type: string + description: epc-sctp-b-net network ip pool end IP address + epc-gtp-net-name: + type: string + description: gtp net name + epc-gtp-net-rt: + type: string + description: gtp route target + epc-gtp-net-cidr: + type: string + description: gtp stubnet + epc-gtp-net-gateway: + type: string + description: gtp network gateway + epc-gtp-pool-start: + type: string + description: gtp network ip pool start IP address + epc-gtp-pool-end: + type: string + description: gtp network ip pool end IP address + static_prefix_sctp_a_1: + type: string + description: Static Prefix + static_prefix_sctp_b_1: + type: string + description: Static Prefix + static_prefix_gtp_1: + type: string + description: Static Prefix + VMME_FSB1_boot_volume: + type: string + VMME_FSB2_boot_volume: + type: string + +resources: + FSB1_volume: + type: OS::Cinder::Volume + properties: + size: 3 + volume_type: {get_param: volume_type} + name: {get_param: FSB1_volume_name} + image: {get_param: FSB_1_image} + + FSB2_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: volume_size} + volume_type: {get_param: volume_type} + name: {get_param: FSB2_volume_name} + image: {get_param: FSB_2_image} + + Internal1_ipam: + type: OS::Contrail::NetworkIpam + properties: + name: { get_param: Internal1_ipam_name } + + Internal2_ipam: + type: OS::Contrail::NetworkIpam + properties: + name: { get_param: Internal2_ipam_name } + + Internal1-net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: Internal1_net_name } + forwarding_mode: { get_param: Internal1_forwarding_mode } + shared: { get_param: Internal1_shared } + external: true +# route_targets: { "Fn::Split" : [ ",", Ref: route_targets ] } + testConvertGetParamFunctions: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: Internal1_net_name } + forwarding_mode: { get_param: Internal1_forwarding_mode } + shared: { get_param: Internal1_shared } + external: { get_param: [my_instance, networks, private, 0] } +# route_targets: { "Fn::Split" : [ ",", Ref: route_targets ] } + testConvertGetAttributeFunctions: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: Internal1_net_name } + forwarding_mode: { get_param: Internal1_forwarding_mode } + shared: { get_param: Internal1_shared } + external: { get_param: Internal1_external } +# route_targets: { "Fn::Split" : [ ",", Ref: route_targets ] } + + Internal1-subnet: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: Internal1-net } + cidr: { get_param: Internal1_cidr } + gateway_ip: { get_param: Internal1_default_gateway } + enable_dhcp: { get_param: Internal1_dhcp } + + +# Internal1-subnet: +# type: OS::Contrail::VnSubnet +# properties: +# name: { get_param: Internal1_subnet_name } +# network: { get_resource: Internal1-net } +# ip_prefix: { get_param: Internal1_cidr } + # ipam: { get_resource: Internal1_ipam } + # enable_dhcp: { get_param: Internal1_dhcp } + # default_gateway: { get_param: Internal1_default_gateway } + # allocation_pools: + # - start: { get_param: Internal1_net_pool_start } + # end: { get_param: Internal1_net_pool_end } + + + + Internal2-net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: Internal2_name } + forwarding_mode: { get_param: Internal2_forwarding_mode } + shared: { get_param: Internal2_shared } + external: { get_param: Internal2_external } +# route_targets: { "Fn::Split" : [ ",", Ref: route_targets ] } + +# Internal2-subnet: +# type: OS::Contrail::VnSubnet +# properties: +# name: { get_param: Internal2_subnet_name } +# network: { get_resource: Internal2-net } +# ip_prefix: { get_param: Internal2_cidr } +# ipam: { get_resource: Internal2_ipam } +# enable_dhcp: { get_param: Internal2_dhcp } +# default_gateway: { get_param: Internal2_default_gateway } +# allocation_pools: +# - start: { get_param: Internal2_net_pool_start } +# end: { get_param: Internal2_net_pool_end } + + Internal2-subnet: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: Internal2-net } + cidr: { get_param: Internal2_cidr } + gateway_ip: { get_param: Internal2_default_gateway } + enable_dhcp: { get_param: Internal2_dhcp } + + epc-sctp-a-net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: epc-sctp-a-net-name } + route_targets: [ get_param: epc-sctp-a-net-rt ] + + + epc-sctp-a-subnet: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: epc-sctp-a-net } + cidr: { get_param: epc-sctp-a-net-cidr } + gateway_ip: { get_param: epc-sctp-a-net-gateway } + allocation_pools: + - start: { get_param: epc-sctp-a-pool-start } + end: { get_param: epc-sctp-a-pool-end } + + epc-sctp-b-net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: epc-sctp-b-net-name } + route_targets: [ get_param: epc-sctp-b-net-rt ] + + epc-sctp-b-subnet: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: epc-sctp-b-net } + cidr: { get_param: epc-sctp-b-net-cidr } + gateway_ip: { get_param: epc-sctp-b-net-gateway } + allocation_pools: + - start: { get_param: epc-sctp-b-pool-start } + end: { get_param: epc-sctp-b-pool-end } + + epc-gtp-net: + type: OS::Contrail::VirtualNetwork + properties: + name: { get_param: epc-gtp-net-name } + route_targets: [ get_param: epc-gtp-net-rt ] + + epc-gtp-subnet: + type: OS::Neutron::Subnet + properties: + network_id: { get_resource: epc-gtp-net } + cidr: { get_param: epc-gtp-net-cidr } + gateway_ip: { get_param: epc-gtp-net-gateway } + allocation_pools: + - start: { get_param: epc-gtp-pool-start } + end: { get_param: epc-gtp-pool-end } + + FSB1: + type: OS::Nova::Server + properties: + name: { get_param: fsb1-name } + block_device_mapping: [{device_name: "vda", volume_id : {get_param: VMME_FSB1_boot_volume }, delete_on_termination: "false" }] + flavor: { get_param: fsb1-flavor } + availability_zone: { get_param: fsb_zone } + networks: + - port: { get_resource: FSB1_Internal1 } + - port: { get_resource: FSB1_Internal2 } + - port: { get_resource: FSB1_OAM } + + FSB1_Internal1: + type: OS::Neutron::Port + properties: + network_id: { get_resource: Internal1-net } + mac_address: { get_param: fsb1-Internal1-mac } + + FSB1_Internal2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: Internal2-net } + mac_address: { get_param: fsb1-Internal2-mac } + + FSB1_OAM: + type: OS::Neutron::Port + properties: + network_id: { get_param: oam_net_id } + fixed_ips: + - ip_address: { get_param: fsb1-oam-ip } + + FSB2: + type: OS::Nova::Server + properties: + name: { get_param: fsb2-name } + block_device_mapping: [{device_name: "vda", volume_id : {get_param: VMME_FSB2_boot_volume }, delete_on_termination: "false" }] + flavor: { get_param: fsb2-flavor } + availability_zone: { get_param: fsb_zone } + networks: + - port: { get_resource: FSB2_Internal1 } + - port: { get_resource: FSB2_Internal2 } + - port: { get_resource: FSB2_OAM } + + FSB2_Internal1: + type: OS::Neutron::Port + properties: + network_id: { get_resource: Internal1-net } + mac_address: { get_param: fsb2-Internal1-mac } + + + FSB2_Internal2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: Internal2-net } + mac_address: { get_param: fsb2-Internal2-mac } + + FSB2_OAM: + type: OS::Neutron::Port + properties: + network_id: { get_param: oam_net_id } + fixed_ips: + - ip_address: { get_param: fsb2-oam-ip } + + NCB1: + type: OS::Nova::Server + properties: + name: { get_param: ncb1-name } + image: { get_param: pxe-image } + flavor: { get_param: ncb-flavor } + availability_zone: { get_param: ncb_zone } + networks: + - port: { get_resource: NCB1_Internal1 } + - port: { get_resource: NCB1_Internal2 } + + NCB1_Internal1: + type: OS::Neutron::Port + properties: + network_id: { get_resource: Internal1-net } + mac_address: { get_param: ncb1-Internal1-mac } + + NCB1_Internal2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: Internal2-net } + mac_address: { get_param: ncb1-Internal2-mac } + + NCB2: + type: OS::Nova::Server + properties: + name: { get_param: ncb2-name } + image: { get_param: pxe-image } + flavor: { get_param: ncb-flavor } + availability_zone: { get_param: ncb_zone } + networks: + - port: { get_resource: NCB2_Internal1 } + - port: { get_resource: NCB2_Internal2 } + + NCB2_Internal1: + type: OS::Neutron::Port + properties: + network_id: { get_resource: Internal1-net } + mac_address: { get_param: ncb2-Internal1-mac } + + NCB2_Internal2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: Internal2-net } + mac_address: { get_param: ncb2-Internal2-mac } + + GPB1: + type: OS::Nova::Server + properties: + name: { get_param: gpb1-name } + image: gpb_image + flavor: { get_param: gpb-flavor } + availability_zone: { get_param: gpb_zone } + networks: + - port: { get_resource: GPB1_Internal1 } + - port: { get_resource: GPB1_Internal2 } + + GPB1_Internal1: + type: OS::Neutron::Port + properties: + network_id: { get_resource: Internal1-net } + mac_address: { get_param: gpb1-Internal1-mac } + + GPB1_Internal2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: Internal2-net } + mac_address: { get_param: gpb1-Internal2-mac } + + GPB2: + type: OS::Nova::Server + properties: + name: { get_param: gpb2-name } + image: { get_param: pxe-image } + flavor: { get_param: gpb-flavor } + availability_zone: { get_param: gpb_zone } + networks: + - port: { get_resource: GPB2_Internal1 } + - port: { get_resource: GPB2_Internal2 } + + GPB2_Internal1: + type: OS::Neutron::Port + properties: + network_id: { get_resource: Internal1-net } + mac_address: { get_param: gpb2-Internal1-mac } + + GPB2_Internal2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: Internal2-net } + mac_address: { get_param: gpb2-Internal2-mac } + + VLC1: + type: OS::Nova::Server + properties: + name: { get_param: vlc1-name } + image: { get_param: pxe-image } + flavor: { get_param: vlc-flavor } + availability_zone: { get_param: vlc_zone } + networks: + - port: { get_resource: VLC1_Internal1 } + - port: { get_resource: VLC1_Internal2 } + - port: { get_resource: VLC1_OAM } + - port: { get_resource: VLC1_SCTP_A } + - port: { get_resource: VLC1_SCTP_B } + - port: { get_resource: VLC1_GTP } + + VLC1_Internal1: + type: OS::Neutron::Port + properties: + network_id: { get_resource: Internal1-net } + mac_address: { get_param: vlc1-Internal1-mac } + + VLC1_Internal2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: Internal2-net } + mac_address: { get_param: vlc1-Internal2-mac } + + VLC1_OAM: + type: OS::Neutron::Port + properties: + network_id: { get_param: oam_net_id } + fixed_ips: + - ip_address: { get_param: vlc1-oam-ip } + + VLC1_SCTP_A: + type: OS::Neutron::Port + properties: + network_id: { get_resource: epc-sctp-a-net } + fixed_ips: + - ip_address: { get_param: vlc1-sctp-a-ip } + + VLC1_SCTP_B: + type: OS::Neutron::Port + properties: + network_id: { get_resource: epc-sctp-b-net } + fixed_ips: + - ip_address: { get_param: vlc1-sctp-b-ip } + + VLC1_GTP: + type: OS::Neutron::Port + properties: + network_id: { get_resource: epc-gtp-net } + fixed_ips: + - ip_address: { get_param: vlc1-gtp-ip } + + VLC2: + type: OS::Nova::Server + properties: + name: { get_param: vlc2-name } + image: { get_param: pxe-image } + flavor: { get_param: vlc-flavor } + availability_zone: { get_param: vlc_zone } + networks: + - port: { get_resource: VLC2_Internal1 } + - port: { get_resource: VLC2_Internal2 } + - port: { get_resource: VLC2_OAM } + - port: { get_resource: VLC2_SCTP_A } + - port: { get_resource: VLC2_SCTP_B } + - port: { get_resource: VLC2_GTP } + + + VLC2_Internal1: + type: OS::Neutron::Port + properties: + network_id: { get_resource: Internal1-net } + mac_address: { get_param: vlc2-Internal1-mac } + + VLC2_OAM: + type: OS::Neutron::Port + properties: + network_id: { get_param: oam_net_id } + fixed_ips: + - ip_address: { get_param: vlc2-oam-ip } + + VLC2_Internal2: + type: OS::Neutron::Port + properties: + network_id: { get_resource: Internal2-net } + mac_address: { get_param: vlc2-Internal2-mac } + + VLC2_SCTP_A: + type: OS::Neutron::Port + properties: + network_id: { get_resource: epc-sctp-a-net } + fixed_ips: + - ip_address: { get_param: vlc2-sctp-a-ip } + + VLC2_SCTP_B: + type: OS::Neutron::Port + properties: + network_id: { get_resource: epc-sctp-b-net } + fixed_ips: + - ip_address: { get_param: vlc2-sctp-b-ip } + + VLC2_GTP: + type: OS::Neutron::Port + properties: + network_id: { get_resource: epc-gtp-net } + fixed_ips: + - ip_address: { get_param: vlc2-gtp-ip } + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/vmme_small_create_fsb/vmme_small_create_fsb.env b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/vmme_small_create_fsb/vmme_small_create_fsb.env new file mode 100644 index 0000000000..750bb2dd44 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/vmme_small_create_fsb/vmme_small_create_fsb.env @@ -0,0 +1,8 @@ +parameters: + volume_type: Gold + volume_size: 320 + FSB_1_image: MME_FSB1_15B-CP04-r5a01 + FSB_2_image: MME_FSB2_15B-CP04-r5a01 + FSB1_volume_name: vFSB1_1_Vol_1 + FSB2_volume_name: vFSB2_1_Vol_1 + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/vmme_small_create_fsb/vmme_small_create_fsb.yml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/vmme_small_create_fsb/vmme_small_create_fsb.yml new file mode 100644 index 0000000000..2d695a50c1 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/vmme_small_create_fsb/vmme_small_create_fsb.yml @@ -0,0 +1,54 @@ +heat_template_version: 2013-05-23 + +description: server template for vMME + +parameters: + + volume_type: + type: string + label: volume type + description: volume type Gold + + volume_size: + type: number + label: volume size + description: my volume size 320GB + + FSB_1_image: + type: string + label: MME_FSB1 + description: MME_FSB1_15B-CP04-r5a01 + + FSB_2_image: + type: string + label: MME_FSB2 + description: MME_FSB2_15B-CP04-r5a01 + + FSB1_volume_name: + type: string + label: FSB1_volume + description: FSB1_volume_1 + + FSB2_volume_name: + type: string + label: FSB2_volume + description: FSB2_volume_1 + +resources: + + FSB1_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: volume_size} + volume_type: {get_param: volume_type} + name: {get_param: FSB1_volume_name} + image: {get_param: FSB_1_image} + + FSB2_volume: + type: OS::Cinder::Volume + properties: + size: {get_param: volume_size} + volume_type: {get_param: volume_type} + name: {get_param: FSB2_volume_name} + image: {get_param: FSB_2_image} + diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/pom.xml b/openecomp-be/lib/openecomp-sdc-translator-lib/pom.xml new file mode 100644 index 0000000000..6fec777238 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/pom.xml @@ -0,0 +1,37 @@ + + 4.0.0 + + pom + + openecomp-sdc-lib + org.openecomp.sdc + 1.0.0-SNAPSHOT + + + openecomp-sdc-translator-lib + openecomp-sdc-translator-lib + + + openecomp-sdc-translator-api + openecomp-sdc-translator-core + + + + + org.openecomp.sdc + openecomp-sdc-translator-api + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-translator-core + ${project.version} + + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/pom.xml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/pom.xml new file mode 100644 index 0000000000..4f92b644c4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/pom.xml @@ -0,0 +1,38 @@ + + 4.0.0 + + + org.openecomp.sdc + openecomp-sdc-lib + 1.0.0-SNAPSHOT + ../.. + + + openecomp-sdc-validation-api + openecomp-sdc-validation-api + + + + org.openecomp.core + openecomp-facade-core + ${project.version} + + + io.swagger + swagger-annotations + 1.5.3 + + + org.openecomp.sdc + openecomp-sdc-datatypes-lib + ${project.version} + + + ch.qos.logback + logback-classic + 1.1.2 + + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/api/ValidationManager.java b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/api/ValidationManager.java new file mode 100644 index 0000000000..d18af3a27b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/api/ValidationManager.java @@ -0,0 +1,35 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.validation.api; + + +import org.openecomp.sdc.datatypes.error.ErrorMessage; + +import java.util.List; +import java.util.Map; + +public interface ValidationManager { + + Map> validate(); + + void addFile(String fileName, byte[] validationContent); + +} diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/errors/ErrorMessagesFormatBuilder.java b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/errors/ErrorMessagesFormatBuilder.java new file mode 100644 index 0000000000..210ce76c41 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/errors/ErrorMessagesFormatBuilder.java @@ -0,0 +1,30 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.validation.errors; + +public class ErrorMessagesFormatBuilder { + + public static String getErrorWithParameters(String error, String... params) { + return String.format(error, params); + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/errors/Messages.java b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/errors/Messages.java new file mode 100644 index 0000000000..bca4e820a9 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/errors/Messages.java @@ -0,0 +1,117 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.validation.errors; + +public enum Messages { + INVALID_ZIP_FILE("Invalid zip file"), + /* upload errors */ + + //NO_ZIP_UPLOADED("No zip file was uploaded or zip file doesn't exist"), + ZIP_SHOULD_NOT_CONTAIN_FOLDERS("Zip file should not contain folders"), + MANIFEST_NOT_EXIST("Manifest doesn't exist"), + NO_ZIP_FILE_WAS_UPLOADED_OR_ZIP_NOT_EXIST("no zip file was uploaded or zip file doesn't exist"), + + + /* manifest errors*/ + MISSING_FILE_IN_ZIP("Missing file in zip"), + MISSING_FILE_IN_MANIFEST("Missing file in manifest"), + MISSING_FILE_NAME_IN_MANIFEST("Missing file name in manifest - %s"), + MISSING_NESTED_FILE("Missing nested file - %s"), + MISSING_ARTIFACT("Missing artifact - %s"), + WRONG_HEAT_FILE_EXTENSION("Wrong HEAT file extension - %s"), + WRONG_ENV_FILE_EXTENSION("Wrong ENV file extension - %s"), + INVALID_MANIFEST_FILE("invalid manifest file"), + INVALID_FILE_TYPE("Missing or Unknown file type in Manifest"), + ENV_NOT_ASSOCIATED_TO_HEAT("ENV file must be associated to a HEAT file"), + + /* content errors*/ + INVALID_YAML_FORMAT("Invalid YAML format - %s"), + INVALID_YAML_FORMAT_REASON("Invalid YAML format Problem - [%s]"), + EMPTY_YAML_FILE("empty yaml"), + GENERAL_YAML_PARSER_ERROR("general parser error"), + GENERAL_HEAT_PARSER_ERROR("general parser error"), + INVALID_HEAT_FORMAT_REASON("Invalid HEAT format problem - [%s]"), + MISSING_RESOURCE_IN_DEPENDS_ON("a Missing resource in depend On Missing Resource ID [%s]"), + REFERENCED_PARAMETER_NOT_FOUND("Referenced parameter - %s - not found, used in resource - %s"), + GET_ATTR_NOT_FOUND("get_attr attribute not found - %s in resource %s"), + MISSING_PARAMETER_IN_NESTED( + "Referenced parameter not found in nested file - %s, resource name - %s, " + + "parameter name - %s"), + NESTED_LOOP("Nested files loop - %s"), + MORE_THAN_ONE_BIND_FROM_NOVA_TO_PORT("Resource Port %s exceed allowed relations from NovaServer"), + SERVER_NOT_DEFINED_FROM_NOVA("Missing server group definition - %s, %s"), + WRONG_POLICY_IN_SERVER_GROUP("Wrong policy in server group - %s"), + MISSING_IMAGE_AND_FLAVOR("Missing both Image and Flavor in NOVA Server - %s"), + ENV_INCLUDES_PARAMETER_NOT_IN_HEAT("Env file %s includes a parameter not in HEAT - %s"), + PARAMETER_ENV_VALUE_NOT_ALIGN_WITH_TYPE("Parameter env value %s not align with type"), + PARAMETER_DEFAULT_VALUE_NOT_ALIGN_WITH_TYPE( + "Parameter - %s default value not align with type %s"), + INVALID_RESOURCE_TYPE("A resource has an invalid or unsupported type - %s, Resource ID [%s]"), + ARTIFACT_FILE_NOT_REFERENCED("Artifact file is not referenced."), + SERVER_OR_SECURITY_GROUP_NOT_IN_USE("%s not in use, Resource Id [%s]"), + PORT_NO_BIND_TO_ANY_NOVA_SERVER("Port not bind to any NOVA Server, Resource Id [%s]"), + INVALID_GET_RESOURCE_SYNTAX( + "invalid get_resource syntax is in use - %s , get_resource function should" + + " get the resource id of the referenced resource"), + INVALID_RESOURCE_GROUP_TYPE( + "OS::Heat::ResourceGroup resource with resource_def which is not " + + "pointing to nested heat file is not supported," + + " Resource ID [%s], resource_def type [%s]"), + + /* warnings */ + REFERENCED_RESOURCE_NOT_FOUND("Referenced resource - %s not found"), + MISSING_GET_PARAM("Missing get_param in %s, Resource Id [%s]"), + + /*Ecomp Guide lines*/ + MISSING_NOVA_SERVER_METADATA("Missing Nova Server Metadata property Resource id [%s]"), + MISSING_NOVA_SERVER_VNF_ID("Missing VNF_ID Resource id [%s]"), + MISSING_NOVA_SERVER_VF_MODULE_ID("Missing VF_MODULE_ID, Resource id [%s]"), + NETWORK_PARAM_NOT_ALIGNED_WITH_GUIDE_LINE( + "Network Parameter Name not aligned with Guidelines Parameter Name [%s] Resource ID [%s]"), + MISSIN_BASE_HEAT_FILE( + "Missing Base HEAT. Pay attention that without Base HEAT, there will be no shared resources"), + MULTI_BASE_HEAT_FILE("Multi Base HEAT. Expected only one. Files %s."), + RESOURCE_NOT_DEFINED_IN_OUTPUT( + "Resource is not defined as output and thus cannot be Shared. resource id - %s"), + RESOURCE_CONNECTED_TO_TWO_EXTERNAL_NETWORKS_WITH_SAME_ROLE( + "A resource is connected twice to the same network role Resource ID [%s] Network Role [%s]."), + VOLUME_HEAT_NOT_EXPOSED("Volume is not defined as output and thus cannot be attached %s"), + FLOATING_IP_NOT_IN_USE("OS::Neutron::FloatingIP is in use, Resource ID [%s]"), + FIXED_IPS_NOT_ALIGNED_WITH_GUIDE_LINES("Fixed_IPS not aligned with Guidelines, Resource ID [%s]"), + NOVA_SERVER_NAME_NOT_ALIGNED_WITH_GUIDE_LINES( + "Server Name not aligned with Guidelines, Resource ID [%s]"), + AVAILABILITY_ZONE_NOT_ALIGNED_WITH_GUIDE_LINES( + "Server Availability Zone not aligned with Guidelines, Resource ID [%s]"), + WRONG_IMAGE_OR_FLAVOR_NAME_NOVA_SERVER("Wrong %s name format in NOVA Server, Resource ID [%s]"); + + + private String errorMessage; + + Messages(String errorMessage) { + this.errorMessage = errorMessage; + } + + public String getErrorMessage() { + return errorMessage; + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/factory/ValidationManagerFactory.java b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/factory/ValidationManagerFactory.java new file mode 100644 index 0000000000..6031bc14f7 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/factory/ValidationManagerFactory.java @@ -0,0 +1,32 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.validation.factory; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; +import org.openecomp.core.validation.api.ValidationManager; + +public abstract class ValidationManagerFactory extends AbstractComponentFactory { + + public static ValidationManagerFactory getInstance() { + return AbstractFactory.getInstance(ValidationManagerFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/interfaces/Validator.java b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/interfaces/Validator.java new file mode 100644 index 0000000000..e32dfd72b9 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/interfaces/Validator.java @@ -0,0 +1,36 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.validation.interfaces; + +import org.openecomp.core.validation.types.GlobalValidationContext; + +public interface Validator { + + //public void validate(String fileName, GlobalValidationContext globalContext); + void validate(GlobalValidationContext globalContext); + //Object convert(FileValidationContext + // fileValidationContext); + + /*default boolean filter(FileValidationContext filecontext, + GlobalValidationContext globalValidationContext){ + return true; + }*/ +} diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/types/FileValidationContext.java b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/types/FileValidationContext.java new file mode 100644 index 0000000000..81e8931dab --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/types/FileValidationContext.java @@ -0,0 +1,53 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.validation.types; + + +import java.io.ByteArrayInputStream; +import java.io.InputStream; + +public class FileValidationContext { + private String fileName; + private MessageContainer messageContainer = new MessageContainer(); + private byte[] content; + + public FileValidationContext(String fileName, byte[] fileContent) { + this.fileName = fileName; + this.content = fileContent; + } + + + MessageContainer getMessageContainer() { + return this.messageContainer; + } + + public InputStream getContent() { + return new ByteArrayInputStream(content); + } + + public String getFileName() { + return this.fileName; + } + + public boolean isEmpty() { + return content == null || content.length == 0; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/types/GlobalValidationContext.java b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/types/GlobalValidationContext.java new file mode 100644 index 0000000000..e6917e84f6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/types/GlobalValidationContext.java @@ -0,0 +1,142 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.validation.types; + +import org.apache.commons.collections4.CollectionUtils; +import org.openecomp.core.utilities.CommonMethods; +import org.openecomp.core.validation.interfaces.Validator; +import org.openecomp.sdc.common.utils.AsdcCommon; +import org.openecomp.sdc.datatypes.error.ErrorLevel; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import java.io.InputStream; +import java.util.Collection; +import java.util.HashMap; +import java.util.Map; +import java.util.function.BiPredicate; +import java.util.stream.Collectors; + +public class GlobalValidationContext { + + private static Logger logger = LoggerFactory.getLogger(Validator.class); + private Map fileContextMap = new HashMap<>(); + private Map messageContainerMap = new HashMap<>(); + + /** + * Add message. + * + * @param fileName the file name + * @param level the level + * @param message the message + */ + public void addMessage(String fileName, ErrorLevel level, String message) { + + printLog(fileName, message, level); + + if (fileContextMap.containsKey(fileName)) { + fileContextMap.get(fileName).getMessageContainer().getMessageBuilder().setMessage(message) + .setLevel(level).create(); + } else { + if (CommonMethods.isEmpty(fileName)) { + fileName = AsdcCommon.UPLOAD_FILE; + } + MessageContainer messageContainer; + synchronized (this) { + messageContainer = messageContainerMap.get(fileName); + if (messageContainer == null) { + messageContainer = new MessageContainer(); + messageContainerMap.put(fileName, messageContainer); + } + } + messageContainer.getMessageBuilder().setMessage(message).setLevel(level).create(); + } + } + + /** + * Gets file content. + * + * @param fileName the file name + * @return the file content + */ + public InputStream getFileContent(String fileName) { + FileValidationContext fileContext = fileContextMap.get(fileName); + if (fileContext == null || fileContext.isEmpty()) { + return null; + } + return fileContext.getContent(); + } + + public void addFileContext(String fileName, byte[] fileContent) { + fileContextMap.put(fileName, new FileValidationContext(fileName, fileContent)); + } + + /** + * Gets context message containers. + * + * @return the context message containers + */ + public Map getContextMessageContainers() { + + Map contextMessageContainer = new HashMap<>(); + fileContextMap.entrySet().stream().filter(entry -> CollectionUtils + .isNotEmpty(entry.getValue().getMessageContainer().getErrorMessageList())).forEach( + entry -> contextMessageContainer.put( + entry.getKey(), entry.getValue().getMessageContainer())); + messageContainerMap.entrySet().stream() + .filter(entry -> CollectionUtils.isNotEmpty(entry.getValue().getErrorMessageList())) + .forEach(entry -> contextMessageContainer.put(entry.getKey(), entry.getValue())); + return contextMessageContainer; + } + + public Map getFileContextMap() { + return fileContextMap; + } + + private void printLog(String fileName, String message, ErrorLevel level) { + + String messageToPrint = message + " in file[" + fileName + "]"; + + switch (level) { + case ERROR: + logger.error(messageToPrint); + break; + case WARNING: + logger.warn(messageToPrint); + break; + case INFO: + logger.info(messageToPrint); + break; + default: + break; + } + } + + public Collection files(BiPredicate func) { + return fileContextMap.keySet().stream().filter(t -> func.test(t, this)) + .collect(Collectors.toList()); + } + + public Collection getFiles() { + return this.getFileContextMap().keySet(); + } + +} diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/types/MessageContainer.java b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/types/MessageContainer.java new file mode 100644 index 0000000000..9d37bade67 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/types/MessageContainer.java @@ -0,0 +1,82 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.validation.types; + +import org.openecomp.sdc.datatypes.error.ErrorLevel; +import org.openecomp.sdc.datatypes.error.ErrorMessage; + +import java.util.ArrayList; +import java.util.List; +import java.util.function.Predicate; + +public class MessageContainer { + + private List errorMessageList = new ArrayList<>(); + + public List getErrorMessageList() { + return errorMessageList; + } + + public MessageBuilder getMessageBuilder() { + return new MessageBuilder(); + } + + /** + * Gets error message list by level. + * + * @param level the level + * @return the error message list by level + */ + public List getErrorMessageListByLevel(ErrorLevel level) { + + List errors = new ArrayList<>(); + errorMessageList.stream().filter(new Predicate() { + @Override + public boolean test(ErrorMessage errorMessage) { + return errorMessage.getLevel().equals(level); + } + }).forEach(errorMessage -> errors.add(errorMessage)); + return errors; + } + + public class MessageBuilder { + + String message; + ErrorLevel level; + + MessageBuilder setMessage(String message) { + this.message = message; + return this; + } + + MessageBuilder setLevel(ErrorLevel level) { + this.level = level; + return this; + } + + void create() { + ErrorMessage errorMessage = new ErrorMessage(level, message); + if (!errorMessageList.contains(errorMessage)) { + errorMessageList.add(errorMessage); + } + } + } +} diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/types/MessageContainerUtil.java b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/types/MessageContainerUtil.java new file mode 100644 index 0000000000..c678bb5014 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/java/org/openecomp/core/validation/types/MessageContainerUtil.java @@ -0,0 +1,64 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.core.validation.types; + +import org.openecomp.sdc.datatypes.error.ErrorLevel; +import org.openecomp.sdc.datatypes.error.ErrorMessage; + + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +public class MessageContainerUtil { + + /** + * Gets message by level. + * + * @param level the level + * @param messages the messages + * @return the message by level + */ + public static Map> getMessageByLevel( + ErrorLevel level,Map> messages) { + if (messages == null) { + return null; + } + Map> filteredMessages = new HashMap<>(); + messages.entrySet().stream().forEach( + entry -> entry.getValue().stream().filter(message -> message.getLevel().equals(level)) + .forEach(message -> addMessage(entry.getKey(), message, filteredMessages + ))); + return filteredMessages; + } + + private static void addMessage(String fileName, ErrorMessage message, + Map> messages) { + List messageList = messages.get(fileName); + if (messageList == null) { + messageList = new ArrayList<>(); + messages.put(fileName, messageList); + } + messageList.add(message); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/resources/factoryConfiguration.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/resources/factoryConfiguration.json new file mode 100644 index 0000000000..42a5583bdf --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/resources/factoryConfiguration.json @@ -0,0 +1,3 @@ +{ + "org.openecomp.core.validation.factory.ValidationManagerFactory":"org.openecomp.sdc.validation.impl.ValidationManagerFactoryImpl" +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/resources/validationConfiguration.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/resources/validationConfiguration.json new file mode 100644 index 0000000000..971f4274d9 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-api/src/main/resources/validationConfiguration.json @@ -0,0 +1,24 @@ +{ + "validatorConfigurationList": [ + { + "name": "yamlValidator", + "enableInd": true, + "implementationClass": "org.openecomp.sdc.validation.impl.validators.YamlValidator" + }, + { + "name": "heatValidator", + "enableInd": true, + "implementationClass": "org.openecomp.sdc.validation.impl.validators.HeatValidator" + }, + { + "name": "manifestValidator", + "enableInd": true, + "implementationClass": "org.openecomp.sdc.validation.impl.validators.ManifestValidator" + }, + { + "name": "ecompGuideLineValidator", + "enableInd": true, + "implementationClass": "org.openecomp.sdc.validation.impl.validators.EcompGuideLineValidator" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/pom.xml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/pom.xml new file mode 100644 index 0000000000..9a68e2e11e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/pom.xml @@ -0,0 +1,93 @@ + + 4.0.0 + + + org.openecomp.sdc + openecomp-sdc-lib + 1.0.0-SNAPSHOT + ../.. + + + openecomp-sdc-validation-core + openecomp-sdc-validation-core + + + + com.google.code.gson + gson + 2.3.1 + test + + + org.yaml + snakeyaml + 1.14 + test + + + org.slf4j + slf4j-api + 1.7.10 + + + + + + ch.qos.logback + logback-classic + 1.1.2 + + + + org.testng + testng + test + 6.8.5 + + + snakeyaml + org.yaml + + + + + junit + junit + RELEASE + test + + + org.openecomp.core + openecomp-utilities-lib + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-validation-api + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-validation-impl + ${project.version} + + + + org.openecomp.sdc + openecomp-sdc-datatypes-lib + ${project.version} + + + org.mockito + mockito-all + test + 1.10.19 + + + com.google.guava + guava + 19.0 + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/main/java/org/openecomp/sdc/validation/impl/ValidationManagerFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/main/java/org/openecomp/sdc/validation/impl/ValidationManagerFactoryImpl.java new file mode 100644 index 0000000000..87d4dd8118 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/main/java/org/openecomp/sdc/validation/impl/ValidationManagerFactoryImpl.java @@ -0,0 +1,34 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.validation.impl; + + +import org.openecomp.core.validation.api.ValidationManager; +import org.openecomp.core.validation.factory.ValidationManagerFactory; + + +public class ValidationManagerFactoryImpl extends ValidationManagerFactory { + + @Override + public ValidationManager createInterface() { + return new ValidationManagerImpl(); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/main/java/org/openecomp/sdc/validation/impl/ValidationManagerImpl.java b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/main/java/org/openecomp/sdc/validation/impl/ValidationManagerImpl.java new file mode 100644 index 0000000000..64c409b463 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/main/java/org/openecomp/sdc/validation/impl/ValidationManagerImpl.java @@ -0,0 +1,69 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.validation.impl; + +import org.apache.commons.collections4.CollectionUtils; +import org.openecomp.core.validation.api.ValidationManager; +import org.openecomp.core.validation.interfaces.Validator; +import org.openecomp.core.validation.types.GlobalValidationContext; +import org.openecomp.core.validation.types.MessageContainer; +import org.openecomp.sdc.datatypes.error.ErrorMessage; +import org.openecomp.sdc.validation.utils.ValidationConfigurationManager; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +public class ValidationManagerImpl implements ValidationManager { + + private static Logger logger = LoggerFactory.getLogger(ValidationManagerImpl.class); + private GlobalValidationContext globalContext; + private List validators; + + public ValidationManagerImpl() { + globalContext = new GlobalValidationContext(); + validators = ValidationConfigurationManager.initValidators(); + } + + @Override + public void addFile(String fileName, byte[] fileContent) { + globalContext.addFileContext(fileName, fileContent); + } + + @Override + public Map> validate() { + for (Validator validator : validators) { + validator.validate(globalContext); + } + return convertMessageContainsToErrorMessage(globalContext.getContextMessageContainers()); + } + + private Map> convertMessageContainsToErrorMessage( + Map contextMessageContainers) { + Map> errors = new HashMap<>(); + contextMessageContainers.entrySet().stream() + .filter(entry -> CollectionUtils.isNotEmpty(entry.getValue().getErrorMessageList())) + .forEach(entry -> errors.put(entry.getKey(), entry.getValue().getErrorMessageList())); + return errors; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/main/java/org/openecomp/sdc/validation/utils/ValidationConfiguration.java b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/main/java/org/openecomp/sdc/validation/utils/ValidationConfiguration.java new file mode 100644 index 0000000000..1a74e1cc34 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/main/java/org/openecomp/sdc/validation/utils/ValidationConfiguration.java @@ -0,0 +1,37 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.validation.utils; + +import java.util.Collections; +import java.util.List; + +public class ValidationConfiguration { + private List validatorConfigurationList; + + public List getValidatorConfigurationList() { + return Collections.unmodifiableList(validatorConfigurationList); + } + + public void setValidatorConfigurationList( + List validatorConfigurationList) { + this.validatorConfigurationList = validatorConfigurationList; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/main/java/org/openecomp/sdc/validation/utils/ValidationConfigurationManager.java b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/main/java/org/openecomp/sdc/validation/utils/ValidationConfigurationManager.java new file mode 100644 index 0000000000..cc921ce985 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/main/java/org/openecomp/sdc/validation/utils/ValidationConfigurationManager.java @@ -0,0 +1,74 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.validation.utils; + +import org.apache.commons.collections4.CollectionUtils; +import org.openecomp.core.utilities.CommonMethods; +import org.openecomp.core.utilities.file.FileUtils; +import org.openecomp.core.utilities.json.JsonUtil; +import org.openecomp.core.validation.interfaces.Validator; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import java.io.InputStream; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; + +public class ValidationConfigurationManager { + + private static final String VALIDATION_CONFIGURATION = "validationConfiguration.json"; + private static final List validators = new ArrayList<>(); + private static Logger logger = LoggerFactory.getLogger(ValidationConfigurationManager.class); + + /** + * Init validators list. + * + * @return the list + */ + public static List initValidators() { + synchronized (validators) { + if (CollectionUtils.isEmpty(validators)) { + InputStream validationConfigurationJson = + FileUtils.getFileInputStream(VALIDATION_CONFIGURATION); + ValidationConfiguration validationConfiguration = + JsonUtil.json2Object(validationConfigurationJson, ValidationConfiguration.class); + List conf = validationConfiguration.getValidatorConfigurationList(); + conf.stream().filter(ValidatorConfiguration::isEnableInd).forEachOrdered( + validatorConfiguration -> validators.add(validatorInit(validatorConfiguration))); + } + } + return validators; + } + + private static Validator validatorInit(ValidatorConfiguration validatorConf) { + Validator validator = null; + try { + validator = + CommonMethods.newInstance(validatorConf.getImplementationClass(), Validator.class); + } catch (IllegalArgumentException iae) { + logger.error("Validator:" + validatorConf.getName() + " Class:" + + validatorConf.getImplementationClass() + " failed in initialization. error:" + + iae.toString() + " trace:" + Arrays.toString(iae.getStackTrace())); + } + return validator; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/main/java/org/openecomp/sdc/validation/utils/ValidationManagerUtil.java b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/main/java/org/openecomp/sdc/validation/utils/ValidationManagerUtil.java new file mode 100644 index 0000000000..960bdc2165 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/main/java/org/openecomp/sdc/validation/utils/ValidationManagerUtil.java @@ -0,0 +1,65 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.validation.utils; + +import org.openecomp.core.utilities.file.FileContentHandler; +import org.openecomp.core.utilities.file.FileUtils; +import org.openecomp.core.validation.api.ValidationManager; +import org.openecomp.core.validation.errors.Messages; +import org.openecomp.core.validation.factory.ValidationManagerFactory; +import org.openecomp.sdc.common.utils.AsdcCommon; +import org.openecomp.sdc.datatypes.error.ErrorLevel; +import org.openecomp.sdc.datatypes.error.ErrorMessage; + +import java.io.InputStream; +import java.util.List; +import java.util.Map; + +public class ValidationManagerUtil { + + /** + * Handle missing manifest. + * + * @param fileContentMap the file content map + * @param errors the errors + */ + public static void handleMissingManifest(FileContentHandler fileContentMap, + Map> errors) { + InputStream manifest = fileContentMap.getFileContent(AsdcCommon.MANIFEST_NAME); + if (manifest == null) { + ErrorMessage.ErrorMessageUtil.addMessage(AsdcCommon.MANIFEST_NAME, errors) + .add(new ErrorMessage(ErrorLevel.ERROR, Messages.MANIFEST_NOT_EXIST.getErrorMessage())); + } + } + + /** + * Init validation manager validation manager. + * + * @param fileContentMap the file content map + * @return the validation manager + */ + public static ValidationManager initValidationManager(FileContentHandler fileContentMap) { + ValidationManager validationManager = ValidationManagerFactory.getInstance().createInterface(); + fileContentMap.getFileList().stream().forEach(fileName -> validationManager + .addFile(fileName, FileUtils.toByteArray(fileContentMap.getFileContent(fileName)))); + return validationManager; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/main/java/org/openecomp/sdc/validation/utils/ValidatorConfiguration.java b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/main/java/org/openecomp/sdc/validation/utils/ValidatorConfiguration.java new file mode 100644 index 0000000000..12feb641ae --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/main/java/org/openecomp/sdc/validation/utils/ValidatorConfiguration.java @@ -0,0 +1,51 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.validation.utils; + +public class ValidatorConfiguration { + private String name; + private boolean enableInd = true; + private String implementationClass; + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public boolean isEnableInd() { + return enableInd; + } + + public void setEnableInd(boolean enableInd) { + this.enableInd = enableInd; + } + + public String getImplementationClass() { + return implementationClass; + } + + public void setImplementationClass(String implementationClass) { + this.implementationClass = implementationClass; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/test/java/org/openecomp/sdc/heat/services/tree/HeatTreeManagerTest.java b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/test/java/org/openecomp/sdc/heat/services/tree/HeatTreeManagerTest.java new file mode 100644 index 0000000000..6a9f8df12d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/test/java/org/openecomp/sdc/heat/services/tree/HeatTreeManagerTest.java @@ -0,0 +1,51 @@ +package org.openecomp.sdc.heat.services.tree; + +import org.openecomp.sdc.heat.datatypes.structure.HeatStructureTree; +import org.openecomp.core.utilities.file.FileContentHandler; +import org.openecomp.core.utilities.file.FileUtils; +import org.testng.Assert; +import org.testng.annotations.Test; + +import java.io.File; +import java.io.FileInputStream; +import java.io.IOException; +import java.net.URL; + +public class HeatTreeManagerTest { + + @Test + public void testHeatTreeCreation() { + + FileContentHandler fileContentMap = new FileContentHandler(); + URL url = this.getClass().getResource("/heatTreeValidationOutput"); + + File templateDir = new File(url.getFile()); + File[] files = templateDir.listFiles(); + + if (files == null || files.length == 0) { + return; + } + + for (File file : files) { + fileContentMap.addFile(file.getName(), getFileContent(file)); + } + + HeatTreeManager heatTreeManager = HeatTreeManagerUtil.initHeatTreeManager(fileContentMap); + heatTreeManager.createTree(); + HeatStructureTree tree = heatTreeManager.getTree(); + Assert.assertNotNull(tree); + Assert.assertEquals(tree.getHEAT().size(), 2); + } + + private byte[] getFileContent(File file) { + try { + return FileUtils.toByteArray(new FileInputStream(file)); + } catch (IOException e) { + e.printStackTrace(); + } + + return new byte[0]; + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/test/resources/heatTreeValidationOutput/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/test/resources/heatTreeValidationOutput/MANIFEST.json new file mode 100644 index 0000000000..f1553f5c74 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/test/resources/heatTreeValidationOutput/MANIFEST.json @@ -0,0 +1,35 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "hot-nimbus-psm_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "hot-nimbus-psm_volume.yaml", + "type": "HEAT_VOL" + }, + { + "file": "nested-pps_v1.0.yaml", + "type": "HEAT" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/test/resources/heatTreeValidationOutput/hot-nimbus-pps_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/test/resources/heatTreeValidationOutput/hot-nimbus-pps_v1.0.env new file mode 100644 index 0000000000..809835d2b8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/test/resources/heatTreeValidationOutput/hot-nimbus-pps_v1.0.env @@ -0,0 +1,12 @@ +parameters: + pcrf_pps_server_names: ZRDM1PCRF01PPS001,ZRDM1PCRF01PPS002,ZRDM1PCRF01PPS003,ZRDM1PCRF01PPS004,ZRDM1PCRF01PPS005,ZRDM1PCRF01PPS006 + pcrf_pps_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pps_flavor_name: lc.3xlarge + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.7,172.26.16.8,172.26.16.9,172.26.16.10,172.26.16.11,172.26.16.12 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + mock_param: abskdjska + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/test/resources/heatTreeValidationOutput/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/test/resources/heatTreeValidationOutput/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..d3318ee0ca --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/test/resources/heatTreeValidationOutput/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,94 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + default: True + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + availability_zone_1: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + + +resources: + server_pcrf_pps_001: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + + availability_zone_legal_name_1: + type: OS::Nova::Server + properties: + name: { get_param: [pcrf_pps_server_names, 0] } + availability_zone: {get_param: availability_zone_1} + metadata: + vnf_id: { get_param: pcrf_vnf_id } + vf_module_id: { get_param: pcrf_vnf_module_id } + + availability_zone_illegal_name_1: + type: OS::Nova::Server + properties: + name: { get_param: [pcrf_pps_server_names, 0] } + availability_zone: {get_param: availability_zone_name} + metadata: + vnf_id: { get_param: pcrf_vnf_id } + vf_module_id: { get_param: pcrf_vnf_module_id } + + availability_zone_illegal_name_2: + type: OS::Nova::Server + properties: + name: { get_param: [pcrf_pps_server_names, 0] } + availability_zone: {get_param: availability_zone} + metadata: + vnf_id: { get_param: pcrf_vnf_id } + vf_module_id: { get_param: pcrf_vnf_module_id } + + SecurityGroup_expose: + type: OS::Neutron::SecurityGroup + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/test/resources/heatTreeValidationOutput/hot-nimbus-psm_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/test/resources/heatTreeValidationOutput/hot-nimbus-psm_v1.0.env new file mode 100644 index 0000000000..809835d2b8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/test/resources/heatTreeValidationOutput/hot-nimbus-psm_v1.0.env @@ -0,0 +1,12 @@ +parameters: + pcrf_pps_server_names: ZRDM1PCRF01PPS001,ZRDM1PCRF01PPS002,ZRDM1PCRF01PPS003,ZRDM1PCRF01PPS004,ZRDM1PCRF01PPS005,ZRDM1PCRF01PPS006 + pcrf_pps_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pps_flavor_name: lc.3xlarge + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.7,172.26.16.8,172.26.16.9,172.26.16.10,172.26.16.11,172.26.16.12 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + mock_param: abskdjska + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/test/resources/heatTreeValidationOutput/hot-nimbus-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/test/resources/heatTreeValidationOutput/hot-nimbus-psm_v1.0.yaml new file mode 100644 index 0000000000..072a8ba934 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/test/resources/heatTreeValidationOutput/hot-nimbus-psm_v1.0.yaml @@ -0,0 +1,109 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + default: True + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + availability_zone_1: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + pcrf_images: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + pcrf_network_v0_ips: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + network_net_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + + +resources: + server_pcrf_pps_001: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + + resource_illegal_image: + type: OS::Nova::Server + properties: + name: { get_param: [pcrf_pps_server_names, 0] } + image: {get_param: pcrf_images} + flavor: {get_param: pcrf_flavor_11} + metadata: + vnf_id: { get_param: pcrf_vnf_id } + vf_module_id: { get_param: pcrf_vnf_module_id } + + resource_illegal_network_1: + type: OS::Neutron::Port + properties: + name: { get_param: [pcrf_pps_server_names, 0] } + network: {get_param: network_net_id} + + resource_illegal_network_2: + type: OS::Neutron::Port + properties: + name: { get_param: [pcrf_pps_server_names, 0] } + network: {get_param: network_net_id} + fixed_ips: + - ip_address: {get_param: pcrf_network_v0_ips} + + availability_zone_illegal_name_2: + type: OS::Nova::Server + properties: + name: { get_param: [pcrf_pps_server_names, 0] } + availability_zone: {get_param: availability_zone} + metadata: + vnf_id: { get_param: pcrf_vnf_id } + vf_module_id: { get_param: pcrf_vnf_module_id } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/test/resources/heatTreeValidationOutput/hot-nimbus-psm_volume.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/test/resources/heatTreeValidationOutput/hot-nimbus-psm_volume.yaml new file mode 100644 index 0000000000..288607cf55 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/test/resources/heatTreeValidationOutput/hot-nimbus-psm_volume.yaml @@ -0,0 +1,21 @@ + +heat_template_version: 2013-05-23 + +parameters: + not_null: + type: number + label: not_number + + +resources: + volume_not_expose: + type: OS::Cinder::Volume + properties: + not_null: {get_param: not_null} + + +outputs: + not_expose_resource_network_output: + description: the pcrf_server + value: { get_resource: volume_expose } + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/test/resources/heatTreeValidationOutput/nested-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/test/resources/heatTreeValidationOutput/nested-pps_v1.0.yaml new file mode 100644 index 0000000000..cb23fb8e8c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-core/src/test/resources/heatTreeValidationOutput/nested-pps_v1.0.yaml @@ -0,0 +1,98 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_name: + type: string + default: True + label: PCRF PS server name + description: PCRF PS server name + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availability_zone_0: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + params: + $vm_name: { get_param: pcrf_pps_server_name } + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_pps: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_pps_server_name } + image: { get_param: pcrf_pps_image_name } + flavor: { get_param: pcrf_pps_flavor_name } + availability_zone: { get_param: availability_zone_0 } + networks: + - port: { get_resource: pcrf_pps_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + + pcrf_pps_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/pom.xml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/pom.xml new file mode 100644 index 0000000000..bacd79a97a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/pom.xml @@ -0,0 +1,100 @@ + + 4.0.0 + + + org.openecomp.sdc + openecomp-sdc-lib + 1.0.0-SNAPSHOT + ../.. + + + openecomp-sdc-validation-impl + openecomp-sdc-validation-impl + + + + org.yaml + snakeyaml + 1.17 + test + + + com.google.code.gson + gson + 2.3.1 + test + + + org.slf4j + slf4j-api + 1.7.10 + + + + ch.qos.logback + logback-classic + 1.1.2 + + + + + org.testng + testng + test + 6.8.5 + + + snakeyaml + org.yaml + + + + + junit + junit + RELEASE + test + + + org.openecomp.core + openecomp-utilities-lib + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-validation-api + ${project.version} + + + org.openecomp.core + openecomp-common-lib + ${project.version} + + + org.mockito + mockito-all + test + 1.10.19 + + + com.google.guava + guava + 19.0 + + + + org.openecomp.core + openecomp-heat-lib + ${project.version} + + + org.yaml + snakeyaml + + + + + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/main/java/org/openecomp/sdc/validation/impl/util/HeatValidationService.java b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/main/java/org/openecomp/sdc/validation/impl/util/HeatValidationService.java new file mode 100644 index 0000000000..920724ed3b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/main/java/org/openecomp/sdc/validation/impl/util/HeatValidationService.java @@ -0,0 +1,323 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.validation.impl.util; + +import org.apache.commons.collections4.CollectionUtils; +import org.apache.commons.collections4.MapUtils; +import org.openecomp.core.utilities.yaml.YamlUtil; +import org.openecomp.core.validation.errors.ErrorMessagesFormatBuilder; +import org.openecomp.core.validation.errors.Messages; +import org.openecomp.core.validation.types.GlobalValidationContext; +import org.openecomp.sdc.datatypes.error.ErrorLevel; +import org.openecomp.sdc.heat.datatypes.model.Environment; +import org.openecomp.sdc.heat.datatypes.model.HeatOrchestrationTemplate; +import org.openecomp.sdc.heat.datatypes.model.Output; +import org.openecomp.sdc.heat.datatypes.model.Resource; +import org.openecomp.sdc.heat.datatypes.model.ResourceReferenceFunctions; +import org.openecomp.sdc.heat.services.HeatStructureUtil; +import org.openecomp.sdc.validation.impl.validators.HeatValidator; + +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import java.util.Collection; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.Set; + +public class HeatValidationService { + + private static final Logger logger = LoggerFactory.getLogger(HeatValidator.class); + + /** + * Check artifacts existence. + * + * @param fileName the file name + * @param artifactsNames the artifacts names + * @param globalContext the global context + */ + public static void checkArtifactsExistence(String fileName, Set artifactsNames, + GlobalValidationContext globalContext) { + artifactsNames + .stream() + .filter(artifactName -> !globalContext.getFileContextMap().containsKey(artifactName)) + .forEach(artifactName -> { + globalContext + .addMessage(fileName, ErrorLevel.ERROR, ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.MISSING_ARTIFACT.getErrorMessage(), + artifactName)); + }); + } + + + /** + * Check resource existence from resources map. + * + * @param fileName the file name + * @param resourcesNames the resources names + * @param valuesToSearchIn the values to search in + * @param globalContext the global context + */ + public static void checkResourceExistenceFromResourcesMap(String fileName, + Set resourcesNames, + Collection valuesToSearchIn, + GlobalValidationContext globalContext) { + if (CollectionUtils.isNotEmpty(valuesToSearchIn)) { + for (Object value : valuesToSearchIn) { + if (value instanceof Resource) { + Resource resource = (Resource) value; + //checkResourceDependsOn(fileName,resource,resourcesNames,globalContext); + + Collection resourcePropertiesValues = + resource.getProperties() == null ? null : resource.getProperties().values(); + if (CollectionUtils.isNotEmpty(resourcePropertiesValues)) { + for (Object propertyValue : resourcePropertiesValues) { + handleReferencedResources(fileName, propertyValue, resourcesNames, globalContext); + } + } + } else if (value instanceof Output) { + Output output = (Output) value; + Object outputsValue = output.getValue(); + handleReferencedResources(fileName, outputsValue, resourcesNames, globalContext); + } + } + } + } + + + private static void handleReferencedResources(String fileName, Object valueToSearchReferencesIn, + Set resourcesNames, + GlobalValidationContext globalContext) { + Set referencedResourcesNames = HeatStructureUtil + .getReferencedValuesByFunctionName(fileName, + ResourceReferenceFunctions.GET_RESOURCE.getFunction(), valueToSearchReferencesIn, + globalContext); + if (CollectionUtils.isNotEmpty(referencedResourcesNames)) { + HeatValidationService + .checkIfResourceReferenceExist(fileName, resourcesNames, referencedResourcesNames, + globalContext); + } + } + + + private static void checkIfResourceReferenceExist(String fileName, + Set referencedResourcesNames, + Set referencedResources, + GlobalValidationContext globalContext) { + referencedResources.stream() + .filter(referencedResource -> !referencedResourcesNames.contains(referencedResource)) + .forEach(referencedResource -> { + globalContext.addMessage(fileName, ErrorLevel.ERROR, ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.REFERENCED_RESOURCE_NOT_FOUND.getErrorMessage(), + referencedResource)); + }); + } + + /** + * Draw files loop string. + * + * @param filesInPath the files in path + * @return the string + */ + public static String drawFilesLoop(List filesInPath) { + StringBuilder stringBuilder = new StringBuilder(); + stringBuilder.append("["); + int pathSize = filesInPath.size(); + + for (int i = 0; i < pathSize; i++) { + stringBuilder.append(filesInPath.get(i)); + if (i != pathSize - 1) { + stringBuilder.append(" -- "); + } + } + if (!filesInPath.get(0).equals(filesInPath.get(pathSize - 1))) { + stringBuilder.append(" -- "); + stringBuilder.append(filesInPath.get(0)); + } + stringBuilder.append("]"); + + return stringBuilder.toString(); + } + + + /** + * Check nested parameters. + * + * @param callingNestedFileName the calling nested file name + * @param nestedFileName the nested file name + * @param resourceName the resource name + * @param globalContext the global context + * @param resourceFileProperties the resource file properties + */ + public static void checkNestedParameters(String callingNestedFileName, String nestedFileName, + String resourceName, + GlobalValidationContext globalContext, + Set resourceFileProperties) { + HeatOrchestrationTemplate heatOrchestrationTemplate; + try { + heatOrchestrationTemplate = new YamlUtil() + .yamlToObject(globalContext.getFileContent(nestedFileName), + HeatOrchestrationTemplate.class); + } catch (Exception e0) { + return; + } + Set nestedParametersNames = heatOrchestrationTemplate.getParameters() == null ? null + : heatOrchestrationTemplate.getParameters().keySet(); + + if (CollectionUtils.isNotEmpty(nestedParametersNames)) { + resourceFileProperties + .stream() + .filter(propertyName -> !nestedParametersNames.contains(propertyName)) + .forEach(propertyName -> globalContext + .addMessage(callingNestedFileName, ErrorLevel.ERROR, ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.MISSING_PARAMETER_IN_NESTED.getErrorMessage(), + nestedFileName, resourceName, propertyName))); + } + } + + + /** + * Is nested loop exist in file boolean. + * + * @param callingFileName the calling file name + * @param nestedFileName the nested file name + * @param filesInLoop the files in loop + * @param globalContext the global context + * @return the boolean + */ + public static boolean isNestedLoopExistInFile(String callingFileName, String nestedFileName, + List filesInLoop, + GlobalValidationContext globalContext) { + HeatOrchestrationTemplate nestedHeatOrchestrationTemplate; + try { + nestedHeatOrchestrationTemplate = new YamlUtil() + .yamlToObject(globalContext.getFileContent(nestedFileName), + HeatOrchestrationTemplate.class); + } catch (Exception e0) { + logger.warn("HEAT Validator will not be executed on file " + nestedFileName + + " due to illegal HEAT format"); + return false; + } + filesInLoop.add(nestedFileName); + Collection nestedResources = + nestedHeatOrchestrationTemplate.getResources() == null ? null + : nestedHeatOrchestrationTemplate.getResources().values(); + if (CollectionUtils.isNotEmpty(nestedResources)) { + for (Resource resource : nestedResources) { + String resourceType = resource.getType(); + + if (Objects.nonNull(resourceType) && isNestedResource(resourceType)) { + return resourceType.equals(callingFileName) || !filesInLoop.contains(resourceType) + && isNestedLoopExistInFile(callingFileName, resourceType, filesInLoop, globalContext); + } + } + } + return false; + } + + + /** + * Loop over output map and validate get attr from nested. + * + * @param fileName the file name + * @param outputMap the output map + * @param heatOrchestrationTemplate the heat orchestration template + * @param globalContext the global context + */ + @SuppressWarnings("unchecked") + public static void loopOverOutputMapAndValidateGetAttrFromNested(String fileName, + Map outputMap, + HeatOrchestrationTemplate heatOrchestrationTemplate, + GlobalValidationContext globalContext) { + for (Output output : outputMap.values()) { + Object outputValue = output.getValue(); + if (outputValue != null && outputValue instanceof Map) { + Map outputValueMap = (Map) outputValue; + List getAttrValue = + (List) outputValueMap.get(ResourceReferenceFunctions.GET_ATTR.getFunction()); + if (!CollectionUtils.isEmpty(getAttrValue)) { + String resourceName = getAttrValue.get(0); + String propertyName = getAttrValue.get(1); + String resourceType = + getResourceTypeFromResourcesMap(resourceName, heatOrchestrationTemplate); + + if (Objects.nonNull(resourceType) + && HeatValidationService.isNestedResource(resourceType)) { + Map nestedOutputMap; + HeatOrchestrationTemplate nestedHeatOrchestrationTemplate; + try { + nestedHeatOrchestrationTemplate = new YamlUtil() + .yamlToObject(globalContext.getFileContent(resourceType), + HeatOrchestrationTemplate.class); + } catch (Exception e0) { + return; + } + nestedOutputMap = nestedHeatOrchestrationTemplate.getOutputs(); + + if (MapUtils.isEmpty(nestedOutputMap) || !nestedOutputMap.containsKey(propertyName)) { + globalContext.addMessage(fileName, ErrorLevel.ERROR, ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.GET_ATTR_NOT_FOUND.getErrorMessage(), + propertyName, resourceName)); + } + } + } + } + } + } + + + public static boolean isNestedResource(String resourceType) { + return resourceType.contains(".yaml") || resourceType.contains(".yml"); + } + + + private static String getResourceTypeFromResourcesMap(String resourceName, + HeatOrchestrationTemplate heatOrchestrationTemplate) { + return heatOrchestrationTemplate.getResources().get(resourceName).getType(); + } + + /** + * Validate env content environment. + * + * @param fileName the file name + * @param envFileName the env file name + * @param globalContext the global context + * @return the environment + */ + public static Environment validateEnvContent(String fileName, String envFileName, + GlobalValidationContext globalContext) { + Environment envContent = null; + try { + envContent = + new YamlUtil().yamlToObject(globalContext.getFileContent(envFileName), Environment.class); + } catch (Exception e0) { + return null; + } + return envContent; + } + + + public static String getResourceGroupResourceName(String resourceCallingToResourceGroup) { + return "OS::Heat::ResourceGroup in " + resourceCallingToResourceGroup; + } + +} diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/main/java/org/openecomp/sdc/validation/impl/util/ResourceValidationHeatValidator.java b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/main/java/org/openecomp/sdc/validation/impl/util/ResourceValidationHeatValidator.java new file mode 100644 index 0000000000..3457bed1e9 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/main/java/org/openecomp/sdc/validation/impl/util/ResourceValidationHeatValidator.java @@ -0,0 +1,617 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.validation.impl.util; + +import org.apache.commons.collections4.CollectionUtils; +import org.apache.commons.collections4.MapUtils; +import org.openecomp.core.validation.errors.ErrorMessagesFormatBuilder; +import org.openecomp.core.validation.errors.Messages; +import org.openecomp.core.validation.types.GlobalValidationContext; +import org.openecomp.sdc.datatypes.error.ErrorLevel; +import org.openecomp.sdc.heat.datatypes.model.HeatOrchestrationTemplate; +import org.openecomp.sdc.heat.datatypes.model.HeatResourcesTypes; +import org.openecomp.sdc.heat.datatypes.model.Output; +import org.openecomp.sdc.heat.datatypes.model.PolicyTypes; +import org.openecomp.sdc.heat.datatypes.model.PropertiesMapKeyTypes; +import org.openecomp.sdc.heat.datatypes.model.Resource; +import org.openecomp.sdc.heat.datatypes.model.ResourceReferenceFunctions; +import org.openecomp.sdc.heat.datatypes.model.ResourceTypeToMessageString; +import org.openecomp.sdc.heat.services.HeatStructureUtil; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.Collections; +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.Set; + + +public class ResourceValidationHeatValidator { + + /** + * Validate resource type. + * + * @param fileName the file name + * @param baseFileName the base file name + * @param securityGroupsNamesFromBaseFileOutputs the security groups names from base file outputs + * @param heatOrchestrationTemplate the heat orchestration template + * @param globalContext the global context + */ + public static void validateResourceType(String fileName, String baseFileName, + Set securityGroupsNamesFromBaseFileOutputs, + HeatOrchestrationTemplate heatOrchestrationTemplate, + GlobalValidationContext globalContext) { + Map resourceMap = + heatOrchestrationTemplate.getResources() == null ? new HashMap<>() + : heatOrchestrationTemplate.getResources(); + Map numberOfVisitsInPort = new HashMap<>(); + Set resourcesNames = resourceMap.keySet(); + Set sharedResourcesFromOutputMap = + getSharedResourcesNamesFromOutputs(fileName, heatOrchestrationTemplate.getOutputs(), + globalContext); + boolean isBaseFile = baseFileName != null && fileName.equals(baseFileName); + + Map> resourceTypeToNamesListMap = HeatResourcesTypes + .getListForResourceType(HeatResourcesTypes.NOVA_SERVER_GROUP_RESOURCE_TYPE, + HeatResourcesTypes.NEUTRON_SECURITY_GROUP_RESOURCE_TYPE, + HeatResourcesTypes.CONTRAIL_NETWORK_RULE_RESOURCE_TYPE); + + initResourceTypeListWithItsResourcesNames(fileName, resourceTypeToNamesListMap, resourceMap, + sharedResourcesFromOutputMap, globalContext); + initVisitedPortsMap(fileName, resourceMap, numberOfVisitsInPort, globalContext); + + + for (Map.Entry resourceEntry : resourceMap.entrySet()) { + String resourceType = resourceEntry.getValue().getType(); + validateSecurityGroupsFromBaseOutput(fileName, resourceEntry, isBaseFile, + securityGroupsNamesFromBaseFileOutputs, globalContext); + checkResourceDependsOn(fileName, resourceEntry.getValue(), resourcesNames, globalContext); + + if (Objects.isNull(resourceType)) { + globalContext.addMessage(fileName, ErrorLevel.WARNING, ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.INVALID_RESOURCE_TYPE.getErrorMessage(), "null", + resourceEntry.getKey())); + } else { + HeatResourcesTypes heatResourceType = HeatResourcesTypes.findByHeatResource(resourceType); + + if (heatResourceType != null) { + switch (heatResourceType) { + case NOVA_SERVER_RESOURCE_TYPE: + validateNovaServerResourceType(fileName, resourceEntry, numberOfVisitsInPort, + resourceTypeToNamesListMap + .get(HeatResourcesTypes.NOVA_SERVER_GROUP_RESOURCE_TYPE), + heatOrchestrationTemplate, globalContext); + break; + + case NOVA_SERVER_GROUP_RESOURCE_TYPE: + validateNovaServerGroupPolicy(fileName, resourceEntry, globalContext); + break; + + case RESOURCE_GROUP_RESOURCE_TYPE: + validateResourceGroupType(fileName, resourceEntry, globalContext); + break; + + case NEUTRON_PORT_RESOURCE_TYPE: + validateNeutronPortType(fileName, resourceEntry, resourceTypeToNamesListMap + .get(HeatResourcesTypes.NEUTRON_SECURITY_GROUP_RESOURCE_TYPE), globalContext); + break; + + case CONTRAIL_NETWORK_ATTACH_RULE_RESOURCE_TYPE: + validateContrailAttachPolicyType(resourceEntry, resourceTypeToNamesListMap + .get(HeatResourcesTypes.CONTRAIL_NETWORK_RULE_RESOURCE_TYPE)); + break; + default: + } + } else { + if (HeatValidationService.isNestedResource(resourceType)) { + handleNestedResourceType(fileName, resourceEntry.getKey(), resourceEntry.getValue(), + globalContext); + } + } + } + } + + checkForEmptyResourceNamesInMap(fileName, + CollectionUtils.isEmpty(securityGroupsNamesFromBaseFileOutputs), resourceTypeToNamesListMap, + globalContext); + handleOrphanPorts(fileName, numberOfVisitsInPort, globalContext); + } + + + private static void validateNovaServerResourceType(String fileName, + Map.Entry resourceEntry, + Map numberOfVisitsInPort, + List serverGroupResourcesNames, + HeatOrchestrationTemplate + heatOrchestrationTemplate, + GlobalValidationContext globalContext) { + validateAssignedValueForImageOrFlavorFromNova(fileName, resourceEntry, globalContext); + validateNovaServerPortBinding(fileName, resourceEntry.getValue(), numberOfVisitsInPort, + globalContext); + validateAllServerGroupsPointedByServerExistAndDefined(fileName, resourceEntry, + serverGroupResourcesNames, heatOrchestrationTemplate, globalContext); + + } + + + private static void handleNestedResourceType(String fileName, String resourceName, + Resource resource, + GlobalValidationContext globalContext) { + validateAllPropertiesMatchNestedParameters(fileName, resourceName, resource, globalContext); + validateLoopsOfNestingFromFile(fileName, resource.getType(), globalContext); + } + + + private static void validateResourceGroupType(String fileName, + Map.Entry resourceEntry, + GlobalValidationContext globalContext) { + Resource resourceDef = HeatStructureUtil + .getResourceDef(fileName, resourceEntry.getKey(), resourceEntry.getValue(), globalContext); + // validateResourceGroupTypeIsSupported(fileName, resourceEntry.getKey(),resourceDef.getType(), + // globalContext); + if (resourceDef != null) { + if (Objects.nonNull(resourceDef.getType()) + && HeatValidationService.isNestedResource(resourceDef.getType())) { + handleNestedResourceType(fileName, resourceDef.getType(), resourceDef, globalContext); + } + } + } + + + private static void validateAllPropertiesMatchNestedParameters(String fileName, + String resourceName, + Resource resource, + GlobalValidationContext + globalContext) { + + String resourceType = resource.getType(); + if (globalContext.getFileContextMap().containsKey(resourceType)) { + Set propertiesNames = + resource.getProperties() == null ? null : resource.getProperties().keySet(); + if (CollectionUtils.isNotEmpty(propertiesNames)) { + HeatValidationService + .checkNestedParameters(fileName, resourceType, resourceName, globalContext, + propertiesNames); + } + } else { + globalContext.addMessage(resourceType, ErrorLevel.ERROR, ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.MISSING_NESTED_FILE.getErrorMessage(), resourceType)); + } + } + + + private static void validateAssignedValueForImageOrFlavorFromNova(String fileName, + Map.Entry + resourceEntry, + GlobalValidationContext + globalContext) { + + Resource resource = resourceEntry.getValue(); + Map propertiesMap = resource.getProperties(); + if (propertiesMap.get(PropertiesMapKeyTypes.IMAGE.getKeyMap()) == null + && propertiesMap.get(PropertiesMapKeyTypes.FLAVOR.getKeyMap()) == null) { + globalContext.addMessage(fileName, ErrorLevel.ERROR, ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.MISSING_IMAGE_AND_FLAVOR.getErrorMessage(), + resourceEntry.getKey())); + } + } + + + private static void validateLoopsOfNestingFromFile(String fileName, String resourceType, + GlobalValidationContext globalContext) { + List filesInLoop = new ArrayList<>(Collections.singletonList(fileName)); + if (HeatValidationService + .isNestedLoopExistInFile(fileName, resourceType, filesInLoop, globalContext)) { + globalContext.addMessage(fileName, ErrorLevel.ERROR, ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.NESTED_LOOP.getErrorMessage(), + HeatValidationService.drawFilesLoop(filesInLoop))); + } + } + + + /* validation 22*/ + @SuppressWarnings("unchecked") + private static void validateNovaServerPortBinding(String fileName, Resource resource, + Map numberOfVisitsInPort, + GlobalValidationContext globalContext) { + + Map propertiesMap = resource.getProperties(); + List networksList = + (List) propertiesMap.get(PropertiesMapKeyTypes.NETWORKS.getKeyMap()); + + if (CollectionUtils.isNotEmpty(networksList)) { + networksList + .stream() + .filter(networkObject -> networkObject instanceof Map) + .forEach(networkObject -> { + Map portValueMap = + (Map) ((Map) networkObject).get("port"); + if (MapUtils.isNotEmpty(portValueMap)) { + checkPortBindingFromMap(fileName, portValueMap, numberOfVisitsInPort, globalContext); + } + }); + } + } + + /* validation 23*/ + @SuppressWarnings("unchecked") + private static void validateAllServerGroupsPointedByServerExistAndDefined(String fileName, + Map.Entry resourceEntry, + List serverGroupNamesList, + HeatOrchestrationTemplate heatOrchestrationTemplate, + GlobalValidationContext globalContext) { + Map resourcesMap = heatOrchestrationTemplate.getResources(); + + Map resourceProperties = resourceEntry.getValue().getProperties(); + Map schedulerHintsMap = resourceProperties == null ? null + : (Map) resourceProperties + .get(ResourceReferenceFunctions.SCHEDULER_HINTS.getFunction()); + + if (MapUtils.isNotEmpty(schedulerHintsMap)) { + for (Object serverGroupMap : schedulerHintsMap.values()) { + Map currentServerMap = (Map) serverGroupMap; + String serverResourceName = currentServerMap == null ? null + : (String) currentServerMap.get(ResourceReferenceFunctions.GET_RESOURCE.getFunction()); + Resource serverResource = serverResourceName == null || resourcesMap == null ? null + : resourcesMap.get(serverResourceName); + if (serverResource != null && !serverResource.getType() + .equals(HeatResourcesTypes.NOVA_SERVER_GROUP_RESOURCE_TYPE.getHeatResource())) { + globalContext.addMessage(fileName, ErrorLevel.ERROR, ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.SERVER_NOT_DEFINED_FROM_NOVA.getErrorMessage(), + serverResourceName, resourceEntry.getKey())); + } else { + serverGroupNamesList.remove(serverResourceName); + } + } + } + } + + + /* validation 24*/ + @SuppressWarnings("unchecked") + private static void validateNovaServerGroupPolicy(String fileName, + Map.Entry resourceEntry, + GlobalValidationContext globalContext) { + + Resource resource = resourceEntry.getValue(); + List policiesList = resource.getProperties() == null ? null + : (List) resource.getProperties().get("policies"); + + if (CollectionUtils.isNotEmpty(policiesList)) { + if (policiesList.size() == 1) { + String policy = policiesList.get(0); + if (!PolicyTypes.isGivenPolicyValid(policy)) { + globalContext.addMessage(fileName, ErrorLevel.ERROR, ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.WRONG_POLICY_IN_SERVER_GROUP.getErrorMessage(), + resourceEntry.getKey())); + } + } else { + globalContext.addMessage(fileName, ErrorLevel.ERROR, ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.WRONG_POLICY_IN_SERVER_GROUP.getErrorMessage(), + resourceEntry.getKey())); + } + } + } + + + private static void validateNeutronPortType(String filename, + Map.Entry resourceEntry, + List securityGroupResourceNameList, + GlobalValidationContext globalContext) { + validateAllSecurityGroupsAreUsed(filename, resourceEntry, securityGroupResourceNameList, + globalContext); + + } + + + @SuppressWarnings("unchecked") + private static void validateAllSecurityGroupsAreUsed(String filename, + Map.Entry resourceEntry, + List securityGroupResourceNameList, + GlobalValidationContext globalContext) { + Map propertiesMap = resourceEntry.getValue().getProperties(); + + if (MapUtils.isEmpty(propertiesMap)) { + return; + } + + Object securityGroupsValue = propertiesMap.get("security_groups"); + + if (Objects.isNull(securityGroupsValue)) { + return; + } + + if (securityGroupsValue instanceof List) { + List securityGroupsListFromCurrResource = + (List) propertiesMap.get("security_groups"); + for (Object securityGroup : securityGroupsListFromCurrResource) { + removeSecurityGroupNamesFromListByGivenFunction(filename, + ResourceReferenceFunctions.GET_RESOURCE.getFunction(), securityGroup, + securityGroupResourceNameList, globalContext); + } + } + } + + + private static void validateSecurityGroupsFromBaseOutput(String filename, + Map.Entry resourceEntry, + boolean isBaseFile, + Set securityGroupNamesFromBaseOutput, + GlobalValidationContext globalContext) { + if (!isBaseFile && CollectionUtils.isNotEmpty(securityGroupNamesFromBaseOutput)) { + Map propertiesMap = resourceEntry.getValue().getProperties(); + + if (MapUtils.isEmpty(propertiesMap)) { + return; + } + + for (Map.Entry propertyEntry : propertiesMap.entrySet()) { + removeSecurityGroupNamesFromListByGivenFunction(filename, + ResourceReferenceFunctions.GET_PARAM.getFunction(), propertyEntry.getValue(), + securityGroupNamesFromBaseOutput, globalContext); + } + } + } + + + private static void removeSecurityGroupNamesFromListByGivenFunction(String filename, + String functionName, + Object securityGroup, + Collection securityGroupResourceNameList, + GlobalValidationContext globalContext) { + Set securityGroupsNamesFromFunction = HeatStructureUtil + .getReferencedValuesByFunctionName(filename, functionName, securityGroup, globalContext); + securityGroupsNamesFromFunction.forEach(securityGroupResourceNameList::remove); + } + + + @SuppressWarnings("unchecked") + private static void validateContrailAttachPolicyType(Map.Entry resourceEntry, + List networkPolicyResourceNames) { + Map propertiesMap = resourceEntry.getValue().getProperties(); + + if (MapUtils.isNotEmpty(propertiesMap)) { + Map policyMap = (Map) propertiesMap.get("policy"); + if (MapUtils.isNotEmpty(policyMap)) { + List securityGroupList = + (List) policyMap.get(ResourceReferenceFunctions.GET_ATTR.getFunction()); + //noinspection SuspiciousMethodCalls + if (CollectionUtils.isNotEmpty(securityGroupList)) { + //noinspection SuspiciousMethodCalls + networkPolicyResourceNames.remove(securityGroupList.get(0)); + } + } + } + } + + + private static void getResourceNamesListFromSpecificResource(String filename, + List resourcesNames, + HeatResourcesTypes heatResourcesType, + Map resourcesMap, + Set sharedResourcesFromOutputMap, + GlobalValidationContext globalContext) { + + for (Map.Entry resourceEntry : resourcesMap.entrySet()) { + String resourceType = resourceEntry.getValue().getType(); + if (Objects.isNull(resourceType)) { + globalContext.addMessage(filename, ErrorLevel.WARNING, ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.INVALID_RESOURCE_TYPE.getErrorMessage(), null, + resourceEntry.getKey())); + } else { + if (resourceType.equals(heatResourcesType.getHeatResource()) + && !isSharedResource(resourceEntry.getKey(), sharedResourcesFromOutputMap)) { + resourcesNames.add(resourceEntry.getKey()); + } + } + } + } + + + private static boolean isSharedResource(String resourceName, + Set sharedResourcesFromOutputMap) { + return !CollectionUtils.isEmpty(sharedResourcesFromOutputMap) + && sharedResourcesFromOutputMap.contains(resourceName); + } + + /** + * Handle not empty resource names list. + * + * @param fileName the file name + * @param resourcesNameList the resources name list + * @param securityOrServerGroup the security or server group + * @param globalContext the global context + */ + public static void handleNotEmptyResourceNamesList(String fileName, + Collection resourcesNameList, + String securityOrServerGroup, + GlobalValidationContext globalContext) { + if (CollectionUtils.isNotEmpty(resourcesNameList)) { + resourcesNameList.forEach(name -> + globalContext + .addMessage( + fileName, + ErrorLevel.WARNING, + ErrorMessagesFormatBuilder + .getErrorWithParameters( + Messages.SERVER_OR_SECURITY_GROUP_NOT_IN_USE.getErrorMessage(), + securityOrServerGroup, name))); + } + } + + + private static void initVisitedPortsMap(String filename, Map resourceMap, + Map numberOfVisitsInPort, + GlobalValidationContext globalContext) { + for (Map.Entry resourceEntry : resourceMap.entrySet()) { + String resourceType = resourceEntry.getValue().getType(); + + if (Objects.isNull(resourceType)) { + globalContext.addMessage(filename, ErrorLevel.WARNING, ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.INVALID_RESOURCE_TYPE.getErrorMessage(), "null", + resourceEntry.getKey())); + } else { + if (resourceType.equals(HeatResourcesTypes.NEUTRON_PORT_RESOURCE_TYPE.getHeatResource())) { + numberOfVisitsInPort.put(resourceEntry.getKey(), 0); + } + } + } + } + + private static boolean checkIfPortWasVisited(String resourcePortName, + Map numberOfVisitsInPort) { + return numberOfVisitsInPort.containsKey(resourcePortName) + && numberOfVisitsInPort.get(resourcePortName) == 1; + } + + + private static void incrementNumberOfVisitsInPort(String resourcePortName, + Map numberOfVisitsInPort) { + if (numberOfVisitsInPort.containsKey(resourcePortName)) { + numberOfVisitsInPort.put(resourcePortName, numberOfVisitsInPort.get(resourcePortName) + 1); + } + } + + + private static void handleOrphanPorts(String fileName, Map numberOfVisitsInPort, + GlobalValidationContext globalContext) { + numberOfVisitsInPort + .entrySet() + .stream() + .filter(entry -> entry.getValue() == 0) + .forEach(entry -> + globalContext + .addMessage( + fileName, + ErrorLevel.WARNING, + ErrorMessagesFormatBuilder + .getErrorWithParameters( + Messages.PORT_NO_BIND_TO_ANY_NOVA_SERVER.getErrorMessage(), + entry.getKey()))); + } + + @SuppressWarnings("unchecked") + private static void checkResourceDependsOn(String fileName, Resource resource, + Set resourcesNames, + GlobalValidationContext globalContext) { + Object dependencies = resource.getDepends_on(); + if (dependencies instanceof Collection) { + ((Collection) dependencies) + .stream() + .filter(resource_id -> !resourcesNames.contains(resource_id)) + .forEach(resource_id -> globalContext.addMessage(fileName, ErrorLevel.ERROR, + ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.MISSING_RESOURCE_IN_DEPENDS_ON.getErrorMessage(), + (String) resource_id))); + } else if (dependencies instanceof String) { + if (!resourcesNames.contains(dependencies)) { + globalContext.addMessage(fileName, ErrorLevel.ERROR, ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.MISSING_RESOURCE_IN_DEPENDS_ON.getErrorMessage(), + (String) dependencies)); + } + } + } + + + private static void checkPortBindingFromMap(String fileName, Map portValueMap, + Map numberOfVisitsInPort, + GlobalValidationContext globalContext) { + String resourcePortName = + (String) portValueMap.get(ResourceReferenceFunctions.GET_RESOURCE.getFunction()); + if (checkIfPortWasVisited(resourcePortName, numberOfVisitsInPort)) { + globalContext.addMessage(fileName, ErrorLevel.ERROR, ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.MORE_THAN_ONE_BIND_FROM_NOVA_TO_PORT.getErrorMessage(), + (String) portValueMap.get(ResourceReferenceFunctions.GET_RESOURCE.getFunction()))); + } else { + incrementNumberOfVisitsInPort(resourcePortName, numberOfVisitsInPort); + } + } + + + private static void initResourceTypeListWithItsResourcesNames(String filename, + Map> resourcesTypesListMap, + Map resourcesMap, + Set sharedResourcesFromOutputsMap, + GlobalValidationContext globalContext) { + for (Map.Entry> resourcesTypesToListEntry + : resourcesTypesListMap.entrySet()) { + HeatResourcesTypes currentType = resourcesTypesToListEntry.getKey(); + List currNamesList = new ArrayList<>(); + getResourceNamesListFromSpecificResource(filename, currNamesList, currentType, resourcesMap, + sharedResourcesFromOutputsMap, globalContext); + resourcesTypesListMap.put(currentType, currNamesList); + } + } + + + private static void checkForEmptyResourceNamesInMap(String fileName, + boolean isBaseFileContainPorts, + Map> resourcesTypesListMap, + GlobalValidationContext globalContext) { + if (isBaseFileContainPorts) { + for (Map.Entry> resourcesTypesListEntry + : resourcesTypesListMap.entrySet()) { + handleNotEmptyResourceNamesList(fileName, resourcesTypesListEntry.getValue(), + ResourceTypeToMessageString + .getTypeForMessageFromResourceType(resourcesTypesListEntry.getKey()), + globalContext); + } + } + } + + + private static Set getSharedResourcesNamesFromOutputs(String filename, + Map outputsMap, + GlobalValidationContext globalContext) { + Set sharedResources = new HashSet<>(); + + if (MapUtils.isEmpty(outputsMap)) { + return null; + } + + for (Map.Entry outputEntry : outputsMap.entrySet()) { + Output output = outputEntry.getValue(); + Object valueObject = output.getValue(); + if (valueObject instanceof Map) { + Map outputValueMap = (Map) valueObject; + Object getResourceValue = + outputValueMap.get(ResourceReferenceFunctions.GET_RESOURCE.getFunction()); + if (Objects.nonNull(getResourceValue)) { + if (getResourceValue instanceof String) { + String resourceName = + (String) outputValueMap.get(ResourceReferenceFunctions.GET_RESOURCE.getFunction()); + sharedResources.add(resourceName); + } else { + globalContext.addMessage(filename, ErrorLevel.ERROR, ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.INVALID_GET_RESOURCE_SYNTAX.getErrorMessage(), + getResourceValue.toString())); + } + } + + } + } + + return sharedResources; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/main/java/org/openecomp/sdc/validation/impl/validators/EcompGuideLineValidator.java b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/main/java/org/openecomp/sdc/validation/impl/validators/EcompGuideLineValidator.java new file mode 100644 index 0000000000..5be56e4b38 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/main/java/org/openecomp/sdc/validation/impl/validators/EcompGuideLineValidator.java @@ -0,0 +1,784 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.validation.impl.validators; + +import org.apache.commons.collections4.CollectionUtils; +import org.apache.commons.collections4.MapUtils; +import org.openecomp.core.utilities.CommonMethods; +import org.openecomp.core.utilities.yaml.YamlUtil; +import org.openecomp.core.validation.errors.ErrorMessagesFormatBuilder; +import org.openecomp.core.validation.errors.Messages; +import org.openecomp.core.validation.interfaces.Validator; +import org.openecomp.core.validation.types.GlobalValidationContext; +import org.openecomp.sdc.common.utils.AsdcCommon; +import org.openecomp.sdc.datatypes.error.ErrorLevel; +import org.openecomp.sdc.datatypes.model.heat.ForbiddenHeatResourceTypes; +import org.openecomp.sdc.heat.datatypes.DefinedHeatParameterTypes; +import org.openecomp.sdc.heat.datatypes.manifest.FileData; +import org.openecomp.sdc.heat.datatypes.manifest.ManifestContent; +import org.openecomp.sdc.heat.datatypes.model.Environment; +import org.openecomp.sdc.heat.datatypes.model.HeatOrchestrationTemplate; +import org.openecomp.sdc.heat.datatypes.model.HeatResourcesTypes; +import org.openecomp.sdc.heat.datatypes.model.Resource; +import org.openecomp.sdc.heat.datatypes.model.ResourceReferenceFunctions; +import org.openecomp.sdc.heat.services.HeatStructureUtil; +import org.openecomp.sdc.heat.services.manifest.ManifestUtil; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.Comparator; +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.Set; +import java.util.TreeMap; +import java.util.regex.Pattern; + +public class EcompGuideLineValidator extends HeatValidator implements Validator { + @Override + public void validate(GlobalValidationContext globalContext) { + + ManifestContent manifestContent; + try { + manifestContent = checkValidationPreCondition(globalContext); + } catch (Exception exception) { + return; + } + + //global validations + Set baseFiles = validateManifest(manifestContent, globalContext); + + Map fileTypeMap = ManifestUtil.getFileTypeMap(manifestContent); + Map fileEnvMap = ManifestUtil.getFileAndItsEnv(manifestContent); + globalContext + .getFiles() + .stream() + .filter(fileName -> FileData + .isHeatFile(fileTypeMap.get(fileName))) + .forEach(fileName -> validate(fileName, + fileEnvMap.get(fileName) != null ? fileEnvMap.get(fileName).getFile() : null, + fileTypeMap, baseFiles, globalContext)); + } + + private void validate(String fileName, String envFileName, Map fileTypeMap, + Set baseFiles, GlobalValidationContext globalContext) { + HeatOrchestrationTemplate heatOrchestrationTemplate = + checkHeatOrchestrationPreCondition(fileName, globalContext); + if (heatOrchestrationTemplate == null) { + return; + } + + validateBaseFile(fileName, baseFiles, heatOrchestrationTemplate, globalContext); + validateHeatVolumeFile(fileName, fileTypeMap, heatOrchestrationTemplate, globalContext); + validateHeatNamingConvention(fileName, heatOrchestrationTemplate, globalContext); + validateHeatNovaResource(fileName, envFileName, heatOrchestrationTemplate, globalContext); + validateResourceTypeIsForbidden(fileName, heatOrchestrationTemplate, globalContext); + validateFixedIpsNamingConvention(fileName, heatOrchestrationTemplate, globalContext); + } + + private void validateHeatNovaResource(String fileName, String envFileName, + HeatOrchestrationTemplate heatOrchestrationTemplate, + GlobalValidationContext globalContext) { + Map uniqueResourcePortNetworkRole = new HashMap<>(); + //if no resources exist return + if (heatOrchestrationTemplate.getResources() == null + || heatOrchestrationTemplate.getResources().size() == 0) { + return; + } + + heatOrchestrationTemplate + .getResources() + .entrySet() + .stream() + .filter(entry -> entry.getValue().getType() + .equals(HeatResourcesTypes.NOVA_SERVER_RESOURCE_TYPE.getHeatResource())) + .forEach(entry -> validateNovaServerResourceType(entry.getKey(), fileName, envFileName, + entry, uniqueResourcePortNetworkRole, heatOrchestrationTemplate, globalContext)); + } + + private void validateNovaServerResourceType(String resourceId, String fileName, + String envFileName, + Map.Entry resourceEntry, + Map uniqueResourcePortNetworkRole, + HeatOrchestrationTemplate heatOrchestrationTemplate, + GlobalValidationContext globalValidationContext) { + validateNovaServerResourceMetaData(fileName, resourceId, + heatOrchestrationTemplate.getResources().get(resourceId), globalValidationContext); + validateNovaServerResourceNetworkUniqueRole(fileName, resourceId, heatOrchestrationTemplate, + globalValidationContext); + validateNovaServerNamingConvention(fileName, envFileName, resourceEntry, + globalValidationContext); + validateNovaServerAvailabilityZoneName(fileName, resourceEntry, globalValidationContext); + validateImageAndFlavorFromNovaServer(fileName, resourceEntry, globalValidationContext); + } + + @SuppressWarnings("unchecked") + private void validateNovaServerResourceMetaData(String fileName, String resourceId, + Resource resource, + GlobalValidationContext globalValidationContext) { + Map novaServerProp = resource.getProperties(); + Object novaServerPropMetadata; + if (MapUtils.isNotEmpty(novaServerProp)) { + novaServerPropMetadata = novaServerProp.get("metadata"); + if (novaServerPropMetadata == null) { + globalValidationContext.addMessage( + fileName, + ErrorLevel.WARNING, + ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.MISSING_NOVA_SERVER_METADATA.getErrorMessage(), + resourceId)); + } else if (novaServerPropMetadata instanceof Map) { + TreeMap propertyMap = new TreeMap(new Comparator() { + + @Override + public int compare(String o1, String o2) { + return o1.compareToIgnoreCase(o2); + } + + @Override + public boolean equals(Object obj) { + return false; + } + }); + propertyMap.putAll((Map) novaServerPropMetadata); + if (!propertyMap.containsKey("vf_module_id")) { + globalValidationContext.addMessage(fileName, ErrorLevel.WARNING, + ErrorMessagesFormatBuilder.getErrorWithParameters( + Messages.MISSING_NOVA_SERVER_VF_MODULE_ID.getErrorMessage(), resourceId)); + } + if (!propertyMap.containsKey("vnf_id")) { + globalValidationContext.addMessage(fileName, ErrorLevel.WARNING, + ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.MISSING_NOVA_SERVER_VNF_ID.getErrorMessage(), + resourceId)); + } + } + } + } + + private void validateNovaServerResourceNetworkUniqueRole(String fileName, String resourceId, + HeatOrchestrationTemplate + heatOrchestrationTemplate, + GlobalValidationContext + globalValidationContext) { + + String network; + String role; + Map uniqueResourcePortNetworkRole = new HashMap<>(); + + Object propertyNetworkValue = + heatOrchestrationTemplate.getResources().get(resourceId).getProperties().get("networks"); + if (propertyNetworkValue != null && propertyNetworkValue instanceof List) { + List portResourceIdList = + getNovaNetworkPortResourceList(fileName, (List) propertyNetworkValue, + globalValidationContext); + for (String portResourceId : portResourceIdList) { + Resource portResource = heatOrchestrationTemplate.getResources().get(portResourceId); + if (portResource != null && portResource.getType() + .equals(HeatResourcesTypes.NEUTRON_PORT_RESOURCE_TYPE.getHeatResource())) { + Map portNetwork = + getPortNetwork(fileName, resourceId, portResource, globalValidationContext); + if (Objects.nonNull(portNetwork)) { + network = (String) portNetwork.get("get_param"); + if (Objects.nonNull(network)) { + role = getNetworkRole(network); + if (role != null && uniqueResourcePortNetworkRole.containsKey(role)) { + globalValidationContext.addMessage(fileName, ErrorLevel.WARNING, + ErrorMessagesFormatBuilder.getErrorWithParameters( + Messages.RESOURCE_CONNECTED_TO_TWO_EXTERNAL_NETWORKS_WITH_SAME_ROLE + .getErrorMessage(), resourceId, role)); + } else { + uniqueResourcePortNetworkRole.put(role, portResourceId); + } + } + } + } + } + } + } + + + private Map getPortNetwork(String fileName, String resourceId, Resource portResource, + GlobalValidationContext globalValidationContext) { + Object portNetwork = portResource.getProperties().get("network_id"); + if (portNetwork == null) { + portNetwork = portResource.getProperties().get("network"); + } + if (!(portNetwork instanceof Map)) { + globalValidationContext.addMessage(fileName, ErrorLevel.WARNING, ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.MISSING_GET_PARAM.getErrorMessage(), + "network or network_id", resourceId)); + return null; + } + return (Map) portNetwork; + } + + private List getNovaNetworkPortResourceList(String filename, List propertyNetworkValue, + GlobalValidationContext globalContext) { + List portResourceIdList = new ArrayList<>(); + for (Object propValue : propertyNetworkValue) { + Object portPropValue = ((Map) propValue).get("port"); + Collection portResourceIds = HeatStructureUtil + .getReferencedValuesByFunctionName(filename, "get_resource", portPropValue, + globalContext); + if (portResourceIds != null) { + portResourceIdList.addAll(portResourceIds); + } + } + + return portResourceIdList; + } + + private String getNetworkRole(String network) { + if (network == null) { + return null; + } + if (network.contains("_net_id")) { + return network.substring(0, network.indexOf("_net_id")); + } else if (network.contains("net_name")) { + return network.substring(0, network.indexOf("_net_name")); + } else if (network.contains("net_fqdn")) { + return network.substring(0, network.indexOf("_net_fqdn")); + } + return null; + } + + private void validateHeatNamingConvention(String fileName, + HeatOrchestrationTemplate heatOrchestrationTemplate, + GlobalValidationContext globalContext) { + validatePortNetworkNamingConvention(fileName, heatOrchestrationTemplate, globalContext); + } + + private void validatePortNetworkNamingConvention(String fileName, + HeatOrchestrationTemplate + heatOrchestrationTemplate, + GlobalValidationContext globalContext) { + if (MapUtils.isEmpty(heatOrchestrationTemplate.getResources())) { + return; + } + String[] regexList = new String[]{".*_net_id", ".*_net_name", ".*_net_fqdn"}; + + heatOrchestrationTemplate + .getResources() + .entrySet() + .stream() + .filter(entry -> entry.getValue().getType() != null && entry.getValue().getType() + .equals(HeatResourcesTypes.NEUTRON_PORT_RESOURCE_TYPE.getHeatResource())) + .forEach(entry -> entry.getValue() + .getProperties() + .entrySet() + .stream() + .filter(propertyEntry -> propertyEntry != null + && (propertyEntry.getKey().toLowerCase().equals("network".toLowerCase()) + || + propertyEntry.getKey().equals("network_id"))) + .forEach(propertyEntry -> validateParamNamingConvention(fileName, entry.getKey(), + propertyEntry.getValue(), regexList, + Messages.NETWORK_PARAM_NOT_ALIGNED_WITH_GUIDE_LINE, globalContext))); + } + + private void validateParamNamingConvention(String fileName, String resourceId, + Object propertyValue, String[] regexList, + Messages message, + GlobalValidationContext globalContext) { + Object paramName; + if (propertyValue instanceof Map) { + paramName = ((Map) propertyValue).get("get_param"); + if (paramName instanceof String) { + if (!evalPattern((String) paramName, regexList)) { + globalContext.addMessage(fileName, ErrorLevel.WARNING, ErrorMessagesFormatBuilder + .getErrorWithParameters(message.getErrorMessage(), (String) paramName, resourceId)); + } + } + } else { + globalContext.addMessage(fileName, ErrorLevel.WARNING, ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.MISSING_GET_PARAM.getErrorMessage(), + "network or network_id", resourceId)); + } + } + + private boolean evalPattern(Object paramVal, String[] regexList) { + String value = ""; + if (paramVal instanceof String) { + value = ((String) paramVal); + } + if (paramVal instanceof Integer) { + value = paramVal.toString(); + } + return evalPattern(value, regexList); + } + + private boolean evalPattern(String paramVal, String[] regexList) { + + for (String regex : regexList) { + if (Pattern.matches(regex, paramVal)) { + return true; + } + } + + return false; + } + + + private void validateHeatVolumeFile(String fileName, Map fileTypeMap, + HeatOrchestrationTemplate heatOrchestrationTemplate, + GlobalValidationContext globalContext) { + //if not heat volume return + if (!fileTypeMap.get(fileName).equals(FileData.Type.HEAT_VOL)) { + return; + } + + //if no resources exist return + if (heatOrchestrationTemplate.getResources() == null + || heatOrchestrationTemplate.getResources().size() == 0) { + return; + } + + Set expectedExposedResources = new HashSet<>(); + Set actualExposedResources = new HashSet<>(); + heatOrchestrationTemplate.getResources() + .entrySet() + .stream() + .filter(entry -> entry.getValue().getType() + .equals(HeatResourcesTypes.CINDER_VOLUME_RESOURCE_TYPE.getHeatResource())) + .forEach(entry -> expectedExposedResources.add(entry.getKey())); + + if (heatOrchestrationTemplate.getOutputs() != null) { + + heatOrchestrationTemplate.getOutputs().entrySet() + .stream() + .filter(entry -> isPropertyValueGetResource(fileName, entry.getValue().getValue(), + globalContext)) + .forEach(entry -> actualExposedResources.add( + getResourceIdFromPropertyValue(fileName, entry.getValue().getValue(), + globalContext))); + } + + actualExposedResources.stream().forEach(expectedExposedResources::remove); + + if (expectedExposedResources.size() > 0) { + expectedExposedResources + .stream() + .forEach(name -> globalContext.addMessage(fileName, ErrorLevel.WARNING, + ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.VOLUME_HEAT_NOT_EXPOSED.getErrorMessage(), + name))); + } + } + + private void validateBaseFile(String fileName, Set baseFiles, + HeatOrchestrationTemplate heatOrchestrationTemplate, + GlobalValidationContext globalContext) { + + //if not base return + if (baseFiles == null || !baseFiles.contains(fileName)) { + return; + } + + //if no resources exist return + if (heatOrchestrationTemplate.getResources() == null + || heatOrchestrationTemplate.getResources().size() == 0) { + return; + } + + Set expectedExposedResources = new HashSet<>(); + Set actualExposedResources = new HashSet<>(); + heatOrchestrationTemplate.getResources() + .entrySet() + .stream() + .filter(entry -> isExpectedToBeExposed(entry.getValue().getType())) + .forEach(entry -> expectedExposedResources.add(entry.getKey())); + + if (heatOrchestrationTemplate.getOutputs() != null) { + + heatOrchestrationTemplate.getOutputs().entrySet() + .stream() + .filter(entry -> isPropertyValueGetResource(fileName, entry.getValue().getValue(), + globalContext)) + .forEach(entry -> actualExposedResources.add( + getResourceIdFromPropertyValue(fileName, entry.getValue().getValue(), + globalContext))); + } + actualExposedResources.stream().forEach(expectedExposedResources::remove); + + if (expectedExposedResources.size() > 0) { + expectedExposedResources + .stream() + .forEach(name -> globalContext.addMessage(fileName, ErrorLevel.WARNING, + ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.RESOURCE_NOT_DEFINED_IN_OUTPUT.getErrorMessage(), + name))); + } + } + + private void validateResourceTypeIsForbidden(String fileName, + HeatOrchestrationTemplate heatOrchestrationTemplate, + GlobalValidationContext globalContext) { + if (MapUtils.isEmpty(heatOrchestrationTemplate.getResources())) { + return; + } + + heatOrchestrationTemplate.getResources() + .entrySet() + .stream() + .filter(entry -> + ForbiddenHeatResourceTypes.findByForbiddenHeatResource(entry.getValue().getType()) + != null) + .filter(entry -> ForbiddenHeatResourceTypes + .findByForbiddenHeatResource(entry.getValue().getType()) + .equals(ForbiddenHeatResourceTypes.HEAT_FLOATING_IP_TYPE)) + .forEach(entry -> globalContext.addMessage(fileName, ErrorLevel.WARNING, + ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.FLOATING_IP_NOT_IN_USE.getErrorMessage(), + entry.getKey()))); + } + + + private void validateFixedIpsNamingConvention(String fileName, + HeatOrchestrationTemplate heatOrchestrationTemplate, + GlobalValidationContext globalContext) { + if (MapUtils.isEmpty(heatOrchestrationTemplate.getResources())) { + return; + } + + heatOrchestrationTemplate.getResources() + .entrySet() + .stream() + .filter(entry -> HeatResourcesTypes.findByHeatResource(entry.getValue().getType()) != null) + .filter(entry -> HeatResourcesTypes.findByHeatResource(entry.getValue().getType()) + .equals(HeatResourcesTypes.NEUTRON_PORT_RESOURCE_TYPE)) + .forEach(entry -> checkNeutronPortFixedIpsName(fileName, entry, globalContext)); + } + + private void validateImageAndFlavorFromNovaServer(String fileName, + Map.Entry resourceEntry, + GlobalValidationContext globalContext) { + if (MapUtils.isEmpty(resourceEntry.getValue().getProperties())) { + return; + } + + String[] imageOrFlavorAsParameters = new String[]{"image", "flavor"}; + Map propertiesMap = resourceEntry.getValue().getProperties(); + + for (String imageOrFlavor : imageOrFlavorAsParameters) { + checkImageAndFlavorNames(fileName, imageOrFlavor, resourceEntry.getKey(), propertiesMap, + globalContext); + } + } + + private void checkImageAndFlavorNames(String fileName, String imageOrFlavor, String resourceId, + Map propertiesMap, + GlobalValidationContext globalContext) { + Object nameValue = + propertiesMap.get(imageOrFlavor) == null ? null : propertiesMap.get(imageOrFlavor); + String[] regexList = new String[]{".*_" + imageOrFlavor + "_name"}; + + if (Objects.nonNull(nameValue)) { + if (nameValue instanceof Map) { + String imageOrFlavorName = getWantedNameFromPropertyValueGetParam(nameValue); + if (Objects.nonNull(imageOrFlavorName)) { + if (!evalPattern(imageOrFlavorName, regexList)) { + globalContext.addMessage(fileName, ErrorLevel.WARNING, ErrorMessagesFormatBuilder + .getErrorWithParameters( + Messages.WRONG_IMAGE_OR_FLAVOR_NAME_NOVA_SERVER.getErrorMessage(), + imageOrFlavor, resourceId)); + } + } + } else { + globalContext.addMessage(fileName, ErrorLevel.WARNING, ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.MISSING_GET_PARAM.getErrorMessage(), imageOrFlavor, + resourceId)); + } + } + } + + + @SuppressWarnings("unchecked") + private void checkNeutronPortFixedIpsName(String fileName, + Map.Entry resourceEntry, + GlobalValidationContext globalContext) { + String[] regexList = + new String[]{"[^_]+_[^_]+_ips", "[^_]+_[^_]+_v6_ips", "[^_]+_[^_]+_ip_(\\d+)", + "[^_]+_[^_]+_v6_ip_(\\d+)"}; + + if (MapUtils.isEmpty(resourceEntry.getValue().getProperties())) { + return; + } + + Map propertiesMap = resourceEntry.getValue().getProperties(); + Object fixedIps = propertiesMap.get("fixed_ips"); + if (Objects.nonNull(fixedIps) && fixedIps instanceof List) { + List fixedIpsList = (List) fixedIps; + for (Object fixedIpsObject : fixedIpsList) { + Map.Entry fixedIpsEntry = + ((Map) fixedIpsObject).entrySet().iterator().next(); + if (Objects.nonNull(fixedIpsEntry)) { + if (fixedIpsEntry.getValue() instanceof Map) { + String fixedIpsName = getWantedNameFromPropertyValueGetParam(fixedIpsEntry.getValue()); + if (Objects.nonNull(fixedIpsName)) { + if (!evalPattern(fixedIpsName, regexList)) { + globalContext.addMessage(fileName, ErrorLevel.WARNING, ErrorMessagesFormatBuilder + .getErrorWithParameters( + Messages.FIXED_IPS_NOT_ALIGNED_WITH_GUIDE_LINES.getErrorMessage(), + resourceEntry.getKey())); + } + } + } else { + globalContext.addMessage(fileName, ErrorLevel.WARNING, ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.MISSING_GET_PARAM.getErrorMessage(), "fixed_ips", + resourceEntry.getKey())); + } + } + } + } + } + + + private void validateNovaServerNamingConvention(String fileName, String envFileName, + Map.Entry resourceEntry, + GlobalValidationContext globalContext) { + if (MapUtils.isEmpty(resourceEntry.getValue().getProperties())) { + return; + } + + checkIfNovaNameByGuidelines(fileName, envFileName, resourceEntry, globalContext); + } + + private void checkIfNovaNameByGuidelines(String fileName, String envFileName, + Map.Entry resourceEntry, + GlobalValidationContext globalContext) { + if (MapUtils.isEmpty(resourceEntry.getValue().getProperties())) { + return; + } + + Object novaServerName = resourceEntry.getValue().getProperties().get("name"); + Map novaNameMap; + String novaName; + if (Objects.nonNull(novaServerName)) { + if (novaServerName instanceof Map) { + novaNameMap = (Map) novaServerName; + Object novaNameGetParam = + novaNameMap.get(ResourceReferenceFunctions.GET_PARAM.getFunction()) == null ? null + : novaNameMap.get(ResourceReferenceFunctions.GET_PARAM.getFunction()); + if (Objects.nonNull(novaNameGetParam)) { + checkNovaNameGetParamValueMap(fileName, novaNameGetParam, resourceEntry, globalContext); + novaName = novaNameGetParam instanceof List ? (String) ((List) novaNameGetParam).get(0) + : (String) novaNameGetParam; + checkIfNovaNameParameterInEnvIsStringOrList(fileName, envFileName, resourceEntry, + novaName, globalContext); + } + } else { + globalContext.addMessage(fileName, ErrorLevel.WARNING, ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.MISSING_GET_PARAM.getErrorMessage(), + "nova server name", resourceEntry.getKey())); + } + } + + } + + private void checkIfNovaNameParameterInEnvIsStringOrList(String fileName, String envFileName, + Map.Entry + resourceEntry, + String novaServerName, + GlobalValidationContext globalContext) { + if (Objects.nonNull(envFileName)) { + Environment environment = validateEnvContent(envFileName, globalContext); + + if (environment != null && MapUtils.isNotEmpty(environment.getParameters())) { + Object novaServerNameEnvValue = + environment.getParameters().containsKey(novaServerName) ? environment.getParameters() + .get(novaServerName) : null; + if (Objects.nonNull(novaServerNameEnvValue)) { + if (!DefinedHeatParameterTypes + .isNovaServerEnvValueIsFromRightType(novaServerNameEnvValue)) { + globalContext.addMessage(fileName, ErrorLevel.WARNING, ErrorMessagesFormatBuilder + .getErrorWithParameters( + Messages.NOVA_SERVER_NAME_NOT_ALIGNED_WITH_GUIDE_LINES.getErrorMessage(), + resourceEntry.getKey())); + } + } + } + } + } + + + private void validateNovaServerAvailabilityZoneName(String fileName, + Map.Entry resourceEntry, + GlobalValidationContext globalContext) { + String[] regexList = new String[]{"availability_zone_(\\d+)"}; + + if (MapUtils.isEmpty(resourceEntry.getValue().getProperties())) { + return; + } + + Object availabilityZoneMap = + resourceEntry.getValue().getProperties().containsKey("availability_zone") ? resourceEntry + .getValue().getProperties().get("availability_zone") : null; + + if (Objects.nonNull(availabilityZoneMap)) { + if (availabilityZoneMap instanceof Map) { + String availabilityZoneName = getWantedNameFromPropertyValueGetParam(availabilityZoneMap); + + if (availabilityZoneName != null) { + if (!evalPattern(availabilityZoneName, regexList)) { + globalContext.addMessage(fileName, ErrorLevel.WARNING, ErrorMessagesFormatBuilder + .getErrorWithParameters( + Messages.AVAILABILITY_ZONE_NOT_ALIGNED_WITH_GUIDE_LINES.getErrorMessage(), + resourceEntry.getKey())); + } + } + } else { + globalContext.addMessage(fileName, ErrorLevel.WARNING, ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.MISSING_GET_PARAM.getErrorMessage(), + "availability_zone", resourceEntry.getKey())); + } + } + + } + + @SuppressWarnings("unchecked") + private void checkNovaNameGetParamValueMap(String fileName, Object getParamValue, + Map.Entry resourceEntry, + GlobalValidationContext globalContext) { + if (getParamValue instanceof List) { + List getParamNameList = (List) getParamValue; + String[] regexName = new String[]{".*_names"}; + isNovaNameAsListLegal(fileName, getParamNameList, regexName, resourceEntry, globalContext); + } else if (getParamValue instanceof String) { + String[] regexName = new String[]{".*_name_(\\d+)"}; + isNovaNameAsStringLegal(fileName, (String) getParamValue, regexName, resourceEntry, + globalContext); + } + + } + + + private void isNovaNameAsListLegal(String fileName, List getParamNameList, + String[] regexName, Map.Entry resourceEntry, + GlobalValidationContext globalContext) { + + if (getParamNameList.size() != 2 || !evalPattern(getParamNameList.get(0), regexName)) { + globalContext.addMessage(fileName, ErrorLevel.WARNING, ErrorMessagesFormatBuilder + .getErrorWithParameters( + Messages.NOVA_SERVER_NAME_NOT_ALIGNED_WITH_GUIDE_LINES.getErrorMessage(), + resourceEntry.getKey())); + } + } + + private boolean isNovaNameAsStringLegal(String fileName, String novaName, String[] regexName, + Map.Entry resourceEntry, + GlobalValidationContext globalContext) { + if (!evalPattern(novaName, regexName)) { + globalContext.addMessage(fileName, ErrorLevel.WARNING, ErrorMessagesFormatBuilder + .getErrorWithParameters( + Messages.NOVA_SERVER_NAME_NOT_ALIGNED_WITH_GUIDE_LINES.getErrorMessage(), + resourceEntry.getKey())); + return false; + } + return true; + } + + private String getWantedNameFromPropertyValueGetParam(Object value) { + Set paramName = HeatStructureUtil + .getReferencedValuesByFunctionName(null, ResourceReferenceFunctions.GET_PARAM.getFunction(), + value, null); + if (paramName != null && CollectionUtils.isNotEmpty(paramName)) { + return (String) paramName.toArray()[0]; + } + return null; + } + + private String getResourceIdFromPropertyValue(String filename, Object value, + GlobalValidationContext globalContext) { + Set referenceValues = HeatStructureUtil.getReferencedValuesByFunctionName(filename, + ResourceReferenceFunctions.GET_RESOURCE.getFunction(), value, globalContext); + if (referenceValues != null && CollectionUtils.isNotEmpty(referenceValues)) { + return (String) referenceValues.toArray()[0]; + } + return null; + } + + private boolean isPropertyValueGetResource(String filename, Object value, + GlobalValidationContext globalContext) { + Set referenceValues = HeatStructureUtil.getReferencedValuesByFunctionName(filename, + ResourceReferenceFunctions.GET_RESOURCE.getFunction(), value, globalContext); + return referenceValues != null && (referenceValues.size() > 0); + } + + private boolean isExpectedToBeExposed(String type) { + return HeatResourcesTypes.isResourceExpectedToBeExposed(type); + } + + private Set validateManifest(ManifestContent manifestContent, + GlobalValidationContext globalContext) { + Set baseFiles = ManifestUtil.getBaseFiles(manifestContent); + if (baseFiles == null || baseFiles.size() == 0) { + globalContext.addMessage( + AsdcCommon.MANIFEST_NAME, + ErrorLevel.WARNING, + ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.MISSIN_BASE_HEAT_FILE.getErrorMessage())); + } else if (baseFiles.size() > 1) { + String baseFileList = getElementListAsString(baseFiles); + globalContext.addMessage( + AsdcCommon.MANIFEST_NAME, + ErrorLevel.WARNING, + ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.MULTI_BASE_HEAT_FILE.getErrorMessage(), + baseFileList)); + } + return baseFiles; + } + + private String getElementListAsString(Set elementCollection) { + + return "[" + CommonMethods.collectionToCommaSeparatedString(elementCollection) + "]"; + } + + + private Environment validateEnvContent(String envFileName, + GlobalValidationContext globalContext) { + Environment envContent; + try { + envContent = + new YamlUtil().yamlToObject(globalContext.getFileContent(envFileName), Environment.class); + } catch (Exception exception) { + return null; + } + return envContent; + } + + private HeatOrchestrationTemplate checkHeatOrchestrationPreCondition(String fileName, + GlobalValidationContext + globalContext) { + HeatOrchestrationTemplate heatOrchestrationTemplate; + try { + heatOrchestrationTemplate = new YamlUtil() + .yamlToObject(globalContext.getFileContent(fileName), HeatOrchestrationTemplate.class); + + } catch (Exception exception) { + return null; + } + return heatOrchestrationTemplate; + } +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/main/java/org/openecomp/sdc/validation/impl/validators/HeatValidator.java b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/main/java/org/openecomp/sdc/validation/impl/validators/HeatValidator.java new file mode 100644 index 0000000000..c287394a54 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/main/java/org/openecomp/sdc/validation/impl/validators/HeatValidator.java @@ -0,0 +1,469 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.validation.impl.validators; + +import org.apache.commons.collections4.CollectionUtils; +import org.apache.commons.collections4.MapUtils; +import org.openecomp.core.utilities.json.JsonUtil; +import org.openecomp.core.utilities.yaml.YamlUtil; +import org.openecomp.core.validation.errors.ErrorMessagesFormatBuilder; +import org.openecomp.core.validation.errors.Messages; +import org.openecomp.core.validation.interfaces.Validator; +import org.openecomp.core.validation.types.GlobalValidationContext; +import org.openecomp.sdc.common.utils.AsdcCommon; +import org.openecomp.sdc.datatypes.error.ErrorLevel; +import org.openecomp.sdc.heat.datatypes.DefinedHeatParameterTypes; +import org.openecomp.sdc.heat.datatypes.manifest.FileData; +import org.openecomp.sdc.heat.datatypes.manifest.ManifestContent; +import org.openecomp.sdc.heat.datatypes.model.Environment; +import org.openecomp.sdc.heat.datatypes.model.HeatOrchestrationTemplate; +import org.openecomp.sdc.heat.datatypes.model.HeatPseudoParameters; +import org.openecomp.sdc.heat.datatypes.model.HeatResourcesTypes; +import org.openecomp.sdc.heat.datatypes.model.Output; +import org.openecomp.sdc.heat.datatypes.model.Parameter; +import org.openecomp.sdc.heat.datatypes.model.Resource; +import org.openecomp.sdc.heat.datatypes.model.ResourceReferenceFunctions; +import org.openecomp.sdc.heat.services.HeatStructureUtil; +import org.openecomp.sdc.heat.services.manifest.ManifestUtil; +import org.openecomp.sdc.validation.impl.util.HeatValidationService; +import org.openecomp.sdc.validation.impl.util.ResourceValidationHeatValidator; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import java.io.InputStream; +import java.util.Collection; +import java.util.HashSet; +import java.util.Map; +import java.util.Objects; +import java.util.Set; + +public class HeatValidator implements Validator { + + protected static Logger logger = LoggerFactory.getLogger(HeatValidator.class); + + /* validation 9*/ + private static void validateAllRequiredArtifactsExist(String fileName, + HeatOrchestrationTemplate heatOrchestrationTemplate, + Set artifacts, + GlobalValidationContext globalContext) { + Collection resourcesValues = heatOrchestrationTemplate.getResources() == null ? null + : heatOrchestrationTemplate.getResources().values(); + + if (CollectionUtils.isNotEmpty(resourcesValues)) { + for (Resource resource : resourcesValues) { + Collection properties = + resource.getProperties() == null ? null : resource.getProperties().values(); + if (CollectionUtils.isNotEmpty(properties)) { + for (Object property : properties) { + if (property instanceof Map) { + Set artifactNames = HeatStructureUtil + .getReferencedValuesByFunctionName(fileName, + ResourceReferenceFunctions.GET_FILE.getFunction(), property, globalContext); + artifacts.addAll(artifactNames); + HeatValidationService.checkArtifactsExistence(fileName, artifactNames, globalContext); + } + } + } + } + } + + + } + + /* validation 14 */ + private static void validateAllResourceReferencesExist(String fileName, + HeatOrchestrationTemplate heatOrchestrationTemplate, + GlobalValidationContext globalContext) { + + Set resourcesNames = heatOrchestrationTemplate.getResources() == null ? null + : heatOrchestrationTemplate.getResources().keySet(); + Collection resourcesValues = heatOrchestrationTemplate.getResources() == null ? null + : heatOrchestrationTemplate.getResources().values(); + Collection outputsValues = heatOrchestrationTemplate.getOutputs() == null ? null + : heatOrchestrationTemplate.getOutputs().values(); + + HeatValidationService + .checkResourceExistenceFromResourcesMap(fileName, resourcesNames, resourcesValues, + globalContext); + HeatValidationService + .checkResourceExistenceFromResourcesMap(fileName, resourcesNames, outputsValues, + globalContext); + + } + + /* validation 16 */ + private static void validateGetParamPointToParameter(String fileName, + HeatOrchestrationTemplate heatOrchestrationTemplate, + GlobalValidationContext globalContext) { + Set parametersNames = heatOrchestrationTemplate.getParameters() == null ? null + : heatOrchestrationTemplate.getParameters().keySet(); + Map resourcesMap = heatOrchestrationTemplate.getResources(); + + if (CollectionUtils.isNotEmpty(parametersNames) && MapUtils.isNotEmpty(resourcesMap)) { + for (Map.Entry resourceEntry : resourcesMap.entrySet()) { + Resource resource = resourceEntry.getValue(); + Map properties = resource.getProperties(); + if (MapUtils.isNotEmpty(properties)) { + Collection propertiesValues = properties.values(); + if (CollectionUtils.isNotEmpty(propertiesValues)) { + for (Object propertyObject : propertiesValues) { + //Set referencedParameterNames = HeatValidationService + // .getParameterNameFromGetParamMap(propertyObject); + Set referencedParameterNames = HeatStructureUtil + .getReferencedValuesByFunctionName(fileName, "get_param", propertyObject, + globalContext); + + validateReferenceParams(fileName, resourceEntry.getKey(), parametersNames, + referencedParameterNames, globalContext); + } + } + } + } + } + } + + private static void validateReferenceParams(String fileName, String resourceName, + Set parametersNamesFromFile, + Set referencedParametersNames, + GlobalValidationContext globalContext) { + + for (String parameterName : referencedParametersNames) { + if (!isHeatPseudoParameter(parameterName) + && !parametersNamesFromFile.contains(parameterName)) { + globalContext.addMessage(fileName, ErrorLevel.ERROR, ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.REFERENCED_PARAMETER_NOT_FOUND.getErrorMessage(), + parameterName, resourceName)); + } + } + } + + private static boolean isHeatPseudoParameter(String parameterName) { + return HeatPseudoParameters.getPseudoParameterNames().contains(parameterName); + } + + /* validation 18*/ + private static void validateGetAttr(String fileName, + HeatOrchestrationTemplate heatOrchestrationTemplate, + GlobalValidationContext globalContext) { + Map outputMap; + outputMap = heatOrchestrationTemplate.getOutputs(); + + if (MapUtils.isNotEmpty(outputMap)) { + HeatValidationService.loopOverOutputMapAndValidateGetAttrFromNested(fileName, outputMap, + heatOrchestrationTemplate, globalContext); + } + } + + /* validation 17 + */ + private static void validateEnvFile(String fileName, String envFileName, + HeatOrchestrationTemplate heatOrchestrationTemplate, + GlobalValidationContext globalContext) { + + Environment envContent; + + if (!envFileName.contains(".env")) { + globalContext.addMessage(envFileName, ErrorLevel.ERROR, ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.WRONG_ENV_FILE_EXTENSION.getErrorMessage(), + envFileName)); + } + + envContent = HeatValidationService.validateEnvContent(fileName, envFileName, globalContext); + if (envContent != null) { + validateEnvContentIsSubSetOfHeatParameters(envFileName, envContent, globalContext, + heatOrchestrationTemplate); + validateEnvParametersMatchDefinedHeatParameterTypes(envFileName, envContent, globalContext, + heatOrchestrationTemplate); + } + + } + + private static void validateEnvContentIsSubSetOfHeatParameters(String envFile, + Environment envContent, + GlobalValidationContext globalContext, + HeatOrchestrationTemplate heatOrchestrationTemplate) { + Set parametersNames = heatOrchestrationTemplate.getParameters() == null ? null + : heatOrchestrationTemplate.getParameters().keySet(); + + if (MapUtils.isNotEmpty(envContent.getParameters())) { + if (CollectionUtils.isNotEmpty(parametersNames)) { + for (Map.Entry envEntry : envContent.getParameters().entrySet()) { + String envParameter = envEntry.getKey(); + if (!parametersNames.contains(envParameter)) { + globalContext.addMessage(envFile, ErrorLevel.ERROR, ErrorMessagesFormatBuilder + .getErrorWithParameters( + Messages.ENV_INCLUDES_PARAMETER_NOT_IN_HEAT.getErrorMessage(), envFile, + envParameter)); + } + } + } else { + for (Map.Entry envEntry : envContent.getParameters().entrySet()) { + globalContext.addMessage(envFile, ErrorLevel.ERROR, ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.ENV_INCLUDES_PARAMETER_NOT_IN_HEAT.getErrorMessage(), + envFile, envEntry.getKey())); + } + } + } + } + + private static void validateParameterDefaultTypeAlignWithType(String fileName, + HeatOrchestrationTemplate heatOrchestrationTemplate, + GlobalValidationContext globalContext) { + Map parametersMap = heatOrchestrationTemplate.getParameters() == null ? null + : heatOrchestrationTemplate.getParameters(); + + if (MapUtils.isNotEmpty(parametersMap)) { + for (Map.Entry parameterEntry : parametersMap.entrySet()) { + Parameter parameter = parameterEntry.getValue(); + String parameterType = parameter.getType(); + Object parameterDefault = parameter.get_default(); + if (parameterDefault != null && parameterType != null) { + boolean isValueMatchDefault = + DefinedHeatParameterTypes.isValueIsFromGivenType(parameterDefault, parameterType); + if (!isValueMatchDefault) { + globalContext.addMessage(fileName, ErrorLevel.ERROR, ErrorMessagesFormatBuilder + .getErrorWithParameters( + Messages.PARAMETER_DEFAULT_VALUE_NOT_ALIGN_WITH_TYPE.getErrorMessage(), + parameterEntry.getKey(), parameterType)); + } + } + } + } + } + + private static void validateEnvParametersMatchDefinedHeatParameterTypes(String envFile, + Environment envContent, + GlobalValidationContext globalContext, + HeatOrchestrationTemplate heatOrchestrationTemplate) { + Map heatParameters = heatOrchestrationTemplate.getParameters(); + + if (MapUtils.isNotEmpty(heatParameters) && MapUtils.isNotEmpty(envContent.getParameters())) { + for (Map.Entry envEntry : envContent.getParameters().entrySet()) { + String parameterName = envEntry.getKey(); + Object parameterEnvValue = envEntry.getValue(); + Parameter parameterFromHeatFile = heatParameters.get(parameterName); + if (parameterFromHeatFile != null) { + String parameterType = parameterFromHeatFile.getType(); + if (!DefinedHeatParameterTypes.isEmptyValueInEnv(parameterEnvValue) + && !DefinedHeatParameterTypes.isValueIsFromGivenType(parameterEnvValue, + parameterType)) { + globalContext.addMessage(envFile, ErrorLevel.ERROR, ErrorMessagesFormatBuilder + .getErrorWithParameters( + Messages.PARAMETER_ENV_VALUE_NOT_ALIGN_WITH_TYPE.getErrorMessage(), + parameterName)); + } + } + } + } + } + + @Override + public void validate(GlobalValidationContext globalContext) { + + ManifestContent manifestContent; + try { + manifestContent = checkValidationPreCondition(globalContext); + } catch (Exception e0) { + return; + } + String baseFileName; + Map fileTypeMap = ManifestUtil.getFileTypeMap(manifestContent); + Map fileEnvMap = ManifestUtil.getFileAndItsEnv(manifestContent); + Set baseFiles = ManifestUtil.getBaseFiles(manifestContent); + Set securityGroupsNamesFromBaseFileOutputs; + Set artifacts = new HashSet<>(); + + + baseFileName = CollectionUtils.isEmpty(baseFiles) ? null : baseFiles.iterator().next(); + securityGroupsNamesFromBaseFileOutputs = baseFileName == null ? null + : checkForBaseFilePortsExistenceAndReturnSecurityGroupNamesFromOutputsIfNot(baseFileName, + globalContext); + + + globalContext.getFiles().stream() + .filter(fileName -> FileData.isHeatFile(fileTypeMap.get(fileName))).forEach( + fileName -> validate(fileName, + fileEnvMap.get(fileName) == null ? null : fileEnvMap.get(fileName).getFile(), + baseFileName == null ? null : baseFileName, artifacts, + securityGroupsNamesFromBaseFileOutputs, globalContext)); + + + Set manifestArtifacts = ManifestUtil.getArtifacts(manifestContent); + + globalContext.getFiles().stream() + .filter(fileName -> manifestArtifacts.contains(fileName) && !artifacts.contains(fileName)) + .forEach(fileName -> globalContext.addMessage(fileName, ErrorLevel.WARNING, + Messages.ARTIFACT_FILE_NOT_REFERENCED.getErrorMessage())); + + ResourceValidationHeatValidator + .handleNotEmptyResourceNamesList(baseFileName, securityGroupsNamesFromBaseFileOutputs, + "SecurityGroup", globalContext); + + } + + private void validate(String fileName, String envFileName, String baseFileName, + Set artifacts, Set securityGroupsNamesFromBaseFileOutputs, + GlobalValidationContext globalContext) { + HeatOrchestrationTemplate heatOrchestrationTemplate = + checkHeatOrchestrationPreCondition(fileName, globalContext); + + + if (heatOrchestrationTemplate != null) { + if (!(fileName.contains(".yaml") || fileName.contains(".yml"))) { + globalContext.addMessage(fileName, ErrorLevel.ERROR, ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.WRONG_HEAT_FILE_EXTENSION.getErrorMessage(), + fileName)); + } + + validateHeatBaseStructure(fileName, heatOrchestrationTemplate, globalContext); + + ResourceValidationHeatValidator + .validateResourceType(fileName, baseFileName, securityGroupsNamesFromBaseFileOutputs, + heatOrchestrationTemplate, globalContext); + validateParameterDefaultTypeAlignWithType(fileName, heatOrchestrationTemplate, globalContext); + validateAllResourceReferencesExist(fileName, heatOrchestrationTemplate, globalContext); + validateGetParamPointToParameter(fileName, heatOrchestrationTemplate, globalContext); + validateGetAttr(fileName, heatOrchestrationTemplate, globalContext); + validateAllRequiredArtifactsExist(fileName, heatOrchestrationTemplate, artifacts, + globalContext); + + if (envFileName != null) { + validateEnvFile(fileName, envFileName, heatOrchestrationTemplate, globalContext); + } + } + } + + private void validateHeatBaseStructure(String fileName, + HeatOrchestrationTemplate heatOrchestrationTemplate, + GlobalValidationContext globalContext) { + if (heatOrchestrationTemplate.getHeat_template_version() == null) { + globalContext.addMessage(fileName, ErrorLevel.ERROR, ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.INVALID_HEAT_FORMAT_REASON.getErrorMessage(), + "missing template version")); + } + if (heatOrchestrationTemplate.getResources() == null + || heatOrchestrationTemplate.getResources().size() == 0) { + globalContext.addMessage(fileName, ErrorLevel.ERROR, ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.INVALID_HEAT_FORMAT_REASON.getErrorMessage(), + "heat file must have minimum one resource")); + } + } + + protected ManifestContent checkValidationPreCondition(GlobalValidationContext globalContext) { + InputStream manifest = globalContext.getFileContent(AsdcCommon.MANIFEST_NAME); + if (manifest == null) { + throw new RuntimeException("Can't load manifest file for Heat Validator"); + } + ManifestContent manifestContent; + try { + manifestContent = JsonUtil.json2Object(manifest, ManifestContent.class); + } catch (Exception e0) { + throw new RuntimeException("Can't load manifest file for Heat Validator"); + } + + return manifestContent; + } + + + private HeatOrchestrationTemplate checkHeatOrchestrationPreCondition(String fileName, + GlobalValidationContext globalContext) { + HeatOrchestrationTemplate heatOrchestrationTemplate; + try { + heatOrchestrationTemplate = new YamlUtil() + .yamlToObject(globalContext.getFileContent(fileName), HeatOrchestrationTemplate.class); + } catch (Exception e0) { + globalContext.addMessage(fileName, ErrorLevel.ERROR, ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.INVALID_HEAT_FORMAT_REASON.getErrorMessage(), + getParserExceptionReason(e0))); + return null; + } + + return heatOrchestrationTemplate; + } + + + private Set checkForBaseFilePortsExistenceAndReturnSecurityGroupNamesFromOutputsIfNot( + String baseFileName, GlobalValidationContext globalContext) { + Set securityGroupsNamesFromOutputsMap = new HashSet<>(); + HeatOrchestrationTemplate heatOrchestrationTemplate = + checkHeatOrchestrationPreCondition(baseFileName, globalContext); + + if (heatOrchestrationTemplate != null) { + Map resourceMap = heatOrchestrationTemplate.getResources(); + if (!isPortResourceExistInBaseFile(resourceMap)) { + getSecurityGroupsReferencedResourcesFromOutputs(securityGroupsNamesFromOutputsMap, + heatOrchestrationTemplate.getOutputs(), resourceMap); + } + } + + return securityGroupsNamesFromOutputsMap; + } + + + @SuppressWarnings("unchecked") + private void getSecurityGroupsReferencedResourcesFromOutputs( + Set securityGroupsNamesFromOutputsMap, Map outputMap, + Map resourceMap) { + if (MapUtils.isNotEmpty(outputMap)) { + for (Map.Entry outputEntry : outputMap.entrySet()) { + Object outputValue = outputEntry.getValue().getValue(); + if (Objects.nonNull(outputValue) && outputValue instanceof Map) { + String resourceName = (String) ((Map) outputValue) + .get(ResourceReferenceFunctions.GET_RESOURCE.getFunction()); + if (Objects.nonNull(resourceName)) { + Resource resource = resourceMap.get(resourceName); + if (Objects.nonNull(resource) && resource.getType().equals( + HeatResourcesTypes.NEUTRON_SECURITY_GROUP_RESOURCE_TYPE.getHeatResource())) { + securityGroupsNamesFromOutputsMap.add(outputEntry.getKey()); + } + } + } + } + } + } + + + private boolean isPortResourceExistInBaseFile(Map resourceMap) { + for (Map.Entry resourceEntry : resourceMap.entrySet()) { + if (resourceEntry.getValue().getType() + .equals(HeatResourcesTypes.NEUTRON_PORT_RESOURCE_TYPE.getHeatResource())) { + return true; + } + } + + return false; + } + + + private String getParserExceptionReason(Exception e0) { + String reason; + + if (e0.getCause() != null && e0.getCause().getCause() != null) { + reason = e0.getCause().getCause().getMessage(); + } else if (e0.getCause() != null) { + reason = e0.getCause().getMessage(); + } else { + reason = Messages.GENERAL_HEAT_PARSER_ERROR.getErrorMessage(); + } + return reason; + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/main/java/org/openecomp/sdc/validation/impl/validators/ManifestValidator.java b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/main/java/org/openecomp/sdc/validation/impl/validators/ManifestValidator.java new file mode 100644 index 0000000000..4ce40f0007 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/main/java/org/openecomp/sdc/validation/impl/validators/ManifestValidator.java @@ -0,0 +1,153 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.validation.impl.validators; + +import org.openecomp.core.utilities.json.JsonUtil; +import org.openecomp.core.validation.errors.ErrorMessagesFormatBuilder; +import org.openecomp.core.validation.errors.Messages; +import org.openecomp.core.validation.interfaces.Validator; +import org.openecomp.core.validation.types.GlobalValidationContext; +import org.openecomp.sdc.common.utils.AsdcCommon; +import org.openecomp.sdc.datatypes.error.ErrorLevel; +import org.openecomp.sdc.heat.datatypes.manifest.FileData; +import org.openecomp.sdc.heat.datatypes.manifest.ManifestContent; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import java.io.InputStream; +import java.util.ArrayList; +import java.util.List; + +public class ManifestValidator implements Validator { + + private static Logger logger = LoggerFactory.getLogger(YamlValidator.class); + + + @Override + public void validate(GlobalValidationContext globalContext) { + + + InputStream content = globalContext.getFileContent(AsdcCommon.MANIFEST_NAME); + ManifestContent manifestContent; + + try { + manifestContent = JsonUtil.json2Object(content, ManifestContent.class); + } catch (RuntimeException re) { + globalContext.addMessage(AsdcCommon.MANIFEST_NAME, ErrorLevel.ERROR, + Messages.INVALID_MANIFEST_FILE.getErrorMessage()); + return; + } + + List manifestFiles = getManifestFileList(manifestContent, globalContext); + manifestFiles.stream().filter(name -> + !globalContext.getFileContextMap().containsKey(name) + ).forEach(name -> globalContext + .addMessage(name, ErrorLevel.ERROR, Messages.MISSING_FILE_IN_ZIP.getErrorMessage())); + + globalContext.getFileContextMap().keySet().stream().filter(name -> + !manifestFiles.contains(name) && !AsdcCommon.MANIFEST_NAME.equals(name) + ).forEach(name -> + globalContext.addMessage(name, ErrorLevel.WARNING, + Messages.MISSING_FILE_IN_MANIFEST.getErrorMessage()) + ); + + } + + private List getManifestFileList(ManifestContent manifestContent, + GlobalValidationContext context) { + ManifestScanner manifestScanner = new ManifestScanner(); + manifestScanner.init(context); + manifestScanner.scan(null, manifestContent.getData(), context); + return manifestScanner.getFileList(); + } + + + private class ManifestScanner { + private GlobalValidationContext globalValidationContext; + private List fileList; + + public void init(GlobalValidationContext globalValidationContext) { + this.globalValidationContext = globalValidationContext; + this.fileList = new ArrayList<>(); + } + + + public void scan(FileData fileData, List data, + GlobalValidationContext globalContext) { + if (fileData == null) { + for (FileData childFileData : data) { + if (childFileData.getType() != null + && childFileData.getType().equals(FileData.Type.HEAT_ENV)) { + globalContext.addMessage(childFileData.getFile(), ErrorLevel.ERROR, + ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.ENV_NOT_ASSOCIATED_TO_HEAT.getErrorMessage())); + } + } + } + if (fileData != null) { + fileList.add(fileData.getFile()); + validateFileTypeVsFileName(fileData); + } + if (data == null) { + return; + } + data.stream().forEach(chileFileData -> { + scan(chileFileData, chileFileData.getData(), globalContext); + }); + } + + + public List getFileList() { + return this.fileList; + } + + private void validateFileTypeVsFileName(FileData fileData) { + String fileName = fileData.getFile(); + if (fileName == null) { + this.globalValidationContext.addMessage(AsdcCommon.MANIFEST_NAME, ErrorLevel.ERROR, + Messages.MISSING_FILE_NAME_IN_MANIFEST.getErrorMessage()); + + } + FileData.Type type = fileData.getType(); + if (type == null) { + this.globalValidationContext + .addMessage(fileName, ErrorLevel.ERROR, Messages.INVALID_FILE_TYPE.getErrorMessage()); + } else if (type.equals(FileData.Type.HEAT_NET) || type.equals(FileData.Type.HEAT_VOL) + || type.equals(FileData.Type.HEAT)) { + if (fileName != null && !fileName.endsWith(".yml") && !fileName.endsWith(".yaml")) { + this.globalValidationContext.addMessage(fileName, ErrorLevel.ERROR, + ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.WRONG_HEAT_FILE_EXTENSION.getErrorMessage(), + fileName)); + } + } else if (type.equals(FileData.Type.HEAT_ENV)) { + if (fileName != null && !fileName.endsWith(".env")) { + this.globalValidationContext.addMessage(fileName, ErrorLevel.ERROR, + ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.WRONG_ENV_FILE_EXTENSION.getErrorMessage(), + fileName)); + } + } + } + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/main/java/org/openecomp/sdc/validation/impl/validators/YamlValidator.java b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/main/java/org/openecomp/sdc/validation/impl/validators/YamlValidator.java new file mode 100644 index 0000000000..4d05b2b066 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/main/java/org/openecomp/sdc/validation/impl/validators/YamlValidator.java @@ -0,0 +1,97 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.validation.impl.validators; + +import org.openecomp.core.utilities.yaml.YamlUtil; +import org.openecomp.core.validation.errors.ErrorMessagesFormatBuilder; +import org.openecomp.core.validation.errors.Messages; +import org.openecomp.core.validation.interfaces.Validator; +import org.openecomp.core.validation.types.GlobalValidationContext; +import org.openecomp.sdc.datatypes.error.ErrorLevel; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; +import org.yaml.snakeyaml.error.MarkedYAMLException; +import org.yaml.snakeyaml.parser.ParserException; + +import java.io.InputStream; +import java.util.Collection; +import java.util.Map; + +public class YamlValidator implements Validator { + + private static final Logger logger = LoggerFactory.getLogger(YamlValidator.class); + + @Override + public void validate(GlobalValidationContext globalContext) { + + Collection files = globalContext.files( + (fileName, globalValidationContext) -> (fileName.endsWith(".yaml") + || fileName.endsWith(".yml") || fileName.endsWith(".env"))); + + files.stream().forEach(fileName -> validate(fileName, globalContext)); + } + + private void validate(String fileName, GlobalValidationContext globalContext) { + InputStream rowContent = globalContext.getFileContent(fileName); + if (rowContent == null) { + globalContext.addMessage(fileName, ErrorLevel.ERROR, ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.INVALID_YAML_FORMAT_REASON.getErrorMessage(), + Messages.EMPTY_YAML_FILE.getErrorMessage())); + return; /* no need to continue validation */ + } + + try { + convert(rowContent, Map.class); + } catch (Exception exception) { + + globalContext.addMessage(fileName, ErrorLevel.ERROR, ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.INVALID_YAML_FORMAT_REASON.getErrorMessage(), + getParserExceptionReason(exception))); + logger.error("Exception in yaml parser. message:" + exception.getMessage()); + } + } + + private String getParserExceptionReason(Exception exception) { + String reason = null; + + if (exception.getCause() instanceof MarkedYAMLException) { + if (exception.getCause() != null) { + if (exception.getCause().getCause() instanceof ParserException) { + reason = exception.getCause().getCause().getMessage(); + } else { + reason = exception.getCause().getMessage(); + } + } + } else if (exception instanceof MarkedYAMLException) { + + reason = exception.getMessage(); + + } else { + reason = Messages.GENERAL_YAML_PARSER_ERROR.getErrorMessage(); + } + return reason; + } + + + private T convert(InputStream content, Class type) { + return new YamlUtil().yamlToObject(content, type); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/java/org/openecomp/sdc/validation/impl/validators/ErrorMessagesTest.java b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/java/org/openecomp/sdc/validation/impl/validators/ErrorMessagesTest.java new file mode 100644 index 0000000000..d762689049 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/java/org/openecomp/sdc/validation/impl/validators/ErrorMessagesTest.java @@ -0,0 +1,25 @@ +package org.openecomp.sdc.validation.impl.validators; + +import org.openecomp.core.validation.errors.ErrorMessagesFormatBuilder; +import org.openecomp.core.validation.errors.Messages; +import org.junit.Test; +import org.testng.Assert; + +public class ErrorMessagesTest { + + @Test + public void testErrorFormatWithOneParam() { + String error1 = ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.MISSING_FILE_NAME_IN_MANIFEST.getErrorMessage(), + "file.yaml"); + Assert.assertNotNull(error1); + } + + @Test + public void testErrorFormatWithTwoParams() { + String error1 = ErrorMessagesFormatBuilder + .getErrorWithParameters(Messages.REFERENCED_PARAMETER_NOT_FOUND.getErrorMessage(), "param", + "res"); + Assert.assertNotNull(error1); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/java/org/openecomp/sdc/validation/impl/validators/ValidatorBaseTest.java b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/java/org/openecomp/sdc/validation/impl/validators/ValidatorBaseTest.java new file mode 100644 index 0000000000..f9c5bf423b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/java/org/openecomp/sdc/validation/impl/validators/ValidatorBaseTest.java @@ -0,0 +1,84 @@ +package org.openecomp.sdc.validation.impl.validators; + +import org.openecomp.core.utilities.file.FileUtils; +import org.openecomp.core.validation.errors.ErrorMessagesFormatBuilder; +import org.openecomp.core.validation.interfaces.Validator; +import org.openecomp.core.validation.types.GlobalValidationContext; +import org.openecomp.core.validation.types.MessageContainer; +import org.testng.Assert; + +import java.io.File; +import java.io.FileInputStream; +import java.io.IOException; +import java.net.URL; +import java.util.HashMap; +import java.util.Map; + +public abstract class ValidatorBaseTest { + + private static GlobalValidationContext createGlobalContextFromPath(String path) { + GlobalValidationContext globalValidationContext = new GlobalValidationContext(); + Map contentMap = getContentMapByPath(path); + if (contentMap == null) { + return null; + } + contentMap.entrySet().stream() + .forEach(entry -> globalValidationContext.addFileContext(entry.getKey(), entry.getValue())); + + return globalValidationContext; + } + + + // New test base implementation + + private static Map getContentMapByPath(String path) { + Map contentMap = new HashMap<>(); + byte[] fileContent; + FileInputStream fis; + URL url = ValidatorBaseTest.class.getResource(path); + File pathFile = new File(url.getFile()); + File[] files; + if (pathFile.isDirectory()) { + files = pathFile.listFiles(); + } else { + files = new File[]{pathFile}; + } + + if (files == null || files.length == 0) { + return null; + } + + for (File file : files) { + try { + fis = new FileInputStream(file); + fileContent = FileUtils.toByteArray(fis); + contentMap.put(file.getName(), fileContent); + } catch (IOException e) { + e.printStackTrace(); + } + } + return contentMap; + } + + public abstract Map runValidation(String path); + + protected Map testValidator(Validator validator, String path) { + + GlobalValidationContext globalValidationContext = createGlobalContextFromPath(path); + validator.validate(globalValidationContext); + + assert globalValidationContext != null; + return globalValidationContext.getContextMessageContainers(); + + + } + + protected void validateErrorMessage(String actualMessage, String expected, String... params) { + Assert.assertEquals(actualMessage.replace("\n", "").replace("\r", ""), + ErrorMessagesFormatBuilder.getErrorWithParameters(expected, params).replace("\n", "") + .replace("\r", "")); + + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/java/org/openecomp/sdc/validation/impl/validators/validators/EcompGuideLineValidatorTest.java b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/java/org/openecomp/sdc/validation/impl/validators/validators/EcompGuideLineValidatorTest.java new file mode 100644 index 0000000000..44e9a3a580 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/java/org/openecomp/sdc/validation/impl/validators/validators/EcompGuideLineValidatorTest.java @@ -0,0 +1,281 @@ +package org.openecomp.sdc.validation.impl.validators.validators; + +import org.openecomp.sdc.validation.impl.validators.EcompGuideLineValidator; + +import org.openecomp.sdc.validation.impl.validators.ValidatorBaseTest; +import org.openecomp.core.validation.types.MessageContainer; + +import org.testng.Assert; +import org.testng.annotations.Test; + +import java.util.Map; + +public class EcompGuideLineValidatorTest extends ValidatorBaseTest { + + @Test + public void testMissingBaseHeat() { + Map messages = + runValidation("/openecomp/org/validation/validators/ecompGuideLineValidator/missingBaseHeat/"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + Assert.assertEquals(messages.get("MANIFEST.json").getErrorMessageList().size(), 1); + Assert.assertEquals(messages.get("MANIFEST.json").getErrorMessageList().get(0).getMessage(), + "Missing Base HEAT. Pay attention that without Base HEAT, there will be no shared resources"); + } + + @Test + public void testMultiBaseHeat() { + Map messages = + runValidation("/openecomp/org/validation/validators/ecompGuideLineValidator/multiBaseHeat/"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + Assert.assertEquals(messages.get("MANIFEST.json").getErrorMessageList().size(), 1); + Assert.assertEquals(messages.get("MANIFEST.json").getErrorMessageList().get(0).getMessage(), + "Multi Base HEAT. Expected only one. Files [second.yaml,first.yaml]."); + } + + @Test + public void testBaseHeatExposeVolume() { + Map messages = runValidation( + "/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/positive/"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 0); + + messages = runValidation( + "/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/negative/"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + Assert.assertEquals(messages.get("first.yaml").getErrorMessageList().size(), 1); + Assert.assertEquals(messages.get("first.yaml").getErrorMessageList().get(0).getMessage(), + "Resource is not defined as output and thus cannot be Shared. resource id - volume_expose"); + } + + @Test + public void testBaseHeatExposeServerGroup() { + Map messages = runValidation( + "/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/positive/"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 0); + + messages = runValidation( + "/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/negative/"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + Assert.assertEquals(messages.get("first.yaml").getErrorMessageList().size(), 1); + Assert.assertEquals(messages.get("first.yaml").getErrorMessageList().get(0).getMessage(), + "Resource is not defined as output and thus cannot be Shared. resource id - ServerGroup_expose"); + } + + @Test + public void testBaseHeatExposeSecurityGroup() { + Map messages = runValidation( + "/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/positive/"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 0); + + messages = runValidation( + "/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/negative/"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + Assert.assertEquals(messages.get("first.yaml").getErrorMessageList().size(), 1); + Assert.assertEquals(messages.get("first.yaml").getErrorMessageList().get(0).getMessage(), + "Resource is not defined as output and thus cannot be Shared. resource id - SecurityGroup_expose"); + } + + + @Test + public void testBaseHeatExposeNetwork() { + Map messages = runValidation( + "/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/positive/"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 0); + + messages = runValidation( + "/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/negative/"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + Assert.assertEquals(messages.get("first.yaml").getErrorMessageList().size(), 1); + Assert.assertEquals(messages.get("first.yaml").getErrorMessageList().get(0).getMessage(), + "Resource is not defined as output and thus cannot be Shared. resource id - SecurityGroup_expose"); + } + + @Test + public void testBaseHeatExposeNetworkAndVolume() { + Map messages = runValidation( + "/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/positive/"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 0); + + messages = runValidation( + "/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/negative/"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + Assert.assertEquals(messages.get("first.yaml").getErrorMessageList().size(), 2); + Assert.assertEquals(messages.get("first.yaml").getErrorMessageList().get(0).getMessage(), + "Resource is not defined as output and thus cannot be Shared. resource id - volume_expose"); + Assert.assertEquals(messages.get("first.yaml").getErrorMessageList().get(1).getMessage(), + "Resource is not defined as output and thus cannot be Shared. resource id - net_expose"); + } + + @Test + public void testNovaResourceNetworkUniqueRole() { + Map messages = runValidation( + "/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/positive/"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 0); + + messages = runValidation( + "/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/negative/"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + Assert.assertEquals(messages.get("first.yaml").getErrorMessageList().size(), 1); + Assert.assertEquals(messages.get("first.yaml").getErrorMessageList().get(0).getMessage(), + "A resource is connected twice to the same network role Resource ID [FSB2] Network Role [Internal1]."); + } + + @Test + public void testHeatVolumeExpose() { + Map messages = runValidation( + "/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/positive/"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 0); + + messages = runValidation( + "/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/negative/"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + Assert.assertEquals(messages.get("firstVol.yaml").getErrorMessageList().size(), 1); + Assert.assertEquals(messages.get("firstVol.yaml").getErrorMessageList().get(0).getMessage(), + "Volume is not defined as output and thus cannot be attached volume_expose"); + + } + + @Test + public void testHeatPortNetworkNamingConvention() { + Map messages = runValidation( + "/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/positive/"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 0); + + messages = runValidation( + "/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/negative/"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + Assert.assertEquals(messages.get("first.yaml").getErrorMessageList().size(), 3); + Assert.assertEquals(messages.get("first.yaml").getErrorMessageList().get(0).getMessage(), + "Network Parameter Name not aligned with Guidelines Parameter Name [not_valid_network_name] Resource ID [port_resource]"); + } + + @Test + public void testHeatNovaServerMetaDataValidation() { + Map messages = runValidation( + "/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/positive/"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 0); + + messages = runValidation( + "/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/negative/"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + Assert.assertEquals(messages.get("first.yaml").getErrorMessageList().size(), 1); + Assert.assertEquals(messages.get("first.yaml").getErrorMessageList().get(0).getMessage(), + "Missing VNF_ID Resource id [FSB2]"); + } + + @Test + public void testNeutronFixedIpName() { + Map messages = runValidation( + "/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/positive"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 0); + + messages = runValidation( + "/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/negative/"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + Assert.assertEquals(messages.get("first.yaml").getErrorMessageList().size(), 3); + Assert.assertEquals(messages.get("first.yaml").getErrorMessageList().get(0).getMessage(), + "Fixed_IPS not aligned with Guidelines, Resource ID [port_resource_0]"); + Assert.assertEquals(messages.get("first.yaml").getErrorMessageList().get(1).getMessage(), + "Fixed_IPS not aligned with Guidelines, Resource ID [port_resource_1]"); + Assert.assertEquals(messages.get("first.yaml").getErrorMessageList().get(2).getMessage(), + "Fixed_IPS not aligned with Guidelines, Resource ID [port_resource_2]"); + } + + + @Test + public void testNovaServerName() { + Map messages = runValidation( + "/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/positive"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 0); + + messages = runValidation( + "/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/negative/"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + Assert.assertEquals(messages.get("first.yaml").getErrorMessageList().size(), 2); + Assert.assertEquals(messages.get("first.yaml").getErrorMessageList().get(0).getMessage(), + "Server Name not aligned with Guidelines, Resource ID [FSB2]"); + } + + @Test + public void testAvailabilityZoneName() { + Map messages = runValidation( + "/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/positive"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 0); + + messages = runValidation( + "/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/negative"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + Assert.assertEquals(messages.get("first.yaml").getErrorMessageList().size(), 3); + Assert.assertEquals(messages.get("first.yaml").getErrorMessageList().get(0).getMessage(), + "Server Availability Zone not aligned with Guidelines, Resource ID [FSB2]"); + Assert.assertEquals(messages.get("first.yaml").getErrorMessageList().get(1).getMessage(), + "Server Availability Zone not aligned with Guidelines, Resource ID [FSB3]"); + } + + @Test + public void testFloatingIpResourceType() { + Map messages = runValidation( + "/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/positive"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 0); + + + messages = runValidation( + "/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/negative"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + Assert.assertEquals(messages.get("first.yaml").getErrorMessageList().size(), 1); + Assert.assertEquals(messages.get("first.yaml").getErrorMessageList().get(0).getMessage(), + "OS::Neutron::FloatingIP is in use, Resource ID [FSB2]"); + } + + @Test + public void testImageAndFlavorNames() { + Map messages = runValidation( + "/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/positive"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 0); + + messages = runValidation( + "/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/negative"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + Assert.assertEquals(messages.get("first.yaml").getErrorMessageList().size(), 2); + Assert.assertEquals(messages.get("first.yaml").getErrorMessageList().get(0).getMessage(), + "Wrong flavor name format in NOVA Server, Resource ID [FSB2]"); + Assert.assertEquals(messages.get("first.yaml").getErrorMessageList().get(1).getMessage(), + "Wrong image name format in NOVA Server, Resource ID [FSB3]"); + } + + + @Override + public Map runValidation(String path) { + EcompGuideLineValidator validator = new EcompGuideLineValidator(); + return testValidator(validator, path); + } +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/java/org/openecomp/sdc/validation/impl/validators/validators/EcompNamingConventionTest.java b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/java/org/openecomp/sdc/validation/impl/validators/validators/EcompNamingConventionTest.java new file mode 100644 index 0000000000..e4203945aa --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/java/org/openecomp/sdc/validation/impl/validators/validators/EcompNamingConventionTest.java @@ -0,0 +1,104 @@ +package org.openecomp.sdc.validation.impl.validators.validators; + +import org.openecomp.sdc.validation.impl.validators.EcompGuideLineValidator; +import org.openecomp.sdc.validation.impl.validators.ValidatorBaseTest; +import org.openecomp.core.validation.types.MessageContainer; + +import java.io.IOException; +import java.util.Map; + +import org.testng.Assert; +import org.testng.annotations.Test; + +public class EcompNamingConventionTest extends ValidatorBaseTest { + + @Test + public void testNeutronFixedIpName() throws IOException { + Map messages = runValidation( + "/openecomp/org/validation/validators/ecomp_naming_convention/neutron_port_fixed_ip_name/input"); + + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 2); + + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().size(), 3); + Assert.assertEquals( + messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().get(0).getMessage(), + "Fixed_IPS not aligned with Guidelines, Resource ID [fixed_ip_illegal_name_1]"); + Assert.assertEquals( + messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().get(1).getMessage(), + "Fixed_IPS not aligned with Guidelines, Resource ID [fixed_ip_illegal_name_2]"); + Assert.assertEquals( + messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().get(2).getMessage(), + "Fixed_IPS not aligned with Guidelines, Resource ID [fixed_ip_illegal_name_3]"); + } + + + @Test + public void testNovaServerName() throws IOException { + Map messages = runValidation( + "/openecomp/org/validation/validators/ecomp_naming_convention/nova_server_name/input"); + + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 2); + + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().size(), 6); + Assert.assertEquals( + messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().get(0).getMessage(), + "Server Name not aligned with Guidelines, Resource ID [nova_server_ilegal_name_1]"); + Assert.assertEquals( + messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().get(1).getMessage(), + "Server Name not aligned with Guidelines, Resource ID [nova_server_ilegal_name_2]"); + Assert.assertEquals( + messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().get(2).getMessage(), + "Server Name not aligned with Guidelines, Resource ID [nova_server_ilegal_name_3]"); + Assert.assertEquals( + messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().get(3).getMessage(), + "Server Name not aligned with Guidelines, Resource ID [nova_server_ilegal_name_4]"); + Assert.assertEquals( + messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().get(4).getMessage(), + "Server Name not aligned with Guidelines, Resource ID [nova_server_ilegal_name_5]"); + Assert.assertEquals( + messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().get(5).getMessage(), + "Missing get_param in nova server name, Resource Id [nova_server_ilegal_name_6]"); + } + + + @Test + public void testAvailabilityZoneName() throws IOException { + Map messages = runValidation( + "/openecomp/org/validation/validators/ecomp_naming_convention/availability_zone_name/input"); + + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 2); + + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().size(), 2); + Assert.assertEquals( + messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().get(0).getMessage(), + "Server Availability Zone not aligned with Guidelines, Resource ID [availability_zone_illegal_name_1]"); + Assert.assertEquals( + messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().get(1).getMessage(), + "Server Availability Zone not aligned with Guidelines, Resource ID [availability_zone_illegal_name_2]"); + } + + + @Test + public void testFloatingIpResourceType() throws IOException { + Map messages = runValidation( + "/openecomp/org/validation/validators/ecomp_naming_convention/floating_ip_resource_type/input"); + + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 2); + + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().size(), 1); + Assert.assertEquals( + messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().get(0).getMessage(), + "OS::Neutron::FloatingIP is in use, Resource ID [floating_ip_type]"); + } + + + @Override + public Map runValidation(String path) { + EcompGuideLineValidator ecompGuideLineValidator = new EcompGuideLineValidator(); + return testValidator(ecompGuideLineValidator, path); + } +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/java/org/openecomp/sdc/validation/impl/validators/validators/HeatValidatorTest.java b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/java/org/openecomp/sdc/validation/impl/validators/validators/HeatValidatorTest.java new file mode 100644 index 0000000000..9ff375c1a3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/java/org/openecomp/sdc/validation/impl/validators/validators/HeatValidatorTest.java @@ -0,0 +1,356 @@ +package org.openecomp.sdc.validation.impl.validators.validators; + +import org.openecomp.sdc.validation.impl.validators.HeatValidator; +import org.openecomp.sdc.validation.impl.validators.ValidatorBaseTest; +import org.openecomp.core.validation.types.MessageContainer; + +import org.testng.Assert; +import org.testng.annotations.Test; + +import java.io.IOException; +import java.util.Map; + +public class HeatValidatorTest extends ValidatorBaseTest { + + + @Test + public void testInvalidHeatFormat(){ + Map messages = runValidation("/openecomp/org/validation/validators/heat_validator/invalid_heat_format/negative_test/input"); + + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + + Assert.assertEquals(messages.get("hot-nimbus-psm_v1.0.yaml").getErrorMessageList().size(), 1); + Assert.assertEquals(messages.get("hot-nimbus-psm_v1.0.yaml").getErrorMessageList().get(0).getMessage(), "Invalid HEAT format problem - [Cannot create property=kuku for JavaBean=Resource{type='null', properties=null, metadata=null, depends_on=null, update_policy='null', deletion_policy='null'}\n" + + " in 'reader', line 25, column 5:\n" + + " kuku: kuku\n" + + " ^\n" + + "Unable to find property 'kuku' on class: org.openecomp.sdc.heat.datatypes.model.Resource\n" + + " in 'reader', line 25, column 11:\n" + + " kuku: kuku\n" + + " ^\n" + + "]"); + } + + + @Test + public void testResourcesReferencesExistInHeat() throws IOException { + Map messages = runValidation("/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/negative_test/input"); + + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().size(), 2); + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().get(0).getMessage(), "Referenced resource - not_existing_resource not found"); + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().get(1).getMessage(), "invalid get_resource syntax is in use - null , get_resource function should get the resource id of the referenced resource"); + } + + + @Test + public void testGetResourceValueIsValid(){ + Map messages = runValidation("/openecomp/org/validation/validators/heat_validator/get_resource_value_valid/negative_test/input"); + + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().size(), 3); + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().get(0).getMessage(), "invalid get_resource syntax is in use - [param_1, param_2] , get_resource function should get the resource id of the referenced resource"); + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().get(1).getMessage(), "invalid get_resource syntax is in use - {get_param=param_1} , get_resource function should get the resource id of the referenced resource"); + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().get(2).getMessage(), "invalid get_resource syntax is in use - null , get_resource function should get the resource id of the referenced resource"); + } + + @Test + public void testTwoResourcesDoesNotHoldSameId() throws IOException { + Map messages = runValidation("/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/positive_test/input"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 0); + } + + @Test + public void negativeTestGetParamPointToExistingParameter() throws IOException { + Map messages = runValidation("/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/negative_test/input"); + + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + + Assert.assertEquals(messages.get("hot-nimbus-psm_v1.0.yaml").getErrorMessageList().size(), 1); + Assert.assertEquals(messages.get("hot-nimbus-psm_v1.0.yaml").getErrorMessageList().get(0).getMessage(), "Referenced parameter - not_existing_param_1 - not found, used in resource - server_pcrf_psm_001"); + } + + @Test + public void testGetAttrFromNested() throws IOException { + Map messages = runValidation("/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/negative_test/input"); + + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + + Assert.assertEquals(messages.get("hot-nimbus-psm_v1.0.yaml").getErrorMessageList().size(), 1); + Assert.assertEquals(messages.get("hot-nimbus-psm_v1.0.yaml").getErrorMessageList().get(0).getMessage(), "get_attr attribute not found - nested_output in resource server_pcrf_psm_001"); + } + + @Test + public void testPropertiesMatchNestedParameters() throws IOException { + Map messages = runValidation("/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/negative_test/input"); + + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().size(), 1); + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().get(0).getMessage(), "Referenced parameter not found in nested file - nested-pps_v1.0.yaml, resource name - server_pcrf_pps_001, parameter name - parameter_not_existing_in_nested"); + } + + @Test + public void testNovaPropertiesHasAssignedValue() throws IOException { + Map messages = runValidation("/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/negative_test/input"); + + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + + Assert.assertEquals(messages.get("hot-nimbus-psm_v1.0.yaml").getErrorMessageList().size(), 1); + Assert.assertEquals(messages.get("hot-nimbus-psm_v1.0.yaml").getErrorMessageList().get(0).getMessage(), "Missing both Image and Flavor in NOVA Server - nova_server_resource_missing_both"); + } + + @Test + public void testNoLoopsNesting() throws IOException { + Map messages = runValidation("/openecomp/org/validation/validators/heat_validator/no_loops_nesting/negative_test/input"); + + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 4); + + Assert.assertEquals(messages.get("hot-nimbus-psm_v1.0.yaml").getErrorMessageList().size(), 2); + Assert.assertEquals(messages.get("hot-nimbus-psm_v1.0.yaml").getErrorMessageList().get(0).getMessage(), "A resource has an invalid or unsupported type - null, Resource ID [server_pcrf_psm_002]"); + Assert.assertEquals(messages.get("hot-nimbus-psm_v1.0.yaml").getErrorMessageList().get(1).getMessage(), "Nested files loop - [hot-nimbus-psm_v1.0.yaml -- nested-psm_v1.0.yaml -- nested-points-to-hot-nimbus-psm.yaml -- hot-nimbus-psm_v1.0.yaml]"); + + Assert.assertEquals(messages.get("nested-points-to-hot-nimbus-psm.yaml").getErrorMessageList().size(), 2); + Assert.assertEquals(messages.get("nested-points-to-hot-nimbus-psm.yaml").getErrorMessageList().get(0).getMessage(), "Nested files loop - [nested-points-to-hot-nimbus-psm.yaml -- hot-nimbus-psm_v1.0.yaml -- nested-psm_v1.0.yaml -- nested-points-to-hot-nimbus-psm.yaml]"); + Assert.assertEquals(messages.get("nested-points-to-hot-nimbus-psm.yaml").getErrorMessageList().get(1).getMessage(), "Nested files loop - [nested-points-to-hot-nimbus-psm.yaml -- nested-psm_v1.0.yaml -- nested-points-to-hot-nimbus-psm.yaml]"); + + Assert.assertEquals(messages.get("yaml-point-to-itself.yaml").getErrorMessageList().size(), 1); + Assert.assertEquals(messages.get("yaml-point-to-itself.yaml").getErrorMessageList().get(0).getMessage(), "Nested files loop - [yaml-point-to-itself.yaml -- yaml-point-to-itself.yaml]"); + + Assert.assertEquals(messages.get("nested-psm_v1.0.yaml").getErrorMessageList().size(), 1); + Assert.assertEquals(messages.get("nested-psm_v1.0.yaml").getErrorMessageList().get(0).getMessage(), "Nested files loop - [nested-psm_v1.0.yaml -- nested-points-to-hot-nimbus-psm.yaml -- hot-nimbus-psm_v1.0.yaml -- nested-psm_v1.0.yaml]"); + } + + @Test + public void testOnlyOneNovaPointsToOnePort() throws IOException { + Map messages = runValidation("/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/negative_test/input"); + + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + + Assert.assertEquals(messages.get("hot-nimbus-psm_v1.0.yaml").getErrorMessageList().size(), 1); + Assert.assertEquals(messages.get("hot-nimbus-psm_v1.0.yaml").getErrorMessageList().get(0).getMessage(), "Resource Port oam1_int_port exceed allowed relations from NovaServer"); + } + + @Test + public void testServerGroupsPointedByServersDefinedCorrectly() throws IOException { + Map messages = runValidation("/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/negative_test/input"); + + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().size(), 3); + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().get(0).getMessage(), "Missing server group definition - BE_Affinity_2, nova_server_1"); + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().get(1).getMessage(), "Missing server group definition - BE_Affinity_2, nova_server_2"); + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().get(2).getMessage(), "Referenced resource - BE_Affinity_1 not found"); + } + + + @Test + public void testPolicyIsAffinityOrAntiAffinity() throws IOException { + Map messages = runValidation("/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/negative_test/input"); + + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + + Assert.assertEquals(messages.get("hot-nimbus-psm_v1.0.yaml").getErrorMessageList().size(), 1); + Assert.assertEquals(messages.get("hot-nimbus-psm_v1.0.yaml").getErrorMessageList().get(0).getMessage(), "Wrong policy in server group - pcrf_server_policies_1"); + } + + + @Test + public void testEnvContentIsSubSetOfHeatParameters() throws IOException { + Map messages = runValidation("/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/negative_test/input"); + + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.env").getErrorMessageList().size(), 1); + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.env").getErrorMessageList().get(0).getMessage(), "Env file hot-nimbus-pps_v1.0.env includes a parameter not in HEAT - mock_param"); + } + + @Test + public void testDefaultValueAlignWithType() throws IOException { + Map messages = runValidation("/openecomp/org/validation/validators/heat_validator/default_value_align_with_type/negative_test/input"); + + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().size(), 1); + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().get(0).getMessage(), "Parameter - pcrf_pps_image_name_1 default value not align with type number"); + } + + + @Test + public void testEnvParametersMatchDefinedHeatParameterTypes() throws IOException { + Map messages = runValidation("/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/negative_test/input"); + + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.env").getErrorMessageList().size(), 1); + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.env").getErrorMessageList().get(0).getMessage(), "Parameter env value pcrf_pps_flavor_name not align with type"); + + } + + @Test + public void testReferencedArtifactsExist() throws IOException { + Map messages = runValidation("/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/negative_test/input"); + + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().size(), 1); + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().get(0).getMessage(), "Missing artifact - nimbus-ethernet"); + + } + + + @Test + public void testResourcesGroupWithNested() throws IOException { + Map messages = runValidation("/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/negative_test/input"); + + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 3); + + Assert.assertEquals(messages.get("hot-nimbus-psm_v1.0.yaml").getErrorMessageList().size(), 2); + Assert.assertEquals(messages.get("hot-nimbus-psm_v1.0.yaml").getErrorMessageList().get(0).getMessage(), "Referenced parameter not found in nested file - nested-from-resources-group.yaml, resource name - nested-from-resources-group.yaml, parameter name - property_not_in_nested"); + Assert.assertEquals(messages.get("hot-nimbus-psm_v1.0.yaml").getErrorMessageList().get(1).getMessage(), "OS::Heat::ResourceGroup resource with resource_def which is not pointing to nested heat file is not supported, Resource ID [resource_without_resources_group], resource_def type [OS::Nova::Server]"); + + Assert.assertEquals(messages.get("nested-pps_v1.0.yaml").getErrorMessageList().size(), 1); + Assert.assertEquals(messages.get("nested-pps_v1.0.yaml").getErrorMessageList().get(0).getMessage(), "Nested files loop - [nested-pps_v1.0.yaml -- nested-from-resources-group.yaml -- hot-nimbus-pps_v1.0.yaml -- nested-pps_v1.0.yaml]"); + + Assert.assertEquals(messages.get("nested-not-exist.yaml").getErrorMessageList().size(), 1); + Assert.assertEquals(messages.get("nested-not-exist.yaml").getErrorMessageList().get(0).getMessage(), "Missing nested file - nested-not-exist.yaml"); + } + + + @Test + public void testResourceGroupWithInvalidType(){ + Map messages = runValidation("/openecomp/org/validation/validators/heat_validator/resource_group_invalid_type/negative_test/input"); + + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + + Assert.assertEquals(messages.get("hot-nimbus-psm_v1.0.yaml").getErrorMessageList().size(), 3); + Assert.assertEquals(messages.get("hot-nimbus-psm_v1.0.yaml").getErrorMessageList().get(0).getMessage(), "OS::Heat::ResourceGroup resource with resource_def which is not pointing to nested heat file is not supported, Resource ID [resource_with_resources_group_1], resource_def type [{get_param=pcrf_vnf_id}]"); + Assert.assertEquals(messages.get("hot-nimbus-psm_v1.0.yaml").getErrorMessageList().get(1).getMessage(), "OS::Heat::ResourceGroup resource with resource_def which is not pointing to nested heat file is not supported, Resource ID [resource_with_resources_group_2], resource_def type [OS::Nova::Server]"); + Assert.assertEquals(messages.get("hot-nimbus-psm_v1.0.yaml").getErrorMessageList().get(2).getMessage(), "A resource has an invalid or unsupported type - null, Resource ID [resource_with_resources_group_3]"); + } + + + @Test + public void testNetworkPolicyAssociatedWithAttachPolicy() throws IOException { + Map messages = runValidation("/openecomp/org/validation/validators/heat_validator/network_policy_associated_with_attach_policy/input"); + + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().size(), 1); + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().get(0).getMessage(), "NetworkPolicy not in use, Resource Id [not_used_server_pcrf_policy]"); + } + + + @Test + public void testSecurityGroupsCalledByPort() throws IOException { + Map messages = runValidation("/openecomp/org/validation/validators/heat_validator/security_group_called_by_port/input"); + + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().size(), 2); + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().get(0).getMessage(), "SecurityGroup not in use, Resource Id [not_used_security_group]"); + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().get(1).getMessage(), "Port not bind to any NOVA Server, Resource Id [attach_policy_resource]"); + } + + + @Test + public void testServerGroupCalledByServer() throws IOException { + Map messages = runValidation("/openecomp/org/validation/validators/heat_validator/server_group_called_by_nova_server/input"); + + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().size(), 1); + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().get(0).getMessage(), "ServerGroup not in use, Resource Id [not_used_server_group]"); + + } + + + @Test + public void testSecurityGroupBaseFileNoPorts() throws IOException { + Map messages = runValidation("/openecomp/org/validation/validators/heat_validator/security_group_base_file_no_ports/input"); + + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + + Assert.assertEquals(messages.get("baseFile.yaml").getErrorMessageList().size(), 1); + Assert.assertEquals(messages.get("baseFile.yaml").getErrorMessageList().get(0).getMessage(), "SecurityGroup not in use, Resource Id [shared_security_group_id3]"); + } + + + @Test + public void testDependsOn(){ + Map messages = runValidation("/openecomp/org/validation/validators/heat_validator/depends_on_points_to_existing_resource/input"); + + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().size(), 2); + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().get(0).getMessage(), "a Missing resource in depend On Missing Resource ID [resource_not_exist]"); + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().get(1).getMessage(), "a Missing resource in depend On Missing Resource ID [resource_3]"); + } + + + @Test + public void testSharedResourcesValidation(){ + Map messages = runValidation("/openecomp/org/validation/validators/heat_validator/shared_resources/input"); + + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().size(), 2); + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().get(0).getMessage(), "SecurityGroup not in use, Resource Id [not_used_security_group]"); + Assert.assertEquals(messages.get("hot-nimbus-pps_v1.0.yaml").getErrorMessageList().get(1).getMessage(), "Port not bind to any NOVA Server, Resource Id [attach_policy_resource]"); + } + + + @Test + public void testNoErrorWhenEmptyValueForParameterInEnv(){ + Map messages = runValidation("/openecomp/org/validation/validators/heat_validator/env_empty_value/input"); + + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + + MessageContainer envMessages = messages.get("env_empty_value.env"); + Assert.assertNull(envMessages); + } + + + @Test + public void testGetParamPseudoParameters(){ + Map messages = runValidation("/openecomp/org/validation/validators/heat_validator/pseudo_parameters/input"); + + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 0); + + } + + + @Override + public Map runValidation(String path) { + HeatValidator heatValidator = new HeatValidator(); + return testValidator(heatValidator, path); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/java/org/openecomp/sdc/validation/impl/validators/validators/ManifestValidatorTest.java b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/java/org/openecomp/sdc/validation/impl/validators/validators/ManifestValidatorTest.java new file mode 100644 index 0000000000..479a1fb83b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/java/org/openecomp/sdc/validation/impl/validators/validators/ManifestValidatorTest.java @@ -0,0 +1,125 @@ +package org.openecomp.sdc.validation.impl.validators.validators; + + +import org.openecomp.sdc.common.utils.AsdcCommon; +import org.openecomp.sdc.validation.impl.validators.ManifestValidator; +import org.openecomp.sdc.validation.impl.validators.ValidatorBaseTest; +import org.openecomp.core.validation.errors.Messages; +import org.openecomp.core.validation.types.MessageContainer; + +import org.testng.Assert; +import org.testng.annotations.Test; + +import java.util.Map; + +public class ManifestValidatorTest extends ValidatorBaseTest { + + + @Test + public void testValidManifest() { + Map messages = + runValidation("/openecomp/org/validation/validators/manifestValidator/validFiles"); + Assert.assertNotNull(messages); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 0); + } + + @Test + public void testManifestMissingFileInZip() { + Map messages = + runValidation("/openecomp/org/validation/validators/manifestValidator/missingFileInZip"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + Assert.assertTrue(messages.containsKey("singleVol.yaml")); + validateErrorMessage(messages.get("singleVol.yaml").getErrorMessageList().get(0).getMessage(), + Messages.MISSING_FILE_IN_ZIP.getErrorMessage()); + } + + @Test + public void testInvalidManifest() { + Map messages = + runValidation("/openecomp/org/validation/validators/manifestValidator/invalidManifest"); + Assert.assertNotNull(messages); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + Assert.assertTrue(messages.containsKey(AsdcCommon.MANIFEST_NAME)); + validateErrorMessage( + messages.get(AsdcCommon.MANIFEST_NAME).getErrorMessageList().get(0).getMessage(), + Messages.INVALID_MANIFEST_FILE.getErrorMessage(), AsdcCommon.MANIFEST_NAME); + + } + + @Test + public void testMissingFileInManifest() { + Map messages = + runValidation("/openecomp/org/validation/validators/manifestValidator/missingFileInManifest"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + Assert.assertTrue(messages.containsKey("extraFile.env")); + validateErrorMessage(messages.get("extraFile.env").getErrorMessageList().get(0).getMessage(), + Messages.MISSING_FILE_IN_MANIFEST.getErrorMessage()); + + } + + @Test + public void testInvalidFileTypeInManifest() { + Map messages = runValidation( + "/openecomp/org/validation/validators/manifestValidator/invalidFileTypeInManifest"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 4); + Assert.assertTrue(messages.containsKey("single.env.illegalSuffix")); + Assert.assertTrue(messages.containsKey("illegalTypeFile.yaml")); + Assert.assertTrue(messages.containsKey("single.yaml.illegalSuffix")); + Assert.assertTrue(messages.containsKey("singleVol.yaml.illegalSuffix")); + validateErrorMessage( + messages.get("single.env.illegalSuffix").getErrorMessageList().get(0).getMessage(), + Messages.WRONG_ENV_FILE_EXTENSION.getErrorMessage(), "single.env.illegalSuffix"); + validateErrorMessage( + messages.get("illegalTypeFile.yaml").getErrorMessageList().get(0).getMessage(), + Messages.INVALID_FILE_TYPE.getErrorMessage(), "illegalTypeFile.yaml"); + validateErrorMessage( + messages.get("single.yaml.illegalSuffix").getErrorMessageList().get(0).getMessage(), + Messages.WRONG_HEAT_FILE_EXTENSION.getErrorMessage(), "single.yaml.illegalSuffix"); + validateErrorMessage( + messages.get("singleVol.yaml.illegalSuffix").getErrorMessageList().get(0).getMessage(), + Messages.WRONG_HEAT_FILE_EXTENSION.getErrorMessage(), "singleVol.yaml.illegalSuffix"); + + } + + + @Test + public void testMissingFileInManifestAndInZip() { + + Map messages = runValidation( + "/openecomp/org/validation/validators/manifestValidator/missingFileInManifestAndInZip"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 2); + Assert.assertTrue(messages.containsKey("extraFile.env")); + Assert.assertTrue(messages.containsKey("singleVol.yaml")); + validateErrorMessage(messages.get("extraFile.env").getErrorMessageList().get(0).getMessage(), + Messages.MISSING_FILE_IN_MANIFEST.getErrorMessage()); + validateErrorMessage(messages.get("singleVol.yaml").getErrorMessageList().get(0).getMessage(), + Messages.MISSING_FILE_IN_ZIP.getErrorMessage()); + + } + + + @Test + public void testEnvInRoot() { + Map messages = + runValidation("/openecomp/org/validation/validators/manifestValidator/envInRoot"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + Assert.assertTrue(messages.containsKey("second.env")); + validateErrorMessage(messages.get("second.env").getErrorMessageList().get(0).getMessage(), + "ENV file must be associated to a HEAT file"); + } + + public Map runValidation(String path) { + ManifestValidator manifestValidator = new ManifestValidator(); + return testValidator(manifestValidator, path); + + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/java/org/openecomp/sdc/validation/impl/validators/validators/YamlValidatorTest.java b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/java/org/openecomp/sdc/validation/impl/validators/validators/YamlValidatorTest.java new file mode 100644 index 0000000000..abce8ec88c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/java/org/openecomp/sdc/validation/impl/validators/validators/YamlValidatorTest.java @@ -0,0 +1,89 @@ +package org.openecomp.sdc.validation.impl.validators.validators; + + +import org.openecomp.sdc.validation.impl.validators.ValidatorBaseTest; +import org.openecomp.sdc.validation.impl.validators.YamlValidator; +import org.openecomp.core.validation.errors.Messages; +import org.openecomp.core.validation.types.MessageContainer; + +import org.testng.Assert; +import org.testng.annotations.Test; + +import java.util.Map; + +public class YamlValidatorTest extends ValidatorBaseTest { + + + public Map runValidation(String path) { + YamlValidator validator = new YamlValidator(); + return testValidator(validator, path); + + } + + @Test + public void testValidYaml() { + + Map messages = runValidation( + "/openecomp/org/validation/validators/yaml_validator/valid_yaml/input/validHeat.yaml"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 0); + } + +// @Test + public void testInvalidTabYaml() { + + Map messages = runValidation( + "/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/input/invalidYamlTab.yaml"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + validateErrorMessage( + messages.get("invalidYamlTab.yaml").getErrorMessageList().get(0).getMessage(), + Messages.INVALID_YAML_FORMAT_REASON.getErrorMessage(), + "while scanning for the next tokenfound character '\\t(TAB)' that cannot start any token. (Do not use \\t(TAB) for indentation) in 'reader', line 14, column 5: \tadmin_state_up: true ^"); + + } + + + @Test + public void testDuplicateKeyInYaml() { + + Map messages = + runValidation("/openecomp/org/validation/validators/yaml_validator/duplicateKey.yaml"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + Assert.assertTrue(messages.containsKey("duplicateKey.yaml")); + validateErrorMessage( + messages.get("duplicateKey.yaml").getErrorMessageList().get(0).getMessage(), + Messages.INVALID_YAML_FORMAT_REASON.getErrorMessage(), + "while parsing MappingNode in 'reader', line 6, column 3: Key_1_unique: ^duplicate key: Key_2_not_unique in 'reader', line 31, column 1: ^"); + } + + + @Test + public void testInvalidYamlStructure() { + + Map messages = + runValidation("/openecomp/org/validation/validators/yaml_validator/invalidYamlStructure.yaml"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + Assert.assertTrue(messages.containsKey("invalidYamlStructure.yaml")); + validateErrorMessage( + messages.get("invalidYamlStructure.yaml").getErrorMessageList().get(0).getMessage(), + Messages.INVALID_YAML_FORMAT_REASON.getErrorMessage(), + "while parsing a block mapping in 'reader', line 8, column 7: admin_state_up: true ^expected , but found BlockEntry in 'reader', line 10, column 7: - shared: true ^"); + } + + @Test + public void testEmptyYaml() { + + Map messages = + runValidation("/openecomp/org/validation/validators/yaml_validator/emptyYaml.yaml"); + Assert.assertNotNull(messages); + Assert.assertEquals(messages.size(), 1); + Assert.assertTrue(messages.containsKey("emptyYaml.yaml")); + validateErrorMessage(messages.get("emptyYaml.yaml").getErrorMessageList().get(0).getMessage(), + Messages.INVALID_YAML_FORMAT_REASON.getErrorMessage(), + Messages.EMPTY_YAML_FILE.getErrorMessage()); + } + +} diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/negative/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/negative/MANIFEST.json new file mode 100644 index 0000000000..76ce6de6e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/negative/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "data": [ + { + "file": "first.yaml", + "type": "HEAT", + "isBase": true, + "data": [ + { + "file": "first.env", + "type": "HEAT_ENV" + }, + { + "file": "firstVol.yaml", + "type": "HEAT_VOL" + } + ] + }, + { + "file": "second.yaml", + "type": "HEAT", + "isBase": false + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/negative/first.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/negative/first.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/negative/first.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/negative/first.yaml new file mode 100644 index 0000000000..368834e847 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/negative/first.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat expose volume resource + +resources: + SecurityGroup_expose: + type: OS::Neutron::Net + +outputs: + not_expose_resource_network_output: + description: the pcrf_server + value: { get_param: ServerGroup_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/negative/firstVol.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/negative/firstVol.yaml new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/negative/firstVol.yaml @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/negative/second.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/negative/second.yaml new file mode 100644 index 0000000000..bb06b9d60a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/negative/second.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat second + +resources: + network_expose: + type: OS::Neutron::Net + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: network_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/positive/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/positive/MANIFEST.json new file mode 100644 index 0000000000..76ce6de6e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/positive/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "data": [ + { + "file": "first.yaml", + "type": "HEAT", + "isBase": true, + "data": [ + { + "file": "first.env", + "type": "HEAT_ENV" + }, + { + "file": "firstVol.yaml", + "type": "HEAT_VOL" + } + ] + }, + { + "file": "second.yaml", + "type": "HEAT", + "isBase": false + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/positive/first.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/positive/first.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/positive/first.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/positive/first.yaml new file mode 100644 index 0000000000..08955562d4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/positive/first.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat expose volume resource + +resources: + net_expose: + type: OS::Neutron::Net + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: net_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/positive/firstVol.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/positive/firstVol.yaml new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/positive/firstVol.yaml @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/positive/second.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/positive/second.yaml new file mode 100644 index 0000000000..bb06b9d60a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetwork/positive/second.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat second + +resources: + network_expose: + type: OS::Neutron::Net + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: network_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/negative/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/negative/MANIFEST.json new file mode 100644 index 0000000000..76ce6de6e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/negative/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "data": [ + { + "file": "first.yaml", + "type": "HEAT", + "isBase": true, + "data": [ + { + "file": "first.env", + "type": "HEAT_ENV" + }, + { + "file": "firstVol.yaml", + "type": "HEAT_VOL" + } + ] + }, + { + "file": "second.yaml", + "type": "HEAT", + "isBase": false + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/negative/first.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/negative/first.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/negative/first.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/negative/first.yaml new file mode 100644 index 0000000000..f5c6b598cc --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/negative/first.yaml @@ -0,0 +1,18 @@ +heat_template_version: 2013-05-23 + +description: heat expose volume resource + +resources: + net_expose: + type: OS::Neutron::Net + volume_expose: + type: OS::Cinder::Volume + + + +outputs: + not_expose_resource_network_output: + description: the pcrf_server + value: { get_param: ServerGroup_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/negative/firstVol.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/negative/firstVol.yaml new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/negative/firstVol.yaml @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/negative/second.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/negative/second.yaml new file mode 100644 index 0000000000..bb06b9d60a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/negative/second.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat second + +resources: + network_expose: + type: OS::Neutron::Net + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: network_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/positive/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/positive/MANIFEST.json new file mode 100644 index 0000000000..76ce6de6e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/positive/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "data": [ + { + "file": "first.yaml", + "type": "HEAT", + "isBase": true, + "data": [ + { + "file": "first.env", + "type": "HEAT_ENV" + }, + { + "file": "firstVol.yaml", + "type": "HEAT_VOL" + } + ] + }, + { + "file": "second.yaml", + "type": "HEAT", + "isBase": false + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/positive/first.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/positive/first.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/positive/first.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/positive/first.yaml new file mode 100644 index 0000000000..0c7abd6d49 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/positive/first.yaml @@ -0,0 +1,21 @@ +heat_template_version: 2013-05-23 + +description: heat expose volume resource + +resources: + net_expose: + type: OS::Neutron::Net + volume_expose: + type: OS::Cinder::Volume + + + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: net_expose } + expose_resource_volume_output: + description: the pcrf_server + value: { get_resource: volume_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/positive/firstVol.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/positive/firstVol.yaml new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/positive/firstVol.yaml @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/positive/second.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/positive/second.yaml new file mode 100644 index 0000000000..bb06b9d60a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeNetworkAndVolume/positive/second.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat second + +resources: + network_expose: + type: OS::Neutron::Net + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: network_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/negative/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/negative/MANIFEST.json new file mode 100644 index 0000000000..76ce6de6e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/negative/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "data": [ + { + "file": "first.yaml", + "type": "HEAT", + "isBase": true, + "data": [ + { + "file": "first.env", + "type": "HEAT_ENV" + }, + { + "file": "firstVol.yaml", + "type": "HEAT_VOL" + } + ] + }, + { + "file": "second.yaml", + "type": "HEAT", + "isBase": false + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/negative/first.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/negative/first.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/negative/first.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/negative/first.yaml new file mode 100644 index 0000000000..fe5effbc24 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/negative/first.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat expose volume resource + +resources: + SecurityGroup_expose: + type: OS::Neutron::SecurityGroup + +outputs: + not_expose_resource_network_output: + description: the pcrf_server + value: { get_param: ServerGroup_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/negative/firstVol.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/negative/firstVol.yaml new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/negative/firstVol.yaml @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/negative/second.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/negative/second.yaml new file mode 100644 index 0000000000..bb06b9d60a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/negative/second.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat second + +resources: + network_expose: + type: OS::Neutron::Net + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: network_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/positive/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/positive/MANIFEST.json new file mode 100644 index 0000000000..76ce6de6e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/positive/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "data": [ + { + "file": "first.yaml", + "type": "HEAT", + "isBase": true, + "data": [ + { + "file": "first.env", + "type": "HEAT_ENV" + }, + { + "file": "firstVol.yaml", + "type": "HEAT_VOL" + } + ] + }, + { + "file": "second.yaml", + "type": "HEAT", + "isBase": false + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/positive/first.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/positive/first.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/positive/first.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/positive/first.yaml new file mode 100644 index 0000000000..781bcba716 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/positive/first.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat expose volume resource + +resources: + SecurityGroup_expose: + type: OS::Neutron::SecurityGroup + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: SecurityGroup_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/positive/firstVol.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/positive/firstVol.yaml new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/positive/firstVol.yaml @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/positive/second.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/positive/second.yaml new file mode 100644 index 0000000000..bb06b9d60a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeSecurityGroup/positive/second.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat second + +resources: + network_expose: + type: OS::Neutron::Net + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: network_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/negative/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/negative/MANIFEST.json new file mode 100644 index 0000000000..76ce6de6e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/negative/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "data": [ + { + "file": "first.yaml", + "type": "HEAT", + "isBase": true, + "data": [ + { + "file": "first.env", + "type": "HEAT_ENV" + }, + { + "file": "firstVol.yaml", + "type": "HEAT_VOL" + } + ] + }, + { + "file": "second.yaml", + "type": "HEAT", + "isBase": false + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/negative/first.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/negative/first.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/negative/first.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/negative/first.yaml new file mode 100644 index 0000000000..5660cc003b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/negative/first.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat expose volume resource + +resources: + ServerGroup_expose: + type: OS::Nova::ServerGroup + +outputs: + not_expose_resource_network_output: + description: the pcrf_server + value: { get_param: ServerGroup_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/negative/firstVol.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/negative/firstVol.yaml new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/negative/firstVol.yaml @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/negative/second.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/negative/second.yaml new file mode 100644 index 0000000000..bb06b9d60a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/negative/second.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat second + +resources: + network_expose: + type: OS::Neutron::Net + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: network_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/positive/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/positive/MANIFEST.json new file mode 100644 index 0000000000..76ce6de6e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/positive/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "data": [ + { + "file": "first.yaml", + "type": "HEAT", + "isBase": true, + "data": [ + { + "file": "first.env", + "type": "HEAT_ENV" + }, + { + "file": "firstVol.yaml", + "type": "HEAT_VOL" + } + ] + }, + { + "file": "second.yaml", + "type": "HEAT", + "isBase": false + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/positive/first.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/positive/first.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/positive/first.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/positive/first.yaml new file mode 100644 index 0000000000..89fafb9d3a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/positive/first.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat expose volume resource + +resources: + serverGroup_expose: + type: OS::Nova::ServerGroup + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: serverGroup_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/positive/firstVol.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/positive/firstVol.yaml new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/positive/firstVol.yaml @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/positive/second.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/positive/second.yaml new file mode 100644 index 0000000000..bb06b9d60a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeServerGroup/positive/second.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat second + +resources: + network_expose: + type: OS::Neutron::Net + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: network_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/negative/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/negative/MANIFEST.json new file mode 100644 index 0000000000..76ce6de6e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/negative/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "data": [ + { + "file": "first.yaml", + "type": "HEAT", + "isBase": true, + "data": [ + { + "file": "first.env", + "type": "HEAT_ENV" + }, + { + "file": "firstVol.yaml", + "type": "HEAT_VOL" + } + ] + }, + { + "file": "second.yaml", + "type": "HEAT", + "isBase": false + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/negative/first.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/negative/first.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/negative/first.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/negative/first.yaml new file mode 100644 index 0000000000..e2a4301249 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/negative/first.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat expose volume resource + +resources: + volume_expose: + type: OS::Cinder::Volume + +outputs: + not_expose_resource_network_output: + description: the pcrf_server + value: { get_param: volume_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/negative/firstVol.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/negative/firstVol.yaml new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/negative/firstVol.yaml @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/negative/second.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/negative/second.yaml new file mode 100644 index 0000000000..bb06b9d60a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/negative/second.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat second + +resources: + network_expose: + type: OS::Neutron::Net + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: network_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/positive/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/positive/MANIFEST.json new file mode 100644 index 0000000000..76ce6de6e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/positive/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "data": [ + { + "file": "first.yaml", + "type": "HEAT", + "isBase": true, + "data": [ + { + "file": "first.env", + "type": "HEAT_ENV" + }, + { + "file": "firstVol.yaml", + "type": "HEAT_VOL" + } + ] + }, + { + "file": "second.yaml", + "type": "HEAT", + "isBase": false + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/positive/first.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/positive/first.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/positive/first.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/positive/first.yaml new file mode 100644 index 0000000000..63b576edb8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/positive/first.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat expose volume resource + +resources: + volume_expose: + type: OS::Cinder::Volume + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: volume_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/positive/firstVol.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/positive/firstVol.yaml new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/positive/firstVol.yaml @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/positive/second.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/positive/second.yaml new file mode 100644 index 0000000000..bb06b9d60a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/baseHeatDoesNotExposeVolume/positive/second.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat second + +resources: + network_expose: + type: OS::Neutron::Net + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: network_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/negative/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/negative/MANIFEST.json new file mode 100644 index 0000000000..76ce6de6e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/negative/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "data": [ + { + "file": "first.yaml", + "type": "HEAT", + "isBase": true, + "data": [ + { + "file": "first.env", + "type": "HEAT_ENV" + }, + { + "file": "firstVol.yaml", + "type": "HEAT_VOL" + } + ] + }, + { + "file": "second.yaml", + "type": "HEAT", + "isBase": false + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/negative/first.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/negative/first.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/negative/first.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/negative/first.yaml new file mode 100644 index 0000000000..3d3a1949b1 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/negative/first.yaml @@ -0,0 +1,25 @@ +heat_template_version: 2013-05-23 + +description: heat expose volume resource + +resources: + FSB2: + type: OS::Neutron::FloatingIP + properties: + name: { get_param: fsb_name_2 } + block_device_mapping: [{device_name: "vda", volume_id : {get_param: VMME_FSB2_boot_volume }, delete_on_termination: "false" }] + flavor: { get_param: fsb2-flavor } + availability_zone: { get_param: availability_zone_0 } + metadata: + VNF_id: { get_param: vnfvfVF_id } + vf_module_id: { get_param: vf_module_id } + networks: + - port: { get_resource: FSB2_Internal1 } + - port: { get_resource: FSB2_Internal2 } + - port: { get_resource: FSB2_OAM } +outputs: + expose_resource_nove_output: + description: the pcrf_server + value: { get_resource: FSB2 } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/negative/firstVol.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/negative/firstVol.yaml new file mode 100644 index 0000000000..7e82b2a7e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/negative/firstVol.yaml @@ -0,0 +1,19 @@ + +heat_template_version: 2013-05-23 + +parameters: + not_null: + type: number + label: not_number + + +resources: + volume_expose: + type: OS::Cinder::Volume + properties: + not_null: not_null +outputs: + not_expose_resource_network_output: + description: the pcrf_server + value: { get_resource: volume_expose } + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/negative/second.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/negative/second.yaml new file mode 100644 index 0000000000..bb06b9d60a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/negative/second.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat second + +resources: + network_expose: + type: OS::Neutron::Net + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: network_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/positive/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/positive/MANIFEST.json new file mode 100644 index 0000000000..76ce6de6e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/positive/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "data": [ + { + "file": "first.yaml", + "type": "HEAT", + "isBase": true, + "data": [ + { + "file": "first.env", + "type": "HEAT_ENV" + }, + { + "file": "firstVol.yaml", + "type": "HEAT_VOL" + } + ] + }, + { + "file": "second.yaml", + "type": "HEAT", + "isBase": false + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/positive/first.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/positive/first.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/positive/first.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/positive/first.yaml new file mode 100644 index 0000000000..2fc2a932fe --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/positive/first.yaml @@ -0,0 +1,37 @@ +heat_template_version: 2013-05-23 + +description: heat expose volume resource + +resources: + FSB2_Internal1: + type: OS::Neutron::Port + properties: + network_id: { get_param: Internal1_net_id } + FSB2_Internal2: + type: OS::Neutron::Port + properties: + network_id: { get_param: Internal2_net_name } + FSB2_OAM: + type: OS::Neutron::Port + properties: + network_id: { get_param: Internal3_net_id } + FSB2: + type: OS::Nova::Server + properties: + name: { get_param: fsb_name_2 } + block_device_mapping: [{device_name: "vda", volume_id : {get_param: VMME_FSB2_boot_volume }, delete_on_termination: "false" }] + flavor: { get_param: fsb2_flavor_name } + availability_zone: { get_param: availability_zone_0 } + metadata: + VNF_id: { get_param: vnfvfVF_id } + vf_module_id: { get_param: vf_module_id } + networks: + - port: { get_resource: FSB2_Internal1 } + - port: { get_resource: FSB2_Internal2 } + - port: { get_resource: FSB2_OAM } +outputs: + expose_resource_nove_output: + description: the pcrf_server + value: { get_resource: FSB2 } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/positive/firstVol.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/positive/firstVol.yaml new file mode 100644 index 0000000000..7e82b2a7e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/positive/firstVol.yaml @@ -0,0 +1,19 @@ + +heat_template_version: 2013-05-23 + +parameters: + not_null: + type: number + label: not_number + + +resources: + volume_expose: + type: OS::Cinder::Volume + properties: + not_null: not_null +outputs: + not_expose_resource_network_output: + description: the pcrf_server + value: { get_resource: volume_expose } + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/positive/second.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/positive/second.yaml new file mode 100644 index 0000000000..bb06b9d60a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatFloatingIpResourceType/positive/second.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat second + +resources: + network_expose: + type: OS::Neutron::Net + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: network_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/negative/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/negative/MANIFEST.json new file mode 100644 index 0000000000..76ce6de6e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/negative/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "data": [ + { + "file": "first.yaml", + "type": "HEAT", + "isBase": true, + "data": [ + { + "file": "first.env", + "type": "HEAT_ENV" + }, + { + "file": "firstVol.yaml", + "type": "HEAT_VOL" + } + ] + }, + { + "file": "second.yaml", + "type": "HEAT", + "isBase": false + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/negative/first.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/negative/first.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/negative/first.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/negative/first.yaml new file mode 100644 index 0000000000..5d6cea4d84 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/negative/first.yaml @@ -0,0 +1,37 @@ +heat_template_version: 2013-05-23 + +description: heat expose volume resource + +resources: + FSB2_Internal1: + type: OS::Neutron::Port + properties: + network_id: { get_param: Internal1_net_id } + FSB2_Internal2: + type: OS::Neutron::Port + properties: + network_id: { get_param: Internal2_net_id } + FSB2_OAM: + type: OS::Neutron::Port + properties: + network_id: { get_param: Internal1_net_name } + FSB2: + type: OS::Nova::Server + properties: + name: { get_param: fsb_name_2 } + block_device_mapping: [{device_name: "vda", volume_id : {get_param: VMME_FSB2_boot_volume }, delete_on_termination: "false" }] + flavor: { get_param: fsb2_flavor_name } + availability_zone: { get_param: availability_zone_0 } + metadata: + VNF_id: { get_param: vnfvfVF_id } + vf_module_id: { get_param: vf_module_id } + networks: + - port: { get_resource: FSB2_Internal1 } + - port: { get_resource: FSB2_Internal2 } + - port: { get_resource: FSB2_OAM } +outputs: + expose_resource_nove_output: + description: the pcrf_server + value: { get_resource: FSB2 } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/negative/firstVol.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/negative/firstVol.yaml new file mode 100644 index 0000000000..7e82b2a7e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/negative/firstVol.yaml @@ -0,0 +1,19 @@ + +heat_template_version: 2013-05-23 + +parameters: + not_null: + type: number + label: not_number + + +resources: + volume_expose: + type: OS::Cinder::Volume + properties: + not_null: not_null +outputs: + not_expose_resource_network_output: + description: the pcrf_server + value: { get_resource: volume_expose } + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/negative/second.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/negative/second.yaml new file mode 100644 index 0000000000..bb06b9d60a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/negative/second.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat second + +resources: + network_expose: + type: OS::Neutron::Net + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: network_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/positive/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/positive/MANIFEST.json new file mode 100644 index 0000000000..76ce6de6e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/positive/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "data": [ + { + "file": "first.yaml", + "type": "HEAT", + "isBase": true, + "data": [ + { + "file": "first.env", + "type": "HEAT_ENV" + }, + { + "file": "firstVol.yaml", + "type": "HEAT_VOL" + } + ] + }, + { + "file": "second.yaml", + "type": "HEAT", + "isBase": false + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/positive/first.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/positive/first.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/positive/first.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/positive/first.yaml new file mode 100644 index 0000000000..2c9fd08fb2 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/positive/first.yaml @@ -0,0 +1,52 @@ +heat_template_version: 2013-05-23 + +description: heat expose volume resource + +resources: + FSB2_Internal1: + type: OS::Neutron::Port + properties: + network_id: { get_param: Internal1_net_id } + FSB2_Internal2: + type: OS::Neutron::Port + properties: + network_id: { get_param: Internal2_net_name } + FSB2_OAM: + type: OS::Neutron::Port + properties: + network_id: { get_param: Internal3_net_id } + FSB2: + type: OS::Nova::Server + properties: + name: { get_param: fsb_name_2 } + block_device_mapping: [{device_name: "vda", volume_id : {get_param: VMME_FSB2_boot_volume }, delete_on_termination: "false" }] + flavor: { get_param: fsb2_flavor_name } + availability_zone: { get_param: availability_zone_0 } + metadata: + VNF_id: { get_param: vnfvfVF_id } + vf_module_id: { get_param: vf_module_id } + networks: + - port: { get_resource: FSB2_Internal1 } + - port: { get_resource: FSB2_Internal2 } + - port: { get_resource: FSB2_OAM } + + FSB3: + type: OS::Nova::Server + properties: + name: { get_param: fsb_name_2 } + block_device_mapping: [{device_name: "vda", volume_id : {get_param: VMME_FSB2_boot_volume }, delete_on_termination: "false" }] + flavor: { get_param: fsb2_flavor_name } + availability_zone: { get_param: availability_zone_0 } + metadata: + VNF_id: { get_param: vnfvfVF_id } + vf_module_id: { get_param: vf_module_id } + networks: + - port: { get_resource: FSB2_Internal1 } + - port: { get_resource: FSB2_Internal2 } + - port: { get_resource: FSB2_OAM } +outputs: + expose_resource_nove_output: + description: the pcrf_server + value: { get_resource: FSB2 } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/positive/firstVol.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/positive/firstVol.yaml new file mode 100644 index 0000000000..7e82b2a7e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/positive/firstVol.yaml @@ -0,0 +1,19 @@ + +heat_template_version: 2013-05-23 + +parameters: + not_null: + type: number + label: not_number + + +resources: + volume_expose: + type: OS::Cinder::Volume + properties: + not_null: not_null +outputs: + not_expose_resource_network_output: + description: the pcrf_server + value: { get_resource: volume_expose } + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/positive/second.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/positive/second.yaml new file mode 100644 index 0000000000..bb06b9d60a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaNetworkUniqueRoleConvention/positive/second.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat second + +resources: + network_expose: + type: OS::Neutron::Net + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: network_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/negative/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/negative/MANIFEST.json new file mode 100644 index 0000000000..76ce6de6e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/negative/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "data": [ + { + "file": "first.yaml", + "type": "HEAT", + "isBase": true, + "data": [ + { + "file": "first.env", + "type": "HEAT_ENV" + }, + { + "file": "firstVol.yaml", + "type": "HEAT_VOL" + } + ] + }, + { + "file": "second.yaml", + "type": "HEAT", + "isBase": false + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/negative/first.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/negative/first.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/negative/first.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/negative/first.yaml new file mode 100644 index 0000000000..60f8c45630 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/negative/first.yaml @@ -0,0 +1,58 @@ +heat_template_version: 2013-05-23 + +description: heat expose volume resource + +resources: + FSB2: + type: OS::Nova::Server + properties: + name: { get_param: pcrf_pps_server_name_4 } + block_device_mapping: [{device_name: "vda", volume_id : {get_param: VMME_FSB2_boot_volume }, delete_on_termination: "false" }] + flavor: { get_param: fsb2_flavor_name } + availability_zone: { get_param: availability_zone_a } + metadata: + VnF_id: { get_param: vnfvfVF_id } + vf_module_id: { get_param: vf_module_id } + networks: + - port: { get_resource: FSB2_Internal1 } + - port: { get_resource: FSB2_Internal2 } + - port: { get_resource: FSB2_OAM } + + FSB3: + type: OS::Nova::Server + properties: + name: { get_param: [pcrf_pps_server_names, 0] } + block_device_mapping: [{device_name: "vda", volume_id : {get_param: VMME_FSB2_boot_volume }, delete_on_termination: "false" }] + flavor: { get_param: fsb2_flavor_name } + availability_zone: { get_param: availability_zone} + metadata: + VnF_id: { get_param: vnfvfVF_id } + vf_module_id: { get_param: vf_module_id } + networks: + - port: { get_resource: FSB2_Internal1 } + - port: { get_resource: FSB2_Internal2 } + - port: { get_resource: FSB2_OAM } + + FSB4: + type: OS::Nova::Server + properties: + name: { get_param: [pcrf_pps_server_names, 0] } + block_device_mapping: [{device_name: "vda", volume_id : {get_param: VMME_FSB2_boot_volume }, delete_on_termination: "false" }] + flavor: { get_param: fsb2_flavor_name } + availability_zone: { get_param: availability_zone_blabla} + metadata: + VnF_id: { get_param: vnfvfVF_id } + vf_module_id: { get_param: vf_module_id } + networks: + - port: { get_resource: FSB2_Internal1 } + - port: { get_resource: FSB2_Internal2 } + - port: { get_resource: FSB2_OAM } +outputs: + expose_resource_nove_output2: + description: the pcrf_server + value: { get_resource: FSB2 } + expose_resource_nove_output3: + description: the pcrf_server + value: { get_resource: FSB3 } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/negative/firstVol.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/negative/firstVol.yaml new file mode 100644 index 0000000000..7e82b2a7e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/negative/firstVol.yaml @@ -0,0 +1,19 @@ + +heat_template_version: 2013-05-23 + +parameters: + not_null: + type: number + label: not_number + + +resources: + volume_expose: + type: OS::Cinder::Volume + properties: + not_null: not_null +outputs: + not_expose_resource_network_output: + description: the pcrf_server + value: { get_resource: volume_expose } + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/negative/second.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/negative/second.yaml new file mode 100644 index 0000000000..bb06b9d60a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/negative/second.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat second + +resources: + network_expose: + type: OS::Neutron::Net + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: network_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/positive/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/positive/MANIFEST.json new file mode 100644 index 0000000000..76ce6de6e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/positive/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "data": [ + { + "file": "first.yaml", + "type": "HEAT", + "isBase": true, + "data": [ + { + "file": "first.env", + "type": "HEAT_ENV" + }, + { + "file": "firstVol.yaml", + "type": "HEAT_VOL" + } + ] + }, + { + "file": "second.yaml", + "type": "HEAT", + "isBase": false + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/positive/first.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/positive/first.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/positive/first.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/positive/first.yaml new file mode 100644 index 0000000000..372761514f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/positive/first.yaml @@ -0,0 +1,43 @@ +heat_template_version: 2013-05-23 + +description: heat expose volume resource + +resources: + + FSB2: + type: OS::Nova::Server + properties: + name: { get_param: pcrf_pps_server_name_4 } + block_device_mapping: [{device_name: "vda", volume_id : {get_param: VMME_FSB2_boot_volume }, delete_on_termination: "false" }] + flavor: { get_param: fsb2_flavor_name } + availability_zone: { get_param: availability_zone_0 } + metadata: + VnF_id: { get_param: vnfvfVF_id } + vf_module_id: { get_param: vf_module_id } + networks: + - port: { get_resource: FSB2_Internal1 } + - port: { get_resource: FSB2_Internal2 } + - port: { get_resource: FSB2_OAM } + FSB3: + type: OS::Nova::Server + properties: + name: { get_param: [pcrf_pps_server_names, 0] } + block_device_mapping: [{device_name: "vda", volume_id : {get_param: VMME_FSB2_boot_volume }, delete_on_termination: "false" }] + flavor: { get_param: fsb2_flavor_name } + availability_zone: { get_param: availability_zone_0 } + metadata: + VnF_id: { get_param: vnfvfVF_id } + vf_module_id: { get_param: vf_module_id } + networks: + - port: { get_resource: FSB2_Internal1 } + - port: { get_resource: FSB2_Internal2 } + - port: { get_resource: FSB2_OAM } +outputs: + expose_resource_nove_output2: + description: the pcrf_server + value: { get_resource: FSB2 } + expose_resource_nove_output3: + description: the pcrf_server + value: { get_resource: FSB3 } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/positive/firstVol.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/positive/firstVol.yaml new file mode 100644 index 0000000000..7e82b2a7e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/positive/firstVol.yaml @@ -0,0 +1,19 @@ + +heat_template_version: 2013-05-23 + +parameters: + not_null: + type: number + label: not_number + + +resources: + volume_expose: + type: OS::Cinder::Volume + properties: + not_null: not_null +outputs: + not_expose_resource_network_output: + description: the pcrf_server + value: { get_resource: volume_expose } + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/positive/second.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/positive/second.yaml new file mode 100644 index 0000000000..bb06b9d60a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerAvailabilityZoneName/positive/second.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat second + +resources: + network_expose: + type: OS::Neutron::Net + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: network_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/negative/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/negative/MANIFEST.json new file mode 100644 index 0000000000..76ce6de6e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/negative/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "data": [ + { + "file": "first.yaml", + "type": "HEAT", + "isBase": true, + "data": [ + { + "file": "first.env", + "type": "HEAT_ENV" + }, + { + "file": "firstVol.yaml", + "type": "HEAT_VOL" + } + ] + }, + { + "file": "second.yaml", + "type": "HEAT", + "isBase": false + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/negative/first.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/negative/first.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/negative/first.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/negative/first.yaml new file mode 100644 index 0000000000..58e645e168 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/negative/first.yaml @@ -0,0 +1,41 @@ +heat_template_version: 2013-05-23 + +description: heat expose volume resource + +resources: + FSB2: + type: OS::Nova::Server + properties: + name: { get_param: fsb_name_2 } + block_device_mapping: [{device_name: "vda", volume_id : {get_param: VMME_FSB2_boot_volume }, delete_on_termination: "false" }] + flavor: { get_param: fsb2-flavor } + availability_zone: { get_param: availability_zone_0 } + metadata: + VNF_id: { get_param: vnfvfVF_id } + vf_module_id: { get_param: vf_module_id } + networks: + - port: { get_resource: FSB2_Internal1 } + - port: { get_resource: FSB2_Internal2 } + - port: { get_resource: FSB2_OAM } + + FSB3: + type: OS::Nova::Server + properties: + name: { get_param: fsb_name_2 } + block_device_mapping: [{device_name: "vda", volume_id : {get_param: VMME_FSB2_boot_volume }, delete_on_termination: "false" }] + image: { get_param: fsb2-image } + availability_zone: { get_param: availability_zone_0 } + metadata: + VNF_id: { get_param: vnfvfVF_id } + vf_module_id: { get_param: vf_module_id } + networks: + - port: { get_resource: FSB2_Internal1 } + - port: { get_resource: FSB2_Internal2 } + - port: { get_resource: FSB2_OAM } + +outputs: + expose_resource_nove_output: + description: the pcrf_server + value: { get_resource: FSB2 } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/negative/firstVol.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/negative/firstVol.yaml new file mode 100644 index 0000000000..7e82b2a7e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/negative/firstVol.yaml @@ -0,0 +1,19 @@ + +heat_template_version: 2013-05-23 + +parameters: + not_null: + type: number + label: not_number + + +resources: + volume_expose: + type: OS::Cinder::Volume + properties: + not_null: not_null +outputs: + not_expose_resource_network_output: + description: the pcrf_server + value: { get_resource: volume_expose } + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/negative/second.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/negative/second.yaml new file mode 100644 index 0000000000..bb06b9d60a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/negative/second.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat second + +resources: + network_expose: + type: OS::Neutron::Net + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: network_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/positive/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/positive/MANIFEST.json new file mode 100644 index 0000000000..76ce6de6e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/positive/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "data": [ + { + "file": "first.yaml", + "type": "HEAT", + "isBase": true, + "data": [ + { + "file": "first.env", + "type": "HEAT_ENV" + }, + { + "file": "firstVol.yaml", + "type": "HEAT_VOL" + } + ] + }, + { + "file": "second.yaml", + "type": "HEAT", + "isBase": false + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/positive/first.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/positive/first.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/positive/first.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/positive/first.yaml new file mode 100644 index 0000000000..2fc2a932fe --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/positive/first.yaml @@ -0,0 +1,37 @@ +heat_template_version: 2013-05-23 + +description: heat expose volume resource + +resources: + FSB2_Internal1: + type: OS::Neutron::Port + properties: + network_id: { get_param: Internal1_net_id } + FSB2_Internal2: + type: OS::Neutron::Port + properties: + network_id: { get_param: Internal2_net_name } + FSB2_OAM: + type: OS::Neutron::Port + properties: + network_id: { get_param: Internal3_net_id } + FSB2: + type: OS::Nova::Server + properties: + name: { get_param: fsb_name_2 } + block_device_mapping: [{device_name: "vda", volume_id : {get_param: VMME_FSB2_boot_volume }, delete_on_termination: "false" }] + flavor: { get_param: fsb2_flavor_name } + availability_zone: { get_param: availability_zone_0 } + metadata: + VNF_id: { get_param: vnfvfVF_id } + vf_module_id: { get_param: vf_module_id } + networks: + - port: { get_resource: FSB2_Internal1 } + - port: { get_resource: FSB2_Internal2 } + - port: { get_resource: FSB2_OAM } +outputs: + expose_resource_nove_output: + description: the pcrf_server + value: { get_resource: FSB2 } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/positive/firstVol.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/positive/firstVol.yaml new file mode 100644 index 0000000000..7e82b2a7e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/positive/firstVol.yaml @@ -0,0 +1,19 @@ + +heat_template_version: 2013-05-23 + +parameters: + not_null: + type: number + label: not_number + + +resources: + volume_expose: + type: OS::Cinder::Volume + properties: + not_null: not_null +outputs: + not_expose_resource_network_output: + description: the pcrf_server + value: { get_resource: volume_expose } + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/positive/second.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/positive/second.yaml new file mode 100644 index 0000000000..bb06b9d60a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerImageAndFlavor/positive/second.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat second + +resources: + network_expose: + type: OS::Neutron::Net + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: network_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/negative/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/negative/MANIFEST.json new file mode 100644 index 0000000000..76ce6de6e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/negative/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "data": [ + { + "file": "first.yaml", + "type": "HEAT", + "isBase": true, + "data": [ + { + "file": "first.env", + "type": "HEAT_ENV" + }, + { + "file": "firstVol.yaml", + "type": "HEAT_VOL" + } + ] + }, + { + "file": "second.yaml", + "type": "HEAT", + "isBase": false + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/negative/first.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/negative/first.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/negative/first.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/negative/first.yaml new file mode 100644 index 0000000000..d82e1ee2d3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/negative/first.yaml @@ -0,0 +1,27 @@ +heat_template_version: 2013-05-23 + +description: heat expose volume resource + +resources: + + FSB2: + type: OS::Nova::Server + properties: + name: { get_param: fsb_name_2 } + block_device_mapping: [{device_name: "vda", volume_id : {get_param: VMME_FSB2_boot_volume }, delete_on_termination: "false" }] + flavor: { get_param: fsb2_flavor_name } + availability_zone: { get_param: availability_zone_0 } + metadata: + not_VF_id: { get_param: vnfvfVF_id } + vf_module_id: { get_param: vf_module_id } + networks: + - port: { get_resource: FSB2_Internal1 } + - port: { get_resource: FSB2_Internal2 } + - port: { get_resource: FSB2_OAM } +outputs: + expose_resource_nove_output_1: + description: the pcrf_server + value: { get_resource: FSB2 } + + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/negative/firstVol.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/negative/firstVol.yaml new file mode 100644 index 0000000000..7e82b2a7e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/negative/firstVol.yaml @@ -0,0 +1,19 @@ + +heat_template_version: 2013-05-23 + +parameters: + not_null: + type: number + label: not_number + + +resources: + volume_expose: + type: OS::Cinder::Volume + properties: + not_null: not_null +outputs: + not_expose_resource_network_output: + description: the pcrf_server + value: { get_resource: volume_expose } + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/negative/second.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/negative/second.yaml new file mode 100644 index 0000000000..bb06b9d60a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/negative/second.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat second + +resources: + network_expose: + type: OS::Neutron::Net + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: network_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/positive/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/positive/MANIFEST.json new file mode 100644 index 0000000000..76ce6de6e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/positive/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "data": [ + { + "file": "first.yaml", + "type": "HEAT", + "isBase": true, + "data": [ + { + "file": "first.env", + "type": "HEAT_ENV" + }, + { + "file": "firstVol.yaml", + "type": "HEAT_VOL" + } + ] + }, + { + "file": "second.yaml", + "type": "HEAT", + "isBase": false + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/positive/first.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/positive/first.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/positive/first.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/positive/first.yaml new file mode 100644 index 0000000000..85bb15837b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/positive/first.yaml @@ -0,0 +1,26 @@ +heat_template_version: 2013-05-23 + +description: heat expose volume resource + +resources: + + FSB2: + type: OS::Nova::Server + properties: + name: { get_param: fsb_name_2 } + block_device_mapping: [{device_name: "vda", volume_id : {get_param: VMME_FSB2_boot_volume }, delete_on_termination: "false" }] + flavor: { get_param: fsb2_flavor_name } + availability_zone: { get_param: availability_zone_0 } + metadata: + VnF_id: { get_param: vnfvfVF_id } + vf_module_id: { get_param: vf_module_id } + networks: + - port: { get_resource: FSB2_Internal1 } + - port: { get_resource: FSB2_Internal2 } + - port: { get_resource: FSB2_OAM } +outputs: + expose_resource_nove_output: + description: the pcrf_server + value: { get_resource: FSB2 } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/positive/firstVol.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/positive/firstVol.yaml new file mode 100644 index 0000000000..7e82b2a7e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/positive/firstVol.yaml @@ -0,0 +1,19 @@ + +heat_template_version: 2013-05-23 + +parameters: + not_null: + type: number + label: not_number + + +resources: + volume_expose: + type: OS::Cinder::Volume + properties: + not_null: not_null +outputs: + not_expose_resource_network_output: + description: the pcrf_server + value: { get_resource: volume_expose } + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/positive/second.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/positive/second.yaml new file mode 100644 index 0000000000..bb06b9d60a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerMetaDataValidation/positive/second.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat second + +resources: + network_expose: + type: OS::Neutron::Net + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: network_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/negative/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/negative/MANIFEST.json new file mode 100644 index 0000000000..76ce6de6e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/negative/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "data": [ + { + "file": "first.yaml", + "type": "HEAT", + "isBase": true, + "data": [ + { + "file": "first.env", + "type": "HEAT_ENV" + }, + { + "file": "firstVol.yaml", + "type": "HEAT_VOL" + } + ] + }, + { + "file": "second.yaml", + "type": "HEAT", + "isBase": false + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/negative/first.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/negative/first.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/negative/first.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/negative/first.yaml new file mode 100644 index 0000000000..3a8e71939f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/negative/first.yaml @@ -0,0 +1,43 @@ +heat_template_version: 2013-05-23 + +description: heat expose volume resource + +resources: + + FSB2: + type: OS::Nova::Server + properties: + name: {get_param: pcrf_pps_server_4} + block_device_mapping: [{device_name: "vda", volume_id : {get_param: VMME_FSB2_boot_volume }, delete_on_termination: "false" }] + flavor: { get_param: fsb2_flavor_name } + availability_zone: { get_param: availability_zone_0 } + metadata: + VnF_id: { get_param: vnfvfVF_id } + vf_module_id: { get_param: vf_module_id } + networks: + - port: { get_resource: FSB2_Internal1 } + - port: { get_resource: FSB2_Internal2 } + - port: { get_resource: FSB2_OAM } + FSB3: + type: OS::Nova::Server + properties: + name: { get_param: [pcrf_pps_server, 0] } + block_device_mapping: [{device_name: "vda", volume_id : {get_param: VMME_FSB2_boot_volume }, delete_on_termination: "false" }] + flavor: { get_param: fsb2_flavor_name } + availability_zone: { get_param: availability_zone_0 } + metadata: + VnF_id: { get_param: vnfvfVF_id } + vf_module_id: { get_param: vf_module_id } + networks: + - port: { get_resource: FSB2_Internal1 } + - port: { get_resource: FSB2_Internal2 } + - port: { get_resource: FSB2_OAM } +outputs: + expose_resource_nove_output2: + description: the pcrf_server + value: { get_resource: FSB2 } + expose_resource_nove_output3: + description: the pcrf_server + value: { get_resource: FSB3 } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/negative/firstVol.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/negative/firstVol.yaml new file mode 100644 index 0000000000..7e82b2a7e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/negative/firstVol.yaml @@ -0,0 +1,19 @@ + +heat_template_version: 2013-05-23 + +parameters: + not_null: + type: number + label: not_number + + +resources: + volume_expose: + type: OS::Cinder::Volume + properties: + not_null: not_null +outputs: + not_expose_resource_network_output: + description: the pcrf_server + value: { get_resource: volume_expose } + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/negative/second.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/negative/second.yaml new file mode 100644 index 0000000000..bb06b9d60a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/negative/second.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat second + +resources: + network_expose: + type: OS::Neutron::Net + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: network_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/positive/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/positive/MANIFEST.json new file mode 100644 index 0000000000..76ce6de6e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/positive/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "data": [ + { + "file": "first.yaml", + "type": "HEAT", + "isBase": true, + "data": [ + { + "file": "first.env", + "type": "HEAT_ENV" + }, + { + "file": "firstVol.yaml", + "type": "HEAT_VOL" + } + ] + }, + { + "file": "second.yaml", + "type": "HEAT", + "isBase": false + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/positive/first.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/positive/first.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/positive/first.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/positive/first.yaml new file mode 100644 index 0000000000..13fc942865 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/positive/first.yaml @@ -0,0 +1,57 @@ +heat_template_version: 2013-05-23 + +description: heat expose volume resource + +resources: + + FSB2: + type: OS::Nova::Server + properties: + name: { get_param: pcrf_pps_server_name_4 } + block_device_mapping: [{device_name: "vda", volume_id : {get_param: VMME_FSB2_boot_volume }, delete_on_termination: "false" }] + flavor: { get_param: fsb2_flavor_name } + availability_zone: { get_param: availability_zone_0 } + metadata: + VnF_id: { get_param: vnfvfVF_id } + vf_module_id: { get_param: vf_module_id } + networks: + - port: { get_resource: FSB2_Internal1 } + - port: { get_resource: FSB2_Internal2 } + - port: { get_resource: FSB2_OAM } + FSB3: + type: OS::Nova::Server + properties: + name: { get_param: [pcrf_pps_server_names, 0] } + block_device_mapping: [{device_name: "vda", volume_id : {get_param: VMME_FSB2_boot_volume }, delete_on_termination: "false" }] + flavor: { get_param: fsb2_flavor_name } + availability_zone: { get_param: availability_zone_0 } + metadata: + VnF_id: { get_param: vnfvfVF_id } + vf_module_id: { get_param: vf_module_id } + networks: + - port: { get_resource: FSB2_Internal1 } + - port: { get_resource: FSB2_Internal2 } + - port: { get_resource: FSB2_OAM } + FSB4: + type: OS::Nova::Server + properties: + name: { get_param: [pcrf_pps_server_names, {get_param: index_num}] } + block_device_mapping: [{device_name: "vda", volume_id : {get_param: VMME_FSB2_boot_volume }, delete_on_termination: "false" }] + flavor: { get_param: fsb2_flavor_name } + availability_zone: { get_param: availability_zone_0 } + metadata: + VnF_id: { get_param: vnfvfVF_id } + vf_module_id: { get_param: vf_module_id } + networks: + - port: { get_resource: FSB2_Internal1 } + - port: { get_resource: FSB2_Internal2 } + - port: { get_resource: FSB2_OAM } +outputs: + expose_resource_nove_output2: + description: the pcrf_server + value: { get_resource: FSB2 } + expose_resource_nove_output3: + description: the pcrf_server + value: { get_resource: FSB3 } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/positive/firstVol.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/positive/firstVol.yaml new file mode 100644 index 0000000000..7e82b2a7e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/positive/firstVol.yaml @@ -0,0 +1,19 @@ + +heat_template_version: 2013-05-23 + +parameters: + not_null: + type: number + label: not_number + + +resources: + volume_expose: + type: OS::Cinder::Volume + properties: + not_null: not_null +outputs: + not_expose_resource_network_output: + description: the pcrf_server + value: { get_resource: volume_expose } + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/positive/second.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/positive/second.yaml new file mode 100644 index 0000000000..bb06b9d60a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatNovaServerNameValidation/positive/second.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat second + +resources: + network_expose: + type: OS::Neutron::Net + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: network_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/negative/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/negative/MANIFEST.json new file mode 100644 index 0000000000..76ce6de6e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/negative/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "data": [ + { + "file": "first.yaml", + "type": "HEAT", + "isBase": true, + "data": [ + { + "file": "first.env", + "type": "HEAT_ENV" + }, + { + "file": "firstVol.yaml", + "type": "HEAT_VOL" + } + ] + }, + { + "file": "second.yaml", + "type": "HEAT", + "isBase": false + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/negative/first.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/negative/first.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/negative/first.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/negative/first.yaml new file mode 100644 index 0000000000..85a4c58334 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/negative/first.yaml @@ -0,0 +1,40 @@ +heat_template_version: 2013-05-23 + +description: heat expose volume resource + +resources: + port_resource_0: + type: OS::Neutron::Port + properties: + network_id: { get_param: Internal1_net_id } + fixed_ips: + - ip_address: {get_param: pcrf_net_ips} + - ip_address: {get_param: pcrf_net_v6_ip_a} + port_resource_1: + type: OS::Neutron::Port + properties: + network_id: { get_param: Internal1_net_name } + fixed_ips: + - ip_address: {get_param: pcrf_net_v6_ips} + - ip_address: { "Fn::Select" : [ { get_param: indx }, { get_param: [{ get_param: mvs_mgmt_ip_0 }] } ] } + port_resource_2: + type: OS::Neutron::Port + properties: + network_id: { get_param: Internal1_net_fqdn } + fixed_ips: + - ip_address: {get_param: pcrf_net_ipz} + - ip_address: {get_param: pcrf_net_v6_ip_4} + - ip_address": {get_param: pcrf_net_v0_ip_3} + +outputs: + expose_resource_port_output_0: + description: the pcrf_server + value: { get_resource: port_resource_0 } + expose_resource_port_output_1: + description: the pcrf_server + value: { get_resource: port_resource_1 } + expose_resource_port_output_2: + description: the pcrf_server + value: { get_resource: port_resource_2 } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/negative/firstVol.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/negative/firstVol.yaml new file mode 100644 index 0000000000..7e82b2a7e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/negative/firstVol.yaml @@ -0,0 +1,19 @@ + +heat_template_version: 2013-05-23 + +parameters: + not_null: + type: number + label: not_number + + +resources: + volume_expose: + type: OS::Cinder::Volume + properties: + not_null: not_null +outputs: + not_expose_resource_network_output: + description: the pcrf_server + value: { get_resource: volume_expose } + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/negative/second.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/negative/second.yaml new file mode 100644 index 0000000000..bb06b9d60a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/negative/second.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat second + +resources: + network_expose: + type: OS::Neutron::Net + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: network_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/positive/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/positive/MANIFEST.json new file mode 100644 index 0000000000..76ce6de6e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/positive/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "data": [ + { + "file": "first.yaml", + "type": "HEAT", + "isBase": true, + "data": [ + { + "file": "first.env", + "type": "HEAT_ENV" + }, + { + "file": "firstVol.yaml", + "type": "HEAT_VOL" + } + ] + }, + { + "file": "second.yaml", + "type": "HEAT", + "isBase": false + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/positive/first.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/positive/first.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/positive/first.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/positive/first.yaml new file mode 100644 index 0000000000..7e0aaa373d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/positive/first.yaml @@ -0,0 +1,39 @@ +heat_template_version: 2013-05-23 + +description: heat expose volume resource + +resources: + port_resource_0: + type: OS::Neutron::Port + properties: + network_id: { get_param: Internal1_net_id } + fixed_ips: + - ip_address: {get_param: pcrf_net_ips} + + port_resource_1: + type: OS::Neutron::Port + properties: + network_id: { get_param: Internal1_net_name } + fixed_ips: + - ip_address: {get_param: pcrf_net_v6_ips} + + port_resource_2: + type: OS::Neutron::Port + properties: + network_id: { get_param: Internal1_net_fqdn } + fixed_ips: + - ip_address: {get_param: pcrf_net_ip_4} + - ip_address: {get_param: pcrf_net_v6_ip_4} + +outputs: + expose_resource_port_output_0: + description: the pcrf_server + value: { get_resource: port_resource_0 } + expose_resource_port_output_1: + description: the pcrf_server + value: { get_resource: port_resource_1 } + expose_resource_port_output_2: + description: the pcrf_server + value: { get_resource: port_resource_2 } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/positive/firstVol.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/positive/firstVol.yaml new file mode 100644 index 0000000000..7e82b2a7e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/positive/firstVol.yaml @@ -0,0 +1,19 @@ + +heat_template_version: 2013-05-23 + +parameters: + not_null: + type: number + label: not_number + + +resources: + volume_expose: + type: OS::Cinder::Volume + properties: + not_null: not_null +outputs: + not_expose_resource_network_output: + description: the pcrf_server + value: { get_resource: volume_expose } + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/positive/second.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/positive/second.yaml new file mode 100644 index 0000000000..bb06b9d60a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortFixedIpNamingConvention/positive/second.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat second + +resources: + network_expose: + type: OS::Neutron::Net + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: network_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/negative/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/negative/MANIFEST.json new file mode 100644 index 0000000000..76ce6de6e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/negative/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "data": [ + { + "file": "first.yaml", + "type": "HEAT", + "isBase": true, + "data": [ + { + "file": "first.env", + "type": "HEAT_ENV" + }, + { + "file": "firstVol.yaml", + "type": "HEAT_VOL" + } + ] + }, + { + "file": "second.yaml", + "type": "HEAT", + "isBase": false + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/negative/first.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/negative/first.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/negative/first.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/negative/first.yaml new file mode 100644 index 0000000000..abbf650c8d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/negative/first.yaml @@ -0,0 +1,28 @@ +heat_template_version: 2013-05-23 + +description: heat expose volume resource + +resources: + port_resource: + type: OS::Neutron::Port + properties: + network_id: { get_param: not_valid_network_name } + port_resource_1: + type: OS::Neutron::Port + properties: + network_id: { get_param: not_valid_net } + port_resource_2: + type: OS::Neutron::Port + properties: + network_id: { get_param: not_valid_net_id_error } + port_resource_3: + type: OS::Neutron::Port + properties: + network_id: { get_param: } + +outputs: + expose_resource_port_output: + description: the pcrf_server + value: { get_resource: port_resource } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/negative/firstVol.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/negative/firstVol.yaml new file mode 100644 index 0000000000..7e82b2a7e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/negative/firstVol.yaml @@ -0,0 +1,19 @@ + +heat_template_version: 2013-05-23 + +parameters: + not_null: + type: number + label: not_number + + +resources: + volume_expose: + type: OS::Cinder::Volume + properties: + not_null: not_null +outputs: + not_expose_resource_network_output: + description: the pcrf_server + value: { get_resource: volume_expose } + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/negative/second.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/negative/second.yaml new file mode 100644 index 0000000000..bb06b9d60a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/negative/second.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat second + +resources: + network_expose: + type: OS::Neutron::Net + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: network_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/positive/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/positive/MANIFEST.json new file mode 100644 index 0000000000..76ce6de6e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/positive/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "data": [ + { + "file": "first.yaml", + "type": "HEAT", + "isBase": true, + "data": [ + { + "file": "first.env", + "type": "HEAT_ENV" + }, + { + "file": "firstVol.yaml", + "type": "HEAT_VOL" + } + ] + }, + { + "file": "second.yaml", + "type": "HEAT", + "isBase": false + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/positive/first.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/positive/first.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/positive/first.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/positive/first.yaml new file mode 100644 index 0000000000..c6128e9470 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/positive/first.yaml @@ -0,0 +1,33 @@ +heat_template_version: 2013-05-23 + +description: heat expose volume resource + +resources: + port_resource_0: + type: OS::Neutron::Port + properties: + network_id: { get_param: Internal1_net_id } +resources: + port_resource_1: + type: OS::Neutron::Port + properties: + network_id: { get_param: Internal1_net_name } +resources: + port_resource_2: + type: OS::Neutron::Port + properties: + network_id: { get_param: Internal1_net_fqdn } + + +outputs: + expose_resource_port_output_0: + description: the pcrf_server + value: { get_resource: port_resource_0 } +expose_resource_port_output_1: + description: the pcrf_server + value: { get_resource: port_resource_1 } +expose_resource_port_output_2: + description: the pcrf_server + value: { get_resource: port_resource_2 } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/positive/firstVol.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/positive/firstVol.yaml new file mode 100644 index 0000000000..7e82b2a7e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/positive/firstVol.yaml @@ -0,0 +1,19 @@ + +heat_template_version: 2013-05-23 + +parameters: + not_null: + type: number + label: not_number + + +resources: + volume_expose: + type: OS::Cinder::Volume + properties: + not_null: not_null +outputs: + not_expose_resource_network_output: + description: the pcrf_server + value: { get_resource: volume_expose } + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/positive/second.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/positive/second.yaml new file mode 100644 index 0000000000..bb06b9d60a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatPortNetworkNamingConvention/positive/second.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat second + +resources: + network_expose: + type: OS::Neutron::Net + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: network_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/negative/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/negative/MANIFEST.json new file mode 100644 index 0000000000..76ce6de6e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/negative/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "data": [ + { + "file": "first.yaml", + "type": "HEAT", + "isBase": true, + "data": [ + { + "file": "first.env", + "type": "HEAT_ENV" + }, + { + "file": "firstVol.yaml", + "type": "HEAT_VOL" + } + ] + }, + { + "file": "second.yaml", + "type": "HEAT", + "isBase": false + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/negative/first.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/negative/first.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/negative/first.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/negative/first.yaml new file mode 100644 index 0000000000..3173885d7e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/negative/first.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat expose volume resource + +resources: + volume_expose: + type: OS::Cinder::Volume + +outputs: + not_expose_resource_network_output: + description: the pcrf_server + value: { get_resource: volume_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/negative/firstVol.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/negative/firstVol.yaml new file mode 100644 index 0000000000..4f0d65a735 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/negative/firstVol.yaml @@ -0,0 +1,19 @@ + +heat_template_version: 2013-05-23 + +parameters: + not_null: + type: number + label: not_number + + +resources: + volume_expose: + type: OS::Cinder::Volume + properties: + not_null: not_null +outputs: + not_expose_resource_network_output: + description: the pcrf_server + value: { get_param: volume_expose } + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/negative/second.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/negative/second.yaml new file mode 100644 index 0000000000..bb06b9d60a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/negative/second.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat second + +resources: + network_expose: + type: OS::Neutron::Net + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: network_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/positive/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/positive/MANIFEST.json new file mode 100644 index 0000000000..76ce6de6e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/positive/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "data": [ + { + "file": "first.yaml", + "type": "HEAT", + "isBase": true, + "data": [ + { + "file": "first.env", + "type": "HEAT_ENV" + }, + { + "file": "firstVol.yaml", + "type": "HEAT_VOL" + } + ] + }, + { + "file": "second.yaml", + "type": "HEAT", + "isBase": false + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/positive/first.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/positive/first.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/positive/first.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/positive/first.yaml new file mode 100644 index 0000000000..63b576edb8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/positive/first.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat expose volume resource + +resources: + volume_expose: + type: OS::Cinder::Volume + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: volume_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/positive/firstVol.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/positive/firstVol.yaml new file mode 100644 index 0000000000..7e82b2a7e6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/positive/firstVol.yaml @@ -0,0 +1,19 @@ + +heat_template_version: 2013-05-23 + +parameters: + not_null: + type: number + label: not_number + + +resources: + volume_expose: + type: OS::Cinder::Volume + properties: + not_null: not_null +outputs: + not_expose_resource_network_output: + description: the pcrf_server + value: { get_resource: volume_expose } + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/positive/second.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/positive/second.yaml new file mode 100644 index 0000000000..bb06b9d60a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/heatVolumeExpose/positive/second.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat second + +resources: + network_expose: + type: OS::Neutron::Net + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: network_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/missingBaseHeat/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/missingBaseHeat/MANIFEST.json new file mode 100644 index 0000000000..a189124e6c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/missingBaseHeat/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "data": [ + { + "file": "first.yaml", + "type": "HEAT", + "isBase": false, + "data": [ + { + "file": "first.env", + "type": "HEAT_ENV" + }, + { + "file": "firstVol.yaml", + "type": "HEAT_VOL" + } + ] + }, + { + "file": "second.yaml", + "type": "HEAT", + "isBase": false + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/missingBaseHeat/first.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/missingBaseHeat/first.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/missingBaseHeat/first.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/missingBaseHeat/first.yaml new file mode 100644 index 0000000000..bb06b9d60a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/missingBaseHeat/first.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat second + +resources: + network_expose: + type: OS::Neutron::Net + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: network_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/missingBaseHeat/firstVol.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/missingBaseHeat/firstVol.yaml new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/missingBaseHeat/firstVol.yaml @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/missingBaseHeat/second.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/missingBaseHeat/second.yaml new file mode 100644 index 0000000000..bb06b9d60a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/missingBaseHeat/second.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat second + +resources: + network_expose: + type: OS::Neutron::Net + +outputs: + expose_resource_network_output: + description: the pcrf_server + value: { get_resource: network_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/multiBaseHeat/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/multiBaseHeat/MANIFEST.json new file mode 100644 index 0000000000..3de70a21df --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/multiBaseHeat/MANIFEST.json @@ -0,0 +1,27 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "data": [ + { + "file": "first.yaml", + "type": "HEAT", + "isBase": true, + "data": [ + { + "file": "first.env", + "type": "HEAT_ENV" + }, + { + "file": "firstVol.yaml", + "type": "HEAT_VOL" + } + ] + }, + { + "file": "second.yaml", + "type": "HEAT", + "isBase": true + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/multiBaseHeat/first.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/multiBaseHeat/first.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/multiBaseHeat/first.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/multiBaseHeat/first.yaml new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/multiBaseHeat/firstVol.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/multiBaseHeat/firstVol.yaml new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/multiBaseHeat/second.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecompGuideLineValidator/multiBaseHeat/second.yaml new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/availability_zone_name/expected_output/expected_output.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/availability_zone_name/expected_output/expected_output.json new file mode 100644 index 0000000000..e9106a850c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/availability_zone_name/expected_output/expected_output.json @@ -0,0 +1,38 @@ +{ + "hot-nimbus-pps_v1.0.yaml": { + "errorMessageList": [ + { + "level": "WARNING", + "message": "Server Availability Zone not aligned with Guidelines, Resource ID [availability_zone_illegal_name_1]" + }, + { + "level": "WARNING", + "message": "Server Availability Zone not aligned with Guidelines, Resource ID [availability_zone_illegal_name_2]" + } + ] + }, + "nested-pps_v1.0.yaml": { + "errorMessageList": [ + { + "level": "WARNING", + "message": "Missing VF_MODULE_ID resource id [pcrf_server_pps]" + }, + { + "level": "WARNING", + "message": "Server Name not aligned with Guidelines, Resource ID [pcrf_server_pps]" + }, + { + "level": "WARNING", + "message": "Fixed_IPS not aligned with Guidelines, Resource ID [pcrf_pps_port_0]" + } + ] + }, + "MANIFEST.json": { + "errorMessageList": [ + { + "level": "WARNING", + "message": "Missing Base HEAT. Pay attention that without Base HEAT, there will be no shared resources" + } + ] + } +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/availability_zone_name/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/availability_zone_name/input/MANIFEST.json new file mode 100644 index 0000000000..1e719efb31 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/availability_zone_name/input/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.env", + "type": "HEAT_ENV" + } + ] + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/availability_zone_name/input/hot-nimbus-pps_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/availability_zone_name/input/hot-nimbus-pps_v1.0.env new file mode 100644 index 0000000000..809835d2b8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/availability_zone_name/input/hot-nimbus-pps_v1.0.env @@ -0,0 +1,12 @@ +parameters: + pcrf_pps_server_names: ZRDM1PCRF01PPS001,ZRDM1PCRF01PPS002,ZRDM1PCRF01PPS003,ZRDM1PCRF01PPS004,ZRDM1PCRF01PPS005,ZRDM1PCRF01PPS006 + pcrf_pps_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pps_flavor_name: lc.3xlarge + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.7,172.26.16.8,172.26.16.9,172.26.16.10,172.26.16.11,172.26.16.12 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + mock_param: abskdjska + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/availability_zone_name/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/availability_zone_name/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..1b865e75d5 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/availability_zone_name/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,92 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + default: True + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + availability_zone_1: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + + +resources: + + + availability_zone_legal_name_1: + type: OS::Nova::Server + properties: + name: { get_param: [pcrf_pps_server_names, 0] } + availability_zone: {get_param: availability_zone_1} + flavor: { get_param: pcrf_flavor_name } + metadata: + vnf_id: { get_param: pcrf_vnf_id } + vf_module_id: { get_param: pcrf_vnf_module_id } + + availability_zone_legal_name_2: + type: OS::Nova::Server + properties: + name: { get_param: [pcrf_pps_server_names, 0] } + availability_zone: {get_resource: availability_zone_1} + flavor: { get_param: pcrf_flavor_name } + metadata: + vnf_id: { get_param: pcrf_vnf_id } + vf_module_id: { get_param: pcrf_vnf_module_id } + + availability_zone_illegal_name_1: + type: OS::Nova::Server + properties: + name: { get_param: [pcrf_pps_server_names, 0] } + availability_zone: {get_param: availability_zone_name} + flavor: { get_param: pcrf_flavor_name } + metadata: + vnf_id: { get_param: pcrf_vnf_id } + vf_module_id: { get_param: pcrf_vnf_module_id } + + availability_zone_illegal_name_2: + type: OS::Nova::Server + properties: + name: { get_param: [pcrf_pps_server_names, 0] } + availability_zone: {get_param: availability_zone} + flavor: { get_param: pcrf_flavor_name } + metadata: + vnf_id: { get_param: pcrf_vnf_id } + vf_module_id: { get_param: pcrf_vnf_module_id } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/floating_ip_resource_type/expected_output/expected_output.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/floating_ip_resource_type/expected_output/expected_output.json new file mode 100644 index 0000000000..f0dc0d21a1 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/floating_ip_resource_type/expected_output/expected_output.json @@ -0,0 +1,34 @@ +{ + "hot-nimbus-pps_v1.0.yaml": { + "errorMessageList": [ + { + "level": "WARNING", + "message": "OS::Neutron::FloatingIP is in use, Resource ID [floating_ip_type]" + } + ] + }, + "nested-pps_v1.0.yaml": { + "errorMessageList": [ + { + "level": "WARNING", + "message": "Missing VF_MODULE_ID resource id [pcrf_server_pps]" + }, + { + "level": "WARNING", + "message": "Server Name not aligned with Guidelines, Resource ID [pcrf_server_pps]" + }, + { + "level": "WARNING", + "message": "Fixed_IPS not aligned with Guidelines, Resource ID [pcrf_pps_port_0]" + } + ] + }, + "MANIFEST.json": { + "errorMessageList": [ + { + "level": "WARNING", + "message": "Missing Base HEAT. Pay attention that without Base HEAT, there will be no shared resources" + } + ] + } +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/floating_ip_resource_type/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/floating_ip_resource_type/input/MANIFEST.json new file mode 100644 index 0000000000..1e719efb31 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/floating_ip_resource_type/input/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.env", + "type": "HEAT_ENV" + } + ] + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/floating_ip_resource_type/input/hot-nimbus-pps_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/floating_ip_resource_type/input/hot-nimbus-pps_v1.0.env new file mode 100644 index 0000000000..809835d2b8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/floating_ip_resource_type/input/hot-nimbus-pps_v1.0.env @@ -0,0 +1,12 @@ +parameters: + pcrf_pps_server_names: ZRDM1PCRF01PPS001,ZRDM1PCRF01PPS002,ZRDM1PCRF01PPS003,ZRDM1PCRF01PPS004,ZRDM1PCRF01PPS005,ZRDM1PCRF01PPS006 + pcrf_pps_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pps_flavor_name: lc.3xlarge + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.7,172.26.16.8,172.26.16.9,172.26.16.10,172.26.16.11,172.26.16.12 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + mock_param: abskdjska + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/floating_ip_resource_type/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/floating_ip_resource_type/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..05724cf55b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/floating_ip_resource_type/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,71 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + default: True + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + availability_zone_1: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + + +resources: + legal_resource_type1: + type: OS::Nova::Server + properties: + name: { get_param: [pcrf_pps_server_names, 0] } + availability_zone: {get_param: availability_zone_1} + flavor: {get_param: pcrf_flavor_name} + metadata: + vnf_id: { get_param: pcrf_vnf_id } + vf_module_id: { get_param: pcrf_vnf_module_id } + + floating_ip_type: + type: OS::Neutron::FloatingIP + properties: + name: { get_param: [pcrf_pps_server_names, 0] } + availability_zone: {get_param: availability_zone_name} + metadata: + vnf_id: { get_param: pcrf_vnf_id } + vf_module_id: { get_param: pcrf_vnf_module_id } + + + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/neutron_port_fixed_ip_name/expected_output/expected_output.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/neutron_port_fixed_ip_name/expected_output/expected_output.json new file mode 100644 index 0000000000..7eefd3d36e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/neutron_port_fixed_ip_name/expected_output/expected_output.json @@ -0,0 +1,42 @@ +{ + "hot-nimbus-pps_v1.0.yaml": { + "errorMessageList": [ + { + "level": "WARNING", + "message": "Fixed_IPS not aligned with Guidelines, Resource ID [fixed_ip_illegal_name_1]" + }, + { + "level": "WARNING", + "message": "Fixed_IPS not aligned with Guidelines, Resource ID [fixed_ip_illegal_name_2]" + }, + { + "level": "WARNING", + "message": "Fixed_IPS not aligned with Guidelines, Resource ID [fixed_ip_illegal_name_3]" + } + ] + }, + "nested-pps_v1.0.yaml": { + "errorMessageList": [ + { + "level": "WARNING", + "message": "Missing VF_MODULE_ID resource id [pcrf_server_pps]" + }, + { + "level": "WARNING", + "message": "Server Name not aligned with Guidelines, Resource ID [pcrf_server_pps]" + }, + { + "level": "WARNING", + "message": "Fixed_IPS not aligned with Guidelines, Resource ID [pcrf_pps_port_0]" + } + ] + }, + "MANIFEST.json": { + "errorMessageList": [ + { + "level": "WARNING", + "message": "Missing Base HEAT. Pay attention that without Base HEAT, there will be no shared resources" + } + ] + } +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/neutron_port_fixed_ip_name/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/neutron_port_fixed_ip_name/input/MANIFEST.json new file mode 100644 index 0000000000..1e719efb31 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/neutron_port_fixed_ip_name/input/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.env", + "type": "HEAT_ENV" + } + ] + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/neutron_port_fixed_ip_name/input/hot-nimbus-pps_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/neutron_port_fixed_ip_name/input/hot-nimbus-pps_v1.0.env new file mode 100644 index 0000000000..809835d2b8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/neutron_port_fixed_ip_name/input/hot-nimbus-pps_v1.0.env @@ -0,0 +1,12 @@ +parameters: + pcrf_pps_server_names: ZRDM1PCRF01PPS001,ZRDM1PCRF01PPS002,ZRDM1PCRF01PPS003,ZRDM1PCRF01PPS004,ZRDM1PCRF01PPS005,ZRDM1PCRF01PPS006 + pcrf_pps_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pps_flavor_name: lc.3xlarge + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.7,172.26.16.8,172.26.16.9,172.26.16.10,172.26.16.11,172.26.16.12 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + mock_param: abskdjska + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/neutron_port_fixed_ip_name/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/neutron_port_fixed_ip_name/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..749b7144b6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/neutron_port_fixed_ip_name/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,128 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + default: True + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + pcrf_net_ips: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + pcrf_net_v6_ips: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + pcrf_net_ip_4: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + pcrf_net_v6_ip_4: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + pcrf_net_ipz: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + pcrf_net_v0_ip_3: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + pcrf_net_v6_ip_a: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + + fixed_ip_legal_name_1: + type: OS::Neutron::Port + properties: + name: {get_param: pcrf_pps_image_name} + fixed_ips: + - ip_address: {get_param: pcrf_net_ips} + + fixed_ip_legal_name_2: + type: OS::Neutron::Port + properties: + name: {get_param: pcrf_pps_image_name} + fixed_ips: + - ip_address: {get_param: pcrf_net_v6_ips} + + fixed_ip_legal_name_3: + type: OS::Neutron::Port + properties: + name: {get_param: pcrf_pps_image_name} + fixed_ips: + - ip_address: {get_param: pcrf_net_ip_4} + + fixed_ip_legal_name_4: + type: OS::Neutron::Port + properties: + name: {get_param: pcrf_pps_image_name} + fixed_ips: + - ip_address: {get_param: pcrf_net_v6_ip_4} + + fixed_ip_legal_name_5: + type: OS::Neutron::Port + properties: + name: {get_param: pcrf_pps_image_name} + fixed_ips: + - ip_address: {get_resource: pcrf_net_v6_ip_4} + + fixed_ip_illegal_name_1: + type: OS::Neutron::Port + properties: + name: {get_param: pcrf_pps_image_name} + fixed_ips: + - ip_address: {get_param: pcrf_net_ipz} + + fixed_ip_illegal_name_2: + type: OS::Neutron::Port + properties: + name: {get_param: pcrf_pps_image_name} + fixed_ips: + - ip_address": {get_param: pcrf_net_v0_ip_3} + + fixed_ip_illegal_name_3: + type: OS::Neutron::Port + properties: + name: {get_param: pcrf_pps_image_name} + fixed_ips: + - ip_address: {get_param: pcrf_net_v6_ip_a} diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/nova_server_name/expected_output/expected_output.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/nova_server_name/expected_output/expected_output.json new file mode 100644 index 0000000000..ca1f58c1f8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/nova_server_name/expected_output/expected_output.json @@ -0,0 +1,50 @@ +{ + "hot-nimbus-pps_v1.0.yaml": { + "errorMessageList": [ + { + "level": "WARNING", + "message": "Server Name not aligned with Guidelines, Resource ID [nova_server_ilegal_name_1]" + }, + { + "level": "WARNING", + "message": "Server Name not aligned with Guidelines, Resource ID [nova_server_ilegal_name_2]" + }, + { + "level": "WARNING", + "message": "Server Name not aligned with Guidelines, Resource ID [nova_server_ilegal_name_3]" + }, + { + "level": "WARNING", + "message": "Server Name not aligned with Guidelines, Resource ID [nova_server_ilegal_name_4]" + }, + { + "level": "WARNING", + "message": "Server Name not aligned with Guidelines, Resource ID [nova_server_ilegal_name_5]" + } + ] + }, + "nested-pps_v1.0.yaml": { + "errorMessageList": [ + { + "level": "WARNING", + "message": "Missing VF_MODULE_ID resource id [pcrf_server_pps]" + }, + { + "level": "WARNING", + "message": "Server Name not aligned with Guidelines, Resource ID [pcrf_server_pps]" + }, + { + "level": "WARNING", + "message": "Fixed_IPS not aligned with Guidelines, Resource ID [pcrf_pps_port_0]" + } + ] + }, + "MANIFEST.json": { + "errorMessageList": [ + { + "level": "WARNING", + "message": "Missing Base HEAT. Pay attention that without Base HEAT, there will be no shared resources" + } + ] + } +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/nova_server_name/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/nova_server_name/input/MANIFEST.json new file mode 100644 index 0000000000..1e719efb31 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/nova_server_name/input/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.env", + "type": "HEAT_ENV" + } + ] + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/nova_server_name/input/hot-nimbus-pps_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/nova_server_name/input/hot-nimbus-pps_v1.0.env new file mode 100644 index 0000000000..809835d2b8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/nova_server_name/input/hot-nimbus-pps_v1.0.env @@ -0,0 +1,12 @@ +parameters: + pcrf_pps_server_names: ZRDM1PCRF01PPS001,ZRDM1PCRF01PPS002,ZRDM1PCRF01PPS003,ZRDM1PCRF01PPS004,ZRDM1PCRF01PPS005,ZRDM1PCRF01PPS006 + pcrf_pps_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pps_flavor_name: lc.3xlarge + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.7,172.26.16.8,172.26.16.9,172.26.16.10,172.26.16.11,172.26.16.12 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + mock_param: abskdjska + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/nova_server_name/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/nova_server_name/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..766cbf150f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/ecomp_naming_convention/nova_server_name/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,138 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + default: True + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + pcrf_vnf_module_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + pcrf_flavor: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + pcrf_pps_server_name_4: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + + +resources: + nova_server_legal_name_1: + type: OS::Nova::Server + properties: + name: { get_param: [pcrf_pps_server_names, 0] } + flavor: { get_param: pcrf_flavor_name } + metadata: + vnf_id: { get_param: pcrf_vnf_id } + vf_module_id: { get_param: pcrf_vnf_module_id } + + + nova_server_legal_name_2: + type: OS::Nova::Server + properties: + name: { get_param: pcrf_pps_server_name_4 } + flavor: { get_param: pcrf_flavor_name } + metadata: + vnf_id: { get_param: pcrf_vnf_id } + vf_module_id: { get_param: pcrf_vnf_module_id } + + nova_server_legal_name_3: + type: OS::Nova::Server + properties: + name: { get_resource: pcrf_pps_server_name_4 } + flavor: { get_param: pcrf_flavor_name } + metadata: + vnf_id: { get_param: pcrf_vnf_id } + vf_module_id: { get_param: pcrf_vnf_module_id } + + nova_server_ilegal_name_1: + type: OS::Nova::Server + properties: + name: { get_param: pcrf_pps_server_name_a } + flavor: { get_param: pcrf_flavor_name } + metadata: + vnf_id: { get_param: pcrf_vnf_id } + vf_module_id: { get_param: pcrf_vnf_module_id } + + nova_server_ilegal_name_2: + type: OS::Nova::Server + properties: + name: { get_param: pcrf_pps_server_nameds_a } + flavor: { get_param: pcrf_flavor_name } + metadata: + vnf_id: { get_param: pcrf_vnf_id } + vf_module_id: { get_param: pcrf_vnf_module_id } + + nova_server_ilegal_name_3: + type: OS::Nova::Server + properties: + name: { get_param: pcrf_pps_server_name_a } + flavor: { get_param: pcrf_pps_flavor_name } + metadata: + vnf_id: { get_param: pcrf_vnf_id } + vf_module_id: { get_param: pcrf_vnf_module_id } + + nova_server_ilegal_name_4: + type: OS::Nova::Server + properties: + name: { get_param: pcrf_pps_server_name_a } + flavor: { get_param: pcrf_pps_flavor_name } + metadata: + vnf_id: { get_param: pcrf_vnf_id } + vf_module_id: { get_param: pcrf_vnf_module_id } + + nova_server_ilegal_name_5: + type: OS::Nova::Server + properties: + name: { get_param: pcrf_pps_server_name_a } + flavor: { get_param: pcrf_pps_flavor_name } + metadata: + vnf_id: { get_param: pcrf_vnf_id } + vf_module_id: { get_param: pcrf_vnf_module_id } + + nova_server_ilegal_name_6: + type: OS::Nova::Server + properties: + name: pcrf_pps_server_name_a + flavor: { get_param: pcrf_pps_flavor_name } + metadata: + vnf_id: { get_param: pcrf_vnf_id } + vf_module_id: { get_param: pcrf_vnf_module_id } diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/default_value_align_with_type/negative_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/default_value_align_with_type/negative_test/input/MANIFEST.json new file mode 100644 index 0000000000..1e719efb31 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/default_value_align_with_type/negative_test/input/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.env", + "type": "HEAT_ENV" + } + ] + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/default_value_align_with_type/negative_test/input/hot-nimbus-pps_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/default_value_align_with_type/negative_test/input/hot-nimbus-pps_v1.0.env new file mode 100644 index 0000000000..8ae6fc021a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/default_value_align_with_type/negative_test/input/hot-nimbus-pps_v1.0.env @@ -0,0 +1,11 @@ +parameters: + pcrf_pps_server_names: ZRDM1PCRF01PPS001,ZRDM1PCRF01PPS002,ZRDM1PCRF01PPS003,ZRDM1PCRF01PPS004,ZRDM1PCRF01PPS005,ZRDM1PCRF01PPS006 + pcrf_pps_image_name_1: 14 + pcrf_pps_flavor_name: lc.3xlarge + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.7,172.26.16.8,172.26.16.9,172.26.16.10,172.26.16.11,172.26.16.12 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/default_value_align_with_type/negative_test/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/default_value_align_with_type/negative_test/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..555f6ae852 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/default_value_align_with_type/negative_test/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,60 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name_1: + type: number + default: True + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_image_name_2: + type: + default: True + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_image_name_3: + type: number + default: + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_pps_001: + type: OS::Heat::CloudConfig + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/depends_on_points_to_existing_resource/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/depends_on_points_to_existing_resource/input/MANIFEST.json new file mode 100644 index 0000000000..a1ec6bc0f7 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/depends_on_points_to_existing_resource/input/MANIFEST.json @@ -0,0 +1,11 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/depends_on_points_to_existing_resource/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/depends_on_points_to_existing_resource/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..35a0efb28d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/depends_on_points_to_existing_resource/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,43 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + +resources: + resource_depends_on_legal_1: + type: OS::Heat::CloudConfig + depends_on: [resource_1, resource_2] + + resource_depends_on_legal_2: + type: OS::Heat::CloudConfig + depends_on: resource_1 + + resource_depends_on_illegal_1: + type: OS::Heat::CloudConfig + depends_on: resource_not_exist + + resource_depends_on_illegal_2: + type: OS::Heat::CloudConfig + depends_on: [resource_1, resource_3] + + resource_depends_on_illegal_3: + type: OS::Heat::CloudConfig + depends_on: + + resource_1: + type: OS::Heat::CloudConfig + + resource_2: + type: OS::Heat::CloudConfig + + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/negative_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/negative_test/input/MANIFEST.json new file mode 100644 index 0000000000..1e719efb31 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/negative_test/input/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.env", + "type": "HEAT_ENV" + } + ] + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/negative_test/input/hot-nimbus-pps_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/negative_test/input/hot-nimbus-pps_v1.0.env new file mode 100644 index 0000000000..809835d2b8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/negative_test/input/hot-nimbus-pps_v1.0.env @@ -0,0 +1,12 @@ +parameters: + pcrf_pps_server_names: ZRDM1PCRF01PPS001,ZRDM1PCRF01PPS002,ZRDM1PCRF01PPS003,ZRDM1PCRF01PPS004,ZRDM1PCRF01PPS005,ZRDM1PCRF01PPS006 + pcrf_pps_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pps_flavor_name: lc.3xlarge + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.7,172.26.16.8,172.26.16.9,172.26.16.10,172.26.16.11,172.26.16.12 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + mock_param: abskdjska + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/negative_test/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/negative_test/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..4605195eaf --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/negative_test/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,54 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + pcrf_psm_server_name: + type: string + +resources: + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + params: + $vm_name: { get_param: pcrf_psm_server_name } + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/positive_test/expected_output/expected_output.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/positive_test/expected_output/expected_output.json new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/positive_test/expected_output/expected_output.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/positive_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/positive_test/input/MANIFEST.json new file mode 100644 index 0000000000..fe7d8bdf5a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/positive_test/input/MANIFEST.json @@ -0,0 +1,51 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "hot-nimbus-psm_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "nested-pps_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "nested-psm_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "mount_iso_script.sh", + "type": "SHELL" + }, + { + "file": "cloud-nimbus.sh", + "type": "SHELL" + }, + { + "file": "nimbus-ethernet", + "type": "OTHER" + }, + { + "file": "nimbus-ethernet-gw", + "type": "OTHER" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/positive_test/input/hot-nimbus-pps_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/positive_test/input/hot-nimbus-pps_v1.0.env new file mode 100644 index 0000000000..340be2b815 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/positive_test/input/hot-nimbus-pps_v1.0.env @@ -0,0 +1,11 @@ +parameters: + pcrf_pps_server_names: ZRDM1PCRF01PPS001,ZRDM1PCRF01PPS002,ZRDM1PCRF01PPS003,ZRDM1PCRF01PPS004,ZRDM1PCRF01PPS005,ZRDM1PCRF01PPS006 + pcrf_pps_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pps_flavor_name: lc.3xlarge + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.7,172.26.16.8,172.26.16.9,172.26.16.10,172.26.16.11,172.26.16.12 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/positive_test/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/positive_test/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..05bd6c9318 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/positive_test/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,121 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_pps_001: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_002: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 1] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_003: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 2] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_004: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 3] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_005: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 4] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_006: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 5] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/positive_test/input/hot-nimbus-psm_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/positive_test/input/hot-nimbus-psm_v1.0.env new file mode 100644 index 0000000000..f24e4763c6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/positive_test/input/hot-nimbus-psm_v1.0.env @@ -0,0 +1,10 @@ +parameters: + pcrf_psm_server_names: ZRDM1PCRF01PSM001,ZRDM1PCRF01PSM002,ZRDM1PCRF01PSM003,ZRDM1PCRF01PSM004,ZRDM1PCRF01PSM005,ZRDM1PCRF01PSM006,ZRDM1PCRF01PSM007,ZRDM1PCRF01PSM008,ZRDM1PCRF01PSM009,ZRDM1PCRF01PSM010,ZRDM1PCRF01PSM011,ZRDM1PCRF01PSM012 + pcrf_psm_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_psm_flavor_name: lc.4xlarge4 + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.63,172.26.16.64,172.26.16.65,172.26.16.66,172.26.16.67,172.26.16.68,172.26.16.69,172.26.16.70,172.26.16.71,172.26.16.72,172.26.16.73,172.26.16.74 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/positive_test/input/hot-nimbus-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/positive_test/input/hot-nimbus-psm_v1.0.yaml new file mode 100644 index 0000000000..c2d7b05ead --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/positive_test/input/hot-nimbus-psm_v1.0.yaml @@ -0,0 +1,199 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_names: + type: comma_delimited_list + label: PCRF SM server names + description: name of the PCRF SM instance + pcrf_psm_image_name: + type: string + label: PCRF SM image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_psm_001: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 0] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_002: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 1] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_003: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 2] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_004: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 3] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_005: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 4] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_006: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 5] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_007: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 6] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 6] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_008: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 7] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 7] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_009: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 8] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 8] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_010: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 9] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 9] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_011: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 10] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 10] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_012: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 11] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 11] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/positive_test/input/nested-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/positive_test/input/nested-pps_v1.0.yaml new file mode 100644 index 0000000000..b7291d69d3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/positive_test/input/nested-pps_v1.0.yaml @@ -0,0 +1,97 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_name: + type: string + label: PCRF PS server name + description: PCRF PS server name + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + params: + $vm_name: { get_param: pcrf_pps_server_name } + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_pps: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_pps_server_name } + image: { get_param: pcrf_pps_image_name } + flavor: { get_param: pcrf_pps_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcrf_pps_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + + pcrf_pps_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/positive_test/input/nested-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/positive_test/input/nested-psm_v1.0.yaml new file mode 100644 index 0000000000..6868728b73 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_content_is_subset_of_heat/positive_test/input/nested-psm_v1.0.yaml @@ -0,0 +1,97 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_name: + type: string + label: PCRF SM server name + description: PCRF SM server name + pcrf_psm_image_name: + type: string + label: image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + params: + $vm_name: { get_param: pcrf_psm_server_name } + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_psm: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_psm_server_name } + image: { get_param: pcrf_psm_image_name } + flavor: { get_param: pcrf_psm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: psm01_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + #scheduler_hints: {group: { get_resource: servergroup_nimbus }} + + psm01_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_empty_value/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_empty_value/input/MANIFEST.json new file mode 100644 index 0000000000..d383ab6c95 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_empty_value/input/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "env_empty_value.yaml", + "type": "HEAT", + "data": [ + { + "file": "env_empty_value.env", + "type": "HEAT_ENV" + } + ] + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_empty_value/input/env_empty_value.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_empty_value/input/env_empty_value.env new file mode 100644 index 0000000000..20f9eed60d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_empty_value/input/env_empty_value.env @@ -0,0 +1,3 @@ +parameters: + oam_mgmt_network_id: e1724ea7-553b-470d-a9eb-ed274528a0a1 + cluster_size: diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_empty_value/input/env_empty_value.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_empty_value/input/env_empty_value.yaml new file mode 100644 index 0000000000..9d01d63908 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_empty_value/input/env_empty_value.yaml @@ -0,0 +1,122 @@ +heat_template_version: 2014-10-16 + +description: create BIG-IP VE instance + +parameters: + + # 06-01-2015 added anti-affinity policy + lb_server_group: + type: string + description: Anti-affinity group for lb + server_name: + type: comma_delimited_list + label: BIG-IP instance name + description: BIG-IP instance name + image_name: + type: string + label: image name + description: the MVM BIG-IP image name + flavor_name: + type: string + label: bigip flavor name + description: the flavor name of bigip instance + availabilityzone_name: + type: string + label: availabilityzone name + description: the availabilityzone name + security_group_name: + type: string + label: security group name + description: the name of security group + oam_mgmt_network_id: + type: string + label: oam network name + description: mgmt eth0 local mgmt network + oam_mgmt_network_ip: + type: comma_delimited_list + label: oam network ip + description: the local ip of mgmt network + oam_network_id: + type: string + label: bigip oam network id + description: oam TMM 1.1 network + oam_network_ip: + type: comma_delimited_list + label: oam network ip + description: the local ip of oam network + oam_network_vip_ip: + type: string + label: oam network virtual server ip + description: oam network virtual server ip + dmz_network_id: + type: string + label: bigip dmz network id + description: dmz TMM 1.2 network + dmz_network_ip: + type: comma_delimited_list + label: dmz network ip + description: BIGIP dmz network ip + dmz_network_vip_ip: + type: string + label: dmz network virtual server ip + description: dmz network virtual server ip + core_network_id: + type: string + label: core network id + description: core TMM 1.3 network + core_network_ip: + type: comma_delimited_list + label: core network ip + description: core network ip + core_network_vip_ip: + type: string + label: core network virtual server ip + description: core network virtual server ip + ha_network_f5_id: + type: string + label: HA network id + description: HA TMM 1.4 network + ha_local_ip: + type: comma_delimited_list + label: HA local ip + description: HA failover local ip + vnf_id: + type: string + description: Unique ID for this VF instance + vf_module_id: + type: string + description: Unique ID for this VF_MODULE instance + cluster_size: + type: number + description: number of instance of the VF_module + +resources: + f5_modules: + type: OS::Heat::ResourceGroup + properties: + count: { get_param: cluster_size } + resource_def: + type: vvm_f5_5nic.nested.heat.yaml + properties: + lb_system_name: { get_param: lb_server_group } + server_name: { get_param: server_name } + image_name: { get_param: image_name } + flavor_name: { get_param: flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + security_group_name: { get_param: security_group_name } + oam_mgmt_network_id: { get_param: oam_mgmt_network_id } + oam_mgmt_network_ip: { get_param: oam_mgmt_network_ip } + oam_network_id: { get_param: oam_network_id } + oam_network_ip: { get_param: oam_network_ip } + oam_network_vip_ip: { get_param: oam_network_vip_ip } + dmz_network_id: { get_param: dmz_network_id } + dmz_network_ip: { get_param: dmz_network_ip } + dmz_network_vip_ip: { get_param: dmz_network_vip_ip } + core_network_id: { get_param: core_network_id } + core_network_ip: { get_param: core_network_ip } + core_network_vip_ip: { get_param: core_network_vip_ip } + ha_network_id: { get_param: ha_network_f5_id } + ha_local_ip: { get_param: ha_local_ip } + vnf_id: { get_param: vnf_id } + vf_module_id: { get_param: vf_module_id } + indx: "%index%" diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/negative_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/negative_test/input/MANIFEST.json new file mode 100644 index 0000000000..06df1e696d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/negative_test/input/MANIFEST.json @@ -0,0 +1,35 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "hot-nimbus-psm_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "nested-pps_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "nested-psm_v1.0.yaml", + "type": "HEAT" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/negative_test/input/hot-nimbus-pps_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/negative_test/input/hot-nimbus-pps_v1.0.env new file mode 100644 index 0000000000..089284d177 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/negative_test/input/hot-nimbus-pps_v1.0.env @@ -0,0 +1,11 @@ +parameters: + pcrf_pps_server_names: 1 + pcrf_pps_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pps_flavor_name: lc.3xlarge + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.7,172.26.16.8,172.26.16.9,172.26.16.10,172.26.16.11,172.26.16.12 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/negative_test/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/negative_test/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..4944424af8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/negative_test/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,50 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: number + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_pps_001: + type: OS::Heat::CloudConfig + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/positive_test/expected_output/expected_output.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/positive_test/expected_output/expected_output.json new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/positive_test/expected_output/expected_output.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/positive_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/positive_test/input/MANIFEST.json new file mode 100644 index 0000000000..fe7d8bdf5a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/positive_test/input/MANIFEST.json @@ -0,0 +1,51 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "hot-nimbus-psm_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "nested-pps_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "nested-psm_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "mount_iso_script.sh", + "type": "SHELL" + }, + { + "file": "cloud-nimbus.sh", + "type": "SHELL" + }, + { + "file": "nimbus-ethernet", + "type": "OTHER" + }, + { + "file": "nimbus-ethernet-gw", + "type": "OTHER" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/positive_test/input/hot-nimbus-pps_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/positive_test/input/hot-nimbus-pps_v1.0.env new file mode 100644 index 0000000000..340be2b815 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/positive_test/input/hot-nimbus-pps_v1.0.env @@ -0,0 +1,11 @@ +parameters: + pcrf_pps_server_names: ZRDM1PCRF01PPS001,ZRDM1PCRF01PPS002,ZRDM1PCRF01PPS003,ZRDM1PCRF01PPS004,ZRDM1PCRF01PPS005,ZRDM1PCRF01PPS006 + pcrf_pps_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pps_flavor_name: lc.3xlarge + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.7,172.26.16.8,172.26.16.9,172.26.16.10,172.26.16.11,172.26.16.12 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/positive_test/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/positive_test/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..05bd6c9318 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/positive_test/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,121 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_pps_001: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_002: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 1] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_003: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 2] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_004: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 3] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_005: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 4] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_006: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 5] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/positive_test/input/hot-nimbus-psm_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/positive_test/input/hot-nimbus-psm_v1.0.env new file mode 100644 index 0000000000..f24e4763c6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/positive_test/input/hot-nimbus-psm_v1.0.env @@ -0,0 +1,10 @@ +parameters: + pcrf_psm_server_names: ZRDM1PCRF01PSM001,ZRDM1PCRF01PSM002,ZRDM1PCRF01PSM003,ZRDM1PCRF01PSM004,ZRDM1PCRF01PSM005,ZRDM1PCRF01PSM006,ZRDM1PCRF01PSM007,ZRDM1PCRF01PSM008,ZRDM1PCRF01PSM009,ZRDM1PCRF01PSM010,ZRDM1PCRF01PSM011,ZRDM1PCRF01PSM012 + pcrf_psm_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_psm_flavor_name: lc.4xlarge4 + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.63,172.26.16.64,172.26.16.65,172.26.16.66,172.26.16.67,172.26.16.68,172.26.16.69,172.26.16.70,172.26.16.71,172.26.16.72,172.26.16.73,172.26.16.74 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/positive_test/input/hot-nimbus-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/positive_test/input/hot-nimbus-psm_v1.0.yaml new file mode 100644 index 0000000000..c2d7b05ead --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/positive_test/input/hot-nimbus-psm_v1.0.yaml @@ -0,0 +1,199 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_names: + type: comma_delimited_list + label: PCRF SM server names + description: name of the PCRF SM instance + pcrf_psm_image_name: + type: string + label: PCRF SM image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_psm_001: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 0] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_002: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 1] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_003: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 2] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_004: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 3] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_005: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 4] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_006: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 5] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_007: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 6] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 6] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_008: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 7] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 7] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_009: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 8] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 8] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_010: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 9] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 9] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_011: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 10] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 10] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_012: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 11] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 11] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/positive_test/input/nested-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/positive_test/input/nested-pps_v1.0.yaml new file mode 100644 index 0000000000..b7291d69d3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/positive_test/input/nested-pps_v1.0.yaml @@ -0,0 +1,97 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_name: + type: string + label: PCRF PS server name + description: PCRF PS server name + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + params: + $vm_name: { get_param: pcrf_pps_server_name } + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_pps: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_pps_server_name } + image: { get_param: pcrf_pps_image_name } + flavor: { get_param: pcrf_pps_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcrf_pps_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + + pcrf_pps_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/positive_test/input/nested-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/positive_test/input/nested-psm_v1.0.yaml new file mode 100644 index 0000000000..6868728b73 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/env_parameters_match_defined_types/positive_test/input/nested-psm_v1.0.yaml @@ -0,0 +1,97 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_name: + type: string + label: PCRF SM server name + description: PCRF SM server name + pcrf_psm_image_name: + type: string + label: image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + params: + $vm_name: { get_param: pcrf_psm_server_name } + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_psm: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_psm_server_name } + image: { get_param: pcrf_psm_image_name } + flavor: { get_param: pcrf_psm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: psm01_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + #scheduler_hints: {group: { get_resource: servergroup_nimbus }} + + psm01_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/negative_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/negative_test/input/MANIFEST.json new file mode 100644 index 0000000000..c27fba2205 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/negative_test/input/MANIFEST.json @@ -0,0 +1,21 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "nested-psm_v1.0.yaml", + "type": "HEAT" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/negative_test/input/hot-nimbus-psm_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/negative_test/input/hot-nimbus-psm_v1.0.env new file mode 100644 index 0000000000..f24e4763c6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/negative_test/input/hot-nimbus-psm_v1.0.env @@ -0,0 +1,10 @@ +parameters: + pcrf_psm_server_names: ZRDM1PCRF01PSM001,ZRDM1PCRF01PSM002,ZRDM1PCRF01PSM003,ZRDM1PCRF01PSM004,ZRDM1PCRF01PSM005,ZRDM1PCRF01PSM006,ZRDM1PCRF01PSM007,ZRDM1PCRF01PSM008,ZRDM1PCRF01PSM009,ZRDM1PCRF01PSM010,ZRDM1PCRF01PSM011,ZRDM1PCRF01PSM012 + pcrf_psm_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_psm_flavor_name: lc.4xlarge4 + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.63,172.26.16.64,172.26.16.65,172.26.16.66,172.26.16.67,172.26.16.68,172.26.16.69,172.26.16.70,172.26.16.71,172.26.16.72,172.26.16.73,172.26.16.74 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/negative_test/input/hot-nimbus-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/negative_test/input/hot-nimbus-psm_v1.0.yaml new file mode 100644 index 0000000000..4a66bf5bf6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/negative_test/input/hot-nimbus-psm_v1.0.yaml @@ -0,0 +1,72 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_names: + type: comma_delimited_list + label: PCRF SM server names + description: name of the PCRF SM instance + pcrf_psm_image_name: + type: string + label: PCRF SM image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_psm_001: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 0] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + + +outputs: + server_pcrf_psm_001_output: + description: the pcrf_server + value: { get_attr: [ server_pcrf_psm_001, nested_output ] } + + + server_pcrf_psm_002_output: + description: the pcrf_server + value: { get_attr: } + + server_pcrf_psm_003_output: + description: the pcrf_server + value: { get_attr: []} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/negative_test/input/nested-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/negative_test/input/nested-psm_v1.0.yaml new file mode 100644 index 0000000000..c26a0dd3a8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/negative_test/input/nested-psm_v1.0.yaml @@ -0,0 +1,103 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_name: + type: string + label: PCRF SM server name + description: PCRF SM server name + pcrf_psm_image_name: + type: string + label: image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + params: + $vm_name: { get_param: pcrf_psm_server_name } + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_psm: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_psm_server_name } + image: { get_param: pcrf_psm_image_name } + flavor: { get_param: pcrf_psm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: psm01_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + #scheduler_hints: {group: { get_resource: servergroup_nimbus }} + + psm01_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] + + +outputs: + not_in_resource: + description: the pcrf_swift_container_1 url + value: { get_param: pcrf_psm_server_name } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/positive_test/expected_output/expected_output.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/positive_test/expected_output/expected_output.json new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/positive_test/expected_output/expected_output.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/positive_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/positive_test/input/MANIFEST.json new file mode 100644 index 0000000000..fe7d8bdf5a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/positive_test/input/MANIFEST.json @@ -0,0 +1,51 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "hot-nimbus-psm_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "nested-pps_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "nested-psm_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "mount_iso_script.sh", + "type": "SHELL" + }, + { + "file": "cloud-nimbus.sh", + "type": "SHELL" + }, + { + "file": "nimbus-ethernet", + "type": "OTHER" + }, + { + "file": "nimbus-ethernet-gw", + "type": "OTHER" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/positive_test/input/hot-nimbus-pps_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/positive_test/input/hot-nimbus-pps_v1.0.env new file mode 100644 index 0000000000..340be2b815 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/positive_test/input/hot-nimbus-pps_v1.0.env @@ -0,0 +1,11 @@ +parameters: + pcrf_pps_server_names: ZRDM1PCRF01PPS001,ZRDM1PCRF01PPS002,ZRDM1PCRF01PPS003,ZRDM1PCRF01PPS004,ZRDM1PCRF01PPS005,ZRDM1PCRF01PPS006 + pcrf_pps_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pps_flavor_name: lc.3xlarge + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.7,172.26.16.8,172.26.16.9,172.26.16.10,172.26.16.11,172.26.16.12 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/positive_test/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/positive_test/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..05bd6c9318 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/positive_test/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,121 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_pps_001: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_002: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 1] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_003: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 2] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_004: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 3] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_005: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 4] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_006: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 5] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/positive_test/input/hot-nimbus-psm_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/positive_test/input/hot-nimbus-psm_v1.0.env new file mode 100644 index 0000000000..f24e4763c6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/positive_test/input/hot-nimbus-psm_v1.0.env @@ -0,0 +1,10 @@ +parameters: + pcrf_psm_server_names: ZRDM1PCRF01PSM001,ZRDM1PCRF01PSM002,ZRDM1PCRF01PSM003,ZRDM1PCRF01PSM004,ZRDM1PCRF01PSM005,ZRDM1PCRF01PSM006,ZRDM1PCRF01PSM007,ZRDM1PCRF01PSM008,ZRDM1PCRF01PSM009,ZRDM1PCRF01PSM010,ZRDM1PCRF01PSM011,ZRDM1PCRF01PSM012 + pcrf_psm_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_psm_flavor_name: lc.4xlarge4 + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.63,172.26.16.64,172.26.16.65,172.26.16.66,172.26.16.67,172.26.16.68,172.26.16.69,172.26.16.70,172.26.16.71,172.26.16.72,172.26.16.73,172.26.16.74 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/positive_test/input/hot-nimbus-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/positive_test/input/hot-nimbus-psm_v1.0.yaml new file mode 100644 index 0000000000..4ab762d34b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/positive_test/input/hot-nimbus-psm_v1.0.yaml @@ -0,0 +1,204 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_names: + type: comma_delimited_list + label: PCRF SM server names + description: name of the PCRF SM instance + pcrf_psm_image_name: + type: string + label: PCRF SM image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_psm_001: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 0] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_002: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 1] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_003: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 2] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_004: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 3] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_005: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 4] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_006: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 5] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_007: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 6] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 6] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_008: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 7] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 7] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_009: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 8] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 8] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_010: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 9] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 9] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_011: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 10] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 10] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_012: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 11] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 11] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + +outputs: + server_pcrf_psm_001_output: + description: the pcrf_server + value: { get_attr: [ server_pcrf_psm_001, nested_output ] } + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/positive_test/input/nested-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/positive_test/input/nested-pps_v1.0.yaml new file mode 100644 index 0000000000..b7291d69d3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/positive_test/input/nested-pps_v1.0.yaml @@ -0,0 +1,97 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_name: + type: string + label: PCRF PS server name + description: PCRF PS server name + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + params: + $vm_name: { get_param: pcrf_pps_server_name } + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_pps: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_pps_server_name } + image: { get_param: pcrf_pps_image_name } + flavor: { get_param: pcrf_pps_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcrf_pps_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + + pcrf_pps_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/positive_test/input/nested-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/positive_test/input/nested-psm_v1.0.yaml new file mode 100644 index 0000000000..4b7aac8f44 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_attr_from_nested/positive_test/input/nested-psm_v1.0.yaml @@ -0,0 +1,103 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_name: + type: string + label: PCRF SM server name + description: PCRF SM server name + pcrf_psm_image_name: + type: string + label: image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + params: + $vm_name: { get_param: pcrf_psm_server_name } + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_psm: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_psm_server_name } + image: { get_param: pcrf_psm_image_name } + flavor: { get_param: pcrf_psm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: psm01_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + #scheduler_hints: {group: { get_resource: servergroup_nimbus }} + + psm01_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] + + +outputs: + nested_output: + description: the pcrf_swift_container_1 url + value: { get_param: pcrf_psm_server_name } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/negative_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/negative_test/input/MANIFEST.json new file mode 100644 index 0000000000..c27fba2205 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/negative_test/input/MANIFEST.json @@ -0,0 +1,21 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "nested-psm_v1.0.yaml", + "type": "HEAT" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/negative_test/input/hot-nimbus-psm_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/negative_test/input/hot-nimbus-psm_v1.0.env new file mode 100644 index 0000000000..f24e4763c6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/negative_test/input/hot-nimbus-psm_v1.0.env @@ -0,0 +1,10 @@ +parameters: + pcrf_psm_server_names: ZRDM1PCRF01PSM001,ZRDM1PCRF01PSM002,ZRDM1PCRF01PSM003,ZRDM1PCRF01PSM004,ZRDM1PCRF01PSM005,ZRDM1PCRF01PSM006,ZRDM1PCRF01PSM007,ZRDM1PCRF01PSM008,ZRDM1PCRF01PSM009,ZRDM1PCRF01PSM010,ZRDM1PCRF01PSM011,ZRDM1PCRF01PSM012 + pcrf_psm_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_psm_flavor_name: lc.4xlarge4 + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.63,172.26.16.64,172.26.16.65,172.26.16.66,172.26.16.67,172.26.16.68,172.26.16.69,172.26.16.70,172.26.16.71,172.26.16.72,172.26.16.73,172.26.16.74 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/negative_test/input/hot-nimbus-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/negative_test/input/hot-nimbus-psm_v1.0.yaml new file mode 100644 index 0000000000..6eb260e380 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/negative_test/input/hot-nimbus-psm_v1.0.yaml @@ -0,0 +1,55 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_names: + type: comma_delimited_list + label: PCRF SM server names + description: name of the PCRF SM instance + pcrf_psm_image_name: + type: string + label: PCRF SM image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + + + server_pcrf_psm_001: + type: OS::Contrail::NetworkIpam + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 0] } + pcrf_cps_net_mask: { get_param: } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + property_pointing_to_not_existing_param: {get_param: not_existing_param_1} + + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/positive_test/expected_output/expected_output.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/positive_test/expected_output/expected_output.json new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/positive_test/expected_output/expected_output.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/positive_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/positive_test/input/MANIFEST.json new file mode 100644 index 0000000000..fe7d8bdf5a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/positive_test/input/MANIFEST.json @@ -0,0 +1,51 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "hot-nimbus-psm_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "nested-pps_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "nested-psm_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "mount_iso_script.sh", + "type": "SHELL" + }, + { + "file": "cloud-nimbus.sh", + "type": "SHELL" + }, + { + "file": "nimbus-ethernet", + "type": "OTHER" + }, + { + "file": "nimbus-ethernet-gw", + "type": "OTHER" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/positive_test/input/hot-nimbus-pps_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/positive_test/input/hot-nimbus-pps_v1.0.env new file mode 100644 index 0000000000..340be2b815 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/positive_test/input/hot-nimbus-pps_v1.0.env @@ -0,0 +1,11 @@ +parameters: + pcrf_pps_server_names: ZRDM1PCRF01PPS001,ZRDM1PCRF01PPS002,ZRDM1PCRF01PPS003,ZRDM1PCRF01PPS004,ZRDM1PCRF01PPS005,ZRDM1PCRF01PPS006 + pcrf_pps_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pps_flavor_name: lc.3xlarge + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.7,172.26.16.8,172.26.16.9,172.26.16.10,172.26.16.11,172.26.16.12 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/positive_test/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/positive_test/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..05bd6c9318 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/positive_test/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,121 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_pps_001: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_002: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 1] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_003: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 2] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_004: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 3] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_005: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 4] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_006: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 5] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/positive_test/input/hot-nimbus-psm_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/positive_test/input/hot-nimbus-psm_v1.0.env new file mode 100644 index 0000000000..f24e4763c6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/positive_test/input/hot-nimbus-psm_v1.0.env @@ -0,0 +1,10 @@ +parameters: + pcrf_psm_server_names: ZRDM1PCRF01PSM001,ZRDM1PCRF01PSM002,ZRDM1PCRF01PSM003,ZRDM1PCRF01PSM004,ZRDM1PCRF01PSM005,ZRDM1PCRF01PSM006,ZRDM1PCRF01PSM007,ZRDM1PCRF01PSM008,ZRDM1PCRF01PSM009,ZRDM1PCRF01PSM010,ZRDM1PCRF01PSM011,ZRDM1PCRF01PSM012 + pcrf_psm_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_psm_flavor_name: lc.4xlarge4 + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.63,172.26.16.64,172.26.16.65,172.26.16.66,172.26.16.67,172.26.16.68,172.26.16.69,172.26.16.70,172.26.16.71,172.26.16.72,172.26.16.73,172.26.16.74 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/positive_test/input/hot-nimbus-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/positive_test/input/hot-nimbus-psm_v1.0.yaml new file mode 100644 index 0000000000..c2d7b05ead --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/positive_test/input/hot-nimbus-psm_v1.0.yaml @@ -0,0 +1,199 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_names: + type: comma_delimited_list + label: PCRF SM server names + description: name of the PCRF SM instance + pcrf_psm_image_name: + type: string + label: PCRF SM image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_psm_001: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 0] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_002: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 1] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_003: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 2] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_004: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 3] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_005: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 4] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_006: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 5] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_007: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 6] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 6] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_008: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 7] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 7] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_009: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 8] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 8] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_010: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 9] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 9] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_011: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 10] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 10] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_012: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 11] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 11] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/positive_test/input/nested-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/positive_test/input/nested-pps_v1.0.yaml new file mode 100644 index 0000000000..b7291d69d3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/positive_test/input/nested-pps_v1.0.yaml @@ -0,0 +1,97 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_name: + type: string + label: PCRF PS server name + description: PCRF PS server name + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + params: + $vm_name: { get_param: pcrf_pps_server_name } + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_pps: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_pps_server_name } + image: { get_param: pcrf_pps_image_name } + flavor: { get_param: pcrf_pps_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcrf_pps_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + + pcrf_pps_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/positive_test/input/nested-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/positive_test/input/nested-psm_v1.0.yaml new file mode 100644 index 0000000000..6868728b73 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_param_points_to_existing_parameter/positive_test/input/nested-psm_v1.0.yaml @@ -0,0 +1,97 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_name: + type: string + label: PCRF SM server name + description: PCRF SM server name + pcrf_psm_image_name: + type: string + label: image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + params: + $vm_name: { get_param: pcrf_psm_server_name } + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_psm: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_psm_server_name } + image: { get_param: pcrf_psm_image_name } + flavor: { get_param: pcrf_psm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: psm01_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + #scheduler_hints: {group: { get_resource: servergroup_nimbus }} + + psm01_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_resource_value_valid/negative_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_resource_value_valid/negative_test/input/MANIFEST.json new file mode 100644 index 0000000000..a1ec6bc0f7 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_resource_value_valid/negative_test/input/MANIFEST.json @@ -0,0 +1,11 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_resource_value_valid/negative_test/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_resource_value_valid/negative_test/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..9a8e58ffe2 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/get_resource_value_valid/negative_test/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,31 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + param_1: + type: number + + param_2: + type: number + + +resources: + server_pcrf_pps_006: + type: OS::Contrail::NetworkIpam + properties: + pcrf_pps_server_name: { get_resource: [param_1, param_2] } + + + server_pcrf_pps_007: + type: OS::Contrail::NetworkIpam + properties: + pcrf_pps_server_name: { get_resource: {get_param: param_1} } + + + server_pcrf_pps_008: + type: OS::Contrail::NetworkIpam + properties: + pcrf_pps_server_name: { get_resource: } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/invalid_heat_format/negative_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/invalid_heat_format/negative_test/input/MANIFEST.json new file mode 100644 index 0000000000..5513de2ba2 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/invalid_heat_format/negative_test/input/MANIFEST.json @@ -0,0 +1,11 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.yaml", + "type": "HEAT" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/invalid_heat_format/negative_test/input/hot-nimbus-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/invalid_heat_format/negative_test/input/hot-nimbus-psm_v1.0.yaml new file mode 100644 index 0000000000..a5ee917b2c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/invalid_heat_format/negative_test/input/hot-nimbus-psm_v1.0.yaml @@ -0,0 +1,52 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + num_instances: + type: comma_delimited_list + label: PCRF SM server names + description: name of the PCRF SM instance + pcrf_psm_server_names: + type: comma_delimited_list + label: PCRF SM server names + description: name of the PCRF SM instance + pcrf_psm_image_name: + type: string + + pcrf_pps_image_name: + type: string + pcrf_pps_flavor_name: + type: string + availability_zone_0: + type: string +resources: + resource_with_resources_group_1: + kuku: kuku + type: OS::Heat::ResourceGroup + properties: + count: { get_param: num_instances } + resource_def: + type: {get_param: pcrf_vnf_id} + properties: + pcrf_psm_server_name: { get_param: pcrf_pps_server_names } + pcrf_psm_image_name: { get_param: pcrf_pps_image_name } + + + + + resource_with_resources_group_2: + blabla: blabla + type: OS::Heat::ResourceGroup + properties: + count: { get_param: num_instances } + resource_def: + type: OS::Nova::Server + properties: + cloud_zone_id: { get_param: pcrf_pps_server_names } + vf_name: { get_param: pcrf_pps_image_name } + + + + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/network_policy_associated_with_attach_policy/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/network_policy_associated_with_attach_policy/input/MANIFEST.json new file mode 100644 index 0000000000..1e719efb31 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/network_policy_associated_with_attach_policy/input/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.env", + "type": "HEAT_ENV" + } + ] + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/network_policy_associated_with_attach_policy/input/hot-nimbus-pps_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/network_policy_associated_with_attach_policy/input/hot-nimbus-pps_v1.0.env new file mode 100644 index 0000000000..340be2b815 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/network_policy_associated_with_attach_policy/input/hot-nimbus-pps_v1.0.env @@ -0,0 +1,11 @@ +parameters: + pcrf_pps_server_names: ZRDM1PCRF01PPS001,ZRDM1PCRF01PPS002,ZRDM1PCRF01PPS003,ZRDM1PCRF01PPS004,ZRDM1PCRF01PPS005,ZRDM1PCRF01PPS006 + pcrf_pps_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pps_flavor_name: lc.3xlarge + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.7,172.26.16.8,172.26.16.9,172.26.16.10,172.26.16.11,172.26.16.12 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/network_policy_associated_with_attach_policy/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/network_policy_associated_with_attach_policy/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..b2b91ec36d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/network_policy_associated_with_attach_policy/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,69 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + used_server_pcrf_policy: + type: OS::Contrail::NetworkPolicy + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + + not_used_server_pcrf_policy: + type: OS::Contrail::NetworkPolicy + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + + server_pcrf_network: + type: OS::Contrail::VirtualNetwork + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + + attach_policy_resource: + type: OS::Contrail::AttachPolicy + properties: + network: { get_resource: server_pcrf_network } + policy: { get_attr: [used_server_pcrf_policy, fq_name] } + + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/negative_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/negative_test/input/MANIFEST.json new file mode 100644 index 0000000000..e789fd7b1d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/negative_test/input/MANIFEST.json @@ -0,0 +1,45 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "nested-psm_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "nested-points-to-hot-nimbus-psm.yaml", + "type": "HEAT" + }, + { + "file": "yaml-point-to-itself.yaml", + "type": "HEAT" + }, + { + "file": "mount_iso_script.sh", + "type": "SHELL" + }, + { + "file": "cloud-nimbus.sh", + "type": "SHELL" + }, + { + "file": "nimbus-ethernet", + "type": "OTHER" + }, + { + "file": "nimbus-ethernet-gw", + "type": "OTHER" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/negative_test/input/hot-nimbus-psm_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/negative_test/input/hot-nimbus-psm_v1.0.env new file mode 100644 index 0000000000..f24e4763c6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/negative_test/input/hot-nimbus-psm_v1.0.env @@ -0,0 +1,10 @@ +parameters: + pcrf_psm_server_names: ZRDM1PCRF01PSM001,ZRDM1PCRF01PSM002,ZRDM1PCRF01PSM003,ZRDM1PCRF01PSM004,ZRDM1PCRF01PSM005,ZRDM1PCRF01PSM006,ZRDM1PCRF01PSM007,ZRDM1PCRF01PSM008,ZRDM1PCRF01PSM009,ZRDM1PCRF01PSM010,ZRDM1PCRF01PSM011,ZRDM1PCRF01PSM012 + pcrf_psm_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_psm_flavor_name: lc.4xlarge4 + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.63,172.26.16.64,172.26.16.65,172.26.16.66,172.26.16.67,172.26.16.68,172.26.16.69,172.26.16.70,172.26.16.71,172.26.16.72,172.26.16.73,172.26.16.74 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/negative_test/input/hot-nimbus-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/negative_test/input/hot-nimbus-psm_v1.0.yaml new file mode 100644 index 0000000000..49e03e0a16 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/negative_test/input/hot-nimbus-psm_v1.0.yaml @@ -0,0 +1,56 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_names: + type: comma_delimited_list + label: PCRF SM server names + description: name of the PCRF SM instance + pcrf_psm_image_name: + type: string + label: PCRF SM image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_psm_001: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 0] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + + server_pcrf_psm_002: + type: + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 0] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/negative_test/input/nested-points-to-hot-nimbus-psm.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/negative_test/input/nested-points-to-hot-nimbus-psm.yaml new file mode 100644 index 0000000000..981c08c011 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/negative_test/input/nested-points-to-hot-nimbus-psm.yaml @@ -0,0 +1,60 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_name: + type: string + label: PCRF SM server name + description: PCRF SM server name + pcrf_psm_image_name: + type: string + label: image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + network: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_psm_001: + type: hot-nimbus-psm_v1.0.yaml + properties: + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + + server_pcrf_psm_002: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/negative_test/input/nested-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/negative_test/input/nested-psm_v1.0.yaml new file mode 100644 index 0000000000..bfc412d715 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/negative_test/input/nested-psm_v1.0.yaml @@ -0,0 +1,47 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_name: + type: string + label: PCRF SM server name + description: PCRF SM server name + pcrf_psm_image_name: + type: string + label: image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + psm01_port_0: + type: nested-points-to-hot-nimbus-psm.yaml + properties: + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/negative_test/input/yaml-point-to-itself.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/negative_test/input/yaml-point-to-itself.yaml new file mode 100644 index 0000000000..ec2a02a5d2 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/negative_test/input/yaml-point-to-itself.yaml @@ -0,0 +1,21 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_name: + type: string + label: PCRF SM server name + description: PCRF SM server name + pcrf_psm_image_name: + type: string + label: image name + description: PCRF SM image name + +resources: + + resource_points_to_itself: + type: yaml-point-to-itself.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_name, 0] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/positive_test/expected_output/expected_output.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/positive_test/expected_output/expected_output.json new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/positive_test/expected_output/expected_output.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/positive_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/positive_test/input/MANIFEST.json new file mode 100644 index 0000000000..fe7d8bdf5a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/positive_test/input/MANIFEST.json @@ -0,0 +1,51 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "hot-nimbus-psm_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "nested-pps_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "nested-psm_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "mount_iso_script.sh", + "type": "SHELL" + }, + { + "file": "cloud-nimbus.sh", + "type": "SHELL" + }, + { + "file": "nimbus-ethernet", + "type": "OTHER" + }, + { + "file": "nimbus-ethernet-gw", + "type": "OTHER" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/positive_test/input/hot-nimbus-pps_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/positive_test/input/hot-nimbus-pps_v1.0.env new file mode 100644 index 0000000000..340be2b815 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/positive_test/input/hot-nimbus-pps_v1.0.env @@ -0,0 +1,11 @@ +parameters: + pcrf_pps_server_names: ZRDM1PCRF01PPS001,ZRDM1PCRF01PPS002,ZRDM1PCRF01PPS003,ZRDM1PCRF01PPS004,ZRDM1PCRF01PPS005,ZRDM1PCRF01PPS006 + pcrf_pps_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pps_flavor_name: lc.3xlarge + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.7,172.26.16.8,172.26.16.9,172.26.16.10,172.26.16.11,172.26.16.12 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/positive_test/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/positive_test/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..05bd6c9318 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/positive_test/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,121 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_pps_001: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_002: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 1] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_003: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 2] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_004: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 3] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_005: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 4] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_006: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 5] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/positive_test/input/hot-nimbus-psm_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/positive_test/input/hot-nimbus-psm_v1.0.env new file mode 100644 index 0000000000..f24e4763c6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/positive_test/input/hot-nimbus-psm_v1.0.env @@ -0,0 +1,10 @@ +parameters: + pcrf_psm_server_names: ZRDM1PCRF01PSM001,ZRDM1PCRF01PSM002,ZRDM1PCRF01PSM003,ZRDM1PCRF01PSM004,ZRDM1PCRF01PSM005,ZRDM1PCRF01PSM006,ZRDM1PCRF01PSM007,ZRDM1PCRF01PSM008,ZRDM1PCRF01PSM009,ZRDM1PCRF01PSM010,ZRDM1PCRF01PSM011,ZRDM1PCRF01PSM012 + pcrf_psm_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_psm_flavor_name: lc.4xlarge4 + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.63,172.26.16.64,172.26.16.65,172.26.16.66,172.26.16.67,172.26.16.68,172.26.16.69,172.26.16.70,172.26.16.71,172.26.16.72,172.26.16.73,172.26.16.74 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/positive_test/input/hot-nimbus-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/positive_test/input/hot-nimbus-psm_v1.0.yaml new file mode 100644 index 0000000000..c2d7b05ead --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/positive_test/input/hot-nimbus-psm_v1.0.yaml @@ -0,0 +1,199 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_names: + type: comma_delimited_list + label: PCRF SM server names + description: name of the PCRF SM instance + pcrf_psm_image_name: + type: string + label: PCRF SM image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_psm_001: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 0] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_002: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 1] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_003: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 2] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_004: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 3] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_005: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 4] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_006: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 5] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_007: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 6] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 6] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_008: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 7] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 7] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_009: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 8] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 8] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_010: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 9] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 9] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_011: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 10] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 10] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_012: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 11] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 11] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/positive_test/input/nested-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/positive_test/input/nested-pps_v1.0.yaml new file mode 100644 index 0000000000..b7291d69d3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/positive_test/input/nested-pps_v1.0.yaml @@ -0,0 +1,97 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_name: + type: string + label: PCRF PS server name + description: PCRF PS server name + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + params: + $vm_name: { get_param: pcrf_pps_server_name } + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_pps: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_pps_server_name } + image: { get_param: pcrf_pps_image_name } + flavor: { get_param: pcrf_pps_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcrf_pps_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + + pcrf_pps_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/positive_test/input/nested-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/positive_test/input/nested-psm_v1.0.yaml new file mode 100644 index 0000000000..6868728b73 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/no_loops_nesting/positive_test/input/nested-psm_v1.0.yaml @@ -0,0 +1,97 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_name: + type: string + label: PCRF SM server name + description: PCRF SM server name + pcrf_psm_image_name: + type: string + label: image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + params: + $vm_name: { get_param: pcrf_psm_server_name } + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_psm: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_psm_server_name } + image: { get_param: pcrf_psm_image_name } + flavor: { get_param: pcrf_psm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: psm01_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + #scheduler_hints: {group: { get_resource: servergroup_nimbus }} + + psm01_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/negative_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/negative_test/input/MANIFEST.json new file mode 100644 index 0000000000..dd26e5ac45 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/negative_test/input/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.env", + "type": "HEAT_ENV" + } + ] + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/negative_test/input/hot-nimbus-psm_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/negative_test/input/hot-nimbus-psm_v1.0.env new file mode 100644 index 0000000000..f24e4763c6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/negative_test/input/hot-nimbus-psm_v1.0.env @@ -0,0 +1,10 @@ +parameters: + pcrf_psm_server_names: ZRDM1PCRF01PSM001,ZRDM1PCRF01PSM002,ZRDM1PCRF01PSM003,ZRDM1PCRF01PSM004,ZRDM1PCRF01PSM005,ZRDM1PCRF01PSM006,ZRDM1PCRF01PSM007,ZRDM1PCRF01PSM008,ZRDM1PCRF01PSM009,ZRDM1PCRF01PSM010,ZRDM1PCRF01PSM011,ZRDM1PCRF01PSM012 + pcrf_psm_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_psm_flavor_name: lc.4xlarge4 + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.63,172.26.16.64,172.26.16.65,172.26.16.66,172.26.16.67,172.26.16.68,172.26.16.69,172.26.16.70,172.26.16.71,172.26.16.72,172.26.16.73,172.26.16.74 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/negative_test/input/hot-nimbus-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/negative_test/input/hot-nimbus-psm_v1.0.yaml new file mode 100644 index 0000000000..8ef73ded21 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/negative_test/input/hot-nimbus-psm_v1.0.yaml @@ -0,0 +1,92 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_names: + type: comma_delimited_list + label: PCRF SM server names + description: name of the PCRF SM instance + pcrf_psm_image_name: + type: string + label: PCRF SM image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + nova_server_resource_missing_both: + type: OS::Nova::Server + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 11] } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 11] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + nova_server_resource_only_image: + type: OS::Nova::Server + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 11] } + image: { get_param: pcrf_psm_image_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 11] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + nova_server_resource_only_flavor: + type: OS::Nova::Server + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 11] } + flavor: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 11] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + + nova_server_resource_both_without_get_param: + type: OS::Nova::Server + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 11] } + flavor: { get_param: } + image: { get_param: } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 11] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/positive_test/expected_output/expected_output.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/positive_test/expected_output/expected_output.json new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/positive_test/expected_output/expected_output.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/positive_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/positive_test/input/MANIFEST.json new file mode 100644 index 0000000000..fe7d8bdf5a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/positive_test/input/MANIFEST.json @@ -0,0 +1,51 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "hot-nimbus-psm_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "nested-pps_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "nested-psm_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "mount_iso_script.sh", + "type": "SHELL" + }, + { + "file": "cloud-nimbus.sh", + "type": "SHELL" + }, + { + "file": "nimbus-ethernet", + "type": "OTHER" + }, + { + "file": "nimbus-ethernet-gw", + "type": "OTHER" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/positive_test/input/hot-nimbus-pps_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/positive_test/input/hot-nimbus-pps_v1.0.env new file mode 100644 index 0000000000..340be2b815 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/positive_test/input/hot-nimbus-pps_v1.0.env @@ -0,0 +1,11 @@ +parameters: + pcrf_pps_server_names: ZRDM1PCRF01PPS001,ZRDM1PCRF01PPS002,ZRDM1PCRF01PPS003,ZRDM1PCRF01PPS004,ZRDM1PCRF01PPS005,ZRDM1PCRF01PPS006 + pcrf_pps_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pps_flavor_name: lc.3xlarge + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.7,172.26.16.8,172.26.16.9,172.26.16.10,172.26.16.11,172.26.16.12 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/positive_test/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/positive_test/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..05bd6c9318 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/positive_test/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,121 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_pps_001: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_002: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 1] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_003: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 2] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_004: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 3] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_005: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 4] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_006: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 5] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/positive_test/input/hot-nimbus-psm_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/positive_test/input/hot-nimbus-psm_v1.0.env new file mode 100644 index 0000000000..f24e4763c6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/positive_test/input/hot-nimbus-psm_v1.0.env @@ -0,0 +1,10 @@ +parameters: + pcrf_psm_server_names: ZRDM1PCRF01PSM001,ZRDM1PCRF01PSM002,ZRDM1PCRF01PSM003,ZRDM1PCRF01PSM004,ZRDM1PCRF01PSM005,ZRDM1PCRF01PSM006,ZRDM1PCRF01PSM007,ZRDM1PCRF01PSM008,ZRDM1PCRF01PSM009,ZRDM1PCRF01PSM010,ZRDM1PCRF01PSM011,ZRDM1PCRF01PSM012 + pcrf_psm_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_psm_flavor_name: lc.4xlarge4 + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.63,172.26.16.64,172.26.16.65,172.26.16.66,172.26.16.67,172.26.16.68,172.26.16.69,172.26.16.70,172.26.16.71,172.26.16.72,172.26.16.73,172.26.16.74 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/positive_test/input/hot-nimbus-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/positive_test/input/hot-nimbus-psm_v1.0.yaml new file mode 100644 index 0000000000..25a4545311 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/positive_test/input/hot-nimbus-psm_v1.0.yaml @@ -0,0 +1,236 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_names: + type: comma_delimited_list + label: PCRF SM server names + description: name of the PCRF SM instance + pcrf_psm_image_name: + type: string + label: PCRF SM image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_psm_001: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 0] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_002: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 1] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_003: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 2] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_004: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 3] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_005: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 4] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_006: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 5] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_007: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 6] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 6] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_008: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 7] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 7] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_009: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 8] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 8] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_010: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 9] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 9] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_011: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 10] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 10] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_012: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 11] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 11] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + nova_server_resource: + type: OS::Nova::Server + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 11] } + image: { get_param: pcrf_psm_image_name } + flavor: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 11] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + nova_server_resource_only_image: + type: OS::Nova::Server + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 11] } + image: { get_param: pcrf_psm_image_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 11] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + nova_server_resource_only_flavor: + type: OS::Nova::Server + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 11] } + flavor: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 11] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/positive_test/input/nested-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/positive_test/input/nested-pps_v1.0.yaml new file mode 100644 index 0000000000..b7291d69d3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/positive_test/input/nested-pps_v1.0.yaml @@ -0,0 +1,97 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_name: + type: string + label: PCRF PS server name + description: PCRF PS server name + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + params: + $vm_name: { get_param: pcrf_pps_server_name } + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_pps: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_pps_server_name } + image: { get_param: pcrf_pps_image_name } + flavor: { get_param: pcrf_pps_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcrf_pps_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + + pcrf_pps_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/positive_test/input/nested-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/positive_test/input/nested-psm_v1.0.yaml new file mode 100644 index 0000000000..6868728b73 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/nova_properties_has_assigned_value/positive_test/input/nested-psm_v1.0.yaml @@ -0,0 +1,97 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_name: + type: string + label: PCRF SM server name + description: PCRF SM server name + pcrf_psm_image_name: + type: string + label: image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + params: + $vm_name: { get_param: pcrf_psm_server_name } + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_psm: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_psm_server_name } + image: { get_param: pcrf_psm_image_name } + flavor: { get_param: pcrf_psm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: psm01_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + #scheduler_hints: {group: { get_resource: servergroup_nimbus }} + + psm01_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/negative_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/negative_test/input/MANIFEST.json new file mode 100644 index 0000000000..dd26e5ac45 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/negative_test/input/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.env", + "type": "HEAT_ENV" + } + ] + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/negative_test/input/hot-nimbus-psm_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/negative_test/input/hot-nimbus-psm_v1.0.env new file mode 100644 index 0000000000..f24e4763c6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/negative_test/input/hot-nimbus-psm_v1.0.env @@ -0,0 +1,10 @@ +parameters: + pcrf_psm_server_names: ZRDM1PCRF01PSM001,ZRDM1PCRF01PSM002,ZRDM1PCRF01PSM003,ZRDM1PCRF01PSM004,ZRDM1PCRF01PSM005,ZRDM1PCRF01PSM006,ZRDM1PCRF01PSM007,ZRDM1PCRF01PSM008,ZRDM1PCRF01PSM009,ZRDM1PCRF01PSM010,ZRDM1PCRF01PSM011,ZRDM1PCRF01PSM012 + pcrf_psm_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_psm_flavor_name: lc.4xlarge4 + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.63,172.26.16.64,172.26.16.65,172.26.16.66,172.26.16.67,172.26.16.68,172.26.16.69,172.26.16.70,172.26.16.71,172.26.16.72,172.26.16.73,172.26.16.74 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/negative_test/input/hot-nimbus-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/negative_test/input/hot-nimbus-psm_v1.0.yaml new file mode 100644 index 0000000000..f7678ed6b7 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/negative_test/input/hot-nimbus-psm_v1.0.yaml @@ -0,0 +1,95 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_names: + type: comma_delimited_list + label: PCRF SM server names + description: name of the PCRF SM instance + pcrf_psm_image_name: + type: string + label: PCRF SM image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + vnf_id: + type: string + +resources: + nova_server_2: + type: OS::Nova::Server + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 0] } + image: { get_param: pcrf_psm_image_name } + flavor: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + networks: + - port: { get_resource: oam1_int_port } + fixed_ip: 10.0.0.0 + floating_ip: 10.0.0.1 + network: 100_1000_0011 + port_extra_properties: {admin_state_up: true , allowed_address_pairs: 10} + subnet: 10.0.0.2 + - port: { get_resource: oam1_mgmt_port } + metadata: + vnf_id: { get_param: vnf_id } + + nova_server_3: + type: OS::Nova::Server + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 0] } + image: { get_param: pcrf_psm_image_name } + flavor: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + networks: + - port: { get_resource: oam1_int_port } + fixed_ip: 10.0.0.0 + floating_ip: 10.0.0.1 + network: 100_1000_0011 + port_extra_properties: {admin_state_up: true , allowed_address_pairs: 10} + subnet: 10.0.0.2 + metadata: + vnf_id: { get_param: vnf_id } + + oam1_int_port: + type: OS::Neutron::Port + properties: + network: {get_param: pcrf_psm_server_names} + fixed_ips: [{"ip_address": {get_param: [pcrf_psm_image_name, 0]}}] + security_groups: [{get_param: pcrf_psm_image_name}] + replacement_policy: AUTO + + oam1_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: pcrf_psm_server_names} + fixed_ips: [{"ip_address": {get_param: [pcrf_psm_image_name, 0]}}] + security_groups: [{get_param: pcrf_psm_image_name}] + replacement_policy: AUTO \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/positive_test/expected_output/expected_output.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/positive_test/expected_output/expected_output.json new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/positive_test/expected_output/expected_output.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/positive_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/positive_test/input/MANIFEST.json new file mode 100644 index 0000000000..fe7d8bdf5a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/positive_test/input/MANIFEST.json @@ -0,0 +1,51 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "hot-nimbus-psm_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "nested-pps_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "nested-psm_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "mount_iso_script.sh", + "type": "SHELL" + }, + { + "file": "cloud-nimbus.sh", + "type": "SHELL" + }, + { + "file": "nimbus-ethernet", + "type": "OTHER" + }, + { + "file": "nimbus-ethernet-gw", + "type": "OTHER" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/positive_test/input/hot-nimbus-pps_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/positive_test/input/hot-nimbus-pps_v1.0.env new file mode 100644 index 0000000000..340be2b815 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/positive_test/input/hot-nimbus-pps_v1.0.env @@ -0,0 +1,11 @@ +parameters: + pcrf_pps_server_names: ZRDM1PCRF01PPS001,ZRDM1PCRF01PPS002,ZRDM1PCRF01PPS003,ZRDM1PCRF01PPS004,ZRDM1PCRF01PPS005,ZRDM1PCRF01PPS006 + pcrf_pps_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pps_flavor_name: lc.3xlarge + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.7,172.26.16.8,172.26.16.9,172.26.16.10,172.26.16.11,172.26.16.12 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/positive_test/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/positive_test/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..05bd6c9318 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/positive_test/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,121 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_pps_001: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_002: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 1] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_003: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 2] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_004: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 3] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_005: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 4] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_006: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 5] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/positive_test/input/hot-nimbus-psm_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/positive_test/input/hot-nimbus-psm_v1.0.env new file mode 100644 index 0000000000..f24e4763c6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/positive_test/input/hot-nimbus-psm_v1.0.env @@ -0,0 +1,10 @@ +parameters: + pcrf_psm_server_names: ZRDM1PCRF01PSM001,ZRDM1PCRF01PSM002,ZRDM1PCRF01PSM003,ZRDM1PCRF01PSM004,ZRDM1PCRF01PSM005,ZRDM1PCRF01PSM006,ZRDM1PCRF01PSM007,ZRDM1PCRF01PSM008,ZRDM1PCRF01PSM009,ZRDM1PCRF01PSM010,ZRDM1PCRF01PSM011,ZRDM1PCRF01PSM012 + pcrf_psm_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_psm_flavor_name: lc.4xlarge4 + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.63,172.26.16.64,172.26.16.65,172.26.16.66,172.26.16.67,172.26.16.68,172.26.16.69,172.26.16.70,172.26.16.71,172.26.16.72,172.26.16.73,172.26.16.74 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/positive_test/input/hot-nimbus-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/positive_test/input/hot-nimbus-psm_v1.0.yaml new file mode 100644 index 0000000000..c173fce968 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/positive_test/input/hot-nimbus-psm_v1.0.yaml @@ -0,0 +1,233 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_names: + type: comma_delimited_list + label: PCRF SM server names + description: name of the PCRF SM instance + pcrf_psm_image_name: + type: string + label: PCRF SM image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + nova_server_1: + type: OS::Nova::Server + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 0] } + image: { get_param: pcrf_psm_image_name } + flavor: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + networks: + - port: { get_resource: oam1_int_port } + fixed_ip: 10.0.0.0 + floating_ip: 10.0.0.1 + network: 100_1000_0011 + port_extra_properties: {admin_state_up: true , allowed_address_pairs: 10} + subnet: 10.0.0.2 + - port: { get_resource: oam1_mgmt_port } + metadata: + vnf_id: { get_param: vnf_id } + + oam1_int_port: + type: OS::Neutron::Port + properties: + network: {get_param: pcrf_psm_server_names} + fixed_ips: [{"ip_address": {get_param: [pcrf_psm_image_name, 0]}}] + security_groups: [{get_param: pcrf_psm_image_name}] + replacement_policy: AUTO + + oam1_mgmt_port: + type: OS::Neutron::Port + properties: + network: {get_param: pcrf_psm_server_names} + fixed_ips: [{"ip_address": {get_param: [pcrf_psm_image_name, 0]}}] + security_groups: [{get_param: pcrf_psm_image_name}] + replacement_policy: AUTO + + server_pcrf_psm_001: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 0] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_002: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 1] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_003: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 2] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_004: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 3] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_005: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 4] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_006: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 5] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_007: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 6] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 6] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_008: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 7] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 7] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_009: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 8] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 8] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_010: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 9] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 9] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_011: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 10] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 10] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_012: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 11] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 11] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/positive_test/input/nested-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/positive_test/input/nested-pps_v1.0.yaml new file mode 100644 index 0000000000..b7291d69d3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/positive_test/input/nested-pps_v1.0.yaml @@ -0,0 +1,97 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_name: + type: string + label: PCRF PS server name + description: PCRF PS server name + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + params: + $vm_name: { get_param: pcrf_pps_server_name } + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_pps: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_pps_server_name } + image: { get_param: pcrf_pps_image_name } + flavor: { get_param: pcrf_pps_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcrf_pps_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + + pcrf_pps_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/positive_test/input/nested-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/positive_test/input/nested-psm_v1.0.yaml new file mode 100644 index 0000000000..6868728b73 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/one_nova_points_to_one_port/positive_test/input/nested-psm_v1.0.yaml @@ -0,0 +1,97 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_name: + type: string + label: PCRF SM server name + description: PCRF SM server name + pcrf_psm_image_name: + type: string + label: image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + params: + $vm_name: { get_param: pcrf_psm_server_name } + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_psm: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_psm_server_name } + image: { get_param: pcrf_psm_image_name } + flavor: { get_param: pcrf_psm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: psm01_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + #scheduler_hints: {group: { get_resource: servergroup_nimbus }} + + psm01_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/negative_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/negative_test/input/MANIFEST.json new file mode 100644 index 0000000000..fe7d8bdf5a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/negative_test/input/MANIFEST.json @@ -0,0 +1,51 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "hot-nimbus-psm_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "nested-pps_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "nested-psm_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "mount_iso_script.sh", + "type": "SHELL" + }, + { + "file": "cloud-nimbus.sh", + "type": "SHELL" + }, + { + "file": "nimbus-ethernet", + "type": "OTHER" + }, + { + "file": "nimbus-ethernet-gw", + "type": "OTHER" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/negative_test/input/hot-nimbus-pps_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/negative_test/input/hot-nimbus-pps_v1.0.env new file mode 100644 index 0000000000..340be2b815 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/negative_test/input/hot-nimbus-pps_v1.0.env @@ -0,0 +1,11 @@ +parameters: + pcrf_pps_server_names: ZRDM1PCRF01PPS001,ZRDM1PCRF01PPS002,ZRDM1PCRF01PPS003,ZRDM1PCRF01PPS004,ZRDM1PCRF01PPS005,ZRDM1PCRF01PPS006 + pcrf_pps_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pps_flavor_name: lc.3xlarge + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.7,172.26.16.8,172.26.16.9,172.26.16.10,172.26.16.11,172.26.16.12 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/negative_test/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/negative_test/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..05bd6c9318 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/negative_test/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,121 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_pps_001: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_002: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 1] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_003: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 2] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_004: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 3] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_005: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 4] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_006: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 5] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/negative_test/input/hot-nimbus-psm_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/negative_test/input/hot-nimbus-psm_v1.0.env new file mode 100644 index 0000000000..f24e4763c6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/negative_test/input/hot-nimbus-psm_v1.0.env @@ -0,0 +1,10 @@ +parameters: + pcrf_psm_server_names: ZRDM1PCRF01PSM001,ZRDM1PCRF01PSM002,ZRDM1PCRF01PSM003,ZRDM1PCRF01PSM004,ZRDM1PCRF01PSM005,ZRDM1PCRF01PSM006,ZRDM1PCRF01PSM007,ZRDM1PCRF01PSM008,ZRDM1PCRF01PSM009,ZRDM1PCRF01PSM010,ZRDM1PCRF01PSM011,ZRDM1PCRF01PSM012 + pcrf_psm_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_psm_flavor_name: lc.4xlarge4 + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.63,172.26.16.64,172.26.16.65,172.26.16.66,172.26.16.67,172.26.16.68,172.26.16.69,172.26.16.70,172.26.16.71,172.26.16.72,172.26.16.73,172.26.16.74 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/negative_test/input/hot-nimbus-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/negative_test/input/hot-nimbus-psm_v1.0.yaml new file mode 100644 index 0000000000..c2d7b05ead --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/negative_test/input/hot-nimbus-psm_v1.0.yaml @@ -0,0 +1,199 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_names: + type: comma_delimited_list + label: PCRF SM server names + description: name of the PCRF SM instance + pcrf_psm_image_name: + type: string + label: PCRF SM image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_psm_001: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 0] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_002: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 1] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_003: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 2] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_004: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 3] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_005: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 4] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_006: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 5] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_007: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 6] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 6] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_008: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 7] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 7] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_009: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 8] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 8] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_010: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 9] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 9] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_011: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 10] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 10] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_012: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 11] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 11] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/negative_test/input/nested-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/negative_test/input/nested-pps_v1.0.yaml new file mode 100644 index 0000000000..b7291d69d3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/negative_test/input/nested-pps_v1.0.yaml @@ -0,0 +1,97 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_name: + type: string + label: PCRF PS server name + description: PCRF PS server name + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + params: + $vm_name: { get_param: pcrf_pps_server_name } + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_pps: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_pps_server_name } + image: { get_param: pcrf_pps_image_name } + flavor: { get_param: pcrf_pps_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcrf_pps_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + + pcrf_pps_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/negative_test/input/nested-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/negative_test/input/nested-psm_v1.0.yaml new file mode 100644 index 0000000000..6868728b73 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/negative_test/input/nested-psm_v1.0.yaml @@ -0,0 +1,97 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_name: + type: string + label: PCRF SM server name + description: PCRF SM server name + pcrf_psm_image_name: + type: string + label: image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + params: + $vm_name: { get_param: pcrf_psm_server_name } + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_psm: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_psm_server_name } + image: { get_param: pcrf_psm_image_name } + flavor: { get_param: pcrf_psm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: psm01_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + #scheduler_hints: {group: { get_resource: servergroup_nimbus }} + + psm01_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/positive_test/expected_output/expected_output.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/positive_test/expected_output/expected_output.json new file mode 100644 index 0000000000..ce04d8c601 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/positive_test/expected_output/expected_output.json @@ -0,0 +1,42 @@ +{ + "name": "multiple_not_nested", + "description": "multiple heat files in zip, no nesting", + "version": "2013-05-23", + "data": [{ + "file": "cmaui.yml", + "type": "HEAT", + "data": [{ + "file": "cmaui.env", + "type": "HEAT_ENV" + }] + }, + { + "file": "eca_oam.yaml", + "type": "HEAT", + "data": [{ + "file": "eca_oam.env", + "type": "HEAT_ENV" + }] + }, + { + "file": "eca_oam_nested.yaml", + "type": "HEAT" + }, + { + "file": "MMSC_Capacity_Line.yml", + "type": "HEAT", + "data": [{ + "file": "MMSC_Capacity_Line_1.env", + "type": "HEAT_ENV" + }] + }, + { + "file": "SG_ECA_MGMT.yaml", + "type": "HEAT", + "data": [{ + "file": "sg_eca_mgmt.env", + "type": "HEAT_ENV" + }] + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/positive_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/positive_test/input/MANIFEST.json new file mode 100644 index 0000000000..fe7d8bdf5a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/positive_test/input/MANIFEST.json @@ -0,0 +1,51 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "hot-nimbus-psm_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "nested-pps_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "nested-psm_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "mount_iso_script.sh", + "type": "SHELL" + }, + { + "file": "cloud-nimbus.sh", + "type": "SHELL" + }, + { + "file": "nimbus-ethernet", + "type": "OTHER" + }, + { + "file": "nimbus-ethernet-gw", + "type": "OTHER" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/positive_test/input/hot-nimbus-pps_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/positive_test/input/hot-nimbus-pps_v1.0.env new file mode 100644 index 0000000000..340be2b815 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/positive_test/input/hot-nimbus-pps_v1.0.env @@ -0,0 +1,11 @@ +parameters: + pcrf_pps_server_names: ZRDM1PCRF01PPS001,ZRDM1PCRF01PPS002,ZRDM1PCRF01PPS003,ZRDM1PCRF01PPS004,ZRDM1PCRF01PPS005,ZRDM1PCRF01PPS006 + pcrf_pps_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pps_flavor_name: lc.3xlarge + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.7,172.26.16.8,172.26.16.9,172.26.16.10,172.26.16.11,172.26.16.12 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/positive_test/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/positive_test/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..05bd6c9318 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/positive_test/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,121 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_pps_001: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_002: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 1] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_003: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 2] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_004: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 3] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_005: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 4] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_006: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 5] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/positive_test/input/hot-nimbus-psm_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/positive_test/input/hot-nimbus-psm_v1.0.env new file mode 100644 index 0000000000..f24e4763c6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/positive_test/input/hot-nimbus-psm_v1.0.env @@ -0,0 +1,10 @@ +parameters: + pcrf_psm_server_names: ZRDM1PCRF01PSM001,ZRDM1PCRF01PSM002,ZRDM1PCRF01PSM003,ZRDM1PCRF01PSM004,ZRDM1PCRF01PSM005,ZRDM1PCRF01PSM006,ZRDM1PCRF01PSM007,ZRDM1PCRF01PSM008,ZRDM1PCRF01PSM009,ZRDM1PCRF01PSM010,ZRDM1PCRF01PSM011,ZRDM1PCRF01PSM012 + pcrf_psm_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_psm_flavor_name: lc.4xlarge4 + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.63,172.26.16.64,172.26.16.65,172.26.16.66,172.26.16.67,172.26.16.68,172.26.16.69,172.26.16.70,172.26.16.71,172.26.16.72,172.26.16.73,172.26.16.74 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/positive_test/input/hot-nimbus-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/positive_test/input/hot-nimbus-psm_v1.0.yaml new file mode 100644 index 0000000000..c2d7b05ead --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/positive_test/input/hot-nimbus-psm_v1.0.yaml @@ -0,0 +1,199 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_names: + type: comma_delimited_list + label: PCRF SM server names + description: name of the PCRF SM instance + pcrf_psm_image_name: + type: string + label: PCRF SM image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_psm_001: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 0] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_002: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 1] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_003: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 2] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_004: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 3] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_005: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 4] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_006: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 5] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_007: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 6] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 6] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_008: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 7] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 7] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_009: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 8] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 8] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_010: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 9] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 9] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_011: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 10] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 10] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_012: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 11] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 11] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/positive_test/input/nested-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/positive_test/input/nested-pps_v1.0.yaml new file mode 100644 index 0000000000..fc5b6f74c3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/positive_test/input/nested-pps_v1.0.yaml @@ -0,0 +1,99 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_name: + type: string + label: PCRF PS server name + description: PCRF PS server name + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + template: { get_file: cloud-nimbus.sh } + params: + $vm_name: { get_param: pcrf_pps_server_name } + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet } + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_pps: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_pps_server_name } + image: { get_param: pcrf_pps_image_name } + flavor: { get_param: pcrf_pps_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcrf_pps_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + + pcrf_pps_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/positive_test/input/nested-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/positive_test/input/nested-psm_v1.0.yaml new file mode 100644 index 0000000000..c86aa34713 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/parameter_default_value/positive_test/input/nested-psm_v1.0.yaml @@ -0,0 +1,99 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_name: + type: string + label: PCRF SM server name + description: PCRF SM server name + pcrf_psm_image_name: + type: string + label: image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet } + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + template: { get_file: cloud-nimbus.sh } + params: + $vm_name: { get_param: pcrf_psm_server_name } + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_psm: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_psm_server_name } + image: { get_param: pcrf_psm_image_name } + flavor: { get_param: pcrf_psm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: psm01_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + #scheduler_hints: {group: { get_resource: servergroup_nimbus }} + + psm01_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/negative_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/negative_test/input/MANIFEST.json new file mode 100644 index 0000000000..dd26e5ac45 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/negative_test/input/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.env", + "type": "HEAT_ENV" + } + ] + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/negative_test/input/hot-nimbus-psm_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/negative_test/input/hot-nimbus-psm_v1.0.env new file mode 100644 index 0000000000..f613758633 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/negative_test/input/hot-nimbus-psm_v1.0.env @@ -0,0 +1,8 @@ +parameters: + pcrf_psm_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_psm_flavor_name: lc.4xlarge4 + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/negative_test/input/hot-nimbus-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/negative_test/input/hot-nimbus-psm_v1.0.yaml new file mode 100644 index 0000000000..82edacf101 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/negative_test/input/hot-nimbus-psm_v1.0.yaml @@ -0,0 +1,116 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_name: + type: string + label: PCRF SM server name + description: PCRF SM server name + pcrf_psm_image_name: + type: string + label: image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + params: + $vm_name: { get_param: pcrf_psm_server_name } + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_psm: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_psm_server_name } + image: { get_param: pcrf_psm_image_name } + flavor: { get_param: pcrf_psm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: psm01_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + scheduler_hints: {group_1: { get_resource: pcrf_server_policies_1 }, group_2: { get_resource: pcrf_server_policies_2 }, group_3: { get_resource: pcrf_server_policies_3 }} + + pcrf_server_policies_1: + type: OS::Nova::ServerGroup + properties: + config_drive: "True" + policies: [affinity, anti-affinity] + + pcrf_server_policies_2: + type: OS::Nova::ServerGroup + properties: + config_drive: "True" + policies: + + pcrf_server_policies_3: + type: OS::Nova::ServerGroup + properties: + config_drive: "True" + policies: [affinity, ] + + psm01_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/positive_test/expected_output/expected_output.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/positive_test/expected_output/expected_output.json new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/positive_test/expected_output/expected_output.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/positive_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/positive_test/input/MANIFEST.json new file mode 100644 index 0000000000..fe7d8bdf5a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/positive_test/input/MANIFEST.json @@ -0,0 +1,51 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "hot-nimbus-psm_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "nested-pps_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "nested-psm_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "mount_iso_script.sh", + "type": "SHELL" + }, + { + "file": "cloud-nimbus.sh", + "type": "SHELL" + }, + { + "file": "nimbus-ethernet", + "type": "OTHER" + }, + { + "file": "nimbus-ethernet-gw", + "type": "OTHER" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/positive_test/input/hot-nimbus-pps_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/positive_test/input/hot-nimbus-pps_v1.0.env new file mode 100644 index 0000000000..340be2b815 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/positive_test/input/hot-nimbus-pps_v1.0.env @@ -0,0 +1,11 @@ +parameters: + pcrf_pps_server_names: ZRDM1PCRF01PPS001,ZRDM1PCRF01PPS002,ZRDM1PCRF01PPS003,ZRDM1PCRF01PPS004,ZRDM1PCRF01PPS005,ZRDM1PCRF01PPS006 + pcrf_pps_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pps_flavor_name: lc.3xlarge + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.7,172.26.16.8,172.26.16.9,172.26.16.10,172.26.16.11,172.26.16.12 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/positive_test/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/positive_test/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..05bd6c9318 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/positive_test/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,121 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_pps_001: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_002: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 1] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_003: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 2] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_004: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 3] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_005: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 4] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_006: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 5] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/positive_test/input/hot-nimbus-psm_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/positive_test/input/hot-nimbus-psm_v1.0.env new file mode 100644 index 0000000000..f24e4763c6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/positive_test/input/hot-nimbus-psm_v1.0.env @@ -0,0 +1,10 @@ +parameters: + pcrf_psm_server_names: ZRDM1PCRF01PSM001,ZRDM1PCRF01PSM002,ZRDM1PCRF01PSM003,ZRDM1PCRF01PSM004,ZRDM1PCRF01PSM005,ZRDM1PCRF01PSM006,ZRDM1PCRF01PSM007,ZRDM1PCRF01PSM008,ZRDM1PCRF01PSM009,ZRDM1PCRF01PSM010,ZRDM1PCRF01PSM011,ZRDM1PCRF01PSM012 + pcrf_psm_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_psm_flavor_name: lc.4xlarge4 + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.63,172.26.16.64,172.26.16.65,172.26.16.66,172.26.16.67,172.26.16.68,172.26.16.69,172.26.16.70,172.26.16.71,172.26.16.72,172.26.16.73,172.26.16.74 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/positive_test/input/hot-nimbus-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/positive_test/input/hot-nimbus-psm_v1.0.yaml new file mode 100644 index 0000000000..c2d7b05ead --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/positive_test/input/hot-nimbus-psm_v1.0.yaml @@ -0,0 +1,199 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_names: + type: comma_delimited_list + label: PCRF SM server names + description: name of the PCRF SM instance + pcrf_psm_image_name: + type: string + label: PCRF SM image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_psm_001: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 0] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_002: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 1] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_003: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 2] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_004: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 3] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_005: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 4] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_006: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 5] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_007: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 6] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 6] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_008: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 7] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 7] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_009: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 8] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 8] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_010: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 9] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 9] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_011: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 10] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 10] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_012: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 11] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 11] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/positive_test/input/nested-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/positive_test/input/nested-pps_v1.0.yaml new file mode 100644 index 0000000000..a7966d6d47 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/positive_test/input/nested-pps_v1.0.yaml @@ -0,0 +1,114 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_name: + type: string + label: PCRF PS server name + description: PCRF PS server name + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + params: + $vm_name: { get_param: pcrf_pps_server_name } + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_pps: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_pps_server_name } + image: { get_param: pcrf_pps_image_name } + flavor: { get_param: pcrf_pps_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcrf_pps_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + + pcrf_server_policies: + type: OS::Nova::ServerGroup + properties: + config_drive: "True" + policies: [affinity] + name: { get_param: pcrf_pps_server_name } + image: { get_param: pcrf_pps_image_name } + flavor: { get_param: pcrf_pps_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcrf_pps_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + + pcrf_pps_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/positive_test/input/nested-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/positive_test/input/nested-psm_v1.0.yaml new file mode 100644 index 0000000000..681117d275 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/policy_is_affinity_or_anti_affinity/positive_test/input/nested-psm_v1.0.yaml @@ -0,0 +1,112 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_name: + type: string + label: PCRF SM server name + description: PCRF SM server name + pcrf_psm_image_name: + type: string + label: image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + params: + $vm_name: { get_param: pcrf_psm_server_name } + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_psm: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_psm_server_name } + image: { get_param: pcrf_psm_image_name } + flavor: { get_param: pcrf_psm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: psm01_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + #scheduler_hints: {group: { get_resource: servergroup_nimbus }} + + psm01_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] + + pcrf_server_policies: + type: OS::Nova::ServerGroup + properties: + config_drive: "True" + policies: [anti-affinity] + name: { get_param: pcrf_psm_server_name } + image: { get_param: pcrf_psm_image_name } + flavor: { get_param: pcrf_psm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/negative_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/negative_test/input/MANIFEST.json new file mode 100644 index 0000000000..fe7d8bdf5a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/negative_test/input/MANIFEST.json @@ -0,0 +1,51 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "hot-nimbus-psm_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "nested-pps_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "nested-psm_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "mount_iso_script.sh", + "type": "SHELL" + }, + { + "file": "cloud-nimbus.sh", + "type": "SHELL" + }, + { + "file": "nimbus-ethernet", + "type": "OTHER" + }, + { + "file": "nimbus-ethernet-gw", + "type": "OTHER" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/negative_test/input/hot-nimbus-pps_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/negative_test/input/hot-nimbus-pps_v1.0.env new file mode 100644 index 0000000000..340be2b815 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/negative_test/input/hot-nimbus-pps_v1.0.env @@ -0,0 +1,11 @@ +parameters: + pcrf_pps_server_names: ZRDM1PCRF01PPS001,ZRDM1PCRF01PPS002,ZRDM1PCRF01PPS003,ZRDM1PCRF01PPS004,ZRDM1PCRF01PPS005,ZRDM1PCRF01PPS006 + pcrf_pps_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pps_flavor_name: lc.3xlarge + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.7,172.26.16.8,172.26.16.9,172.26.16.10,172.26.16.11,172.26.16.12 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/negative_test/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/negative_test/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..05bd6c9318 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/negative_test/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,121 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_pps_001: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_002: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 1] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_003: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 2] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_004: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 3] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_005: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 4] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_006: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 5] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/negative_test/input/hot-nimbus-psm_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/negative_test/input/hot-nimbus-psm_v1.0.env new file mode 100644 index 0000000000..f24e4763c6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/negative_test/input/hot-nimbus-psm_v1.0.env @@ -0,0 +1,10 @@ +parameters: + pcrf_psm_server_names: ZRDM1PCRF01PSM001,ZRDM1PCRF01PSM002,ZRDM1PCRF01PSM003,ZRDM1PCRF01PSM004,ZRDM1PCRF01PSM005,ZRDM1PCRF01PSM006,ZRDM1PCRF01PSM007,ZRDM1PCRF01PSM008,ZRDM1PCRF01PSM009,ZRDM1PCRF01PSM010,ZRDM1PCRF01PSM011,ZRDM1PCRF01PSM012 + pcrf_psm_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_psm_flavor_name: lc.4xlarge4 + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.63,172.26.16.64,172.26.16.65,172.26.16.66,172.26.16.67,172.26.16.68,172.26.16.69,172.26.16.70,172.26.16.71,172.26.16.72,172.26.16.73,172.26.16.74 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/negative_test/input/hot-nimbus-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/negative_test/input/hot-nimbus-psm_v1.0.yaml new file mode 100644 index 0000000000..c2d7b05ead --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/negative_test/input/hot-nimbus-psm_v1.0.yaml @@ -0,0 +1,199 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_names: + type: comma_delimited_list + label: PCRF SM server names + description: name of the PCRF SM instance + pcrf_psm_image_name: + type: string + label: PCRF SM image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_psm_001: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 0] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_002: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 1] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_003: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 2] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_004: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 3] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_005: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 4] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_006: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 5] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_007: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 6] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 6] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_008: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 7] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 7] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_009: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 8] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 8] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_010: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 9] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 9] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_011: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 10] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 10] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_012: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 11] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 11] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/negative_test/input/nested-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/negative_test/input/nested-pps_v1.0.yaml new file mode 100644 index 0000000000..fc5b6f74c3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/negative_test/input/nested-pps_v1.0.yaml @@ -0,0 +1,99 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_name: + type: string + label: PCRF PS server name + description: PCRF PS server name + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + template: { get_file: cloud-nimbus.sh } + params: + $vm_name: { get_param: pcrf_pps_server_name } + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet } + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_pps: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_pps_server_name } + image: { get_param: pcrf_pps_image_name } + flavor: { get_param: pcrf_pps_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcrf_pps_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + + pcrf_pps_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/negative_test/input/nested-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/negative_test/input/nested-psm_v1.0.yaml new file mode 100644 index 0000000000..c86aa34713 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/negative_test/input/nested-psm_v1.0.yaml @@ -0,0 +1,99 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_name: + type: string + label: PCRF SM server name + description: PCRF SM server name + pcrf_psm_image_name: + type: string + label: image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet } + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + template: { get_file: cloud-nimbus.sh } + params: + $vm_name: { get_param: pcrf_psm_server_name } + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_psm: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_psm_server_name } + image: { get_param: pcrf_psm_image_name } + flavor: { get_param: pcrf_psm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: psm01_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + #scheduler_hints: {group: { get_resource: servergroup_nimbus }} + + psm01_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/positive_test/expected_output/expected_output.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/positive_test/expected_output/expected_output.json new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/positive_test/expected_output/expected_output.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/positive_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/positive_test/input/MANIFEST.json new file mode 100644 index 0000000000..fe7d8bdf5a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/positive_test/input/MANIFEST.json @@ -0,0 +1,51 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "hot-nimbus-psm_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "nested-pps_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "nested-psm_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "mount_iso_script.sh", + "type": "SHELL" + }, + { + "file": "cloud-nimbus.sh", + "type": "SHELL" + }, + { + "file": "nimbus-ethernet", + "type": "OTHER" + }, + { + "file": "nimbus-ethernet-gw", + "type": "OTHER" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/positive_test/input/hot-nimbus-pps_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/positive_test/input/hot-nimbus-pps_v1.0.env new file mode 100644 index 0000000000..340be2b815 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/positive_test/input/hot-nimbus-pps_v1.0.env @@ -0,0 +1,11 @@ +parameters: + pcrf_pps_server_names: ZRDM1PCRF01PPS001,ZRDM1PCRF01PPS002,ZRDM1PCRF01PPS003,ZRDM1PCRF01PPS004,ZRDM1PCRF01PPS005,ZRDM1PCRF01PPS006 + pcrf_pps_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pps_flavor_name: lc.3xlarge + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.7,172.26.16.8,172.26.16.9,172.26.16.10,172.26.16.11,172.26.16.12 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/positive_test/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/positive_test/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..05bd6c9318 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/positive_test/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,121 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_pps_001: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_002: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 1] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_003: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 2] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_004: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 3] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_005: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 4] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_006: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 5] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/positive_test/input/hot-nimbus-psm_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/positive_test/input/hot-nimbus-psm_v1.0.env new file mode 100644 index 0000000000..f24e4763c6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/positive_test/input/hot-nimbus-psm_v1.0.env @@ -0,0 +1,10 @@ +parameters: + pcrf_psm_server_names: ZRDM1PCRF01PSM001,ZRDM1PCRF01PSM002,ZRDM1PCRF01PSM003,ZRDM1PCRF01PSM004,ZRDM1PCRF01PSM005,ZRDM1PCRF01PSM006,ZRDM1PCRF01PSM007,ZRDM1PCRF01PSM008,ZRDM1PCRF01PSM009,ZRDM1PCRF01PSM010,ZRDM1PCRF01PSM011,ZRDM1PCRF01PSM012 + pcrf_psm_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_psm_flavor_name: lc.4xlarge4 + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.63,172.26.16.64,172.26.16.65,172.26.16.66,172.26.16.67,172.26.16.68,172.26.16.69,172.26.16.70,172.26.16.71,172.26.16.72,172.26.16.73,172.26.16.74 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/positive_test/input/hot-nimbus-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/positive_test/input/hot-nimbus-psm_v1.0.yaml new file mode 100644 index 0000000000..c2d7b05ead --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/positive_test/input/hot-nimbus-psm_v1.0.yaml @@ -0,0 +1,199 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_names: + type: comma_delimited_list + label: PCRF SM server names + description: name of the PCRF SM instance + pcrf_psm_image_name: + type: string + label: PCRF SM image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_psm_001: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 0] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_002: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 1] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_003: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 2] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_004: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 3] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_005: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 4] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_006: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 5] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_007: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 6] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 6] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_008: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 7] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 7] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_009: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 8] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 8] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_010: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 9] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 9] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_011: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 10] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 10] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_012: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 11] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 11] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/positive_test/input/nested-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/positive_test/input/nested-pps_v1.0.yaml new file mode 100644 index 0000000000..fc5b6f74c3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/positive_test/input/nested-pps_v1.0.yaml @@ -0,0 +1,99 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_name: + type: string + label: PCRF PS server name + description: PCRF PS server name + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + template: { get_file: cloud-nimbus.sh } + params: + $vm_name: { get_param: pcrf_pps_server_name } + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet } + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_pps: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_pps_server_name } + image: { get_param: pcrf_pps_image_name } + flavor: { get_param: pcrf_pps_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcrf_pps_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + + pcrf_pps_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/positive_test/input/nested-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/positive_test/input/nested-psm_v1.0.yaml new file mode 100644 index 0000000000..c86aa34713 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties-match-nested-parameters/positive_test/input/nested-psm_v1.0.yaml @@ -0,0 +1,99 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_name: + type: string + label: PCRF SM server name + description: PCRF SM server name + pcrf_psm_image_name: + type: string + label: image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet } + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + template: { get_file: cloud-nimbus.sh } + params: + $vm_name: { get_param: pcrf_psm_server_name } + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_psm: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_psm_server_name } + image: { get_param: pcrf_psm_image_name } + flavor: { get_param: pcrf_psm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: psm01_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + #scheduler_hints: {group: { get_resource: servergroup_nimbus }} + + psm01_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/negative_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/negative_test/input/MANIFEST.json new file mode 100644 index 0000000000..02118a7b23 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/negative_test/input/MANIFEST.json @@ -0,0 +1,21 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "nested-pps_v1.0.yaml", + "type": "HEAT" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/negative_test/input/hot-nimbus-pps_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/negative_test/input/hot-nimbus-pps_v1.0.env new file mode 100644 index 0000000000..340be2b815 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/negative_test/input/hot-nimbus-pps_v1.0.env @@ -0,0 +1,11 @@ +parameters: + pcrf_pps_server_names: ZRDM1PCRF01PPS001,ZRDM1PCRF01PPS002,ZRDM1PCRF01PPS003,ZRDM1PCRF01PPS004,ZRDM1PCRF01PPS005,ZRDM1PCRF01PPS006 + pcrf_pps_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pps_flavor_name: lc.3xlarge + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.7,172.26.16.8,172.26.16.9,172.26.16.10,172.26.16.11,172.26.16.12 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/negative_test/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/negative_test/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..5d93b2f4f7 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/negative_test/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,49 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_pps_001: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + parameter_not_existing_in_nested: {get_param: pcrf_vnf_id} diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/negative_test/input/nested-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/negative_test/input/nested-pps_v1.0.yaml new file mode 100644 index 0000000000..0ed9043fc2 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/negative_test/input/nested-pps_v1.0.yaml @@ -0,0 +1,74 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_name: + type: string + label: PCRF PS server name + description: PCRF PS server name + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + params: + $vm_name: { get_param: pcrf_pps_server_name } + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/positive_test/expected_output/expected_output.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/positive_test/expected_output/expected_output.json new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/positive_test/expected_output/expected_output.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/positive_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/positive_test/input/MANIFEST.json new file mode 100644 index 0000000000..fe7d8bdf5a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/positive_test/input/MANIFEST.json @@ -0,0 +1,51 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "hot-nimbus-psm_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "nested-pps_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "nested-psm_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "mount_iso_script.sh", + "type": "SHELL" + }, + { + "file": "cloud-nimbus.sh", + "type": "SHELL" + }, + { + "file": "nimbus-ethernet", + "type": "OTHER" + }, + { + "file": "nimbus-ethernet-gw", + "type": "OTHER" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/positive_test/input/hot-nimbus-pps_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/positive_test/input/hot-nimbus-pps_v1.0.env new file mode 100644 index 0000000000..340be2b815 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/positive_test/input/hot-nimbus-pps_v1.0.env @@ -0,0 +1,11 @@ +parameters: + pcrf_pps_server_names: ZRDM1PCRF01PPS001,ZRDM1PCRF01PPS002,ZRDM1PCRF01PPS003,ZRDM1PCRF01PPS004,ZRDM1PCRF01PPS005,ZRDM1PCRF01PPS006 + pcrf_pps_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pps_flavor_name: lc.3xlarge + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.7,172.26.16.8,172.26.16.9,172.26.16.10,172.26.16.11,172.26.16.12 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/positive_test/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/positive_test/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..05bd6c9318 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/positive_test/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,121 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_pps_001: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_002: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 1] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_003: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 2] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_004: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 3] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_005: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 4] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_006: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 5] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/positive_test/input/hot-nimbus-psm_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/positive_test/input/hot-nimbus-psm_v1.0.env new file mode 100644 index 0000000000..f24e4763c6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/positive_test/input/hot-nimbus-psm_v1.0.env @@ -0,0 +1,10 @@ +parameters: + pcrf_psm_server_names: ZRDM1PCRF01PSM001,ZRDM1PCRF01PSM002,ZRDM1PCRF01PSM003,ZRDM1PCRF01PSM004,ZRDM1PCRF01PSM005,ZRDM1PCRF01PSM006,ZRDM1PCRF01PSM007,ZRDM1PCRF01PSM008,ZRDM1PCRF01PSM009,ZRDM1PCRF01PSM010,ZRDM1PCRF01PSM011,ZRDM1PCRF01PSM012 + pcrf_psm_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_psm_flavor_name: lc.4xlarge4 + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.63,172.26.16.64,172.26.16.65,172.26.16.66,172.26.16.67,172.26.16.68,172.26.16.69,172.26.16.70,172.26.16.71,172.26.16.72,172.26.16.73,172.26.16.74 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/positive_test/input/hot-nimbus-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/positive_test/input/hot-nimbus-psm_v1.0.yaml new file mode 100644 index 0000000000..c2d7b05ead --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/positive_test/input/hot-nimbus-psm_v1.0.yaml @@ -0,0 +1,199 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_names: + type: comma_delimited_list + label: PCRF SM server names + description: name of the PCRF SM instance + pcrf_psm_image_name: + type: string + label: PCRF SM image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_psm_001: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 0] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_002: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 1] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_003: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 2] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_004: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 3] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_005: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 4] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_006: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 5] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_007: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 6] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 6] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_008: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 7] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 7] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_009: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 8] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 8] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_010: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 9] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 9] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_011: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 10] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 10] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_012: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 11] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 11] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/positive_test/input/nested-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/positive_test/input/nested-pps_v1.0.yaml new file mode 100644 index 0000000000..b7291d69d3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/positive_test/input/nested-pps_v1.0.yaml @@ -0,0 +1,97 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_name: + type: string + label: PCRF PS server name + description: PCRF PS server name + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + params: + $vm_name: { get_param: pcrf_pps_server_name } + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_pps: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_pps_server_name } + image: { get_param: pcrf_pps_image_name } + flavor: { get_param: pcrf_pps_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcrf_pps_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + + pcrf_pps_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/positive_test/input/nested-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/positive_test/input/nested-psm_v1.0.yaml new file mode 100644 index 0000000000..6868728b73 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/properties_match_nested_parameters/positive_test/input/nested-psm_v1.0.yaml @@ -0,0 +1,97 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_name: + type: string + label: PCRF SM server name + description: PCRF SM server name + pcrf_psm_image_name: + type: string + label: image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + params: + $vm_name: { get_param: pcrf_psm_server_name } + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_psm: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_psm_server_name } + image: { get_param: pcrf_psm_image_name } + flavor: { get_param: pcrf_psm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: psm01_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + #scheduler_hints: {group: { get_resource: servergroup_nimbus }} + + psm01_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/pseudo_parameters/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/pseudo_parameters/input/MANIFEST.json new file mode 100644 index 0000000000..d038fb2a7e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/pseudo_parameters/input/MANIFEST.json @@ -0,0 +1,11 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "pseudo_parameters.yml", + "type": "HEAT" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/pseudo_parameters/input/pseudo_parameters.yml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/pseudo_parameters/input/pseudo_parameters.yml new file mode 100644 index 0000000000..8dd378ccbd --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/pseudo_parameters/input/pseudo_parameters.yml @@ -0,0 +1,61 @@ +heat_template_version: 2013-05-23 + +description: HOT template for vMME Cinder Volumes + + +parameters: + + volume_type: + type: string + label: volume type + description: volume type SolidFire + + volume_size: + type: number + label: volume size + description: my volume size 320GB + + FSB_1_image: + type: string + label: MME_FSB1 + description: MME_FSB1_16ACP03_GA + + FSB_2_image: + type: string + label: MME_FSB2 + description: MME_FSB2_16ACP03_GA + +resources: + + FSB1_volume: + type: OS::Cinder::Volume + properties: + name: + list_join: ['_', [{get_param: 'OS::stack_name'}, 'FSB1_Vol_1']] + + FSB2_volume: + type: OS::Cinder::Volume + properties: + name: + list_join: ['_', [{get_param: 'OS::stack_id'}, 'FSB1_Vol_2']] + + FSB3_volume: + type: OS::Cinder::Volume + properties: + name: + list_join: ['_', [{get_param: 'OS::project_id'}, 'FSB1_Vol_3']] + + +outputs: + FSB1_volume_id: + description: ID of Cinder Volume for FSB1 + value: {get_resource: FSB1_volume} + + FSB2_volume_id: + description: ID of Cinder Volume for FSB2 + value: {get_resource: FSB2_volume} + + FSB3_volume_id: + description: ID of Cinder Volume for FSB3 + value: {get_resource: FSB3_volume} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/negative_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/negative_test/input/MANIFEST.json new file mode 100644 index 0000000000..a1ec6bc0f7 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/negative_test/input/MANIFEST.json @@ -0,0 +1,11 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/negative_test/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/negative_test/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..c4680ab619 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/negative_test/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,99 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_name: + type: string + label: PCRF PS server name + description: PCRF PS server name + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + template: { get_file: } + params: + $vm_name: { get_param: pcrf_pps_server_name } + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet } + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_pps: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_pps_server_name } + image: { get_param: pcrf_pps_image_name } + flavor: { get_param: pcrf_pps_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcrf_pps_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + + pcrf_pps_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/expected_output/expected_output.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/expected_output/expected_output.json new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/expected_output/expected_output.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/MANIFEST.json new file mode 100644 index 0000000000..ea7f326c76 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/MANIFEST.json @@ -0,0 +1,51 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "hot-nimbus-psm_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "nested-pps_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "nested-psm_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "mount_iso_script.sh", + "type": "SHELL" + }, + { + "file": "cloud-nimbus.sh", + "type": "SHELL" + }, + { + "file": "nimbus-ethernet", + "type": "OTHER" + }, + { + "file": "artifact.sh", + "type": "OTHER" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/artifact.sh b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/artifact.sh new file mode 100644 index 0000000000..fc5b6f74c3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/artifact.sh @@ -0,0 +1,99 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_name: + type: string + label: PCRF PS server name + description: PCRF PS server name + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + template: { get_file: cloud-nimbus.sh } + params: + $vm_name: { get_param: pcrf_pps_server_name } + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet } + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_pps: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_pps_server_name } + image: { get_param: pcrf_pps_image_name } + flavor: { get_param: pcrf_pps_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcrf_pps_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + + pcrf_pps_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/cloud-nimbus.sh b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/cloud-nimbus.sh new file mode 100644 index 0000000000..fc5b6f74c3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/cloud-nimbus.sh @@ -0,0 +1,99 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_name: + type: string + label: PCRF PS server name + description: PCRF PS server name + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + template: { get_file: cloud-nimbus.sh } + params: + $vm_name: { get_param: pcrf_pps_server_name } + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet } + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_pps: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_pps_server_name } + image: { get_param: pcrf_pps_image_name } + flavor: { get_param: pcrf_pps_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcrf_pps_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + + pcrf_pps_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/hot-nimbus-pps_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/hot-nimbus-pps_v1.0.env new file mode 100644 index 0000000000..340be2b815 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/hot-nimbus-pps_v1.0.env @@ -0,0 +1,11 @@ +parameters: + pcrf_pps_server_names: ZRDM1PCRF01PPS001,ZRDM1PCRF01PPS002,ZRDM1PCRF01PPS003,ZRDM1PCRF01PPS004,ZRDM1PCRF01PPS005,ZRDM1PCRF01PPS006 + pcrf_pps_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pps_flavor_name: lc.3xlarge + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.7,172.26.16.8,172.26.16.9,172.26.16.10,172.26.16.11,172.26.16.12 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..05bd6c9318 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,121 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_pps_001: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_002: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 1] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_003: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 2] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_004: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 3] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_005: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 4] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_006: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 5] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/hot-nimbus-psm_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/hot-nimbus-psm_v1.0.env new file mode 100644 index 0000000000..f24e4763c6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/hot-nimbus-psm_v1.0.env @@ -0,0 +1,10 @@ +parameters: + pcrf_psm_server_names: ZRDM1PCRF01PSM001,ZRDM1PCRF01PSM002,ZRDM1PCRF01PSM003,ZRDM1PCRF01PSM004,ZRDM1PCRF01PSM005,ZRDM1PCRF01PSM006,ZRDM1PCRF01PSM007,ZRDM1PCRF01PSM008,ZRDM1PCRF01PSM009,ZRDM1PCRF01PSM010,ZRDM1PCRF01PSM011,ZRDM1PCRF01PSM012 + pcrf_psm_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_psm_flavor_name: lc.4xlarge4 + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.63,172.26.16.64,172.26.16.65,172.26.16.66,172.26.16.67,172.26.16.68,172.26.16.69,172.26.16.70,172.26.16.71,172.26.16.72,172.26.16.73,172.26.16.74 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/hot-nimbus-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/hot-nimbus-psm_v1.0.yaml new file mode 100644 index 0000000000..a591692753 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/hot-nimbus-psm_v1.0.yaml @@ -0,0 +1,212 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_names: + type: comma_delimited_list + label: PCRF SM server names + description: name of the PCRF SM instance + pcrf_psm_image_name: + type: string + label: PCRF SM image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + artifact_resource: + type: OS::Nova::Server + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 0] } + image: { get_param: pcrf_psm_image_name } + flavor: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + artifact: { get_file: artifact.sh } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_001: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 0] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_002: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 1] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_003: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 2] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_004: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 3] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_005: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 4] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_006: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 5] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_007: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 6] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 6] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_008: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 7] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 7] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_009: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 8] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 8] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_010: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 9] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 9] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_011: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 10] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 10] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_012: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 11] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 11] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/nested-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/nested-pps_v1.0.yaml new file mode 100644 index 0000000000..fc5b6f74c3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/nested-pps_v1.0.yaml @@ -0,0 +1,99 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_name: + type: string + label: PCRF PS server name + description: PCRF PS server name + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + template: { get_file: cloud-nimbus.sh } + params: + $vm_name: { get_param: pcrf_pps_server_name } + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet } + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_pps: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_pps_server_name } + image: { get_param: pcrf_pps_image_name } + flavor: { get_param: pcrf_pps_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcrf_pps_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + + pcrf_pps_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/nested-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/nested-psm_v1.0.yaml new file mode 100644 index 0000000000..c86aa34713 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/nested-psm_v1.0.yaml @@ -0,0 +1,99 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_name: + type: string + label: PCRF SM server name + description: PCRF SM server name + pcrf_psm_image_name: + type: string + label: image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet } + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + template: { get_file: cloud-nimbus.sh } + params: + $vm_name: { get_param: pcrf_psm_server_name } + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_psm: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_psm_server_name } + image: { get_param: pcrf_psm_image_name } + flavor: { get_param: pcrf_psm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: psm01_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + #scheduler_hints: {group: { get_resource: servergroup_nimbus }} + + psm01_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/nimbus-ethernet b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/nimbus-ethernet new file mode 100644 index 0000000000..fc5b6f74c3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/referenced_artifacts_exist/positive_test/input/nimbus-ethernet @@ -0,0 +1,99 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_name: + type: string + label: PCRF PS server name + description: PCRF PS server name + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + template: { get_file: cloud-nimbus.sh } + params: + $vm_name: { get_param: pcrf_pps_server_name } + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet } + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_pps: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_pps_server_name } + image: { get_param: pcrf_pps_image_name } + flavor: { get_param: pcrf_pps_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcrf_pps_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + + pcrf_pps_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_group_invalid_type/negative_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_group_invalid_type/negative_test/input/MANIFEST.json new file mode 100644 index 0000000000..5513de2ba2 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_group_invalid_type/negative_test/input/MANIFEST.json @@ -0,0 +1,11 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.yaml", + "type": "HEAT" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_group_invalid_type/negative_test/input/hot-nimbus-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_group_invalid_type/negative_test/input/hot-nimbus-psm_v1.0.yaml new file mode 100644 index 0000000000..14ee7b10d2 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_group_invalid_type/negative_test/input/hot-nimbus-psm_v1.0.yaml @@ -0,0 +1,102 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + num_instances: + type: comma_delimited_list + label: PCRF SM server names + description: name of the PCRF SM instance + pcrf_psm_server_names: + type: comma_delimited_list + label: PCRF SM server names + description: name of the PCRF SM instance + pcrf_psm_image_name: + type: string + label: PCRF SM image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + pcrf_pps_server_names: + type: string + + pcrf_pps_image_name: + type: string + pcrf_pps_flavor_name: + type: string + availability_zone_0: + type: string +resources: + resource_with_resources_group_1: + type: OS::Heat::ResourceGroup + properties: + count: { get_param: num_instances } + resource_def: + type: {get_param: pcrf_vnf_id} + properties: + pcrf_psm_server_name: { get_param: pcrf_pps_server_names } + pcrf_psm_image_name: { get_param: pcrf_pps_image_name } + + + + + resource_with_resources_group_2: + type: OS::Heat::ResourceGroup + properties: + count: { get_param: num_instances } + resource_def: + type: OS::Nova::Server + properties: + cloud_zone_id: { get_param: pcrf_pps_server_names } + vf_name: { get_param: pcrf_pps_image_name } + + + + resource_with_resources_group_3: + type: OS::Heat::ResourceGroup + properties: + count: { get_param: num_instances } + resource_def: + type: + properties: + cloud_zone_id: { get_param: pcrf_pps_server_names } + vf_name: { get_param: pcrf_pps_image_name } + + + resource_with_resources_group_4: + type: OS::Heat::ResourceGroup + properties: + count: { get_param: num_instances } + resource_def: + type: yamlFile.yaml + + + + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_group_invalid_type/negative_test/input/yamlFile.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_group_invalid_type/negative_test/input/yamlFile.yaml new file mode 100644 index 0000000000..12a838bcf5 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_group_invalid_type/negative_test/input/yamlFile.yaml @@ -0,0 +1,47 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + num_instances: + type: comma_delimited_list + label: PCRF SM server names + description: name of the PCRF SM instance + pcrf_psm_server_names: + type: comma_delimited_list + label: PCRF SM server names + description: name of the PCRF SM instance + pcrf_psm_image_name: + type: string + label: PCRF SM image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + pcrf_pps_server_names: + type: string \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/negative_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/negative_test/input/MANIFEST.json new file mode 100644 index 0000000000..3a4d09caa9 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/negative_test/input/MANIFEST.json @@ -0,0 +1,15 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "nested-pps_v1.0.yaml", + "type": "HEAT" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/negative_test/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/negative_test/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..1154c06f4d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/negative_test/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,16 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +resources: + server_pcrf_pps_007: + type: OS::Contrail::NetworkIpam + properties: + pcrf_pps_server_name: { get_resource: not_existing_resource } + + server_pcrf_pps_008: + type: OS::Contrail::NetworkIpam + properties: + pcrf_pps_server_name: { get_resource: } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/positive_test/expected_output/expected_output.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/positive_test/expected_output/expected_output.json new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/positive_test/expected_output/expected_output.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/positive_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/positive_test/input/MANIFEST.json new file mode 100644 index 0000000000..fe7d8bdf5a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/positive_test/input/MANIFEST.json @@ -0,0 +1,51 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "hot-nimbus-psm_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "nested-pps_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "nested-psm_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "mount_iso_script.sh", + "type": "SHELL" + }, + { + "file": "cloud-nimbus.sh", + "type": "SHELL" + }, + { + "file": "nimbus-ethernet", + "type": "OTHER" + }, + { + "file": "nimbus-ethernet-gw", + "type": "OTHER" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/positive_test/input/hot-nimbus-pps_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/positive_test/input/hot-nimbus-pps_v1.0.env new file mode 100644 index 0000000000..340be2b815 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/positive_test/input/hot-nimbus-pps_v1.0.env @@ -0,0 +1,11 @@ +parameters: + pcrf_pps_server_names: ZRDM1PCRF01PPS001,ZRDM1PCRF01PPS002,ZRDM1PCRF01PPS003,ZRDM1PCRF01PPS004,ZRDM1PCRF01PPS005,ZRDM1PCRF01PPS006 + pcrf_pps_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pps_flavor_name: lc.3xlarge + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.7,172.26.16.8,172.26.16.9,172.26.16.10,172.26.16.11,172.26.16.12 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/positive_test/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/positive_test/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..05bd6c9318 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/positive_test/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,121 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_pps_001: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_002: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 1] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_003: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 2] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_004: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 3] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_005: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 4] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_006: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 5] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/positive_test/input/hot-nimbus-psm_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/positive_test/input/hot-nimbus-psm_v1.0.env new file mode 100644 index 0000000000..f24e4763c6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/positive_test/input/hot-nimbus-psm_v1.0.env @@ -0,0 +1,10 @@ +parameters: + pcrf_psm_server_names: ZRDM1PCRF01PSM001,ZRDM1PCRF01PSM002,ZRDM1PCRF01PSM003,ZRDM1PCRF01PSM004,ZRDM1PCRF01PSM005,ZRDM1PCRF01PSM006,ZRDM1PCRF01PSM007,ZRDM1PCRF01PSM008,ZRDM1PCRF01PSM009,ZRDM1PCRF01PSM010,ZRDM1PCRF01PSM011,ZRDM1PCRF01PSM012 + pcrf_psm_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_psm_flavor_name: lc.4xlarge4 + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.63,172.26.16.64,172.26.16.65,172.26.16.66,172.26.16.67,172.26.16.68,172.26.16.69,172.26.16.70,172.26.16.71,172.26.16.72,172.26.16.73,172.26.16.74 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/positive_test/input/hot-nimbus-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/positive_test/input/hot-nimbus-psm_v1.0.yaml new file mode 100644 index 0000000000..c2d7b05ead --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/positive_test/input/hot-nimbus-psm_v1.0.yaml @@ -0,0 +1,199 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_names: + type: comma_delimited_list + label: PCRF SM server names + description: name of the PCRF SM instance + pcrf_psm_image_name: + type: string + label: PCRF SM image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_psm_001: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 0] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_002: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 1] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_003: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 2] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_004: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 3] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_005: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 4] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_006: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 5] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_007: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 6] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 6] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_008: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 7] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 7] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_009: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 8] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 8] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_010: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 9] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 9] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_011: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 10] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 10] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_012: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 11] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 11] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/positive_test/input/nested-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/positive_test/input/nested-pps_v1.0.yaml new file mode 100644 index 0000000000..b7291d69d3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/positive_test/input/nested-pps_v1.0.yaml @@ -0,0 +1,97 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_name: + type: string + label: PCRF PS server name + description: PCRF PS server name + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + params: + $vm_name: { get_param: pcrf_pps_server_name } + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_pps: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_pps_server_name } + image: { get_param: pcrf_pps_image_name } + flavor: { get_param: pcrf_pps_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcrf_pps_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + + pcrf_pps_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/positive_test/input/nested-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/positive_test/input/nested-psm_v1.0.yaml new file mode 100644 index 0000000000..6868728b73 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resource_references_exist_in_heat/positive_test/input/nested-psm_v1.0.yaml @@ -0,0 +1,97 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_name: + type: string + label: PCRF SM server name + description: PCRF SM server name + pcrf_psm_image_name: + type: string + label: image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + params: + $vm_name: { get_param: pcrf_psm_server_name } + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_psm: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_psm_server_name } + image: { get_param: pcrf_psm_image_name } + flavor: { get_param: pcrf_psm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: psm01_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + #scheduler_hints: {group: { get_resource: servergroup_nimbus }} + + psm01_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/negative_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/negative_test/input/MANIFEST.json new file mode 100644 index 0000000000..0c8e740434 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/negative_test/input/MANIFEST.json @@ -0,0 +1,19 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "hot-nimbus-psm_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "nested-pps_v1.0.yaml", + "type": "HEAT" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/negative_test/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/negative_test/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..e3779ed99d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/negative_test/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,59 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + num_instances: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_pps_001: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + + + resource_with_resources_group: + type: OS::Heat::ResourceGroup + properties: + count: { get_param: num_instances } + resource_def: + type: nested-not-exist.yaml + properties: + pcrf_psm_server_name: { get_param: pcrf_pps_server_names } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/negative_test/input/hot-nimbus-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/negative_test/input/hot-nimbus-psm_v1.0.yaml new file mode 100644 index 0000000000..dc78b37ca2 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/negative_test/input/hot-nimbus-psm_v1.0.yaml @@ -0,0 +1,98 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + num_instances: + type: comma_delimited_list + label: PCRF SM server names + description: name of the PCRF SM instance + pcrf_psm_server_names: + type: comma_delimited_list + label: PCRF SM server names + description: name of the PCRF SM instance + pcrf_psm_image_name: + type: string + label: PCRF SM image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + pcrf_pps_server_names: + type: string + + pcrf_pps_image_name: + type: string + pcrf_pps_flavor_name: + type: string + availability_zone_0: + type: string +resources: + resource_with_resources_group: + type: OS::Heat::ResourceGroup + properties: + count: { get_param: num_instances } + resource_def: + type: nested-from-resources-group.yaml + properties: + pcrf_psm_server_name: { get_param: pcrf_pps_server_names } + pcrf_psm_image_name: { get_param: pcrf_pps_image_name } + property_not_in_nested: { get_param: availabilityzone_name } + pcrf_cps_net_name: { get_param: availabilityzone_name } + pcrf_cps_net_ip: { get_param: pcrf_vnf_id } + pcrf_cps_net_mask: { get_param: pcrf_vnf_id } + pcrf_security_group_name: { get_param: pcrf_pps_image_name } + pcrf_vnf_id: { get_param: pcrf_pps_flavor_name } + + availabilityzone_name: { get_param: availability_zone_0 } + + + + resource_without_resources_group: + type: OS::Heat::ResourceGroup + properties: + count: { get_param: num_instances } + resource_def: + type: OS::Nova::Server + properties: + cloud_zone_id: { get_param: pcrf_pps_server_names } + vf_name: { get_param: pcrf_pps_image_name } + vf_instance_num: { get_param: pcrf_pps_image_name } + vf_component: { get_param: availabilityzone_name } + vm_instance_num: { get_param: availabilityzone_name } + vnf_id: { get_param: pcrf_vnf_id } + vf_module_id: { get_param: pcrf_vnf_id } + bootimage: { get_param: pcrf_pps_image_name } + flavor: { get_param: pcrf_pps_flavor_name } + key_name: { get_param: pcrf_cps_net_mask } + + availability_zone_0: { get_param: availability_zone_0 } + + + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/negative_test/input/nested-from-resources-group.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/negative_test/input/nested-from-resources-group.yaml new file mode 100644 index 0000000000..836ab5c1f8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/negative_test/input/nested-from-resources-group.yaml @@ -0,0 +1,105 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_name: + type: string + label: PCRF SM server name + description: PCRF SM server name + pcrf_psm_image_name: + type: string + label: image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + params: + $vm_name: { get_param: pcrf_psm_server_name } + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_psm: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_psm_server_name } + image: { get_param: pcrf_psm_image_name } + flavor: { get_param: pcrf_psm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: psm01_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + #scheduler_hints: {group: { get_resource: servergroup_nimbus }} + + psm01_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] + + psm01_port_1: + type: hot-nimbus-pps_v1.0.yaml + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/negative_test/input/nested-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/negative_test/input/nested-pps_v1.0.yaml new file mode 100644 index 0000000000..bdf957c59e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/negative_test/input/nested-pps_v1.0.yaml @@ -0,0 +1,52 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_name: + type: string + label: PCRF PS server name + description: PCRF PS server name + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + num_instances: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + pcrf_pps_server_names: + type: string +resources: + resource_with_resources_group: + type: OS::Heat::ResourceGroup + properties: + count: { get_param: num_instances } + resource_def: + type: nested-from-resources-group.yaml + properties: + pcrf_psm_server_name: { get_param: pcrf_pps_server_names } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/expected_output/expected_output.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/expected_output/expected_output.json new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/expected_output/expected_output.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/input/MANIFEST.json new file mode 100644 index 0000000000..fe7d8bdf5a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/input/MANIFEST.json @@ -0,0 +1,51 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "hot-nimbus-psm_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "nested-pps_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "nested-psm_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "mount_iso_script.sh", + "type": "SHELL" + }, + { + "file": "cloud-nimbus.sh", + "type": "SHELL" + }, + { + "file": "nimbus-ethernet", + "type": "OTHER" + }, + { + "file": "nimbus-ethernet-gw", + "type": "OTHER" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/input/hot-nimbus-pps_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/input/hot-nimbus-pps_v1.0.env new file mode 100644 index 0000000000..a1ea053e07 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/input/hot-nimbus-pps_v1.0.env @@ -0,0 +1,11 @@ +parameters: + pcrf_pps_server_names: ZRDM1PCRF01PPS001,ZRDM1PCRF01PPS002,ZRDM1PCRF01PPS003,ZRDM1PCRF01PPS004,ZRDM1PCRF01PPS005,ZRDM1PCRF01PPS006 + pcrf_pps_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pps_flavor_name: lc.3xlarge + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.7,172.26.16.8,172.26.16.9,172.26.16.10,172.26.16.11,172.26.16.12 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..b12de0def4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,144 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_pps_001: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_002: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 1] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_003: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 2] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_004: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 3] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_005: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 4] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_006: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 5] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + nova_server: + type: OS::Nova::Server + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 5] } + image: { get_param: pcrf_pps_image_name } + flavor: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + scheduler_hints: { group_1: { get_resource: BE_Affinity_1 }, group_2: { get_resource: BE_Affinity_2 } } + + BE_Affinity_1: + type: OS::Nova::ServerGroup + properties: + network: { get_param: pcrf_pps_server_names } + + BE_Affinity_2: + type: OS::Nova::ServerGroup + properties: + network: { get_param: pcrf_pps_server_names } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/input/hot-nimbus-psm_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/input/hot-nimbus-psm_v1.0.env new file mode 100644 index 0000000000..f24e4763c6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/input/hot-nimbus-psm_v1.0.env @@ -0,0 +1,10 @@ +parameters: + pcrf_psm_server_names: ZRDM1PCRF01PSM001,ZRDM1PCRF01PSM002,ZRDM1PCRF01PSM003,ZRDM1PCRF01PSM004,ZRDM1PCRF01PSM005,ZRDM1PCRF01PSM006,ZRDM1PCRF01PSM007,ZRDM1PCRF01PSM008,ZRDM1PCRF01PSM009,ZRDM1PCRF01PSM010,ZRDM1PCRF01PSM011,ZRDM1PCRF01PSM012 + pcrf_psm_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_psm_flavor_name: lc.4xlarge4 + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.63,172.26.16.64,172.26.16.65,172.26.16.66,172.26.16.67,172.26.16.68,172.26.16.69,172.26.16.70,172.26.16.71,172.26.16.72,172.26.16.73,172.26.16.74 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/input/hot-nimbus-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/input/hot-nimbus-psm_v1.0.yaml new file mode 100644 index 0000000000..3f91e94d74 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/input/hot-nimbus-psm_v1.0.yaml @@ -0,0 +1,288 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + num_instances: + type: comma_delimited_list + label: PCRF SM server names + description: name of the PCRF SM instance + pcrf_psm_server_names: + type: comma_delimited_list + label: PCRF SM server names + description: name of the PCRF SM instance + pcrf_psm_image_name: + type: string + label: PCRF SM image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_psm_001: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 0] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_002: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 1] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_003: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 2] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_004: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 3] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_005: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 4] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_006: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 5] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_007: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 6] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 6] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_008: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 7] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 7] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_009: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 8] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 8] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_010: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 9] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 9] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_011: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 10] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 10] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_012: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 11] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 11] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + resource_with_resources_group: + type: OS::Heat::ResourceGroup + properties: + count: { get_param: num_instances } + resource_def: + type: nested-from-resources-group.yaml + properties: + cloud_zone_id: { get_param: cloud_zone_id } + vf_name: { get_param: vf_name } + vf_instance_num: { get_param: vf_instance_num } + vf_component: { get_param: vf_component } + vm_instance_num: { get_param: vm_instance_num } + vnf_id: { get_param: vnf_id } + vf_module_id: { get_param: vf_module_id } + bootimage: { get_param: bootimage } + flavor: { get_param: flavor } + key_name: { get_param: key_name } + + availability_zone_0: { get_param: availability_zone_0 } + + sec_groups: { get_param: sec_groups } + data_volume_size: { get_param: data_volume_size } + mgmt_net_id: { get_param: mgmt_net_id } + + sas_mgmt_ip_0: { get_param: sas_mgmt_ip_0 } + + indx: "%index%" + + + resource_without_resources_group: + type: OS::Heat::ResourceGroup + properties: + count: { get_param: num_instances } + resource_def: + type: OS::Nova::Server + properties: + cloud_zone_id: { get_param: cloud_zone_id } + vf_name: { get_param: vf_name } + vf_instance_num: { get_param: vf_instance_num } + vf_component: { get_param: vf_component } + vm_instance_num: { get_param: vm_instance_num } + vnf_id: { get_param: vnf_id } + vf_module_id: { get_param: vf_module_id } + bootimage: { get_param: bootimage } + flavor: { get_param: flavor } + key_name: { get_param: key_name } + + availability_zone_0: { get_param: availability_zone_0 } + + sec_groups: { get_param: sec_groups } + data_volume_size: { get_param: data_volume_size } + mgmt_net_id: { get_param: mgmt_net_id } + + sas_mgmt_ip_0: { get_param: sas_mgmt_ip_0 } + + indx: "%index%" + + resource_with_not_existing_resources_group: + type: OS::Heat::ResourceGroup + properties: + count: { get_param: num_instances } + resource_def: + type: nested-from-resources-group.yaml + properties: + cloud_zone_id: { get_param: cloud_zone_id } + vf_name: { get_param: vf_name } + vf_instance_num: { get_param: vf_instance_num } + vf_component: { get_param: vf_component } + vm_instance_num: { get_param: vm_instance_num } + vnf_id: { get_param: vnf_id } + vf_module_id: { get_param: vf_module_id } + bootimage: { get_param: bootimage } + flavor: { get_param: flavor } + key_name: { get_param: key_name } + + availability_zone_0: { get_param: availability_zone_0 } + + sec_groups: { get_param: sec_groups } + data_volume_size: { get_param: data_volume_size } + mgmt_net_id: { get_param: mgmt_net_id } + + sas_mgmt_ip_0: { get_param: sas_mgmt_ip_0 } + + indx: "%index%" + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/input/nested-from-resources-group.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/input/nested-from-resources-group.yaml new file mode 100644 index 0000000000..6868728b73 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/input/nested-from-resources-group.yaml @@ -0,0 +1,97 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_name: + type: string + label: PCRF SM server name + description: PCRF SM server name + pcrf_psm_image_name: + type: string + label: image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + params: + $vm_name: { get_param: pcrf_psm_server_name } + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_psm: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_psm_server_name } + image: { get_param: pcrf_psm_image_name } + flavor: { get_param: pcrf_psm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: psm01_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + #scheduler_hints: {group: { get_resource: servergroup_nimbus }} + + psm01_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/input/nested-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/input/nested-pps_v1.0.yaml new file mode 100644 index 0000000000..b7291d69d3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/input/nested-pps_v1.0.yaml @@ -0,0 +1,97 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_name: + type: string + label: PCRF PS server name + description: PCRF PS server name + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + params: + $vm_name: { get_param: pcrf_pps_server_name } + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_pps: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_pps_server_name } + image: { get_param: pcrf_pps_image_name } + flavor: { get_param: pcrf_pps_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcrf_pps_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + + pcrf_pps_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/input/nested-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/input/nested-psm_v1.0.yaml new file mode 100644 index 0000000000..6868728b73 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/resources_group_with_nested/positive_test/input/nested-psm_v1.0.yaml @@ -0,0 +1,97 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_name: + type: string + label: PCRF SM server name + description: PCRF SM server name + pcrf_psm_image_name: + type: string + label: image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + params: + $vm_name: { get_param: pcrf_psm_server_name } + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_psm: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_psm_server_name } + image: { get_param: pcrf_psm_image_name } + flavor: { get_param: pcrf_psm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: psm01_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + #scheduler_hints: {group: { get_resource: servergroup_nimbus }} + + psm01_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/security_group_base_file_no_ports/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/security_group_base_file_no_ports/input/MANIFEST.json new file mode 100644 index 0000000000..f487bae31f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/security_group_base_file_no_ports/input/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "baseFile.yaml", + "type": "HEAT", + "isBase": true + }, + { + "file": "notBaseFile.yaml", + "type": "HEAT", + "isBase": false + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/security_group_base_file_no_ports/input/baseFile.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/security_group_base_file_no_ports/input/baseFile.yaml new file mode 100644 index 0000000000..9446d6fde0 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/security_group_base_file_no_ports/input/baseFile.yaml @@ -0,0 +1,43 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + jsa_net_name: + type: string + description: network name of jsa log network + security_group_name: + type: string + label: security group name + description: the name of security group + +resources: + jsa_security_group1: + type: OS::Neutron::SecurityGroup + properties: + description: ems security group + name: {get_param: security_group_name} + + + jsa_security_group2: + type: OS::Neutron::SecurityGroup + properties: + description: ems security group + name: {get_param: security_group_name} + + jsa_security_group3: + type: OS::Neutron::SecurityGroup + properties: + description: ems security group + name: {get_param: security_group_name} + +outputs: + shared_security_group_id1: + value: {get_resource: jsa_security_group1} + + shared_security_group_id2: + value: {get_resource: jsa_security_group2} + + shared_security_group_id3: + value: {get_resource: jsa_security_group3} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/security_group_base_file_no_ports/input/notBaseFile.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/security_group_base_file_no_ports/input/notBaseFile.yaml new file mode 100644 index 0000000000..7ac05194ac --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/security_group_base_file_no_ports/input/notBaseFile.yaml @@ -0,0 +1,26 @@ +heat_template_version: 2013-05-23 + +description: > + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + +parameters: + shared_security_group_id1: + type: string + description: network name of jsa log network + shared_security_group_id2: + type: string + description: network name of jsa log network + jsa_net_name: + type: string + description: network name of jsa log network + security_group_name: + type: string + label: security group name + description: the name of security group + +resources: + test_nested: + type: OS::Contrail::NetworkIpam + properties: + p1: { get_param: shared_security_group_id1} + p2: { get_param: shared_security_group_id2} diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/security_group_called_by_port/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/security_group_called_by_port/input/MANIFEST.json new file mode 100644 index 0000000000..1e719efb31 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/security_group_called_by_port/input/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.env", + "type": "HEAT_ENV" + } + ] + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/security_group_called_by_port/input/hot-nimbus-pps_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/security_group_called_by_port/input/hot-nimbus-pps_v1.0.env new file mode 100644 index 0000000000..340be2b815 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/security_group_called_by_port/input/hot-nimbus-pps_v1.0.env @@ -0,0 +1,11 @@ +parameters: + pcrf_pps_server_names: ZRDM1PCRF01PPS001,ZRDM1PCRF01PPS002,ZRDM1PCRF01PPS003,ZRDM1PCRF01PPS004,ZRDM1PCRF01PPS005,ZRDM1PCRF01PPS006 + pcrf_pps_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pps_flavor_name: lc.3xlarge + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.7,172.26.16.8,172.26.16.9,172.26.16.10,172.26.16.11,172.26.16.12 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/security_group_called_by_port/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/security_group_called_by_port/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..51b9481bfa --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/security_group_called_by_port/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,68 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + used_security_group: + type: OS::Neutron::SecurityGroup + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + + not_used_security_group: + type: OS::Neutron::SecurityGroup + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + + server_pcrf_network: + type: OS::Contrail::VirtualNetwork + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + + attach_policy_resource: + type: OS::Neutron::Port + properties: + security_groups: [{ get_resource: used_security_group }] + + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_group_called_by_nova_server/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_group_called_by_nova_server/input/MANIFEST.json new file mode 100644 index 0000000000..1e719efb31 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_group_called_by_nova_server/input/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.env", + "type": "HEAT_ENV" + } + ] + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_group_called_by_nova_server/input/hot-nimbus-pps_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_group_called_by_nova_server/input/hot-nimbus-pps_v1.0.env new file mode 100644 index 0000000000..340be2b815 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_group_called_by_nova_server/input/hot-nimbus-pps_v1.0.env @@ -0,0 +1,11 @@ +parameters: + pcrf_pps_server_names: ZRDM1PCRF01PPS001,ZRDM1PCRF01PPS002,ZRDM1PCRF01PPS003,ZRDM1PCRF01PPS004,ZRDM1PCRF01PPS005,ZRDM1PCRF01PPS006 + pcrf_pps_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pps_flavor_name: lc.3xlarge + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.7,172.26.16.8,172.26.16.9,172.26.16.10,172.26.16.11,172.26.16.12 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_group_called_by_nova_server/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_group_called_by_nova_server/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..63eea76e2e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_group_called_by_nova_server/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,67 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + image_name: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + used_server_group: + type: OS::Nova::ServerGroup + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + + not_used_server_group: + type: OS::Nova::ServerGroup + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + + nova_server: + type: OS::Nova::Server + properties: + scheduler_hints: { group: { get_resource: used_server_group } } + image: {get_param: image_name} + + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/negative_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/negative_test/input/MANIFEST.json new file mode 100644 index 0000000000..1e719efb31 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/negative_test/input/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.env", + "type": "HEAT_ENV" + } + ] + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/negative_test/input/hot-nimbus-pps_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/negative_test/input/hot-nimbus-pps_v1.0.env new file mode 100644 index 0000000000..340be2b815 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/negative_test/input/hot-nimbus-pps_v1.0.env @@ -0,0 +1,11 @@ +parameters: + pcrf_pps_server_names: ZRDM1PCRF01PPS001,ZRDM1PCRF01PPS002,ZRDM1PCRF01PPS003,ZRDM1PCRF01PPS004,ZRDM1PCRF01PPS005,ZRDM1PCRF01PPS006 + pcrf_pps_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pps_flavor_name: lc.3xlarge + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.7,172.26.16.8,172.26.16.9,172.26.16.10,172.26.16.11,172.26.16.12 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/negative_test/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/negative_test/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..1955922940 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/negative_test/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,70 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + nova_server_1: + type: OS::Nova::Server + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 5] } + image: { get_param: pcrf_pps_image_name } + flavor: { get_param: pcrf_pps_flavor_name } + scheduler_hints: { group_1: { get_resource: BE_Affinity_1 }, group_2: { get_resource: BE_Affinity_2 } } + networks: + - port: {get_resource: BE_Affinity_2} + + + nova_server_2: + type: OS::Nova::Server + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 5] } + image: { get_param: pcrf_pps_image_name } + flavor: { get_param: pcrf_pps_flavor_name } + scheduler_hints: { group_1: , group_2: { get_resource: BE_Affinity_2 } } + + BE_Affinity_2: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_pps_server_names } + + + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/positive_test/expected_output/expected_output.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/positive_test/expected_output/expected_output.json new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/positive_test/expected_output/expected_output.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/positive_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/positive_test/input/MANIFEST.json new file mode 100644 index 0000000000..fe7d8bdf5a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/positive_test/input/MANIFEST.json @@ -0,0 +1,51 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "hot-nimbus-psm_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "nested-pps_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "nested-psm_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "mount_iso_script.sh", + "type": "SHELL" + }, + { + "file": "cloud-nimbus.sh", + "type": "SHELL" + }, + { + "file": "nimbus-ethernet", + "type": "OTHER" + }, + { + "file": "nimbus-ethernet-gw", + "type": "OTHER" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/positive_test/input/hot-nimbus-pps_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/positive_test/input/hot-nimbus-pps_v1.0.env new file mode 100644 index 0000000000..a1ea053e07 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/positive_test/input/hot-nimbus-pps_v1.0.env @@ -0,0 +1,11 @@ +parameters: + pcrf_pps_server_names: ZRDM1PCRF01PPS001,ZRDM1PCRF01PPS002,ZRDM1PCRF01PPS003,ZRDM1PCRF01PPS004,ZRDM1PCRF01PPS005,ZRDM1PCRF01PPS006 + pcrf_pps_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pps_flavor_name: lc.3xlarge + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.7,172.26.16.8,172.26.16.9,172.26.16.10,172.26.16.11,172.26.16.12 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/positive_test/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/positive_test/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..b12de0def4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/positive_test/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,144 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_pps_001: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_002: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 1] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_003: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 2] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_004: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 3] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_005: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 4] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_006: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 5] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + nova_server: + type: OS::Nova::Server + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 5] } + image: { get_param: pcrf_pps_image_name } + flavor: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + scheduler_hints: { group_1: { get_resource: BE_Affinity_1 }, group_2: { get_resource: BE_Affinity_2 } } + + BE_Affinity_1: + type: OS::Nova::ServerGroup + properties: + network: { get_param: pcrf_pps_server_names } + + BE_Affinity_2: + type: OS::Nova::ServerGroup + properties: + network: { get_param: pcrf_pps_server_names } \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/positive_test/input/hot-nimbus-psm_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/positive_test/input/hot-nimbus-psm_v1.0.env new file mode 100644 index 0000000000..f24e4763c6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/positive_test/input/hot-nimbus-psm_v1.0.env @@ -0,0 +1,10 @@ +parameters: + pcrf_psm_server_names: ZRDM1PCRF01PSM001,ZRDM1PCRF01PSM002,ZRDM1PCRF01PSM003,ZRDM1PCRF01PSM004,ZRDM1PCRF01PSM005,ZRDM1PCRF01PSM006,ZRDM1PCRF01PSM007,ZRDM1PCRF01PSM008,ZRDM1PCRF01PSM009,ZRDM1PCRF01PSM010,ZRDM1PCRF01PSM011,ZRDM1PCRF01PSM012 + pcrf_psm_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_psm_flavor_name: lc.4xlarge4 + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.63,172.26.16.64,172.26.16.65,172.26.16.66,172.26.16.67,172.26.16.68,172.26.16.69,172.26.16.70,172.26.16.71,172.26.16.72,172.26.16.73,172.26.16.74 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/positive_test/input/hot-nimbus-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/positive_test/input/hot-nimbus-psm_v1.0.yaml new file mode 100644 index 0000000000..c2d7b05ead --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/positive_test/input/hot-nimbus-psm_v1.0.yaml @@ -0,0 +1,199 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_names: + type: comma_delimited_list + label: PCRF SM server names + description: name of the PCRF SM instance + pcrf_psm_image_name: + type: string + label: PCRF SM image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_psm_001: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 0] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_002: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 1] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_003: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 2] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_004: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 3] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_005: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 4] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_006: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 5] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_007: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 6] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 6] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_008: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 7] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 7] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_009: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 8] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 8] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_010: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 9] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 9] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_011: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 10] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 10] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_012: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 11] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 11] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/positive_test/input/nested-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/positive_test/input/nested-pps_v1.0.yaml new file mode 100644 index 0000000000..b7291d69d3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/positive_test/input/nested-pps_v1.0.yaml @@ -0,0 +1,97 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_name: + type: string + label: PCRF PS server name + description: PCRF PS server name + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + params: + $vm_name: { get_param: pcrf_pps_server_name } + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_pps: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_pps_server_name } + image: { get_param: pcrf_pps_image_name } + flavor: { get_param: pcrf_pps_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcrf_pps_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + + pcrf_pps_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/positive_test/input/nested-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/positive_test/input/nested-psm_v1.0.yaml new file mode 100644 index 0000000000..6868728b73 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/server_groups_defined_correctly/positive_test/input/nested-psm_v1.0.yaml @@ -0,0 +1,97 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_name: + type: string + label: PCRF SM server name + description: PCRF SM server name + pcrf_psm_image_name: + type: string + label: image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + params: + $vm_name: { get_param: pcrf_psm_server_name } + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_psm: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_psm_server_name } + image: { get_param: pcrf_psm_image_name } + flavor: { get_param: pcrf_psm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: psm01_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + #scheduler_hints: {group: { get_resource: servergroup_nimbus }} + + psm01_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/shared_resources/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/shared_resources/input/MANIFEST.json new file mode 100644 index 0000000000..1e719efb31 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/shared_resources/input/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.env", + "type": "HEAT_ENV" + } + ] + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/shared_resources/input/hot-nimbus-pps_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/shared_resources/input/hot-nimbus-pps_v1.0.env new file mode 100644 index 0000000000..340be2b815 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/shared_resources/input/hot-nimbus-pps_v1.0.env @@ -0,0 +1,11 @@ +parameters: + pcrf_pps_server_names: ZRDM1PCRF01PPS001,ZRDM1PCRF01PPS002,ZRDM1PCRF01PPS003,ZRDM1PCRF01PPS004,ZRDM1PCRF01PPS005,ZRDM1PCRF01PPS006 + pcrf_pps_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pps_flavor_name: lc.3xlarge + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.7,172.26.16.8,172.26.16.9,172.26.16.10,172.26.16.11,172.26.16.12 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/shared_resources/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/shared_resources/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..1114734097 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/shared_resources/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,90 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + used_security_group: + type: OS::Neutron::SecurityGroup + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + + not_used_security_group: + type: OS::Neutron::SecurityGroup + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + + shared_security_group: + type: OS::Neutron::SecurityGroup + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + + shared_server_group: + type: OS::Nova::ServerGroup + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + + server_pcrf_network: + type: OS::Contrail::VirtualNetwork + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + + attach_policy_resource: + type: OS::Neutron::Port + properties: + security_groups: [{ get_resource: used_security_group }] + + +outputs: + output_shrared_resource_1: + description: uuid of the security group + value: {get_resource: shared_security_group } + + output_shrared_resource_2: + description: uuid of the security group + value: {get_resource: shared_server_group } + + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/negative_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/negative_test/input/MANIFEST.json new file mode 100644 index 0000000000..06df1e696d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/negative_test/input/MANIFEST.json @@ -0,0 +1,35 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-pps_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "hot-nimbus-psm_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "nested-pps_v1.0.yaml", + "type": "HEAT" + }, + { + "file": "nested-psm_v1.0.yaml", + "type": "HEAT" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/negative_test/input/hot-nimbus-pps_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/negative_test/input/hot-nimbus-pps_v1.0.env new file mode 100644 index 0000000000..340be2b815 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/negative_test/input/hot-nimbus-pps_v1.0.env @@ -0,0 +1,11 @@ +parameters: + pcrf_pps_server_names: ZRDM1PCRF01PPS001,ZRDM1PCRF01PPS002,ZRDM1PCRF01PPS003,ZRDM1PCRF01PPS004,ZRDM1PCRF01PPS005,ZRDM1PCRF01PPS006 + pcrf_pps_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_pps_flavor_name: lc.3xlarge + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.7,172.26.16.8,172.26.16.9,172.26.16.10,172.26.16.11,172.26.16.12 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/negative_test/input/hot-nimbus-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/negative_test/input/hot-nimbus-pps_v1.0.yaml new file mode 100644 index 0000000000..717b915c68 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/negative_test/input/hot-nimbus-pps_v1.0.yaml @@ -0,0 +1,125 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_server_names: + type: comma_delimited_list + label: PCRF PS server names + description: PCRF PS server names + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_pps_001: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 0] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_002: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 1] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_003: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 2] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_004: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 3] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_005: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 4] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_pps_006: + type: nested-pps_v1.0.yaml + properties: + pcrf_pps_server_name: { get_param: [pcrf_pps_server_names, 5] } + pcrf_pps_image_name: { get_param: pcrf_pps_image_name } + pcrf_pps_flavor_name: { get_param: pcrf_pps_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/negative_test/input/hot-nimbus-psm_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/negative_test/input/hot-nimbus-psm_v1.0.env new file mode 100644 index 0000000000..f24e4763c6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/negative_test/input/hot-nimbus-psm_v1.0.env @@ -0,0 +1,10 @@ +parameters: + pcrf_psm_server_names: ZRDM1PCRF01PSM001,ZRDM1PCRF01PSM002,ZRDM1PCRF01PSM003,ZRDM1PCRF01PSM004,ZRDM1PCRF01PSM005,ZRDM1PCRF01PSM006,ZRDM1PCRF01PSM007,ZRDM1PCRF01PSM008,ZRDM1PCRF01PSM009,ZRDM1PCRF01PSM010,ZRDM1PCRF01PSM011,ZRDM1PCRF01PSM012 + pcrf_psm_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_psm_flavor_name: lc.4xlarge4 + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.63,172.26.16.64,172.26.16.65,172.26.16.66,172.26.16.67,172.26.16.68,172.26.16.69,172.26.16.70,172.26.16.71,172.26.16.72,172.26.16.73,172.26.16.74 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/negative_test/input/hot-nimbus-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/negative_test/input/hot-nimbus-psm_v1.0.yaml new file mode 100644 index 0000000000..de8d6b7658 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/negative_test/input/hot-nimbus-psm_v1.0.yaml @@ -0,0 +1,207 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_names: + type: comma_delimited_list + label: PCRF SM server names + description: name of the PCRF SM instance + pcrf_psm_image_name: + type: string + label: PCRF SM image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + pcrf_vnf_id: + type: number + label: PCRF id number + description: PCRF id number + +resources: + server_pcrf_psm_001: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 0] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 0] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_002: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 1] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 1] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_003: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 2] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 2] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_004: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 3] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 3] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_005: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 4] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 4] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_006: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 5] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 5] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_007: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 6] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 6] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_008: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 7] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 7] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_009: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 8] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 8] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_010: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 9] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 9] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_011: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 10] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 10] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + + server_pcrf_psm_012: + type: nested-psm_v1.0.yaml + properties: + pcrf_psm_server_name: { get_param: [pcrf_psm_server_names, 11] } + pcrf_psm_image_name: { get_param: pcrf_psm_image_name } + pcrf_psm_flavor_name: { get_param: pcrf_psm_flavor_name } + availabilityzone_name: { get_param: availabilityzone_name } + pcrf_security_group_name: { get_param: pcrf_security_group_name } + pcrf_cps_net_name: { get_param: pcrf_cps_net_name } + pcrf_cps_net_ip: { get_param: [pcrf_cps_net_ips, 11] } + pcrf_cps_net_mask: { get_param: pcrf_cps_net_mask } + pcrf_vnf_id: {get_param: pcrf_vnf_id} + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/negative_test/input/nested-pps_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/negative_test/input/nested-pps_v1.0.yaml new file mode 100644 index 0000000000..153820b2c2 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/negative_test/input/nested-pps_v1.0.yaml @@ -0,0 +1,103 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Policy Server stack + +parameters: + pcrf_pps_server_name: + type: string + label: PCRF PS server name + description: PCRF PS server name + pcrf_pps_image_name: + type: string + label: PCRF PS image name + description: PCRF PS image name + pcrf_pps_flavor_name: + type: string + label: PCRF PS flavor name + description: flavor name of PCRF PS instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + template: { get_file: cloud-nimbus.sh } + params: + $vm_name: { get_param: pcrf_pps_server_name } + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet } + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_pps: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_pps_server_name } + image: { get_param: pcrf_pps_image_name } + flavor: { get_param: pcrf_pps_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: pcrf_pps_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + + pcrf_pps_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/negative_test/input/nested-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/negative_test/input/nested-psm_v1.0.yaml new file mode 100644 index 0000000000..f982cc9195 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/negative_test/input/nested-psm_v1.0.yaml @@ -0,0 +1,103 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_name: + type: string + label: PCRF SM server name + description: PCRF SM server name + pcrf_psm_server_name: + type: string + label: PCRF SM server name + description: PCRF SM server name + pcrf_psm_image_name: + type: string + label: image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ip: + type: string + label: CPS network ip + description: CPS network ip + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + network: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/ifcfg-eth0 + permissions: "0644" + content: + str_replace: + template: { get_file: nimbus-ethernet } + params: + $dev: eth0 + $ip: { get_param: pcrf_cps_net_ip } + $netmask: { get_param: pcrf_cps_net_mask } + runcmd: + - ifdown eth0 && ifup eth0 + script_init: + type: OS::Heat::SoftwareConfig + properties: + group: ungrouped + config: + str_replace: + template: { get_file: cloud-nimbus.sh } + params: + $vm_name: { get_param: pcrf_psm_server_name } + pcrf_server_init: + type: OS::Heat::MultipartMime + properties: + parts: + - config: { get_resource: network} + - config: { get_resource: script_init} + + pcrf_server_psm: + type: OS::Nova::Server + properties: + config_drive: "True" + name: { get_param: pcrf_psm_server_name } + image: { get_param: pcrf_psm_image_name } + flavor: { get_param: pcrf_psm_flavor_name } + availability_zone: { get_param: availabilityzone_name } + networks: + - port: { get_resource: psm01_port_0} + user_data_format: RAW + user_data: + get_resource: pcrf_server_init + metadata: + vnf_id: {get_param: pcrf_vnf_id} + #scheduler_hints: {group: { get_resource: servergroup_nimbus }} + + psm01_port_0: + type: OS::Neutron::Port + properties: + network: { get_param: pcrf_cps_net_name } + fixed_ips: + - ip_address: { get_param: pcrf_cps_net_ip } + security_groups: [{ get_param: pcrf_security_group_name }] \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/positive_test/expected_output/expected_output.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/positive_test/expected_output/expected_output.json new file mode 100644 index 0000000000..9e26dfeeb6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/positive_test/expected_output/expected_output.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/positive_test/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/positive_test/input/MANIFEST.json new file mode 100644 index 0000000000..dd26e5ac45 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/positive_test/input/MANIFEST.json @@ -0,0 +1,17 @@ +{ + "name": "hot-mog", + "description": "HOT template to create hot mog server", + "version": "2013-05-23", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-psm_v1.0.env", + "type": "HEAT_ENV" + } + ] + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/positive_test/input/hot-nimbus-psm_v1.0.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/positive_test/input/hot-nimbus-psm_v1.0.env new file mode 100644 index 0000000000..f24e4763c6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/positive_test/input/hot-nimbus-psm_v1.0.env @@ -0,0 +1,10 @@ +parameters: + pcrf_psm_server_names: ZRDM1PCRF01PSM001,ZRDM1PCRF01PSM002,ZRDM1PCRF01PSM003,ZRDM1PCRF01PSM004,ZRDM1PCRF01PSM005,ZRDM1PCRF01PSM006,ZRDM1PCRF01PSM007,ZRDM1PCRF01PSM008,ZRDM1PCRF01PSM009,ZRDM1PCRF01PSM010,ZRDM1PCRF01PSM011,ZRDM1PCRF01PSM012 + pcrf_psm_image_name: PCRF_8.995-ATTM1.0.3.qcow2 + pcrf_psm_flavor_name: lc.4xlarge4 + availabilityzone_name: nova + pcrf_cps_net_name: Mobisupport-25193-I-INT1_int_pcrf_net_0 + pcrf_cps_net_ips: 172.26.16.63,172.26.16.64,172.26.16.65,172.26.16.66,172.26.16.67,172.26.16.68,172.26.16.69,172.26.16.70,172.26.16.71,172.26.16.72,172.26.16.73,172.26.16.74 + pcrf_cps_net_mask: 255.255.255.0 + pcrf_security_group_name: nimbus_security_group + pcrf_vnf_id: 730797234b4a40aa99335157b02871cd diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/positive_test/input/hot-nimbus-psm_v1.0.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/positive_test/input/hot-nimbus-psm_v1.0.yaml new file mode 100644 index 0000000000..5e940bdd49 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/heat_validator/two_resources_does_not_hold_same_id/positive_test/input/hot-nimbus-psm_v1.0.yaml @@ -0,0 +1,50 @@ +heat_template_version: 2013-05-23 + +description: heat template that creates PCRF Session Manager stack + +parameters: + pcrf_psm_server_names: + type: comma_delimited_list + label: PCRF SM server names + description: name of the PCRF SM instance + pcrf_psm_image_name: + type: string + label: PCRF SM image name + description: PCRF SM image name + pcrf_psm_flavor_name: + type: string + label: PCRF SM flavor name + description: flavor name of PCRF SM instance + availabilityzone_name: + type: string + label: availabilityzone name + description: availabilityzone name + pcrf_cps_net_name: + type: string + label: CPS network name + description: CPS network name + pcrf_cps_net_ips: + type: comma_delimited_list + label: CPS network ips + description: CPS network ips + pcrf_cps_net_mask: + type: string + label: CPS network mask + description: CPS network mask + pcrf_security_group_name: + type: string + label: security group name + description: the name of security group + pcrf_vnf_id: + type: string + label: PCRF VNF Id + description: PCRF VNF Id + +resources: + server_pcrf_psm_001: + type: OS::Contrail::NetworkIpam + + server_pcrf_psm_002: + type: OS::Contrail::NetworkIpam + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/envInRoot/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/envInRoot/MANIFEST.json new file mode 100644 index 0000000000..5524f47fa8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/envInRoot/MANIFEST.json @@ -0,0 +1,22 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "data": [ + { + "file": "first.yaml", + "type": "HEAT", + "isBase": true, + "data": [ + { + "file": "first.env", + "type": "HEAT_ENV" + } + ] + }, + { + "file": "second.env", + "type": "HEAT_ENV" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/envInRoot/first.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/envInRoot/first.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/envInRoot/first.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/envInRoot/first.yaml new file mode 100644 index 0000000000..368834e847 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/envInRoot/first.yaml @@ -0,0 +1,14 @@ +heat_template_version: 2013-05-23 + +description: heat expose volume resource + +resources: + SecurityGroup_expose: + type: OS::Neutron::Net + +outputs: + not_expose_resource_network_output: + description: the pcrf_server + value: { get_param: ServerGroup_expose } + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/envInRoot/second.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/envInRoot/second.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/invalidFileTypeInManifest/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/invalidFileTypeInManifest/MANIFEST.json new file mode 100644 index 0000000000..de35dfc0db --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/invalidFileTypeInManifest/MANIFEST.json @@ -0,0 +1,24 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "data": [ + { + "file": "single.yaml.illegalSuffix", + "type": "HEAT", + "data": [ + { + "file": "single.env.illegalSuffix", + "type": "HEAT_ENV" + }, + { + "file": "singleVol.yaml.illegalSuffix", + "type": "HEAT_VOL" + } + ] + },{ + "file": "illegalTypeFile.yaml", + "type": "ILLEGAL_TYPE" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/invalidFileTypeInManifest/illegalTypeFile.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/invalidFileTypeInManifest/illegalTypeFile.yaml new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/invalidFileTypeInManifest/single.env.illegalSuffix b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/invalidFileTypeInManifest/single.env.illegalSuffix new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/invalidFileTypeInManifest/single.yaml.illegalSuffix b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/invalidFileTypeInManifest/single.yaml.illegalSuffix new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/invalidFileTypeInManifest/singleVol.yaml.illegalSuffix b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/invalidFileTypeInManifest/singleVol.yaml.illegalSuffix new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/invalidManifest/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/invalidManifest/MANIFEST.json new file mode 100644 index 0000000000..7b3dd77ed7 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/invalidManifest/MANIFEST.json @@ -0,0 +1,21 @@ +{ + "name": "inValidTest", + "description": "inValid Test", + "version": [{"v": "1.0"}], + "data": [ + { + "file": "single.yaml", + "type": "HEAT", + "data": [ + { + "file": "single.env", + "type": "HEAT_ENV" + }, + { + "file": "singleVol.yaml", + "type": "HEAT_VOL" + } + ] + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/invalidManifest/single.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/invalidManifest/single.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/invalidManifest/single.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/invalidManifest/single.yaml new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/invalidManifest/singleVol.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/invalidManifest/singleVol.yaml new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInManifest/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInManifest/MANIFEST.json new file mode 100644 index 0000000000..fd2b2c3f6d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInManifest/MANIFEST.json @@ -0,0 +1,22 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "invalidField":"value", + "data": [ + { + "file": "single.yaml", + "type": "HEAT", + "data": [ + { + "file": "single.env", + "type": "HEAT_ENV" + }, + { + "file": "singleVol.yaml", + "type": "HEAT_VOL" + } + ] + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInManifest/extraFile.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInManifest/extraFile.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInManifest/single.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInManifest/single.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInManifest/single.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInManifest/single.yaml new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInManifest/singleVol.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInManifest/singleVol.yaml new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInManifestAndInZip/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInManifestAndInZip/MANIFEST.json new file mode 100644 index 0000000000..60a8efe769 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInManifestAndInZip/MANIFEST.json @@ -0,0 +1,21 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "data": [ + { + "file": "single.yaml", + "type": "HEAT", + "data": [ + { + "file": "single.env", + "type": "HEAT_ENV" + }, + { + "file": "singleVol.yaml", + "type": "HEAT_VOL" + } + ] + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInManifestAndInZip/extraFile.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInManifestAndInZip/extraFile.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInManifestAndInZip/single.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInManifestAndInZip/single.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInManifestAndInZip/single.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInManifestAndInZip/single.yaml new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInZip/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInZip/MANIFEST.json new file mode 100644 index 0000000000..60a8efe769 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInZip/MANIFEST.json @@ -0,0 +1,21 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "data": [ + { + "file": "single.yaml", + "type": "HEAT", + "data": [ + { + "file": "single.env", + "type": "HEAT_ENV" + }, + { + "file": "singleVol.yaml", + "type": "HEAT_VOL" + } + ] + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInZip/single.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInZip/single.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInZip/single.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/missingFileInZip/single.yaml new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/validFiles/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/validFiles/MANIFEST.json new file mode 100644 index 0000000000..60a8efe769 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/validFiles/MANIFEST.json @@ -0,0 +1,21 @@ +{ + "name": "validTest", + "description": "Valid Test", + "version": "1610", + "data": [ + { + "file": "single.yaml", + "type": "HEAT", + "data": [ + { + "file": "single.env", + "type": "HEAT_ENV" + }, + { + "file": "singleVol.yaml", + "type": "HEAT_VOL" + } + ] + } + ] +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/validFiles/single.env b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/validFiles/single.env new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/validFiles/single.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/validFiles/single.yaml new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/validFiles/singleVol.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/manifestValidator/validFiles/singleVol.yaml new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/duplicateKey.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/duplicateKey.yaml new file mode 100644 index 0000000000..418cc59c71 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/duplicateKey.yaml @@ -0,0 +1,30 @@ +### Heat Template ### +description: Generated template +heat_template_version: 2013-05-23 +parameters: {} +resources: + Key_1_unique: + properties: + admin_state_up: true + name: name_notReleventForTest + shared: true + type: type_notReleventForTest + Key_2_not_unique: + properties: + admin_state_up: true + name: name_notReleventForTest + shared: true + type: type_notReleventForTest + Key_2_not_unique: + properties: + admin_state_up: true + name: name_notReleventForTest + shared: true + type: type_notReleventForTest + Key_3_unique: + properties: + admin_state_up: true + name: name_notReleventForTest + shared: true + type: type_notReleventForTest + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/emptyYaml.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/emptyYaml.yaml new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalidTabYamlStructure.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalidTabYamlStructure.yaml new file mode 100644 index 0000000000..9cc18cef35 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalidTabYamlStructure.yaml @@ -0,0 +1,24 @@ +### Heat Template ### +description: Generated template +heat_template_version: 2013-05-23 +parameters: {} +resources: + Key_1_unique: + properties: + admin_state_up: true + name: name_notReleventForTest + shared: true + type: type_notReleventForTest + Key_2_unique: + properties: + admin_state_up: true + name: name_notReleventForTest + shared: true + type: type_notReleventForTest + Key_3_unique: + properties: + admin_state_up: true + name: name_notReleventForTest + shared: true + type: type_notReleventForTest + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalidYamlStructure.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalidYamlStructure.yaml new file mode 100644 index 0000000000..65205e01f9 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalidYamlStructure.yaml @@ -0,0 +1,30 @@ +### Heat Template ### +description: Generated template +heat_template_version: 2013-05-23 +parameters: {} +resources: + Key_1_unique: + properties: + admin_state_up: true + name: name_notReleventForTest + - shared: true + type: type_notReleventForTest + Key_2_not_unique: + properties: + admin_state_up: true + name: name_notReleventForTest + shared: true + type: type_notReleventForTest + Key_2_not_unique: + properties: + admin_state_up: true + name: name_notReleventForTest + shared: true + type: type_notReleventForTest + Key_3_unique: + properties: + admin_state_up: true + name: name_notReleventForTest + shared: true + type: type_notReleventForTest + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_duplicate_key/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_duplicate_key/input/MANIFEST.json new file mode 100644 index 0000000000..a4065d0b68 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_duplicate_key/input/MANIFEST.json @@ -0,0 +1,39 @@ +{ + "data": [ + { + "file": "validHeat.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-oam_v1.0.env", + "type": "HEAT_ENV" + }, + { + "file": "hot-nimbus-oam-volumes_v1.0", + "type": "HEAT_VOL", + "data": [{ + "file": "hot-nimbus-oam-volumes_v1.0.env", + "type": "HEAT_ENV" + }] + } + ] + }, + { + "file": "mainValid.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-oam-networks_v1.0", + "type": "HEAT_NET" + } + ] + }, + { + "file": "missingHeatFromZip.yaml.yaml", + "type": "HEAT" + } + ], + "description": "RXAEmleoRDWLeWVvmXUJxDKCItgjkMEXuKJcUWyVUZrCUiMzZSyHPzhqLcJSIUNBzohsIGXLBIwstuVDEuFtxuLIwWgCCdjprtvzruHIUKdVnCyifJQUJjqSCoKKKyVaWFTFKzHNhTZNlZTYaMKGEpIMXOpIxSyTZZCgVsGkItQelBbFVrmCltTgkuppYMrEfvwqNBLVRSGCucNwliWFZUuXloXBiZaqtodZjyFpqBNqhlpcrARmMpvLiz", + "name": "FCTRQGcMevNngRDvECQYfiEXCYbGeAWRHdaGggLUgyOnssHAiU", + "version": "2013-05-23" +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_duplicate_key/input/heat_missing_from_manifast.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_duplicate_key/input/heat_missing_from_manifast.yaml new file mode 100644 index 0000000000..d5608abfb4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_duplicate_key/input/heat_missing_from_manifast.yaml @@ -0,0 +1,250 @@ +### Heat Template ### +description: Generated template +heat_template_version: 2013-05-23 +parameters: {} +resources: + network_0: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + network_1: + properties: + admin_state_up: true + name: NET_169 + shared: true + type: OS::Neutron::Net + network_2: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_3: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: OS::Neutron::Net + network_4: + properties: + admin_state_up: true + name: NET_169 + shared: true + type: OS::Neutron::Net + network_5: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_6: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: OS::Neutron::Net + network_7: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_8: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_9: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + security_group_0: + properties: + description: Default security group + name: _default + rules: + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + security_group_1: + properties: + description: Default security group + name: _default + rules: + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + subnet_0: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_9 + type: OS::Neutron::Subnet + subnet_1: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_0 + type: OS::Neutron::Subnet + subnet_2: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_8 + type: OS::Neutron::Subnet + subnet_3: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_2 + type: OS::Neutron::Subnet + subnet_4: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_5 + type: OS::Neutron::Subnet + subnet_5: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_6 + type: OS::Neutron::Subnet + subnet_6: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_3 + type: OS::Neutron::Subnet + subnet_7: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_1 + type: OS::Neutron::Subnet + subnet_8: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_4 + type: OS::Neutron::Subnet + subnet_9: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_7 + type: OS::Neutron::Subnet + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_duplicate_key/input/mainValid.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_duplicate_key/input/mainValid.yaml new file mode 100644 index 0000000000..318c8f1283 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_duplicate_key/input/mainValid.yaml @@ -0,0 +1,250 @@ +### Heat Template ### +description: Generated template +heat_template_version: 2013-05-23 +parameters: {} +resources: + network_0: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + network_1: + properties: + admin_state_up: true + name: NET_169 + shared: true + type: OS::Neutron::Net + network_2: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_3: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: missingNested.yaml + network_4: + properties: + admin_state_up: true + name: { get_file: missing-artifact } + shared: true + type: OS::Neutron::Net + network_5: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_6: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: OS::Neutron::Net + network_7: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_8: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_9: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + security_group_0: + properties: + description: Default security group + name: _default + rules: + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + security_group_1: + properties: + description: Default security group + name: _default + rules: + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + subnet_0: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_9 + type: OS::Neutron::Subnet + subnet_1: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_0 + type: OS::Neutron::Subnet + subnet_2: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_8 + type: OS::Neutron::Subnet + subnet_3: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_2 + type: OS::Neutron::Subnet + subnet_4: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_5 + type: OS::Neutron::Subnet + subnet_5: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_6 + type: OS::Neutron::Subnet + subnet_6: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_3 + type: OS::Neutron::Subnet + subnet_7: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_1 + type: OS::Neutron::Subnet + subnet_8: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_4 + type: OS::Neutron::Subnet + subnet_9: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_7 + type: OS::Neutron::Subnet + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_duplicate_key/input/validHeat.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_duplicate_key/input/validHeat.yaml new file mode 100644 index 0000000000..d5608abfb4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_duplicate_key/input/validHeat.yaml @@ -0,0 +1,250 @@ +### Heat Template ### +description: Generated template +heat_template_version: 2013-05-23 +parameters: {} +resources: + network_0: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + network_1: + properties: + admin_state_up: true + name: NET_169 + shared: true + type: OS::Neutron::Net + network_2: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_3: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: OS::Neutron::Net + network_4: + properties: + admin_state_up: true + name: NET_169 + shared: true + type: OS::Neutron::Net + network_5: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_6: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: OS::Neutron::Net + network_7: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_8: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_9: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + security_group_0: + properties: + description: Default security group + name: _default + rules: + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + security_group_1: + properties: + description: Default security group + name: _default + rules: + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + subnet_0: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_9 + type: OS::Neutron::Subnet + subnet_1: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_0 + type: OS::Neutron::Subnet + subnet_2: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_8 + type: OS::Neutron::Subnet + subnet_3: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_2 + type: OS::Neutron::Subnet + subnet_4: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_5 + type: OS::Neutron::Subnet + subnet_5: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_6 + type: OS::Neutron::Subnet + subnet_6: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_3 + type: OS::Neutron::Subnet + subnet_7: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_1 + type: OS::Neutron::Subnet + subnet_8: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_4 + type: OS::Neutron::Subnet + subnet_9: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_7 + type: OS::Neutron::Subnet + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/expected_output/expected_output.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/expected_output/expected_output.json new file mode 100644 index 0000000000..dedbeaf5db --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/expected_output/expected_output.json @@ -0,0 +1,46 @@ +{ + "invalid_duplicateKey.yaml": { + "errorMessageList": [ + { + "level": "ERROR", + "message": "Can\u0027t construct a java object for tag:yaml.org,2002:java.util.Map; exception\u003dwhile parsing MappingNode\n in \u0027string\u0027, line 6, column 3:\n network_0:\n ^\nduplicate key: network_0\n in \u0027string\u0027, line 26, column 1:\n \n ^\n\n in \u0027string\u0027, line 2, column 1:\n description: Generated template\n ^\n" + } + ] + }, + "invalid_empty.yml": { + "errorMessageList": [ + { + "level": "ERROR", + "message": "File:invalid_empty.yml is empty." + } + ] + }, + "MANIFEST.json": { + "errorMessageList": [] + }, + "invalid_yamlInXMLFormat.yaml": { + "errorMessageList": [ + { + "level": "ERROR", + "message": "Can\u0027t construct a java object for tag:yaml.org,2002:java.util.Map; exception\u003dNo single argument constructor found for interface java.util.Map\n in \u0027string\u0027, line 1, column 1:\n \u003cstart\u003e\n ^\n" + } + ] + }, + "expected_output.json": { + "errorMessageList": [] + }, + "invalid_additionalSpaceBeforeProperty.yaml": { + "errorMessageList": [ + { + "level": "ERROR", + "message": "while parsing a block mapping\n in \u0027string\u0027, line 7, column 5:\n properties:\n ^\nexpected \u003cblock end\u003e, but found BlockMappingStart\n in \u0027string\u0027, line 9, column 7:\n name: NET_167\n ^\n" + } + ] + }, + "validHeat.yaml": { + "errorMessageList": [] + }, + "heat_missing_from_manifast.yaml": { + "errorMessageList": [] + } +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/input/MANIFEST.json new file mode 100644 index 0000000000..a4065d0b68 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/input/MANIFEST.json @@ -0,0 +1,39 @@ +{ + "data": [ + { + "file": "validHeat.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-oam_v1.0.env", + "type": "HEAT_ENV" + }, + { + "file": "hot-nimbus-oam-volumes_v1.0", + "type": "HEAT_VOL", + "data": [{ + "file": "hot-nimbus-oam-volumes_v1.0.env", + "type": "HEAT_ENV" + }] + } + ] + }, + { + "file": "mainValid.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-oam-networks_v1.0", + "type": "HEAT_NET" + } + ] + }, + { + "file": "missingHeatFromZip.yaml.yaml", + "type": "HEAT" + } + ], + "description": "RXAEmleoRDWLeWVvmXUJxDKCItgjkMEXuKJcUWyVUZrCUiMzZSyHPzhqLcJSIUNBzohsIGXLBIwstuVDEuFtxuLIwWgCCdjprtvzruHIUKdVnCyifJQUJjqSCoKKKyVaWFTFKzHNhTZNlZTYaMKGEpIMXOpIxSyTZZCgVsGkItQelBbFVrmCltTgkuppYMrEfvwqNBLVRSGCucNwliWFZUuXloXBiZaqtodZjyFpqBNqhlpcrARmMpvLiz", + "name": "FCTRQGcMevNngRDvECQYfiEXCYbGeAWRHdaGggLUgyOnssHAiU", + "version": "2013-05-23" +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/input/heat_missing_from_manifast.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/input/heat_missing_from_manifast.yaml new file mode 100644 index 0000000000..d5608abfb4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/input/heat_missing_from_manifast.yaml @@ -0,0 +1,250 @@ +### Heat Template ### +description: Generated template +heat_template_version: 2013-05-23 +parameters: {} +resources: + network_0: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + network_1: + properties: + admin_state_up: true + name: NET_169 + shared: true + type: OS::Neutron::Net + network_2: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_3: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: OS::Neutron::Net + network_4: + properties: + admin_state_up: true + name: NET_169 + shared: true + type: OS::Neutron::Net + network_5: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_6: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: OS::Neutron::Net + network_7: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_8: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_9: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + security_group_0: + properties: + description: Default security group + name: _default + rules: + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + security_group_1: + properties: + description: Default security group + name: _default + rules: + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + subnet_0: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_9 + type: OS::Neutron::Subnet + subnet_1: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_0 + type: OS::Neutron::Subnet + subnet_2: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_8 + type: OS::Neutron::Subnet + subnet_3: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_2 + type: OS::Neutron::Subnet + subnet_4: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_5 + type: OS::Neutron::Subnet + subnet_5: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_6 + type: OS::Neutron::Subnet + subnet_6: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_3 + type: OS::Neutron::Subnet + subnet_7: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_1 + type: OS::Neutron::Subnet + subnet_8: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_4 + type: OS::Neutron::Subnet + subnet_9: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_7 + type: OS::Neutron::Subnet + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/input/invalidYamlTab.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/input/invalidYamlTab.yaml new file mode 100644 index 0000000000..042f301507 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/input/invalidYamlTab.yaml @@ -0,0 +1,250 @@ +### Heat Template ### +description: Generated template +heat_template_version: 2013-05-23 +parameters: {} +resources: + network_0: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + network_1: + properties: + admin_state_up: true + name: NET_169 + shared: true + type: OS::Neutron::Net + network_2: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_3: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: OS::Neutron::Net + network_4: + properties: + admin_state_up: true + name: NET_169 + shared: true + type: OS::Neutron::Net + network_5: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_6: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: OS::Neutron::Net + network_7: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_8: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_9: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + security_group_0: + properties: + description: Default security group + name: _default + rules: + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + security_group_1: + properties: + description: Default security group + name: _default + rules: + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + subnet_0: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_9 + type: OS::Neutron::Subnet + subnet_1: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_0 + type: OS::Neutron::Subnet + subnet_2: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_8 + type: OS::Neutron::Subnet + subnet_3: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_2 + type: OS::Neutron::Subnet + subnet_4: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_5 + type: OS::Neutron::Subnet + subnet_5: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_6 + type: OS::Neutron::Subnet + subnet_6: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_3 + type: OS::Neutron::Subnet + subnet_7: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_1 + type: OS::Neutron::Subnet + subnet_8: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_4 + type: OS::Neutron::Subnet + subnet_9: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_7 + type: OS::Neutron::Subnet + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/input/invalid_additionalSpaceBeforeProperty.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/input/invalid_additionalSpaceBeforeProperty.yaml new file mode 100644 index 0000000000..b47d7d32f4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/input/invalid_additionalSpaceBeforeProperty.yaml @@ -0,0 +1,250 @@ +### Heat Template ### +description: Generated template +heat_template_version: 2013-05-23 +parameters: {} +resources: + network_0: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + network_1: + properties: + admin_state_up: true + name: NET_169 + shared: true + type: OS::Neutron::Net + network_2: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_3: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: missingNested.yaml + network_4: + properties: + admin_state_up: true + name: { get_file: missing-artifact } + shared: true + type: OS::Neutron::Net + network_5: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_6: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: OS::Neutron::Net + network_7: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_8: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_9: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + security_group_0: + properties: + description: Default security group + name: _default + rules: + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + security_group_1: + properties: + description: Default security group + name: _default + rules: + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + subnet_0: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_9 + type: OS::Neutron::Subnet + subnet_1: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_0 + type: OS::Neutron::Subnet + subnet_2: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_8 + type: OS::Neutron::Subnet + subnet_3: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_2 + type: OS::Neutron::Subnet + subnet_4: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_5 + type: OS::Neutron::Subnet + subnet_5: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_6 + type: OS::Neutron::Subnet + subnet_6: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_3 + type: OS::Neutron::Subnet + subnet_7: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_1 + type: OS::Neutron::Subnet + subnet_8: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_4 + type: OS::Neutron::Subnet + subnet_9: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_7 + type: OS::Neutron::Subnet + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/input/invalid_duplicateKey.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/input/invalid_duplicateKey.yaml new file mode 100644 index 0000000000..2dc0c63941 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/input/invalid_duplicateKey.yaml @@ -0,0 +1,25 @@ +### Heat Template ### +description: Generated template +heat_template_version: 2013-05-23 +parameters: {} +resources: + network_0: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + network_0: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + network_1: + properties: + admin_state_up: true + name: NET_169 + shared: true + type: OS::Neutron::Net + + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/input/invalid_empty.yml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/input/invalid_empty.yml new file mode 100644 index 0000000000..e69de29bb2 diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/input/invalid_yamlInXMLFormat.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/input/invalid_yamlInXMLFormat.yaml new file mode 100644 index 0000000000..54626a9d62 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/input/invalid_yamlInXMLFormat.yaml @@ -0,0 +1,4 @@ + + dfdf + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/input/validHeat.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/input/validHeat.yaml new file mode 100644 index 0000000000..d5608abfb4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/invalid_valid_yaml_structure/input/validHeat.yaml @@ -0,0 +1,250 @@ +### Heat Template ### +description: Generated template +heat_template_version: 2013-05-23 +parameters: {} +resources: + network_0: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + network_1: + properties: + admin_state_up: true + name: NET_169 + shared: true + type: OS::Neutron::Net + network_2: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_3: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: OS::Neutron::Net + network_4: + properties: + admin_state_up: true + name: NET_169 + shared: true + type: OS::Neutron::Net + network_5: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_6: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: OS::Neutron::Net + network_7: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_8: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_9: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + security_group_0: + properties: + description: Default security group + name: _default + rules: + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + security_group_1: + properties: + description: Default security group + name: _default + rules: + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + subnet_0: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_9 + type: OS::Neutron::Subnet + subnet_1: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_0 + type: OS::Neutron::Subnet + subnet_2: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_8 + type: OS::Neutron::Subnet + subnet_3: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_2 + type: OS::Neutron::Subnet + subnet_4: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_5 + type: OS::Neutron::Subnet + subnet_5: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_6 + type: OS::Neutron::Subnet + subnet_6: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_3 + type: OS::Neutron::Subnet + subnet_7: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_1 + type: OS::Neutron::Subnet + subnet_8: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_4 + type: OS::Neutron::Subnet + subnet_9: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_7 + type: OS::Neutron::Subnet + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/valid_yaml/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/valid_yaml/input/MANIFEST.json new file mode 100644 index 0000000000..a4065d0b68 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/valid_yaml/input/MANIFEST.json @@ -0,0 +1,39 @@ +{ + "data": [ + { + "file": "validHeat.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-oam_v1.0.env", + "type": "HEAT_ENV" + }, + { + "file": "hot-nimbus-oam-volumes_v1.0", + "type": "HEAT_VOL", + "data": [{ + "file": "hot-nimbus-oam-volumes_v1.0.env", + "type": "HEAT_ENV" + }] + } + ] + }, + { + "file": "mainValid.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-oam-networks_v1.0", + "type": "HEAT_NET" + } + ] + }, + { + "file": "missingHeatFromZip.yaml.yaml", + "type": "HEAT" + } + ], + "description": "RXAEmleoRDWLeWVvmXUJxDKCItgjkMEXuKJcUWyVUZrCUiMzZSyHPzhqLcJSIUNBzohsIGXLBIwstuVDEuFtxuLIwWgCCdjprtvzruHIUKdVnCyifJQUJjqSCoKKKyVaWFTFKzHNhTZNlZTYaMKGEpIMXOpIxSyTZZCgVsGkItQelBbFVrmCltTgkuppYMrEfvwqNBLVRSGCucNwliWFZUuXloXBiZaqtodZjyFpqBNqhlpcrARmMpvLiz", + "name": "FCTRQGcMevNngRDvECQYfiEXCYbGeAWRHdaGggLUgyOnssHAiU", + "version": "2013-05-23" +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/valid_yaml/input/heat_missing_from_manifast.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/valid_yaml/input/heat_missing_from_manifast.yaml new file mode 100644 index 0000000000..d5608abfb4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/valid_yaml/input/heat_missing_from_manifast.yaml @@ -0,0 +1,250 @@ +### Heat Template ### +description: Generated template +heat_template_version: 2013-05-23 +parameters: {} +resources: + network_0: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + network_1: + properties: + admin_state_up: true + name: NET_169 + shared: true + type: OS::Neutron::Net + network_2: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_3: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: OS::Neutron::Net + network_4: + properties: + admin_state_up: true + name: NET_169 + shared: true + type: OS::Neutron::Net + network_5: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_6: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: OS::Neutron::Net + network_7: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_8: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_9: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + security_group_0: + properties: + description: Default security group + name: _default + rules: + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + security_group_1: + properties: + description: Default security group + name: _default + rules: + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + subnet_0: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_9 + type: OS::Neutron::Subnet + subnet_1: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_0 + type: OS::Neutron::Subnet + subnet_2: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_8 + type: OS::Neutron::Subnet + subnet_3: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_2 + type: OS::Neutron::Subnet + subnet_4: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_5 + type: OS::Neutron::Subnet + subnet_5: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_6 + type: OS::Neutron::Subnet + subnet_6: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_3 + type: OS::Neutron::Subnet + subnet_7: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_1 + type: OS::Neutron::Subnet + subnet_8: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_4 + type: OS::Neutron::Subnet + subnet_9: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_7 + type: OS::Neutron::Subnet + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/valid_yaml/input/mainValid.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/valid_yaml/input/mainValid.yaml new file mode 100644 index 0000000000..318c8f1283 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/valid_yaml/input/mainValid.yaml @@ -0,0 +1,250 @@ +### Heat Template ### +description: Generated template +heat_template_version: 2013-05-23 +parameters: {} +resources: + network_0: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + network_1: + properties: + admin_state_up: true + name: NET_169 + shared: true + type: OS::Neutron::Net + network_2: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_3: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: missingNested.yaml + network_4: + properties: + admin_state_up: true + name: { get_file: missing-artifact } + shared: true + type: OS::Neutron::Net + network_5: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_6: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: OS::Neutron::Net + network_7: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_8: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_9: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + security_group_0: + properties: + description: Default security group + name: _default + rules: + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + security_group_1: + properties: + description: Default security group + name: _default + rules: + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + subnet_0: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_9 + type: OS::Neutron::Subnet + subnet_1: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_0 + type: OS::Neutron::Subnet + subnet_2: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_8 + type: OS::Neutron::Subnet + subnet_3: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_2 + type: OS::Neutron::Subnet + subnet_4: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_5 + type: OS::Neutron::Subnet + subnet_5: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_6 + type: OS::Neutron::Subnet + subnet_6: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_3 + type: OS::Neutron::Subnet + subnet_7: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_1 + type: OS::Neutron::Subnet + subnet_8: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_4 + type: OS::Neutron::Subnet + subnet_9: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_7 + type: OS::Neutron::Subnet + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/valid_yaml/input/validHeat.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/valid_yaml/input/validHeat.yaml new file mode 100644 index 0000000000..d5608abfb4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/openecomp/org/validation/validators/yaml_validator/valid_yaml/input/validHeat.yaml @@ -0,0 +1,250 @@ +### Heat Template ### +description: Generated template +heat_template_version: 2013-05-23 +parameters: {} +resources: + network_0: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + network_1: + properties: + admin_state_up: true + name: NET_169 + shared: true + type: OS::Neutron::Net + network_2: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_3: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: OS::Neutron::Net + network_4: + properties: + admin_state_up: true + name: NET_169 + shared: true + type: OS::Neutron::Net + network_5: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_6: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: OS::Neutron::Net + network_7: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_8: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_9: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + security_group_0: + properties: + description: Default security group + name: _default + rules: + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + security_group_1: + properties: + description: Default security group + name: _default + rules: + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + subnet_0: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_9 + type: OS::Neutron::Subnet + subnet_1: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_0 + type: OS::Neutron::Subnet + subnet_2: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_8 + type: OS::Neutron::Subnet + subnet_3: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_2 + type: OS::Neutron::Subnet + subnet_4: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_5 + type: OS::Neutron::Subnet + subnet_5: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_6 + type: OS::Neutron::Subnet + subnet_6: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_3 + type: OS::Neutron::Subnet + subnet_7: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_1 + type: OS::Neutron::Subnet + subnet_8: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_4 + type: OS::Neutron::Subnet + subnet_9: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_7 + type: OS::Neutron::Subnet + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/org/openecomp/validation/validators/yaml_validator/input/MANIFEST.json b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/org/openecomp/validation/validators/yaml_validator/input/MANIFEST.json new file mode 100644 index 0000000000..a4065d0b68 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/org/openecomp/validation/validators/yaml_validator/input/MANIFEST.json @@ -0,0 +1,39 @@ +{ + "data": [ + { + "file": "validHeat.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-oam_v1.0.env", + "type": "HEAT_ENV" + }, + { + "file": "hot-nimbus-oam-volumes_v1.0", + "type": "HEAT_VOL", + "data": [{ + "file": "hot-nimbus-oam-volumes_v1.0.env", + "type": "HEAT_ENV" + }] + } + ] + }, + { + "file": "mainValid.yaml", + "type": "HEAT", + "data": [ + { + "file": "hot-nimbus-oam-networks_v1.0", + "type": "HEAT_NET" + } + ] + }, + { + "file": "missingHeatFromZip.yaml.yaml", + "type": "HEAT" + } + ], + "description": "RXAEmleoRDWLeWVvmXUJxDKCItgjkMEXuKJcUWyVUZrCUiMzZSyHPzhqLcJSIUNBzohsIGXLBIwstuVDEuFtxuLIwWgCCdjprtvzruHIUKdVnCyifJQUJjqSCoKKKyVaWFTFKzHNhTZNlZTYaMKGEpIMXOpIxSyTZZCgVsGkItQelBbFVrmCltTgkuppYMrEfvwqNBLVRSGCucNwliWFZUuXloXBiZaqtodZjyFpqBNqhlpcrARmMpvLiz", + "name": "FCTRQGcMevNngRDvECQYfiEXCYbGeAWRHdaGggLUgyOnssHAiU", + "version": "2013-05-23" +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/org/openecomp/validation/validators/yaml_validator/input/heat_missing_from_manifast.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/org/openecomp/validation/validators/yaml_validator/input/heat_missing_from_manifast.yaml new file mode 100644 index 0000000000..d5608abfb4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/org/openecomp/validation/validators/yaml_validator/input/heat_missing_from_manifast.yaml @@ -0,0 +1,250 @@ +### Heat Template ### +description: Generated template +heat_template_version: 2013-05-23 +parameters: {} +resources: + network_0: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + network_1: + properties: + admin_state_up: true + name: NET_169 + shared: true + type: OS::Neutron::Net + network_2: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_3: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: OS::Neutron::Net + network_4: + properties: + admin_state_up: true + name: NET_169 + shared: true + type: OS::Neutron::Net + network_5: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_6: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: OS::Neutron::Net + network_7: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_8: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_9: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + security_group_0: + properties: + description: Default security group + name: _default + rules: + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + security_group_1: + properties: + description: Default security group + name: _default + rules: + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + subnet_0: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_9 + type: OS::Neutron::Subnet + subnet_1: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_0 + type: OS::Neutron::Subnet + subnet_2: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_8 + type: OS::Neutron::Subnet + subnet_3: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_2 + type: OS::Neutron::Subnet + subnet_4: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_5 + type: OS::Neutron::Subnet + subnet_5: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_6 + type: OS::Neutron::Subnet + subnet_6: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_3 + type: OS::Neutron::Subnet + subnet_7: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_1 + type: OS::Neutron::Subnet + subnet_8: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_4 + type: OS::Neutron::Subnet + subnet_9: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_7 + type: OS::Neutron::Subnet + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/org/openecomp/validation/validators/yaml_validator/input/mainValid.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/org/openecomp/validation/validators/yaml_validator/input/mainValid.yaml new file mode 100644 index 0000000000..318c8f1283 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/org/openecomp/validation/validators/yaml_validator/input/mainValid.yaml @@ -0,0 +1,250 @@ +### Heat Template ### +description: Generated template +heat_template_version: 2013-05-23 +parameters: {} +resources: + network_0: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + network_1: + properties: + admin_state_up: true + name: NET_169 + shared: true + type: OS::Neutron::Net + network_2: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_3: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: missingNested.yaml + network_4: + properties: + admin_state_up: true + name: { get_file: missing-artifact } + shared: true + type: OS::Neutron::Net + network_5: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_6: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: OS::Neutron::Net + network_7: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_8: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_9: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + security_group_0: + properties: + description: Default security group + name: _default + rules: + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + security_group_1: + properties: + description: Default security group + name: _default + rules: + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + subnet_0: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_9 + type: OS::Neutron::Subnet + subnet_1: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_0 + type: OS::Neutron::Subnet + subnet_2: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_8 + type: OS::Neutron::Subnet + subnet_3: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_2 + type: OS::Neutron::Subnet + subnet_4: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_5 + type: OS::Neutron::Subnet + subnet_5: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_6 + type: OS::Neutron::Subnet + subnet_6: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_3 + type: OS::Neutron::Subnet + subnet_7: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_1 + type: OS::Neutron::Subnet + subnet_8: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_4 + type: OS::Neutron::Subnet + subnet_9: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_7 + type: OS::Neutron::Subnet + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/org/openecomp/validation/validators/yaml_validator/input/validHeat.yaml b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/org/openecomp/validation/validators/yaml_validator/input/validHeat.yaml new file mode 100644 index 0000000000..d5608abfb4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-impl/src/test/resources/org/openecomp/validation/validators/yaml_validator/input/validHeat.yaml @@ -0,0 +1,250 @@ +### Heat Template ### +description: Generated template +heat_template_version: 2013-05-23 +parameters: {} +resources: + network_0: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + network_1: + properties: + admin_state_up: true + name: NET_169 + shared: true + type: OS::Neutron::Net + network_2: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_3: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: OS::Neutron::Net + network_4: + properties: + admin_state_up: true + name: NET_169 + shared: true + type: OS::Neutron::Net + network_5: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_6: + properties: + admin_state_up: true + name: NET_168 + shared: true + type: OS::Neutron::Net + network_7: + properties: + admin_state_up: true + name: NET_170 + shared: true + type: OS::Neutron::Net + network_8: + properties: + admin_state_up: true + name: NET_166 + shared: true + type: OS::Neutron::Net + network_9: + properties: + admin_state_up: true + name: NET_167 + shared: true + type: OS::Neutron::Net + security_group_0: + properties: + description: Default security group + name: _default + rules: + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + security_group_1: + properties: + description: Default security group + name: _default + rules: + - direction: egress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + - direction: ingress + ethertype: IPv4 + remote_ip_prefix: 0.0.0.0/0 + type: OS::Neutron::SecurityGroup + subnet_0: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_9 + type: OS::Neutron::Subnet + subnet_1: + properties: + allocation_pools: + - end: 10.147.32.254 + start: 10.147.32.130 + cidr: 10.147.32.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_167 + network_id: + get_resource: network_0 + type: OS::Neutron::Subnet + subnet_2: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_8 + type: OS::Neutron::Subnet + subnet_3: + properties: + allocation_pools: + - end: 10.147.32.126 + start: 10.147.32.2 + cidr: 10.147.32.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_166 + network_id: + get_resource: network_2 + type: OS::Neutron::Subnet + subnet_4: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_5 + type: OS::Neutron::Subnet + subnet_5: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_6 + type: OS::Neutron::Subnet + subnet_6: + properties: + allocation_pools: + - end: 10.147.33.126 + start: 10.147.33.2 + cidr: 10.147.33.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_168 + network_id: + get_resource: network_3 + type: OS::Neutron::Subnet + subnet_7: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_1 + type: OS::Neutron::Subnet + subnet_8: + properties: + allocation_pools: + - end: 10.147.33.254 + start: 10.147.33.130 + cidr: 10.147.33.128/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_169 + network_id: + get_resource: network_4 + type: OS::Neutron::Subnet + subnet_9: + properties: + allocation_pools: + - end: 10.147.34.126 + start: 10.147.34.2 + cidr: 10.147.34.0/25 + dns_nameservers: + - 10.147.4.18 + - 10.247.5.11 + enable_dhcp: true + host_routes: [] + ip_version: 4 + name: NET_170 + network_id: + get_resource: network_7 + type: OS::Neutron::Subnet + diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/pom.xml b/openecomp-be/lib/openecomp-sdc-validation-lib/pom.xml new file mode 100644 index 0000000000..a132a618a8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-validation-lib/pom.xml @@ -0,0 +1,38 @@ + + 4.0.0 + + + openecomp-sdc-lib + org.openecomp.sdc + 1.0.0-SNAPSHOT + + + openecomp-sdc-validation-lib + openecomp-sdc-validation-lib + pom + + + openecomp-sdc-validation-api + openecomp-sdc-validation-core + openecomp-sdc-validation-impl + + + + + org.openecomp.sdc + openecomp-sdc-validation-api + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-validation-core + ${project.version} + + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/pom.xml b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/pom.xml new file mode 100644 index 0000000000..1cb542eba5 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/pom.xml @@ -0,0 +1,57 @@ + + 4.0.0 + + + org.openecomp.sdc + openecomp-sdc-lib + 1.0.0-SNAPSHOT + ../.. + + + openecomp-sdc-vendor-license-api + openecomp-sdc-vendor-license-api + + + + org.openecomp.core + openecomp-facade-core + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-versioning-core + ${project.version} + + + org.openecomp.core + openecomp-nosqldb-core + ${project.version} + + + javax.el + javax.el-api + ${javax.el-api.version} + + + org.glassfish.web + javax.el + 2.2.4 + + + com.fasterxml.jackson.core + jackson-annotations + 2.7.4 + + + com.fasterxml.jackson.dataformat + jackson-dataformat-xml + 2.7.4 + + + org.codehaus.woodstox + woodstox-core-asl + 4.4.1 + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/HealingServiceFactory.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/HealingServiceFactory.java new file mode 100644 index 0000000000..19d664247b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/HealingServiceFactory.java @@ -0,0 +1,32 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; +import org.openecomp.sdc.vendorlicense.healing.HealingService; + +public abstract class HealingServiceFactory extends AbstractComponentFactory { + + public static HealingServiceFactory getInstance() { + return AbstractFactory.getInstance(HealingServiceFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/VendorLicenseArtifactServiceFactory.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/VendorLicenseArtifactServiceFactory.java new file mode 100644 index 0000000000..0ce7484aa7 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/VendorLicenseArtifactServiceFactory.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; +import org.openecomp.sdc.vendorlicense.licenseartifacts.VendorLicenseArtifactsService; + +public abstract class VendorLicenseArtifactServiceFactory + extends AbstractComponentFactory { + + public static VendorLicenseArtifactServiceFactory getInstance() { + return AbstractFactory.getInstance(VendorLicenseArtifactServiceFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/VendorLicenseConstants.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/VendorLicenseConstants.java new file mode 100644 index 0000000000..2a1930d626 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/VendorLicenseConstants.java @@ -0,0 +1,43 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense; + +import java.io.File; + +public final class VendorLicenseConstants { + public static final String VENDOR_LICENSE_MODEL_VERSIONABLE_TYPE = "VendorLicenseModel"; + + public static final String EXTERNAL_ARTIFACTS_DIR = "Artifacts"; + //todo change when separating external from internal artifacts + public static final String VNF_ARTIFACT_NAME_WITH_PATH = + EXTERNAL_ARTIFACTS_DIR + File.separator + "vf-license-model.xml"; + public static final String VENDOR_LICENSE_MODEL_ARTIFACT_NAME_WITH_PATH = + EXTERNAL_ARTIFACTS_DIR + File.separator + "vendor-license-model.xml"; + public static final String VENDOR_LICENSE_MODEL_ARTIFACT_REGEX_REMOVE = " xmlns=\"\""; + + public final class UniqueValues { + public static final String VENDOR_NAME = "Vendor name"; + public static final String LICENSE_AGREEMENT_NAME = "License Agreement name"; + public static final String FEATURE_GROUP_NAME = "Feature Group name"; + public static final String ENTITLEMENT_POOL_NAME = "Entitlement Pool name"; + public static final String LICENSE_KEY_GROUP_NAME = "License Key Group name"; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/EntitlementPoolDao.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/EntitlementPoolDao.java new file mode 100644 index 0000000000..c507e6946a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/EntitlementPoolDao.java @@ -0,0 +1,38 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao; + +import org.openecomp.core.dao.BaseDao; +import org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity; +import org.openecomp.sdc.versioning.dao.VersionableDao; + +public interface EntitlementPoolDao extends VersionableDao, BaseDao { + + long count(EntitlementPoolEntity entitlementPool); + + void deleteAll(EntitlementPoolEntity entitlementPool); + + void addReferencingFeatureGroup(EntitlementPoolEntity entitlementPool, + String referencingFeatureGroupId); + + void removeReferencingFeatureGroup(EntitlementPoolEntity entitlementPool, + String referencingFeatureGroupId); +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/EntitlementPoolDaoFactory.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/EntitlementPoolDaoFactory.java new file mode 100644 index 0000000000..e5bfcfa1cb --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/EntitlementPoolDaoFactory.java @@ -0,0 +1,31 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; + +public abstract class EntitlementPoolDaoFactory + extends AbstractComponentFactory { + public static EntitlementPoolDaoFactory getInstance() { + return AbstractFactory.getInstance(EntitlementPoolDaoFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/FeatureGroupDao.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/FeatureGroupDao.java new file mode 100644 index 0000000000..a5db802861 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/FeatureGroupDao.java @@ -0,0 +1,47 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao; + +import org.openecomp.core.dao.BaseDao; +import org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity; +import org.openecomp.sdc.versioning.dao.VersionableDao; + +import java.util.Set; + +public interface FeatureGroupDao extends VersionableDao, BaseDao { + + long count(FeatureGroupEntity featureGroup); + + void deleteAll(FeatureGroupEntity featureGroup); + + void updateFeatureGroup(FeatureGroupEntity entity, Set addedEntitlementPools, + Set removedEntitlementPools, Set addedLicenseKeyGroups, + Set removedLicenseKeyGroups); + + void addReferencingLicenseAgreement(FeatureGroupEntity featureGroup, String licenseAgreementId); + + void removeReferencingLicenseAgreement(FeatureGroupEntity featureGroup, + String licenseAgreementId); + + void removeEntitlementPool(FeatureGroupEntity featureGroup, String entitlementPoolId); + + void removeLicenseKeyGroup(FeatureGroupEntity featureGroup, String licenseKeyGroupId); +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/FeatureGroupDaoFactory.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/FeatureGroupDaoFactory.java new file mode 100644 index 0000000000..58832e12ae --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/FeatureGroupDaoFactory.java @@ -0,0 +1,31 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; + + +public abstract class FeatureGroupDaoFactory extends AbstractComponentFactory { + public static FeatureGroupDaoFactory getInstance() { + return AbstractFactory.getInstance(FeatureGroupDaoFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/LicenseAgreementDao.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/LicenseAgreementDao.java new file mode 100644 index 0000000000..df5e972422 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/LicenseAgreementDao.java @@ -0,0 +1,40 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao; + +import org.openecomp.core.dao.BaseDao; +import org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementEntity; +import org.openecomp.sdc.versioning.dao.VersionableDao; + +import java.util.Set; + +public interface LicenseAgreementDao extends VersionableDao, BaseDao { + + long count(LicenseAgreementEntity entity); + + void deleteAll(LicenseAgreementEntity entity); + + void removeFeatureGroup(LicenseAgreementEntity licenseAgreement, String featureGroupId); + + void updateColumnsAndDeltaFeatureGroupIds(LicenseAgreementEntity licenseAgreement, + Set addedFeatureGroupIds, + Set removedFeatureGroupIds); +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/LicenseAgreementDaoFactory.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/LicenseAgreementDaoFactory.java new file mode 100644 index 0000000000..54c7b7bfea --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/LicenseAgreementDaoFactory.java @@ -0,0 +1,31 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; + +public abstract class LicenseAgreementDaoFactory + extends AbstractComponentFactory { + public static LicenseAgreementDaoFactory getInstance() { + return AbstractFactory.getInstance(LicenseAgreementDaoFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/LicenseKeyGroupDao.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/LicenseKeyGroupDao.java new file mode 100644 index 0000000000..43e380d9b9 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/LicenseKeyGroupDao.java @@ -0,0 +1,34 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao; + +import org.openecomp.core.dao.BaseDao; +import org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyGroupEntity; +import org.openecomp.sdc.versioning.dao.VersionableDao; + +public interface LicenseKeyGroupDao extends VersionableDao, BaseDao { + + void deleteAll(LicenseKeyGroupEntity licenseKeyGroup); + + void addReferencingFeatureGroup(LicenseKeyGroupEntity licenseKeyGroup, String featureGroupId); + + void removeReferencingFeatureGroup(LicenseKeyGroupEntity licenseKeyGroup, String featureGroupId); +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/LicenseKeyGroupDaoFactory.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/LicenseKeyGroupDaoFactory.java new file mode 100644 index 0000000000..1f887390db --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/LicenseKeyGroupDaoFactory.java @@ -0,0 +1,32 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; + +public abstract class LicenseKeyGroupDaoFactory + extends AbstractComponentFactory { + + public static LicenseKeyGroupDaoFactory getInstance() { + return AbstractFactory.getInstance(LicenseKeyGroupDaoFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/VendorLicenseModelDao.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/VendorLicenseModelDao.java new file mode 100644 index 0000000000..b8e39bc496 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/VendorLicenseModelDao.java @@ -0,0 +1,29 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao; + +import org.openecomp.core.dao.BaseDao; +import org.openecomp.sdc.vendorlicense.dao.types.VendorLicenseModelEntity; +import org.openecomp.sdc.versioning.dao.VersionableDao; + +public interface VendorLicenseModelDao extends VersionableDao, BaseDao { +// void updateLastModificationTime(VendorLicenseModelEntity vendorLicenseModel); +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/VendorLicenseModelDaoFactory.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/VendorLicenseModelDaoFactory.java new file mode 100644 index 0000000000..b6d13a9027 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/VendorLicenseModelDaoFactory.java @@ -0,0 +1,32 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; + +public abstract class VendorLicenseModelDaoFactory + extends AbstractComponentFactory { + + public static VendorLicenseModelDaoFactory getInstance() { + return AbstractFactory.getInstance(VendorLicenseModelDaoFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/AggregationFunction.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/AggregationFunction.java new file mode 100644 index 0000000000..9a5af213c4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/AggregationFunction.java @@ -0,0 +1,27 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao.types; + +public enum AggregationFunction { + Peak, + Average, + Other +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/ChoiceOrOther.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/ChoiceOrOther.java new file mode 100644 index 0000000000..ca7a09b0df --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/ChoiceOrOther.java @@ -0,0 +1,154 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao.types; + +import com.datastax.driver.mapping.annotations.Transient; +import com.datastax.driver.mapping.annotations.UDT; +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; + +@UDT(keyspace = "dox", name = "choice_or_other") +public class ChoiceOrOther> { + + public static final String CHOICE_OR_OTHER_INVALID_ENUM_ERR_ID = + "MULTI_CHOICE_OR_OTHER_INVALID_ENUM_ERR_ID"; + public static final String CHOICE_OR_OTHER_INVALID_ENUM_MSG = + "Enum used as part of ChoiceOrOther type must contain the value 'Other'"; + public static final String OTHER_ENUM_VALUE = "Other"; + + @Transient + private E choice; + + @Transient + private String other; + + private String result; + + public ChoiceOrOther() { + } + + /** + * Instantiates a new Choice or other. + * + * @param choice the choice + * @param other the other + */ + public ChoiceOrOther(E choice, String other) { + this.choice = choice; + this.other = other; + result = resolveResult(); + } + + public E getChoice() { + return choice; + } + + public void setChoice(E choice) { + + this.choice = choice; + } + + public String getOther() { + return other; + } + + public void setOther(String other) { + this.other = other; + } + + public String getResult() { + return result; + } + + /** + * Sets result. + * + * @param result the result + */ + public void setResult(String result) { + if (choice != null) { + if (result == null) { + this.result = resolveResult(); + } + } else { + this.result = result; + } + } + + private String resolveResult() { + return OTHER_ENUM_VALUE.equals(choice.name()) ? other : choice.name(); + } + + /** + * Resolve enum. + * + * @param enumClass the enum class + */ + public void resolveEnum(Class enumClass) { + if (choice != null || result == null) { + return; + } + + try { + choice = E.valueOf(enumClass, result); + } catch (IllegalArgumentException e0) { + try { + choice = E.valueOf(enumClass, OTHER_ENUM_VALUE); + } catch (IllegalArgumentException ex) { + throw new CoreException(new ErrorCode.ErrorCodeBuilder() + .withId(CHOICE_OR_OTHER_INVALID_ENUM_ERR_ID) + .withMessage(CHOICE_OR_OTHER_INVALID_ENUM_MSG) + .withCategory(ErrorCategory.APPLICATION).build()); + } + other = result; + } + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (obj == null || getClass() != obj.getClass()) { + return false; + } + + ChoiceOrOther that = (ChoiceOrOther) obj; + + if (choice != null ? !choice.equals(that.choice) : that.choice != null) { + return false; + } + if (other != null ? !other.equals(that.other) : that.other != null) { + return false; + } + return result != null ? result.equals(that.result) : that.result == null; + + } + + @Override + public int hashCode() { + int result1 = choice != null ? choice.hashCode() : 0; + result1 = 31 * result1 + (other != null ? other.hashCode() : 0); + result1 = 31 * result1 + (result != null ? result.hashCode() : 0); + return result1; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/EntitlementMetric.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/EntitlementMetric.java new file mode 100644 index 0000000000..42cc231273 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/EntitlementMetric.java @@ -0,0 +1,37 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao.types; + +public enum EntitlementMetric { + Software_Instances_Count, + Core, + CPU, + Trunks, + User, + Subscribers, + Tenants, + Tokens, + Seats, + Units_TB, + Units_MB, + Units_GB, + Other +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/EntitlementPoolEntity.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/EntitlementPoolEntity.java new file mode 100644 index 0000000000..8964458181 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/EntitlementPoolEntity.java @@ -0,0 +1,370 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao.types; + +import com.datastax.driver.mapping.annotations.ClusteringColumn; +import com.datastax.driver.mapping.annotations.Column; +import com.datastax.driver.mapping.annotations.Enumerated; +import com.datastax.driver.mapping.annotations.Frozen; +import com.datastax.driver.mapping.annotations.PartitionKey; +import com.datastax.driver.mapping.annotations.Table; +import org.openecomp.sdc.vendorlicense.dao.types.xml.AggregationFunctionForXml; +import org.openecomp.sdc.vendorlicense.dao.types.xml.EntitlementMetricForXml; +import org.openecomp.sdc.vendorlicense.dao.types.xml.EntitlementTimeForXml; +import org.openecomp.sdc.vendorlicense.dao.types.xml.ThresholdForXml; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.dao.types.VersionableEntity; + +import java.util.HashSet; +import java.util.Objects; +import java.util.Set; + +@Table(keyspace = "dox", name = "entitlement_pool") +public class EntitlementPoolEntity implements VersionableEntity { + private static final String ENTITY_TYPE = "Entitlement Pool"; + + @PartitionKey + @Column(name = "vlm_id") + private String vendorLicenseModelId; + + @PartitionKey(value = 1) + @Frozen + private Version version; + + @ClusteringColumn + @Column(name = "ep_id") + private String id; + private String name; + private String description; + + + @Column(name = "threshold") + private int thresholdValue; + + @Column(name = "threshold_unit") + @Enumerated + private ThresholdUnit thresholdUnit; + + @Column(name = "entitlement_metric") + @Frozen + private ChoiceOrOther entitlementMetric; + private String increments; + + @Column(name = "aggregation_func") + @Frozen + private ChoiceOrOther aggregationFunction; + + @Column(name = "operational_scope") + @Frozen + private MultiChoiceOrOther operationalScope; + + @Frozen + private ChoiceOrOther time; + + @Column(name = "manufacturer_ref_num") + private String manufacturerReferenceNumber; + + @Column(name = "ref_fg_ids") + private Set referencingFeatureGroups = new HashSet<>(); + + @Column(name = "version_uuid") + private String versionUuId; + + public EntitlementPoolEntity() { + } + + /** + * Instantiates a new Entitlement pool entity. + * + * @param vlmId the vlm id + * @param version the version + * @param id the id + */ + public EntitlementPoolEntity(String vlmId, Version version, String id) { + this.vendorLicenseModelId = vlmId; + this.version = version; + this.id = id; + } + + @Override + public String getEntityType() { + return ENTITY_TYPE; + } + + @Override + public String getFirstClassCitizenId() { + return getVendorLicenseModelId(); + } + + public String getVendorLicenseModelId() { + return vendorLicenseModelId; + } + + public void setVendorLicenseModelId(String vendorLicenseModelId) { + this.vendorLicenseModelId = vendorLicenseModelId; + } + + @Override + public String getId() { + return id; + } + + @Override + public void setId(String id) { + this.id = id; + } + + @Override + public Version getVersion() { + return version; + } + + @Override + public void setVersion(Version version) { + this.version = version; + } + + public Set getReferencingFeatureGroups() { + return referencingFeatureGroups; + } + + public void setReferencingFeatureGroups(Set referencingFeatureGroups) { + this.referencingFeatureGroups = referencingFeatureGroups; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public int getThresholdValue() { + return thresholdValue; + } + + public void setThresholdValue(int thresholdValue) { + this.thresholdValue = thresholdValue; + } + + public ThresholdUnit getThresholdUnit() { + return thresholdUnit; + } + + public void setThresholdUnit(ThresholdUnit thresholdUnits) { + this.thresholdUnit = thresholdUnits; + } + + public ChoiceOrOther getEntitlementMetric() { + return entitlementMetric; + } + + public void setEntitlementMetric(ChoiceOrOther entitlementMetric) { + entitlementMetric.resolveEnum(EntitlementMetric.class); + this.entitlementMetric = entitlementMetric; + } + + public String getIncrements() { + return increments; + } + + public void setIncrements(String increments) { + this.increments = increments; + } + + public ChoiceOrOther getAggregationFunction() { + return aggregationFunction; + } + + public void setAggregationFunction(ChoiceOrOther aggregationFunction) { + aggregationFunction.resolveEnum(AggregationFunction.class); + this.aggregationFunction = aggregationFunction; + } + + public MultiChoiceOrOther getOperationalScope() { + return operationalScope; + } + + public void setOperationalScope(MultiChoiceOrOther operationalScope) { + operationalScope.resolveEnum(OperationalScope.class); + this.operationalScope = operationalScope; + } + + public ChoiceOrOther getTime() { + return time; + } + + public void setTime(ChoiceOrOther time) { + time.resolveEnum(EntitlementTime.class); + this.time = time; + } + + public String getManufacturerReferenceNumber() { + return manufacturerReferenceNumber; + } + + public void setManufacturerReferenceNumber(String manufacturerReferenceNumber) { + this.manufacturerReferenceNumber = manufacturerReferenceNumber; + } + + + /** + * Gets threshold for artifact. + * + * @return the threshold for artifact + */ + //util methods for XML + public ThresholdForXml getThresholdForArtifact() { + ThresholdForXml threshold = new ThresholdForXml(); + threshold.setUnit(getThresholdUnit() == null ? null : getThresholdUnit().name()); + threshold.setValue(getThresholdValue()); + return threshold; + } + + /** + * Gets entitlement metric for artifact. + * + * @return the entitlement metric for artifact + */ + public EntitlementMetricForXml getEntitlementMetricForArtifact() { + EntitlementMetricForXml metric = new EntitlementMetricForXml(); + if (entitlementMetric != null) { + metric.setValue(entitlementMetric.getResult()); + } else { + metric.setValue(null); + } + return metric; + } + + /** + * Gets time for artifact. + * + * @return the time for artifact + */ + public EntitlementTimeForXml getTimeForArtifact() { + EntitlementTimeForXml timeForXml = new EntitlementTimeForXml(); + if (time != null) { + timeForXml.setValue(time.getResult()); + } + + return timeForXml; + } + + + @Override + public String toString() { + return "EntitlementPoolEntity{" + + "vendorLicenseModelId='" + vendorLicenseModelId + '\'' + + ", version=" + version + + ", id='" + id + '\'' + + ", name='" + name + '\'' + + ", description='" + description + '\'' + + ", thresholdValue=" + thresholdValue + + ", thresholdUnit='" + thresholdUnit + '\'' + + ", entitlementMetric=" + entitlementMetric + + ", increments='" + increments + '\'' + + ", aggregationFunction=" + aggregationFunction + + ", operationalScope=" + operationalScope + + ", time=" + time + + ", manufacturerReferenceNumber='" + manufacturerReferenceNumber + '\'' + + ", referencingFeatureGroups=" + referencingFeatureGroups + + ", version_uuid=" + versionUuId + + '}'; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (obj == null || getClass() != obj.getClass()) { + return false; + } + EntitlementPoolEntity that = (EntitlementPoolEntity) obj; + return Float.compare(that.thresholdValue, thresholdValue) == 0 + && Objects.equals(vendorLicenseModelId, that.vendorLicenseModelId) + && Objects.equals(version, that.version) + && Objects.equals(id, that.id) + && Objects.equals(name, that.name) + && Objects.equals(description, that.description) + && Objects.equals(thresholdUnit, that.thresholdUnit) + && Objects.equals(entitlementMetric, that.entitlementMetric) + && Objects.equals(increments, that.increments) + && Objects.equals(aggregationFunction, that.aggregationFunction) + && Objects.equals(operationalScope, that.operationalScope) + && Objects.equals(time, that.time) + && Objects.equals(manufacturerReferenceNumber, that.manufacturerReferenceNumber) + && Objects.equals(referencingFeatureGroups, that.referencingFeatureGroups); + } + + @Override + public int hashCode() { + return Objects + .hash(vendorLicenseModelId, version, id, name, description, thresholdValue, thresholdUnit, + entitlementMetric, increments, aggregationFunction, operationalScope, time, + manufacturerReferenceNumber, referencingFeatureGroups); + } + + /** + * Gets aggregation function for artifact. + * + * @return the aggregation function for artifact + */ + public AggregationFunctionForXml getAggregationFunctionForArtifact() { + AggregationFunctionForXml aggregationFunctionForXml = new AggregationFunctionForXml(); + if (entitlementMetric != null) { + aggregationFunctionForXml.setValue(aggregationFunction.getResult()); + } else { + aggregationFunctionForXml.setValue(null); + } + return aggregationFunctionForXml; + } + + /** + * Gets operational scope for artifact. + * + * @return the operational scope for artifact + */ + public Set getOperationalScopeForArtifact() { + if (operationalScope != null) { + return operationalScope.getResults(); + } else { + return null; + } + } + + public String getVersionUuId() { + return versionUuId; + } + + public void setVersionUuId(String uuId) { + versionUuId = uuId; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/EntitlementTime.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/EntitlementTime.java new file mode 100644 index 0000000000..5005075122 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/EntitlementTime.java @@ -0,0 +1,30 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao.types; + +public enum EntitlementTime { //TODO MetricTime ? ask Segev... + Hour, + Day, + Month, + Quarter, + Year, + Other +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/FeatureGroupEntity.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/FeatureGroupEntity.java new file mode 100644 index 0000000000..de5bd2e1c5 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/FeatureGroupEntity.java @@ -0,0 +1,203 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao.types; + +import com.datastax.driver.mapping.annotations.ClusteringColumn; +import com.datastax.driver.mapping.annotations.Column; +import com.datastax.driver.mapping.annotations.Frozen; +import com.datastax.driver.mapping.annotations.PartitionKey; +import com.datastax.driver.mapping.annotations.Table; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.dao.types.VersionableEntity; + + +import java.util.HashSet; +import java.util.Objects; +import java.util.Set; + +@Table(name = "feature_group", keyspace = "dox") +public class FeatureGroupEntity implements VersionableEntity { + private static final String ENTITY_TYPE = "Feature Group"; + + @PartitionKey + @Column(name = "vlm_id") + private String vendorLicenseModelId; + @PartitionKey(value = 1) + @Frozen + private Version version; + @ClusteringColumn + @Column(name = "fg_id") + private String id; + private String name; + private String description; + @Column(name = "part_num") + private String partNumber; + @Column(name = "lkg_ids") + private Set licenseKeyGroupIds = new HashSet<>(); + @Column(name = "ep_ids") + private Set entitlementPoolIds = new HashSet<>(); + @Column(name = "ref_la_ids") + private Set referencingLicenseAgreements = new HashSet<>(); + + public FeatureGroupEntity() { + } + + /** + * Instantiates a new Feature group entity. + * + * @param vendorLicenseModelId the vendor license model id + * @param version the version + * @param id the id + */ + public FeatureGroupEntity(String vendorLicenseModelId, Version version, String id) { + this.vendorLicenseModelId = vendorLicenseModelId; + this.version = version; + this.id = id; + } + + @Override + public String getEntityType() { + return ENTITY_TYPE; + } + + @Override + public String getFirstClassCitizenId() { + return getVendorLicenseModelId(); + } + + public String getVendorLicenseModelId() { + return vendorLicenseModelId; + } + + public void setVendorLicenseModelId(String vendorLicenseModelId) { + this.vendorLicenseModelId = vendorLicenseModelId; + } + + @Override + public Version getVersion() { + return version; + } + + @Override + public void setVersion(Version version) { + this.version = version; + } + + @Override + public String getId() { + return id; + } + + @Override + public void setId(String id) { + this.id = id; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public String getPartNumber() { + return partNumber; + } + + public void setPartNumber(String partNumber) { + this.partNumber = partNumber; + } + + public Set getLicenseKeyGroupIds() { + return licenseKeyGroupIds; + } + + public void setLicenseKeyGroupIds(Set licenseKeyGroupIds) { + this.licenseKeyGroupIds = licenseKeyGroupIds; + } + + public Set getEntitlementPoolIds() { + return entitlementPoolIds; + } + + public void setEntitlementPoolIds(Set entitlementPoolIds) { + this.entitlementPoolIds = entitlementPoolIds; + } + + public Set getReferencingLicenseAgreements() { + return referencingLicenseAgreements; + } + + public void setReferencingLicenseAgreements(Set referencingLicenseAgreements) { + this.referencingLicenseAgreements = referencingLicenseAgreements; + } + + @Override + public String toString() { + return "FeatureGroupEntity{" + + "vendorLicenseModelId='" + vendorLicenseModelId + '\'' + + ", version=" + version + + ", id='" + id + '\'' + + ", name='" + name + '\'' + + ", description='" + description + '\'' + + ", partNumber='" + partNumber + '\'' + + ", licenseKeyGroupIds=" + licenseKeyGroupIds + + ", entitlementPoolIds=" + entitlementPoolIds + + ", referencingLicenseAgreements=" + referencingLicenseAgreements + + '}'; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (obj == null || getClass() != obj.getClass()) { + return false; + } + FeatureGroupEntity that = (FeatureGroupEntity) obj; + return Objects.equals(vendorLicenseModelId, that.vendorLicenseModelId) + && Objects.equals(version, that.version) + && Objects.equals(id, that.id) + && Objects.equals(name, that.name) + && Objects.equals(description, that.description) + && Objects.equals(partNumber, that.partNumber) + && Objects.equals(licenseKeyGroupIds, that.licenseKeyGroupIds) + && Objects.equals(entitlementPoolIds, that.entitlementPoolIds) + && Objects.equals(referencingLicenseAgreements, that.referencingLicenseAgreements); + } + + @Override + public int hashCode() { + return Objects + .hash(vendorLicenseModelId, version, id, name, description, partNumber, licenseKeyGroupIds, + entitlementPoolIds, referencingLicenseAgreements); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/FeatureGroupModel.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/FeatureGroupModel.java new file mode 100644 index 0000000000..78e081760c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/FeatureGroupModel.java @@ -0,0 +1,75 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao.types; + +import java.util.HashSet; +import java.util.Set; + +public class FeatureGroupModel { + private FeatureGroupEntity featureGroup; + private Set entitlementPools = new HashSet<>(); + + private Set licenseKeyGroups = new HashSet<>(); + + public FeatureGroupEntity getFeatureGroup() { + return featureGroup; + } + + public void setFeatureGroup(FeatureGroupEntity featureGroup) { + this.featureGroup = featureGroup; + } + + public Set getEntitlementPools() { + return entitlementPools; + } + + public Set getLicenseKeyGroups() { + return licenseKeyGroups; + } + + public void setEntitlementPools(Set entitlementPools) { + this.entitlementPools = entitlementPools; + } + + public void setLicenseKeyGroups(Set licenseKeyGroups) { + this.licenseKeyGroups = licenseKeyGroups; + } + + //for XML Artifact + public String getEntityName() { + return featureGroup.getName(); + } + + public String getEntityDesc() { + return featureGroup.getDescription(); + } + + public String getEntityId() { + return featureGroup.getId(); + } + + public String getEntityPartNumber() { + return featureGroup.getPartNumber(); + } + + +} + diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/LicenseAgreementEntity.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/LicenseAgreementEntity.java new file mode 100644 index 0000000000..a6e46bf44c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/LicenseAgreementEntity.java @@ -0,0 +1,182 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao.types; + +import com.datastax.driver.mapping.annotations.ClusteringColumn; +import com.datastax.driver.mapping.annotations.Column; +import com.datastax.driver.mapping.annotations.Frozen; +import com.datastax.driver.mapping.annotations.PartitionKey; +import com.datastax.driver.mapping.annotations.Table; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.dao.types.VersionableEntity; + +import java.util.HashSet; +import java.util.Objects; +import java.util.Set; + +@Table(keyspace = "dox", name = "license_agreement") +public class LicenseAgreementEntity implements VersionableEntity { + public static final String ENTITY_TYPE = "License Agreement"; + + @PartitionKey(value = 0) + @Column(name = "vlm_id") + private String vendorLicenseModelId; + + @PartitionKey(value = 1) + @Frozen + private Version version; + + @ClusteringColumn + @Column(name = "la_id") + private String id; + private String name; + private String description; + + @Column(name = "lic_term") + @Frozen + private ChoiceOrOther licenseTerm; + + @Column(name = "req_const") + private String requirementsAndConstrains; + + @Column(name = "fg_ids") + private Set featureGroupIds = new HashSet<>(); + + public LicenseAgreementEntity() { + } + + /** + * Instantiates a new License agreement entity. + * + * @param vlmId the vlm id + * @param version the version + * @param id the id + */ + public LicenseAgreementEntity(String vlmId, Version version, String id) { + this.vendorLicenseModelId = vlmId; + this.id = id; + this.version = version; + } + + @Override + public String getEntityType() { + return ENTITY_TYPE; + } + + @Override + public String getFirstClassCitizenId() { + return getVendorLicenseModelId(); + } + + public String getVendorLicenseModelId() { + return vendorLicenseModelId; + } + + public void setVendorLicenseModelId(String vendorLicenseModelId) { + this.vendorLicenseModelId = vendorLicenseModelId; + } + + @Override + public Version getVersion() { + return version; + } + + @Override + public void setVersion(Version version) { + this.version = version; + } + + @Override + public String getId() { + return id; + } + + @Override + public void setId(String id) { + this.id = id; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public ChoiceOrOther getLicenseTerm() { + return licenseTerm; + } + + public void setLicenseTerm(ChoiceOrOther licenseTerm) { + licenseTerm.resolveEnum(LicenseTerm.class); + this.licenseTerm = licenseTerm; + } + + public String getRequirementsAndConstrains() { + return requirementsAndConstrains; + } + + public void setRequirementsAndConstrains(String requirementsAndConstrains) { + this.requirementsAndConstrains = requirementsAndConstrains; + } + + public Set getFeatureGroupIds() { + return featureGroupIds; + } + + public void setFeatureGroupIds(Set featureGroupIds) { + this.featureGroupIds = featureGroupIds; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (obj == null || getClass() != obj.getClass()) { + return false; + } + LicenseAgreementEntity that = (LicenseAgreementEntity) obj; + return Objects.equals(vendorLicenseModelId, that.vendorLicenseModelId) + && Objects.equals(version, that.version) + && Objects.equals(id, that.id) + && Objects.equals(name, that.name) + && Objects.equals(description, that.description) + && Objects.equals(licenseTerm, that.licenseTerm) + && Objects.equals(requirementsAndConstrains, that.requirementsAndConstrains) + && Objects.equals(featureGroupIds, that.featureGroupIds); + } + + @Override + public int hashCode() { + return Objects.hash(vendorLicenseModelId, version, id, name, description, licenseTerm, + requirementsAndConstrains, featureGroupIds); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/LicenseAgreementModel.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/LicenseAgreementModel.java new file mode 100644 index 0000000000..1e65f70cc0 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/LicenseAgreementModel.java @@ -0,0 +1,45 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao.types; + +import java.util.HashSet; +import java.util.Set; + +public class LicenseAgreementModel { + private LicenseAgreementEntity licenseAgreement; + private Set featureGroups = new HashSet<>(); + + public LicenseAgreementEntity getLicenseAgreement() { + return licenseAgreement; + } + + public void setLicenseAgreement(LicenseAgreementEntity licenseAgreement) { + this.licenseAgreement = licenseAgreement; + } + + public Set getFeatureGroups() { + return featureGroups; + } + + public void setFeatureGroups(Set featureGroups) { + this.featureGroups = featureGroups; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/LicenseKeyGroupEntity.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/LicenseKeyGroupEntity.java new file mode 100644 index 0000000000..2a7e936cb3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/LicenseKeyGroupEntity.java @@ -0,0 +1,231 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao.types; + +import com.datastax.driver.mapping.annotations.ClusteringColumn; +import com.datastax.driver.mapping.annotations.Column; +import com.datastax.driver.mapping.annotations.Enumerated; +import com.datastax.driver.mapping.annotations.Frozen; +import com.datastax.driver.mapping.annotations.PartitionKey; +import com.datastax.driver.mapping.annotations.Table; +import org.openecomp.sdc.vendorlicense.dao.types.xml.LicenseKeyTypeForXml; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.dao.types.VersionableEntity; + + +import java.util.HashSet; +import java.util.Objects; +import java.util.Set; + +@Table(keyspace = "dox", name = "license_key_group") +public class LicenseKeyGroupEntity implements VersionableEntity { + private static final String ENTITY_TYPE = "License Key Group"; + + @PartitionKey + @Column(name = "vlm_id") + private String vendorLicenseModelId; + @PartitionKey(value = 1) + @Frozen + private Version version; + @ClusteringColumn + @Column(name = "lkg_id") + private String id; + private String name; + private String description; + @Enumerated + private LicenseKeyType type; + @Column(name = "operational_scope") + @Frozen + private MultiChoiceOrOther operationalScope; + @Column(name = "ref_fg_ids") + private Set referencingFeatureGroups = new HashSet<>(); + @Column(name = "version_uuid") + private String versionUuId; + + + public LicenseKeyGroupEntity() { + } + + /** + * Instantiates a new License key group entity. + * + * @param vendorLicenseModelId the vendor license model id + * @param version the version + * @param id the id + */ + public LicenseKeyGroupEntity(String vendorLicenseModelId, Version version, String id) { + this.vendorLicenseModelId = vendorLicenseModelId; + this.version = version; + this.id = id; + } + + @Override + public String getEntityType() { + return ENTITY_TYPE; + } + + @Override + public String getFirstClassCitizenId() { + return getVendorLicenseModelId(); + } + + public String getVendorLicenseModelId() { + return vendorLicenseModelId; + } + + public void setVendorLicenseModelId(String vendorLicenseModelId) { + this.vendorLicenseModelId = vendorLicenseModelId; + } + + public String getId() { + return id; + } + + public void setId(String id) { + this.id = id; + } + + public Version getVersion() { + return version; + } + + public void setVersion(Version version) { + this.version = version; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public LicenseKeyType getType() { + return type; + } + + public void setType(LicenseKeyType type) { + this.type = type; + } + + public MultiChoiceOrOther getOperationalScope() { + return operationalScope; + } + + public void setOperationalScope(MultiChoiceOrOther operationalScope) { + operationalScope.resolveEnum(OperationalScope.class); + this.operationalScope = operationalScope; + } + + public Set getReferencingFeatureGroups() { + return referencingFeatureGroups; + } + + public void setReferencingFeatureGroups(Set referencingFeatureGroups) { + this.referencingFeatureGroups = referencingFeatureGroups; + } + + @Override + public String toString() { + return "LicenseKeyGroupEntity{" + "vendorLicenseModelId='" + vendorLicenseModelId + '\'' + + ", version=" + version + + ", id='" + id + '\'' + + ", name='" + name + '\'' + + ", description='" + description + '\'' + + ", type=" + type + + ", operationalScope=" + operationalScope + + ", referencingFeatureGroups=" + referencingFeatureGroups + + ", versionUuId='" + versionUuId + '\'' + + '}'; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (obj == null || getClass() != obj.getClass()) { + return false; + } + LicenseKeyGroupEntity that = (LicenseKeyGroupEntity) obj; + return Objects.equals(vendorLicenseModelId, that.vendorLicenseModelId) + && Objects.equals(version, that.version) + && Objects.equals(id, that.id) + && Objects.equals(name, that.name) + && Objects.equals(description, that.description) + && type == that.type + && Objects.equals(operationalScope, that.operationalScope) + && Objects.equals(referencingFeatureGroups, that.referencingFeatureGroups); + } + + @Override + public int hashCode() { + return Objects + .hash(vendorLicenseModelId, version, id, name, description, type, operationalScope, + referencingFeatureGroups); + } + + /** + * Gets operational scope for artifact. + * + * @return the operational scope for artifact + */ + public Set getOperationalScopeForArtifact() { + if (operationalScope != null) { + return operationalScope.getResults(); + } else { + return null; + } + } + + /** + * Gets type for artifact. + * + * @return the type for artifact + */ + public LicenseKeyTypeForXml getTypeForArtifact() { + LicenseKeyTypeForXml typeXml = new LicenseKeyTypeForXml(); + if (type != null) { + typeXml.setValue(type.toString()); + } else { + typeXml.setValue(null); + } + return typeXml; + } + + + public String getVersionUuId() { + return versionUuId; + } + + public void setVersionUuId(String uuId) { + versionUuId = uuId; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/LicenseKeyType.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/LicenseKeyType.java new file mode 100644 index 0000000000..3ba913de31 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/LicenseKeyType.java @@ -0,0 +1,27 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao.types; + +public enum LicenseKeyType { + Universal, + Unique, + One_Time +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/LicenseTerm.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/LicenseTerm.java new file mode 100644 index 0000000000..729a985473 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/LicenseTerm.java @@ -0,0 +1,28 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao.types; + +public enum LicenseTerm { + Fixed_Term, + Perpetual, + Unlimited, + Other +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/MultiChoiceOrOther.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/MultiChoiceOrOther.java new file mode 100644 index 0000000000..df9d6887ce --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/MultiChoiceOrOther.java @@ -0,0 +1,172 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao.types; + +import com.datastax.driver.mapping.annotations.Transient; +import com.datastax.driver.mapping.annotations.UDT; +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; + +import java.util.HashSet; +import java.util.Set; + +@UDT(keyspace = "dox", name = "multi_choice_or_other") +public class MultiChoiceOrOther> { + public static final String MULTI_CHOICE_OR_OTHER_INVALID_ENUM_ERR_ID = + "MULTI_CHOICE_OR_OTHER_INVALID_ENUM_ERR_ID"; + public static final String MULTI_CHOICE_OR_OTHER_INVALID_ENUM_MSG = + "Enum used as part of MultiChoiceOrOther type must contain the value 'Other'"; + public static final String OTHER_ENUM_VALUE = "Other"; + + @Transient + private Set choices; + @Transient + private String other; + + + private Set results; + + public MultiChoiceOrOther() { + } + + /** + * Instantiates a new Multi choice or other. + * + * @param choices the choices + * @param other the other + */ + public MultiChoiceOrOther(Set choices, String other) { + this.choices = choices; + this.other = other; + results = resolveResult(); + } + + public Set getChoices() { + return choices; + } + + public void setChoices(Set choices) { + this.choices = choices; + } + + public String getOther() { + return other; + } + + public void setOther(String other) { + this.other = other; + } + + public Set getResults() { + return results; + } + + /** + * Sets results. + * + * @param results the results + */ + public void setResults(Set results) { + if (choices != null) { + if (results == null) { + this.results = resolveResult(); + } + } else { + this.results = results; + } + } + + private Set resolveResult() { + results = new HashSet<>(); + if (choices.size() == 1 && OTHER_ENUM_VALUE.equals(choices.iterator().next().name())) { + results.add(other); + } else { + for (E choice : choices) { + results.add(choice.name()); + } + } + + return results; + } + + /** + * Resolve enum. + * + * @param enumClass the enum class + */ + public void resolveEnum(Class enumClass) { + if (choices != null || results == null || results.size() == 0) { + return; + } + + choices = new HashSet<>(); + if (results.size() > 1) { + for (String result : results) { + choices.add(E.valueOf(enumClass, result)); + } + } else { + String result = results.iterator().next(); + try { + choices.add(E.valueOf(enumClass, result)); + } catch (IllegalArgumentException illegalArgumentException) { + try { + choices.add(E.valueOf(enumClass, OTHER_ENUM_VALUE)); + } catch (IllegalArgumentException ex) { + throw new CoreException(new ErrorCode.ErrorCodeBuilder() + .withId(MULTI_CHOICE_OR_OTHER_INVALID_ENUM_ERR_ID) + .withMessage(MULTI_CHOICE_OR_OTHER_INVALID_ENUM_MSG) + .withCategory(ErrorCategory.APPLICATION).build()); + } + other = result; + } + } + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (obj == null || getClass() != obj.getClass()) { + return false; + } + + MultiChoiceOrOther that = (MultiChoiceOrOther) obj; + + if (choices != null ? !choices.equals(that.choices) : that.choices != null) { + return false; + } + if (other != null ? !other.equals(that.other) : that.other != null) { + return false; + } + return results != null ? results.equals(that.results) : that.results == null; + + } + + @Override + public int hashCode() { + int result = choices != null ? choices.hashCode() : 0; + result = 31 * result + (other != null ? other.hashCode() : 0); + result = 31 * result + (results != null ? results.hashCode() : 0); + return result; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/OperationalScope.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/OperationalScope.java new file mode 100644 index 0000000000..ed9497d30b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/OperationalScope.java @@ -0,0 +1,32 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao.types; + +public enum OperationalScope { + Network_Wide, + Availability_Zone, + Data_Center, + Tenant, + VM, + CPU, + Core, + Other +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/ThresholdUnit.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/ThresholdUnit.java new file mode 100644 index 0000000000..bd0fa41073 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/ThresholdUnit.java @@ -0,0 +1,26 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao.types; + +public enum ThresholdUnit { + Absolute, + Percentage +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/VendorLicenseModelEntity.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/VendorLicenseModelEntity.java new file mode 100644 index 0000000000..ea93b1ab4f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/VendorLicenseModelEntity.java @@ -0,0 +1,153 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao.types; + +import com.datastax.driver.mapping.annotations.Column; +import com.datastax.driver.mapping.annotations.Computed; +import com.datastax.driver.mapping.annotations.Frozen; +import com.datastax.driver.mapping.annotations.PartitionKey; +import com.datastax.driver.mapping.annotations.Table; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.dao.types.VersionableEntity; + +import java.util.Objects; + +@Table(keyspace = "dox", name = "vendor_license_model") +public class VendorLicenseModelEntity implements VersionableEntity { + public static final String ENTITY_TYPE = "Vendor License Model"; + + @PartitionKey + @Column(name = "vlm_id") + private String id; + + @PartitionKey(value = 1) + @Frozen + private Version version; + + // @Column(name = "last_modification_time") + // private Date lastModificationTime; + + @Column(name = "vendor_name") + private String vendorName; + private String description; + @Column(name = "icon") + private String iconRef; + + @Computed("writetime(vendor_name)") + private Long writetimeMicroSeconds; + + public VendorLicenseModelEntity() { + } + + public VendorLicenseModelEntity(String id, Version version) { + this.id = id; + this.version = version; + } + + @Override + public String getEntityType() { + return ENTITY_TYPE; + } + + @Override + public String getFirstClassCitizenId() { + return getId(); + } + + public String getId() { + return id; + } + + public void setId(String id) { + this.id = id; + } + + @Override + public Version getVersion() { + return version; + } + + @Override + public void setVersion(Version version) { + this.version = version; + } + + public String getVendorName() { + return vendorName; + } + + public void setVendorName(String vendorName) { + this.vendorName = vendorName; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public String getIconRef() { + return iconRef; + } + + public void setIconRef(String iconRef) { + this.iconRef = iconRef; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (obj == null || getClass() != obj.getClass()) { + return false; + } + VendorLicenseModelEntity that = (VendorLicenseModelEntity) obj; + return Objects.equals(id, that.id) + && Objects.equals(version, that.version) + && Objects.equals(vendorName, that.vendorName) + && Objects.equals(description, that.description) + && Objects.equals(iconRef, that.iconRef); + } + + @Override + public int hashCode() { + return Objects.hash(id, version, vendorName, description, iconRef); + } + + // public Date getLastModificationTime() { + // return lastModificationTime; + // } + // + // public void setLastModificationTime(Date lastModificationTime) { + // this.lastModificationTime = lastModificationTime; + // } + + public Long getWritetimeMicroSeconds() { + return writetimeMicroSeconds; + } + + public void setWritetimeMicroSeconds(Long writetimeMicroSeconds) { + this.writetimeMicroSeconds = writetimeMicroSeconds; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/xml/AggregationFunctionForXml.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/xml/AggregationFunctionForXml.java new file mode 100644 index 0000000000..e2a6be6b9e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/xml/AggregationFunctionForXml.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao.types.xml; + +public class AggregationFunctionForXml { + private String value; + + public String getValue() { + return value; + } + + public void setValue(String value) { + this.value = value; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/xml/EntitlementMetricForXml.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/xml/EntitlementMetricForXml.java new file mode 100644 index 0000000000..8a449446ec --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/xml/EntitlementMetricForXml.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao.types.xml; + +public class EntitlementMetricForXml { + private String value; + + public String getValue() { + return value; + } + + public void setValue(String value) { + this.value = value; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/xml/EntitlementTimeForXml.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/xml/EntitlementTimeForXml.java new file mode 100644 index 0000000000..c78a2d6d91 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/xml/EntitlementTimeForXml.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao.types.xml; + +public class EntitlementTimeForXml { + private String value; + + public String getValue() { + return value; + } + + public void setValue(String value) { + this.value = value; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/xml/LicenseKeyTypeForXml.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/xml/LicenseKeyTypeForXml.java new file mode 100644 index 0000000000..c8c0d3067e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/xml/LicenseKeyTypeForXml.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao.types.xml; + +public class LicenseKeyTypeForXml { + private String value; + + public String getValue() { + return value; + } + + public void setValue(String value) { + this.value = value; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/xml/ThresholdForXml.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/xml/ThresholdForXml.java new file mode 100644 index 0000000000..11627160ad --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/dao/types/xml/ThresholdForXml.java @@ -0,0 +1,42 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao.types.xml; + +public class ThresholdForXml { + String unit; + int value; + + public String getUnit() { + return unit; + } + + public void setUnit(String unit) { + this.unit = unit; + } + + public int getValue() { + return value; + } + + public void setValue(int value) { + this.value = value; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/errors/JsonErrorBuilder.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/errors/JsonErrorBuilder.java new file mode 100644 index 0000000000..a11092bbe3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/errors/JsonErrorBuilder.java @@ -0,0 +1,51 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.errors; + +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; + +public class JsonErrorBuilder { + + private static final String JSON_ERROR_OCCURED_DURING_ARTIFACT_GENERATION_ERR_ID = + "JSON_ERROR_OCCURED_DURING_ARTIFACT_GENERATION_ERR_ID"; + private static final String JSON_ERROR_OCCURED_DURING_ARTIFACT_GENERATION_ERR_ID_MSG = + "Json error occured during artifact generation:%s."; + + private final ErrorCode.ErrorCodeBuilder builder = new ErrorCode.ErrorCodeBuilder(); + + /** + * Instantiates a new Json error builder. + * + * @param exceptionMessage the exception message + */ + public JsonErrorBuilder(String exceptionMessage) { + builder.withId(JSON_ERROR_OCCURED_DURING_ARTIFACT_GENERATION_ERR_ID); + builder.withCategory(ErrorCategory.APPLICATION); + builder.withMessage( + String.format(JSON_ERROR_OCCURED_DURING_ARTIFACT_GENERATION_ERR_ID_MSG, exceptionMessage)); + } + + public ErrorCode build() { + return builder.build(); + } + +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/errors/LicensingDataInvalidErrorBuilder.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/errors/LicensingDataInvalidErrorBuilder.java new file mode 100644 index 0000000000..dfc9a93751 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/errors/LicensingDataInvalidErrorBuilder.java @@ -0,0 +1,49 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.errors; + +import org.openecomp.core.utilities.CommonMethods; +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; + +import java.util.List; + +public class LicensingDataInvalidErrorBuilder { + private static final String LICENSING_DATA_INVALID_MSG = "Invalid licensing data: %s"; + private final ErrorCode.ErrorCodeBuilder builder = new ErrorCode.ErrorCodeBuilder(); + + /** + * Instantiates a new Licensing data invalid error builder. + * + * @param licensingDataErrors the licensing data errors + */ + public LicensingDataInvalidErrorBuilder(List licensingDataErrors) { + builder.withId(VendorLicenseErrorCodes.LICENSING_DATA_INVALID); + builder.withCategory(ErrorCategory.APPLICATION); + builder.withMessage(String.format(LICENSING_DATA_INVALID_MSG, + CommonMethods.listToSeparatedString(licensingDataErrors, ','))); + } + + public ErrorCode build() { + return builder.build(); + } + +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/errors/SubmitUncompletedLicenseModelErrorBuilder.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/errors/SubmitUncompletedLicenseModelErrorBuilder.java new file mode 100644 index 0000000000..0a00cff8ea --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/errors/SubmitUncompletedLicenseModelErrorBuilder.java @@ -0,0 +1,50 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.errors; + +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; + +public class SubmitUncompletedLicenseModelErrorBuilder { + + private static final String SUBMIT_UNCOMPLETED_LICENSE_MODEL_MSG = + "Uncompleted vendor license model %s cannot be submitted. " + + "It must contain license_agreement(s) that all feature groups " + + "contain at least one entitlement pool."; + private final ErrorCode.ErrorCodeBuilder builder = new ErrorCode.ErrorCodeBuilder(); + + /** + * Instantiates a new Submit uncompleted license model error builder. + * + * @param vlmId the vlm id + */ + public SubmitUncompletedLicenseModelErrorBuilder(String vlmId) { + builder.withId(VendorLicenseErrorCodes.SUBMIT_UNCOMPLETED_LICENSE_MODEL); + builder.withCategory(ErrorCategory.APPLICATION); + builder.withMessage(String.format(SUBMIT_UNCOMPLETED_LICENSE_MODEL_MSG, vlmId)); + } + + public ErrorCode build() { + return builder.build(); + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/errors/VendorLicenseErrorCodes.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/errors/VendorLicenseErrorCodes.java new file mode 100644 index 0000000000..4cd7a5bc1b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/errors/VendorLicenseErrorCodes.java @@ -0,0 +1,28 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.errors; + +public class VendorLicenseErrorCodes { + + public static final String VENDOR_LICENSE_MODEL_NOT_FOUND = "VENDOR_LICENSE_MODEL_NOT_FOUND"; + public static final String SUBMIT_UNCOMPLETED_LICENSE_MODEL = "SUBMIT_UNCOMPLETED_LICENSE_MODEL"; + public static final String LICENSING_DATA_INVALID = "LICENSING_DATA_INVALID"; +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/errors/VendorLicenseModelNotFoundErrorBuilder.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/errors/VendorLicenseModelNotFoundErrorBuilder.java new file mode 100644 index 0000000000..d2dc1d6f00 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/errors/VendorLicenseModelNotFoundErrorBuilder.java @@ -0,0 +1,48 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.errors; + +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; + +public class VendorLicenseModelNotFoundErrorBuilder { + + private static final String VENDOR_LICENSE_MODEL_NOT_FOUND_MSG = + "Vendor license model with id %s not found."; + private final ErrorCode.ErrorCodeBuilder builder = new ErrorCode.ErrorCodeBuilder(); + + /** + * Instantiates a new Vendor license model not found error builder. + * + * @param vendorLicenseModelId the vendor license model id + */ + public VendorLicenseModelNotFoundErrorBuilder(String vendorLicenseModelId) { + builder.withId(VendorLicenseErrorCodes.VENDOR_LICENSE_MODEL_NOT_FOUND); + builder.withCategory(ErrorCategory.APPLICATION); + builder.withMessage(String.format(VENDOR_LICENSE_MODEL_NOT_FOUND_MSG, vendorLicenseModelId)); + } + + public ErrorCode build() { + return builder.build(); + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/facade/VendorLicenseFacade.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/facade/VendorLicenseFacade.java new file mode 100644 index 0000000000..e36852d25f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/facade/VendorLicenseFacade.java @@ -0,0 +1,89 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.facade; + +import org.openecomp.sdc.common.errors.ErrorCode; +import org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity; +import org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity; +import org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupModel; +import org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementEntity; +import org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementModel; +import org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyGroupEntity; +import org.openecomp.sdc.vendorlicense.dao.types.VendorLicenseModelEntity; +import org.openecomp.sdc.vendorlicense.types.VersionedVendorLicenseModel; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.types.VersionInfo; +import org.openecomp.sdc.versioning.types.VersionableEntityAction; + +import java.util.Collection; + +public interface VendorLicenseFacade { + + void checkin(String vendorLicenseModelId, String user); + + void submit(String vendorLicenseModelId, String user); + + FeatureGroupEntity getFeatureGroup(FeatureGroupEntity featureGroup, String user); + + FeatureGroupModel getFeatureGroupModel(FeatureGroupEntity featureGroup, String user); + + LicenseAgreementEntity getLicenseAgreement(String vlmId, Version version, + String licenseAgreementId, String user); + + LicenseAgreementModel getLicenseAgreementModel(String vlmId, Version version, + String licenseAgreementId, String user); + + EntitlementPoolEntity createEntitlementPool(EntitlementPoolEntity entitlementPool, String user); + + LicenseKeyGroupEntity createLicenseKeyGroup(LicenseKeyGroupEntity licenseKeyGroup, String user); + + void updateEntitlementPool(EntitlementPoolEntity entitlementPool, String user); + + Collection listLicenseKeyGroups(String vlmId, Version version, + String user); + + Collection listEntitlementPools(String vlmId, Version version, + String user); + + void updateLicenseKeyGroup(LicenseKeyGroupEntity licenseKeyGroup, String user); + + + VersionedVendorLicenseModel getVendorLicenseModel(String vlmId, Version version, String user); + + VendorLicenseModelEntity createVendorLicenseModel( + VendorLicenseModelEntity vendorLicenseModelEntity, String user); + + + LicenseAgreementEntity createLicenseAgreement(LicenseAgreementEntity licenseAgreement, + String user); + + FeatureGroupEntity createFeatureGroup(FeatureGroupEntity featureGroup, String user); + + + Collection validateLicensingData(String vlmId, Version vlmVersion, + String licenseAgreementId, + Collection featureGroupIds); + + VersionInfo getVersionInfo(String vendorLicenseModelId, VersionableEntityAction action, + String user); + + void updateVlmLastModificationTime(String vendorLicenseModelId, Version version); +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/facade/VendorLicenseFacadeFactory.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/facade/VendorLicenseFacadeFactory.java new file mode 100644 index 0000000000..540cc5ba66 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/facade/VendorLicenseFacadeFactory.java @@ -0,0 +1,32 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.facade; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; + +public abstract class VendorLicenseFacadeFactory + extends AbstractComponentFactory { + + public static VendorLicenseFacadeFactory getInstance() { + return AbstractFactory.getInstance(VendorLicenseFacadeFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/healing/HealingService.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/healing/HealingService.java new file mode 100644 index 0000000000..027cb1e5be --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/healing/HealingService.java @@ -0,0 +1,31 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.healing; + +import org.openecomp.sdc.versioning.dao.types.VersionableEntity; + +public interface HealingService { + + // VersionableEntity heal(VersionableEntity toHeal, String user); + VersionableEntity heal(VersionableEntity toHeal, String user); +} + + diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/VendorLicenseArtifactsService.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/VendorLicenseArtifactsService.java new file mode 100644 index 0000000000..c0610a99cd --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/VendorLicenseArtifactsService.java @@ -0,0 +1,32 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.licenseartifacts; + +import org.openecomp.core.utilities.file.FileContentHandler; +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.util.List; + +public interface VendorLicenseArtifactsService { + + FileContentHandler createLicenseArtifacts(String vspId, String vlmId, Version vlmVersion, + List featureGroups, String user); +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/types/VersionedVendorLicenseModel.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/types/VersionedVendorLicenseModel.java new file mode 100644 index 0000000000..deb321f14e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/java/org/openecomp/sdc/vendorlicense/types/VersionedVendorLicenseModel.java @@ -0,0 +1,54 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.types; + +import org.openecomp.sdc.vendorlicense.dao.types.VendorLicenseModelEntity; +import org.openecomp.sdc.versioning.types.VersionInfo; + +public class VersionedVendorLicenseModel { + private VendorLicenseModelEntity vendorLicenseModel; + private VersionInfo versionInfo; + + public VersionedVendorLicenseModel() { + } + + public VersionedVendorLicenseModel(VendorLicenseModelEntity vendorLicenseModel, + VersionInfo versionInfo) { + this.vendorLicenseModel = vendorLicenseModel; + this.versionInfo = versionInfo; + } + + public VendorLicenseModelEntity getVendorLicenseModel() { + return vendorLicenseModel; + } + + public void setVendorLicenseModel(VendorLicenseModelEntity vendorLicenseModel) { + this.vendorLicenseModel = vendorLicenseModel; + } + + public VersionInfo getVersionInfo() { + return versionInfo; + } + + public void setVersionInfo(VersionInfo versionInfo) { + this.versionInfo = versionInfo; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/resources/factoryConfiguration.json b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/resources/factoryConfiguration.json new file mode 100644 index 0000000000..7f59b42103 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-api/src/main/resources/factoryConfiguration.json @@ -0,0 +1,11 @@ +{ + "org.openecomp.sdc.vendorlicense.VendorLicenseArtifactServiceFactory": "org.openecomp.sdc.vendorlicense.VendorLicenseArtifactServiceFactoryImpl", + "org.openecomp.sdc.vendorlicense.HealingServiceFactory": "org.openecomp.sdc.vendorlicense.SimpleHealingServiceServiceFactoryImpl", + "org.openecomp.sdc.vendorlicense.facade.VendorLicenseFacadeFactory": "org.openecomp.sdc.vendorlicense.facade.impl.VendorLicenseFacadeFactoryImpl", + "org.openecomp.sdc.vendorlicense.dao.VendorLicenseModelDaoFactory": "org.openecomp.sdc.vendorlicense.dao.impl.VendorLicenseModelDaoFactoryImpl", + "org.openecomp.sdc.vendorlicense.dao.LicenseAgreementDaoFactory": "org.openecomp.sdc.vendorlicense.dao.impl.LicenseAgreementDaoFactoryImpl", + "org.openecomp.sdc.vendorlicense.dao.FeatureGroupDaoFactory": "org.openecomp.sdc.vendorlicense.dao.impl.FeatureGroupDaoFactoryImpl", + "org.openecomp.sdc.vendorlicense.dao.LicenseKeyGroupDaoFactory": "org.openecomp.sdc.vendorlicense.dao.impl.LicenseKeyGroupDaoFactoryImpl", + "org.openecomp.sdc.vendorlicense.dao.EntitlementPoolDaoFactory": "org.openecomp.sdc.vendorlicense.dao.impl.EntitlementPoolDaoFactoryImpl" + +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/pom.xml b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/pom.xml new file mode 100644 index 0000000000..7b66b2a505 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/pom.xml @@ -0,0 +1,48 @@ + + 4.0.0 + + openecomp-sdc-vendor-license-core + openecomp-sdc-vendor-license-core + + + org.openecomp.sdc + openecomp-sdc-lib + 1.0.0-SNAPSHOT + ../.. + + + + + org.openecomp.sdc + openecomp-sdc-vendor-license-api + ${project.version} + + + + org.mockito + mockito-all + test + 1.10.19 + + + org.testng + testng + test + 6.8.5 + + + snakeyaml + org.yaml + + + + + junit + junit + test + RELEASE + + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/SimpleHealingServiceServiceFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/SimpleHealingServiceServiceFactoryImpl.java new file mode 100644 index 0000000000..79973bb888 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/SimpleHealingServiceServiceFactoryImpl.java @@ -0,0 +1,34 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense; + +import org.openecomp.sdc.vendorlicense.healing.HealingService; +import org.openecomp.sdc.vendorlicense.healing.impl.SimpleHealingServiceImpl; + +public class SimpleHealingServiceServiceFactoryImpl extends HealingServiceFactory { + private static HealingService INSTANCE = new SimpleHealingServiceImpl(); + + @Override + public HealingService createInterface() { + return INSTANCE; + } + +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/VendorLicenseArtifactServiceFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/VendorLicenseArtifactServiceFactoryImpl.java new file mode 100644 index 0000000000..582b0e2094 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/VendorLicenseArtifactServiceFactoryImpl.java @@ -0,0 +1,34 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense; + +import org.openecomp.sdc.vendorlicense.licenseartifacts.VendorLicenseArtifactsService; +import org.openecomp.sdc.vendorlicense.licenseartifacts.impl.VendorLicenseArtifactsServiceImpl; + +public class VendorLicenseArtifactServiceFactoryImpl extends VendorLicenseArtifactServiceFactory { + private static VendorLicenseArtifactsService INSTANCE = new VendorLicenseArtifactsServiceImpl(); + + @Override + public VendorLicenseArtifactsService createInterface() { + return INSTANCE; + } + +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/EntitlementPoolCassandraDaoImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/EntitlementPoolCassandraDaoImpl.java new file mode 100644 index 0000000000..1722f8f8de --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/EntitlementPoolCassandraDaoImpl.java @@ -0,0 +1,148 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao.impl; + +import com.datastax.driver.core.ResultSet; +import com.datastax.driver.core.UDTValue; +import com.datastax.driver.mapping.Mapper; +import com.datastax.driver.mapping.Result; +import com.datastax.driver.mapping.UDTMapper; +import com.datastax.driver.mapping.annotations.Accessor; +import com.datastax.driver.mapping.annotations.Query; +import org.openecomp.core.dao.impl.CassandraBaseDao; +import org.openecomp.core.nosqldb.api.NoSqlDb; +import org.openecomp.core.nosqldb.factory.NoSqlDbFactory; +import org.openecomp.core.utilities.CommonMethods; +import org.openecomp.sdc.vendorlicense.VendorLicenseConstants; +import org.openecomp.sdc.vendorlicense.dao.EntitlementPoolDao; +import org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity; +import org.openecomp.sdc.versioning.VersioningManagerFactory; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.types.UniqueValueMetadata; +import org.openecomp.sdc.versioning.types.VersionableEntityMetadata; + +import java.util.Arrays; +import java.util.Collection; +import java.util.Collections; +import java.util.Set; + +public class EntitlementPoolCassandraDaoImpl extends CassandraBaseDao + implements EntitlementPoolDao { + + private static NoSqlDb noSqlDb = NoSqlDbFactory.getInstance().createInterface(); + private static Mapper mapper = + noSqlDb.getMappingManager().mapper(EntitlementPoolEntity.class); + private static EntitlementPoolAccessor accessor = + noSqlDb.getMappingManager().createAccessor(EntitlementPoolAccessor.class); + private static UDTMapper versionMapper = + noSqlDb.getMappingManager().udtMapper(Version.class); + + @Override + public void registerVersioning(String versionableEntityType) { + VersionableEntityMetadata metadata = new VersionableEntityMetadata( + mapper.getTableMetadata().getName(), + mapper.getTableMetadata().getPartitionKey().get(0).getName(), + mapper.getTableMetadata().getPartitionKey().get(1).getName()); + + metadata.setUniqueValuesMetadata(Collections.singletonList( + new UniqueValueMetadata(VendorLicenseConstants.UniqueValues.ENTITLEMENT_POOL_NAME, + Arrays.asList(mapper.getTableMetadata().getPartitionKey().get(0).getName(), + mapper.getTableMetadata().getPartitionKey().get(1).getName(), "name")))); + + VersioningManagerFactory.getInstance().createInterface() + .register(versionableEntityType, metadata); + } + + @Override + protected Mapper getMapper() { + return mapper; + } + + @Override + protected Object[] getKeys(EntitlementPoolEntity entity) { + return new Object[]{entity.getVendorLicenseModelId(), versionMapper.toUDT(entity.getVersion()), + entity.getId()}; + } + + @Override + public Collection list(EntitlementPoolEntity entity) { + return accessor.listByVlmVersion(entity.getVendorLicenseModelId(), + versionMapper.toUDT(entity.getVersion())).all(); + } + + @Override + public long count(EntitlementPoolEntity entity) { + return accessor.countByVlmVersion(entity.getVendorLicenseModelId(), + versionMapper.toUDT(entity.getVersion())).one().getLong("count"); + } + + @Override + public void deleteAll(EntitlementPoolEntity entity) { + accessor.deleteByVlmVersion(entity.getVendorLicenseModelId(), + versionMapper.toUDT(entity.getVersion())).all(); + } + + @Override + public void addReferencingFeatureGroup(EntitlementPoolEntity entity, + String referencingFeatureGroupId) { + accessor + .addReferencingFeatureGroups(CommonMethods.toSingleElementSet(referencingFeatureGroupId), + entity.getVendorLicenseModelId(), versionMapper.toUDT(entity.getVersion()), + entity.getId()); + } + + @Override + public void removeReferencingFeatureGroup(EntitlementPoolEntity entity, + String referencingFeatureGroupId) { + accessor + .removeReferencingFeatureGroups(CommonMethods.toSingleElementSet(referencingFeatureGroupId), + entity.getVendorLicenseModelId(), versionMapper.toUDT(entity.getVersion()), + entity.getId()); + } + + @Accessor + interface EntitlementPoolAccessor { + + @Query("select * from entitlement_pool where vlm_id=? AND version=?") + Result listByVlmVersion(String vendorLicenseModelId, + UDTValue vendorLicenseModelVersion); + + @Query("delete from entitlement_pool where vlm_id=? AND version=?") + ResultSet deleteByVlmVersion(String vendorLicenseModelId, UDTValue vendorLicenseModelVersion); + + @Query("select count(1) from entitlement_pool where vlm_id=? AND version=?") + ResultSet countByVlmVersion(String vendorLicenseModelId, UDTValue vendorLicenseModelVersion); + + @Query( + "UPDATE entitlement_pool SET ref_fg_ids = ref_fg_ids + ? WHERE vlm_id=? AND version=? " + + "AND ep_id=?") + ResultSet addReferencingFeatureGroups(Set referencingFeatureGroups, + String vendorLicenseModelId, + UDTValue vendorLicenseModelVersion, String id); + + @Query( + "UPDATE entitlement_pool SET ref_fg_ids = ref_fg_ids - ? WHERE vlm_id=? AND version=? " + + "AND ep_id=?") + ResultSet removeReferencingFeatureGroups(Set referencingFeatureGroups, + String vendorLicenseModelId, + UDTValue vendorLicenseModelVersion, String id); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/EntitlementPoolDaoFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/EntitlementPoolDaoFactoryImpl.java new file mode 100644 index 0000000000..c1046f79cd --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/EntitlementPoolDaoFactoryImpl.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao.impl; + +import org.openecomp.sdc.vendorlicense.dao.EntitlementPoolDao; +import org.openecomp.sdc.vendorlicense.dao.EntitlementPoolDaoFactory; + +public class EntitlementPoolDaoFactoryImpl extends EntitlementPoolDaoFactory { + private static EntitlementPoolDao INSTANCE = new EntitlementPoolCassandraDaoImpl(); + + @Override + public EntitlementPoolDao createInterface() { + return INSTANCE; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/FeatureGroupCassandraDaoImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/FeatureGroupCassandraDaoImpl.java new file mode 100644 index 0000000000..86957a02c7 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/FeatureGroupCassandraDaoImpl.java @@ -0,0 +1,206 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao.impl; + +import com.datastax.driver.core.ResultSet; +import com.datastax.driver.core.UDTValue; +import com.datastax.driver.mapping.Mapper; +import com.datastax.driver.mapping.Result; +import com.datastax.driver.mapping.UDTMapper; +import com.datastax.driver.mapping.annotations.Accessor; +import com.datastax.driver.mapping.annotations.Query; +import org.openecomp.core.dao.impl.CassandraBaseDao; +import org.openecomp.core.nosqldb.api.NoSqlDb; +import org.openecomp.core.nosqldb.factory.NoSqlDbFactory; +import org.openecomp.core.utilities.CommonMethods; +import org.openecomp.sdc.vendorlicense.VendorLicenseConstants; +import org.openecomp.sdc.vendorlicense.dao.FeatureGroupDao; +import org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity; +import org.openecomp.sdc.versioning.VersioningManagerFactory; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.types.UniqueValueMetadata; +import org.openecomp.sdc.versioning.types.VersionableEntityMetadata; + +import java.util.Arrays; +import java.util.Collection; +import java.util.Collections; +import java.util.HashSet; +import java.util.Set; + + +public class FeatureGroupCassandraDaoImpl extends CassandraBaseDao + implements FeatureGroupDao { + + private static NoSqlDb noSqlDb = NoSqlDbFactory.getInstance().createInterface(); + private static Mapper mapper = + noSqlDb.getMappingManager().mapper(FeatureGroupEntity.class); + private static FeatureGroupAccessor accessor = + noSqlDb.getMappingManager().createAccessor(FeatureGroupAccessor.class); + private static UDTMapper versionMapper = + noSqlDb.getMappingManager().udtMapper(Version.class); + + private static Set emptyIfNull(Set set) { + return set == null ? new HashSet<>() : set; + } + + @Override + public void registerVersioning(String versionableEntityType) { + VersionableEntityMetadata metadata = new VersionableEntityMetadata( + mapper.getTableMetadata().getName(), + mapper.getTableMetadata().getPartitionKey().get(0).getName(), + mapper.getTableMetadata().getPartitionKey().get(1).getName()); + + metadata.setUniqueValuesMetadata(Collections.singletonList( + new UniqueValueMetadata(VendorLicenseConstants.UniqueValues.FEATURE_GROUP_NAME, + Arrays.asList(mapper.getTableMetadata().getPartitionKey().get(0).getName(), + mapper.getTableMetadata().getPartitionKey().get(1).getName(), "name")))); + + VersioningManagerFactory.getInstance().createInterface() + .register(versionableEntityType, metadata); + } + + @Override + protected Mapper getMapper() { + return mapper; + } + + @Override + protected Object[] getKeys(FeatureGroupEntity entity) { + return new Object[]{entity.getVendorLicenseModelId(), versionMapper.toUDT(entity.getVersion()), + entity.getId()}; + } + + @Override + public long count(FeatureGroupEntity entity) { + return accessor.countByVlmVersion(entity.getVendorLicenseModelId(), + versionMapper.toUDT(entity.getVersion())).one().getLong("count"); + } + + @Override + public void updateFeatureGroup(FeatureGroupEntity entity, + Set addedEntitlementPools, + Set removedEntitlementPools, + Set addedLicenseKeyGroups, + Set removedLicenseKeyGroups) { + accessor.updateColumnsAndDeltaFeatureGroupIds( + entity.getName(), + entity.getDescription(), + entity.getPartNumber(), + emptyIfNull(addedEntitlementPools), + emptyIfNull(removedEntitlementPools), + emptyIfNull(addedLicenseKeyGroups), + emptyIfNull(removedLicenseKeyGroups), + entity.getVendorLicenseModelId(), + versionMapper.toUDT(entity.getVersion()), + entity.getId() + ); + } + + @Override + public Collection list(FeatureGroupEntity entity) { + return accessor.listByVlmVersion(entity.getVendorLicenseModelId(), + versionMapper.toUDT(entity.getVersion())).all(); + } + + @Override + public void deleteAll(FeatureGroupEntity entity) { + accessor.deleteByVlmVersion(entity.getVendorLicenseModelId(), + versionMapper.toUDT(entity.getVersion())).all(); + } + + @Override + public void addReferencingLicenseAgreement(FeatureGroupEntity entity, String licenseAgreementId) { + accessor.addReferencingLicenseAgreements(CommonMethods.toSingleElementSet(licenseAgreementId), + entity.getVendorLicenseModelId(), versionMapper.toUDT(entity.getVersion()), entity.getId()); + } + + @Override + public void removeReferencingLicenseAgreement(FeatureGroupEntity entity, + String licenseAgreementId) { + accessor + .removeReferencingLicenseAgreements(CommonMethods.toSingleElementSet(licenseAgreementId), + entity.getVendorLicenseModelId(), versionMapper.toUDT(entity.getVersion()), + entity.getId()); + } + + @Override + public void removeEntitlementPool(FeatureGroupEntity entity, String entitlementPoolId) { + accessor.removeEntitlementPools(CommonMethods.toSingleElementSet(entitlementPoolId), + entity.getVendorLicenseModelId(), versionMapper.toUDT(entity.getVersion()), entity.getId()); + } + + @Override + public void removeLicenseKeyGroup(FeatureGroupEntity entity, String licenseKeyGroupId) { + accessor.removeLicenseKeyGroup(CommonMethods.toSingleElementSet(licenseKeyGroupId), + entity.getVendorLicenseModelId(), versionMapper.toUDT(entity.getVersion()), entity.getId()); + } + + @Accessor + interface FeatureGroupAccessor { + + @Query("select * from feature_group where vlm_id=? AND version=?") + Result listByVlmVersion(String vendorLicenseModelId, UDTValue version); + + @Query("select count(1) from feature_group where vlm_id=? AND version=?") + ResultSet countByVlmVersion(String vendorLicenseModelId, UDTValue vendorLicenseModelVersion); + + @Query("delete from feature_group where vlm_id=? AND version=?") + ResultSet deleteByVlmVersion(String vendorLicenseModelId, UDTValue vendorLicenseModelVersion); + + @Query( + "update feature_group set name=?,description=?, part_num=?, ep_ids=ep_ids+ ?," + + "ep_ids=ep_ids-?, lkg_ids=lkg_ids+?,lkg_ids=lkg_ids-? WHERE " + + "vlm_id=? AND version=? AND fg_id=?") + ResultSet updateColumnsAndDeltaFeatureGroupIds(String name, String description, + String partNumber, + Set addedEntitlementPools, + Set removedEntitlementPools, + Set addedLicenseKeyGroups, + Set removedLicenseKeyGroups, + String vendorLicenseModelId, UDTValue version, + String id); + + @Query( + "UPDATE feature_group SET ref_la_ids = ref_la_ids " + + "+ ? WHERE vlm_id=? AND version=? AND fg_id=?") + ResultSet addReferencingLicenseAgreements(Set licenseAgreementIds, + String vendorLicenseModelId, UDTValue version, + String id); + + @Query( + "UPDATE feature_group SET ref_la_ids = ref_la_ids - ? " + + "WHERE vlm_id=? AND version=? AND fg_id=?") + ResultSet removeReferencingLicenseAgreements(Set licenseAgreementIds, + String vendorLicenseModelId, UDTValue version, + String id); + + @Query("UPDATE feature_group SET ep_ids = ep_ids - ? WHERE vlm_id=? AND version=? AND fg_id=?") + ResultSet removeEntitlementPools(Set entitlementPoolIds, String vendorLicenseModelId, + UDTValue version, String id); + + @Query( + "UPDATE feature_group SET lkg_ids = lkg_ids - ? WHERE vlm_id=? AND version=? AND fg_id=?") + ResultSet removeLicenseKeyGroup(Set licenseKeyGroupIds, String vendorLicenseModelId, + UDTValue version, String id); + + } +} + diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/FeatureGroupDaoFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/FeatureGroupDaoFactoryImpl.java new file mode 100644 index 0000000000..941b2b5ecc --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/FeatureGroupDaoFactoryImpl.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao.impl; + +import org.openecomp.sdc.vendorlicense.dao.FeatureGroupDao; +import org.openecomp.sdc.vendorlicense.dao.FeatureGroupDaoFactory; + +public class FeatureGroupDaoFactoryImpl extends FeatureGroupDaoFactory { + private static FeatureGroupDao INSTANCE = new FeatureGroupCassandraDaoImpl(); + + @Override + public FeatureGroupDao createInterface() { + return INSTANCE; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/LicenseAgreementCassandraDaoImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/LicenseAgreementCassandraDaoImpl.java new file mode 100644 index 0000000000..6a7cc2aa60 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/LicenseAgreementCassandraDaoImpl.java @@ -0,0 +1,160 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao.impl; + +import com.datastax.driver.core.ResultSet; +import com.datastax.driver.core.UDTValue; +import com.datastax.driver.mapping.Mapper; +import com.datastax.driver.mapping.Result; +import com.datastax.driver.mapping.UDTMapper; +import com.datastax.driver.mapping.annotations.Accessor; +import com.datastax.driver.mapping.annotations.Query; +import org.openecomp.core.dao.impl.CassandraBaseDao; +import org.openecomp.core.nosqldb.api.NoSqlDb; +import org.openecomp.core.nosqldb.factory.NoSqlDbFactory; +import org.openecomp.core.utilities.CommonMethods; +import org.openecomp.sdc.vendorlicense.VendorLicenseConstants; +import org.openecomp.sdc.vendorlicense.dao.LicenseAgreementDao; +import org.openecomp.sdc.vendorlicense.dao.types.ChoiceOrOther; +import org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementEntity; +import org.openecomp.sdc.versioning.VersioningManagerFactory; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.types.UniqueValueMetadata; +import org.openecomp.sdc.versioning.types.VersionableEntityMetadata; + +import java.util.Arrays; +import java.util.Collection; +import java.util.Collections; +import java.util.HashSet; +import java.util.Set; + +public class LicenseAgreementCassandraDaoImpl extends CassandraBaseDao + implements LicenseAgreementDao { + private static NoSqlDb noSqlDb = NoSqlDbFactory.getInstance().createInterface(); + private static Mapper mapper = + noSqlDb.getMappingManager().mapper(LicenseAgreementEntity.class); + private static LicenseAgreementAccessor accessor = + noSqlDb.getMappingManager().createAccessor(LicenseAgreementAccessor.class); + private static UDTMapper choiceOrOtherMapper = + noSqlDb.getMappingManager().udtMapper(ChoiceOrOther.class); + private static UDTMapper versionMapper = + noSqlDb.getMappingManager().udtMapper(Version.class); + + private static Set emptyIfNull(Set set) { + return set == null ? new HashSet<>() : set; + } + + @Override + public void registerVersioning(String versionableEntityType) { + VersionableEntityMetadata metadata = new VersionableEntityMetadata( + mapper.getTableMetadata().getName(), + mapper.getTableMetadata().getPartitionKey().get(0).getName(), + mapper.getTableMetadata().getPartitionKey().get(1).getName()); + + metadata.setUniqueValuesMetadata(Collections.singletonList( + new UniqueValueMetadata(VendorLicenseConstants.UniqueValues.LICENSE_AGREEMENT_NAME, + Arrays.asList(mapper.getTableMetadata().getPartitionKey().get(0).getName(), + mapper.getTableMetadata().getPartitionKey().get(1).getName(), "name")))); + + VersioningManagerFactory.getInstance().createInterface() + .register(versionableEntityType, metadata); + } + + @Override + protected Mapper getMapper() { + return mapper; + } + + @Override + protected Object[] getKeys(LicenseAgreementEntity entity) { + return new Object[]{entity.getVendorLicenseModelId(), versionMapper.toUDT(entity.getVersion()), + entity.getId()}; + } + + @Override + public Collection list(LicenseAgreementEntity entity) { + return accessor.listByVlmVersion(entity.getVendorLicenseModelId(), + versionMapper.toUDT(entity.getVersion())).all(); + } + + @Override + public long count(LicenseAgreementEntity entity) { + return accessor.countByVlmVersion(entity.getVendorLicenseModelId(), + versionMapper.toUDT(entity.getVersion())).one().getLong("count"); + } + + @Override + public void deleteAll(LicenseAgreementEntity entity) { + accessor.deleteByVlmVersion(entity.getVendorLicenseModelId(), + versionMapper.toUDT(entity.getVersion())).all(); + } + + @Override + public void removeFeatureGroup(LicenseAgreementEntity licenseAgreement, String featureGroupId) { + accessor.removeFeatureGroup(CommonMethods.toSingleElementSet(featureGroupId), + licenseAgreement.getVendorLicenseModelId(), + versionMapper.toUDT(licenseAgreement.getVersion()), licenseAgreement.getId()); + } + + @Override + public void updateColumnsAndDeltaFeatureGroupIds(LicenseAgreementEntity licenseAgreement, + Set addedFeatureGroupIds, + Set removedFeatureGroupIds) { + accessor.updateColumnsAndDeltaFeatureGroupIds(licenseAgreement.getName(), + licenseAgreement.getDescription(), + licenseAgreement.getLicenseTerm() == null ? null + : choiceOrOtherMapper.toUDT(licenseAgreement.getLicenseTerm()), + licenseAgreement.getRequirementsAndConstrains(), + emptyIfNull(addedFeatureGroupIds), + emptyIfNull(removedFeatureGroupIds), + licenseAgreement.getVendorLicenseModelId(), + versionMapper.toUDT(licenseAgreement.getVersion()), + licenseAgreement.getId()); + + } + + @Accessor + interface LicenseAgreementAccessor { + + @Query("SELECT * FROM license_agreement WHERE vlm_id=? and version=?") + Result listByVlmVersion(String vendorLicenseModelId, UDTValue version); + + @Query("select count(1) from license_agreement where vlm_id=? AND version=?") + ResultSet countByVlmVersion(String vendorLicenseModelId, UDTValue vendorLicenseModelVersion); + + @Query("delete from license_agreement where vlm_id=? AND version=?") + ResultSet deleteByVlmVersion(String vendorLicenseModelId, UDTValue vendorLicenseModelVersion); + + @Query( + "UPDATE license_agreement SET name=?, description=?, lic_term=?, req_const=?, " + + "fg_ids=fg_ids+?, fg_ids=fg_ids-? WHERE vlm_id=? AND version=? AND la_id=?") + ResultSet updateColumnsAndDeltaFeatureGroupIds(String name, String description, + UDTValue licenseTerm, String reqAndConst, + Set addedFeatureGroupIds, + Set removedFeatureGroupIds, + String vendorLicenseModelId, UDTValue version, + String id); + + @Query("UPDATE license_agreement SET fg_ids=fg_ids-? WHERE vlm_id=? AND version=? AND la_id=?") + ResultSet removeFeatureGroup(Set featureGroupIds, String vendorLicenseModelId, + UDTValue version, String id); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/LicenseAgreementDaoFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/LicenseAgreementDaoFactoryImpl.java new file mode 100644 index 0000000000..d92e2562e9 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/LicenseAgreementDaoFactoryImpl.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao.impl; + +import org.openecomp.sdc.vendorlicense.dao.LicenseAgreementDao; +import org.openecomp.sdc.vendorlicense.dao.LicenseAgreementDaoFactory; + +public class LicenseAgreementDaoFactoryImpl extends LicenseAgreementDaoFactory { + private static LicenseAgreementDao INSTANCE = new LicenseAgreementCassandraDaoImpl(); + + @Override + public LicenseAgreementDao createInterface() { + return INSTANCE; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/LicenseKeyGroupCassandraDaoImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/LicenseKeyGroupCassandraDaoImpl.java new file mode 100644 index 0000000000..c6952c8d03 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/LicenseKeyGroupCassandraDaoImpl.java @@ -0,0 +1,130 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao.impl; + +import com.datastax.driver.core.ResultSet; +import com.datastax.driver.core.UDTValue; +import com.datastax.driver.mapping.Mapper; +import com.datastax.driver.mapping.Result; +import com.datastax.driver.mapping.UDTMapper; +import com.datastax.driver.mapping.annotations.Accessor; +import com.datastax.driver.mapping.annotations.Query; +import org.openecomp.core.dao.impl.CassandraBaseDao; +import org.openecomp.core.nosqldb.api.NoSqlDb; +import org.openecomp.core.nosqldb.factory.NoSqlDbFactory; +import org.openecomp.core.utilities.CommonMethods; +import org.openecomp.sdc.vendorlicense.VendorLicenseConstants; +import org.openecomp.sdc.vendorlicense.dao.LicenseKeyGroupDao; +import org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyGroupEntity; +import org.openecomp.sdc.versioning.VersioningManagerFactory; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.types.UniqueValueMetadata; +import org.openecomp.sdc.versioning.types.VersionableEntityMetadata; + +import java.util.Arrays; +import java.util.Collection; +import java.util.Collections; +import java.util.Set; + + +public class LicenseKeyGroupCassandraDaoImpl extends CassandraBaseDao + implements LicenseKeyGroupDao { + private static NoSqlDb noSqlDb = NoSqlDbFactory.getInstance().createInterface(); + private static Mapper mapper = + noSqlDb.getMappingManager().mapper(LicenseKeyGroupEntity.class); + private static LicenseKeyGroupAccessor accessor = + noSqlDb.getMappingManager().createAccessor(LicenseKeyGroupAccessor.class); + private static UDTMapper versionMapper = + noSqlDb.getMappingManager().udtMapper(Version.class); + + @Override + public void registerVersioning(String versionableEntityType) { + VersionableEntityMetadata metadata = new VersionableEntityMetadata( + mapper.getTableMetadata().getName(), + mapper.getTableMetadata().getPartitionKey().get(0).getName(), + mapper.getTableMetadata().getPartitionKey().get(1).getName()); + + metadata.setUniqueValuesMetadata(Collections.singletonList( + new UniqueValueMetadata(VendorLicenseConstants.UniqueValues.LICENSE_KEY_GROUP_NAME, + Arrays.asList(mapper.getTableMetadata().getPartitionKey().get(0).getName(), + mapper.getTableMetadata().getPartitionKey().get(1).getName(), "name")))); + + VersioningManagerFactory.getInstance().createInterface() + .register(versionableEntityType, metadata); + } + + @Override + protected Mapper getMapper() { + return mapper; + } + + @Override + protected Object[] getKeys(LicenseKeyGroupEntity entity) { + return new Object[]{entity.getVendorLicenseModelId(), versionMapper.toUDT(entity.getVersion()), + entity.getId()}; + } + + @Override + public Collection list(LicenseKeyGroupEntity entity) { + return accessor.listByVlmVersion(entity.getVendorLicenseModelId(), + versionMapper.toUDT(entity.getVersion())).all(); + } + + @Override + public void deleteAll(LicenseKeyGroupEntity entity) { + accessor.deleteByVlmVersion(entity.getVendorLicenseModelId(), + versionMapper.toUDT(entity.getVersion())).all(); + } + + @Override + public void addReferencingFeatureGroup(LicenseKeyGroupEntity entity, String featureGroupId) { + accessor.addReferencingFeatureGroups(CommonMethods.toSingleElementSet(featureGroupId), + entity.getVendorLicenseModelId(), versionMapper.toUDT(entity.getVersion()), entity.getId()); + } + + @Override + public void removeReferencingFeatureGroup(LicenseKeyGroupEntity entity, String featureGroupId) { + accessor.removeReferencingFeatureGroups(CommonMethods.toSingleElementSet(featureGroupId), + entity.getVendorLicenseModelId(), versionMapper.toUDT(entity.getVersion()), entity.getId()); + } + + @Accessor + interface LicenseKeyGroupAccessor { + @Query("select * from license_key_group where vlm_id=? and version=?") + Result listByVlmVersion(String vendorLicenseModelId, UDTValue version); + + @Query("delete from license_key_group where vlm_id=? and version=?") + Result deleteByVlmVersion(String vendorLicenseModelId, UDTValue version); + + @Query( + "UPDATE license_key_group SET ref_fg_ids = ref_fg_ids + ? WHERE vlm_id=? AND version=?" + + " AND lkg_id=?") + ResultSet addReferencingFeatureGroups(Set referencingFeatureGroups, + String vendorLicenseModelId, UDTValue version, String id); + + @Query( + "UPDATE license_key_group SET ref_fg_ids = ref_fg_ids - ? WHERE vlm_id=? AND version=? " + + "AND lkg_id=?") + ResultSet removeReferencingFeatureGroups(Set referencingFeatureGroups, + String vendorLicenseModelId, UDTValue version, + String id); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/LicenseKeyGroupDaoFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/LicenseKeyGroupDaoFactoryImpl.java new file mode 100644 index 0000000000..16d1fd2a3e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/LicenseKeyGroupDaoFactoryImpl.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao.impl; + +import org.openecomp.sdc.vendorlicense.dao.LicenseKeyGroupDao; +import org.openecomp.sdc.vendorlicense.dao.LicenseKeyGroupDaoFactory; + +public class LicenseKeyGroupDaoFactoryImpl extends LicenseKeyGroupDaoFactory { + private static LicenseKeyGroupDao INSTANCE = new LicenseKeyGroupCassandraDaoImpl(); + + @Override + public LicenseKeyGroupDao createInterface() { + return INSTANCE; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/VendorLicenseModelCassandraDaoImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/VendorLicenseModelCassandraDaoImpl.java new file mode 100644 index 0000000000..4d08d98bd7 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/VendorLicenseModelCassandraDaoImpl.java @@ -0,0 +1,91 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao.impl; + +import com.datastax.driver.mapping.Mapper; +import com.datastax.driver.mapping.Result; +import com.datastax.driver.mapping.UDTMapper; +import com.datastax.driver.mapping.annotations.Accessor; +import com.datastax.driver.mapping.annotations.Query; +import org.openecomp.core.dao.impl.CassandraBaseDao; +import org.openecomp.core.nosqldb.api.NoSqlDb; +import org.openecomp.core.nosqldb.factory.NoSqlDbFactory; +import org.openecomp.sdc.vendorlicense.dao.VendorLicenseModelDao; +import org.openecomp.sdc.vendorlicense.dao.types.VendorLicenseModelEntity; +import org.openecomp.sdc.versioning.VersioningManagerFactory; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.types.VersionableEntityMetadata; + +import java.util.Collection; + +public class VendorLicenseModelCassandraDaoImpl extends CassandraBaseDao + implements VendorLicenseModelDao { + + private static NoSqlDb noSqlDb = NoSqlDbFactory.getInstance().createInterface(); + private static Mapper mapper = + noSqlDb.getMappingManager().mapper(VendorLicenseModelEntity.class); + private static VendorLicenseModelAccessor accessor = + noSqlDb.getMappingManager().createAccessor(VendorLicenseModelAccessor.class); + private static UDTMapper versionMapper = + noSqlDb.getMappingManager().udtMapper(Version.class); + + @Override + public void registerVersioning(String versionableEntityType) { + VersioningManagerFactory.getInstance().createInterface() + .register(versionableEntityType, new VersionableEntityMetadata( + mapper.getTableMetadata().getName(), + mapper.getTableMetadata().getPartitionKey().get(0).getName(), + mapper.getTableMetadata().getPartitionKey().get(1).getName())); + } + + @Override + protected Mapper getMapper() { + return mapper; + } + + @Override + protected Object[] getKeys(VendorLicenseModelEntity entity) { + return new Object[]{entity.getId(), versionMapper.toUDT(entity.getVersion())}; + } + + @Override + public Collection list(VendorLicenseModelEntity vendorLicenseModel) { + return accessor.getAll().all(); + } + + // @Override + // public void updateLastModificationTime(VendorLicenseModelEntity vendorLicenseModel){ + // accessor.updateLastModificationTime(vendorLicenseModel.getLastModificationTime(), + // vendorLicenseModel.getId(), versionMapper.toUDT(vendorLicenseModel.getVersion())); + // } + + @Accessor + interface VendorLicenseModelAccessor { + + @Query("SELECT * FROM vendor_license_model") + Result getAll(); + + // @Query("UPDATE vendor_license_model set last_modification_time + // = ? where vlm_id = ? and version = ?") + // ResultSet updateLastModificationTime(Date lastModificationTime, + // String vlmId, UDTValue version); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/VendorLicenseModelDaoFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/VendorLicenseModelDaoFactoryImpl.java new file mode 100644 index 0000000000..d218ca4907 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/dao/impl/VendorLicenseModelDaoFactoryImpl.java @@ -0,0 +1,34 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.dao.impl; + +import org.openecomp.sdc.vendorlicense.dao.VendorLicenseModelDao; +import org.openecomp.sdc.vendorlicense.dao.VendorLicenseModelDaoFactory; + +public class VendorLicenseModelDaoFactoryImpl extends VendorLicenseModelDaoFactory { + + private static VendorLicenseModelDao INSTANCE = new VendorLicenseModelCassandraDaoImpl(); + + @Override + public VendorLicenseModelDao createInterface() { + return INSTANCE; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/facade/impl/VendorLicenseFacadeFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/facade/impl/VendorLicenseFacadeFactoryImpl.java new file mode 100644 index 0000000000..3cf6d0b806 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/facade/impl/VendorLicenseFacadeFactoryImpl.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.facade.impl; + +import org.openecomp.sdc.vendorlicense.facade.VendorLicenseFacade; +import org.openecomp.sdc.vendorlicense.facade.VendorLicenseFacadeFactory; + +public class VendorLicenseFacadeFactoryImpl extends VendorLicenseFacadeFactory { + private static VendorLicenseFacade INSTANCE = new VendorLicenseFacadeImpl(); + + @Override + public VendorLicenseFacade createInterface() { + return INSTANCE; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/facade/impl/VendorLicenseFacadeImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/facade/impl/VendorLicenseFacadeImpl.java new file mode 100644 index 0000000000..678a53583c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/facade/impl/VendorLicenseFacadeImpl.java @@ -0,0 +1,478 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.facade.impl; + +import org.openecomp.core.util.UniqueValueUtil; +import org.openecomp.core.utilities.CommonMethods; +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.common.errors.ErrorCode; +import org.openecomp.sdc.vendorlicense.VendorLicenseConstants; +import org.openecomp.sdc.vendorlicense.dao.EntitlementPoolDao; +import org.openecomp.sdc.vendorlicense.dao.EntitlementPoolDaoFactory; +import org.openecomp.sdc.vendorlicense.dao.FeatureGroupDao; +import org.openecomp.sdc.vendorlicense.dao.FeatureGroupDaoFactory; +import org.openecomp.sdc.vendorlicense.dao.LicenseAgreementDao; +import org.openecomp.sdc.vendorlicense.dao.LicenseAgreementDaoFactory; +import org.openecomp.sdc.vendorlicense.dao.LicenseKeyGroupDao; +import org.openecomp.sdc.vendorlicense.dao.LicenseKeyGroupDaoFactory; +import org.openecomp.sdc.vendorlicense.dao.VendorLicenseModelDao; +import org.openecomp.sdc.vendorlicense.dao.VendorLicenseModelDaoFactory; +import org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity; +import org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity; +import org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupModel; +import org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementEntity; +import org.openecomp.sdc.vendorlicense.dao.types.LicenseAgreementModel; +import org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyGroupEntity; +import org.openecomp.sdc.vendorlicense.dao.types.VendorLicenseModelEntity; +import org.openecomp.sdc.vendorlicense.errors.SubmitUncompletedLicenseModelErrorBuilder; +import org.openecomp.sdc.vendorlicense.errors.VendorLicenseModelNotFoundErrorBuilder; +import org.openecomp.sdc.vendorlicense.facade.VendorLicenseFacade; +import org.openecomp.sdc.vendorlicense.types.VersionedVendorLicenseModel; +import org.openecomp.sdc.versioning.VersioningManager; +import org.openecomp.sdc.versioning.VersioningManagerFactory; +import org.openecomp.sdc.versioning.VersioningUtil; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.errors.RequestedVersionInvalidErrorBuilder; +import org.openecomp.sdc.versioning.errors.VersionableSubEntityNotFoundErrorBuilder; +import org.openecomp.sdc.versioning.types.VersionInfo; +import org.openecomp.sdc.versioning.types.VersionableEntityAction; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.Collections; +import java.util.List; + + +public class VendorLicenseFacadeImpl + implements VendorLicenseFacade { + + + private static final VersioningManager versioningManager = + VersioningManagerFactory.getInstance().createInterface(); + + private static final VendorLicenseModelDao vendorLicenseModelDao = + VendorLicenseModelDaoFactory.getInstance().createInterface(); + private static final LicenseAgreementDao licenseAgreementDao = + LicenseAgreementDaoFactory.getInstance().createInterface(); + private static final FeatureGroupDao featureGroupDao = + FeatureGroupDaoFactory.getInstance().createInterface(); + private static final EntitlementPoolDao entitlementPoolDao = + EntitlementPoolDaoFactory.getInstance().createInterface(); + private static final LicenseKeyGroupDao licenseKeyGroupDao = + LicenseKeyGroupDaoFactory.getInstance().createInterface(); + + /** + * Instantiates a new Vendor license facade. + */ + public VendorLicenseFacadeImpl() { + vendorLicenseModelDao + .registerVersioning(VendorLicenseConstants.VENDOR_LICENSE_MODEL_VERSIONABLE_TYPE); + licenseAgreementDao + .registerVersioning(VendorLicenseConstants.VENDOR_LICENSE_MODEL_VERSIONABLE_TYPE); + featureGroupDao + .registerVersioning(VendorLicenseConstants.VENDOR_LICENSE_MODEL_VERSIONABLE_TYPE); + entitlementPoolDao + .registerVersioning(VendorLicenseConstants.VENDOR_LICENSE_MODEL_VERSIONABLE_TYPE); + licenseKeyGroupDao + .registerVersioning(VendorLicenseConstants.VENDOR_LICENSE_MODEL_VERSIONABLE_TYPE); + } + + @Override + public void checkin(String vendorLicenseModelId, String user) { + Version newVersion = versioningManager + .checkin(VendorLicenseConstants + .VENDOR_LICENSE_MODEL_VERSIONABLE_TYPE, + vendorLicenseModelId, user, null); + updateVlmLastModificationTime(vendorLicenseModelId, newVersion); + } + + @Override + public void submit(String vendorLicenseModelId, String user) { + validateCompletedVendorLicenseModel(vendorLicenseModelId, user); + Version newVersion = versioningManager + .submit(VendorLicenseConstants + .VENDOR_LICENSE_MODEL_VERSIONABLE_TYPE, + vendorLicenseModelId, user, null); + updateVlmLastModificationTime(vendorLicenseModelId, newVersion); + } + + @Override + public FeatureGroupEntity getFeatureGroup(FeatureGroupEntity featureGroup, String user) { + Version version = VersioningUtil.resolveVersion(featureGroup.getVersion(), + getVersionInfo(featureGroup.getVendorLicenseModelId(), VersionableEntityAction.Read, user)); + featureGroup.setVersion(version); + return getFeatureGroup(featureGroup); + } + + private FeatureGroupEntity getFeatureGroup(FeatureGroupEntity featureGroup) { + FeatureGroupEntity retrieved = featureGroupDao.get(featureGroup); + VersioningUtil + .validateEntityExistence(retrieved, featureGroup, VendorLicenseModelEntity.ENTITY_TYPE); + return retrieved; + } + + @Override + public FeatureGroupModel getFeatureGroupModel(FeatureGroupEntity featureGroup, String user) { + FeatureGroupEntity retrieved = getFeatureGroup(featureGroup, user); + + FeatureGroupModel featureGroupModel = new FeatureGroupModel(); + featureGroupModel.setFeatureGroup(retrieved); + + for (String licenseKeyGroupId : retrieved.getLicenseKeyGroupIds()) { + featureGroupModel.getLicenseKeyGroups().add(licenseKeyGroupDao.get( + new LicenseKeyGroupEntity(retrieved.getVendorLicenseModelId(), retrieved.getVersion(), + licenseKeyGroupId))); + } + for (String entitlementPoolId : retrieved.getEntitlementPoolIds()) { + featureGroupModel.getEntitlementPools().add(entitlementPoolDao.get( + new EntitlementPoolEntity(retrieved.getVendorLicenseModelId(), retrieved.getVersion(), + entitlementPoolId))); + } + + return featureGroupModel; + } + + @Override + public LicenseAgreementEntity getLicenseAgreement(String vlmId, Version version, + String licenseAgreementId, String user) { + return getLicenseAgreement(vlmId, licenseAgreementId, VersioningUtil + .resolveVersion(version, getVersionInfo(vlmId, VersionableEntityAction.Read, user))); + } + + private LicenseAgreementEntity getLicenseAgreement(String vlmId, String licenseAgreementId, + Version version) { + LicenseAgreementEntity input = new LicenseAgreementEntity(vlmId, version, licenseAgreementId); + LicenseAgreementEntity retrieved = licenseAgreementDao.get(input); + VersioningUtil.validateEntityExistence(retrieved, input, VendorLicenseModelEntity.ENTITY_TYPE); + return retrieved; + } + + @Override + public LicenseAgreementModel getLicenseAgreementModel(String vlmId, Version version, + String licenseAgreementId, String user) { + LicenseAgreementEntity retrieved = + getLicenseAgreement(vlmId, version, licenseAgreementId, user); + + LicenseAgreementModel licenseAgreementModel = new LicenseAgreementModel(); + licenseAgreementModel.setLicenseAgreement(retrieved); + + for (String featureGroupId : retrieved.getFeatureGroupIds()) { + licenseAgreementModel.getFeatureGroups().add(featureGroupDao + .get(new FeatureGroupEntity(vlmId, retrieved.getVersion(), featureGroupId))); + } + + return licenseAgreementModel; + } + + @Override + public EntitlementPoolEntity createEntitlementPool(EntitlementPoolEntity entitlementPool, + String user) { + entitlementPool.setVersion( + getVersionInfo(entitlementPool.getVendorLicenseModelId(), VersionableEntityAction.Write, + user).getActiveVersion()); + entitlementPool.setId(CommonMethods.nextUuId()); + entitlementPool.setVersionUuId(CommonMethods.nextUuId()); + UniqueValueUtil.createUniqueValue(VendorLicenseConstants.UniqueValues.ENTITLEMENT_POOL_NAME, + entitlementPool.getVendorLicenseModelId(), entitlementPool.getVersion().toString(), + entitlementPool.getName()); + entitlementPoolDao.create(entitlementPool); + updateVlmLastModificationTime(entitlementPool.getVendorLicenseModelId(), + entitlementPool.getVersion()); + return entitlementPool; + } + + @Override + public LicenseKeyGroupEntity createLicenseKeyGroup(LicenseKeyGroupEntity licenseKeyGroup, + String user) { + licenseKeyGroup.setVersion( + getVersionInfo(licenseKeyGroup.getVendorLicenseModelId(), VersionableEntityAction.Write, + user).getActiveVersion()); + licenseKeyGroup.setId(CommonMethods.nextUuId()); + licenseKeyGroup.setVersionUuId(CommonMethods.nextUuId()); + UniqueValueUtil.createUniqueValue(VendorLicenseConstants.UniqueValues.LICENSE_KEY_GROUP_NAME, + licenseKeyGroup.getVendorLicenseModelId(), licenseKeyGroup.getVersion().toString(), + licenseKeyGroup.getName()); + licenseKeyGroupDao.create(licenseKeyGroup); + updateVlmLastModificationTime(licenseKeyGroup.getVendorLicenseModelId(), + licenseKeyGroup.getVersion()); + return licenseKeyGroup; + } + + @Override + public void updateEntitlementPool(EntitlementPoolEntity entitlementPool, String user) { + entitlementPool.setVersion( + getVersionInfo(entitlementPool.getVendorLicenseModelId(), VersionableEntityAction.Write, + user).getActiveVersion()); + EntitlementPoolEntity retrieved = entitlementPoolDao.get(entitlementPool); + VersioningUtil + .validateEntityExistence(retrieved, entitlementPool, VendorLicenseModelEntity.ENTITY_TYPE); + + UniqueValueUtil.updateUniqueValue(VendorLicenseConstants.UniqueValues.ENTITLEMENT_POOL_NAME, + retrieved.getName(), entitlementPool.getName(), entitlementPool.getVendorLicenseModelId(), + entitlementPool.getVersion().toString()); + entitlementPool.setVersionUuId(CommonMethods.nextUuId()); + entitlementPoolDao.update(entitlementPool); + + updateVlmLastModificationTime(entitlementPool.getVendorLicenseModelId(), + entitlementPool.getVersion()); + + } + + @Override + public Collection listLicenseKeyGroups(String vlmId, Version version, + String user) { + return licenseKeyGroupDao.list(new LicenseKeyGroupEntity(vlmId, VersioningUtil + .resolveVersion(version, getVersionInfo(vlmId, VersionableEntityAction.Read, user)), null)); + } + + @Override + public Collection listEntitlementPools(String vlmId, Version version, + String user) { + return entitlementPoolDao.list(new EntitlementPoolEntity(vlmId, VersioningUtil + .resolveVersion(version, getVersionInfo(vlmId, VersionableEntityAction.Read, user)), null)); + } + + @Override + public void updateLicenseKeyGroup(LicenseKeyGroupEntity licenseKeyGroup, String user) { + licenseKeyGroup.setVersion( + getVersionInfo(licenseKeyGroup.getVendorLicenseModelId(), VersionableEntityAction.Write, + user).getActiveVersion()); + LicenseKeyGroupEntity retrieved = licenseKeyGroupDao.get(licenseKeyGroup); + licenseKeyGroup.setVersionUuId((CommonMethods.nextUuId())); + VersioningUtil + .validateEntityExistence(retrieved, licenseKeyGroup, VendorLicenseModelEntity.ENTITY_TYPE); + UniqueValueUtil.updateUniqueValue(VendorLicenseConstants.UniqueValues.LICENSE_KEY_GROUP_NAME, + retrieved.getName(), licenseKeyGroup.getName(), licenseKeyGroup.getVendorLicenseModelId(), + licenseKeyGroup.getVersion().toString()); + licenseKeyGroupDao.update(licenseKeyGroup); + + updateVlmLastModificationTime(licenseKeyGroup.getVendorLicenseModelId(), + licenseKeyGroup.getVersion()); + } + + + @Override + public VersionInfo getVersionInfo(String vendorLicenseModelId, VersionableEntityAction action, + String user) { + return versioningManager + .getEntityVersionInfo(VendorLicenseConstants + .VENDOR_LICENSE_MODEL_VERSIONABLE_TYPE, + vendorLicenseModelId, user, + action); + } + + @Override + public VersionedVendorLicenseModel getVendorLicenseModel(String vlmId, Version version, + String user) { + VersionInfo versionInfo = getVersionInfo(vlmId, VersionableEntityAction.Read, user); + + VendorLicenseModelEntity vendorLicenseModel = vendorLicenseModelDao.get( + new VendorLicenseModelEntity(vlmId, VersioningUtil.resolveVersion(version, versionInfo))); + if (vendorLicenseModel == null) { + throw new CoreException(new VendorLicenseModelNotFoundErrorBuilder(vlmId).build()); + } + + return new VersionedVendorLicenseModel(vendorLicenseModel, versionInfo); + } + + @Override + public VendorLicenseModelEntity createVendorLicenseModel( + VendorLicenseModelEntity vendorLicenseModelEntity, String user) { + UniqueValueUtil.validateUniqueValue(VendorLicenseConstants.UniqueValues.VENDOR_NAME, + vendorLicenseModelEntity.getVendorName()); + vendorLicenseModelEntity.setId(CommonMethods.nextUuId()); + + Version version = versioningManager + .create(VendorLicenseConstants + .VENDOR_LICENSE_MODEL_VERSIONABLE_TYPE, + vendorLicenseModelEntity.getId(), user); + vendorLicenseModelEntity.setVersion(version); + + // vendorLicenseModelEntity.setLastModificationTime(new Date()); + + vendorLicenseModelDao.create(vendorLicenseModelEntity); + UniqueValueUtil.createUniqueValue(VendorLicenseConstants.UniqueValues.VENDOR_NAME, + vendorLicenseModelEntity.getVendorName()); + + return vendorLicenseModelEntity; + } + + @Override + public LicenseAgreementEntity createLicenseAgreement(LicenseAgreementEntity licenseAgreement, + String user) { + Version activeVersion = + getVersionInfo(licenseAgreement.getVendorLicenseModelId(), VersionableEntityAction.Write, + user).getActiveVersion(); + licenseAgreement.setVersion(activeVersion); + licenseAgreement.setId(CommonMethods.nextUuId()); + VersioningUtil.validateEntitiesExistence(licenseAgreement.getFeatureGroupIds(), + new FeatureGroupEntity(licenseAgreement.getVendorLicenseModelId(), activeVersion, null), + featureGroupDao, VendorLicenseModelEntity.ENTITY_TYPE); + UniqueValueUtil.validateUniqueValue(VendorLicenseConstants.UniqueValues.LICENSE_AGREEMENT_NAME, + licenseAgreement.getVendorLicenseModelId(), licenseAgreement.getVersion().toString(), + licenseAgreement.getName()); + + if (licenseAgreement.getFeatureGroupIds() != null) { + for (String addedFgId : licenseAgreement.getFeatureGroupIds()) { + featureGroupDao.addReferencingLicenseAgreement( + new FeatureGroupEntity(licenseAgreement.getVendorLicenseModelId(), activeVersion, + addedFgId), licenseAgreement.getId()); + } + } + + licenseAgreementDao.create(licenseAgreement); + UniqueValueUtil.createUniqueValue(VendorLicenseConstants.UniqueValues.LICENSE_AGREEMENT_NAME, + licenseAgreement.getVendorLicenseModelId(), licenseAgreement.getVersion().toString(), + licenseAgreement.getName()); + + updateVlmLastModificationTime(licenseAgreement.getVendorLicenseModelId(), + licenseAgreement.getVersion()); + + return licenseAgreement; + } + + @Override + public FeatureGroupEntity createFeatureGroup(FeatureGroupEntity featureGroup, String user) { + Version activeVersion = + getVersionInfo(featureGroup.getVendorLicenseModelId(), VersionableEntityAction.Write, user) + .getActiveVersion(); + featureGroup.setId(CommonMethods.nextUuId()); + featureGroup.setVersion(activeVersion); + VersioningUtil.validateEntitiesExistence(featureGroup.getLicenseKeyGroupIds(), + new LicenseKeyGroupEntity(featureGroup.getVendorLicenseModelId(), activeVersion, null), + licenseKeyGroupDao, VendorLicenseModelEntity.ENTITY_TYPE); + VersioningUtil.validateEntitiesExistence(featureGroup.getEntitlementPoolIds(), + new EntitlementPoolEntity(featureGroup.getVendorLicenseModelId(), activeVersion, null), + entitlementPoolDao, VendorLicenseModelEntity.ENTITY_TYPE); + UniqueValueUtil.validateUniqueValue(VendorLicenseConstants.UniqueValues.FEATURE_GROUP_NAME, + featureGroup.getVendorLicenseModelId(), featureGroup.getVersion().toString(), + featureGroup.getName()); + + if (featureGroup.getLicenseKeyGroupIds() != null) { + for (String addedLkgId : featureGroup.getLicenseKeyGroupIds()) { + licenseKeyGroupDao.addReferencingFeatureGroup( + new LicenseKeyGroupEntity(featureGroup.getVendorLicenseModelId(), activeVersion, + addedLkgId), featureGroup.getId()); + } + } + + if (featureGroup.getEntitlementPoolIds() != null) { + for (String addedEpId : featureGroup.getEntitlementPoolIds()) { + entitlementPoolDao.addReferencingFeatureGroup( + new EntitlementPoolEntity(featureGroup.getVendorLicenseModelId(), activeVersion, + addedEpId), featureGroup.getId()); + } + } + + featureGroupDao.create(featureGroup); + UniqueValueUtil.createUniqueValue(VendorLicenseConstants.UniqueValues.FEATURE_GROUP_NAME, + featureGroup.getVendorLicenseModelId(), featureGroup.getVersion().toString(), + featureGroup.getName()); + + updateVlmLastModificationTime(featureGroup.getVendorLicenseModelId(), + featureGroup.getVersion()); + + return featureGroup; + } + + + @Override + public Collection validateLicensingData(String vlmId, Version version, + String licenseAgreementId, + Collection featureGroupIds) { + try { + VersionInfo versionInfo = getVersionInfo(vlmId, VersionableEntityAction.Read, ""); + if (version == null || !version.isFinal() + || !versionInfo.getViewableVersions().contains(version)) { + return Collections.singletonList(new RequestedVersionInvalidErrorBuilder().build()); + } + } catch (CoreException coreException) { + return Collections.singletonList(coreException.code()); + } + + List errorMessages = new ArrayList<>(); + + try { + getLicenseAgreement(vlmId, licenseAgreementId, version); + } catch (CoreException coreException) { + errorMessages.add(coreException.code()); + } + + for (String featureGroupId : featureGroupIds) { + try { + FeatureGroupEntity featureGroup = + getFeatureGroup(new FeatureGroupEntity(vlmId, version, featureGroupId)); + if (!featureGroup.getReferencingLicenseAgreements().contains(licenseAgreementId)) { + errorMessages.add(new VersionableSubEntityNotFoundErrorBuilder( + featureGroup.getEntityType(), + featureGroupId, + LicenseAgreementEntity.ENTITY_TYPE, + licenseAgreementId, + version).build()); + } + } catch (CoreException coreException) { + errorMessages.add(coreException.code()); + } + } + + return errorMessages; + } + + @Override + public void updateVlmLastModificationTime(String vendorLicenseModelId, Version version) { + VendorLicenseModelEntity retrieved = + vendorLicenseModelDao.get(new VendorLicenseModelEntity(vendorLicenseModelId, version)); + vendorLicenseModelDao.update(retrieved); + // entity.setLastModificationTime(new Date()); + // + // vendorLicenseModelDao.updateLastModificationTime(entity); + } + + private void validateCompletedVendorLicenseModel(String vendorLicenseModelId, String user) { + Version activeVersion = + getVersionInfo(vendorLicenseModelId, VersionableEntityAction.Read, user).getActiveVersion(); + Collection licenseAgreements = licenseAgreementDao + .list(new LicenseAgreementEntity(vendorLicenseModelId, activeVersion, null)); + + if (licenseAgreements == null || licenseAgreements.isEmpty()) { + throw new CoreException( + new SubmitUncompletedLicenseModelErrorBuilder(vendorLicenseModelId).build()); + } + + for (LicenseAgreementEntity licenseAgreement : licenseAgreements) { + if (licenseAgreement.getFeatureGroupIds() == null + || licenseAgreement.getFeatureGroupIds().isEmpty()) { + throw new CoreException( + new SubmitUncompletedLicenseModelErrorBuilder(vendorLicenseModelId).build()); + } + } + + Collection featureGroupEntities = featureGroupDao + .list(new FeatureGroupEntity(vendorLicenseModelId, activeVersion, null)); + for (FeatureGroupEntity featureGroupEntity : featureGroupEntities) { + if (featureGroupEntity.getEntitlementPoolIds() == null + || featureGroupEntity.getEntitlementPoolIds().isEmpty()) { + throw new CoreException( + new SubmitUncompletedLicenseModelErrorBuilder(vendorLicenseModelId).build()); + } + } + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/healing/impl/SimpleHealingServiceImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/healing/impl/SimpleHealingServiceImpl.java new file mode 100644 index 0000000000..8f8f34e471 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/healing/impl/SimpleHealingServiceImpl.java @@ -0,0 +1,63 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.healing.impl; + +import org.openecomp.sdc.vendorlicense.dao.EntitlementPoolDao; +import org.openecomp.sdc.vendorlicense.dao.EntitlementPoolDaoFactory; +import org.openecomp.sdc.vendorlicense.dao.LicenseKeyGroupDao; +import org.openecomp.sdc.vendorlicense.dao.LicenseKeyGroupDaoFactory; +import org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity; +import org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyGroupEntity; +import org.openecomp.sdc.vendorlicense.healing.HealingService; +import org.openecomp.sdc.versioning.dao.types.VersionableEntity; + +public class SimpleHealingServiceImpl implements HealingService { + private static final EntitlementPoolDao entitlementPoolDao = + EntitlementPoolDaoFactory.getInstance().createInterface(); + private static final LicenseKeyGroupDao licenseKeyGroupDao = + LicenseKeyGroupDaoFactory.getInstance().createInterface(); + + @Override + public VersionableEntity heal(VersionableEntity toHeal, String user) { + return handleMissingVersionId(toHeal, user); + } + + private VersionableEntity handleMissingVersionId(VersionableEntity toHeal, String user) { + if (toHeal.getVersionUuId() != null) { + return toHeal; + } + + + if (toHeal instanceof EntitlementPoolEntity) { + toHeal.setVersionUuId(toHeal.getId()); + entitlementPoolDao.update((EntitlementPoolEntity) toHeal); + } else if (toHeal instanceof LicenseKeyGroupEntity) { + toHeal.setVersionUuId(toHeal.getId()); + licenseKeyGroupDao.update((LicenseKeyGroupEntity) toHeal); + } else { + throw new UnsupportedOperationException( + "Unsupported operation for 1610 release/1607->1610 migration."); + //todo maybe errorbuilder? + } + return toHeal; + } + +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/VendorLicenseArtifactsServiceImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/VendorLicenseArtifactsServiceImpl.java new file mode 100644 index 0000000000..2f11b75a98 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/VendorLicenseArtifactsServiceImpl.java @@ -0,0 +1,200 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.licenseartifacts.impl; + +import org.apache.commons.collections4.MultiValuedMap; +import org.apache.commons.collections4.multimap.ArrayListValuedHashMap; +import org.openecomp.core.utilities.file.FileContentHandler; +import org.openecomp.sdc.vendorlicense.HealingServiceFactory; +import org.openecomp.sdc.vendorlicense.VendorLicenseConstants; +import org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity; +import org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity; +import org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupModel; +import org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyGroupEntity; +import org.openecomp.sdc.vendorlicense.facade.VendorLicenseFacade; +import org.openecomp.sdc.vendorlicense.facade.VendorLicenseFacadeFactory; +import org.openecomp.sdc.vendorlicense.healing.HealingService; +import org.openecomp.sdc.vendorlicense.licenseartifacts.VendorLicenseArtifactsService; +import org.openecomp.sdc.vendorlicense.licenseartifacts.impl.types.VendorLicenseArtifact; +import org.openecomp.sdc.vendorlicense.licenseartifacts.impl.types.VnfLicenseArtifact; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.dao.types.VersionableEntity; +import org.openecomp.sdc.versioning.types.VersionInfo; +import org.openecomp.sdc.versioning.types.VersionableEntityAction; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Set; +import java.util.stream.Collectors; + +public class VendorLicenseArtifactsServiceImpl implements VendorLicenseArtifactsService { + + private static final VendorLicenseFacade vendorLicenseFacade = VendorLicenseFacadeFactory + .getInstance().createInterface(); + private static final HealingService healingService = HealingServiceFactory + .getInstance().createInterface(); + + /** + * Create License Artifacts. + * + * @param vspId the vsp id + * @param vlmId the vlm id + * @param vlmVersion the vlm version + * @param featureGroups the feature groups + * @param user the user + * @return FileContentHandler + */ + public FileContentHandler createLicenseArtifacts(String vspId, String vlmId, + Version vlmVersion, + List featureGroups, String user) { + FileContentHandler artifacts = new FileContentHandler(); + String vendorName = getVendorName(vlmId, user); + + artifacts.addFile(VendorLicenseConstants.VNF_ARTIFACT_NAME_WITH_PATH, + createVnfArtifact(vspId, vlmId, vlmVersion, vendorName, featureGroups, user)); + artifacts.addFile(VendorLicenseConstants.VENDOR_LICENSE_MODEL_ARTIFACT_NAME_WITH_PATH, + createVendorLicenseArtifact(vlmId, vendorName, user)); + + return artifacts; + } + + static byte[] createVnfArtifact( + String vspId, String vlmId, Version vlmVersion, + String vendorName, List featureGroups, + String user) { + VnfLicenseArtifact artifact = new VnfLicenseArtifact(); + + artifact.setVspId(vspId); + artifact.setVendorName(vendorName); + for (String featureGroupId : featureGroups) { + FeatureGroupModel featureGroupModel = + vendorLicenseFacade.getFeatureGroupModel(new FeatureGroupEntity( + vlmId, vlmVersion, featureGroupId), user); + Set entitlementPoolEntities = featureGroupModel.getEntitlementPools(); + Set licenseKeyGroupEntities = featureGroupModel.getLicenseKeyGroups(); + + featureGroupModel.setEntitlementPools( + entitlementPoolEntities.stream() + .map(entitlementPoolEntity -> (EntitlementPoolEntity) healingService + .heal(entitlementPoolEntity, user)) + .collect(Collectors.toSet())); + featureGroupModel.setLicenseKeyGroups( + licenseKeyGroupEntities.stream() + .map(licenseKeyGroupEntity -> (LicenseKeyGroupEntity) healingService + .heal(licenseKeyGroupEntity, user)) + .collect(Collectors.toSet())); + artifact.getFeatureGroups().add(featureGroupModel); + } + + return artifact.toXml().getBytes(); + } + + + static byte[] createVendorLicenseArtifact(String vlmId, String vendorName, String user) { + VendorLicenseArtifact vendorLicenseArtifact = new VendorLicenseArtifact(); + vendorLicenseArtifact.setVendorName(vendorName); + Set entitlementPoolEntities = new HashSet<>(); + Set licenseKeyGroupEntities = new HashSet<>(); + + List finalVersions = getFinalVersionsForVlm(vlmId); + for (Version finalVersion : finalVersions) { + entitlementPoolEntities.addAll( + vendorLicenseFacade.listEntitlementPools(vlmId, finalVersion, user)); + licenseKeyGroupEntities.addAll( + vendorLicenseFacade.listLicenseKeyGroups(vlmId, finalVersion, user)); + } + + + entitlementPoolEntities = healEPs(user, filterChangedEntities(entitlementPoolEntities)); + licenseKeyGroupEntities = healLkgs(user, filterChangedEntities(licenseKeyGroupEntities)); + + vendorLicenseArtifact.setEntitlementPoolEntities(entitlementPoolEntities); + vendorLicenseArtifact.setLicenseKeyGroupEntities(licenseKeyGroupEntities); + return vendorLicenseArtifact.toXml().getBytes(); + } + + private static List filterChangedEntities( + Collection versionableEntities) { + MultiValuedMap entitiesById = mapById(versionableEntities); + Map entitiesByVersionUuId = new HashMap<>(); + List changedOnly = new ArrayList<>(); + + for (String epId : entitiesById.keySet()) { + Collection versionableEntitiesForId = entitiesById.get(epId); + for (VersionableEntity ep : versionableEntitiesForId) { + entitiesByVersionUuId.put(ep.getVersionUuId(), ep); + } + } + + changedOnly.addAll(entitiesByVersionUuId.values()); + + return changedOnly; + } + + private static MultiValuedMap mapById( + Collection versionableEntities) { + MultiValuedMap mappedById = new ArrayListValuedHashMap<>(); + for (VersionableEntity ve : versionableEntities) { + mappedById.put(ve.getId(), ve); + } + return mappedById; + } + + + private static Set healLkgs( + String user, Collection licenseKeyGroupEntities) { + Set healed = new HashSet<>(); + for (VersionableEntity licenseKeyGroupEntity : licenseKeyGroupEntities) { + healed.add((LicenseKeyGroupEntity) healingService.heal(licenseKeyGroupEntity, user)); + } + + return healed; + } + + private static Set healEPs( + String user, Collection entitlementPoolEntities) { + Set healed = new HashSet<>(); + for (VersionableEntity entitlementPoolEntity : entitlementPoolEntities) { + healed.add((EntitlementPoolEntity) healingService.heal(entitlementPoolEntity, user)); + } + + return healed; + } + + private static List getFinalVersionsForVlm(String vlmId) { + VersionInfo versionInfo = vendorLicenseFacade + .getVersionInfo(vlmId, VersionableEntityAction.Read, ""); + return versionInfo.getFinalVersions(); + + } + + + private static String getVendorName(String vendorLicenseModelId, String user) { + return vendorLicenseFacade + .getVendorLicenseModel(vendorLicenseModelId, null, user) + .getVendorLicenseModel().getVendorName(); + } + +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/FeatureGroupForArtifact.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/FeatureGroupForArtifact.java new file mode 100644 index 0000000000..6dddb9ac69 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/FeatureGroupForArtifact.java @@ -0,0 +1,60 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.licenseartifacts.impl.types; + +import org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity; +import org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyGroupEntity; + +import java.util.ArrayList; +import java.util.Collection; + +public class FeatureGroupForArtifact { + Collection entitlementPoolEntities = new ArrayList<>(); + Collection licenseKeyGroupEntities = new ArrayList<>(); + private String name; + private String description; + private String partNumber; + private String id; + + public String getName() { + return name; + } + + public String getDescription() { + return description; + } + + public String getPartNumber() { + return partNumber; + } + + public String getId() { + return id; + } + + public Collection getEntitlementPoolEntities() { + return entitlementPoolEntities; + } + + public Collection getLicenseKeyGroupEntities() { + return licenseKeyGroupEntities; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/VendorLicenseArtifact.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/VendorLicenseArtifact.java new file mode 100644 index 0000000000..589b7fa668 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/VendorLicenseArtifact.java @@ -0,0 +1,80 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.licenseartifacts.impl.types; + +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlElementWrapper; +import com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlProperty; +import com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlRootElement; +import org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity; +import org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyGroupEntity; +import org.openecomp.sdc.vendorlicense.licenseartifacts.impl.types.mixins.MixinEntitlementPoolEntityForVendorLicenseArtifact; +import org.openecomp.sdc.vendorlicense.licenseartifacts.impl.types.mixins.MixinLicenseKeyGroupEntityForVendorLicenseArtifact; + +import java.util.Collection; + +@JacksonXmlRootElement(localName = "vendor-license-model", + namespace = "http://xmlns.openecomp.org/asdc/license-model/1.0") +public class VendorLicenseArtifact extends XmlArtifact { + @JsonProperty(value = "vendor-name") + String vendorName; + + Collection entitlementPoolEntities; + Collection licenseKeyGroupEntities; + + public String getVendorName() { + return vendorName; + } + + public void setVendorName(String vendorName) { + this.vendorName = vendorName; + } + + @JacksonXmlProperty(isAttribute = false, localName = "entitlement-pool") + @JacksonXmlElementWrapper(localName = "entitlement-pool-list") + public Collection getEntitlementPoolEntities() { + return entitlementPoolEntities; + } + + public void setEntitlementPoolEntities( + Collection entitlementPoolEntities) { + this.entitlementPoolEntities = entitlementPoolEntities; + } + + @JacksonXmlProperty(isAttribute = false, localName = "license-key-group") + @JacksonXmlElementWrapper(localName = "license-key-group-list") + public Collection getLicenseKeyGroupEntities() { + return licenseKeyGroupEntities; + } + + public void setLicenseKeyGroupEntities( + Collection licenseKeyGroupEntities) { + this.licenseKeyGroupEntities = licenseKeyGroupEntities; + } + + @Override + void initMapper() { + xmlMapper.addMixIn(EntitlementPoolEntity.class, + MixinEntitlementPoolEntityForVendorLicenseArtifact.class); + xmlMapper.addMixIn(LicenseKeyGroupEntity.class, + MixinLicenseKeyGroupEntityForVendorLicenseArtifact.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/VnfLicenseArtifact.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/VnfLicenseArtifact.java new file mode 100644 index 0000000000..1f8607765a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/VnfLicenseArtifact.java @@ -0,0 +1,97 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.licenseartifacts.impl.types; + +import com.ctc.wstx.api.WstxInputProperties; +import com.ctc.wstx.stax.WstxInputFactory; +import com.ctc.wstx.stax.WstxOutputFactory; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.dataformat.xml.XmlFactory; +import com.fasterxml.jackson.dataformat.xml.XmlMapper; +import com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlElementWrapper; +import com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlProperty; +import com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlRootElement; +import org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity; +import org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupModel; +import org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyGroupEntity; +import org.openecomp.sdc.vendorlicense.licenseartifacts.impl.types.mixins.MixinEntitlementPoolEntityForVnfArtifact; +import org.openecomp.sdc.vendorlicense.licenseartifacts.impl.types.mixins.MixinFeatureGroupModel; +import org.openecomp.sdc.vendorlicense.licenseartifacts.impl.types.mixins.MixinLicenseKeyGroupEntityForVnfArtifact; + +import java.io.Writer; +import java.util.ArrayList; +import java.util.List; +import javax.xml.stream.XMLStreamException; +import javax.xml.stream.XMLStreamWriter; + +@JacksonXmlRootElement(localName = "vf-license-model", + namespace = "http://xmlns.openecomp.org/asdc/license-model/1.0") +public class VnfLicenseArtifact extends XmlArtifact { + @JsonProperty(value = "vendor-name") + String vendorName; + @JsonProperty(value = "vf-id") + String vspId; + List featureGroups = new ArrayList<>(); + + public String getVspId() { + return vspId; + } + + public void setVspId(String vspId) { + this.vspId = vspId; + } + + public String getVendorName() { + return vendorName; + } + + public void setVendorName(String vendorName) { + this.vendorName = vendorName; + } + + @JacksonXmlProperty(isAttribute = false, localName = "feature-group") + @JacksonXmlElementWrapper(localName = "feature-group-list") + public List getFeatureGroups() { + return featureGroups; + } + + public void setFeatureGroups(List featureGroups) { + this.featureGroups = featureGroups; + } + + void initMapper() { + WstxOutputFactory wstxOutputFactory = new WstxOutputFactory() { + @Override + public XMLStreamWriter createXMLStreamWriter(Writer writer) throws XMLStreamException { + mConfig.setProperty(WstxInputProperties.P_RETURN_NULL_FOR_DEFAULT_NAMESPACE, true); + return super.createXMLStreamWriter(writer); + } + }; + XmlFactory factory = new XmlFactory(new WstxInputFactory(), wstxOutputFactory); + + xmlMapper = new XmlMapper(factory); + + + xmlMapper.addMixIn(EntitlementPoolEntity.class, MixinEntitlementPoolEntityForVnfArtifact.class); + xmlMapper.addMixIn(LicenseKeyGroupEntity.class, MixinLicenseKeyGroupEntityForVnfArtifact.class); + xmlMapper.addMixIn(FeatureGroupModel.class, MixinFeatureGroupModel.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/XmlArtifact.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/XmlArtifact.java new file mode 100644 index 0000000000..78d5e22412 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/XmlArtifact.java @@ -0,0 +1,54 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.licenseartifacts.impl.types; + +import com.fasterxml.jackson.dataformat.xml.XmlMapper; +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.vendorlicense.VendorLicenseConstants; +import org.openecomp.sdc.vendorlicense.errors.JsonErrorBuilder; + +public abstract class XmlArtifact { + + XmlMapper xmlMapper = new XmlMapper(); + + abstract void initMapper(); + + /** + * To xml string. + * + * @return the string + */ + public String toXml() { + initMapper(); + String xml = ""; + + try { + xml = xmlMapper.writeValueAsString(this); + } catch (com.fasterxml.jackson.core.JsonProcessingException jsonProcessingException) { + throw new CoreException(new JsonErrorBuilder(jsonProcessingException.getMessage()).build()); + + } + + return xml.replaceAll(VendorLicenseConstants.VENDOR_LICENSE_MODEL_ARTIFACT_REGEX_REMOVE, ""); + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/mixins/MixinEntitlementPoolEntityForVendorLicenseArtifact.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/mixins/MixinEntitlementPoolEntityForVendorLicenseArtifact.java new file mode 100644 index 0000000000..1458fa80a7 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/mixins/MixinEntitlementPoolEntityForVendorLicenseArtifact.java @@ -0,0 +1,100 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.licenseartifacts.impl.types.mixins; + +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlElementWrapper; +import com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlProperty; +import org.openecomp.sdc.vendorlicense.dao.types.AggregationFunction; +import org.openecomp.sdc.vendorlicense.dao.types.ChoiceOrOther; +import org.openecomp.sdc.vendorlicense.dao.types.EntitlementMetric; +import org.openecomp.sdc.vendorlicense.dao.types.EntitlementTime; +import org.openecomp.sdc.vendorlicense.dao.types.OperationalScope; +import org.openecomp.sdc.vendorlicense.dao.types.xml.AggregationFunctionForXml; +import org.openecomp.sdc.vendorlicense.dao.types.xml.EntitlementMetricForXml; +import org.openecomp.sdc.vendorlicense.dao.types.xml.EntitlementTimeForXml; +import org.openecomp.sdc.vendorlicense.dao.types.xml.ThresholdForXml; + +import java.util.Set; + +public abstract class MixinEntitlementPoolEntityForVendorLicenseArtifact { + @JsonProperty(value = "threshold-value") + abstract ThresholdForXml getThresholdForArtifact(); + + @JsonProperty(value = "entitlement-pool-uuid") + abstract String getVersionUuId(); + + @JsonProperty(value = "manufacturer-reference-number") + abstract String getManufacturerReferenceNumber(); + + @JsonIgnore + abstract Set getReferencingFeatureGroups(); + + @JsonIgnore + abstract String getFirstClassCitizenId(); + + @JsonIgnore + abstract String getId(); + + @JsonIgnore + abstract String getVersion(); + + @JsonIgnore + abstract String getVendorLicenseModelId(); + + @JsonIgnore + abstract String getThresholdUnit(); + + @JsonIgnore + abstract float getThresholdValue(); + + @JsonIgnore + abstract ChoiceOrOther getEntitlementMetric(); + + @JsonIgnore + abstract ChoiceOrOther getTime(); + + @JsonIgnore + abstract ChoiceOrOther getAggregationFunction(); + + @JsonIgnore + abstract String getEntityType(); + + @JacksonXmlProperty(isAttribute = false, localName = "value") + @JacksonXmlElementWrapper(localName = "operational-scope") + abstract String getOperationalScopeForArtifact(); + + @JsonIgnore + abstract ChoiceOrOther getOperationalScope(); + + + @JsonProperty(value = "entitlement-metric") + abstract EntitlementMetricForXml getEntitlementMetricForArtifact(); + + @JsonProperty(value = "time") + abstract EntitlementTimeForXml getTimeForArtifact(); + + + @JsonProperty(value = "aggregation-function") + abstract AggregationFunctionForXml getAggregationFunctionForArtifact(); + +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/mixins/MixinEntitlementPoolEntityForVnfArtifact.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/mixins/MixinEntitlementPoolEntityForVnfArtifact.java new file mode 100644 index 0000000000..c4f2b4d4bd --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/mixins/MixinEntitlementPoolEntityForVnfArtifact.java @@ -0,0 +1,100 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.licenseartifacts.impl.types.mixins; + +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlElementWrapper; +import com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlProperty; +import org.openecomp.sdc.vendorlicense.dao.types.AggregationFunction; +import org.openecomp.sdc.vendorlicense.dao.types.ChoiceOrOther; +import org.openecomp.sdc.vendorlicense.dao.types.EntitlementMetric; +import org.openecomp.sdc.vendorlicense.dao.types.EntitlementTime; +import org.openecomp.sdc.vendorlicense.dao.types.OperationalScope; +import org.openecomp.sdc.vendorlicense.dao.types.xml.AggregationFunctionForXml; +import org.openecomp.sdc.vendorlicense.dao.types.xml.EntitlementMetricForXml; +import org.openecomp.sdc.vendorlicense.dao.types.xml.EntitlementTimeForXml; +import org.openecomp.sdc.vendorlicense.dao.types.xml.ThresholdForXml; + +import java.util.Set; + +public abstract class MixinEntitlementPoolEntityForVnfArtifact { + @JsonProperty(value = "threshold-value") + abstract ThresholdForXml getThresholdForArtifact(); + + @JsonIgnore + abstract String getId(); + + @JsonProperty(value = "manufacturer-reference-number") + abstract String getManufacturerReferenceNumber(); + + @JsonIgnore + abstract Set getReferencingFeatureGroups(); + + @JsonIgnore + abstract String getFirstClassCitizenId(); + + @JsonProperty(value = "entitlement-pool-uuid") + abstract String getVersionUuId(); + + @JsonIgnore + abstract String getVersion(); + + @JsonIgnore + abstract String getVendorLicenseModelId(); + + @JsonIgnore + abstract String getThresholdUnit(); + + @JsonIgnore + abstract float getThresholdValue(); + + @JsonIgnore + abstract ChoiceOrOther getEntitlementMetric(); + + @JsonIgnore + abstract ChoiceOrOther getTime(); + + @JsonIgnore + abstract ChoiceOrOther getAggregationFunction(); + + @JsonIgnore + abstract String getEntityType(); + + @JacksonXmlProperty(isAttribute = false, localName = "value") + @JacksonXmlElementWrapper(localName = "operational-scope") + abstract String getOperationalScopeForArtifact(); + + @JsonIgnore + abstract ChoiceOrOther getOperationalScope(); + + + @JsonProperty(value = "entitlement-metric") + abstract EntitlementMetricForXml getEntitlementMetricForArtifact(); + + @JsonProperty(value = "time") + abstract EntitlementTimeForXml getTimeForArtifact(); + + + @JsonProperty(value = "aggregation-function") + abstract AggregationFunctionForXml getAggregationFunctionForArtifact(); + +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/mixins/MixinFeatureGroupEntity.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/mixins/MixinFeatureGroupEntity.java new file mode 100644 index 0000000000..be6bd61357 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/mixins/MixinFeatureGroupEntity.java @@ -0,0 +1,62 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.licenseartifacts.impl.types.mixins; + +import com.fasterxml.jackson.annotation.JsonIgnore; +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.util.Set; + +public abstract class MixinFeatureGroupEntity { + + @JsonIgnore + abstract String getVendorLicenseModelId(); + + @JsonIgnore + abstract String getEntityType(); + + + @JsonIgnore + abstract Version getVersion(); + + @JsonIgnore + abstract String getId(); + + @JsonIgnore + abstract String getName(); + + @JsonIgnore + abstract String getDescription(); + + @JsonIgnore + abstract String getPartNumber(); + + @JsonIgnore + abstract Set getLicenseKeyGroupIds(); + + @JsonIgnore + abstract Set getEntitlementPoolIds(); + + + @JsonIgnore + abstract Set getReferencingLicenseAgreements(); + +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/mixins/MixinFeatureGroupModel.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/mixins/MixinFeatureGroupModel.java new file mode 100644 index 0000000000..1e76a74f4c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/mixins/MixinFeatureGroupModel.java @@ -0,0 +1,61 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.licenseartifacts.impl.types.mixins; + +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlElementWrapper; +import com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlProperty; +import org.openecomp.sdc.vendorlicense.dao.types.EntitlementPoolEntity; +import org.openecomp.sdc.vendorlicense.dao.types.FeatureGroupEntity; +import org.openecomp.sdc.vendorlicense.dao.types.LicenseKeyGroupEntity; + +import java.util.Set; + +public abstract class MixinFeatureGroupModel { + @JacksonXmlProperty(isAttribute = false, localName = "entitlement-pool") + @JacksonXmlElementWrapper(localName = "entitlement-pool-list") + abstract Set getEntitlementPools(); + + @JacksonXmlProperty(isAttribute = false, localName = "license-key-group") + @JacksonXmlElementWrapper(localName = "license-key-group-list") + abstract Set getLicenseKeyGroups(); + + @JacksonXmlProperty(isAttribute = false, localName = "internal-part-number") + abstract String getEntityPartNumber(); + + @JacksonXmlProperty(isAttribute = false, localName = "feature-group-uuid") + abstract String getEntityId(); + + @JacksonXmlProperty(isAttribute = false, localName = "description") + abstract String getEntityDesc(); + + @JacksonXmlProperty(isAttribute = false, localName = "name") + abstract String getEntityName(); + + + @JsonIgnore + abstract FeatureGroupEntity getFeatureGroup(); + + @JsonIgnore + abstract String getEntityType(); + + +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/mixins/MixinLicenseKeyGroupEntityForVendorLicenseArtifact.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/mixins/MixinLicenseKeyGroupEntityForVendorLicenseArtifact.java new file mode 100644 index 0000000000..ed3083afe3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/mixins/MixinLicenseKeyGroupEntityForVendorLicenseArtifact.java @@ -0,0 +1,72 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.licenseartifacts.impl.types.mixins; + +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlElementWrapper; +import com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlProperty; +import org.openecomp.sdc.vendorlicense.dao.types.ChoiceOrOther; +import org.openecomp.sdc.vendorlicense.dao.types.OperationalScope; +import org.openecomp.sdc.vendorlicense.dao.types.xml.LicenseKeyTypeForXml; + +import java.util.Set; + +public abstract class MixinLicenseKeyGroupEntityForVendorLicenseArtifact { + @JsonProperty(value = "license-key-group-uuid") + abstract String getVersionUuId(); + + @JsonIgnore + abstract Set getReferencingFeatureGroups(); + + @JsonIgnore + abstract String getVersion(); + + @JsonIgnore + abstract String getVendorLicenseModelId(); + + + @JsonIgnore + abstract String getEntityType(); + + @JsonIgnore + abstract String getFirstClassCitizenId(); + + @JsonIgnore + abstract String getId(); + + + @JsonIgnore + abstract ChoiceOrOther getOperationalScope(); + + @JacksonXmlProperty(isAttribute = false, localName = "value") + @JacksonXmlElementWrapper(localName = "operational-scope") + abstract String getOperationalScopeForArtifact(); + + + @JsonIgnore + abstract LicenseKeyTypeForXml getTypeForArtifact(); + + @JsonIgnore + abstract String getVersionableId(); + + +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/mixins/MixinLicenseKeyGroupEntityForVnfArtifact.java b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/mixins/MixinLicenseKeyGroupEntityForVnfArtifact.java new file mode 100644 index 0000000000..6281c44830 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/openecomp-sdc-vendor-license-core/src/main/java/org/openecomp/sdc/vendorlicense/licenseartifacts/impl/types/mixins/MixinLicenseKeyGroupEntityForVnfArtifact.java @@ -0,0 +1,74 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorlicense.licenseartifacts.impl.types.mixins; + +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlElementWrapper; +import com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlProperty; +import org.openecomp.sdc.vendorlicense.dao.types.ChoiceOrOther; +import org.openecomp.sdc.vendorlicense.dao.types.OperationalScope; +import org.openecomp.sdc.vendorlicense.dao.types.xml.LicenseKeyTypeForXml; + +import java.util.Set; + +public abstract class MixinLicenseKeyGroupEntityForVnfArtifact { + @JsonIgnore + abstract String getId(); + + @JsonIgnore + abstract Set getReferencingFeatureGroups(); + + @JsonIgnore + abstract String getVersion(); + + @JsonIgnore + abstract String getVendorLicenseModelId(); + + + @JsonIgnore + abstract String getEntityType(); + + @JsonProperty(value = "license-key-group-uuid") + abstract String getVersionUuId(); + + @JsonIgnore + abstract String getFirstClassCitizenId(); + + + + @JsonIgnore + abstract ChoiceOrOther getOperationalScope(); + + @JacksonXmlProperty(isAttribute = false, localName = "value") + @JacksonXmlElementWrapper(localName = "operational-scope") + abstract String getOperationalScopeForArtifact(); + + + @JsonIgnore + abstract LicenseKeyTypeForXml getTypeForArtifact(); + + @JsonIgnore + abstract String getVersionableId(); + + +} + diff --git a/openecomp-be/lib/openecomp-sdc-vendor-license-lib/pom.xml b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/pom.xml new file mode 100644 index 0000000000..5b1cef8ef7 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-license-lib/pom.xml @@ -0,0 +1,24 @@ + + 4.0.0 + + + openecomp-sdc-lib + org.openecomp.sdc + 1.0.0-SNAPSHOT + + + openecomp-sdc-vendor-license-lib + openecomp-sdc-vendor-license-lib + + pom + + + openecomp-sdc-vendor-license-api + openecomp-sdc-vendor-license-core + + + + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/pom.xml b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/pom.xml new file mode 100644 index 0000000000..100e85536d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/pom.xml @@ -0,0 +1,63 @@ + + + 4.0.0 + + + org.openecomp.sdc + openecomp-sdc-vendor-software-product-lib + 1.0.0-SNAPSHOT + + + openecomp-sdc-vendor-software-product-api + + + + com.google.code.gson + gson + 2.3.1 + test + + + org.openecomp.core + openecomp-core-lib + pom + ${project.version} + + + org.openecomp.core + openecomp-facade-core + ${project.version} + + + org.openecomp.core + openecomp-nosqldb-core + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-versioning-core + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-translator-core + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-enrichment-api + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-model-core + ${project.version} + + + + + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/VendorSoftwareProductConstants.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/VendorSoftwareProductConstants.java new file mode 100644 index 0000000000..860ef5fd41 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/VendorSoftwareProductConstants.java @@ -0,0 +1,38 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct; + +public final class VendorSoftwareProductConstants { + public static final String VENDOR_SOFTWARE_PRODUCT_VERSIONABLE_TYPE = "VendorSoftwareProduct"; + public static final String GENERAL_COMPONENT_ID = "General"; + public static final String VSP_PACKAGE_ZIP = "VSPPackage.zip"; + public static final String CSAR = "CSAR"; + public static final String UPLOAD_RAW_DATA = "UPLOAD_RAW_DATA"; + + public final class UniqueValues { + public static final String VENDOR_SOFTWARE_PRODUCT_NAME = "Vendor Software Product name"; + public static final String PROCESS_NAME = "Process name"; + public static final String NETWORK_NAME = "Network name"; + public static final String COMPONENT_NAME = "ComponentData name"; + public static final String NIC_NAME = "NIC name"; + //public static final String COMPONENT_ARTIFACT_NAME = "ComponentArtifact name"; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ComponentArtifactDao.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ComponentArtifactDao.java new file mode 100644 index 0000000000..d43c9687c2 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ComponentArtifactDao.java @@ -0,0 +1,40 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao; + +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentArtifactEntity; +import org.openecomp.sdc.versioning.dao.VersionableDao; + +import java.util.Collection; + +public interface ComponentArtifactDao extends VersionableDao { + + ComponentArtifactEntity getArtifactByType(ComponentArtifactEntity entity); + + void update(ComponentArtifactEntity entity); + + void delete(ComponentArtifactEntity entity); + + Collection getArtifactNamesAndTypesForComponent( + ComponentArtifactEntity entity); + + void deleteAll(ComponentArtifactEntity entity); +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ComponentArtifactDaoFactory.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ComponentArtifactDaoFactory.java new file mode 100644 index 0000000000..56a0ec65af --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ComponentArtifactDaoFactory.java @@ -0,0 +1,32 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; + +public abstract class ComponentArtifactDaoFactory + extends AbstractComponentFactory { + + public static ComponentArtifactDaoFactory getInstance() { + return AbstractFactory.getInstance(ComponentArtifactDaoFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ComponentDao.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ComponentDao.java new file mode 100644 index 0000000000..ca795b4929 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ComponentDao.java @@ -0,0 +1,38 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao; + +import org.openecomp.core.dao.BaseDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity; +import org.openecomp.sdc.versioning.dao.VersionableDao; +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.util.Collection; + +public interface ComponentDao extends VersionableDao, BaseDao { + + void updateQuestionnaireData(String vspId, Version version, String componentId, + String questionnaireData); + + Collection listQuestionnaires(String vspId, Version version); + + void deleteAll(String vspId, Version version); +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ComponentDaoFactory.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ComponentDaoFactory.java new file mode 100644 index 0000000000..e1cf30bfb1 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ComponentDaoFactory.java @@ -0,0 +1,31 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; + +public abstract class ComponentDaoFactory extends AbstractComponentFactory { + + public static ComponentDaoFactory getInstance() { + return AbstractFactory.getInstance(ComponentDaoFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/NetworkDao.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/NetworkDao.java new file mode 100644 index 0000000000..199e65fd83 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/NetworkDao.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao; + +import org.openecomp.core.dao.BaseDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.NetworkEntity; +import org.openecomp.sdc.versioning.dao.VersionableDao; +import org.openecomp.sdc.versioning.dao.types.Version; + +public interface NetworkDao extends VersionableDao, BaseDao { + + void updateQuestionnaireData(String vspId, Version version, String id, String questionnaireData); + + void deleteAll(String vspId, Version version); +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/NetworkDaoFactory.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/NetworkDaoFactory.java new file mode 100644 index 0000000000..8db3d605e4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/NetworkDaoFactory.java @@ -0,0 +1,31 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; + +public abstract class NetworkDaoFactory extends AbstractComponentFactory { + + public static NetworkDaoFactory getInstance() { + return AbstractFactory.getInstance(NetworkDaoFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/NicDao.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/NicDao.java new file mode 100644 index 0000000000..bbfa8bf8c0 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/NicDao.java @@ -0,0 +1,40 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao; + +import org.openecomp.core.dao.BaseDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity; +import org.openecomp.sdc.versioning.dao.VersionableDao; +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.util.Collection; + +public interface NicDao extends VersionableDao, BaseDao { + + void updateQuestionnaireData(String vspId, Version version, String componentId, String nicId, + String questionnaireData); + + Collection listByVsp(String vspId, Version version); + + void deleteByComponentId(String vspId, Version version, String componentId); + + void deleteByVspId(String vspId, Version version); +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/NicDaoFactory.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/NicDaoFactory.java new file mode 100644 index 0000000000..b61ad6a3ca --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/NicDaoFactory.java @@ -0,0 +1,31 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; + +public abstract class NicDaoFactory extends AbstractComponentFactory { + + public static NicDaoFactory getInstance() { + return AbstractFactory.getInstance(NicDaoFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/PackageInfoDao.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/PackageInfoDao.java new file mode 100644 index 0000000000..a22c725b6f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/PackageInfoDao.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao; + +import org.openecomp.core.dao.BaseDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.PackageInfo; +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.util.List; + +public interface PackageInfoDao extends BaseDao { + List listByCategory(String category, String subCategory); + + void deleteRowTranslateContent(String vspId, Version version); +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/PackageInfoDaoFactory.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/PackageInfoDaoFactory.java new file mode 100644 index 0000000000..a8e3d6563d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/PackageInfoDaoFactory.java @@ -0,0 +1,31 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; + +public abstract class PackageInfoDaoFactory extends AbstractComponentFactory { + + public static PackageInfoDaoFactory getInstance() { + return AbstractFactory.getInstance(PackageInfoDaoFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ProcessArtifactDao.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ProcessArtifactDao.java new file mode 100644 index 0000000000..5b562368b5 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ProcessArtifactDao.java @@ -0,0 +1,32 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao; + +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessArtifactEntity; + +public interface ProcessArtifactDao { + + void update(ProcessArtifactEntity entity); + + ProcessArtifactEntity get(ProcessArtifactEntity entity); + + void delete(ProcessArtifactEntity entity); +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ProcessArtifactDaoFactory.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ProcessArtifactDaoFactory.java new file mode 100644 index 0000000000..534777c701 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ProcessArtifactDaoFactory.java @@ -0,0 +1,32 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; + +public abstract class ProcessArtifactDaoFactory + extends AbstractComponentFactory { + + public static ProcessArtifactDaoFactory getInstance() { + return AbstractFactory.getInstance(ProcessArtifactDaoFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ProcessDao.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ProcessDao.java new file mode 100644 index 0000000000..8aa3400d24 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ProcessDao.java @@ -0,0 +1,30 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao; + +import org.openecomp.core.dao.BaseDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity; +import org.openecomp.sdc.versioning.dao.VersionableDao; + +public interface ProcessDao extends VersionableDao, BaseDao { + + void deleteAll(ProcessEntity entity); +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ProcessDaoFactory.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ProcessDaoFactory.java new file mode 100644 index 0000000000..f661a0ccda --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ProcessDaoFactory.java @@ -0,0 +1,31 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; + +public abstract class ProcessDaoFactory extends AbstractComponentFactory { + + public static ProcessDaoFactory getInstance() { + return AbstractFactory.getInstance(ProcessDaoFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/UploadDataDao.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/UploadDataDao.java new file mode 100644 index 0000000000..cdc3a770db --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/UploadDataDao.java @@ -0,0 +1,34 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao; + +import org.openecomp.core.dao.BaseDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.UploadDataEntity; +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.nio.ByteBuffer; + +public interface UploadDataDao extends BaseDao { + + void deleteContentDataAndValidationData(String vspId, Version version); + + ByteBuffer getContentData(String vspId, Version version); +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/UploadDataDaoFactory.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/UploadDataDaoFactory.java new file mode 100644 index 0000000000..9654551f8f --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/UploadDataDaoFactory.java @@ -0,0 +1,31 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; + +public abstract class UploadDataDaoFactory extends AbstractComponentFactory { + + public static UploadDataDaoFactory getInstance() { + return AbstractFactory.getInstance(UploadDataDaoFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/VendorSoftwareProductDao.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/VendorSoftwareProductDao.java new file mode 100644 index 0000000000..d8de3c6bd4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/VendorSoftwareProductDao.java @@ -0,0 +1,140 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao; + +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.NetworkEntity; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.PackageInfo; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessArtifactEntity; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.UploadDataEntity; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.VspDetails; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.VspQuestionnaireEntity; +import org.openecomp.sdc.versioning.dao.VersionableDao; +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.nio.ByteBuffer; +import java.util.Collection; +import java.util.List; + +public interface VendorSoftwareProductDao extends VersionableDao { + + void createVendorSoftwareProductInfo(VspDetails vspDetails); + + Collection listVendorSoftwareProductsInfo(); + + VspDetails getVendorSoftwareProductInfo(VspDetails vspDetails); + + void updateVendorSoftwareProductInfo(VspDetails vspDetails); + + void deleteVendorSoftwareProductInfo(VspDetails vspDetails); + + + void updateUploadData(UploadDataEntity uploadData); + + UploadDataEntity getUploadData(UploadDataEntity uploadData); + + ByteBuffer getContentData(UploadDataEntity uploadDataEntity); + + + List listPackages(String category, String subCategory); + + void insertPackageDetails(PackageInfo packageInfo); + + PackageInfo getPackageInfo(PackageInfo packageInfo); + + void deletePackageInfo(PackageInfo packageInfo); + + + Collection listNetworks(String vspId, Version version); + + void createNetwork(NetworkEntity network); + + void updateNetwork(NetworkEntity network); + + NetworkEntity getNetwork(String vspId, Version version, String networkId); + + void deleteNetwork(String vspId, Version version); + + + Collection listComponents(String vspId, Version version); + + void createComponent(ComponentEntity component); + + void updateComponent(ComponentEntity component); + + ComponentEntity getComponent(String vspId, Version version, String componentId); + + Collection listComponentsQuestionnaire(String vspId, Version version); + + void updateComponentQuestionnaire(String vspId, Version version, String componentId, + String questionnaireData); + + void deleteComponent(String vspId, Version version); + + + Collection listProcesses(String vspId, Version version, String componentId); + + void deleteProcesses(String vspId, Version version, String componentId); + + ProcessEntity getProcess(String vspId, Version version, String componentId, String processId); + + void createProcess(ProcessEntity processEntity); + + void updateProcess(ProcessEntity processEntity); + + void deleteProcess(String vspId, Version version, String componentId, String processId); + + + void uploadProcessArtifact(String vspId, Version version, String componentId, String processId, + byte[] artifact, String artifactFileName); + + ProcessArtifactEntity getProcessArtifact(String vspId, Version version, String componentId, + String processId); + + void deleteProcessArtifact(String vspId, Version version, String componentId, String processId); + + + VspQuestionnaireEntity getQuestionnaire(String vspId, Version version); + + void updateQuestionnaire(String vspId, Version version, String questionnaireData); + + + Collection listNics(String vspId, Version version, String componentId); + + void createNic(NicEntity nic); + + void updateNic(NicEntity nicEntity); + + NicEntity getNic(String vspId, Version version, String componentId, String nicId); + + void updateNicQuestionnaire(String vspId, Version version, String componentId, String nicId, + String questionnaireData); + + Collection listNicsByVsp(String vspId, Version version); + + void deleteNic(String vspId, Version version, String componentId); + + void deleteUploadData(String vspId, Version version); + + void updateVspLatestModificationTime(String vspId, Version version); +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/VendorSoftwareProductDaoFactory.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/VendorSoftwareProductDaoFactory.java new file mode 100644 index 0000000000..33aaa8e1ad --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/VendorSoftwareProductDaoFactory.java @@ -0,0 +1,34 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; + +public abstract class VendorSoftwareProductDaoFactory + extends AbstractComponentFactory { + + + public static VendorSoftwareProductDaoFactory getInstance() { + return AbstractFactory.getInstance(VendorSoftwareProductDaoFactory.class); + } + +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/VendorSoftwareProductInfoDao.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/VendorSoftwareProductInfoDao.java new file mode 100644 index 0000000000..74a3f69e6c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/VendorSoftwareProductInfoDao.java @@ -0,0 +1,30 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao; + +import org.openecomp.core.dao.BaseDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.VspDetails; +import org.openecomp.sdc.versioning.dao.VersionableDao; + +public interface VendorSoftwareProductInfoDao extends VersionableDao, BaseDao { + +// void updateLastModificationTime(VspDetails entity); +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/VendorSoftwareProductInfoDaoFactory.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/VendorSoftwareProductInfoDaoFactory.java new file mode 100644 index 0000000000..570ddc496e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/VendorSoftwareProductInfoDaoFactory.java @@ -0,0 +1,32 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; + +public abstract class VendorSoftwareProductInfoDaoFactory + extends AbstractComponentFactory { + + public static VendorSoftwareProductInfoDaoFactory getInstance() { + return AbstractFactory.getInstance(VendorSoftwareProductInfoDaoFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/VspQuestionnaireDao.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/VspQuestionnaireDao.java new file mode 100644 index 0000000000..4658f71d2a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/VspQuestionnaireDao.java @@ -0,0 +1,32 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao; + +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.VspQuestionnaireEntity; +import org.openecomp.sdc.versioning.dao.VersionableDao; +import org.openecomp.sdc.versioning.dao.types.Version; + +public interface VspQuestionnaireDao extends VersionableDao { + + VspQuestionnaireEntity get(VspQuestionnaireEntity entity); + + void updateQuestionnaireData(String id, Version version, String questionnaireData); +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/VspQuestionnaireDaoFactory.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/VspQuestionnaireDaoFactory.java new file mode 100644 index 0000000000..afc3dc9649 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/VspQuestionnaireDaoFactory.java @@ -0,0 +1,32 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; + +public abstract class VspQuestionnaireDaoFactory + extends AbstractComponentFactory { + + public static VspQuestionnaireDaoFactory getInstance() { + return AbstractFactory.getInstance(VspQuestionnaireDaoFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/Action.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/Action.java new file mode 100644 index 0000000000..3e82053574 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/Action.java @@ -0,0 +1,27 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao.type; + +public enum Action { + CREATE_PACKAGE, + CHECK_IN, + CHECK_OUT +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/ComponentArtifactEntity.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/ComponentArtifactEntity.java new file mode 100644 index 0000000000..3636a591d4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/ComponentArtifactEntity.java @@ -0,0 +1,140 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao.type; + +import com.datastax.driver.mapping.annotations.ClusteringColumn; +import com.datastax.driver.mapping.annotations.Column; +import com.datastax.driver.mapping.annotations.Frozen; +import com.datastax.driver.mapping.annotations.PartitionKey; +import com.datastax.driver.mapping.annotations.Table; +import org.openecomp.core.enrichment.types.ComponentArtifactType; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.dao.types.VersionableEntity; + +import java.nio.ByteBuffer; + +@Table(keyspace = "dox", name = "vsp_component_artifact") +public class ComponentArtifactEntity implements VersionableEntity { + public static final String ENTITY_TYPE = "Vendor Software Product Component Artifact"; + @PartitionKey + @Column(name = "vsp_id") + private String vspId; + @PartitionKey(value = 1) + @Frozen + private Version version; + @ClusteringColumn + @Column(name = "component_id") + private String componentId; + @ClusteringColumn(value = 1) + @Column(name = "artifact_type") + private ComponentArtifactType type; + @ClusteringColumn(value = 2) + @Column(name = "artifact_id") + private String id; + @Column(name = "name") + private String artifactName; + private ByteBuffer artifact; + + public ComponentArtifactEntity() { + + } + + /** + * Instantiates a new Component artifact entity. + * + * @param vspId the vsp id + * @param version the version + * @param componentId the component id + * @param id the id + */ + public ComponentArtifactEntity(String vspId, Version version, String componentId, String id) { + this.vspId = vspId; + this.version = version; + this.componentId = componentId; + this.id = id; + } + + public String getVspId() { + return vspId; + } + + public void setVspId(String vspId) { + this.vspId = vspId; + } + + public Version getVersion() { + return version; + } + + public void setVersion(Version version) { + this.version = version; + } + + public String getComponentId() { + return componentId; + } + + public void setComponentId(String componentId) { + this.componentId = componentId; + } + + @Override + public String getEntityType() { + return ENTITY_TYPE; + } + + @Override + public String getFirstClassCitizenId() { + return getVspId(); + } + + public String getId() { + return id; + } + + public void setId(String id) { + this.id = id; + } + + public String getArtifactName() { + return artifactName; + } + + public void setArtifactName(String artifactName) { + this.artifactName = artifactName; + } + + public ByteBuffer getArtifact() { + return artifact; + } + + public void setArtifact(ByteBuffer artifact) { + this.artifact = artifact; + } + + public ComponentArtifactType getType() { + return type; + } + + public void setType(ComponentArtifactType type) { + this.type = type; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/ComponentEntity.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/ComponentEntity.java new file mode 100644 index 0000000000..a74ba04ec4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/ComponentEntity.java @@ -0,0 +1,199 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao.type; + +import com.datastax.driver.mapping.annotations.ClusteringColumn; +import com.datastax.driver.mapping.annotations.Column; +import com.datastax.driver.mapping.annotations.Frozen; +import com.datastax.driver.mapping.annotations.PartitionKey; +import com.datastax.driver.mapping.annotations.Table; +import com.datastax.driver.mapping.annotations.Transient; +import org.openecomp.core.utilities.json.JsonUtil; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.ComponentData; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionEntityId; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionEntityType; +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.util.ArrayList; +import java.util.List; + + +@Table(keyspace = "dox", name = "vsp_component") +public class ComponentEntity implements CompositionEntity { + private static final String ENTITY_TYPE = "Vendor Software Product ComponentData"; + + @PartitionKey + @Column(name = "vsp_id") + private String vspId; + @PartitionKey(value = 1) + @Frozen + private Version version; + @ClusteringColumn + @Column(name = "component_id") + private String id; + @Column(name = "composition_data") + private String compositionData; + @Column(name = "questionnaire_data") + private String questionnaireData; + @Transient + private List nics = new ArrayList<>(); + + public ComponentEntity() { + + } + + /** + * Instantiates a new Component entity. + * + * @param vspId the vsp id + * @param version the version + * @param id the id + */ + public ComponentEntity(String vspId, Version version, String id) { + this.vspId = vspId; + this.version = version; + this.id = id; + } + + @Override + public CompositionEntityType getType() { + return CompositionEntityType.component; + } + + @Override + public CompositionEntityId getCompositionEntityId() { + return new CompositionEntityId(getId(), new CompositionEntityId(getVspId(), null)); + } + + public String getVspId() { + return vspId; + } + + public void setVspId(String vspId) { + this.vspId = vspId; + } + + @Override + public Version getVersion() { + return version; + } + + @Override + public void setVersion(Version version) { + this.version = version; + } + + @Override + public String getEntityType() { + return ENTITY_TYPE; + } + + @Override + public String getFirstClassCitizenId() { + return getVspId(); + } + + @Override + public String getId() { + return id; + } + + @Override + public void setId(String id) { + this.id = id; + } + + @Override + public String getCompositionData() { + return compositionData; + } + + @Override + public void setCompositionData(String compositionData) { + this.compositionData = compositionData; + } + + public ComponentData getComponentCompositionData() { + return compositionData == null ? null + : JsonUtil.json2Object(compositionData, ComponentData.class); + } + + public void setComponentCompositionData(ComponentData component) { + this.compositionData = component == null ? null : JsonUtil.object2Json(component); + } + + @Override + public String getQuestionnaireData() { + return questionnaireData; + } + + @Override + public void setQuestionnaireData(String questionnaireData) { + this.questionnaireData = questionnaireData; + } + + public List getNics() { + return nics; + } + + public void setNics(List nics) { + this.nics = nics; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (obj == null || getClass() != obj.getClass()) { + return false; + } + + ComponentEntity that = (ComponentEntity) obj; + + if (vspId != null ? !vspId.equals(that.vspId) : that.vspId != null) { + return false; + } + if (version != null ? !version.equals(that.version) : that.version != null) { + return false; + } + if (id != null ? !id.equals(that.id) : that.id != null) { + return false; + } + if (compositionData != null ? !compositionData.equals(that.compositionData) + : that.compositionData != null) { + return false; + } + return questionnaireData != null ? questionnaireData.equals(that.questionnaireData) + : that.questionnaireData == null; + + } + + @Override + public int hashCode() { + int result = vspId != null ? vspId.hashCode() : 0; + result = 31 * result + (version != null ? version.hashCode() : 0); + result = 31 * result + (id != null ? id.hashCode() : 0); + result = 31 * result + (compositionData != null ? compositionData.hashCode() : 0); + result = 31 * result + (questionnaireData != null ? questionnaireData.hashCode() : 0); + return result; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/CompositionEntity.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/CompositionEntity.java new file mode 100644 index 0000000000..b3e8eef3f2 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/CompositionEntity.java @@ -0,0 +1,40 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao.type; + +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionEntityId; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionEntityType; +import org.openecomp.sdc.versioning.dao.types.VersionableEntity; + +public interface CompositionEntity extends VersionableEntity { + + CompositionEntityType getType(); + + CompositionEntityId getCompositionEntityId(); + + String getCompositionData(); + + void setCompositionData(String compositionData); + + String getQuestionnaireData(); + + void setQuestionnaireData(String questionnaireData); +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/NetworkEntity.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/NetworkEntity.java new file mode 100644 index 0000000000..1599e4a88c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/NetworkEntity.java @@ -0,0 +1,183 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao.type; + +import com.datastax.driver.mapping.annotations.ClusteringColumn; +import com.datastax.driver.mapping.annotations.Column; +import com.datastax.driver.mapping.annotations.Frozen; +import com.datastax.driver.mapping.annotations.PartitionKey; +import com.datastax.driver.mapping.annotations.Table; +import org.openecomp.core.utilities.json.JsonUtil; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionEntityId; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionEntityType; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.Network; +import org.openecomp.sdc.versioning.dao.types.Version; + +@Table(keyspace = "dox", name = "vsp_network") +public class NetworkEntity implements CompositionEntity { + private static final String ENTITY_TYPE = "Vendor Software Product Network"; + + @PartitionKey + @Column(name = "vsp_id") + private String vspId; + @PartitionKey(value = 1) + @Frozen + private Version version; + @ClusteringColumn + @Column(name = "network_id") + private String id; + @Column(name = "composition_data") + private String compositionData; + @Column(name = "questionnaire_data") + private String questionnaireData; + + public NetworkEntity() { + + } + + /** + * Instantiates a new Network entity. + * + * @param vspId the vsp id + * @param version the version + * @param id the id + */ + public NetworkEntity(String vspId, Version version, String id) { + this.vspId = vspId; + this.version = version; + this.id = id; + } + + @Override + public CompositionEntityType getType() { + return CompositionEntityType.network; + } + + @Override + public CompositionEntityId getCompositionEntityId() { + return new CompositionEntityId(getId(), new CompositionEntityId(getVspId(), null)); + } + + public String getVspId() { + return vspId; + } + + public void setVspId(String vspId) { + this.vspId = vspId; + } + + @Override + public Version getVersion() { + return version; + } + + @Override + public void setVersion(Version version) { + this.version = version; + } + + @Override + public String getEntityType() { + return ENTITY_TYPE; + } + + @Override + public String getFirstClassCitizenId() { + return getVspId(); + } + + @Override + public String getId() { + return id; + } + + @Override + public void setId(String id) { + this.id = id; + } + + @Override + public String getCompositionData() { + return compositionData; + } + + @Override + public void setCompositionData(String compositionData) { + this.compositionData = compositionData; + } + + public Network getNetworkCompositionData() { + return compositionData == null ? null : JsonUtil.json2Object(compositionData, Network.class); + } + + public void setNetworkCompositionData(Network network) { + this.compositionData = network == null ? null : JsonUtil.object2Json(network); + } + + @Override + public String getQuestionnaireData() { + return questionnaireData; + } + + @Override + public void setQuestionnaireData(String questionnaireData) { + this.questionnaireData = questionnaireData; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (obj == null || getClass() != obj.getClass()) { + return false; + } + + NetworkEntity that = (NetworkEntity) obj; + + if (vspId != null ? !vspId.equals(that.vspId) : that.vspId != null) { + return false; + } + if (version != null ? !version.equals(that.version) : that.version != null) { + return false; + } + if (id != null ? !id.equals(that.id) : that.id != null) { + return false; + } + if (compositionData != null ? !compositionData.equals(that.compositionData) + : that.compositionData != null) { + return false; + } + return questionnaireData != null ? questionnaireData.equals(that.questionnaireData) + : that.questionnaireData == null; + + } + + @Override + public int hashCode() { + int result = vspId != null ? vspId.hashCode() : 0; + result = 31 * result + (version != null ? version.hashCode() : 0); + result = 31 * result + (id != null ? id.hashCode() : 0); + result = 31 * result + (compositionData != null ? compositionData.hashCode() : 0); + result = 31 * result + (questionnaireData != null ? questionnaireData.hashCode() : 0); + return result; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/NicEntity.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/NicEntity.java new file mode 100644 index 0000000000..33042a128a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/NicEntity.java @@ -0,0 +1,203 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao.type; + +import com.datastax.driver.mapping.annotations.ClusteringColumn; +import com.datastax.driver.mapping.annotations.Column; +import com.datastax.driver.mapping.annotations.Frozen; +import com.datastax.driver.mapping.annotations.PartitionKey; +import com.datastax.driver.mapping.annotations.Table; +import org.openecomp.core.utilities.json.JsonUtil; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionEntityId; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionEntityType; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.Nic; +import org.openecomp.sdc.versioning.dao.types.Version; + + +@Table(keyspace = "dox", name = "vsp_component_nic") +public class NicEntity implements CompositionEntity { + private static final String ENTITY_TYPE = "Vendor Software Product ComponentData NIC"; + + @PartitionKey + @Column(name = "vsp_id") + private String vspId; + @PartitionKey(value = 1) + @Frozen + private Version version; + @ClusteringColumn + @Column(name = "component_id") + private String componentId; + @ClusteringColumn(value = 1) + @Column(name = "nic_id") + private String id; + @Column(name = "composition_data") + private String compositionData; + @Column(name = "questionnaire_data") + private String questionnaireData; + + public NicEntity() { + + } + + /** + * Instantiates a new Nic entity. + * + * @param vspId the vsp id + * @param version the version + * @param componentId the component id + * @param id the id + */ + public NicEntity(String vspId, Version version, String componentId, String id) { + this.vspId = vspId; + this.version = version; + this.componentId = componentId; + this.id = id; + } + + @Override + public CompositionEntityType getType() { + return CompositionEntityType.nic; + } + + @Override + public CompositionEntityId getCompositionEntityId() { + return new CompositionEntityId(getId(), + new CompositionEntityId(getComponentId(), new CompositionEntityId(getVspId(), null))); + } + + public String getVspId() { + return vspId; + } + + public void setVspId(String vspId) { + this.vspId = vspId; + } + + @Override + public Version getVersion() { + return version; + } + + @Override + public void setVersion(Version version) { + this.version = version; + } + + @Override + public String getEntityType() { + return ENTITY_TYPE; + } + + @Override + public String getFirstClassCitizenId() { + return getVspId(); + } + + public String getComponentId() { + return componentId; + } + + public void setComponentId(String componentId) { + this.componentId = componentId; + } + + @Override + public String getId() { + return id; + } + + @Override + public void setId(String id) { + this.id = id; + } + + @Override + public String getCompositionData() { + return compositionData; + } + + @Override + public void setCompositionData(String compositionData) { + this.compositionData = compositionData; + } + + public Nic getNicCompositionData() { + return compositionData == null ? null : JsonUtil.json2Object(compositionData, Nic.class); + } + + public void setNicCompositionData(Nic nic) { + this.compositionData = nic == null ? null : JsonUtil.object2Json(nic); + } + + @Override + public String getQuestionnaireData() { + return questionnaireData; + } + + @Override + public void setQuestionnaireData(String questionnaireData) { + this.questionnaireData = questionnaireData; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (obj == null || getClass() != obj.getClass()) { + return false; + } + + NicEntity nicEntity = (NicEntity) obj; + + if (vspId != null ? !vspId.equals(nicEntity.vspId) : nicEntity.vspId != null) { + return false; + } + if (version != null ? !version.equals(nicEntity.version) : nicEntity.version != null) { + return false; + } + if (componentId != null ? !componentId.equals(nicEntity.componentId) + : nicEntity.componentId != null) { + return false; + } + if (id != null ? !id.equals(nicEntity.id) : nicEntity.id != null) { + return false; + } + if (compositionData != null ? !compositionData.equals(nicEntity.compositionData) + : nicEntity.compositionData != null) { + return false; + } + return questionnaireData != null ? questionnaireData.equals(nicEntity.questionnaireData) + : nicEntity.questionnaireData == null; + + } + + @Override + public int hashCode() { + int result = vspId != null ? vspId.hashCode() : 0; + result = 31 * result + (version != null ? version.hashCode() : 0); + result = 31 * result + (componentId != null ? componentId.hashCode() : 0); + result = 31 * result + (id != null ? id.hashCode() : 0); + result = 31 * result + (compositionData != null ? compositionData.hashCode() : 0); + result = 31 * result + (questionnaireData != null ? questionnaireData.hashCode() : 0); + return result; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/PackageInfo.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/PackageInfo.java new file mode 100644 index 0000000000..03f26cb57d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/PackageInfo.java @@ -0,0 +1,176 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao.type; + + +import com.datastax.driver.mapping.annotations.Column; +import com.datastax.driver.mapping.annotations.Frozen; +import com.datastax.driver.mapping.annotations.PartitionKey; +import com.datastax.driver.mapping.annotations.Table; +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.nio.ByteBuffer; + +@Table(keyspace = "dox", name = "package_details") +public class PackageInfo { + + + @PartitionKey + @Column(name = "vsp_id") + private String vspId; + + @PartitionKey(value = 1) + @Frozen + private Version version; + + @Column(name = "display_name") + private String displayName; + + @Column(name = "vsp_name") + private String vspName; + + @Column(name = "vsp_description") + private String vspDescription; + + @Column(name = "vendor_name") + private String vendorName; + + private String category; + + @Column(name = "sub_category") + private String subCategory; + + @Column(name = "vendor_release") + private String vendorRelease; + + @Column(name = "package_checksum") + private String packageChecksum; + + @Column(name = "package_type") + private String packageType; + + @Column(name = "translate_content") + private ByteBuffer translatedFile; + + public PackageInfo() { + } + + public PackageInfo(String packageId, Version version) { + this.vspId = packageId; + this.version = version; + } + + public String getDisplayName() { + return displayName; + } + + public void setDisplayName(String displayName) { + this.displayName = displayName; + } + + public String getVspDescription() { + return vspDescription; + } + + public void setVspDescription(String vspDescription) { + this.vspDescription = vspDescription; + } + + public Version getVersion() { + return version; + } + + public void setVersion(Version version) { + this.version = version; + } + + public String getVspId() { + return vspId; + } + + public void setVspId(String vspId) { + this.vspId = vspId; + } + + public String getCategory() { + return category; + } + + public void setCategory(String category) { + this.category = category; + } + + public String getSubCategory() { + return subCategory; + } + + public void setSubCategory(String subCategory) { + this.subCategory = subCategory; + } + + public String getVendorName() { + return vendorName; + } + + public void setVendorName(String vendorName) { + this.vendorName = vendorName; + } + + public String getVendorRelease() { + return vendorRelease; + } + + public void setVendorRelease(String vendorRelease) { + this.vendorRelease = vendorRelease; + } + + public String getPackageChecksum() { + return packageChecksum; + } + + public void setPackageChecksum(String packageChecksum) { + this.packageChecksum = packageChecksum; + } + + public String getPackageType() { + return packageType; + } + + public void setPackageType(String packageType) { + this.packageType = packageType; + } + + public ByteBuffer getTranslatedFile() { + return translatedFile; + } + + public void setTranslatedFile(ByteBuffer translatedFile) { + this.translatedFile = translatedFile; + } + + public String getVspName() { + return vspName; + } + + public void setVspName(String vendorName) { + this.vspName = vendorName; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/ProcessArtifactEntity.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/ProcessArtifactEntity.java new file mode 100644 index 0000000000..89e6de1e87 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/ProcessArtifactEntity.java @@ -0,0 +1,128 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao.type; + +import com.datastax.driver.mapping.annotations.ClusteringColumn; +import com.datastax.driver.mapping.annotations.Column; +import com.datastax.driver.mapping.annotations.Frozen; +import com.datastax.driver.mapping.annotations.PartitionKey; +import com.datastax.driver.mapping.annotations.Table; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.dao.types.VersionableEntity; + +import java.nio.ByteBuffer; + +@Table(keyspace = "dox", name = "vsp_process") +public class ProcessArtifactEntity implements VersionableEntity { + public static final String ENTITY_TYPE = "Vendor Software Product Process artifact"; + @PartitionKey + @Column(name = "vsp_id") + private String vspId; + @PartitionKey(value = 1) + @Frozen + private Version version; + @ClusteringColumn + @Column(name = "component_id") + private String componentId; + @ClusteringColumn(value = 1) + @Column(name = "process_id") + private String id; + @Column(name = "artifact_name") + private String artifactName; + private ByteBuffer artifact; + + public ProcessArtifactEntity() { + + } + + /** + * Instantiates a new Process artifact entity. + * + * @param vspId the vsp id + * @param version the version + * @param componentId the component id + * @param id the id + */ + public ProcessArtifactEntity(String vspId, Version version, String componentId, String id) { + this.vspId = vspId; + this.version = version; + this.componentId = componentId; + this.id = id; + } + + public String getVspId() { + return vspId; + } + + public void setVspId(String vspId) { + this.vspId = vspId; + } + + public Version getVersion() { + return version; + } + + public void setVersion(Version version) { + this.version = version; + } + + public String getComponentId() { + return componentId; + } + + public void setComponentId(String componentId) { + this.componentId = componentId; + } + + @Override + public String getEntityType() { + return ENTITY_TYPE; + } + + @Override + public String getFirstClassCitizenId() { + return getVspId(); + } + + public String getId() { + return id; + } + + public void setId(String id) { + this.id = id; + } + + public String getArtifactName() { + return artifactName; + } + + public void setArtifactName(String artifactName) { + this.artifactName = artifactName; + } + + public ByteBuffer getArtifact() { + return artifact; + } + + public void setArtifact(ByteBuffer artifact) { + this.artifact = artifact; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/ProcessEntity.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/ProcessEntity.java new file mode 100644 index 0000000000..d407540194 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/ProcessEntity.java @@ -0,0 +1,179 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao.type; + +import com.datastax.driver.mapping.annotations.ClusteringColumn; +import com.datastax.driver.mapping.annotations.Column; +import com.datastax.driver.mapping.annotations.Frozen; +import com.datastax.driver.mapping.annotations.PartitionKey; +import com.datastax.driver.mapping.annotations.Table; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.dao.types.VersionableEntity; + +@Table(keyspace = "dox", name = "vsp_process") +public class ProcessEntity implements VersionableEntity { + public static final String ENTITY_TYPE = "Vendor Software Product Process"; + @PartitionKey + @Column(name = "vsp_id") + private String vspId; + @PartitionKey(value = 1) + @Frozen + private Version version; + @ClusteringColumn + @Column(name = "component_id") + private String componentId; + @ClusteringColumn(value = 1) + @Column(name = "process_id") + private String id; + private String name; + private String description; + @Column(name = "artifact_name") + private String artifactName; + + public ProcessEntity() { + + } + + /** + * Instantiates a new Process entity. + * + * @param vspId the vsp id + * @param version the version + * @param componentId the component id + * @param id the id + */ + public ProcessEntity(String vspId, Version version, String componentId, String id) { + this.vspId = vspId; + this.version = version; + this.componentId = componentId; + this.id = id; + } + + public String getVspId() { + return vspId; + } + + public void setVspId(String vspId) { + this.vspId = vspId; + } + + public Version getVersion() { + return version; + } + + public void setVersion(Version version) { + this.version = version; + } + + public String getComponentId() { + return componentId; + } + + public void setComponentId(String componentId) { + this.componentId = componentId; + } + + @Override + public String getEntityType() { + return ENTITY_TYPE; + } + + @Override + public String getFirstClassCitizenId() { + return getVspId(); + } + + public String getId() { + return id; + } + + public void setId(String id) { + this.id = id; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public String getArtifactName() { + return artifactName; + } + + public void setArtifactName(String artifactName) { + this.artifactName = artifactName; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (obj == null || getClass() != obj.getClass()) { + return false; + } + + ProcessEntity that = (ProcessEntity) obj; + + if (vspId != null ? !vspId.equals(that.vspId) : that.vspId != null) { + return false; + } + if (version != null ? !version.equals(that.version) : that.version != null) { + return false; + } + if (componentId != null ? !componentId.equals(that.componentId) : that.componentId != null) { + return false; + } + if (id != null ? !id.equals(that.id) : that.id != null) { + return false; + } + if (name != null ? !name.equals(that.name) : that.name != null) { + return false; + } + return description != null ? description.equals(that.description) : that.description == null + && + (artifactName != null ? artifactName.equals(that.artifactName) : that.artifactName == null); + + } + + @Override + public int hashCode() { + int result = vspId != null ? vspId.hashCode() : 0; + result = 31 * result + (version != null ? version.hashCode() : 0); + result = 31 * result + (componentId != null ? componentId.hashCode() : 0); + result = 31 * result + (id != null ? id.hashCode() : 0); + result = 31 * result + (name != null ? name.hashCode() : 0); + result = 31 * result + (description != null ? description.hashCode() : 0); + result = 31 * result + (artifactName != null ? artifactName.hashCode() : 0); + return result; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/TranslatedFileData.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/TranslatedFileData.java new file mode 100644 index 0000000000..c6f197a4cf --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/TranslatedFileData.java @@ -0,0 +1,97 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao.type; + +public class TranslatedFileData { + + private String displayName; + private String version; + private String category; + private String subcategory; + private String vandorName; + private String vendorRelease; + private String packageChecksum; + private String packageType; + + public String getDisplayName() { + return displayName; + } + + public void setDisplayName(String displayName) { + this.displayName = displayName; + } + + public String getVersion() { + return version; + } + + public void setVersion(String version) { + this.version = version; + } + + public String getCategory() { + return category; + } + + public void setCategory(String category) { + this.category = category; + } + + public String getSubcategory() { + return subcategory; + } + + public void setSubcategory(String subcategory) { + this.subcategory = subcategory; + } + + public String getVandorName() { + return vandorName; + } + + public void setVandorName(String vandorName) { + this.vandorName = vandorName; + } + + public String getVendorRelease() { + return vendorRelease; + } + + public void setVendorRelease(String vendorRelease) { + this.vendorRelease = vendorRelease; + } + + public String getPackageChecksum() { + return packageChecksum; + } + + public void setPackageChecksum(String packageChecksum) { + this.packageChecksum = packageChecksum; + } + + public String getPackageType() { + return packageType; + } + + public void setPackageType(String packageType) { + this.packageType = packageType; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/UploadDataEntity.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/UploadDataEntity.java new file mode 100644 index 0000000000..a70b2cd6c8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/UploadDataEntity.java @@ -0,0 +1,135 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao.type; + +import com.datastax.driver.mapping.annotations.Column; +import com.datastax.driver.mapping.annotations.Frozen; +import com.datastax.driver.mapping.annotations.PartitionKey; +import com.datastax.driver.mapping.annotations.Table; +import org.openecomp.core.utilities.json.JsonUtil; +import org.openecomp.sdc.heat.datatypes.structure.ValidationStructureList; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.dao.types.VersionableEntity; + +import java.nio.ByteBuffer; + +@Table(keyspace = "dox", name = "vsp_information") +public class UploadDataEntity implements VersionableEntity { + private static final String ENTITY_TYPE = "Vendor Software Product Upload data"; + + @PartitionKey + @Column(name = "vsp_id") + private String id; + + @PartitionKey(value = 1) + @Frozen + private Version version; + + @Column(name = "package_name") + private String packageName; + + @Column(name = "package_version") + private String packageVersion; + + @Column(name = "validation_data") + private String validationData; + + @Column(name = "content_data") + private ByteBuffer contentData; + + public UploadDataEntity() { + } + + public UploadDataEntity(String id, Version version) { + this.id = id; + this.version = version; + } + + @Override + public String getEntityType() { + return ENTITY_TYPE; + } + + @Override + public String getFirstClassCitizenId() { + return getId(); + } + + public String getId() { + return id; + } + + public void setId(String id) { + this.id = id; + } + + @Override + public Version getVersion() { + return version; + } + + @Override + public void setVersion(Version version) { + this.version = version; + } + + public String getPackageName() { + return packageName; + } + + public void setPackageName(String packageName) { + this.packageName = packageName; + } + + public String getPackageVersion() { + return packageVersion; + } + + public void setPackageVersion(String packageVersion) { + this.packageVersion = packageVersion; + } + + public String getValidationData() { + return validationData; + } + + public void setValidationData(String validationData) { + this.validationData = validationData; + } + + public ValidationStructureList getValidationDataStructure() { + return validationData == null ? null + : JsonUtil.json2Object(validationData, ValidationStructureList.class); + } + + public void setValidationDataStructure(ValidationStructureList validationData) { + this.validationData = validationData == null ? null + : JsonUtil.object2Json(validationData); + } + + public ByteBuffer getContentData() { + return contentData; + } + + public void setContentData(ByteBuffer contentData) { + this.contentData = contentData; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/VspDetails.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/VspDetails.java new file mode 100644 index 0000000000..3423ba36b3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/VspDetails.java @@ -0,0 +1,242 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao.type; + +import com.datastax.driver.mapping.annotations.Column; +import com.datastax.driver.mapping.annotations.Computed; +import com.datastax.driver.mapping.annotations.Frozen; +import com.datastax.driver.mapping.annotations.PartitionKey; +import com.datastax.driver.mapping.annotations.Table; +import org.openecomp.core.utilities.json.JsonUtil; +import org.openecomp.sdc.heat.datatypes.structure.ValidationStructureList; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.dao.types.VersionableEntity; + +import java.util.List; + +@Table(keyspace = "dox", name = "vsp_information") +public class VspDetails implements VersionableEntity { + public static final String ENTITY_TYPE = "Vendor Software Product"; + + @PartitionKey + @Column(name = "vsp_id") + private String id; + + @PartitionKey(value = 1) + @Frozen + private Version version; + + private String name; + private String description; + + private String category; + + @Column(name = "sub_category") + private String subCategory; + + private String icon; + + @Column(name = "vendor_name") + private String vendorName; + + @Column(name = "vendor_id") + private String vendorId; + + @Column(name = "vlm_version") + @Frozen + private Version vlmVersion; + + @Column(name = "license_agreement") + private String licenseAgreement; + + @Column(name = "feature_groups") + private List featureGroups; + + @Column(name = "package_name") + private String packageName; + + @Column(name = "package_version") + private String packageVersion; + + @Column(name = "validation_data") + private String validationData; + + @Computed("writetime(name)") + private Long writetimeMicroSeconds; + + public VspDetails() { + } + + public VspDetails(String id, Version version) { + this.id = id; + this.version = version; + } + + @Override + public String getEntityType() { + return ENTITY_TYPE; + } + + @Override + public String getFirstClassCitizenId() { + return getId(); + } + + public String getId() { + return id; + } + + public void setId(String id) { + this.id = id; + } + + @Override + public Version getVersion() { + return version; + } + + @Override + public void setVersion(Version version) { + this.version = version; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public String getCategory() { + return category; + } + + public void setCategory(String category) { + this.category = category; + } + + public String getSubCategory() { + return subCategory; + } + + public void setSubCategory(String subCategory) { + this.subCategory = subCategory; + } + + public String getIcon() { + return icon; + } + + public void setIcon(String icon) { + this.icon = icon; + } + + public String getVendorName() { + return vendorName; + } + + public void setVendorName(String vendorName) { + this.vendorName = vendorName; + } + + public String getVendorId() { + return vendorId; + } + + public void setVendorId(String vendorId) { + this.vendorId = vendorId; + } + + public Version getVlmVersion() { + return vlmVersion; + } + + public void setVlmVersion(Version vlmVersion) { + this.vlmVersion = vlmVersion; + } + + public String getLicenseAgreement() { + return licenseAgreement; + } + + public void setLicenseAgreement(String licenseAgreement) { + this.licenseAgreement = licenseAgreement; + } + + public List getFeatureGroups() { + return featureGroups; + } + + public void setFeatureGroups(List featureGroups) { + this.featureGroups = featureGroups; + } + + public String getPackageName() { + return packageName; + } + + public void setPackageName(String packageName) { + this.packageName = packageName; + } + + public String getPackageVersion() { + return packageVersion; + } + + public void setPackageVersion(String packageVersion) { + this.packageVersion = packageVersion; + } + + public String getValidationData() { + return validationData; + } + + public void setValidationData(String validationData) { + this.validationData = validationData; + } + + public ValidationStructureList getValidationDataStructure() { + return validationData == null ? null + : JsonUtil.json2Object(validationData, ValidationStructureList.class); + } + + public void setValidationDataStructure(ValidationStructureList validationData) { + this.validationData = validationData == null ? null + : JsonUtil.object2Json(validationData); + } + + public Long getWritetimeMicroSeconds() { + return this.writetimeMicroSeconds; + } + + public void setWritetimeMicroSeconds(Long writetimeMicroSeconds) { + this.writetimeMicroSeconds = writetimeMicroSeconds; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/VspQuestionnaireEntity.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/VspQuestionnaireEntity.java new file mode 100644 index 0000000000..42fbecfe01 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/type/VspQuestionnaireEntity.java @@ -0,0 +1,111 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao.type; + +import com.datastax.driver.mapping.annotations.Column; +import com.datastax.driver.mapping.annotations.Frozen; +import com.datastax.driver.mapping.annotations.PartitionKey; +import com.datastax.driver.mapping.annotations.Table; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionEntityId; +import org.openecomp.sdc.vendorsoftwareproduct.types.composition.CompositionEntityType; +import org.openecomp.sdc.versioning.dao.types.Version; + +@Table(keyspace = "dox", name = "vsp_information") +public class VspQuestionnaireEntity implements CompositionEntity { + private static final String ENTITY_TYPE = "Vendor Software Product"; + + @PartitionKey + @Column(name = "vsp_id") + private String id; + @PartitionKey(value = 1) + @Frozen + private Version version; + @Column(name = "questionnaire_data") + private String questionnaireData; + + public VspQuestionnaireEntity() { + + } + + public VspQuestionnaireEntity(String vspId, Version version) { + this.id = vspId; + this.version = version; + } + + @Override + public String getId() { + return id; + } + + @Override + public void setId(String id) { + this.id = id; + } + + @Override + public Version getVersion() { + return version; + } + + @Override + public void setVersion(Version version) { + this.version = version; + } + + @Override + public String getEntityType() { + return ENTITY_TYPE; + } + + @Override + public String getFirstClassCitizenId() { + return getId(); + } + + @Override + public CompositionEntityType getType() { + return CompositionEntityType.vsp; + } + + @Override + public CompositionEntityId getCompositionEntityId() { + return new CompositionEntityId(getId(), null); + } + + @Override + public String getCompositionData() { + return null; //none + } + + @Override + public void setCompositionData(String compositionData) { + //none + } + + public String getQuestionnaireData() { + return questionnaireData; + } + + public void setQuestionnaireData(String questionnaireData) { + this.questionnaireData = questionnaireData; + } + +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/Component.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/Component.java new file mode 100644 index 0000000000..b112ee2216 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/Component.java @@ -0,0 +1,44 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.types.composition; + +import java.util.List; + +public class Component { + private ComponentData data; + private List nics; + + public ComponentData getData() { + return data; + } + + public void setData(ComponentData data) { + this.data = data; + } + + public List getNics() { + return nics; + } + + public void setNics(List nics) { + this.nics = nics; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/ComponentData.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/ComponentData.java new file mode 100644 index 0000000000..0b3096c686 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/ComponentData.java @@ -0,0 +1,80 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.types.composition; + +public class ComponentData implements CompositionDataEntity { + private String name; + private String description; + private String displayName; + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public String getDisplayName() { + return displayName; + } + + public void setDisplayName(String displayName) { + this.displayName = displayName; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (!(obj instanceof ComponentData)) { + return false; + } + + ComponentData that = (ComponentData) obj; + + if (!name.equals(that.name)) { + return false; + } + if (description != null ? !description.equals(that.description) : that.description != null) { + return false; + } + return displayName != null ? displayName.equals(that.displayName) : that.displayName == null; + + } + + @Override + public int hashCode() { + int result = name.hashCode(); + result = 31 * result + (description != null ? description.hashCode() : 0); + result = 31 * result + (displayName != null ? displayName.hashCode() : 0); + return result; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/CompositionData.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/CompositionData.java new file mode 100644 index 0000000000..30e11cde60 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/CompositionData.java @@ -0,0 +1,44 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.types.composition; + +import java.util.List; + +public class CompositionData { + private List networks; + private List components; + + public List getNetworks() { + return networks; + } + + public void setNetworks(List networks) { + this.networks = networks; + } + + public List getComponents() { + return components; + } + + public void setComponents(List components) { + this.components = components; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/CompositionDataEntity.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/CompositionDataEntity.java new file mode 100644 index 0000000000..9c09b0ded4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/CompositionDataEntity.java @@ -0,0 +1,24 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.types.composition; + +public interface CompositionDataEntity { +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/CompositionEntityId.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/CompositionEntityId.java new file mode 100644 index 0000000000..af1123b2e8 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/CompositionEntityId.java @@ -0,0 +1,64 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.types.composition; + +public class CompositionEntityId { + private String id; + private CompositionEntityId parentId; + + public CompositionEntityId(String id, CompositionEntityId parentId) { + this.id = id; + this.parentId = parentId; + } + + public String getId() { + return id; + } + + public CompositionEntityId getParentId() { + return parentId; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (obj == null || getClass() != obj.getClass()) { + return false; + } + + CompositionEntityId that = (CompositionEntityId) obj; + + if (id != null ? !id.equals(that.id) : that.id != null) { + return false; + } + return parentId != null ? parentId.equals(that.parentId) : that.parentId == null; + + } + + @Override + public int hashCode() { + int result = id != null ? id.hashCode() : 0; + result = 31 * result + (parentId != null ? parentId.hashCode() : 0); + return result; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/CompositionEntityType.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/CompositionEntityType.java new file mode 100644 index 0000000000..f762aeb341 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/CompositionEntityType.java @@ -0,0 +1,28 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.types.composition; + +public enum CompositionEntityType { + vsp, + network, + component, + nic +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/Network.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/Network.java new file mode 100644 index 0000000000..2f9eb4e69c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/Network.java @@ -0,0 +1,67 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.types.composition; + +public class Network implements CompositionDataEntity { + private String name; + private boolean dhcp; + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public boolean isDhcp() { + return dhcp; + } + + public void setDhcp(boolean dhcp) { + this.dhcp = dhcp; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (obj == null || getClass() != obj.getClass()) { + return false; + } + + Network network = (Network) obj; + + if (dhcp != network.dhcp) { + return false; + } + return name != null ? name.equals(network.name) : network.name == null; + + } + + @Override + public int hashCode() { + int result = name != null ? name.hashCode() : 0; + result = 31 * result + (dhcp ? 1 : 0); + return result; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/NetworkType.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/NetworkType.java new file mode 100644 index 0000000000..d90135a205 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/NetworkType.java @@ -0,0 +1,26 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.types.composition; + +public enum NetworkType { + Internal, + External +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/Nic.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/Nic.java new file mode 100644 index 0000000000..e44a731824 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/types/composition/Nic.java @@ -0,0 +1,102 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.types.composition; + +public class Nic implements CompositionDataEntity { + private String name; + private String description; + private String networkId; + private String networkName; + private NetworkType networkType; + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public String getNetworkId() { + return networkId; + } + + public void setNetworkId(String networkId) { + this.networkId = networkId; + } + + public String getNetworkName() { + return networkName; + } + + public void setNetworkName(String networkName) { + this.networkName = networkName; + } + + public NetworkType getNetworkType() { + return networkType; + } + + public void setNetworkType(NetworkType networkType) { + this.networkType = networkType; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (obj == null || getClass() != obj.getClass()) { + return false; + } + + Nic nic = (Nic) obj; + + if (name != null ? !name.equals(nic.name) : nic.name != null) { + return false; + } + if (description != null ? !description.equals(nic.description) : nic.description != null) { + return false; + } + if (networkId != null ? !networkId.equals(nic.networkId) : nic.networkId != null) { + return false; + } + return networkType == nic.networkType; + + } + + @Override + public int hashCode() { + int result = name != null ? name.hashCode() : 0; + result = 31 * result + (description != null ? description.hashCode() : 0); + result = 31 * result + (networkId != null ? networkId.hashCode() : 0); + result = 31 * result + (networkType != null ? networkType.hashCode() : 0); + return result; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/resources/factoryConfiguration.json b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/resources/factoryConfiguration.json new file mode 100644 index 0000000000..86b2f857cf --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-api/src/main/resources/factoryConfiguration.json @@ -0,0 +1,14 @@ +{ + "org.openecomp.sdc.vendorsoftwareproduct.dao.VendorSoftwareProductDaoFactory": "org.openecomp.sdc.vendorsoftwareproduct.dao.impl.VendorSoftwareProductDaoFactoryImpl", + "org.openecomp.sdc.vendorsoftwareproduct.dao.VendorSoftwareProductInfoDaoFactory": "org.openecomp.sdc.vendorsoftwareproduct.dao.impl.VendorSoftwareProductInfoDaoFactoryImpl", + "org.openecomp.sdc.vendorsoftwareproduct.dao.UploadDataDaoFactory": "org.openecomp.sdc.vendorsoftwareproduct.dao.impl.UploadDataDaoFactoryImpl", + "org.openecomp.sdc.vendorsoftwareproduct.dao.PackageInfoDaoFactory": "org.openecomp.sdc.vendorsoftwareproduct.dao.impl.PackageInfoDaoFactoryImpl", + "org.openecomp.sdc.vendorsoftwareproduct.dao.NetworkDaoFactory": "org.openecomp.sdc.vendorsoftwareproduct.dao.impl.NetworkDaoFactoryImpl", + "org.openecomp.sdc.vendorsoftwareproduct.dao.ComponentDaoFactory": "org.openecomp.sdc.vendorsoftwareproduct.dao.impl.ComponentDaoFactoryImpl", + "org.openecomp.sdc.vendorsoftwareproduct.dao.ComponentArtifactDaoFactory": "org.openecomp.sdc.vendorsoftwareproduct.dao.impl.ComponentArtifactDaoFactoryImpl", + "org.openecomp.sdc.vendorsoftwareproduct.dao.NicDaoFactory": "org.openecomp.sdc.vendorsoftwareproduct.dao.impl.NicDaoFactoryImpl", + "org.openecomp.sdc.vendorsoftwareproduct.dao.VspQuestionnaireDaoFactory": "org.openecomp.sdc.vendorsoftwareproduct.dao.impl.VspQuestionnaireDaoFactoryImpl", + "org.openecomp.sdc.vendorsoftwareproduct.dao.ProcessDaoFactory": "org.openecomp.sdc.vendorsoftwareproduct.dao.impl.ProcessDaoFactoryImpl", + "org.openecomp.sdc.vendorsoftwareproduct.dao.ProcessArtifactDaoFactory": "org.openecomp.sdc.vendorsoftwareproduct.dao.impl.ProcessArtifactDaoFactoryImpl" + +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/pom.xml b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/pom.xml new file mode 100644 index 0000000000..c732472152 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/pom.xml @@ -0,0 +1,67 @@ + + + 4.0.0 + + + org.openecomp.sdc + openecomp-sdc-vendor-software-product-lib + 1.0.0-SNAPSHOT + + + openecomp-sdc-vendor-software-product-core + + + + com.google.code.gson + gson + 2.3.1 + test + + + org.yaml + snakeyaml + 1.14 + test + + + org.openecomp.sdc + openecomp-sdc-enrichment-impl + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-vendor-software-product-api + ${project.version} + + + org.openecomp.core + openecomp-nosqldb-api + ${project.version} + + + org.freemarker + freemarker + 2.3.23 + + + org.testng + testng + ${testng.version} + test + + + org.openecomp.core + openecomp-config-lib + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-model-impl + ${project.version} + test + + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/ComponentArtifactDaoCassandraImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/ComponentArtifactDaoCassandraImpl.java new file mode 100644 index 0000000000..2525537cef --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/ComponentArtifactDaoCassandraImpl.java @@ -0,0 +1,159 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao.impl; + +import com.datastax.driver.core.ResultSet; +import com.datastax.driver.core.UDTValue; +import com.datastax.driver.mapping.Mapper; +import com.datastax.driver.mapping.Result; +import com.datastax.driver.mapping.UDTMapper; +import com.datastax.driver.mapping.annotations.Accessor; +import com.datastax.driver.mapping.annotations.Query; +import org.openecomp.core.dao.impl.CassandraBaseDao; +import org.openecomp.core.nosqldb.api.NoSqlDb; +import org.openecomp.core.nosqldb.factory.NoSqlDbFactory; +import org.openecomp.sdc.vendorsoftwareproduct.dao.ComponentArtifactDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentArtifactEntity; +import org.openecomp.sdc.versioning.VersioningManagerFactory; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.types.VersionableEntityMetadata; + + +import java.nio.ByteBuffer; +import java.util.Collection; + +public class ComponentArtifactDaoCassandraImpl extends CassandraBaseDao + implements ComponentArtifactDao { + + private static final NoSqlDb noSqlDb = NoSqlDbFactory.getInstance().createInterface(); + private static final ComponentArtifactAccessor accessor = + noSqlDb.getMappingManager().createAccessor(ComponentArtifactAccessor.class); + private static final Mapper mapper = + noSqlDb.getMappingManager().mapper(ComponentArtifactEntity.class); + private static final UDTMapper versionMapper = + noSqlDb.getMappingManager().udtMapper(Version.class); + + + @Override + public void registerVersioning(String versionableEntityType) { + VersionableEntityMetadata metadata = new VersionableEntityMetadata( + mapper.getTableMetadata().getName(), + mapper.getTableMetadata().getPartitionKey().get(0).getName(), + mapper.getTableMetadata().getPartitionKey().get(1).getName()); + + // metadata.setUniqueValuesMetadata(Collections.singletonList(new UniqueValueMetadata + // (VendorSoftwareProductConstants.UniqueValues.COMPONENT_ARTIFACT_NAME, + // Arrays.asList(mapper.getTableMetadata().getPartitionKey().get(0).getName(), mapper + // .getTableMetadata().getPartitionKey().get(1).getName(), "name")))); + + VersioningManagerFactory.getInstance().createInterface() + .register(versionableEntityType, metadata); + } + + @Override + public ComponentArtifactEntity getArtifactByType(ComponentArtifactEntity entity) { + return accessor.listByType(entity.getVspId(), versionMapper.toUDT(entity.getVersion()), + entity.getComponentId(), entity.getType().toString()).one(); + } + + @Override + protected Mapper getMapper() { + return mapper; + } + + @Override + protected Object[] getKeys(ComponentArtifactEntity entity) { + return new Object[]{entity.getVspId(), versionMapper.toUDT(entity.getVersion()), + entity.getComponentId(), entity.getType().toString(), entity.getId()}; + } + + @Override + public Collection list(ComponentArtifactEntity entity) { + return accessor.listByType(entity.getVspId(), versionMapper.toUDT(entity.getVersion()), + entity.getComponentId(), entity.getType().toString()).all(); + } + + @Override + public void update(ComponentArtifactEntity entity) { + accessor.update(entity.getVspId(), versionMapper.toUDT(entity.getVersion()), + entity.getComponentId(), entity.getId(), entity.getArtifactName(), entity.getArtifact(), + entity.getType().toString()); + + } + + @Override + public void delete(ComponentArtifactEntity entity) { + accessor.delete(entity.getVspId(), versionMapper.toUDT(entity.getVersion()), + entity.getComponentId(), entity.getType().toString()); + } + + @Override + public Collection getArtifactNamesAndTypesForComponent( + ComponentArtifactEntity entity) { + return accessor.getArtifactNamesAndTypesForComponent(entity.getVspId(), + versionMapper.toUDT(entity.getVersion()), entity.getComponentId()).all(); + } + + @Override + public void deleteAll(ComponentArtifactEntity entity) { + accessor.deleteAll(entity.getVspId(), versionMapper.toUDT(entity.getVersion())); + } + + + @Accessor + interface ComponentArtifactAccessor { + + @Query( + "insert into vsp_component_artifact (vsp_id, version, component_id, artifact_id, name, " + + "artifact, artifact_type) values (?,?,?,?,?,?,?)") + ResultSet update(String vspId, UDTValue version, String componentId, String id, + String artifactName, ByteBuffer artifact, String type); + + @Query( + "select vsp_id, version, component_id, artifact_type, artifact_id, name, artifact from " + + "vsp_component_artifact where vsp_id=? and version=? and component_id=? and " + + "artifact_type =?") + Result listByType(String vspId, UDTValue version, String componentId, + String type); + + @Query( + "delete name, artifact from vsp_component_artifact where vsp_id=? and version=? and " + + "component_id=? and artifact_type=? and artifact_id=?") + ResultSet delete(String vspId, UDTValue version, String componentId, String type, + String artifactId); + + @Query( + "delete from vsp_component_artifact where vsp_id=? and version=? and component_id=? " + + "and artifact_type=?") + ResultSet delete(String vspId, UDTValue version, String componentId, String artifactType); + + @Query("delete from vsp_component_artifact where vsp_id=? and version=?") + ResultSet deleteAll(String vspId, UDTValue version); + + @Query( + "select name, artifact_type from vsp_component_artifact where vsp_id=? and version=? " + + "and component_id=?") + Result getArtifactNamesAndTypesForComponent(String vspId, + UDTValue version, + String componentId); + + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/ComponentArtifactDaoFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/ComponentArtifactDaoFactoryImpl.java new file mode 100644 index 0000000000..07a9f104f4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/ComponentArtifactDaoFactoryImpl.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao.impl; + +import org.openecomp.sdc.vendorsoftwareproduct.dao.ComponentArtifactDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.ComponentArtifactDaoFactory; + +public class ComponentArtifactDaoFactoryImpl extends ComponentArtifactDaoFactory { + private static final ComponentArtifactDao INSTANCE = new ComponentArtifactDaoCassandraImpl(); + + @Override + public ComponentArtifactDao createInterface() { + return INSTANCE; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/ComponentDaoCassandraImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/ComponentDaoCassandraImpl.java new file mode 100644 index 0000000000..85372380c0 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/ComponentDaoCassandraImpl.java @@ -0,0 +1,139 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao.impl; + +import com.datastax.driver.core.ResultSet; +import com.datastax.driver.core.UDTValue; +import com.datastax.driver.mapping.Mapper; +import com.datastax.driver.mapping.Result; +import com.datastax.driver.mapping.UDTMapper; +import com.datastax.driver.mapping.annotations.Accessor; +import com.datastax.driver.mapping.annotations.Query; +import org.openecomp.core.dao.impl.CassandraBaseDao; +import org.openecomp.core.nosqldb.api.NoSqlDb; +import org.openecomp.core.nosqldb.factory.NoSqlDbFactory; +import org.openecomp.sdc.vendorsoftwareproduct.VendorSoftwareProductConstants; +import org.openecomp.sdc.vendorsoftwareproduct.dao.ComponentDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity; +import org.openecomp.sdc.versioning.VersioningManagerFactory; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.types.UniqueValueMetadata; +import org.openecomp.sdc.versioning.types.VersionableEntityMetadata; + +import java.util.Arrays; +import java.util.Collection; +import java.util.Collections; + +public class ComponentDaoCassandraImpl extends CassandraBaseDao + implements ComponentDao { + + private static final NoSqlDb noSqlDb = NoSqlDbFactory.getInstance().createInterface(); + private static final Mapper mapper = + noSqlDb.getMappingManager().mapper(ComponentEntity.class); + private static final ComponentAccessor accessor = + noSqlDb.getMappingManager().createAccessor(ComponentAccessor.class); + private static final UDTMapper versionMapper = + noSqlDb.getMappingManager().udtMapper(Version.class); + + @Override + public void registerVersioning(String versionableEntityType) { + VersionableEntityMetadata metadata = new VersionableEntityMetadata( + mapper.getTableMetadata().getName(), + mapper.getTableMetadata().getPartitionKey().get(0).getName(), + mapper.getTableMetadata().getPartitionKey().get(1).getName()); + + + metadata.setUniqueValuesMetadata(Collections.singletonList( + new UniqueValueMetadata(VendorSoftwareProductConstants.UniqueValues.COMPONENT_NAME, + Arrays.asList(mapper.getTableMetadata().getPartitionKey().get(0).getName(), + mapper.getTableMetadata().getPartitionKey().get(1).getName(), "name")))); + + VersioningManagerFactory.getInstance().createInterface() + .register(versionableEntityType, metadata); + } + + @Override + protected Mapper getMapper() { + return mapper; + } + + @Override + protected Object[] getKeys(ComponentEntity entity) { + return new Object[]{entity.getVspId(), versionMapper.toUDT(entity.getVersion()), + entity.getId()}; + } + + @Override + public void update(ComponentEntity entity) { + accessor.updateCompositionData(entity.getVspId(), versionMapper.toUDT(entity.getVersion()), + entity.getId(), entity.getCompositionData()); + } + + @Override + public Collection list(ComponentEntity entity) { + return accessor.list(entity.getVspId(), versionMapper.toUDT(entity.getVersion())).all(); + } + + @Override + public void updateQuestionnaireData(String vspId, Version version, String id, + String questionnaireData) { + accessor.updateQuestionnaireData(questionnaireData, vspId, versionMapper.toUDT(version), id); + } + + @Override + public Collection listQuestionnaires(String vspId, Version version) { + return accessor.listQuestionnaires(vspId, versionMapper.toUDT(version)).all(); + } + + @Override + public void deleteAll(String vspId, Version version) { + accessor.deleteAll(vspId, version); + } + + @Accessor + interface ComponentAccessor { + + @Query( + "select vsp_id, version, component_id, composition_data from vsp_component " + + "where vsp_id=? and version=?") + Result list(String vspId, UDTValue version); + + @Query( + "select vsp_id, version, component_id, questionnaire_data from vsp_component " + + "where vsp_id=? and version=?") + Result listQuestionnaires(String vspId, UDTValue version); + + @Query( + "insert into vsp_component (vsp_id, version, component_id, composition_data) " + + "values (?,?,?,?)") + ResultSet updateCompositionData(String vspId, UDTValue version, String id, + String compositionData); + + @Query( + "update vsp_component set questionnaire_data=? where vsp_id=? and version=? " + + "and component_id=?") + ResultSet updateQuestionnaireData(String questionnaireData, String vspId, UDTValue version, + String id); + + @Query("delete from vsp_component where vsp_id=? and version=?") + ResultSet deleteAll(String vspId, Version version); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/ComponentDaoFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/ComponentDaoFactoryImpl.java new file mode 100644 index 0000000000..1e57242ce1 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/ComponentDaoFactoryImpl.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao.impl; + +import org.openecomp.sdc.vendorsoftwareproduct.dao.ComponentDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.ComponentDaoFactory; + +public class ComponentDaoFactoryImpl extends ComponentDaoFactory { + private static final ComponentDao INSTANCE = new ComponentDaoCassandraImpl(); + + @Override + public ComponentDao createInterface() { + return INSTANCE; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/NetworkDaoCassandraImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/NetworkDaoCassandraImpl.java new file mode 100644 index 0000000000..f7b8f30f0a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/NetworkDaoCassandraImpl.java @@ -0,0 +1,127 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao.impl; + +import com.datastax.driver.core.ResultSet; +import com.datastax.driver.core.UDTValue; +import com.datastax.driver.mapping.Mapper; +import com.datastax.driver.mapping.Result; +import com.datastax.driver.mapping.UDTMapper; +import com.datastax.driver.mapping.annotations.Accessor; +import com.datastax.driver.mapping.annotations.Query; +import org.openecomp.core.dao.impl.CassandraBaseDao; +import org.openecomp.core.nosqldb.api.NoSqlDb; +import org.openecomp.core.nosqldb.factory.NoSqlDbFactory; +import org.openecomp.sdc.vendorsoftwareproduct.VendorSoftwareProductConstants; +import org.openecomp.sdc.vendorsoftwareproduct.dao.NetworkDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.NetworkEntity; +import org.openecomp.sdc.versioning.VersioningManagerFactory; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.types.UniqueValueMetadata; +import org.openecomp.sdc.versioning.types.VersionableEntityMetadata; + +import java.util.Arrays; +import java.util.Collection; +import java.util.Collections; + +public class NetworkDaoCassandraImpl extends CassandraBaseDao implements NetworkDao { + + private static final NoSqlDb noSqlDb = NoSqlDbFactory.getInstance().createInterface(); + private static final Mapper mapper = + noSqlDb.getMappingManager().mapper(NetworkEntity.class); + private static final NetworkAccessor accessor = + noSqlDb.getMappingManager().createAccessor(NetworkAccessor.class); + private static final UDTMapper versionMapper = + noSqlDb.getMappingManager().udtMapper(Version.class); + + @Override + public void registerVersioning(String versionableEntityType) { + VersionableEntityMetadata metadata = new VersionableEntityMetadata( + mapper.getTableMetadata().getName(), + mapper.getTableMetadata().getPartitionKey().get(0).getName(), + mapper.getTableMetadata().getPartitionKey().get(1).getName()); + + + metadata.setUniqueValuesMetadata(Collections.singletonList( + new UniqueValueMetadata(VendorSoftwareProductConstants.UniqueValues.NETWORK_NAME, + Arrays.asList(mapper.getTableMetadata().getPartitionKey().get(0).getName(), + mapper.getTableMetadata().getPartitionKey().get(1).getName(), "name")))); + + VersioningManagerFactory.getInstance().createInterface() + .register(versionableEntityType, metadata); + } + + @Override + protected Mapper getMapper() { + return mapper; + } + + @Override + protected Object[] getKeys(NetworkEntity entity) { + return new Object[]{entity.getVspId(), versionMapper.toUDT(entity.getVersion()), + entity.getId()}; + } + + @Override + public void update(NetworkEntity entity) { + accessor.updateCompositionData(entity.getVspId(), versionMapper.toUDT(entity.getVersion()), + entity.getId(), entity.getCompositionData()); + } + + @Override + public void updateQuestionnaireData(String vspId, Version version, String id, + String questionnaireData) { + accessor.updateQuestionnaireData(questionnaireData, vspId, versionMapper.toUDT(version), id); + } + + @Override + public Collection list(NetworkEntity entity) { + return accessor.list(entity.getVspId(), versionMapper.toUDT(entity.getVersion())).all(); + } + + @Override + public void deleteAll(String vspId, Version version) { + accessor.deleteAll(vspId, version); + } + + @Accessor + interface NetworkAccessor { + + @Query( + "select vsp_id, version, network_id, composition_data from vsp_network where vsp_id=? " + + "and version=?") + Result list(String vspId, UDTValue version); + + @Query( + "insert into vsp_network (vsp_id, version, network_id, composition_data) values (?,?,?,?)") + ResultSet updateCompositionData(String vspId, UDTValue version, String id, + String compositionData); + + @Query( + "update vsp_network set questionnaire_data=? where vsp_id=? and version=? and network_id=?") + ResultSet updateQuestionnaireData(String questionnaireData, String vspId, UDTValue version, + String id); + + @Query("delete from vsp_network where vsp_id=? and version=?") + ResultSet deleteAll(String vspId, Version version); + + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/NetworkDaoFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/NetworkDaoFactoryImpl.java new file mode 100644 index 0000000000..b4360996df --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/NetworkDaoFactoryImpl.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao.impl; + +import org.openecomp.sdc.vendorsoftwareproduct.dao.NetworkDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.NetworkDaoFactory; + +public class NetworkDaoFactoryImpl extends NetworkDaoFactory { + private static final NetworkDao INSTANCE = new NetworkDaoCassandraImpl(); + + @Override + public NetworkDao createInterface() { + return INSTANCE; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/NicDaoCassandraImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/NicDaoCassandraImpl.java new file mode 100644 index 0000000000..e7e1eed8e0 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/NicDaoCassandraImpl.java @@ -0,0 +1,148 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao.impl; + +import com.datastax.driver.core.ResultSet; +import com.datastax.driver.core.UDTValue; +import com.datastax.driver.mapping.Mapper; +import com.datastax.driver.mapping.Result; +import com.datastax.driver.mapping.UDTMapper; +import com.datastax.driver.mapping.annotations.Accessor; +import com.datastax.driver.mapping.annotations.Query; +import org.openecomp.core.dao.impl.CassandraBaseDao; +import org.openecomp.core.nosqldb.api.NoSqlDb; +import org.openecomp.core.nosqldb.factory.NoSqlDbFactory; +import org.openecomp.sdc.vendorsoftwareproduct.VendorSoftwareProductConstants; +import org.openecomp.sdc.vendorsoftwareproduct.dao.NicDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity; +import org.openecomp.sdc.versioning.VersioningManagerFactory; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.types.UniqueValueMetadata; +import org.openecomp.sdc.versioning.types.VersionableEntityMetadata; + +import java.util.Arrays; +import java.util.Collection; +import java.util.Collections; + +public class NicDaoCassandraImpl extends CassandraBaseDao implements NicDao { + + private static final NoSqlDb noSqlDb = NoSqlDbFactory.getInstance().createInterface(); + private static final Mapper mapper = + noSqlDb.getMappingManager().mapper(NicEntity.class); + private static final NicAccessor accessor = + noSqlDb.getMappingManager().createAccessor(NicAccessor.class); + private static final UDTMapper versionMapper = + noSqlDb.getMappingManager().udtMapper(Version.class); + + @Override + public void registerVersioning(String versionableEntityType) { + VersionableEntityMetadata metadata = new VersionableEntityMetadata( + mapper.getTableMetadata().getName(), + mapper.getTableMetadata().getPartitionKey().get(0).getName(), + mapper.getTableMetadata().getPartitionKey().get(1).getName()); + + + metadata.setUniqueValuesMetadata(Collections + .singletonList(new UniqueValueMetadata(VendorSoftwareProductConstants.UniqueValues.NIC_NAME, + Arrays.asList("vsp_id", "version", "component_id", "name")))); + + VersioningManagerFactory.getInstance().createInterface() + .register(versionableEntityType, metadata); + } + + @Override + protected Mapper getMapper() { + return mapper; + } + + @Override + protected Object[] getKeys(NicEntity entity) { + return new Object[]{entity.getVspId(), versionMapper.toUDT(entity.getVersion()), + entity.getComponentId(), entity.getId()}; + } + + @Override + public void create(NicEntity entity) { + super.create(entity); + } + + @Override + public void update(NicEntity entity) { + accessor.updateCompositionData(entity.getVspId(), versionMapper.toUDT(entity.getVersion()), + entity.getComponentId(), entity.getId(), entity.getCompositionData()); + } + + @Override + public void updateQuestionnaireData(String vspId, Version version, String id, String componentId, + String questionnaireData) { + accessor.updateQuestionnaireData(questionnaireData, vspId, versionMapper.toUDT(version), id, + componentId); + } + + @Override + public Collection listByVsp(String vspId, Version version) { + return accessor.listByVspId(vspId, versionMapper.toUDT(version)).all(); + } + + @Override + public Collection list(NicEntity entity) { + return accessor.listByComponentId(entity.getVspId(), versionMapper.toUDT(entity.getVersion()), + entity.getComponentId()).all(); + } + + public void deleteByComponentId(String vspId, Version version, String componentId) { + accessor.deleteByComponentId(vspId, version, componentId); + } + + public void deleteByVspId(String vspId, Version version) { + accessor.deleteByVspId(vspId, versionMapper.toUDT(version)); + } + + @Accessor + interface NicAccessor { + + @Query( + "select vsp_id, version, component_id, nic_id, composition_data " + + "from vsp_component_nic where vsp_id=? and version=? and component_id=?") + Result listByComponentId(String vspId, UDTValue version, String componentId); + + @Query("select * from vsp_component_nic where vsp_id=? and version=?") + Result listByVspId(String vspId, UDTValue version); + + @Query( + "insert into vsp_component_nic (vsp_id, version, component_id, nic_id, composition_data) " + + "values (?,?,?,?,?)") + ResultSet updateCompositionData(String vspId, UDTValue version, String componentId, String id, + String compositionData); + + @Query( + "update vsp_component_nic set questionnaire_data=? where vsp_id=? and version=? " + + "and component_id=? and nic_id=?") + ResultSet updateQuestionnaireData(String questionnaireData, String vspId, UDTValue version, + String componentId, String id); + + @Query("delete from vsp_component_nic where vsp_id=? and version=? and component_id=?") + ResultSet deleteByComponentId(String vspId, Version version, String componentId); + + @Query("delete from vsp_component_nic where vsp_id=? and version=?") + ResultSet deleteByVspId(String vspId, UDTValue version); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/NicDaoFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/NicDaoFactoryImpl.java new file mode 100644 index 0000000000..f4dd8d5a71 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/NicDaoFactoryImpl.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao.impl; + +import org.openecomp.sdc.vendorsoftwareproduct.dao.NicDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.NicDaoFactory; + +public class NicDaoFactoryImpl extends NicDaoFactory { + private static final NicDao INSTANCE = new NicDaoCassandraImpl(); + + @Override + public NicDao createInterface() { + return INSTANCE; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/PackageInfoDaoFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/PackageInfoDaoFactoryImpl.java new file mode 100644 index 0000000000..8b9bedcd3a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/PackageInfoDaoFactoryImpl.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao.impl; + +import org.openecomp.sdc.vendorsoftwareproduct.dao.PackageInfoDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.PackageInfoDaoFactory; + +public class PackageInfoDaoFactoryImpl extends PackageInfoDaoFactory { + private static final PackageInfoDao INSTANCE = new PackageInfoDaoImpl(); + + @Override + public PackageInfoDao createInterface() { + return INSTANCE; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/PackageInfoDaoImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/PackageInfoDaoImpl.java new file mode 100644 index 0000000000..9b7b81fe52 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/PackageInfoDaoImpl.java @@ -0,0 +1,103 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao.impl; + +import com.datastax.driver.mapping.Mapper; +import com.datastax.driver.mapping.Result; +import com.datastax.driver.mapping.UDTMapper; +import com.datastax.driver.mapping.annotations.Accessor; +import com.datastax.driver.mapping.annotations.Query; +import org.openecomp.core.dao.impl.CassandraBaseDao; +import org.openecomp.core.nosqldb.api.NoSqlDb; +import org.openecomp.core.nosqldb.factory.NoSqlDbFactory; +import org.openecomp.sdc.vendorsoftwareproduct.dao.PackageInfoDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.PackageInfo; +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.List; + +public class PackageInfoDaoImpl extends CassandraBaseDao implements PackageInfoDao { + + private static final NoSqlDb noSqlDb = NoSqlDbFactory.getInstance().createInterface(); + private static final Mapper mapper = + noSqlDb.getMappingManager().mapper(PackageInfo.class); + private static final PackageInfoAccessor accessor = + noSqlDb.getMappingManager().createAccessor(PackageInfoAccessor.class); + private static final UDTMapper versionMapper = + noSqlDb.getMappingManager().udtMapper(Version.class); + + @Override + protected Mapper getMapper() { + return mapper; + } + + @Override + protected Object[] getKeys(PackageInfo entity) { + return new Object[]{entity.getVspId(), versionMapper.toUDT(entity.getVersion())}; + } + + @Override + public Collection list(PackageInfo entity) { + return accessor.listInfo().all(); + } + + @Override + public List listByCategory(String category, String subCategory) { + Result packages = accessor.listInfo(); + + List filteredPackages = new ArrayList<>(); + for (PackageInfo packageInfo : packages) { + if (category != null) { + if (category.equals(packageInfo.getCategory())) { + filteredPackages.add(packageInfo); + } + } else if (subCategory != null) { + if (subCategory.equals(packageInfo.getSubCategory())) { + filteredPackages.add(packageInfo); + } + } else { + filteredPackages.add(packageInfo); + } + } + + return filteredPackages; + } + + @Override + public void deleteRowTranslateContent(String vspId, Version version) { + accessor.deleteRowTranslateContent(vspId, version); + } + + @Accessor + interface PackageInfoAccessor { + + @Query( + "SELECT vsp_id,version,display_name,vsp_name,vsp_description,vendor_name,category," + + "sub_category,vendor_release,package_checksum,package_type FROM package_details") + Result listInfo(); + + @Query("DELETE TRANSLATE_CONTENT FROM package_details WHERE vsp_id=? and version=?") + Result deleteRowTranslateContent(String vspId, Version version); + + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/ProcessArtifactDaoCassandraImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/ProcessArtifactDaoCassandraImpl.java new file mode 100644 index 0000000000..0e9fd90a13 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/ProcessArtifactDaoCassandraImpl.java @@ -0,0 +1,82 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao.impl; + +import com.datastax.driver.core.ResultSet; +import com.datastax.driver.core.UDTValue; +import com.datastax.driver.mapping.UDTMapper; +import com.datastax.driver.mapping.annotations.Accessor; +import com.datastax.driver.mapping.annotations.Query; +import org.openecomp.core.nosqldb.api.NoSqlDb; +import org.openecomp.core.nosqldb.factory.NoSqlDbFactory; +import org.openecomp.sdc.vendorsoftwareproduct.dao.ProcessArtifactDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessArtifactEntity; +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.nio.ByteBuffer; + +public class ProcessArtifactDaoCassandraImpl implements ProcessArtifactDao { + + private static final NoSqlDb noSqlDb = NoSqlDbFactory.getInstance().createInterface(); + private static final ProcessArtifactAccessor accessor = + noSqlDb.getMappingManager().createAccessor(ProcessArtifactAccessor.class); + private static final UDTMapper versionMapper = + noSqlDb.getMappingManager().udtMapper(Version.class); + + @Override + public void update(ProcessArtifactEntity entity) { + accessor.update(entity.getVspId(), versionMapper.toUDT(entity.getVersion()), + entity.getComponentId(), entity.getId(), entity.getArtifactName(), entity.getArtifact()); + } + + @Override + public ProcessArtifactEntity get(ProcessArtifactEntity entity) { + return accessor + .get(entity.getVspId(), versionMapper.toUDT(entity.getVersion()), entity.getComponentId(), + entity.getId()); + } + + @Override + public void delete(ProcessArtifactEntity entity) { + accessor.delete(entity.getVspId(), versionMapper.toUDT(entity.getVersion()), + entity.getComponentId(), entity.getId()); + } + + @Accessor + interface ProcessArtifactAccessor { + + @Query( + "insert into vsp_process (vsp_id, version, component_id, process_id, artifact_name," + + " artifact) values (?,?,?,?,?,?)") + ResultSet update(String vspId, UDTValue version, String componentId, String id, + String artifactName, ByteBuffer artifact); + + @Query( + "select vsp_id, version, component_id, process_id, artifact_name, artifact " + + "from vsp_process where vsp_id=? and version=? and component_id=? and process_id=?") + ProcessArtifactEntity get(String vspId, UDTValue version, String componentId, String id); + + @Query( + "delete artifact_name, artifact from vsp_process where vsp_id=? and version=? and" + + " component_id=? and process_id=?") + ResultSet delete(String vspId, UDTValue version, String componentId, String id); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/ProcessArtifactDaoFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/ProcessArtifactDaoFactoryImpl.java new file mode 100644 index 0000000000..2a5d9013bd --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/ProcessArtifactDaoFactoryImpl.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao.impl; + +import org.openecomp.sdc.vendorsoftwareproduct.dao.ProcessArtifactDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.ProcessArtifactDaoFactory; + +public class ProcessArtifactDaoFactoryImpl extends ProcessArtifactDaoFactory { + private static final ProcessArtifactDao INSTANCE = new ProcessArtifactDaoCassandraImpl(); + + @Override + public ProcessArtifactDao createInterface() { + return INSTANCE; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/ProcessDaoCassandraImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/ProcessDaoCassandraImpl.java new file mode 100644 index 0000000000..b8900eb5d3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/ProcessDaoCassandraImpl.java @@ -0,0 +1,139 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao.impl; + +import com.datastax.driver.core.ResultSet; +import com.datastax.driver.core.UDTValue; +import com.datastax.driver.mapping.Mapper; +import com.datastax.driver.mapping.Result; +import com.datastax.driver.mapping.UDTMapper; +import com.datastax.driver.mapping.annotations.Accessor; +import com.datastax.driver.mapping.annotations.Query; +import org.openecomp.core.nosqldb.api.NoSqlDb; +import org.openecomp.core.nosqldb.factory.NoSqlDbFactory; +import org.openecomp.sdc.vendorsoftwareproduct.VendorSoftwareProductConstants; +import org.openecomp.sdc.vendorsoftwareproduct.dao.ProcessDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity; +import org.openecomp.sdc.versioning.VersioningManagerFactory; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.types.UniqueValueMetadata; +import org.openecomp.sdc.versioning.types.VersionableEntityMetadata; + +import java.util.Arrays; +import java.util.Collection; +import java.util.Collections; + +public class ProcessDaoCassandraImpl implements ProcessDao { + + private static final NoSqlDb noSqlDb = NoSqlDbFactory.getInstance().createInterface(); + private static final Mapper mapper = + noSqlDb.getMappingManager().mapper(ProcessEntity.class); + private static final ProcessAccessor accessor = + noSqlDb.getMappingManager().createAccessor(ProcessAccessor.class); + private static final UDTMapper versionMapper = + noSqlDb.getMappingManager().udtMapper(Version.class); + + @Override + public void registerVersioning(String versionableEntityType) { + VersionableEntityMetadata metadata = new VersionableEntityMetadata( + mapper.getTableMetadata().getName(), + mapper.getTableMetadata().getPartitionKey().get(0).getName(), + mapper.getTableMetadata().getPartitionKey().get(1).getName()); + + metadata.setUniqueValuesMetadata(Collections.singletonList( + new UniqueValueMetadata(VendorSoftwareProductConstants.UniqueValues.PROCESS_NAME, + Arrays.asList("vsp_id", "version", "component_id", "name")))); + + VersioningManagerFactory.getInstance().createInterface() + .register(versionableEntityType, metadata); + } + + @Override + public Collection list(ProcessEntity entity) { + return accessor + .list(entity.getVspId(), versionMapper.toUDT(entity.getVersion()), entity.getComponentId()) + .all(); + } + + @Override + public void create(ProcessEntity entity) { + accessor.update(entity.getVspId(), versionMapper.toUDT(entity.getVersion()), + entity.getComponentId(), entity.getId(), entity.getName(), entity.getDescription()); + } + + @Override + public void update(ProcessEntity entity) { + accessor.update(entity.getVspId(), versionMapper.toUDT(entity.getVersion()), + entity.getComponentId(), entity.getId(), entity.getName(), entity.getDescription()); + } + + @Override + public ProcessEntity get(ProcessEntity entity) { + return accessor + .get(entity.getVspId(), versionMapper.toUDT(entity.getVersion()), entity.getComponentId(), + entity.getId()); + } + + @Override + public void delete(ProcessEntity entity) { + if (entity.getId() == null) { + accessor.deleteAll(entity.getVspId(), versionMapper.toUDT(entity.getVersion()), + entity.getComponentId()); + } else { + accessor.delete(entity.getVspId(), versionMapper.toUDT(entity.getVersion()), + entity.getComponentId(), entity.getId()); + } + } + + public void deleteAll(ProcessEntity entity) { + accessor.deleteAll(entity.getVspId(), versionMapper.toUDT(entity.getVersion())); + } + + @Accessor + interface ProcessAccessor { + + @Query( + "insert into vsp_process (vsp_id, version, component_id, process_id, name, description) " + + "values (?,?,?,?,?,?)") + ResultSet update(String vspId, UDTValue version, String componentId, String id, String name, + String description); + + @Query( + "select vsp_id, version, component_id, process_id, name, description, artifact_name " + + "from vsp_process where vsp_id=? and version=? and component_id=? and process_id=?") + ProcessEntity get(String vspId, UDTValue version, String componentId, String id); + + @Query( + "select vsp_id, version, component_id, process_id, name, description, artifact_name " + + "from vsp_process where vsp_id=? and version=? and component_id=?") + Result list(String vspId, UDTValue version, String componentId); + + @Query( + "delete from vsp_process where vsp_id=? and version=? and component_id=? and process_id=?") + ResultSet delete(String vspId, UDTValue version, String componentId, String id); + + @Query("delete from vsp_process where vsp_id=? and version=? and component_id=?") + ResultSet deleteAll(String vspId, UDTValue version, String componentId); + + @Query("delete from vsp_process where vsp_id=? and version=?") + ResultSet deleteAll(String vspId, UDTValue version); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/ProcessDaoFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/ProcessDaoFactoryImpl.java new file mode 100644 index 0000000000..4c981d8448 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/ProcessDaoFactoryImpl.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao.impl; + +import org.openecomp.sdc.vendorsoftwareproduct.dao.ProcessDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.ProcessDaoFactory; + +public class ProcessDaoFactoryImpl extends ProcessDaoFactory { + private static final ProcessDao INSTANCE = new ProcessDaoCassandraImpl(); + + @Override + public ProcessDao createInterface() { + return INSTANCE; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/UploadDataDaoFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/UploadDataDaoFactoryImpl.java new file mode 100644 index 0000000000..317bc344c4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/UploadDataDaoFactoryImpl.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao.impl; + +import org.openecomp.sdc.vendorsoftwareproduct.dao.UploadDataDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.UploadDataDaoFactory; + +public class UploadDataDaoFactoryImpl extends UploadDataDaoFactory { + private static final UploadDataDao INSTANCE = new UploadDataDaoImpl(); + + @Override + public UploadDataDao createInterface() { + return INSTANCE; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/UploadDataDaoImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/UploadDataDaoImpl.java new file mode 100644 index 0000000000..df019a4f53 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/UploadDataDaoImpl.java @@ -0,0 +1,92 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao.impl; + +import com.datastax.driver.core.UDTValue; +import com.datastax.driver.mapping.Mapper; +import com.datastax.driver.mapping.Result; +import com.datastax.driver.mapping.UDTMapper; +import com.datastax.driver.mapping.annotations.Accessor; +import com.datastax.driver.mapping.annotations.Query; +import org.openecomp.core.dao.impl.CassandraBaseDao; +import org.openecomp.core.nosqldb.api.NoSqlDb; +import org.openecomp.core.nosqldb.factory.NoSqlDbFactory; +import org.openecomp.sdc.vendorsoftwareproduct.dao.UploadDataDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.UploadDataEntity; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.VspDetails; +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.nio.ByteBuffer; +import java.util.Collection; + +public class UploadDataDaoImpl extends CassandraBaseDao implements UploadDataDao { + + private static final NoSqlDb noSqlDb = NoSqlDbFactory.getInstance().createInterface(); + private static final Mapper mapper = + noSqlDb.getMappingManager().mapper(UploadDataEntity.class); + private static final UploadDataAccessor accessor = + noSqlDb.getMappingManager().createAccessor(UploadDataAccessor.class); + private static final UDTMapper versionMapper = + noSqlDb.getMappingManager().udtMapper(Version.class); + + @Override + protected Mapper getMapper() { + return mapper; + } + + @Override + protected Object[] getKeys(UploadDataEntity entity) { + return new Object[]{entity.getId(), versionMapper.toUDT(entity.getVersion())}; + } + + @Override + public Collection list(UploadDataEntity entity) { + return accessor.listAll().all(); + } + + @Override + public void deleteContentDataAndValidationData(String vspId, Version version) { + accessor.deleteContentDataAndValidationData(vspId, versionMapper.toUDT(version)); + } + + @Override + public ByteBuffer getContentData(String vspId, Version version) { + return accessor.getContentData(vspId, version).one().getContentData(); + } + + + @Accessor + interface UploadDataAccessor { + + @Query( + "SELECT package_name, package_version, content_data, validation_data FROM vsp_information") + Result listAll(); + + @Query( + "DELETE package_name, package_version, content_data, validation_data FROM vsp_information " + + "WHERE vsp_id=? and version=?") + Result deleteContentDataAndValidationData(String vspId, UDTValue udtValue); + + @Query("SELECT CONTENT_DATA FROM vsp_information WHERE vsp_id=? and version=?") + Result getContentData(String vspId, Version version); + + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/VendorSoftwareProductDaoFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/VendorSoftwareProductDaoFactoryImpl.java new file mode 100644 index 0000000000..587f8ac036 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/VendorSoftwareProductDaoFactoryImpl.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao.impl; + +import org.openecomp.sdc.vendorsoftwareproduct.dao.VendorSoftwareProductDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.VendorSoftwareProductDaoFactory; + +public class VendorSoftwareProductDaoFactoryImpl extends VendorSoftwareProductDaoFactory { + private static final VendorSoftwareProductDao INSTANCE = new VendorSoftwareProductDaoImpl(); + + @Override + public VendorSoftwareProductDao createInterface() { + return INSTANCE; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/VendorSoftwareProductDaoImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/VendorSoftwareProductDaoImpl.java new file mode 100644 index 0000000000..f592e63280 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/VendorSoftwareProductDaoImpl.java @@ -0,0 +1,349 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao.impl; + +import org.openecomp.core.model.dao.EnrichedServiceArtifactDao; +import org.openecomp.core.model.dao.EnrichedServiceArtifactDaoFactory; +import org.openecomp.core.model.dao.ServiceArtifactDaoFactory; +import org.openecomp.core.model.dao.ServiceArtifactDaoInter; +import org.openecomp.sdc.vendorsoftwareproduct.dao.ComponentArtifactDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.ComponentArtifactDaoFactory; +import org.openecomp.sdc.vendorsoftwareproduct.dao.ComponentDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.ComponentDaoFactory; +import org.openecomp.sdc.vendorsoftwareproduct.dao.NetworkDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.NetworkDaoFactory; +import org.openecomp.sdc.vendorsoftwareproduct.dao.NicDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.NicDaoFactory; +import org.openecomp.sdc.vendorsoftwareproduct.dao.PackageInfoDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.PackageInfoDaoFactory; +import org.openecomp.sdc.vendorsoftwareproduct.dao.ProcessArtifactDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.ProcessArtifactDaoFactory; +import org.openecomp.sdc.vendorsoftwareproduct.dao.ProcessDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.ProcessDaoFactory; +import org.openecomp.sdc.vendorsoftwareproduct.dao.UploadDataDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.UploadDataDaoFactory; +import org.openecomp.sdc.vendorsoftwareproduct.dao.VendorSoftwareProductDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.VendorSoftwareProductInfoDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.VendorSoftwareProductInfoDaoFactory; +import org.openecomp.sdc.vendorsoftwareproduct.dao.VspQuestionnaireDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.VspQuestionnaireDaoFactory; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentArtifactEntity; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.ComponentEntity; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.NetworkEntity; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.NicEntity; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.PackageInfo; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessArtifactEntity; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.ProcessEntity; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.UploadDataEntity; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.VspDetails; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.VspQuestionnaireEntity; +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.nio.ByteBuffer; +import java.util.Collection; +import java.util.List; +import java.util.Objects; + +public class VendorSoftwareProductDaoImpl implements VendorSoftwareProductDao { + + private static final VendorSoftwareProductInfoDao vspInfoDao = + VendorSoftwareProductInfoDaoFactory.getInstance().createInterface(); + private static final PackageInfoDao packageInfoDao = + PackageInfoDaoFactory.getInstance().createInterface(); + private static final UploadDataDao uploadDataDao = + UploadDataDaoFactory.getInstance().createInterface(); + private static final VspQuestionnaireDao vspQuestionnaireDao = + VspQuestionnaireDaoFactory.getInstance().createInterface(); + private static final NetworkDao networkDao = NetworkDaoFactory.getInstance().createInterface(); + private static final ComponentDao componentDao = + ComponentDaoFactory.getInstance().createInterface(); + private static final NicDao nicDao = NicDaoFactory.getInstance().createInterface(); + private static final ProcessDao processDao = ProcessDaoFactory.getInstance().createInterface(); + private static final ProcessArtifactDao processArtifactDao = + ProcessArtifactDaoFactory.getInstance().createInterface(); + private static final ComponentArtifactDao componentArtifactDao = + ComponentArtifactDaoFactory.getInstance().createInterface(); + private static final ServiceArtifactDaoInter artifactDao = + ServiceArtifactDaoFactory.getInstance().createInterface(); + private static final EnrichedServiceArtifactDao enrichArtifactDao = + EnrichedServiceArtifactDaoFactory.getInstance().createInterface(); + + @Override + public void registerVersioning(String versionableEntityType) { + vspInfoDao.registerVersioning(versionableEntityType); + vspQuestionnaireDao.registerVersioning(versionableEntityType); + networkDao.registerVersioning(versionableEntityType); + componentDao.registerVersioning(versionableEntityType); + nicDao.registerVersioning(versionableEntityType); + processDao.registerVersioning(versionableEntityType); + } + + @Override + public void createVendorSoftwareProductInfo(VspDetails vspDetails) { + vspInfoDao.create(vspDetails); + } + + @Override + public Collection listVendorSoftwareProductsInfo() { + return vspInfoDao.list(new VspDetails()); + } + + public VspDetails getVendorSoftwareProductInfo(VspDetails vspDetails) { + return vspInfoDao.get(vspDetails); + } + + + @Override + public void updateVendorSoftwareProductInfo(VspDetails vspDetails) { + vspInfoDao.update(vspDetails); + } + + @Override + public void deleteVendorSoftwareProductInfo(VspDetails vspDetails) { + vspInfoDao.delete(vspDetails); + } + + @Override + public void updateUploadData(UploadDataEntity uploadData) { + uploadDataDao.update(uploadData); + } + + @Override + public UploadDataEntity getUploadData(UploadDataEntity uploadData) { + return uploadDataDao.get(uploadData); + } + + @Override + public ByteBuffer getContentData(UploadDataEntity uploadDataEntity) { + return uploadDataDao.getContentData(uploadDataEntity.getId(), uploadDataEntity.getVersion()); + } + + @Override + public void insertPackageDetails(PackageInfo packageInfo) { + packageInfoDao.update(packageInfo); + } + + @Override + public PackageInfo getPackageInfo(PackageInfo packageInfo) { + return packageInfoDao.get(packageInfo); + } + + @Override + public void deletePackageInfo(PackageInfo packageInfo) { + packageInfoDao.delete(packageInfo); + } + + @Override + public Collection listNetworks(String vspId, Version version) { + return networkDao.list(new NetworkEntity(vspId, version, null)); + } + + @Override + public void createNetwork(NetworkEntity network) { + networkDao.create(network); + } + + @Override + public void updateNetwork(NetworkEntity networkEntity) { + networkDao.update(networkEntity); + } + + @Override + public NetworkEntity getNetwork(String vspId, Version version, String networkId) { + return networkDao.get(new NetworkEntity(vspId, version, networkId)); + } + + @Override + public void deleteNetwork(String vspId, Version version) { + NetworkEntity networkEntity = new NetworkEntity(vspId, version, null); + networkDao.delete(networkEntity); + } + + @Override + public List listPackages(String category, String subCategory) { + return packageInfoDao.listByCategory(category, subCategory); + } + + + @Override + public Collection listComponents(String vspId, Version version) { + return componentDao.list(new ComponentEntity(vspId, version, null)); + } + + @Override + public void createComponent(ComponentEntity component) { + componentDao.create(component); + } + + @Override + public void updateComponent(ComponentEntity component) { + componentDao.update(component); + } + + @Override + public ComponentEntity getComponent(String vspId, Version version, String componentId) { + return componentDao.get(new ComponentEntity(vspId, version, componentId)); + } + + @Override + public Collection listComponentsQuestionnaire(String vspId, Version version) { + return componentDao.listQuestionnaires(vspId, version); + } + + @Override + public void updateComponentQuestionnaire(String vspId, Version version, String componentId, + String questionnaireData) { + componentDao.updateQuestionnaireData(vspId, version, componentId, questionnaireData); + } + + @Override + public void deleteComponent(String vspId, Version version) { + ComponentEntity componentEntity = new ComponentEntity(vspId, version, null); + componentDao.delete(componentEntity); + } + + @Override + public Collection listProcesses(String vspId, Version version, + String componentId) { + return processDao.list(new ProcessEntity(vspId, version, componentId, null)); + } + + @Override + public void deleteProcesses(String vspId, Version version, String componentId) { + processDao.delete(new ProcessEntity(vspId, version, componentId, null)); + } + + @Override + public ProcessEntity getProcess(String vspId, Version version, String componentId, + String processId) { + return processDao.get(new ProcessEntity(vspId, version, componentId, processId)); + } + + @Override + public void createProcess(ProcessEntity processEntity) { + processDao.create(processEntity); + } + + @Override + public void updateProcess(ProcessEntity processEntity) { + processDao.update(processEntity); + } + + @Override + public void deleteProcess(String vspId, Version version, String componentId, String processId) { + processDao.delete(new ProcessEntity(vspId, version, componentId, processId)); + } + + @Override + public void uploadProcessArtifact(String vspId, Version version, String componentId, + String processId, byte[] artifact, String artifactName) { + ProcessArtifactEntity processArtifact = + new ProcessArtifactEntity(vspId, version, componentId, processId); + processArtifact.setArtifact(ByteBuffer.wrap(artifact)); + processArtifact.setArtifactName(artifactName); + processArtifactDao.update(processArtifact); + } + + @Override + public ProcessArtifactEntity getProcessArtifact(String vspId, Version version, String componentId, + String processId) { + return processArtifactDao + .get(new ProcessArtifactEntity(vspId, version, componentId, processId)); + } + + @Override + public void deleteProcessArtifact(String vspId, Version version, String componentId, + String processId) { + processArtifactDao.delete(new ProcessArtifactEntity(vspId, version, componentId, processId)); + } + + @Override + public VspQuestionnaireEntity getQuestionnaire(String vspId, Version version) { + return vspQuestionnaireDao.get(new VspQuestionnaireEntity(vspId, version)); + } + + @Override + public void updateQuestionnaire(String vspId, Version version, String questionnaireData) { + vspQuestionnaireDao.updateQuestionnaireData(vspId, version, questionnaireData); + } + + @Override + public Collection listNics(String vspId, Version version, String componentId) { + return nicDao.list(new NicEntity(vspId, version, componentId, null)); + } + + @Override + public void createNic(NicEntity nic) { + nicDao.create(nic); + } + + @Override + public NicEntity getNic(String vspId, Version version, String componentId, String nicId) { + return nicDao.get(new NicEntity(vspId, version, componentId, nicId)); + } + + @Override + public void updateNic(NicEntity nicEntity) { + nicDao.update(nicEntity); + } + + @Override + public void updateNicQuestionnaire(String vspId, Version version, String componentId, + String nicId, String questionnaireData) { + nicDao.updateQuestionnaireData(vspId, version, componentId, nicId, questionnaireData); + } + + @Override + public Collection listNicsByVsp(String vspId, Version version) { + return nicDao.listByVsp(vspId, version); + } + + @Override + public void deleteNic(String vspId, Version version, String componentId) { + NicEntity nicEntity = new NicEntity(vspId, version, componentId, null); + nicDao.delete(nicEntity); + } + + @Override + public void deleteUploadData(String vspId, Version version) { + networkDao.deleteAll(vspId, version); + nicDao.deleteByVspId(vspId, version); + artifactDao.delete(vspId, version); + enrichArtifactDao.delete(vspId, version); + ComponentArtifactEntity componentArtifactEntity = + new ComponentArtifactEntity(vspId, version, null, null); + ProcessEntity processEntity = new ProcessEntity(vspId, version, null, null); + componentArtifactDao.deleteAll(componentArtifactEntity); + processDao.deleteAll(processEntity); + componentDao.deleteAll(vspId, version); + uploadDataDao.deleteContentDataAndValidationData(vspId, version); + } + + @Override + public void updateVspLatestModificationTime(String vspId, Version version) { + if (Objects.isNull(vspId) || Objects.isNull(version)) { + return; + } + + VspDetails retrieved = getVendorSoftwareProductInfo(new VspDetails(vspId, version)); + updateVendorSoftwareProductInfo(retrieved); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/VendorSoftwareProductInfoDaoFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/VendorSoftwareProductInfoDaoFactoryImpl.java new file mode 100644 index 0000000000..1dcb3f4c66 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/VendorSoftwareProductInfoDaoFactoryImpl.java @@ -0,0 +1,34 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao.impl; + +import org.openecomp.sdc.vendorsoftwareproduct.dao.VendorSoftwareProductInfoDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.VendorSoftwareProductInfoDaoFactory; + +public class VendorSoftwareProductInfoDaoFactoryImpl extends VendorSoftwareProductInfoDaoFactory { + private static final VendorSoftwareProductInfoDao INSTANCE = + new VendorSoftwareProductInfoDaoImpl(); + + @Override + public VendorSoftwareProductInfoDao createInterface() { + return INSTANCE; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/VendorSoftwareProductInfoDaoImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/VendorSoftwareProductInfoDaoImpl.java new file mode 100644 index 0000000000..c3096dab29 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/VendorSoftwareProductInfoDaoImpl.java @@ -0,0 +1,83 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao.impl; + +import com.datastax.driver.mapping.Mapper; +import com.datastax.driver.mapping.Result; +import com.datastax.driver.mapping.UDTMapper; +import com.datastax.driver.mapping.annotations.Accessor; +import com.datastax.driver.mapping.annotations.Query; +import org.openecomp.core.dao.impl.CassandraBaseDao; +import org.openecomp.core.nosqldb.api.NoSqlDb; +import org.openecomp.core.nosqldb.factory.NoSqlDbFactory; +import org.openecomp.sdc.vendorsoftwareproduct.dao.VendorSoftwareProductInfoDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.VspDetails; +import org.openecomp.sdc.versioning.VersioningManagerFactory; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.types.VersionableEntityMetadata; + +import java.util.Collection; + +public class VendorSoftwareProductInfoDaoImpl extends CassandraBaseDao + implements VendorSoftwareProductInfoDao { + + private static final NoSqlDb noSqlDb = NoSqlDbFactory.getInstance().createInterface(); + private static final Mapper mapper = + noSqlDb.getMappingManager().mapper(VspDetails.class); + private static final VendorSoftwareProductInfoAccessor accessor = + noSqlDb.getMappingManager().createAccessor(VendorSoftwareProductInfoAccessor.class); + private static final UDTMapper versionMapper = + noSqlDb.getMappingManager().udtMapper(Version.class); + + @Override + public void registerVersioning(String versionableEntityType) { + VersioningManagerFactory.getInstance().createInterface() + .register(versionableEntityType, new VersionableEntityMetadata( + mapper.getTableMetadata().getName(), + mapper.getTableMetadata().getPartitionKey().get(0).getName(), + mapper.getTableMetadata().getPartitionKey().get(1).getName())); + } + + @Override + protected Mapper getMapper() { + return mapper; + } + + @Override + protected Object[] getKeys(VspDetails entity) { + return new Object[]{entity.getId(), versionMapper.toUDT(entity.getVersion())}; + } + + @Override + public Collection list(VspDetails entity) { + return accessor.listAll().all(); + } + + @Accessor + interface VendorSoftwareProductInfoAccessor { + + @Query( + "SELECT vsp_id,version,name,description,icon,category,sub_category,vendor_id," + + "vlm_version,license_agreement,feature_groups FROM vsp_information") + Result listAll(); + + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/VspQuestionnaireDaoCassandraImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/VspQuestionnaireDaoCassandraImpl.java new file mode 100644 index 0000000000..ef4dd0de74 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/VspQuestionnaireDaoCassandraImpl.java @@ -0,0 +1,72 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao.impl; + +import com.datastax.driver.core.ResultSet; +import com.datastax.driver.core.UDTValue; +import com.datastax.driver.mapping.Mapper; +import com.datastax.driver.mapping.UDTMapper; +import com.datastax.driver.mapping.annotations.Accessor; +import com.datastax.driver.mapping.annotations.Query; +import org.openecomp.core.nosqldb.api.NoSqlDb; +import org.openecomp.core.nosqldb.factory.NoSqlDbFactory; +import org.openecomp.sdc.vendorsoftwareproduct.dao.VspQuestionnaireDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.type.VspQuestionnaireEntity; +import org.openecomp.sdc.versioning.VersioningManagerFactory; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.types.VersionableEntityMetadata; + +public class VspQuestionnaireDaoCassandraImpl implements VspQuestionnaireDao { + + private static final NoSqlDb noSqlDb = NoSqlDbFactory.getInstance().createInterface(); + private static final Mapper mapper = + noSqlDb.getMappingManager().mapper(VspQuestionnaireEntity.class); + private static final VspQuestionnaireAccessor accessor = + noSqlDb.getMappingManager().createAccessor(VspQuestionnaireAccessor.class); + private static final UDTMapper versionMapper = + noSqlDb.getMappingManager().udtMapper(Version.class); + + @Override + public void registerVersioning(String versionableEntityType) { + VersioningManagerFactory.getInstance().createInterface() + .register(versionableEntityType, new VersionableEntityMetadata( + mapper.getTableMetadata().getName(), + mapper.getTableMetadata().getPartitionKey().get(0).getName(), + mapper.getTableMetadata().getPartitionKey().get(1).getName())); + } + + @Override + public VspQuestionnaireEntity get(VspQuestionnaireEntity entity) { + return mapper.get(entity.getId(), versionMapper.toUDT(entity.getVersion())); + } + + @Override + public void updateQuestionnaireData(String id, Version version, String questionnaireData) { + accessor.updateQuestionnaireData(questionnaireData, id, versionMapper.toUDT(version)); + } + + @Accessor + interface VspQuestionnaireAccessor { + + @Query("update vsp_information set questionnaire_data=? where vsp_id=? and version=?") + ResultSet updateQuestionnaireData(String questionnaireData, String id, UDTValue version); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/VspQuestionnaireDaoFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/VspQuestionnaireDaoFactoryImpl.java new file mode 100644 index 0000000000..aa91302ca2 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/main/java/org/openecomp/sdc/vendorsoftwareproduct/dao/impl/VspQuestionnaireDaoFactoryImpl.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.vendorsoftwareproduct.dao.impl; + +import org.openecomp.sdc.vendorsoftwareproduct.dao.VspQuestionnaireDao; +import org.openecomp.sdc.vendorsoftwareproduct.dao.VspQuestionnaireDaoFactory; + +public class VspQuestionnaireDaoFactoryImpl extends VspQuestionnaireDaoFactory { + private static final VspQuestionnaireDao INSTANCE = new VspQuestionnaireDaoCassandraImpl(); + + @Override + public VspQuestionnaireDao createInterface() { + return INSTANCE; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ServiceModelDaoFactoryTest.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ServiceModelDaoFactoryTest.java new file mode 100644 index 0000000000..2c8ffb1ded --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ServiceModelDaoFactoryTest.java @@ -0,0 +1,97 @@ +package org.openecomp.sdc.vendorsoftwareproduct.dao; + +import org.openecomp.sdc.tosca.datatypes.ToscaServiceModel; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; + +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.core.model.dao.ServiceModelDaoFactory; +import org.openecomp.core.model.types.ServiceArtifact; +import org.openecomp.core.utilities.CommonMethods; +import org.openecomp.core.utilities.file.FileContentHandler; +import org.testng.Assert; +import org.testng.annotations.Test; + +import java.util.HashMap; +import java.util.Map; + +public class ServiceModelDaoFactoryTest { + + private static final String vspId = CommonMethods.nextUuId(); + private static final Version version = Version.valueOf("1.0"); + private static final String baseServiceTemplateName = "baseYaml.yaml"; + private static String artifact001; + + +// @Test + public void storeServiceModelTest() { + + + ToscaServiceModel model = getToscaServiceModel(); + ServiceModelDaoFactory.getInstance().createInterface().storeServiceModel(vspId, version, model); + } + + +// @Test(dependsOnMethods = "storeServiceModelTest") + public void getServiceModelTest() { + Object model = + ServiceModelDaoFactory.getInstance().createInterface().getServiceModel(vspId, version); + Assert.assertNotNull(model); + Assert.assertTrue(model instanceof ToscaServiceModel); + if (model instanceof ToscaServiceModel) { + + artifact001 = + (String) ((ToscaServiceModel) model).getArtifactFiles().getFileList().toArray()[0]; + } + } + +// @Test(dependsOnMethods = "getServiceModelTest") + public void getServiceModelInfoTest() { + Object info = ServiceModelDaoFactory.getInstance().createInterface() + .getServiceModelInfo(vspId, version, artifact001); + Assert.assertNotNull(info); + Assert.assertTrue(info instanceof ServiceArtifact); + if (info instanceof ServiceArtifact) { + Assert.assertEquals(((ServiceArtifact) info).getName(), artifact001); + } + } + + private ToscaServiceModel getToscaServiceModel() { + + Map serviceTemplates = getServiceTemplates(baseServiceTemplateName); + FileContentHandler artifacts = getArtifacts(); + return new ToscaServiceModel(artifacts, serviceTemplates, baseServiceTemplateName); + } + + + private Map getServiceTemplates(String base) { + + Map serviceTemplates = new HashMap<>(); + + serviceTemplates.put(base, getServiceTemplate()); + serviceTemplates.put("SERV1", getServiceTemplate()); + serviceTemplates.put("SERV2", getServiceTemplate()); + serviceTemplates.put("SERV3", getServiceTemplate()); + serviceTemplates.put("SERV4", getServiceTemplate()); + + return serviceTemplates; + } + + public FileContentHandler getArtifacts() { + Map artifacts = new HashMap<>(); + artifacts.put("art1", "this is art1".getBytes()); + artifacts.put("art2", ("this is art2 desc:" + CommonMethods.nextUuId()).getBytes()); + artifacts.put("art2", ("this is art3 desc:" + CommonMethods.nextUuId()).getBytes()); + artifacts.put("art2", ("this is art4 desc:" + CommonMethods.nextUuId()).getBytes()); + + FileContentHandler fileContentHandler = new FileContentHandler(); + fileContentHandler.putAll(artifacts); + return fileContentHandler; + } + + public ServiceTemplate getServiceTemplate() { + ServiceTemplate serviceTemplate = new ServiceTemplate(); + serviceTemplate.setTosca_definitions_version("version 1.0"); + serviceTemplate.setDescription(CommonMethods.nextUuId()); + return serviceTemplate; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/pom.xml b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/pom.xml new file mode 100644 index 0000000000..8eabd76102 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/pom.xml @@ -0,0 +1,23 @@ + + + 4.0.0 + + + org.openecomp.sdc + openecomp-sdc-lib + 1.0.0-SNAPSHOT + + + + openecomp-sdc-vendor-software-product-lib + pom + + + openecomp-sdc-vendor-software-product-api + openecomp-sdc-vendor-software-product-core + + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/pom.xml b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/pom.xml new file mode 100644 index 0000000000..180410dcf0 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/pom.xml @@ -0,0 +1,71 @@ + + 4.0.0 + + + org.openecomp.sdc + openecomp-sdc-lib + 1.0.0-SNAPSHOT + ../.. + + + openecomp-sdc-versioning-api + openecomp-sdc-versioning-api + + + + org.openecomp.core + openecomp-facade-core + ${project.version} + + + org.openecomp.core + openecomp-facade-api + ${project.version} + + + org.openecomp.core + openecomp-nosqldb-core + ${project.version} + + + org.hibernate + hibernate-validator + ${hibernate.validator.version} + + + javax.el + javax.el-api + ${javax.el-api.version} + + + org.glassfish.web + javax.el + 2.2.4 + + + org.mockito + mockito-all + test + 1.10.19 + + + org.testng + testng + test + 6.8.5 + + + snakeyaml + org.yaml + + + + + junit + junit + test + RELEASE + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/VersioningManager.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/VersioningManager.java new file mode 100644 index 0000000000..7fab25456c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/VersioningManager.java @@ -0,0 +1,57 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning; + +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.types.VersionInfo; +import org.openecomp.sdc.versioning.types.VersionableEntityAction; +import org.openecomp.sdc.versioning.types.VersionableEntityMetadata; + +import java.util.Map; + +public interface VersioningManager { + + void register(String entityType, VersionableEntityMetadata entityMetadata); + + Version create(String entityType, String entityId, String user); + + void delete(String entityType, String entityId, String user); + + void undoDelete(String entityType, String entityId, String user); + + Version checkout(String entityType, String entityId, String user); + + Version undoCheckout(String entityType, String entityId, String user); + + Version checkin(String entityType, String entityId, String user, String checkinDescription); + + Version submit(String entityType, String entityId, String user, String submitDescription); + + VersionInfo getEntityVersionInfo(String entityType, String entityId, String user, + VersionableEntityAction action); + + Map listEntitiesVersionInfo(String entityType, String user, + VersionableEntityAction action); + + Map listDeletedEntitiesVersionInfo(String entityType, String user, + VersionableEntityAction action); + +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/VersioningManagerFactory.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/VersioningManagerFactory.java new file mode 100644 index 0000000000..089777bbe6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/VersioningManagerFactory.java @@ -0,0 +1,31 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; + +public abstract class VersioningManagerFactory extends AbstractComponentFactory { + + public static VersioningManagerFactory getInstance() { + return AbstractFactory.getInstance(VersioningManagerFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/VersioningUtil.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/VersioningUtil.java new file mode 100644 index 0000000000..d51f8c0a2b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/VersioningUtil.java @@ -0,0 +1,187 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning; + +import org.openecomp.core.dao.BaseDao; +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.dao.types.VersionableEntity; +import org.openecomp.sdc.versioning.errors.RequestedVersionInvalidErrorBuilder; +import org.openecomp.sdc.versioning.errors.VersionableSubEntityNotFoundErrorBuilder; +import org.openecomp.sdc.versioning.types.VersionInfo; + +import java.util.ArrayList; +import java.util.List; +import java.util.Set; +import java.util.stream.Collectors; + +/** + * The type Versioning util. + */ +public class VersioningUtil { + + /** + * Validate entity existence. + * + * @param the type parameter + * @param retrievedEntity the retrieved entity + * @param inputEntity the input entity + * @param firstClassCitizenType the first class citizen type + */ + public static void validateEntityExistence(Object retrievedEntity, + T inputEntity, + String firstClassCitizenType) { + if (retrievedEntity == null) { + throw new CoreException(new VersionableSubEntityNotFoundErrorBuilder( + inputEntity.getEntityType(), + inputEntity.getId(), + firstClassCitizenType, + inputEntity.getFirstClassCitizenId(), + inputEntity.getVersion()).build()); + } + } + + /** + * Validate entities existence. + * + * @param the type parameter + * @param the type parameter + * @param entityIds the entity ids + * @param entity the entity + * @param entityDao the entity dao + * @param firstClassCitizenType the first class citizen type + */ + public static > void validateEntitiesExistence( + Set entityIds, T entity, D entityDao, String firstClassCitizenType) { + if (entityIds == null) { + return; + } + + List nonExistingIds = new ArrayList<>(); + for (String entityId : entityIds) { + entity.setId(entityId); + if (entityDao.get(entity) == null) { + nonExistingIds.add(entityId); + } + } + + if (nonExistingIds.size() > 0) { + if (nonExistingIds.size() == 1) { + throw new CoreException(new VersionableSubEntityNotFoundErrorBuilder( + entity.getEntityType(), + nonExistingIds.get(0), + firstClassCitizenType, + entity.getFirstClassCitizenId(), + entity.getVersion()).build()); + } + throw new CoreException(new VersionableSubEntityNotFoundErrorBuilder( + entity.getEntityType(), + nonExistingIds, + firstClassCitizenType, + entity.getFirstClassCitizenId(), + entity.getVersion()).build()); + } + } + + /** + * Validate contained entities existence. + * + * @param the type parameter + * @param containedEntityType the contained entity type + * @param inputContainedEntityIds the input contained entity ids + * @param containingEntity the containing entity + * @param retrievedContainedEntityIds the retrieved contained entity ids + */ + public static void validateContainedEntitiesExistence( + String containedEntityType, Set inputContainedEntityIds, T containingEntity, + Set retrievedContainedEntityIds) { + if (inputContainedEntityIds == null) { + return; + } + + List nonExistingIds = inputContainedEntityIds.stream() + .filter(entityId -> !retrievedContainedEntityIds.contains(entityId)) + .collect(Collectors.toList()); + + if (nonExistingIds.size() > 0) { + if (nonExistingIds.size() == 1) { + throw new CoreException(new VersionableSubEntityNotFoundErrorBuilder( + containedEntityType, + nonExistingIds.get(0), + containingEntity.getEntityType(), + containingEntity.getId(), + containingEntity.getVersion()).build()); + } + throw new CoreException(new VersionableSubEntityNotFoundErrorBuilder( + containedEntityType, + nonExistingIds, + containingEntity.getEntityType(), + containingEntity.getId(), + containingEntity.getVersion()).build()); + } + } + + /** + * Resolve version version. + * + * @param requestedVersion the requested version + * @param versionInfo the version info + * @param finalOnly the final only + * @return the version + */ + public static Version resolveVersion(Version requestedVersion, VersionInfo versionInfo, + boolean finalOnly) { + if (requestedVersion == null) { + if (finalOnly) { + if (versionInfo.getLatestFinalVersion() == null) { + throw new CoreException(new RequestedVersionInvalidErrorBuilder().build()); + } + requestedVersion = versionInfo.getLatestFinalVersion(); + } else { + requestedVersion = versionInfo.getActiveVersion(); + } + } else { + if ((finalOnly && !requestedVersion.isFinal()) + || !versionInfo.getViewableVersions().contains(requestedVersion)) { + throw new CoreException(new RequestedVersionInvalidErrorBuilder().build()); + } + } + return requestedVersion; + } + + /** + * Resolve version version. + * + * @param requestedVersion the requested version + * @param versionInfo the version info + * @return the version + */ + public static Version resolveVersion(Version requestedVersion, VersionInfo versionInfo) { + if (requestedVersion == null) { + requestedVersion = versionInfo.getActiveVersion(); + } else { + if (!versionInfo.getViewableVersions().contains(requestedVersion)) { + throw new CoreException(new RequestedVersionInvalidErrorBuilder().build()); + } + } + return requestedVersion; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionHistoryDao.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionHistoryDao.java new file mode 100644 index 0000000000..f90265aeb6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionHistoryDao.java @@ -0,0 +1,27 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.dao; + +import org.openecomp.core.dao.BaseDao; +import org.openecomp.sdc.versioning.dao.types.VersionHistoryEntity; + +public interface VersionHistoryDao extends BaseDao { +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionHistoryDaoFactory.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionHistoryDaoFactory.java new file mode 100644 index 0000000000..9ea8d714b0 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionHistoryDaoFactory.java @@ -0,0 +1,30 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.dao; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; + +public abstract class VersionHistoryDaoFactory extends AbstractComponentFactory { + public static VersionHistoryDaoFactory getInstance() { + return AbstractFactory.getInstance(VersionHistoryDaoFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionInfoDao.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionInfoDao.java new file mode 100644 index 0000000000..260214eb07 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionInfoDao.java @@ -0,0 +1,28 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.dao; + +import org.openecomp.core.dao.BaseDao; +import org.openecomp.sdc.versioning.dao.types.VersionInfoEntity; + +public interface VersionInfoDao extends BaseDao { + +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionInfoDaoFactory.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionInfoDaoFactory.java new file mode 100644 index 0000000000..ebdb1a590b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionInfoDaoFactory.java @@ -0,0 +1,30 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.dao; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; + +public abstract class VersionInfoDaoFactory extends AbstractComponentFactory { + public static VersionInfoDaoFactory getInstance() { + return AbstractFactory.getInstance(VersionInfoDaoFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionInfoDeletedDao.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionInfoDeletedDao.java new file mode 100644 index 0000000000..cb6c050520 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionInfoDeletedDao.java @@ -0,0 +1,29 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.dao; + + +import org.openecomp.core.dao.BaseDao; +import org.openecomp.sdc.versioning.dao.types.VersionInfoDeletedEntity; + +public interface VersionInfoDeletedDao extends BaseDao { + +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionInfoDeletedDaoFactory.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionInfoDeletedDaoFactory.java new file mode 100644 index 0000000000..d14cbfeb0b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionInfoDeletedDaoFactory.java @@ -0,0 +1,32 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.dao; + + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; + +public abstract class VersionInfoDeletedDaoFactory + extends AbstractComponentFactory { + public static VersionInfoDeletedDaoFactory getInstance() { + return AbstractFactory.getInstance(VersionInfoDeletedDaoFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionableDao.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionableDao.java new file mode 100644 index 0000000000..12cef62f44 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionableDao.java @@ -0,0 +1,25 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.dao; + +public interface VersionableDao { + void registerVersioning(String versionableEntityType); +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionableEntityDao.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionableEntityDao.java new file mode 100644 index 0000000000..8709a983a3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionableEntityDao.java @@ -0,0 +1,34 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.dao; + +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.types.VersionableEntityMetadata; + +public interface VersionableEntityDao { + + void initVersion(VersionableEntityMetadata versionableTableMetadata, String entityId, + Version baseVersion, Version newVersion); + + void deleteVersion(VersionableEntityMetadata versionableTableMetadata, String entityId, + Version versionToDelete); + +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionableEntityDaoFactory.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionableEntityDaoFactory.java new file mode 100644 index 0000000000..be3c635be2 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/VersionableEntityDaoFactory.java @@ -0,0 +1,31 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.dao; + +import org.openecomp.core.factory.api.AbstractComponentFactory; +import org.openecomp.core.factory.api.AbstractFactory; + +public abstract class VersionableEntityDaoFactory + extends AbstractComponentFactory { + public static VersionableEntityDaoFactory getInstance() { + return AbstractFactory.getInstance(VersionableEntityDaoFactory.class); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/UserCandidateVersion.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/UserCandidateVersion.java new file mode 100644 index 0000000000..ca044142de --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/UserCandidateVersion.java @@ -0,0 +1,56 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.dao.types; + +import com.datastax.driver.mapping.annotations.Frozen; +import com.datastax.driver.mapping.annotations.UDT; + +@UDT(name = "user_candidate_version", keyspace = "dox") +public class UserCandidateVersion { + + @Frozen + private Version version; + private String user; + + public UserCandidateVersion() { + } + + public UserCandidateVersion(String user, Version candidateVersion) { + this.user = user; + this.version = candidateVersion; + } + + public Version getVersion() { + return version; + } + + public void setVersion(Version version) { + this.version = version; + } + + public String getUser() { + return user; + } + + public void setUser(String user) { + this.user = user; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/Version.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/Version.java new file mode 100644 index 0000000000..e6ac799fd4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/Version.java @@ -0,0 +1,119 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.dao.types; + +import com.datastax.driver.mapping.annotations.UDT; + +@UDT(name = "version", keyspace = "dox") +public class Version { + public static final String VERSION_REGEX = "^\\d+\\.\\d+$"; + public static final String VERSION_STRING_VIOLATION_MSG = + "Version string must be in the format of: {integer}.{integer}"; + + private int major; + private int minor; + + public Version() { + } + + public Version(int major, int minor) { + this.major = major; + this.minor = minor; + } + + /** + * Value of version. + * + * @param versionString the version string + * @return the version + */ + public static Version valueOf(String versionString) { + if (versionString == null) { + return null; + } + String[] versionLevels = versionString.split("\\."); + Version version; + if (versionLevels.length != 2) { + throw new IllegalArgumentException(VERSION_STRING_VIOLATION_MSG); + } + try { + version = new Version(Integer.parseInt(versionLevels[0]), Integer.parseInt(versionLevels[1])); + } catch (Exception exception) { + throw new IllegalArgumentException(VERSION_STRING_VIOLATION_MSG); + } + + return version; + } + + public int getMajor() { + return major; + } + + public void setMajor(int major) { + this.major = major; + } + + public int getMinor() { + return minor; + } + + public void setMinor(int minor) { + this.minor = minor; + } + + public Version calculateNextCandidate() { + return new Version(major, minor + 1); + } + + public Version calculateNextFinal() { + return new Version(major + 1, 0); + } + + public boolean isFinal() { + return major != 0 && minor == 0; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (obj == null || getClass() != obj.getClass()) { + return false; + } + + Version version = (Version) obj; + + return major == version.major && minor == version.minor; + } + + @Override + public int hashCode() { + int result = major; + result = 31 * result + minor; + return result; + } + + @Override + public String toString() { + return major + "." + minor; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/VersionHistoryEntity.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/VersionHistoryEntity.java new file mode 100644 index 0000000000..e97e177f52 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/VersionHistoryEntity.java @@ -0,0 +1,90 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.dao.types; + +import com.datastax.driver.mapping.annotations.Column; +import com.datastax.driver.mapping.annotations.Frozen; +import com.datastax.driver.mapping.annotations.PartitionKey; +import com.datastax.driver.mapping.annotations.Table; + +@Table(keyspace = "dox", name = "version_history") +public class VersionHistoryEntity { + + @PartitionKey + @Column(name = "entity_id") + @Frozen + private VersionableEntityId entityId; + + @Column(name = "active_version") + @Frozen + private Version version; + + private String user; + private String description; + private VersionType type; + + public VersionHistoryEntity() { + } + + public VersionHistoryEntity(VersionableEntityId entityId) { + this.entityId = entityId; + } + + public VersionableEntityId getEntityId() { + return entityId; + } + + public void setEntityId(VersionableEntityId entityId) { + this.entityId = entityId; + } + + public Version getVersion() { + return version; + } + + public void setVersion(Version version) { + this.version = version; + } + + public String getUser() { + return user; + } + + public void setUser(String user) { + this.user = user; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public VersionType getType() { + return type; + } + + public void setType(VersionType type) { + this.type = type; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/VersionInfoDeletedEntity.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/VersionInfoDeletedEntity.java new file mode 100644 index 0000000000..9a60aa3b4a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/VersionInfoDeletedEntity.java @@ -0,0 +1,126 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.dao.types; + +import com.datastax.driver.mapping.annotations.ClusteringColumn; +import com.datastax.driver.mapping.annotations.Column; +import com.datastax.driver.mapping.annotations.Enumerated; +import com.datastax.driver.mapping.annotations.Frozen; +import com.datastax.driver.mapping.annotations.FrozenValue; +import com.datastax.driver.mapping.annotations.PartitionKey; +import com.datastax.driver.mapping.annotations.Table; + +import java.util.HashSet; +import java.util.Set; + +@Table(keyspace = "dox", name = "version_info_deleted") +public class VersionInfoDeletedEntity { + + @PartitionKey + @Column(name = "entity_type") + private String entityType; + + @ClusteringColumn + @Column(name = "entity_id") + private String entityId; + + @Column(name = "active_version") + @Frozen + private Version activeVersion; + + @Enumerated + private VersionStatus status; + + @Frozen + private UserCandidateVersion candidate; + + @Column(name = "viewable_versions") + @FrozenValue + private Set viewableVersions = new HashSet<>(); + + @Column(name = "latest_final_version") + @Frozen + private Version latestFinalVersion; + + public VersionInfoDeletedEntity() { + } + + public VersionInfoDeletedEntity(String entityType, String entityId) { + this.entityType = entityType; + this.entityId = entityId; + } + + public String getEntityType() { + return entityType; + } + + public void setEntityType(String entityType) { + this.entityType = entityType; + } + + public String getEntityId() { + return entityId; + } + + public void setEntityId(String entityId) { + this.entityId = entityId; + } + + public Version getActiveVersion() { + return activeVersion; + } + + public void setActiveVersion(Version activeVersion) { + this.activeVersion = activeVersion; + } + + public VersionStatus getStatus() { + return status; + } + + public void setStatus(VersionStatus status) { + this.status = status; + } + + public UserCandidateVersion getCandidate() { + return candidate; + } + + public void setCandidate(UserCandidateVersion candidate) { + this.candidate = candidate; + } + + public Set getViewableVersions() { + return viewableVersions; + } + + public void setViewableVersions(Set viewableVersions) { + this.viewableVersions = viewableVersions; + } + + public Version getLatestFinalVersion() { + return latestFinalVersion; + } + + public void setLatestFinalVersion(Version latestFinalVersion) { + this.latestFinalVersion = latestFinalVersion; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/VersionInfoEntity.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/VersionInfoEntity.java new file mode 100644 index 0000000000..35ab4056f9 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/VersionInfoEntity.java @@ -0,0 +1,126 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.dao.types; + +import com.datastax.driver.mapping.annotations.ClusteringColumn; +import com.datastax.driver.mapping.annotations.Column; +import com.datastax.driver.mapping.annotations.Enumerated; +import com.datastax.driver.mapping.annotations.Frozen; +import com.datastax.driver.mapping.annotations.FrozenValue; +import com.datastax.driver.mapping.annotations.PartitionKey; +import com.datastax.driver.mapping.annotations.Table; + +import java.util.HashSet; +import java.util.Set; + +@Table(keyspace = "dox", name = "version_info") +public class VersionInfoEntity { + + @PartitionKey + @Column(name = "entity_type") + private String entityType; + + @ClusteringColumn + @Column(name = "entity_id") + private String entityId; + + @Column(name = "active_version") + @Frozen + private Version activeVersion; + + @Enumerated + private VersionStatus status; + + @Frozen + private UserCandidateVersion candidate; + + @Column(name = "viewable_versions") + @FrozenValue + private Set viewableVersions = new HashSet<>(); + + @Column(name = "latest_final_version") + @Frozen + private Version latestFinalVersion; + + public VersionInfoEntity() { + } + + public VersionInfoEntity(String entityType, String entityId) { + this.entityType = entityType; + this.entityId = entityId; + } + + public String getEntityType() { + return entityType; + } + + public void setEntityType(String entityType) { + this.entityType = entityType; + } + + public String getEntityId() { + return entityId; + } + + public void setEntityId(String entityId) { + this.entityId = entityId; + } + + public Version getActiveVersion() { + return activeVersion; + } + + public void setActiveVersion(Version activeVersion) { + this.activeVersion = activeVersion; + } + + public VersionStatus getStatus() { + return status; + } + + public void setStatus(VersionStatus status) { + this.status = status; + } + + public UserCandidateVersion getCandidate() { + return candidate; + } + + public void setCandidate(UserCandidateVersion candidate) { + this.candidate = candidate; + } + + public Set getViewableVersions() { + return viewableVersions; + } + + public void setViewableVersions(Set viewableVersions) { + this.viewableVersions = viewableVersions; + } + + public Version getLatestFinalVersion() { + return latestFinalVersion; + } + + public void setLatestFinalVersion(Version latestFinalVersion) { + this.latestFinalVersion = latestFinalVersion; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/VersionStatus.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/VersionStatus.java new file mode 100644 index 0000000000..1fb68540d6 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/VersionStatus.java @@ -0,0 +1,28 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.dao.types; + +public enum VersionStatus { + Available, + Locked, + Final + +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/VersionType.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/VersionType.java new file mode 100644 index 0000000000..5a395c6172 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/VersionType.java @@ -0,0 +1,26 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.dao.types; + +public enum VersionType { + Draft, + Finalized +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/VersionableEntity.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/VersionableEntity.java new file mode 100644 index 0000000000..d909af86a3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/VersionableEntity.java @@ -0,0 +1,43 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.dao.types; + +public interface VersionableEntity { + + String getEntityType(); + + String getFirstClassCitizenId(); + + String getId(); + + void setId(String id); + + Version getVersion(); + + void setVersion(Version version); + + default String getVersionUuId() { + return ""; + } + + default void setVersionUuId(String uuId) { + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/VersionableEntityId.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/VersionableEntityId.java new file mode 100644 index 0000000000..78dc1b8811 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/dao/types/VersionableEntityId.java @@ -0,0 +1,53 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.dao.types; + +import com.datastax.driver.mapping.annotations.UDT; + +@UDT(name = "versionable_entity_id", keyspace = "dox") +public class VersionableEntityId { + private String type; + private String id; + + public VersionableEntityId() { + } + + public VersionableEntityId(String type, String id) { + this.type = type; + this.id = id; + } + + public String getType() { + return type; + } + + public void setType(String type) { + this.type = type; + } + + public String getId() { + return id; + } + + public void setId(String id) { + this.id = id; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/CheckinOnEntityLockedByOtherErrorBuilder.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/CheckinOnEntityLockedByOtherErrorBuilder.java new file mode 100644 index 0000000000..829ce2691b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/CheckinOnEntityLockedByOtherErrorBuilder.java @@ -0,0 +1,52 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.errors; + +import static org.openecomp.sdc.versioning.errors.VersioningErrorCodes + .CHECKIN_ON_ENTITY_LOCKED_BY_OTHER_USER; + +import org.openecomp.sdc.common.errors.BaseErrorBuilder; +import org.openecomp.sdc.common.errors.ErrorCategory; + +/** + * The type Checkin on entity locked by other error builder. + */ +public class CheckinOnEntityLockedByOtherErrorBuilder extends BaseErrorBuilder { + + private static final String CHECKIN_ON_ENTITY_LOCKED_BY_OTHER_USER_MSG = + "Can not check in versionable entity %s with id %s since it is " + + "checked out by other user: %s."; + + /** + * Instantiates a new Checkin on entity locked by other error builder. + * + * @param entityType the entity type + * @param entityId the entity id + * @param lockingUser the locking user + */ + public CheckinOnEntityLockedByOtherErrorBuilder(String entityType, String entityId, + String lockingUser) { + getErrorCodeBuilder().withId(CHECKIN_ON_ENTITY_LOCKED_BY_OTHER_USER); + getErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION); + getErrorCodeBuilder().withMessage(String + .format(CHECKIN_ON_ENTITY_LOCKED_BY_OTHER_USER_MSG, entityType, entityId, lockingUser)); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/CheckinOnUnlockedEntityErrorBuilder.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/CheckinOnUnlockedEntityErrorBuilder.java new file mode 100644 index 0000000000..4628febe2b --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/CheckinOnUnlockedEntityErrorBuilder.java @@ -0,0 +1,46 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.errors; + +import org.openecomp.sdc.common.errors.BaseErrorBuilder; +import org.openecomp.sdc.common.errors.ErrorCategory; + +/** + * The type Checkin on unlocked entity error builder. + */ +public class CheckinOnUnlockedEntityErrorBuilder extends BaseErrorBuilder { + + private static final String CHECKIN_ON_UNLOCKED_ENTITY_MSG = + "Can not check in versionable entity %s with id %s since it is not checked out."; + + /** + * Instantiates a new Checkin on unlocked entity error builder. + * + * @param entityType the entity type + * @param entityId the entity id + */ + public CheckinOnUnlockedEntityErrorBuilder(String entityType, String entityId) { + getErrorCodeBuilder().withId(VersioningErrorCodes.CHECKIN_ON_UNLOCKED_ENTITY); + getErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION); + getErrorCodeBuilder() + .withMessage(String.format(CHECKIN_ON_UNLOCKED_ENTITY_MSG, entityType, entityId)); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/CheckoutOnLockedEntityErrorBuilder.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/CheckoutOnLockedEntityErrorBuilder.java new file mode 100644 index 0000000000..60c02474ad --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/CheckoutOnLockedEntityErrorBuilder.java @@ -0,0 +1,51 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.errors; + +import org.openecomp.sdc.common.errors.BaseErrorBuilder; +import org.openecomp.sdc.common.errors.ErrorCategory; + +/** + * The type Checkout on locked entity error builder. + */ +public class CheckoutOnLockedEntityErrorBuilder extends BaseErrorBuilder { + + private static final String CHECKOT_ON_LOCKED_ENTITY_MSG = + "Can not check out versionable entity %s with id %s since it is " + + "checked out by other user: %s."; + + /** + * Instantiates a new Checkout on locked entity error builder. + * + * @param entityType the entity type + * @param entityId the entity id + * @param lockingUser the locking user + */ + public CheckoutOnLockedEntityErrorBuilder(String entityType, String entityId, + String lockingUser) { + getErrorCodeBuilder().withId(VersioningErrorCodes.CHECKOT_ON_LOCKED_ENTITY); + getErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION); + getErrorCodeBuilder().withMessage( + String.format(CHECKOT_ON_LOCKED_ENTITY_MSG, entityType, entityId, lockingUser)); + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/DeleteOnLockedEntityErrorBuilder.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/DeleteOnLockedEntityErrorBuilder.java new file mode 100644 index 0000000000..a431e92ba4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/DeleteOnLockedEntityErrorBuilder.java @@ -0,0 +1,49 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.errors; + +import org.openecomp.sdc.common.errors.BaseErrorBuilder; +import org.openecomp.sdc.common.errors.ErrorCategory; + +/** + * The type Delete on locked entity error builder. + */ +public class DeleteOnLockedEntityErrorBuilder extends BaseErrorBuilder { + + private static final String DELETE_ON_LOCKED_ENTITY_MSG = + "Can not delete versionable entity %s with id %s since it is checked out by other user: %s."; + + /** + * Instantiates a new Delete on locked entity error builder. + * + * @param entityType the entity type + * @param entityId the entity id + * @param lockingUser the locking user + */ + public DeleteOnLockedEntityErrorBuilder(String entityType, String entityId, String lockingUser) { + getErrorCodeBuilder().withId(VersioningErrorCodes.DELETE_ON_LOCKED_ENTITY); + getErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION); + getErrorCodeBuilder() + .withMessage(String.format(DELETE_ON_LOCKED_ENTITY_MSG, entityType, entityId, lockingUser)); + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/EditOnEntityLockedByOtherErrorBuilder.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/EditOnEntityLockedByOtherErrorBuilder.java new file mode 100644 index 0000000000..2c41bdeab1 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/EditOnEntityLockedByOtherErrorBuilder.java @@ -0,0 +1,50 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.errors; + +import org.openecomp.sdc.common.errors.BaseErrorBuilder; +import org.openecomp.sdc.common.errors.ErrorCategory; + +/** + * The type Edit on entity locked by other error builder. + */ +public class EditOnEntityLockedByOtherErrorBuilder extends BaseErrorBuilder { + + private static final String EDIT_ON_ENTITY_LOCKED_BY_OTHER_USER_MSG = + "Versionable entity %s with id %s can not be edited since it is locked by other user %s."; + + /** + * Instantiates a new Edit on entity locked by other error builder. + * + * @param entityType the entity type + * @param entityId the entity id + * @param lockingUser the locking user + */ + public EditOnEntityLockedByOtherErrorBuilder(String entityType, String entityId, + String lockingUser) { + getErrorCodeBuilder().withId(VersioningErrorCodes.EDIT_ON_ENTITY_LOCKED_BY_OTHER_USER); + getErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION); + getErrorCodeBuilder().withMessage( + String.format(EDIT_ON_ENTITY_LOCKED_BY_OTHER_USER_MSG, entityType, entityId, lockingUser)); + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/EditOnUnlockedEntityErrorBuilder.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/EditOnUnlockedEntityErrorBuilder.java new file mode 100644 index 0000000000..fb61cce1f0 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/EditOnUnlockedEntityErrorBuilder.java @@ -0,0 +1,48 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.errors; + +import org.openecomp.sdc.common.errors.BaseErrorBuilder; +import org.openecomp.sdc.common.errors.ErrorCategory; + +/** + * The type Edit on unlocked entity error builder. + */ +public class EditOnUnlockedEntityErrorBuilder extends BaseErrorBuilder { + + private static final String EDIT_ON_UNLOCKED_ENTITY_MSG = + "Can not edit versionable entity %s with id %s since it is not checked out."; + + /** + * Instantiates a new Edit on unlocked entity error builder. + * + * @param entityType the entity type + * @param entityId the entity id + */ + public EditOnUnlockedEntityErrorBuilder(String entityType, String entityId) { + getErrorCodeBuilder().withId(VersioningErrorCodes.EDIT_ON_UNLOCKED_ENTITY); + getErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION); + getErrorCodeBuilder() + .withMessage(String.format(EDIT_ON_UNLOCKED_ENTITY_MSG, entityType, entityId)); + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/EntityAlreadyExistErrorBuilder.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/EntityAlreadyExistErrorBuilder.java new file mode 100644 index 0000000000..8f80f6e14e --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/EntityAlreadyExistErrorBuilder.java @@ -0,0 +1,46 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.errors; + +import org.openecomp.sdc.common.errors.BaseErrorBuilder; +import org.openecomp.sdc.common.errors.ErrorCategory; + +/** + * The type Entity already exist error builder. + */ +public class EntityAlreadyExistErrorBuilder extends BaseErrorBuilder { + + private static final String VERSIONABLE_ENTITY_ALREADY_EXIST_MSG = + "Versionable entity %s with id %s already exist."; + + /** + * Instantiates a new Entity already exist error builder. + * + * @param entityType the entity type + * @param entityId the entity id + */ + public EntityAlreadyExistErrorBuilder(String entityType, String entityId) { + getErrorCodeBuilder().withId(VersioningErrorCodes.VERSIONABLE_ENTITY_ALREADY_EXIST); + getErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION); + getErrorCodeBuilder() + .withMessage(String.format(VERSIONABLE_ENTITY_ALREADY_EXIST_MSG, entityType, entityId)); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/EntityAlreadyFinalizedErrorBuilder.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/EntityAlreadyFinalizedErrorBuilder.java new file mode 100644 index 0000000000..22643ddc26 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/EntityAlreadyFinalizedErrorBuilder.java @@ -0,0 +1,51 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.errors; + +import static org.openecomp.sdc.versioning.errors.VersioningErrorCodes + .SUBMIT_FINALIZED_ENTITY_NOT_ALLOWED; + +import org.openecomp.sdc.common.errors.BaseErrorBuilder; +import org.openecomp.sdc.common.errors.ErrorCategory; + +/** + * The type Entity already finalized error builder. + */ +public class EntityAlreadyFinalizedErrorBuilder extends BaseErrorBuilder { + + private static final String SUBMIT_FINALIZED_ENTITY_NOT_ALLOWED_MSG = + "Versionable entity %s with id %s can not be submitted since it is already final."; + + /** + * Instantiates a new Entity already finalized error builder. + * + * @param entityType the entity type + * @param entityId the entity id + */ + public EntityAlreadyFinalizedErrorBuilder(String entityType, String entityId) { + getErrorCodeBuilder().withId(SUBMIT_FINALIZED_ENTITY_NOT_ALLOWED); + getErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION); + getErrorCodeBuilder() + .withMessage(String.format(SUBMIT_FINALIZED_ENTITY_NOT_ALLOWED_MSG, entityType, entityId)); + } + + +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/EntityNotExistErrorBuilder.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/EntityNotExistErrorBuilder.java new file mode 100644 index 0000000000..806557f935 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/EntityNotExistErrorBuilder.java @@ -0,0 +1,46 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.errors; + +import org.openecomp.sdc.common.errors.BaseErrorBuilder; +import org.openecomp.sdc.common.errors.ErrorCategory; + +/** + * The type Entity not exist error builder. + */ +public class EntityNotExistErrorBuilder extends BaseErrorBuilder { + + private static final String VERSIONABLE_ENTITY_NOT_EXIST_MSG = + "Versionable entity %s with id %s does not exist."; + + /** + * Instantiates a new Entity not exist error builder. + * + * @param entityType the entity type + * @param entityId the entity id + */ + public EntityNotExistErrorBuilder(String entityType, String entityId) { + getErrorCodeBuilder().withId(VersioningErrorCodes.VERSIONABLE_ENTITY_NOT_EXIST); + getErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION); + getErrorCodeBuilder() + .withMessage(String.format(VERSIONABLE_ENTITY_NOT_EXIST_MSG, entityType, entityId)); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/RequestedVersionInvalidErrorBuilder.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/RequestedVersionInvalidErrorBuilder.java new file mode 100644 index 0000000000..7d3afcb94a --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/RequestedVersionInvalidErrorBuilder.java @@ -0,0 +1,40 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.errors; + +import org.openecomp.sdc.common.errors.BaseErrorBuilder; +import org.openecomp.sdc.common.errors.ErrorCategory; + +/** + * The type Requested version invalid error builder. + */ +public class RequestedVersionInvalidErrorBuilder extends BaseErrorBuilder { + private static final String REQUESTED_VERSION_INVALID_MSG = "Invalid requested version."; + + /** + * Instantiates a new Requested version invalid error builder. + */ + public RequestedVersionInvalidErrorBuilder() { + getErrorCodeBuilder().withId(VersioningErrorCodes.REQUESTED_VERSION_INVALID); + getErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION); + getErrorCodeBuilder().withMessage(REQUESTED_VERSION_INVALID_MSG); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/SubmitLockedEntityNotAllowedErrorBuilder.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/SubmitLockedEntityNotAllowedErrorBuilder.java new file mode 100644 index 0000000000..3f4fc81b76 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/SubmitLockedEntityNotAllowedErrorBuilder.java @@ -0,0 +1,49 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.errors; + +import org.openecomp.sdc.common.errors.BaseErrorBuilder; +import org.openecomp.sdc.common.errors.ErrorCategory; + +/** + * The type Submit locked entity not allowed error builder. + */ +public class SubmitLockedEntityNotAllowedErrorBuilder extends BaseErrorBuilder { + + private static final String SUBMIT_LOCKED_ENTITY_NOT_ALLOWED_MSG = + "Versionable entity %s with id %s can not be submitted since it is currently " + + "locked by user %s."; + + /** + * Instantiates a new Submit locked entity not allowed error builder. + * + * @param entityType the entity type + * @param entityId the entity id + * @param lockingUser the locking user + */ + public SubmitLockedEntityNotAllowedErrorBuilder(String entityType, String entityId, + String lockingUser) { + getErrorCodeBuilder().withId(VersioningErrorCodes.SUBMIT_LOCKED_ENTITY_NOT_ALLOWED); + getErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION); + getErrorCodeBuilder().withMessage( + String.format(SUBMIT_LOCKED_ENTITY_NOT_ALLOWED_MSG, entityType, entityId, lockingUser)); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/UndoCheckoutOnEntityLockedByOtherErrorBuilder.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/UndoCheckoutOnEntityLockedByOtherErrorBuilder.java new file mode 100644 index 0000000000..5e2be13d61 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/UndoCheckoutOnEntityLockedByOtherErrorBuilder.java @@ -0,0 +1,53 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.errors; + +import static org.openecomp.sdc.versioning.errors.VersioningErrorCodes + .UNDO_CHECKOUT_ON_ENTITY_LOCKED_BY_OTHER_USER; + +import org.openecomp.sdc.common.errors.BaseErrorBuilder; +import org.openecomp.sdc.common.errors.ErrorCategory; + +/** + * The type Undo checkout on entity locked by other error builder. + */ +public class UndoCheckoutOnEntityLockedByOtherErrorBuilder extends BaseErrorBuilder { + + private static final String UNDO_CHECKOUT_ON_ENTITY_LOCKED_BY_OTHER_USER_MSG = + "Can not undo checkout on versionable entity %s with id %s since it is checked out by " + + "other user: %s."; + + /** + * Instantiates a new Undo checkout on entity locked by other error builder. + * + * @param entityType the entity type + * @param entityId the entity id + * @param lockingUser the locking user + */ + public UndoCheckoutOnEntityLockedByOtherErrorBuilder(String entityType, String entityId, + String lockingUser) { + getErrorCodeBuilder().withId(UNDO_CHECKOUT_ON_ENTITY_LOCKED_BY_OTHER_USER); + getErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION); + getErrorCodeBuilder().withMessage(String + .format(UNDO_CHECKOUT_ON_ENTITY_LOCKED_BY_OTHER_USER_MSG, entityType, entityId, + lockingUser)); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/UndoCheckoutOnUnlockedEntityErrorBuilder.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/UndoCheckoutOnUnlockedEntityErrorBuilder.java new file mode 100644 index 0000000000..36ca5b5c41 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/UndoCheckoutOnUnlockedEntityErrorBuilder.java @@ -0,0 +1,50 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.errors; + +import static org.openecomp.sdc.versioning.errors.VersioningErrorCodes + .UNDO_CHECKOUT_ON_UNLOCKED_ENTITY; + +import org.openecomp.sdc.common.errors.BaseErrorBuilder; +import org.openecomp.sdc.common.errors.ErrorCategory; + + +/** + * The type Undo checkout on unlocked entity error builder. + */ +public class UndoCheckoutOnUnlockedEntityErrorBuilder extends BaseErrorBuilder { + + private static final String UNDO_CHECKOUT_ON_UNLOCKED_ENTITY_MSG = + "Can not undo checkout on versionable entity %s with id %s since it is not checked out."; + + /** + * Instantiates a new Undo checkout on unlocked entity error builder. + * + * @param entityType the entity type + * @param entityId the entity id + */ + public UndoCheckoutOnUnlockedEntityErrorBuilder(String entityType, String entityId) { + getErrorCodeBuilder().withId(UNDO_CHECKOUT_ON_UNLOCKED_ENTITY); + getErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION); + getErrorCodeBuilder() + .withMessage(String.format(UNDO_CHECKOUT_ON_UNLOCKED_ENTITY_MSG, entityType, entityId)); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/VersionableSubEntityNotFoundErrorBuilder.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/VersionableSubEntityNotFoundErrorBuilder.java new file mode 100644 index 0000000000..77be83f427 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/VersionableSubEntityNotFoundErrorBuilder.java @@ -0,0 +1,77 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.errors; + +import org.openecomp.core.utilities.CommonMethods; +import org.openecomp.sdc.common.errors.BaseErrorBuilder; +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.versioning.dao.types.Version; + +import java.util.List; + +/** + * The type Versionable sub entity not found error builder. + */ +public class VersionableSubEntityNotFoundErrorBuilder extends BaseErrorBuilder { + + private static final String SUB_ENTITY_NOT_FOUND_MSG = + "%s with Id %s does not exist for %s with id %s and version %s"; + private static final String SUB_ENTITIES_NOT_FOUND_MSG = + "%ss with Ids %s do not exist for %s with id %s and version %s"; + + /** + * Instantiates a new Versionable sub entity not found error builder. + * + * @param entityType the entity type + * @param entityId the entity id + * @param containingEntityType the containing entity type + * @param containingEntityId the containing entity id + * @param version the version + */ + public VersionableSubEntityNotFoundErrorBuilder(String entityType, String entityId, + String containingEntityType, + String containingEntityId, Version version) { + getErrorCodeBuilder().withId(VersioningErrorCodes.VERSIONABLE_SUB_ENTITY_NOT_FOUND); + getErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION); + getErrorCodeBuilder().withMessage(String + .format(SUB_ENTITY_NOT_FOUND_MSG, entityType, entityId, containingEntityType, + containingEntityId, version.toString())); + } + + /** + * Instantiates a new Versionable sub entity not found error builder. + * + * @param entityType the entity type + * @param entityIds the entity ids + * @param containingEntityType the containing entity type + * @param containingEntityId the containing entity id + * @param version the version + */ + public VersionableSubEntityNotFoundErrorBuilder(String entityType, List entityIds, + String containingEntityType, + String containingEntityId, Version version) { + getErrorCodeBuilder().withId(VersioningErrorCodes.VERSIONABLE_SUB_ENTITY_NOT_FOUND); + getErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION); + getErrorCodeBuilder().withMessage(String.format(SUB_ENTITIES_NOT_FOUND_MSG, entityType, + CommonMethods.listToSeparatedString(entityIds, ','), containingEntityType, + containingEntityId, version.toString())); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/VersioningErrorCodes.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/VersioningErrorCodes.java new file mode 100644 index 0000000000..c1c6b96bfd --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/errors/VersioningErrorCodes.java @@ -0,0 +1,43 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.errors; + +public class VersioningErrorCodes { + + public static final String REQUESTED_VERSION_INVALID = "REQUESTED_VERSION_INVALID"; + public static final String CHECKIN_ON_ENTITY_LOCKED_BY_OTHER_USER = + "CHECKIN_ON_ENTITY_LOCKED_BY_OTHER_USER"; + public static final String CHECKIN_ON_UNLOCKED_ENTITY = "CHECKIN_ON_UNLOCKED_ENTITY"; + public static final String CHECKOT_ON_LOCKED_ENTITY = "CHECKOT_ON_LOCKED_ENTITY"; + public static final String DELETE_ON_LOCKED_ENTITY = "DELETE_ON_LOCKED_ENTITY"; + public static final String EDIT_ON_ENTITY_LOCKED_BY_OTHER_USER = + "EDIT_ON_ENTITY_LOCKED_BY_OTHER_USER"; + public static final String EDIT_ON_UNLOCKED_ENTITY = "EDIT_ON_UNLOCKED_ENTITY"; + public static final String VERSIONABLE_ENTITY_ALREADY_EXIST = "VERSIONABLE_ENTITY_ALREADY_EXIST"; + public static final String SUBMIT_FINALIZED_ENTITY_NOT_ALLOWED = + "SUBMIT_FINALIZED_ENTITY_NOT_ALLOWED"; + public static final String VERSIONABLE_ENTITY_NOT_EXIST = "VERSIONABLE_ENTITY_NOT_EXIST"; + public static final String VERSIONABLE_SUB_ENTITY_NOT_FOUND = "VERSIONABLE_SUB_ENTITY_NOT_FOUND"; + public static final String SUBMIT_LOCKED_ENTITY_NOT_ALLOWED = "SUBMIT_LOCKED_ENTITY_NOT_ALLOWED"; + public static final String UNDO_CHECKOUT_ON_ENTITY_LOCKED_BY_OTHER_USER = + "UNDO_CHECKOUT_ON_ENTITY_LOCKED_BY_OTHER_USER"; + public static final String UNDO_CHECKOUT_ON_UNLOCKED_ENTITY = "UNDO_CHECKOUT_ON_UNLOCKED_ENTITY"; +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/types/UniqueValueMetadata.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/types/UniqueValueMetadata.java new file mode 100644 index 0000000000..21d42299fa --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/types/UniqueValueMetadata.java @@ -0,0 +1,49 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.types; + +import java.util.List; + +public class UniqueValueMetadata { + private String type; + private List uniqueConstraintIdentifiers; + + public UniqueValueMetadata(String type, List contextIdentifierNames) { + this.type = type; + this.uniqueConstraintIdentifiers = contextIdentifierNames; + } + + public String getType() { + return type; + } + + public void setType(String type) { + this.type = type; + } + + public List getUniqueConstraintIdentifiers() { + return uniqueConstraintIdentifiers; + } + + public void setUniqueConstraintIdentifiers(List uniqueConstraintIdentifiers) { + this.uniqueConstraintIdentifiers = uniqueConstraintIdentifiers; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/types/VersionInfo.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/types/VersionInfo.java new file mode 100644 index 0000000000..02b5aaa3bd --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/types/VersionInfo.java @@ -0,0 +1,97 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.types; + +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.dao.types.VersionStatus; + +import java.util.ArrayList; +import java.util.List; + +public class VersionInfo { + private Version activeVersion; + private Version latestFinalVersion; + private List viewableVersions = new ArrayList<>(); + private List finalVersions = new ArrayList<>(); + private VersionStatus status; + private String lockingUser; + + public Version getActiveVersion() { + return activeVersion; + } + + public void setActiveVersion(Version activeVersion) { + this.activeVersion = activeVersion; + } + + public Version getLatestFinalVersion() { + return latestFinalVersion; + } + + public void setLatestFinalVersion(Version latestFinalVersion) { + this.latestFinalVersion = latestFinalVersion; + } + + public List getViewableVersions() { + return viewableVersions; + } + + public void setViewableVersions(List viewableVersions) { + this.viewableVersions = viewableVersions; + } + + public List getFinalVersions() { + return finalVersions; + } + + public void setFinalVersions(List finalVersions) { + this.finalVersions = finalVersions; + } + + public VersionStatus getStatus() { + return status; + } + + public void setStatus(VersionStatus status) { + this.status = status; + } + + public String getLockingUser() { + return lockingUser; + } + + public void setLockingUser(String lockingUser) { + this.lockingUser = lockingUser; + } + + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("VersionInfo{"); + sb.append("activeVersion=").append(activeVersion); + sb.append(", latestFinalVersion=").append(latestFinalVersion); + sb.append(", viewableVersions=").append(viewableVersions); + sb.append(", finalVersions=").append(finalVersions); + sb.append(", status=").append(status); + sb.append(", lockingUser='").append(lockingUser).append('\''); + sb.append('}'); + return sb.toString(); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/types/VersionableEntityAction.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/types/VersionableEntityAction.java new file mode 100644 index 0000000000..c7413858e5 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/types/VersionableEntityAction.java @@ -0,0 +1,26 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.types; + +public enum VersionableEntityAction { + Read, + Write +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/types/VersionableEntityMetadata.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/types/VersionableEntityMetadata.java new file mode 100644 index 0000000000..161221abe3 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/java/org/openecomp/sdc/versioning/types/VersionableEntityMetadata.java @@ -0,0 +1,78 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.types; + +import java.util.ArrayList; +import java.util.List; + +public class VersionableEntityMetadata { + + private String name; + private String identifierName; + private String versionIdentifierName; + private List uniqueValuesMetadata = new ArrayList<>(); + + /** + * Instantiates a new Versionable entity metadata. + * + * @param name the name + * @param identifierName the identifier name + * @param versionIdentifierName the version identifier name + */ + public VersionableEntityMetadata(String name, String identifierName, + String versionIdentifierName) { + this.name = name; + this.identifierName = identifierName; + this.versionIdentifierName = versionIdentifierName; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getIdentifierName() { + return identifierName; + } + + public void setIdentifierName(String idColumnName) { + this.identifierName = idColumnName; + } + + public String getVersionIdentifierName() { + return versionIdentifierName; + } + + public void setVersionIdentifierName(String versionColumnName) { + this.versionIdentifierName = versionColumnName; + } + + public List getUniqueValuesMetadata() { + return uniqueValuesMetadata; + } + + public void setUniqueValuesMetadata(List uniqueValuesMetadata) { + this.uniqueValuesMetadata = uniqueValuesMetadata; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/resources/factoryConfiguration.json b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/resources/factoryConfiguration.json new file mode 100644 index 0000000000..f36c2d5a43 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-api/src/main/resources/factoryConfiguration.json @@ -0,0 +1,7 @@ +{ + "org.openecomp.sdc.versioning.VersioningManagerFactory": "org.openecomp.sdc.versioning.impl.VersioningManagerFactoryImpl", + "org.openecomp.sdc.versioning.dao.VersionableEntityDaoFactory" : "org.openecomp.sdc.versioning.dao.impl.VersionableEntityDaoFactoryImpl", + "org.openecomp.sdc.versioning.dao.VersionInfoDaoFactory": "org.openecomp.sdc.versioning.dao.impl.VersionInfoDaoFactoryImpl", + "org.openecomp.sdc.versioning.dao.VersionInfoDeletedDaoFactory": "org.openecomp.sdc.versioning.dao.impl.VersionInfoDeletedDaoFactoryImpl" + +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/pom.xml b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/pom.xml new file mode 100644 index 0000000000..9812a3e941 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/pom.xml @@ -0,0 +1,61 @@ + + 4.0.0 + + + org.openecomp.sdc + openecomp-sdc-lib + 1.0.0-SNAPSHOT + ../.. + + + openecomp-sdc-versioning-core + openecomp-sdc-versioning-core + + + + + org.openecomp.sdc + openecomp-sdc-versioning-api + ${project.version} + + + com.google.code.gson + gson + 2.3.1 + test + + + org.yaml + snakeyaml + 1.14 + test + + + + org.mockito + mockito-all + test + 1.10.19 + + + org.testng + testng + test + 6.8.5 + + + snakeyaml + org.yaml + + + + + junit + junit + test + RELEASE + + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionHistoryCassandraDaoImpl.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionHistoryCassandraDaoImpl.java new file mode 100644 index 0000000000..a50a8b7beb --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionHistoryCassandraDaoImpl.java @@ -0,0 +1,69 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.dao.impl; + +import com.datastax.driver.core.UDTValue; +import com.datastax.driver.mapping.Mapper; +import com.datastax.driver.mapping.Result; +import com.datastax.driver.mapping.UDTMapper; +import com.datastax.driver.mapping.annotations.Accessor; +import com.datastax.driver.mapping.annotations.Query; +import org.openecomp.core.dao.impl.CassandraBaseDao; +import org.openecomp.core.nosqldb.api.NoSqlDb; +import org.openecomp.core.nosqldb.factory.NoSqlDbFactory; +import org.openecomp.sdc.versioning.dao.VersionHistoryDao; +import org.openecomp.sdc.versioning.dao.types.VersionHistoryEntity; +import org.openecomp.sdc.versioning.dao.types.VersionableEntityId; + +import java.util.Collection; + +public class VersionHistoryCassandraDaoImpl extends CassandraBaseDao + implements VersionHistoryDao { + + private static NoSqlDb noSqlDb = NoSqlDbFactory.getInstance().createInterface(); + private static Mapper mapper = + noSqlDb.getMappingManager().mapper(VersionHistoryEntity.class); + private static VersionHistoryAccessor accessor = + noSqlDb.getMappingManager().createAccessor(VersionHistoryAccessor.class); + private static UDTMapper versionedEntityIdMapper = + noSqlDb.getMappingManager().udtMapper(VersionableEntityId.class); + + @Override + protected Mapper getMapper() { + return mapper; + } + + @Override + protected Object[] getKeys(VersionHistoryEntity entity) { + return new Object[]{versionedEntityIdMapper.toUDT(entity.getEntityId())}; + } + + @Override + public Collection list(VersionHistoryEntity entity) { + return accessor.getAll(versionedEntityIdMapper.toUDT(entity.getEntityId())).all(); + } + + @Accessor + interface VersionHistoryAccessor { + @Query("select * from version_history where entity_id=?") + Result getAll(UDTValue entityId); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionHistoryDaoFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionHistoryDaoFactoryImpl.java new file mode 100644 index 0000000000..ac1c7e9634 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionHistoryDaoFactoryImpl.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.dao.impl; + +import org.openecomp.sdc.versioning.dao.VersionHistoryDao; +import org.openecomp.sdc.versioning.dao.VersionHistoryDaoFactory; + +public class VersionHistoryDaoFactoryImpl extends VersionHistoryDaoFactory { + private static final VersionHistoryDao INSTANCE = new VersionHistoryCassandraDaoImpl(); + + @Override + public VersionHistoryDao createInterface() { + return INSTANCE; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionInfoDaoFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionInfoDaoFactoryImpl.java new file mode 100644 index 0000000000..46c6a9d795 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionInfoDaoFactoryImpl.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.dao.impl; + +import org.openecomp.sdc.versioning.dao.VersionInfoDao; +import org.openecomp.sdc.versioning.dao.VersionInfoDaoFactory; + +public class VersionInfoDaoFactoryImpl extends VersionInfoDaoFactory { + private static VersionInfoDao INSTANCE = new VersionInfoDaoImpl(); + + @Override + public VersionInfoDao createInterface() { + return INSTANCE; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionInfoDaoImpl.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionInfoDaoImpl.java new file mode 100644 index 0000000000..a45c211f94 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionInfoDaoImpl.java @@ -0,0 +1,66 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.dao.impl; + +import com.datastax.driver.mapping.Mapper; +import com.datastax.driver.mapping.Result; +import com.datastax.driver.mapping.annotations.Accessor; +import com.datastax.driver.mapping.annotations.Query; +import org.openecomp.core.dao.impl.CassandraBaseDao; +import org.openecomp.core.nosqldb.api.NoSqlDb; +import org.openecomp.core.nosqldb.factory.NoSqlDbFactory; +import org.openecomp.sdc.versioning.dao.VersionInfoDao; +import org.openecomp.sdc.versioning.dao.types.VersionInfoEntity; + +import java.util.Collection; + +public class VersionInfoDaoImpl extends CassandraBaseDao + implements VersionInfoDao { + + private static NoSqlDb noSqlDb = NoSqlDbFactory.getInstance().createInterface(); + private static Mapper mapper = + noSqlDb.getMappingManager().mapper(VersionInfoEntity.class); + private static VersionInfoAccessor accessor = + noSqlDb.getMappingManager().createAccessor(VersionInfoAccessor.class); + //private static UDTMapper versionedEntityIdMapper = noSqlDb + //.getMappingManager().udtMapper(VersionableEntityId.class); + + @Override + protected Mapper getMapper() { + return mapper; + } + + @Override + protected Object[] getKeys(VersionInfoEntity entity) { + return new Object[]{entity.getEntityType(), entity.getEntityId()}; + } + + @Override + public Collection list(VersionInfoEntity entity) { + return accessor.getAll(entity.getEntityType()).all(); + } + + @Accessor + interface VersionInfoAccessor { + @Query("select * from version_info where entity_type=?") + Result getAll(String entityType); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionInfoDeletedDaoFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionInfoDeletedDaoFactoryImpl.java new file mode 100644 index 0000000000..9163018a85 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionInfoDeletedDaoFactoryImpl.java @@ -0,0 +1,34 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.dao.impl; + + +import org.openecomp.sdc.versioning.dao.VersionInfoDeletedDao; +import org.openecomp.sdc.versioning.dao.VersionInfoDeletedDaoFactory; + +public class VersionInfoDeletedDaoFactoryImpl extends VersionInfoDeletedDaoFactory { + private static VersionInfoDeletedDao INSTANCE = new VersionInfoDeletedDaoImpl(); + + @Override + public VersionInfoDeletedDao createInterface() { + return INSTANCE; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionInfoDeletedDaoImpl.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionInfoDeletedDaoImpl.java new file mode 100644 index 0000000000..82e4edcd80 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionInfoDeletedDaoImpl.java @@ -0,0 +1,65 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.dao.impl; + +import com.datastax.driver.mapping.Mapper; +import com.datastax.driver.mapping.Result; +import com.datastax.driver.mapping.annotations.Accessor; +import com.datastax.driver.mapping.annotations.Query; +import org.openecomp.core.dao.impl.CassandraBaseDao; +import org.openecomp.core.nosqldb.api.NoSqlDb; +import org.openecomp.core.nosqldb.factory.NoSqlDbFactory; +import org.openecomp.sdc.versioning.dao.VersionInfoDeletedDao; +import org.openecomp.sdc.versioning.dao.types.VersionInfoDeletedEntity; + +import java.util.Collection; + +public class VersionInfoDeletedDaoImpl extends CassandraBaseDao + implements VersionInfoDeletedDao { + + private static NoSqlDb noSqlDb = NoSqlDbFactory.getInstance().createInterface(); + private static Mapper mapper = + noSqlDb.getMappingManager().mapper(VersionInfoDeletedEntity.class); + private static VersionInfoAccessor accessor = + noSqlDb.getMappingManager().createAccessor(VersionInfoAccessor.class); + + + @Override + protected Mapper getMapper() { + return mapper; + } + + @Override + protected Object[] getKeys(VersionInfoDeletedEntity entity) { + return new Object[]{entity.getEntityType(), entity.getEntityId()}; + } + + @Override + public Collection list(VersionInfoDeletedEntity entity) { + return accessor.getAll(entity.getEntityType()).all(); + } + + @Accessor + interface VersionInfoAccessor { + @Query("select * from version_info_deleted where entity_type=?") + Result getAll(String entityType); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionableEntityDaoCassandraImpl.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionableEntityDaoCassandraImpl.java new file mode 100644 index 0000000000..f02ea89e34 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionableEntityDaoCassandraImpl.java @@ -0,0 +1,159 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.dao.impl; + +import com.datastax.driver.core.ColumnDefinitions; +import com.datastax.driver.core.ResultSet; +import com.datastax.driver.core.Row; +import com.datastax.driver.mapping.UDTMapper; +import org.openecomp.core.nosqldb.api.NoSqlDb; +import org.openecomp.core.nosqldb.factory.NoSqlDbFactory; +import org.openecomp.core.util.UniqueValueUtil; +import org.openecomp.core.utilities.CommonMethods; +import org.openecomp.sdc.versioning.dao.VersionableEntityDao; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.types.UniqueValueMetadata; +import org.openecomp.sdc.versioning.types.VersionableEntityMetadata; + +import org.slf4j.LoggerFactory; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.function.Function; +import java.util.stream.Collectors; + +class VersionableEntityDaoCassandraImpl implements VersionableEntityDao { + + private static final NoSqlDb noSqlDb = NoSqlDbFactory.getInstance().createInterface(); + private static org.slf4j.Logger Logger = + LoggerFactory.getLogger(VersionableEntityDaoCassandraImpl.class); + private static UDTMapper versionMapper = + noSqlDb.getMappingManager().udtMapper(Version.class); + + private static String commaSeparatedQuestionMarks(int size) { + StringBuilder sb = new StringBuilder(size * 2 - 1); + for (int i = 0; i < size; i++) { + if (i > 0) { + sb.append(','); + } + sb.append('?'); + } + return sb.toString(); + + } + + @Override + public void initVersion(VersionableEntityMetadata metadata, String entityId, Version baseVersion, + Version newVersion) { + ResultSet rows = loadVersionRows(metadata, entityId, baseVersion); + List columnNames = + rows.getColumnDefinitions().asList().stream().map(ColumnDefinitions.Definition::getName) + .collect(Collectors.toList()); + + String insertCql = String.format("insert into %s (%s) values (%s)", metadata.getName(), + CommonMethods.listToSeparatedString(columnNames, ','), + commaSeparatedQuestionMarks(columnNames.size())); + Logger.debug("insertCql", insertCql); + + for (Row row : rows) { + List columnValues = new ArrayList<>(); + Map columnNameToValue = new HashMap<>(); + + for (String columnName : columnNames) { + if (metadata.getVersionIdentifierName().equals(columnName)) { + columnValues.add(versionMapper.toUDT(newVersion)); + columnNameToValue.put(columnName, newVersion.toString()); + } else { + Object value = row.getObject(columnName); + columnValues.add(value); + columnNameToValue.put(columnName, value); + } + } + + initRowUniqueValues(metadata.getUniqueValuesMetadata(), columnNameToValue); + + noSqlDb.execute(insertCql, columnValues.toArray()); + } + } + + private ResultSet loadVersionRows(VersionableEntityMetadata metadata, String entityId, + Version version) { + String selectCql = String.format("select * from %s where %s=? and %s=?", metadata.getName(), + metadata.getIdentifierName(), metadata.getVersionIdentifierName()); + Logger.debug("selectCql", selectCql); + Logger.debug("entityId", entityId); + Logger.debug("version", version); + + return noSqlDb.execute(selectCql, entityId, versionMapper.toUDT(version)); + } + + @Override + public void deleteVersion(VersionableEntityMetadata metadata, String entityId, + Version versionToDelete) { + deleteRowsUniqueValues(metadata, entityId, versionToDelete); + + String deleteCql = String.format("delete from %s where %s=? and %s=?", metadata.getName(), + metadata.getIdentifierName(), metadata.getVersionIdentifierName()); + noSqlDb.execute(deleteCql, entityId, versionMapper.toUDT(versionToDelete)); + } + + private void initRowUniqueValues(List metadata, + Map columnNameToValue) { + for (UniqueValueMetadata uniqueMetadata : metadata) { + List uniqueValueCombination = uniqueMetadata.getUniqueConstraintIdentifiers().stream() + .map(colName -> (String) columnNameToValue.get(colName)).collect(Collectors.toList()); + UniqueValueUtil.createUniqueValue(uniqueMetadata.getType(), + uniqueValueCombination.toArray(new String[uniqueValueCombination.size()])); + } + } + + private void deleteRowUniqueValues(List metadata, + Map columnNameToValue) { + for (UniqueValueMetadata uniqueMetadata : metadata) { + List uniqueValueCombination = uniqueMetadata.getUniqueConstraintIdentifiers().stream() + .map(colName -> (String) columnNameToValue.get(colName)).collect(Collectors.toList()); + UniqueValueUtil.deleteUniqueValue(uniqueMetadata.getType(), + uniqueValueCombination.toArray(new String[uniqueValueCombination.size()])); + } + } + + private void deleteRowsUniqueValues(VersionableEntityMetadata metadata, String entityId, + Version version) { + if (metadata.getUniqueValuesMetadata().isEmpty()) { + return; + } + ResultSet rows = loadVersionRows(metadata, entityId, version); + List columnNames = + rows.getColumnDefinitions().asList().stream().map(ColumnDefinitions.Definition::getName) + .collect(Collectors.toList()); + + for (Row row : rows) { + Map columnNameToValue = + columnNames.stream().filter(name -> row.getObject(name) != null).collect(Collectors + .toMap(Function.identity(), + columnName -> metadata.getVersionIdentifierName().equals(columnName) ? version + .toString() : row.getObject(columnName))); + deleteRowUniqueValues(metadata.getUniqueValuesMetadata(), columnNameToValue); + } + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionableEntityDaoFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionableEntityDaoFactoryImpl.java new file mode 100644 index 0000000000..8ec0814fc9 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/dao/impl/VersionableEntityDaoFactoryImpl.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.dao.impl; + +import org.openecomp.sdc.versioning.dao.VersionableEntityDao; +import org.openecomp.sdc.versioning.dao.VersionableEntityDaoFactory; + +public class VersionableEntityDaoFactoryImpl extends VersionableEntityDaoFactory { + private static VersionableEntityDao INSTANCE = new VersionableEntityDaoCassandraImpl(); + + @Override + public VersionableEntityDao createInterface() { + return INSTANCE; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/impl/VersioningManagerFactoryImpl.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/impl/VersioningManagerFactoryImpl.java new file mode 100644 index 0000000000..f7065cfda4 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/impl/VersioningManagerFactoryImpl.java @@ -0,0 +1,33 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.impl; + +import org.openecomp.sdc.versioning.VersioningManager; +import org.openecomp.sdc.versioning.VersioningManagerFactory; + +public class VersioningManagerFactoryImpl extends VersioningManagerFactory { + private static final VersioningManager INSTANCE = new VersioningManagerImpl(); + + @Override + public VersioningManager createInterface() { + return INSTANCE; + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/impl/VersioningManagerImpl.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/impl/VersioningManagerImpl.java new file mode 100644 index 0000000000..6aa2a9f63c --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/main/java/org/openecomp/sdc/versioning/impl/VersioningManagerImpl.java @@ -0,0 +1,468 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.versioning.impl; + +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.versioning.VersioningManager; +import org.openecomp.sdc.versioning.dao.VersionInfoDao; +import org.openecomp.sdc.versioning.dao.VersionInfoDaoFactory; +import org.openecomp.sdc.versioning.dao.VersionInfoDeletedDao; +import org.openecomp.sdc.versioning.dao.VersionInfoDeletedDaoFactory; +import org.openecomp.sdc.versioning.dao.VersionableEntityDao; +import org.openecomp.sdc.versioning.dao.VersionableEntityDaoFactory; +import org.openecomp.sdc.versioning.dao.types.UserCandidateVersion; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.dao.types.VersionHistoryEntity; +import org.openecomp.sdc.versioning.dao.types.VersionInfoDeletedEntity; +import org.openecomp.sdc.versioning.dao.types.VersionInfoEntity; +import org.openecomp.sdc.versioning.dao.types.VersionStatus; +import org.openecomp.sdc.versioning.dao.types.VersionType; +import org.openecomp.sdc.versioning.dao.types.VersionableEntityId; +import org.openecomp.sdc.versioning.errors.CheckinOnEntityLockedByOtherErrorBuilder; +import org.openecomp.sdc.versioning.errors.CheckinOnUnlockedEntityErrorBuilder; +import org.openecomp.sdc.versioning.errors.CheckoutOnLockedEntityErrorBuilder; +import org.openecomp.sdc.versioning.errors.DeleteOnLockedEntityErrorBuilder; +import org.openecomp.sdc.versioning.errors.EditOnEntityLockedByOtherErrorBuilder; +import org.openecomp.sdc.versioning.errors.EditOnUnlockedEntityErrorBuilder; +import org.openecomp.sdc.versioning.errors.EntityAlreadyExistErrorBuilder; +import org.openecomp.sdc.versioning.errors.EntityAlreadyFinalizedErrorBuilder; +import org.openecomp.sdc.versioning.errors.EntityNotExistErrorBuilder; +import org.openecomp.sdc.versioning.errors.SubmitLockedEntityNotAllowedErrorBuilder; +import org.openecomp.sdc.versioning.errors.UndoCheckoutOnEntityLockedByOtherErrorBuilder; +import org.openecomp.sdc.versioning.errors.UndoCheckoutOnUnlockedEntityErrorBuilder; +import org.openecomp.sdc.versioning.types.VersionInfo; +import org.openecomp.sdc.versioning.types.VersionableEntityAction; +import org.openecomp.sdc.versioning.types.VersionableEntityMetadata; + +import java.util.Collection; +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Set; +import java.util.stream.Collectors; + +public class VersioningManagerImpl implements VersioningManager { + + private static final Version INITIAL_ACTIVE_VERSION = new Version(0, 0); + private static VersionInfoDao versionInfoDao = + VersionInfoDaoFactory.getInstance().createInterface(); + private static VersionInfoDeletedDao versionInfoDeletedDao = + VersionInfoDeletedDaoFactory.getInstance().createInterface(); + private static VersionableEntityDao versionableEntityDao = + VersionableEntityDaoFactory.getInstance().createInterface(); + + private static Map> versionableEntities = new HashMap<>(); + + private static VersionInfo getVersionInfo(VersionInfoEntity versionInfoEntity, String user, + VersionableEntityAction action) { + return getVersionInfo(versionInfoEntity.getEntityId(), + versionInfoEntity.getEntityType(), + versionInfoEntity.getActiveVersion(), + versionInfoEntity.getCandidate(), + versionInfoEntity.getStatus(), + versionInfoEntity.getLatestFinalVersion(), + versionInfoEntity.getViewableVersions(), + action, + user); + } + + private static VersionInfo getVersionInfo(VersionInfoDeletedEntity versionInfoEntity, String user, + VersionableEntityAction action) { + return getVersionInfo(versionInfoEntity.getEntityId(), + versionInfoEntity.getEntityType(), + versionInfoEntity.getActiveVersion(), + versionInfoEntity.getCandidate(), + versionInfoEntity.getStatus(), + versionInfoEntity.getLatestFinalVersion(), + versionInfoEntity.getViewableVersions(), + action, + user); + } + + private static VersionInfo getVersionInfo(String entityId, String entityType, Version activeVer, + UserCandidateVersion candidate, VersionStatus status, + Version latestFinalVersion, + Set viewableVersions, + VersionableEntityAction action, String user) { + Version activeVersion; + + if (action == VersionableEntityAction.Write) { + if (candidate != null) { + if (user.equals(candidate.getUser())) { + activeVersion = candidate.getVersion(); + } else { + throw new CoreException( + new EditOnEntityLockedByOtherErrorBuilder(entityType, entityId, candidate.getUser()) + .build()); + } + } else { + throw new CoreException(new EditOnUnlockedEntityErrorBuilder(entityType, entityId).build()); + } + } else { + if (candidate != null && user.equals(candidate.getUser())) { + activeVersion = candidate.getVersion(); + } else { + activeVersion = activeVer; + } + } + + VersionInfo versionInfo = new VersionInfo(); + versionInfo.setActiveVersion(activeVersion); + versionInfo.setLatestFinalVersion(latestFinalVersion); + versionInfo.setViewableVersions(toSortedList(viewableVersions)); + versionInfo.setFinalVersions(getFinalVersions(viewableVersions)); + versionInfo.setStatus(status); + if (candidate != null) { + versionInfo.setLockingUser(candidate.getUser()); + if (user.equals(candidate.getUser())) { + versionInfo.getViewableVersions().add(candidate.getVersion()); + } + } + return versionInfo; + } + + private static List toSortedList( + Set versions) { // changing the Set to List in DB will require migration... + return versions.stream().sorted((o1, o2) -> { + return o1.getMajor() > o2.getMajor() ? 1 + : o1.getMajor() == o2.getMajor() ? (o1.getMinor() > o2.getMinor() ? 1 + : o1.getMinor() == o2.getMinor() ? 0 : -1) : -1; + }).collect(Collectors.toList()); + } + + private static List getFinalVersions(Set versions) { + return versions.stream().filter(version -> version.isFinal()).collect(Collectors.toList()); + } + + @Override + public void register(String entityType, VersionableEntityMetadata entityMetadata) { + Set entitiesMetadata = versionableEntities.get(entityType); + if (entitiesMetadata == null) { + entitiesMetadata = new HashSet<>(); + versionableEntities.put(entityType, entitiesMetadata); + } + entitiesMetadata.add(entityMetadata); + } + + @Override + public Version create(String entityType, String entityId, String user) { + VersionInfoEntity versionInfoEntity = + versionInfoDao.get(new VersionInfoEntity(entityType, entityId)); + if (versionInfoEntity != null) { + throw new CoreException(new EntityAlreadyExistErrorBuilder(entityType, entityId).build()); + } + + versionInfoEntity = new VersionInfoEntity(entityType, entityId); + versionInfoEntity.setActiveVersion(INITIAL_ACTIVE_VERSION); + markAsCheckedOut(versionInfoEntity, user); + versionInfoDao.create(versionInfoEntity); + + return versionInfoEntity.getCandidate().getVersion(); + } + + @Override + public Version checkout(String entityType, String entityId, String user) { + VersionInfoEntity versionInfoEntity = + versionInfoDao.get(new VersionInfoEntity(entityType, entityId)); + if (versionInfoEntity == null) { + throw new CoreException(new EntityNotExistErrorBuilder(entityType, entityId).build()); + } + + Version checkoutVersion = null; + switch (versionInfoEntity.getStatus()) { + case Locked: + throw new CoreException(new CheckoutOnLockedEntityErrorBuilder(entityType, entityId, + versionInfoEntity.getCandidate().getUser()).build()); + case Final: + case Available: + checkoutVersion = doCheckout(versionInfoEntity, user); + break; + default: + } + return checkoutVersion; + } + + @Override + public Version undoCheckout(String entityType, String entityId, String user) { + VersionInfoEntity versionInfoEntity = + versionInfoDao.get(new VersionInfoEntity(entityType, entityId)); + if (versionInfoEntity == null) { + throw new CoreException(new EntityNotExistErrorBuilder(entityType, entityId).build()); + } + + Version activeVersion = null; + switch (versionInfoEntity.getStatus()) { + case Locked: + if (!user.equals(versionInfoEntity.getCandidate().getUser())) { + throw new CoreException( + new UndoCheckoutOnEntityLockedByOtherErrorBuilder(entityType, entityId, + versionInfoEntity.getCandidate().getUser()).build()); + } + activeVersion = undoCheckout(versionInfoEntity); + break; + case Final: + case Available: + throw new CoreException( + new UndoCheckoutOnUnlockedEntityErrorBuilder(entityType, entityId).build()); + default: + } + return activeVersion; + } + + private Version undoCheckout(VersionInfoEntity versionInfoEntity) { + deleteVersionFromEntity(versionInfoEntity.getEntityType(), versionInfoEntity.getEntityId(), + versionInfoEntity.getCandidate().getVersion()); + + versionInfoEntity.setStatus(versionInfoEntity.getActiveVersion().isFinal() ? VersionStatus.Final + : VersionStatus.Available); + versionInfoEntity.setCandidate(null); + versionInfoDao.update(versionInfoEntity); + return versionInfoEntity.getActiveVersion(); + } + + @Override + public Version checkin(String entityType, String entityId, String user, + String checkinDescription) { + VersionInfoEntity versionInfoEntity = + versionInfoDao.get(new VersionInfoEntity(entityType, entityId)); + if (versionInfoEntity == null) { + throw new CoreException(new EntityNotExistErrorBuilder(entityType, entityId).build()); + } + + Version checkedInVersion = null; + switch (versionInfoEntity.getStatus()) { + case Available: + case Final: + throw new CoreException( + new CheckinOnUnlockedEntityErrorBuilder(entityType, entityId).build()); + case Locked: + if (!user.equals(versionInfoEntity.getCandidate().getUser())) { + throw new CoreException(new CheckinOnEntityLockedByOtherErrorBuilder(entityType, entityId, + versionInfoEntity.getCandidate().getUser()).build()); + } + checkedInVersion = doCheckin(versionInfoEntity, checkinDescription); + break; + default: + } + return checkedInVersion; + } + + @Override + public Version submit(String entityType, String entityId, String user, String submitDescription) { + VersionInfoEntity versionInfoEntity = + versionInfoDao.get(new VersionInfoEntity(entityType, entityId)); + if (versionInfoEntity == null) { + throw new CoreException(new EntityNotExistErrorBuilder(entityType, entityId).build()); + } + + Version submitVersion = null; + switch (versionInfoEntity.getStatus()) { + case Final: + throw new CoreException( + new EntityAlreadyFinalizedErrorBuilder(entityType, entityId).build()); + case Locked: + throw new CoreException(new SubmitLockedEntityNotAllowedErrorBuilder(entityType, entityId, + versionInfoEntity.getCandidate().getUser()).build()); + case Available: + submitVersion = doSubmit(versionInfoEntity, user, submitDescription); + break; + default: + } + return submitVersion; + } + + @Override + public VersionInfo getEntityVersionInfo(String entityType, String entityId, String user, + VersionableEntityAction action) { + VersionInfoEntity versionInfoEntity = + versionInfoDao.get(new VersionInfoEntity(entityType, entityId)); + if (versionInfoEntity == null) { + throw new CoreException(new EntityNotExistErrorBuilder(entityType, entityId).build()); + } + return getVersionInfo(versionInfoEntity, user, action); + } + + @Override + public Map listEntitiesVersionInfo(String entityType, String user, + VersionableEntityAction action) { + Collection versionInfoEntities = + versionInfoDao.list(new VersionInfoEntity(entityType, null)); + Map activeVersions = new HashMap<>(); + for (VersionInfoEntity versionInfoEntity : versionInfoEntities) { + activeVersions + .put(versionInfoEntity.getEntityId(), getVersionInfo(versionInfoEntity, user, action)); + } + return activeVersions; + } + + @Override + public Map listDeletedEntitiesVersionInfo(String entityType, String user, + VersionableEntityAction action) { + Collection versionInfoDeletedEntities = + versionInfoDeletedDao.list(new VersionInfoDeletedEntity(entityType, null)); + Map activeVersions = new HashMap<>(); + + + for (VersionInfoDeletedEntity versionInfoDeletedEntity : versionInfoDeletedEntities) { + activeVersions.put(versionInfoDeletedEntity.getEntityId(), + getVersionInfo(versionInfoDeletedEntity, user, action)); + } + return activeVersions; + } + + @Override + public void delete(String entityType, String entityId, String user) { + VersionInfoEntity versionInfoEntity = + versionInfoDao.get(new VersionInfoEntity(entityType, entityId)); + if (versionInfoEntity == null) { + throw new CoreException(new EntityNotExistErrorBuilder(entityType, entityId).build()); + } + + switch (versionInfoEntity.getStatus()) { + case Locked: + throw new CoreException(new DeleteOnLockedEntityErrorBuilder(entityType, entityId, + versionInfoEntity.getCandidate().getUser()).build()); + default: + } + + doDelete(versionInfoEntity, user); + } + + @Override + public void undoDelete(String entityType, String entityId, String user) { + VersionInfoDeletedEntity versionInfoDeletedEntity = + versionInfoDeletedDao.get(new VersionInfoDeletedEntity(entityType, entityId)); + if (versionInfoDeletedEntity == null) { + throw new CoreException(new EntityNotExistErrorBuilder(entityType, entityId).build()); + } + + doUndoDelete(versionInfoDeletedEntity, user); + } + + private void markAsCheckedOut(VersionInfoEntity versionInfoEntity, String checkingOutUser) { + versionInfoEntity.setStatus(VersionStatus.Locked); + versionInfoEntity.setCandidate(new UserCandidateVersion(checkingOutUser, + versionInfoEntity.getActiveVersion().calculateNextCandidate())); + } + + private Version doCheckout(VersionInfoEntity versionInfoEntity, String user) { + markAsCheckedOut(versionInfoEntity, user); + versionInfoDao.update(versionInfoEntity); + + initVersionOnEntity(versionInfoEntity.getEntityType(), versionInfoEntity.getEntityId(), + versionInfoEntity.getActiveVersion(), versionInfoEntity.getCandidate().getVersion()); + + return versionInfoEntity.getCandidate().getVersion(); + } + + private void doDelete(VersionInfoEntity versionInfoEntity, String user) { + + VersionInfoDeletedEntity versionInfoDeletedEntity = new VersionInfoDeletedEntity(); + versionInfoDeletedEntity.setStatus(versionInfoEntity.getStatus()); + versionInfoDeletedEntity.setViewableVersions(versionInfoEntity.getViewableVersions()); + versionInfoDeletedEntity.setActiveVersion(versionInfoEntity.getActiveVersion()); + versionInfoDeletedEntity.setCandidate(versionInfoEntity.getCandidate()); + versionInfoDeletedEntity.setEntityId(versionInfoEntity.getEntityId()); + versionInfoDeletedEntity.setEntityType(versionInfoEntity.getEntityType()); + versionInfoDeletedEntity.setLatestFinalVersion(versionInfoEntity.getLatestFinalVersion()); + versionInfoDeletedDao.create(versionInfoDeletedEntity); + versionInfoDao.delete(versionInfoEntity); + + } + + private void doUndoDelete(VersionInfoDeletedEntity versionInfoDeletedEntity, String user) { + + VersionInfoEntity versionInfoEntity = new VersionInfoEntity(); + versionInfoEntity.setStatus(versionInfoDeletedEntity.getStatus()); + versionInfoEntity.setViewableVersions(versionInfoDeletedEntity.getViewableVersions()); + versionInfoEntity.setActiveVersion(versionInfoDeletedEntity.getActiveVersion()); + versionInfoEntity.setCandidate(versionInfoDeletedEntity.getCandidate()); + versionInfoEntity.setEntityId(versionInfoDeletedEntity.getEntityId()); + versionInfoEntity.setEntityType(versionInfoDeletedEntity.getEntityType()); + versionInfoEntity.setLatestFinalVersion(versionInfoDeletedEntity.getLatestFinalVersion()); + versionInfoDao.create(versionInfoEntity); + versionInfoDeletedDao.delete(versionInfoDeletedEntity); + + } + + private Version doCheckin(VersionInfoEntity versionInfoEntity, String checkinDescription) { + UserCandidateVersion userCandidateVersion = versionInfoEntity.getCandidate(); + versionInfoEntity.setCandidate(null); + versionInfoEntity.setActiveVersion(userCandidateVersion.getVersion()); + versionInfoEntity.getViewableVersions().add(versionInfoEntity.getActiveVersion()); + versionInfoEntity.setStatus(VersionStatus.Available); + versionInfoDao.update(versionInfoEntity); + + return versionInfoEntity.getActiveVersion(); + } + + private Version doSubmit(VersionInfoEntity versionInfoEntity, String submittingUser, + String submitDescription) { + Version finalVersion = versionInfoEntity.getActiveVersion().calculateNextFinal(); + initVersionOnEntity(versionInfoEntity.getEntityType(), versionInfoEntity.getEntityId(), + versionInfoEntity.getActiveVersion(), finalVersion); + + Set viewableVersions = new HashSet<>(); + for (Version version : versionInfoEntity.getViewableVersions()) { + if (version.isFinal()) { + viewableVersions.add(version); + } + } + viewableVersions.add(finalVersion); + versionInfoEntity.setViewableVersions(viewableVersions); + versionInfoEntity.setActiveVersion(finalVersion); + versionInfoEntity.setLatestFinalVersion(finalVersion); + versionInfoEntity.setStatus(VersionStatus.Final); + versionInfoDao.update(versionInfoEntity); + + return finalVersion; + } + + private void createVersionHistory(VersionableEntityId entityId, Version version, String user, + String description, VersionType type) { + VersionHistoryEntity versionHistory = new VersionHistoryEntity(entityId); + versionHistory.setVersion(version); + versionHistory.setUser(user); + versionHistory.setDescription(description); + versionHistory.setType(type); + } + + private void initVersionOnEntity(String entityType, String entityId, Version baseVersion, + Version newVersion) { + Set entityMetadatas = versionableEntities.get(entityType); + if (entityMetadatas != null) { + for (VersionableEntityMetadata entityMetadata : entityMetadatas) { + versionableEntityDao.initVersion(entityMetadata, entityId, baseVersion, newVersion); + } + } + } + + private void deleteVersionFromEntity(String entityType, String entityId, + Version versionToDelete) { + Set entityMetadatas = versionableEntities.get(entityType); + if (entityMetadatas != null) { + for (VersionableEntityMetadata entityMetadata : entityMetadatas) { + versionableEntityDao.deleteVersion(entityMetadata, entityId, versionToDelete); + } + } + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/test/java/org/openecomp/sdc/versioning/VersioningManagerTest.java b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/test/java/org/openecomp/sdc/versioning/VersioningManagerTest.java new file mode 100644 index 0000000000..3695f9ef2d --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/openecomp-sdc-versioning-core/src/test/java/org/openecomp/sdc/versioning/VersioningManagerTest.java @@ -0,0 +1,364 @@ +package org.openecomp.sdc.versioning; + + +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.versioning.dao.VersionInfoDao; +import org.openecomp.sdc.versioning.dao.VersionInfoDaoFactory; +import org.openecomp.sdc.versioning.dao.VersionInfoDeletedDao; +import org.openecomp.sdc.versioning.dao.VersionInfoDeletedDaoFactory; +import org.openecomp.sdc.versioning.dao.types.Version; +import org.openecomp.sdc.versioning.dao.types.VersionInfoDeletedEntity; +import org.openecomp.sdc.versioning.dao.types.VersionInfoEntity; +import org.openecomp.sdc.versioning.dao.types.VersionStatus; +import org.openecomp.sdc.versioning.types.VersionInfo; +import org.openecomp.sdc.versioning.types.VersionableEntityAction; +import org.openecomp.sdc.versioning.types.VersionableEntityMetadata; +import org.openecomp.core.nosqldb.api.NoSqlDb; +import org.openecomp.core.nosqldb.factory.NoSqlDbFactory; +import com.datastax.driver.core.ResultSet; +import com.datastax.driver.mapping.UDTMapper; + +import org.testng.Assert; +import org.testng.annotations.BeforeClass; +import org.testng.annotations.Test; + +import java.util.HashSet; +import java.util.Map; +import java.util.Set; + +public class VersioningManagerTest { + private static final VersioningManager versioningManager = + VersioningManagerFactory.getInstance().createInterface(); + private static final VersionInfoDao versionInfoDao = + VersionInfoDaoFactory.getInstance().createInterface(); + private static final VersionInfoDeletedDao versionInfoDeletedDao = + VersionInfoDeletedDaoFactory.getInstance().createInterface(); + private static final NoSqlDb noSqlDb = NoSqlDbFactory.getInstance().createInterface(); + private static final String USR1 = "usr1"; + private static final String USR2 = "usr2"; + private static final String USR3 = "usr3"; + private static final String TYPE1 = "Type1"; + private static final String TYPE2 = "Type2"; + private static final String ID1 = "Id1"; + private static final String ID2 = "Id2"; + private static final String ID3 = "Id3"; + private static final String TYPE1_TABLE_NAME = "vendor_license_model"; + private static final String TYPE1_ID_NAME = "vlm_id"; + private static final String TYPE1_VERSION_NAME = "version"; + private static final String TYPE2_TABLE_NAME = "feature_group"; + private static final String TYPE2_ID_NAME = "vlm_id"; + private static final String TYPE2_VERSION_NAME = "version"; + private static final Version VERSION01 = new Version(0, 1); + private static final Version VERSION02 = new Version(0, 2); + private static final Version VERSION10 = new Version(1, 0); + private static final Version VERSION11 = new Version(1, 1); + private static UDTMapper versionMapper = + noSqlDb.getMappingManager().udtMapper(Version.class); + private static Set expectedViewableVersionsType1Id1 = new HashSet<>(); + + private static void assretVersionInfoEntity(VersionInfoEntity actual, String entityType, + String entityId, Version activeVersion, + Version candidateVersion, String candidateUser, + VersionStatus status, Set viewbleVersions, + Version latestFinalVersion) { + Assert.assertNotNull(actual); + Assert.assertEquals(actual.getEntityType(), entityType); + Assert.assertEquals(actual.getEntityId(), entityId); + Assert.assertEquals(actual.getActiveVersion(), activeVersion); + if (candidateVersion != null && candidateUser != null) { + Assert.assertEquals(actual.getCandidate().getVersion(), candidateVersion); + Assert.assertEquals(actual.getCandidate().getUser(), candidateUser); + } else { + Assert.assertNull(actual.getCandidate()); + } + Assert.assertEquals(actual.getStatus(), status); + Assert.assertEquals(actual.getViewableVersions().size(), viewbleVersions.size()); + Assert.assertEquals(actual.getViewableVersions(), viewbleVersions); + Assert.assertEquals(actual.getLatestFinalVersion(), latestFinalVersion); + } + + private static void assretVersionInfo(VersionInfo actual, Version activeVersion, + VersionStatus status, String lockingUser, + Set viewableVersions, Version latestFinalVersion) { + Assert.assertNotNull(actual); + Assert.assertEquals(actual.getActiveVersion(), activeVersion); + Assert.assertEquals(actual.getStatus(), status); + Assert.assertEquals(actual.getLockingUser(), lockingUser); + Assert.assertEquals(actual.getViewableVersions().size(), viewableVersions.size()); + Assert.assertEquals(actual.getViewableVersions(), viewableVersions); + Assert.assertEquals(actual.getLatestFinalVersion(), latestFinalVersion); + } + +// @BeforeClass + private void init() { + versionInfoDao.delete(new VersionInfoEntity(TYPE1, ID1)); + versionInfoDao.delete(new VersionInfoEntity(TYPE1, ID2)); + versionInfoDao.delete(new VersionInfoEntity(TYPE2, ID3)); + String deleteFromType1 = String + .format("delete from %s where %s=? and %s=?", TYPE1_TABLE_NAME, TYPE1_ID_NAME, + TYPE1_VERSION_NAME); + noSqlDb.execute(deleteFromType1, ID1, versionMapper.toUDT(VERSION01)); + noSqlDb.execute(deleteFromType1, ID1, versionMapper.toUDT(VERSION02)); + noSqlDb.execute(deleteFromType1, ID1, versionMapper.toUDT(VERSION11)); + + versioningManager.register(TYPE1, + new VersionableEntityMetadata(TYPE1_TABLE_NAME, TYPE1_ID_NAME, TYPE1_VERSION_NAME)); + versioningManager.register(TYPE2, + new VersionableEntityMetadata(TYPE2_TABLE_NAME, TYPE2_ID_NAME, TYPE2_VERSION_NAME)); + } + +// @Test + public void createTest() { + Version version = versioningManager.create(TYPE1, ID1, USR1); + createVersionableEntityRecord(TYPE1_TABLE_NAME, TYPE1_ID_NAME, TYPE1_VERSION_NAME, ID1, + version); + + VersionInfoEntity versionInfoEntity = versionInfoDao.get(new VersionInfoEntity(TYPE1, ID1)); + assretVersionInfoEntity(versionInfoEntity, TYPE1, ID1, new Version(0, 0), VERSION01, USR1, + VersionStatus.Locked, expectedViewableVersionsType1Id1, null); + } + +// @Test(dependsOnMethods = "createTest") + public void checkinTest() { + Version version = versioningManager.checkin(TYPE1, ID1, USR1, "checkin 0.1"); + Assert.assertEquals(version, VERSION01); + + VersionInfoEntity versionInfoEntity = versionInfoDao.get(new VersionInfoEntity(TYPE1, ID1)); + expectedViewableVersionsType1Id1.add(VERSION01); + assretVersionInfoEntity(versionInfoEntity, TYPE1, ID1, VERSION01, null, null, + VersionStatus.Available, expectedViewableVersionsType1Id1, null); + } + +// @Test(dependsOnMethods = "checkinTest") + public void getVersionInfoForReadOnAvailableTest() { + VersionInfo versionInfo = + versioningManager.getEntityVersionInfo(TYPE1, ID1, USR2, VersionableEntityAction.Read); + assretVersionInfo(versionInfo, VERSION01, VersionStatus.Available, null, + expectedViewableVersionsType1Id1, null); + } + +// @Test(dependsOnMethods = "getVersionInfoForReadOnAvailableTest", +// expectedExceptions = CoreException.class) + public void getVersionInfoForWriteOnAvailableTest() { + versioningManager.getEntityVersionInfo(TYPE1, ID1, USR2, VersionableEntityAction.Write); + } + +// @Test(dependsOnMethods = "getVersionInfoForWriteOnAvailableTest", +// expectedExceptions = CoreException.class) + public void checkinOnAvailableTest() { + versioningManager.checkin(TYPE1, ID1, USR1, "fail checkin"); + } + +// @Test(dependsOnMethods = "checkinOnAvailableTest", expectedExceptions = CoreException.class) + public void undoCheckoutOnAvailableTest() { + versioningManager.undoCheckout(TYPE1, ID1, USR1); + } + +// @Test(dependsOnMethods = "undoCheckoutOnAvailableTest") + public void checkoutTest() { + Version version = versioningManager.checkout(TYPE1, ID1, USR2); + Assert.assertEquals(version, VERSION02); + + VersionInfoEntity versionInfoEntity = versionInfoDao.get(new VersionInfoEntity(TYPE1, ID1)); + assretVersionInfoEntity(versionInfoEntity, TYPE1, ID1, VERSION01, VERSION02, USR2, + VersionStatus.Locked, expectedViewableVersionsType1Id1, null); + + ResultSet results = + loadVersionableEntityRecord(TYPE1_TABLE_NAME, TYPE1_ID_NAME, TYPE1_VERSION_NAME, ID1, + VERSION02); + Assert.assertTrue(results.iterator().hasNext()); + } + +// @Test(dependsOnMethods = "checkoutTest") + public void getVersionInfoForReadOnLockedSameUserTest() { + VersionInfo versionInfo = + versioningManager.getEntityVersionInfo(TYPE1, ID1, USR2, VersionableEntityAction.Read); + Set expectedViewableVersions = new HashSet<>(); + expectedViewableVersions.addAll(expectedViewableVersionsType1Id1); + expectedViewableVersions.add(VERSION02); + assretVersionInfo(versionInfo, VERSION02, VersionStatus.Locked, USR2, expectedViewableVersions, + null); + } + +// @Test(dependsOnMethods = "getVersionInfoForReadOnLockedSameUserTest") + public void getVersionInfoForReadOnLockedOtherUserTest() { + VersionInfo entityVersionInfo = + versioningManager.getEntityVersionInfo(TYPE1, ID1, USR1, VersionableEntityAction.Read); + Assert.assertEquals(entityVersionInfo.getActiveVersion(), VERSION01); + } + +// @Test(dependsOnMethods = "getVersionInfoForReadOnLockedOtherUserTest", +// expectedExceptions = CoreException.class) + public void getVersionInfoForWriteOnLockedOtherUserTest() { + versioningManager.getEntityVersionInfo(TYPE1, ID1, USR1, VersionableEntityAction.Write) + .getActiveVersion(); + } + +// @Test(dependsOnMethods = "getVersionInfoForWriteOnLockedOtherUserTest") + public void getVersionInfoForWriteOnLockedSameUserTest() { + Version activeVersion = + versioningManager.getEntityVersionInfo(TYPE1, ID1, USR2, VersionableEntityAction.Write) + .getActiveVersion(); + Assert.assertEquals(activeVersion, VERSION02); + } + +// @Test(dependsOnMethods = "getVersionInfoForWriteOnLockedSameUserTest", +// expectedExceptions = CoreException.class) + public void checkoutOnLockedSameUserTest() { + versioningManager.checkout(TYPE1, ID1, USR2); + } + +// @Test(dependsOnMethods = "checkoutOnLockedSameUserTest", expectedExceptions = CoreException.class) + public void checkoutOnLockedOtherUserTest() { + versioningManager.checkout(TYPE1, ID1, USR1); + } + +// @Test(dependsOnMethods = "checkoutOnLockedSameUserTest", expectedExceptions = CoreException.class) + public void undoCheckoutOnLockedOtherUserTest() { + versioningManager.undoCheckout(TYPE1, ID1, USR1); + } + +// @Test(dependsOnMethods = "undoCheckoutOnLockedOtherUserTest", +// expectedExceptions = CoreException.class) + public void submitOnLockedTest() { + versioningManager.submit(TYPE1, ID1, USR2, "failed submit"); + } + +// @Test(dependsOnMethods = "submitOnLockedTest") + public void undoCheckoutTest() { + Version version = versioningManager.undoCheckout(TYPE1, ID1, USR2); + Assert.assertEquals(version, VERSION01); + + VersionInfoEntity versionInfoEntity = versionInfoDao.get(new VersionInfoEntity(TYPE1, ID1)); + assretVersionInfoEntity(versionInfoEntity, TYPE1, ID1, VERSION01, null, null, + VersionStatus.Available, expectedViewableVersionsType1Id1, null); + + ResultSet results = + loadVersionableEntityRecord(TYPE1_TABLE_NAME, TYPE1_ID_NAME, TYPE1_VERSION_NAME, ID1, + VERSION02); + Assert.assertFalse(results.iterator().hasNext()); + } + +// @Test(dependsOnMethods = "undoCheckoutTest") + public void submitTest() { + Version version = versioningManager.submit(TYPE1, ID1, USR3, "submit msg"); + Assert.assertEquals(version, VERSION10); + expectedViewableVersionsType1Id1 = new HashSet<>(); + expectedViewableVersionsType1Id1.add(version); + + VersionInfoEntity versionInfoEntity = versionInfoDao.get(new VersionInfoEntity(TYPE1, ID1)); + assretVersionInfoEntity(versionInfoEntity, TYPE1, ID1, VERSION10, null, null, + VersionStatus.Final, expectedViewableVersionsType1Id1, VERSION10); + + ResultSet results = + loadVersionableEntityRecord(TYPE1_TABLE_NAME, TYPE1_ID_NAME, TYPE1_VERSION_NAME, ID1, + VERSION10); + Assert.assertTrue(results.iterator().hasNext()); + } + +// @Test(dependsOnMethods = "submitTest", expectedExceptions = CoreException.class) + public void checkinOnFinalizedTest() { + versioningManager.checkin(TYPE1, ID1, USR2, "failed checkin"); + } + +// @Test(dependsOnMethods = "checkinOnFinalizedTest", expectedExceptions = CoreException.class) + public void undoCheckouOnFinalizedTest() { + versioningManager.undoCheckout(TYPE1, ID1, USR2); + } + +// @Test(dependsOnMethods = "undoCheckouOnFinalizedTest", expectedExceptions = CoreException.class) + public void submitOnFinalizedTest() { + versioningManager.submit(TYPE1, ID1, USR2, "failed submit"); + } + +// @Test(dependsOnMethods = "submitOnFinalizedTest") + public void checkoutOnFinalizedTest() { + Version version = versioningManager.checkout(TYPE1, ID1, USR3); + Assert.assertEquals(version, VERSION11); + + VersionInfoEntity versionInfoEntity = versionInfoDao.get(new VersionInfoEntity(TYPE1, ID1)); + assretVersionInfoEntity(versionInfoEntity, TYPE1, ID1, VERSION10, VERSION11, USR3, + VersionStatus.Locked, expectedViewableVersionsType1Id1, VERSION10); + + ResultSet results = + loadVersionableEntityRecord(TYPE1_TABLE_NAME, TYPE1_ID_NAME, TYPE1_VERSION_NAME, ID1, + VERSION11); + Assert.assertTrue(results.iterator().hasNext()); + } + +// @Test(dependsOnMethods = "checkoutOnFinalizedTest") + public void viewableVersionsTest() { + versioningManager.checkin(TYPE1, ID1, USR3, "check in 1.1"); + versioningManager.checkout(TYPE1, ID1, USR3); + versioningManager.checkin(TYPE1, ID1, USR3, "check in 1.2"); + versioningManager.submit(TYPE1, ID1, USR3, "submit in 2.0"); + versioningManager.checkout(TYPE1, ID1, USR3); + versioningManager.checkin(TYPE1, ID1, USR3, "check in 2.1"); + versioningManager.submit(TYPE1, ID1, USR3, "submit in 3.0"); + versioningManager.checkout(TYPE1, ID1, USR3); + versioningManager.checkin(TYPE1, ID1, USR3, "check in 3.1"); + versioningManager.checkout(TYPE1, ID1, USR3); + versioningManager.checkin(TYPE1, ID1, USR3, "check in 3.2"); + versioningManager.checkout(TYPE1, ID1, USR2); + + VersionInfoEntity versionInfoEntity = versionInfoDao.get(new VersionInfoEntity(TYPE1, ID1)); + HashSet expectedViewableVersions = new HashSet<>(); + expectedViewableVersions.add(VERSION10); + expectedViewableVersions.add(new Version(2, 0)); + expectedViewableVersions.add(new Version(3, 0)); + expectedViewableVersions.add(new Version(3, 1)); + expectedViewableVersions.add(new Version(3, 2)); + assretVersionInfoEntity(versionInfoEntity, TYPE1, ID1, new Version(3, 2), new Version(3, 3), + USR2, VersionStatus.Locked, expectedViewableVersions, new Version(3, 0)); + } + +// @Test(dependsOnMethods = "viewableVersionsTest") + public void listActiveVersionsTest() { + versioningManager.create(TYPE1, ID2, USR3); + versioningManager.checkin(TYPE1, ID2, USR3, "check in 0.1"); + + versioningManager.create(TYPE2, ID3, USR3); + versioningManager.checkin(TYPE2, ID3, USR3, "check in 0.1"); + + Map idToVersionInfo = + versioningManager.listEntitiesVersionInfo(TYPE1, USR2, VersionableEntityAction.Read); + Assert.assertEquals(idToVersionInfo.size(), 2); + Assert.assertEquals(idToVersionInfo.get(ID1).getActiveVersion(), new Version(3, 3)); + Assert.assertEquals(idToVersionInfo.get(ID2).getActiveVersion(), VERSION01); + } + +// @Test(dependsOnMethods = "listActiveVersionsTest") + public void deleteTest() { + versioningManager.checkin(TYPE1, ID1, USR2, "check in for delete"); + versioningManager.delete(TYPE1, ID1, USR1); + + VersionInfoDeletedEntity versionInfoDeletedEntity = + versionInfoDeletedDao.get(new VersionInfoDeletedEntity(TYPE1, ID1)); + Assert.assertNotNull(versionInfoDeletedEntity); + + Map entitiesInfoMap = + versioningManager.listDeletedEntitiesVersionInfo(TYPE1, USR2, null); + Assert.assertEquals(entitiesInfoMap.size(), 1); + VersionInfoEntity versionInfoEntity = versionInfoDao.get(new VersionInfoEntity(TYPE1, ID1)); + Assert.assertNull(versionInfoEntity); + versioningManager.undoDelete(TYPE1, ID1, USR1); + versionInfoEntity = versionInfoDao.get(new VersionInfoEntity(TYPE1, ID1)); + Assert.assertNotNull(versionInfoEntity); + + + } + + private void createVersionableEntityRecord(String tableName, String idName, String versionName, + String id, Version version) { + noSqlDb.execute( + String.format("insert into %s (%s,%s) values (?,?)", tableName, idName, versionName), id, + versionMapper.toUDT(version)); + } + + private ResultSet loadVersionableEntityRecord(String tableName, String idName, String versionName, + String id, Version version) { + return noSqlDb.execute( + String.format("select * from %s where %s=? and %s=?", tableName, idName, versionName), id, + versionMapper.toUDT(version)); + } +} diff --git a/openecomp-be/lib/openecomp-sdc-versioning-lib/pom.xml b/openecomp-be/lib/openecomp-sdc-versioning-lib/pom.xml new file mode 100644 index 0000000000..b94d9a1cac --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-versioning-lib/pom.xml @@ -0,0 +1,23 @@ + + 4.0.0 + + + openecomp-sdc-lib + org.openecomp.sdc + 1.0.0-SNAPSHOT + + + openecomp-sdc-versioning-lib + pom + openecomp-sdc-versioning-lib + + + openecomp-sdc-versioning-api + openecomp-sdc-versioning-core + + + + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-tosca-lib/pom.xml b/openecomp-be/lib/openecomp-tosca-lib/pom.xml new file mode 100644 index 0000000000..eb67349896 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/pom.xml @@ -0,0 +1,66 @@ + + 4.0.0 + + + + + openecomp-sdc-lib + org.openecomp.sdc + 1.0.0-SNAPSHOT + + + org.openecomp.core + openecomp-tosca-lib + openecomp-tosca-lib + + + + + org.openecomp.core + openecomp-utilities-lib + ${project.version} + + + org.openecomp.sdc + openecomp-sdc-datatypes-lib + ${project.version} + + + org.openecomp.core + openecomp-common-lib + ${project.version} + + + ch.qos.logback + logback-classic + 1.1.2 + + + junit + junit + RELEASE + test + + + org.mockito + mockito-all + 1.10.19 + test + + + com.google.guava + guava + 19.0 + + + org.yaml + snakeyaml + + + + + + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaArtifactType.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaArtifactType.java new file mode 100644 index 0000000000..2da60c0b79 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaArtifactType.java @@ -0,0 +1,39 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes; + + +public enum ToscaArtifactType { + + DEPLOYMENT("tosca.artifacts.Deployment"),; + + private String displayName; + + ToscaArtifactType(String displayName) { + this.displayName = displayName; + } + + public String getDisplayName() { + return displayName; + } + + +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaCapabilityType.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaCapabilityType.java new file mode 100644 index 0000000000..d26eb3a83a --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaCapabilityType.java @@ -0,0 +1,52 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes; + + +public enum ToscaCapabilityType { + + ROOT("tosca.capabilities.Root"), + NODE("tosca.capabilities.Node"), + CONTAINER("tosca.capabilities.Container"), + NETWORK_BINDABLE("tosca.capabilities.network.Bindable"), + SCALABLE("tosca.capabilities.Scalable"), + OPERATING_SYSTEM("tosca.capabilities.OperatingSystem"), + ENDPOINT_ADMIN("tosca.capabilities.Endpoint.Admin"), + ATTACHMENT("tosca.capabilities.Attachment"), + NETWORK_LINKABLE("tosca.capabilities.network.Linkable"), + METRIC("org.openecomp.capabilities.Metric"), + NFV_METRIC("tosca.capabilities.nfv.Metric"), + METRIC_CEILOMETER("org.openecomp.capabilities.metric.Ceilometer"), + METRIC_SNMP_TRAP("org.openecomp.capabilities.metric.SnmpTrap"), + METRIC_SNMP_POLLING("org.openecomp.capabilities.metric.SnmpPolling"),; + + private String displayName; + + ToscaCapabilityType(String displayName) { + this.displayName = displayName; + } + + public String getDisplayName() { + return displayName; + } + + +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaDataType.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaDataType.java new file mode 100644 index 0000000000..2a9df65b17 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaDataType.java @@ -0,0 +1,84 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes; + + +public enum ToscaDataType { + + ROOT("tosca.datatypes.Root"), + NETWORK_NETWORK_INFO("tosca.datatypes.network.NetworkInfo"), + NETWORK_PORT_INFO("tosca.datatypes.network.PortInfo"), + NOVA_SERVER_PORT_EXTRA_PROPERTIES( + "org.openecomp.datatypes.heat.novaServer.network.PortExtraProperties"), + NETWORK_ADDRESS_PAIR("org.openecomp.datatypes.heat.network.AddressPair"), + NEUTRON_PORT_FIXED_IPS("org.openecomp.datatypes.heat.neutron.port.FixedIps"), + CONTRAIL_NETWORK_RULE("org.openecomp.datatypes.heat.contrail.network.rule.Rule"), + CONTRAIL_NETWORK_RULE_LIST("org.openecomp.datatypes.heat.contrail.network.rule.RuleList"), + CONTRAIL_NETWORK_RULE_PORT_PAIRS("org.openecomp.datatypes.heat.contrail.network.rule.PortPairs"), + CONTRAIL_NETWORK_RULE_VIRTUAL_NETWORK( + "org.openecomp.datatypes.heat.contrail.network.rule.VirtualNetwork"), + CONTRAILV2_NETWORK_RULE("org.openecomp.datatypes.heat.contrailV2.network.rule.Rule"), + CONTRAILV2_NETWORK_RULE_LIST("org.openecomp.datatypes.heat.contrailV2.network.rule.RuleList"), + CONTRAILV2_NETWORK_RULE_SRC_PORT_PAIRS( + "org.openecomp.datatypes.heat.contrailV2.network.rule.SrcPortPairs"), + CONTRAILV2_NETWORK_RULE_DST_PORT_PAIRS( + "org.openecomp.datatypes.heat.contrailV2.network.rule.DstPortPairs"), + CONTRAILV2_NETWORK_RULE_DST_VIRTUAL_NETWORK( + "org.openecomp.datatypes.heat.contrailV2.network.rule.DstVirtualNetwork"), + CONTRAILV2_NETWORK_RULE_SRC_VIRTUAL_NETWORK( + "org.openecomp.datatypes.heat.contrailV2.network.rule.SrcVirtualNetwork"), + CONTRAILV2_VIRTUAL_MACHINE_INTERFACE_PROPERTIES( + "org.openecomp.datatypes.heat.contrailV2.virtual.machine.interface.Properties"), + CONTRAILV2_NETWORK_RULE_ACTION_LIST( + "org.openecomp.datatypes.heat.contrailV2.network.rule.ActionList"), + CONTRAILV2_VIRTUAL_NETWORK_IPAM_REF_DATA( + "org.openecomp.datatypes.heat.contrailV2.virtual.network.rule.IpamRefData"), + CONTRAILV2_VIRTUAL_NETWORK_IPAM_REF_DATA_IPAM_SUBNET_LIST( + "org.openecomp.datatypes.heat.contrailV2.virtual.network.rule.ref.data.IpamSubnetList"), + CONTRAILV2_VIRTUAL_NETWORK_IPAM_REF_DATA_IPAM_SUBNET( + "org.openecomp.datatypes.heat.contrailV2.virtual.network.rule.ref.data.IpamSubnet"), + CONTRAILV2_VIRTUAL_NETWORK_POLICY_REF_DATA( + "org.openecomp.datatypes.heat.contrailV2.virtual.network.rule.RefData"), + CONTRAILV2_VIRTUAL_NETWORK_POLICY_REF_DATA_SEQUENCE( + "org.openecomp.datatypes.heat.contrailV2.virtual.network.rule.RefDataSequence"), + NOVA_SERVER_NETWORK_ADDRESS_INFO("org.openecomp.datatypes.heat.novaServer.network.AddressInfo"), + NEUTRON_SUBNET("org.openecomp.datatypes.heat.network.neutron.Subnet"), + NETWORK_ALLOCATION_POOL("org.openecomp.datatypes.heat.network.AllocationPool"), + NETWORK_HOST_ROUTE("org.openecomp.datatypes.heat.network.subnet.HostRoute"), + SUBSTITUTION_FILTER("org.openecomp.datatypes.heat.substitution.SubstitutionFilter"), + SUBSTITUTION_FILTERING("org.openecomp.datatypes.heat.substitution.SubstitutionFiltering"), + NEUTRON_SECURITY_RULES_RULE("org.openecomp.datatypes.heat.network.neutron.SecurityRules.Rule"), + CONTRAIL_STATIC_ROUTE("org.openecomp.datatypes.heat.network.contrail.port.StaticRoute"), + CONTRAIL_ADDRESS_PAIR("org.openecomp.datatypes.heat.network.contrail.AddressPair"), + CONTRAIL_INTERFACE_DATA("org.openecomp.datatypes.heat.network.contrail.InterfaceData"); + + private String displayName; + + ToscaDataType(String displayName) { + this.displayName = displayName; + } + + public String getDisplayName() { + return displayName; + } + + +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaElementTypes.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaElementTypes.java new file mode 100644 index 0000000000..97fec7ae7d --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaElementTypes.java @@ -0,0 +1,25 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes; + +public enum ToscaElementTypes { + CAPABILITY_TYPE +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaFunctions.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaFunctions.java new file mode 100644 index 0000000000..989a1c6178 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaFunctions.java @@ -0,0 +1,43 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes; + +public enum ToscaFunctions { + + TOKEN("token"), + GET_PROPERTY("get_property"), + GET_ATTRIBUTE("get_attribute"), + GET_ARTIFACT("get_artifact"), + GET_INPUT("get_input"), + CONCAT("concat"); + + private String displayName; + + ToscaFunctions(String displayName) { + this.displayName = displayName; + } + + public String getDisplayName() { + return displayName; + } + + +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaGroupType.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaGroupType.java new file mode 100644 index 0000000000..5422fa6dc9 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaGroupType.java @@ -0,0 +1,40 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes; + + +public enum ToscaGroupType { + + ROOT("tosca.groups.Root"), + HEAT_STACK("org.openecomp.groups.heat.HeatStack"),; + + private String displayName; + + ToscaGroupType(String displayName) { + this.displayName = displayName; + } + + public String getDisplayName() { + return displayName; + } + + +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaNodeType.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaNodeType.java new file mode 100644 index 0000000000..c7c5a6e64e --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaNodeType.java @@ -0,0 +1,162 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes; + +import org.openecomp.sdc.tosca.services.ToscaConstants; + +import java.util.Collections; +import java.util.HashMap; +import java.util.Map; + + +/** + * The enum Tosca node type. + */ +public enum ToscaNodeType { + + /** + * Compute tosca node type. + */ + COMPUTE("tosca.nodes.Compute"), + /** + * Root tosca node type. + */ + ROOT("tosca.nodes.Root"), + /** + * Block storage tosca node type. + */ + BLOCK_STORAGE("tosca.nodes.BlockStorage"), + /** + * Network tosca node type. + */ + NETWORK("tosca.nodes.network.Network"), + /** + * Network port tosca node type. + */ + NETWORK_PORT("tosca.nodes.network.Port"), + /** + * Nova server tosca node type. + */ + NOVA_SERVER(ToscaConstants.NODES_PREFIX + "nova.Server"), + /** + * Cinder volume tosca node type. + */ + CINDER_VOLUME(ToscaConstants.NODES_PREFIX + "cinder.Volume"), + /** + * Neutron net tosca node type. + */ + NEUTRON_NET("org.openecomp.resource.vl.nodes.heat.network.neutron.Net"), + /** + * Neutron port tosca node type. + */ + NEUTRON_PORT("org.openecomp.resource.cp.nodes.heat.network.neutron.Port"), + /** + * Neutron security rules tosca node type. + */ + NEUTRON_SECURITY_RULES("org.openecomp.resource.vfc.rules.nodes" + + ".heat.network.neutron.SecurityRules"), + /** + * Contrail virtual network tosca node type. + */ + CONTRAIL_VIRTUAL_NETWORK("org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork"), + /** + * Contrail network rule tosca node type. + */ + CONTRAIL_NETWORK_RULE("org.openecomp.resource.vfc." + + "rules.nodes.heat.network.contrail.NetworkRules"), + /** + * Contrailv 2 virtual network tosca node type. + */ + CONTRAILV2_VIRTUAL_NETWORK("org.openecomp.resource.vl.nodes." + + "heat.network.contrailV2.VirtualNetwork"), + /** + * Contrailv 2 network rule tosca node type. + */ + CONTRAILV2_NETWORK_RULE( + "org.openecomp.resource.vfc.rules.nodes.heat.network.contrailV2.NetworkRules"), + /** + * Contrailv 2 virtual machine interface tosca node type. + */ + CONTRAILV2_VIRTUAL_MACHINE_INTERFACE( + "org.openecomp.resource.cp.nodes.heat.contrailV2.VirtualMachineInterface"), + /** + * Abstract substitute tosca node type. + */ + ABSTRACT_SUBSTITUTE("org.openecomp.resource.abstract.nodes.AbstractSubstitute"), + /** + * Contrail compute tosca node type. + */ + CONTRAIL_COMPUTE(ToscaConstants.NODES_PREFIX + "contrail.Compute"), + /** + * Contrail port tosca node type. + */ + CONTRAIL_PORT("org.openecomp.resource.cp.nodes.heat.network.contrail.Port"), + /** + * Contrail abstract substitute tosca node type. + */ + CONTRAIL_ABSTRACT_SUBSTITUTE("org.openecomp.resource.abstract." + + "nodes.contrail.AbstractSubstitute"),; + + private static final Map mMap = + Collections.unmodifiableMap(initializeMapping()); + private String displayName; + + ToscaNodeType(String displayName) { + this.displayName = displayName; + } + + /** + * Initialize mapping map. + * + * @return the map + */ + public static Map initializeMapping() { + Map toscaMap = new HashMap<>(); + for (ToscaNodeType v : ToscaNodeType.values()) { + toscaMap.put(v.displayName, v); + } + return toscaMap; + } + + /** + * Gets tosca node type by display name. + * + * @param displayName the display name + * @return the tosca node type by display name + */ + public static ToscaNodeType getToscaNodeTypeByDisplayName(String displayName) { + if (mMap.containsKey(displayName)) { + return mMap.get(displayName); + } + return null; + } + + /** + * Gets display name. + * + * @return the display name + */ + public String getDisplayName() { + return displayName; + } + + +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaPolicyType.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaPolicyType.java new file mode 100644 index 0000000000..38195782d2 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaPolicyType.java @@ -0,0 +1,43 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes; + +public enum ToscaPolicyType { + + PLACEMENT("tosca.policy.placement"), + PLACEMENT_ANTILOCATE("org.openecomp.policies.placement.Antilocate"), + PLACEMENT_COLOCATE("org.openecomp.policies.placement.Colocate"), + PLACEMENT_VALET_AFFINITY("org.openecomp.policies.placement.valet.Affinity"), + PLACEMENT_VALET_EXCLUSIVITY("org.openecomp.policies.placement.valet.Exclusivity"), + PLACEMENT_VALET_DIVERSITY("org.openecomp.policies.placement.valet.Diversity"); + + private String displayName; + + ToscaPolicyType(String displayName) { + this.displayName = displayName; + } + + public String getDisplayName() { + return displayName; + } + + +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaRelationshipType.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaRelationshipType.java new file mode 100644 index 0000000000..03a35bd4d0 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaRelationshipType.java @@ -0,0 +1,44 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes; + +public enum ToscaRelationshipType { + + ROOT("tosca.relationships.Root"), + NATIVE_ATTACHES_TO("tosca.relationships.AttachesTo"), + DEPENDS_ON("tosca.relationships.DependsOn"), + NETWORK_LINK_TO("tosca.relationships.network.LinksTo"), + NETWORK_BINDS_TO("tosca.relationships.network.BindsTo"), + CINDER_VOLUME_ATTACHES_TO("org.openecomp.relationships.heat.cinder.VolumeAttachesTo"), + ATTACHES_TO("org.openecomp.relationships.AttachesTo"),; + + private String displayName; + + ToscaRelationshipType(String displayName) { + this.displayName = displayName; + } + + public String getDisplayName() { + return displayName; + } + + +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaServiceModel.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaServiceModel.java new file mode 100644 index 0000000000..70b23ae3f6 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/ToscaServiceModel.java @@ -0,0 +1,72 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes; + +import org.openecomp.core.utilities.file.FileContentHandler; +import org.openecomp.sdc.datatypes.model.AsdcModel; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; + +import java.util.Collections; +import java.util.Map; + +public class ToscaServiceModel implements AsdcModel { + private FileContentHandler artifactFiles; + private Map serviceTemplates; + private String entryDefinitionServiceTemplate; + + /** + * Instantiates a new Tosca service model. + * + * @param artifactFiles the artifact files + * @param serviceTemplates the service templates + * @param entryDefinitionServiceTemplate the entry definition service template + */ + public ToscaServiceModel(FileContentHandler artifactFiles, + Map serviceTemplates, + String entryDefinitionServiceTemplate) { + this.artifactFiles = artifactFiles; + this.serviceTemplates = serviceTemplates; + this.entryDefinitionServiceTemplate = entryDefinitionServiceTemplate; + } + + + public FileContentHandler getArtifactFiles() { + return artifactFiles;//MapUtils.isEmpty(artifactFiles) ? Collections.EMPTY_MAP + // : Collections.unmodifiableMap(artifactFiles); + } + + + public Map getServiceTemplates() { + return Collections.unmodifiableMap(serviceTemplates); + } + + public void setServiceTemplates(Map serviceTemplates) { + this.serviceTemplates = serviceTemplates; + } + + public String getEntryDefinitionServiceTemplate() { + return entryDefinitionServiceTemplate; + } + + public void setEntryDefinitionServiceTemplate(String entryDefinitionServiceTemplate) { + this.entryDefinitionServiceTemplate = entryDefinitionServiceTemplate; + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/ArtifactDefinition.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/ArtifactDefinition.java new file mode 100644 index 0000000000..8461fef85f --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/ArtifactDefinition.java @@ -0,0 +1,69 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model; + +public class ArtifactDefinition { + private String type; + private String file; + private String repository; + private String description; + private String deploy_path; + + public String getType() { + return type; + } + + public void setType(String type) { + this.type = type; + } + + public String getFile() { + return file; + } + + public void setFile(String file) { + this.file = file; + } + + public String getRepository() { + return repository; + } + + public void setRepository(String repository) { + this.repository = repository; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public String getDeploy_path() { + return deploy_path; + } + + public void setDeploy_path(String deployPath) { + this.deploy_path = deployPath; + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/ArtifactType.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/ArtifactType.java new file mode 100644 index 0000000000..80580e97f3 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/ArtifactType.java @@ -0,0 +1,83 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model; + +import java.util.List; +import java.util.Map; + +public class ArtifactType { + + private String derived_from; + private String version; + private String description; + private String mime_type; + private List file_ext; + private Map properties; + + + public String getDerived_from() { + return derived_from; + } + + public void setDerived_from(String derivedFrom) { + this.derived_from = derivedFrom; + } + + public String getVersion() { + return version; + } + + public void setVersion(String version) { + this.version = version; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public String getMime_type() { + return mime_type; + } + + public void setMime_type(String mimeType) { + this.mime_type = mimeType; + } + + public List getFile_ext() { + return file_ext; + } + + public void setFile_ext(List fileExt) { + this.file_ext = fileExt; + } + + public Map getProperties() { + return properties; + } + + public void setProperties(Map properties) { + this.properties = properties; + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/AttributeDefinition.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/AttributeDefinition.java new file mode 100644 index 0000000000..13c93a283d --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/AttributeDefinition.java @@ -0,0 +1,85 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model; + +public class AttributeDefinition { + + private String type; + private String description; + private Object _default; + private Status status; + private EntrySchema entry_schema; + + public AttributeDefinition() { + status = Status.SUPPORTED; + } + + public EntrySchema getEntry_schema() { + return entry_schema; + } + + public void setEntry_schema(EntrySchema entrySchema) { + this.entry_schema = entrySchema; + } + + public Status getStatus() { + return status; + } + + public void setStatus(Status status) { + this.status = status; + } + + public Object get_default() { + return _default; + } + + public void set_default(Object defaultValue) { + this._default = defaultValue; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public String getType() { + return type; + } + + public void setType(String type) { + this.type = type; + } + + @Override + public AttributeDefinition clone() { + AttributeDefinition attributeDefinition = new AttributeDefinition(); + attributeDefinition.setType(this.getType()); + attributeDefinition.setDescription(this.getDescription()); + attributeDefinition.set_default(this.get_default()); + attributeDefinition.setStatus(this.getStatus()); + attributeDefinition.setEntry_schema(this.getEntry_schema().clone()); + return attributeDefinition; + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/CapabilityAssignment.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/CapabilityAssignment.java new file mode 100644 index 0000000000..b548f7855c --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/CapabilityAssignment.java @@ -0,0 +1,45 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model; + +import java.util.Map; + +public class CapabilityAssignment { + + private Map properties; + private Map attributes; + + public Map getProperties() { + return properties; + } + + public void setProperties(Map properties) { + this.properties = properties; + } + + public Map getAttributes() { + return attributes; + } + + public void setAttributes(Map attributes) { + this.attributes = attributes; + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/CapabilityDefinition.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/CapabilityDefinition.java new file mode 100644 index 0000000000..36dccad6eb --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/CapabilityDefinition.java @@ -0,0 +1,113 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model; + +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.tosca.services.ToscaConstants; + +import java.util.List; +import java.util.Map; + +public class CapabilityDefinition { + + private String type; + private String description; + private Map properties; + private Map attributes; + private List valid_source_types; + private Object[] occurrences; + + + /** + * Instantiates a new Capability definition. + */ + public CapabilityDefinition() { + occurrences = new Object[2]; + occurrences[0] = 1; + occurrences[1] = ToscaConstants.UNBOUNDED; + } + + public String getType() { + return type; + } + + public void setType(String type) { + this.type = type; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public Map getProperties() { + return properties; + } + + public void setProperties(Map properties) { + this.properties = properties; + } + + public Map getAttributes() { + return attributes; + } + + public void setAttributes(Map attributes) { + this.attributes = attributes; + } + + public List getValid_source_types() { + return valid_source_types; + } + + public void setValid_source_types(List validSourceTypes) { + this.valid_source_types = validSourceTypes; + } + + public Object[] getOccurrences() { + return occurrences; + } + + public void setOccurrences(Object[] occurrences) { + this.occurrences = occurrences; + } + + @Override + public CapabilityDefinition clone() { + CapabilityDefinition capabilityDefinition = new CapabilityDefinition(); + capabilityDefinition + .setOccurrences(new Object[]{this.getOccurrences()[0], this.getOccurrences()[1]}); + capabilityDefinition + .setProperties(DataModelUtil.clonePropertyDefinitions(this.getProperties())); + capabilityDefinition.setType(this.getType()); + capabilityDefinition + .setAttributes(DataModelUtil.cloneAttributeDefinitions(this.getAttributes())); + capabilityDefinition.setDescription(this.getDescription()); + capabilityDefinition + .setValid_source_types(DataModelUtil.cloneValidSourceTypes(this.getValid_source_types())); + return capabilityDefinition; + + } + +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/CapabilityFilterDefinition.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/CapabilityFilterDefinition.java new file mode 100644 index 0000000000..3678583384 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/CapabilityFilterDefinition.java @@ -0,0 +1,35 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model; + +import java.util.List; + +public class CapabilityFilterDefinition { + List properties; + + public List getProperties() { + return properties; + } + + public void setProperties(List properties) { + this.properties = properties; + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/CapabilityType.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/CapabilityType.java new file mode 100644 index 0000000000..b0281b4ca0 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/CapabilityType.java @@ -0,0 +1,82 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model; + +import java.util.List; +import java.util.Map; + +public class CapabilityType { + + private String derived_from; + private String version; + private String description; + private Map properties; + private Map attributes; + private List valid_source_types; + + public String getDerived_from() { + return derived_from; + } + + public void setDerived_from(String derivedFrom) { + this.derived_from = derivedFrom; + } + + public String getVersion() { + return version; + } + + public void setVersion(String version) { + this.version = version; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public Map getProperties() { + return properties; + } + + public void setProperties(Map properties) { + this.properties = properties; + } + + public Map getAttributes() { + return attributes; + } + + public void setAttributes(Map attributes) { + this.attributes = attributes; + } + + public List getValid_source_types() { + return valid_source_types; + } + + public void setValid_source_types(List validSourceTypes) { + this.valid_source_types = validSourceTypes; + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/Constraint.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/Constraint.java new file mode 100644 index 0000000000..2c39ce3902 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/Constraint.java @@ -0,0 +1,181 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model; + +import java.util.ArrayList; +import java.util.List; + +public class Constraint { + private Object equal; + private Object greater_or_equal; + private Object greater_than; + private Object less_than; + private Object less_or_equal; + private Object[] in_range; + private List valid_values; + private Integer length; + private Integer min_length; + private Integer max_length; + private Object pattern; + + public Constraint() { + } + + public Object getGreater_or_equal() { + return greater_or_equal; + } + + public void setGreater_or_equal(Object greaterOrEqual) { + this.greater_or_equal = greaterOrEqual; + } + + public Object getEqual() { + return equal; + } + + public void setEqual(Object equal) { + this.equal = equal; + } + + public Object getGreater_than() { + return greater_than; + } + + public void setGreater_than(Object greaterThan) { + this.greater_than = greaterThan; + } + + public Object getLess_than() { + return less_than; + } + + public void setLess_than(Object lessThan) { + this.less_than = lessThan; + } + + public Object getLess_or_equal() { + return less_or_equal; + } + + public void setLess_or_equal(Object lessOrEqual) { + this.less_or_equal = lessOrEqual; + } + + public Object[] getIn_range() { + return in_range; + } + + /** + * Sets in range. + * + * @param inRange the in range + */ + public void setIn_range(Object[] inRange) { + this.in_range = new Object[2]; + this.in_range[0] = inRange[0]; + this.in_range[1] = inRange[1]; + } + + public List getValid_values() { + return valid_values; + } + + public void setValid_values(List validValues) { + this.valid_values = validValues; + } + + /** + * Add valid value. + * + * @param validValue the valid value + */ + public void addValidValue(Object validValue) { + if (this.valid_values == null) { + this.valid_values = new ArrayList<>(); + } + valid_values.add(validValue); + } + + public Integer getLength() { + return length; + } + + public void setLength(Integer length) { + this.length = length; + } + + public Integer getMin_length() { + return min_length; + } + + public void setMin_length(Integer minLength) { + this.min_length = minLength; + } + + public Integer getMax_length() { + return max_length; + } + + public void setMax_length(Integer maxLength) { + this.max_length = maxLength; + } + + public Object getPattern() { + return pattern; + } + + public void setPattern(Object pattern) { + this.pattern = pattern; + } + + @Override + public Constraint clone() { + Constraint constraint = new Constraint(); + constraint.setEqual(this.getEqual()); + constraint.setGreater_or_equal(this.getGreater_or_equal()); + constraint.setGreater_than(this.getGreater_than()); + cloneInRange(constraint); + constraint.setLength(this.getLength()); + constraint.setLess_or_equal(this.getLess_or_equal()); + constraint.setLess_than(this.getLess_than()); + constraint.setMax_length(this.getMax_length()); + constraint.setMin_length(this.getMin_length()); + constraint.setPattern(this.getPattern()); + cloneValidValues(constraint); + + return constraint; + } + + private void cloneInRange(Constraint constraint) { + if (this.getIn_range() != null) { + constraint.setIn_range(new Object[]{this.getIn_range()[0], this.getIn_range()[1]}); + } + } + + private void cloneValidValues(Constraint constraint) { + if (this.getValid_values() != null) { + constraint.setValid_values(new ArrayList<>()); + for (Object entry : this.getValid_values()) { + constraint.getValid_values().add(entry); + } + } + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/DataType.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/DataType.java new file mode 100644 index 0000000000..866c5774d8 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/DataType.java @@ -0,0 +1,73 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model; + +import java.util.List; +import java.util.Map; + +public class DataType { + + private String derived_from; + private String version; + private String description; + private List constraints; + private Map properties; + + public String getDerived_from() { + return derived_from; + } + + public void setDerived_from(String derivedFrom) { + this.derived_from = derivedFrom; + } + + public String getVersion() { + return version; + } + + public void setVersion(String version) { + this.version = version; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public List getConstraints() { + return constraints; + } + + public void setConstraints(List constraints) { + this.constraints = constraints; + } + + public Map getProperties() { + return properties; + } + + public void setProperties(Map properties) { + this.properties = properties; + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/Directive.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/Directive.java new file mode 100644 index 0000000000..078a6449ea --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/Directive.java @@ -0,0 +1,40 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model; + +public enum Directive { + + + SELECTABLE("selectable"), + SUBSTITUTABLE("substitutable"); + + private String displayName; + + Directive(String displayName) { + this.displayName = displayName; + } + + public String getDisplayName() { + return displayName; + } + + +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/EntrySchema.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/EntrySchema.java new file mode 100644 index 0000000000..8b08e54c01 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/EntrySchema.java @@ -0,0 +1,65 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model; + +import org.openecomp.sdc.tosca.services.DataModelUtil; + +import java.util.List; + +public class EntrySchema { + + private String description; + private String type; + private List constraints; + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public String getType() { + return type; + } + + public void setType(String type) { + this.type = type; + } + + public List getConstraints() { + return constraints; + } + + public void setConstraints(List constraints) { + this.constraints = constraints; + } + + @Override + public EntrySchema clone() { + EntrySchema entrySchema = new EntrySchema(); + entrySchema.setDescription(this.getDescription()); + entrySchema.setType(this.getType()); + entrySchema.setConstraints(DataModelUtil.cloneConstraints(this.getConstraints())); + return entrySchema; + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/GroupDefinition.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/GroupDefinition.java new file mode 100644 index 0000000000..807bf260c3 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/GroupDefinition.java @@ -0,0 +1,64 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model; + +import java.util.List; +import java.util.Map; + +public class GroupDefinition { + + private String type; + private String description; + private Map properties; + private List members; + + public String getType() { + return type; + } + + public void setType(String type) { + this.type = type; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public Map getProperties() { + return properties; + } + + public void setProperties(Map properties) { + this.properties = properties; + } + + public List getMembers() { + return members; + } + + public void setMembers(List members) { + this.members = members; + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/GroupType.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/GroupType.java new file mode 100644 index 0000000000..4bbb861286 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/GroupType.java @@ -0,0 +1,82 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model; + +import java.util.List; +import java.util.Map; + +public class GroupType { + + private String derived_from; + private String version; + private String description; + private Map properties; + private List members; + private Map interfaces; + + public String getDerived_from() { + return derived_from; + } + + public void setDerived_from(String derivedFrom) { + this.derived_from = derivedFrom; + } + + public String getVersion() { + return version; + } + + public void setVersion(String version) { + this.version = version; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public Map getProperties() { + return properties; + } + + public void setProperties(Map properties) { + this.properties = properties; + } + + public List getMembers() { + return members; + } + + public void setMembers(List members) { + this.members = members; + } + + public Map getInterfaces() { + return interfaces; + } + + public void setInterfaces(Map interfaces) { + this.interfaces = interfaces; + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/Import.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/Import.java new file mode 100644 index 0000000000..207a1b520a --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/Import.java @@ -0,0 +1,61 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model; + +public class Import { + + private String file; + private String repository; + private String namespace_uri; + private String namespace_prefix; + + public String getFile() { + return file; + } + + public void setFile(String file) { + this.file = file; + } + + public String getRepository() { + return repository; + } + + public void setRepository(String repository) { + this.repository = repository; + } + + public String getNamespace_uri() { + return namespace_uri; + } + + public void setNamespace_uri(String namespaceUri) { + this.namespace_uri = namespaceUri; + } + + public String getNamespace_prefix() { + return namespace_prefix; + } + + public void setNamespace_prefix(String namespacePrefix) { + this.namespace_prefix = namespacePrefix; + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/InterfaceDefinition.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/InterfaceDefinition.java new file mode 100644 index 0000000000..cf09510083 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/InterfaceDefinition.java @@ -0,0 +1,24 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model; + +public class InterfaceDefinition { +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/InterfaceType.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/InterfaceType.java new file mode 100644 index 0000000000..b177b0660a --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/InterfaceType.java @@ -0,0 +1,24 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model; + +public class InterfaceType { +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/Metadata.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/Metadata.java new file mode 100644 index 0000000000..162e693dba --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/Metadata.java @@ -0,0 +1,55 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model; + +import java.util.Map; + +public class Metadata { + + private String template_name; + private String template_author; + private String template_version; + + + public String getTemplate_name() { + return template_name; + } + + public void setTemplate_name(String templateName) { + this.template_name = templateName; + } + + public String getTemplate_author() { + return template_author; + } + + public void setTemplate_author(String templateAuthor) { + this.template_author = templateAuthor; + } + + public String getTemplate_version() { + return template_version; + } + + public void setTemplate_version(String templateVersion) { + this.template_version = templateVersion; + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/NodeFilter.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/NodeFilter.java new file mode 100644 index 0000000000..d87dcd7b1d --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/NodeFilter.java @@ -0,0 +1,47 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model; + +import java.util.List; +import java.util.Map; + +public class NodeFilter { + + Map> properties; + Map capabilities; + + public Map> getProperties() { + + return properties; + } + + public void setProperties(Map> properties) { + this.properties = properties; + } + + public Map getCapabilities() { + return capabilities; + } + + public void setCapabilities(Map capabilities) { + this.capabilities = capabilities; + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/NodeTemplate.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/NodeTemplate.java new file mode 100644 index 0000000000..41ac232605 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/NodeTemplate.java @@ -0,0 +1,127 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model; + +import java.util.List; +import java.util.Map; + +public class NodeTemplate implements Template { + + private String type; + private String description; + private List directives; + private Map properties; + private Map attributes; + private List> requirements; + private List> capabilities; + private Map interfaces; + private Map artifacts; + private NodeFilter node_filter; + private String copy; + + public String getType() { + return type; + } + + public void setType(String type) { + this.type = type; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public List getDirectives() { + return directives; + } + + public void setDirectives(List directives) { + this.directives = directives; + } + + public Map getProperties() { + return properties; + } + + public void setProperties(Map properties) { + this.properties = properties; + } + + public Map getAttributes() { + return attributes; + } + + public void setAttributes(Map attributes) { + this.attributes = attributes; + } + + public List> getRequirements() { + return requirements; + } + + public void setRequirements(List> requirements) { + this.requirements = requirements; + } + + public List> getCapabilities() { + return capabilities; + } + + public void setCapabilities(List> capabilities) { + this.capabilities = capabilities; + } + + public Map getInterfaces() { + return interfaces; + } + + public void setInterfaces(Map interfaces) { + this.interfaces = interfaces; + } + + public Map getArtifacts() { + return artifacts; + } + + public void setArtifacts(Map artifacts) { + this.artifacts = artifacts; + } + + public NodeFilter getNode_filter() { + return node_filter; + } + + public void setNode_filter(NodeFilter nodeFilter) { + this.node_filter = nodeFilter; + } + + public String getCopy() { + return copy; + } + + public void setCopy(String copy) { + this.copy = copy; + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/NodeType.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/NodeType.java new file mode 100644 index 0000000000..d477f286ee --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/NodeType.java @@ -0,0 +1,125 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model; + +import java.util.List; +import java.util.Map; + +public class NodeType { + + private String derived_from; + private String version; + private String description; + private Map properties; + private Map attributes; + private List> requirements; + private Map capabilities; + private Map interfaces; + private Map artifacts; + + + public String getDerived_from() { + return derived_from; + } + + public void setDerived_from(String derivedFrom) { + this.derived_from = derivedFrom; + } + + public String getVersion() { + return version; + } + + public void setVersion(String version) { + this.version = version; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public Map getProperties() { + return properties; + } + + public void setProperties(Map properties) { + this.properties = properties; + } + + public Map getAttributes() { + return attributes; + } + + public void setAttributes(Map attributes) { + this.attributes = attributes; + } + + public List> getRequirements() { + return requirements; + } + + public void setRequirements(List> requirements) { + this.requirements = requirements; + } + + public Map getCapabilities() { + return capabilities; + } + + public void setCapabilities(Map capabilities) { + this.capabilities = capabilities; + } + + public Map getInterfaces() { + return interfaces; + } + + public void setInterfaces(Map interfaces) { + this.interfaces = interfaces; + } + + public Map getArtifacts() { + return artifacts; + } + + public void setArtifacts(Map artifacts) { + this.artifacts = artifacts; + } + + @Override + public NodeType clone() { + NodeType clone = new NodeType(); + clone.setCapabilities(this.getCapabilities()); + clone.setDerived_from(this.getDerived_from()); + clone.setProperties(this.getProperties()); + clone.setRequirements(this.getRequirements()); + clone.setDescription(this.getDescription()); + clone.setAttributes(this.getAttributes()); + clone.setInterfaces(this.getInterfaces()); + clone.setVersion(this.getVersion()); + clone.setArtifacts(this.getArtifacts()); + return clone; + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/ParameterDefinition.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/ParameterDefinition.java new file mode 100644 index 0000000000..6ef4c782f5 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/ParameterDefinition.java @@ -0,0 +1,99 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model; + +import java.util.List; + +public class ParameterDefinition { + + private String type; + private String description; + private Object value; + private Boolean required; + private Object _default; + private Status status; + private List constraints; + private EntrySchema entry_schema; + + public String getType() { + return type; + } + + public void setType(String type) { + this.type = type; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public Object getValue() { + return value; + } + + public void setValue(Object value) { + this.value = value; + } + + public Boolean getRequired() { + return required; + } + + public void setRequired(Boolean required) { + this.required = required; + } + + public Object get_default() { + return _default; + } + + public void set_default(Object defaultValue) { + this._default = defaultValue; + } + + public Status getStatus() { + return status; + } + + public void setStatus(Status status) { + this.status = status; + } + + public List getConstraints() { + return constraints; + } + + public void setConstraints(List constraints) { + this.constraints = constraints; + } + + public EntrySchema getEntry_schema() { + return entry_schema; + } + + public void setEntry_schema(EntrySchema entrySchema) { + this.entry_schema = entrySchema; + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/PolicyDefinition.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/PolicyDefinition.java new file mode 100644 index 0000000000..90f44ae36a --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/PolicyDefinition.java @@ -0,0 +1,63 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model; + +import java.util.List; +import java.util.Map; + +public class PolicyDefinition implements Template { + private String type; + private String description; + private Map properties; + private List targets; + + public String getType() { + return type; + } + + public void setType(String type) { + this.type = type; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public Map getProperties() { + return properties; + } + + public void setProperties(Map properties) { + this.properties = properties; + } + + public List getTargets() { + return targets; + } + + public void setTargets(List targets) { + this.targets = targets; + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/PolicyType.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/PolicyType.java new file mode 100644 index 0000000000..07412cda59 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/PolicyType.java @@ -0,0 +1,73 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model; + +import java.util.List; +import java.util.Map; + +public class PolicyType { + + private String derived_from; + private String version; + private String description; + private Map properties; + private List targets; + + public String getDerived_from() { + return derived_from; + } + + public void setDerived_from(String derivedFrom) { + this.derived_from = derivedFrom; + } + + public String getVersion() { + return version; + } + + public void setVersion(String version) { + this.version = version; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public Map getProperties() { + return properties; + } + + public void setProperties(Map properties) { + this.properties = properties; + } + + public List getTargets() { + return targets; + } + + public void setTargets(List targets) { + this.targets = targets; + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/PropertyDefinition.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/PropertyDefinition.java new file mode 100644 index 0000000000..cf47d0b113 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/PropertyDefinition.java @@ -0,0 +1,112 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model; + +import org.openecomp.sdc.tosca.services.DataModelUtil; + +import java.util.List; + +public class PropertyDefinition { + + private String type; + private String description; + private Boolean required; + private Object _default; + private Status status; + private List constraints; + private EntrySchema entry_schema; + + public PropertyDefinition() { + status = Status.SUPPORTED; + required = true; + } + + public String getType() { + return type; + } + + public void setType(String type) { + this.type = type; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public Boolean getRequired() { + return required; + } + + public void setRequired(Boolean required) { + this.required = required; + } + + public Object get_default() { + return _default; + } + + public void set_default(Object defaultValue) { + this._default = defaultValue; + } + + public Status getStatus() { + return status; + } + + public void setStatus(Status status) { + this.status = status; + } + + public List getConstraints() { + return constraints; + } + + public void setConstraints(List constraints) { + this.constraints = constraints; + } + + public EntrySchema getEntry_schema() { + return entry_schema; + } + + public void setEntry_schema(EntrySchema entrySchema) { + this.entry_schema = entrySchema; + } + + @Override + public PropertyDefinition clone() { + PropertyDefinition propertyDefinition = new PropertyDefinition(); + propertyDefinition.setType(this.getType()); + propertyDefinition.setDescription(this.getDescription()); + propertyDefinition.setRequired(this.getRequired()); + propertyDefinition.set_default(this.get_default()); + propertyDefinition.setStatus(this.getStatus()); + propertyDefinition.setEntry_schema(this.getEntry_schema().clone()); + propertyDefinition.setConstraints(DataModelUtil.cloneConstraints(this.getConstraints())); + return propertyDefinition; + } + + +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/PropertyType.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/PropertyType.java new file mode 100644 index 0000000000..3fdd9bba0e --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/PropertyType.java @@ -0,0 +1,117 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model; + +import java.util.Collections; +import java.util.HashMap; +import java.util.Map; + +/** + * The enum Property type. + */ +public enum PropertyType { + + /** + * String property type. + */ + STRING("string"), + /** + * Integer property type. + */ + INTEGER("integer"), + /** + * Float property type. + */ + FLOAT("float"), + /** + * Boolean property type. + */ + BOOLEAN("boolean"), + /** + * Timestamp property type. + */ + TIMESTAMP("timestamp"), + /** + * Null property type. + */ + NULL("null"), + /** + * Map property type. + */ + MAP("map"), + /** + * List property type. + */ + LIST("list"), + /** + * Scalar unit size property type. + */ + SCALAR_UNIT_SIZE("scalar-unit.size"); + + private static final Map mMap = + Collections.unmodifiableMap(initializeMapping()); + private String displayName; + + PropertyType(String displayName) { + + this.displayName = displayName; + } + + /** + * Initialize mapping map. + * + * @return the map + */ + public static Map initializeMapping() { + Map typeMap = new HashMap(); + for (PropertyType v : PropertyType.values()) { + typeMap.put(v.displayName, v); + } + return typeMap; + } + + /** + * Gets property type by display name. + * + * @param displayName the display name + * @return the property type by display name + */ + public static PropertyType getPropertyTypeByDisplayName(String displayName) { + if (mMap == null) { + initializeMapping(); + } + if (mMap.containsKey(displayName)) { + return mMap.get(displayName); + } + return null; + } + + /** + * Gets display name. + * + * @return the display name + */ + public String getDisplayName() { + return displayName; + } + + +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/RelationshipTemplate.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/RelationshipTemplate.java new file mode 100644 index 0000000000..c3a1195565 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/RelationshipTemplate.java @@ -0,0 +1,99 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model; + +import java.util.Map; + +public class RelationshipTemplate implements Template { + + private String type; + private String description; + private Map properties; + private Map attributes; + private Map requirements; + private Map capabilities; + private Map interfaces; + private String copy; + + public String getType() { + return type; + } + + public void setType(String type) { + this.type = type; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public Map getProperties() { + return properties; + } + + public void setProperties(Map properties) { + this.properties = properties; + } + + public Map getAttributes() { + return attributes; + } + + public void setAttributes(Map attributes) { + this.attributes = attributes; + } + + public Map getRequirements() { + return requirements; + } + + public void setRequirements(Map requirements) { + this.requirements = requirements; + } + + public Map getCapabilities() { + return capabilities; + } + + public void setCapabilities(Map capabilities) { + this.capabilities = capabilities; + } + + public Map getInterfaces() { + return interfaces; + } + + public void setInterfaces(Map interfaces) { + this.interfaces = interfaces; + } + + public String getCopy() { + return copy; + } + + public void setCopy(String copy) { + this.copy = copy; + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/RelationshipType.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/RelationshipType.java new file mode 100644 index 0000000000..173a8a0f64 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/RelationshipType.java @@ -0,0 +1,93 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model; + +import java.util.List; +import java.util.Map; + +public class RelationshipType { + + private String derived_from; + private String version; + private String description; + private Map properties; + private Map attributes; + private Map interfaces; + private List valid_target_types; + //An optional list of one or more names of Capability Types that are valid targets + //for this relationship + + public String getDerived_from() { + return derived_from; + } + + public void setDerived_from(String derivedFrom) { + this.derived_from = derivedFrom; + } + + public String getVersion() { + return version; + } + + public void setVersion(String version) { + this.version = version; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public Map getProperties() { + return properties; + } + + public void setProperties(Map properties) { + this.properties = properties; + } + + public Map getAttributes() { + return attributes; + } + + public void setAttributes(Map attributes) { + this.attributes = attributes; + } + + public Map getInterfaces() { + return interfaces; + } + + public void setInterfaces(Map interfaces) { + this.interfaces = interfaces; + } + + public List getValid_target_types() { + return valid_target_types; + } + + public void setValid_target_types(List validTargetTypes) { + this.valid_target_types = validTargetTypes; + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/RequirementAssignment.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/RequirementAssignment.java new file mode 100644 index 0000000000..445063a3ed --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/RequirementAssignment.java @@ -0,0 +1,70 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model; + +public class RequirementAssignment { + + private String capability; + private String node; + private String relationship; + private NodeFilter node_filter; + private Object[] occurrences; + + public String getCapability() { + return capability; + } + + public void setCapability(String capability) { + this.capability = capability; + } + + public String getNode() { + return node; + } + + public void setNode(String node) { + this.node = node; + } + + public String getRelationship() { + return relationship; + } + + public void setRelationship(String relationship) { + this.relationship = relationship; + } + + public NodeFilter getNode_filter() { + return node_filter; + } + + public void setNode_filter(NodeFilter nodeFilter) { + this.node_filter = nodeFilter; + } + + public Object[] getOccurrences() { + return occurrences; + } + + public void setOccurrences(Object[] occurrences) { + this.occurrences = occurrences; + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/RequirementDefinition.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/RequirementDefinition.java new file mode 100644 index 0000000000..fe3238f1b5 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/RequirementDefinition.java @@ -0,0 +1,82 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model; + +public class RequirementDefinition { + + private String capability; + private String node; + private String relationship; + private Object[] occurrences; + + /** + * Instantiates a new Requirement definition. + */ + public RequirementDefinition() { + occurrences = new Object[2]; + occurrences[0] = 1; + occurrences[1] = 1; + } + + public String getCapability() { + return capability; + } + + public void setCapability(String capability) { + this.capability = capability; + } + + public String getNode() { + return node; + } + + public void setNode(String node) { + this.node = node; + } + + public String getRelationship() { + return relationship; + } + + public void setRelationship(String relationship) { + this.relationship = relationship; + } + + public Object[] getOccurrences() { + return occurrences; + } + + public void setOccurrences(Object[] occurrences) { + this.occurrences = occurrences; + } + + @Override + public RequirementDefinition clone() { + RequirementDefinition requirementDefinition = new RequirementDefinition(); + requirementDefinition.setNode(this.getNode()); + requirementDefinition.setRelationship(this.getRelationship()); + requirementDefinition.setCapability(this.getCapability()); + requirementDefinition + .setOccurrences(new Object[]{this.getOccurrences()[0], this.getOccurrences()[1]}); + return requirementDefinition; + } + +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/Scalar.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/Scalar.java new file mode 100644 index 0000000000..619ac510b0 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/Scalar.java @@ -0,0 +1,34 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model; + +public class Scalar { + + private Float value; + + public Float getValue() { + return value; + } + + public void setValue(Float value) { + this.value = value; + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/ServiceTemplate.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/ServiceTemplate.java new file mode 100644 index 0000000000..98da0104b8 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/ServiceTemplate.java @@ -0,0 +1,144 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model; + +import java.util.Map; + +public class ServiceTemplate implements Template { + + private String tosca_definitions_version; + private Metadata metadata; + private String description; + private Map imports; + private Map artifact_types; + private Map data_types; + private Map capability_types; + private Map interface_types; + private Map relationship_types; + private Map node_types; + private Map group_types; + private Map policy_types; + private TopologyTemplate topology_template; + + public String getTosca_definitions_version() { + return tosca_definitions_version; + } + + public void setTosca_definitions_version(String toscaDefinitionsVersion) { + this.tosca_definitions_version = toscaDefinitionsVersion; + } + + public Metadata getMetadata() { + return metadata; + } + + public void setMetadata(Metadata metadata) { + this.metadata = metadata; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public Map getImports() { + return imports; + } + + public void setImports(Map imports) { + this.imports = imports; + } + + public Map getArtifact_types() { + return artifact_types; + } + + public void setArtifact_types(Map artifactTypes) { + this.artifact_types = artifactTypes; + } + + public Map getData_types() { + return data_types; + } + + public void setData_types(Map dataTypes) { + this.data_types = dataTypes; + } + + public Map getCapability_types() { + return capability_types; + } + + public void setCapability_types(Map capabilityTypes) { + this.capability_types = capabilityTypes; + } + + public Map getRelationship_types() { + return relationship_types; + } + + public void setRelationship_types(Map relationshipTypes) { + this.relationship_types = relationshipTypes; + } + + public Map getNode_types() { + return node_types; + } + + public void setNode_types(Map nodeTypes) { + this.node_types = nodeTypes; + } + + public Map getGroup_types() { + return group_types; + } + + public void setGroup_types(Map groupTypes) { + this.group_types = groupTypes; + } + + public Map getInterface_types() { + return interface_types; + } + + public void setInterface_types(Map interfaceTypes) { + this.interface_types = interfaceTypes; + } + + public Map getPolicy_types() { + return policy_types; + } + + public void setPolicy_types(Map policyTypes) { + this.policy_types = policyTypes; + } + + public TopologyTemplate getTopology_template() { + return topology_template; + } + + public void setTopology_template(TopologyTemplate topologyTemplate) { + this.topology_template = topologyTemplate; + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/Status.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/Status.java new file mode 100644 index 0000000000..0805982a54 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/Status.java @@ -0,0 +1,42 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model; + +import java.util.Map; + +public enum Status { + + SUPPORTED("supported"), + UNSUPPORTED("unsupported"), + EXPERIMENTAL("experimental"), + DEPRECATED("deprecated"),; + private String displayName; + + Status(String displayName) { + this.displayName = displayName; + } + + public String getDisplayName() { + return displayName; + } + + +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/SubstitutionMapping.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/SubstitutionMapping.java new file mode 100644 index 0000000000..50c262dc42 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/SubstitutionMapping.java @@ -0,0 +1,54 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model; + +import java.util.List; +import java.util.Map; + +public class SubstitutionMapping { + private String node_type; + private Map> capabilities; + private Map> requirements; + + public String getNode_type() { + return node_type; + } + + public void setNode_type(String nodeType) { + this.node_type = nodeType; + } + + public Map> getRequirements() { + return requirements; + } + + public void setRequirements(Map> requirements) { + this.requirements = requirements; + } + + public Map> getCapabilities() { + return capabilities; + } + + public void setCapabilities(Map> capabilities) { + this.capabilities = capabilities; + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/Template.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/Template.java new file mode 100644 index 0000000000..128bb3c0a9 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/Template.java @@ -0,0 +1,24 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model; + +public interface Template { +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/TopologyTemplate.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/TopologyTemplate.java new file mode 100644 index 0000000000..288242946a --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/TopologyTemplate.java @@ -0,0 +1,114 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model; + +import java.util.HashMap; +import java.util.Map; +import java.util.Objects; + +public class TopologyTemplate { + + private String description; + private Map inputs; + private Map node_templates; + private Map relationship_templates; + private Map groups; + private Map outputs; + private SubstitutionMapping substitution_mappings; + private Map policies; + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public Map getInputs() { + return inputs; + } + + public void setInputs(Map inputs) { + this.inputs = inputs; + } + + public Map getNode_templates() { + return node_templates; + } + + public void setNode_templates(Map nodeTemplates) { + this.node_templates = nodeTemplates; + } + + public Map getRelationship_templates() { + return relationship_templates; + } + + public void setRelationship_templates(Map relationshipTemplates) { + this.relationship_templates = relationshipTemplates; + } + + public Map getGroups() { + return groups; + } + + public void setGroups(Map groups) { + this.groups = groups; + } + + /** + * Add group. + * + * @param groupKey the group key + * @param groupDefinition the group definition + */ + public void addGroup(String groupKey, GroupDefinition groupDefinition) { + if (Objects.isNull(this.groups)) { + this.groups = new HashMap<>(); + } + this.groups.put(groupKey, groupDefinition); + } + + public Map getOutputs() { + return outputs; + } + + public void setOutputs(Map outputs) { + this.outputs = outputs; + } + + public SubstitutionMapping getSubstitution_mappings() { + return substitution_mappings; + } + + public void setSubstitution_mappings(SubstitutionMapping substitutionMapping) { + this.substitution_mappings = substitutionMapping; + } + + public Map getPolicies() { + return policies; + } + + public void setPolicies(Map policies) { + this.policies = policies; + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/heatextend/ParameterDefinitionExt.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/heatextend/ParameterDefinitionExt.java new file mode 100644 index 0000000000..bde81108de --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/heatextend/ParameterDefinitionExt.java @@ -0,0 +1,55 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model.heatextend; + + +import org.openecomp.sdc.tosca.datatypes.model.ParameterDefinition; + +public class ParameterDefinitionExt extends ParameterDefinition { + + String label; + Boolean hidden; + Boolean immutable; + + public String getLabel() { + return label; + } + + public void setLabel(String label) { + this.label = label; + } + + public Boolean getHidden() { + return hidden; + } + + public void setHidden(Boolean hidden) { + this.hidden = hidden; + } + + public Boolean getImmutable() { + return immutable; + } + + public void setImmutable(Boolean immutable) { + this.immutable = immutable; + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/heatextend/PropertyTypeExt.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/heatextend/PropertyTypeExt.java new file mode 100644 index 0000000000..f92d674070 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/datatypes/model/heatextend/PropertyTypeExt.java @@ -0,0 +1,85 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.datatypes.model.heatextend; + +import java.util.Collections; +import java.util.HashMap; +import java.util.Map; + +/** + * The enum Property type ext. + */ +public enum PropertyTypeExt { + + /** + * Json property type ext. + */ + JSON("json"); + + private static final Map mMap = + Collections.unmodifiableMap(initializeMapping()); + private String displayName; + + PropertyTypeExt(String displayName) { + + this.displayName = displayName; + } + + /** + * Initialize mapping map. + * + * @return the map + */ + public static Map initializeMapping() { + Map typeMap = new HashMap(); + for (PropertyTypeExt v : PropertyTypeExt.values()) { + typeMap.put(v.displayName, v); + } + return typeMap; + } + + /** + * Gets property type by display name. + * + * @param displayName the display name + * @return the property type by display name + */ + public static PropertyTypeExt getPropertyTypeByDisplayName(String displayName) { + if (mMap == null) { + initializeMapping(); + } + if (mMap.containsKey(displayName)) { + return mMap.get(displayName); + } + return null; + } + + /** + * Gets display name. + * + * @return the display name + */ + public String getDisplayName() { + return displayName; + } + + +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/InvalidAddActionNullEntityErrorBuilder.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/InvalidAddActionNullEntityErrorBuilder.java new file mode 100644 index 0000000000..02bee69251 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/InvalidAddActionNullEntityErrorBuilder.java @@ -0,0 +1,58 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.errors; + +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; + +/** + * The type Invalid add action null entity error builder. + */ +public class InvalidAddActionNullEntityErrorBuilder { + + private static final String INVALID_ACTION_NULL_ENTITY_ERR_MSG = + "Invalid action, can't add '%s' to '%s', '%s' entity is NULL."; + + private final ErrorCode.ErrorCodeBuilder builder = new ErrorCode.ErrorCodeBuilder(); + + /** + * Instantiates a new Invalid add action null entity error builder. + * + * @param addedData the added data + * @param updatedEntity the updated entity + */ + public InvalidAddActionNullEntityErrorBuilder(String addedData, String updatedEntity) { + builder.withId(ToscaErrorCodes.TOSCA_INVALID_ADD_ACTION_NULL_ENTITY); + builder.withCategory(ErrorCategory.APPLICATION); + builder.withMessage( + String.format(INVALID_ACTION_NULL_ENTITY_ERR_MSG, addedData, updatedEntity, updatedEntity)); + } + + /** + * Build error code. + * + * @return the error code + */ + public ErrorCode build() { + return builder.build(); + } + +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/InvalidRequirementAssignmentErrorBuilder.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/InvalidRequirementAssignmentErrorBuilder.java new file mode 100644 index 0000000000..cc0b821748 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/InvalidRequirementAssignmentErrorBuilder.java @@ -0,0 +1,57 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.errors; + +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; + +/** + * The type Invalid requirement assignment error builder. + */ +public class InvalidRequirementAssignmentErrorBuilder { + + private static final String INVALID_REQ_ASSIGNMENT_ERR_ID = "INVALID_REQ_ASSIGNMENT_ERR_ID"; + private static final String INVALID_REQ_ASSIGNMENT_ERR_MSG = + "Invalid Requirement Assignment, Node value is NULL, Requirement ID '%s'."; + + private final ErrorCode.ErrorCodeBuilder builder = new ErrorCode.ErrorCodeBuilder(); + + /** + * Instantiates a new Invalid requirement assignment error builder. + * + * @param requirementId the requirement id + */ + public InvalidRequirementAssignmentErrorBuilder(String requirementId) { + builder.withId(INVALID_REQ_ASSIGNMENT_ERR_ID); + builder.withCategory(ErrorCategory.APPLICATION); + builder.withMessage(String.format(INVALID_REQ_ASSIGNMENT_ERR_MSG, requirementId)); + } + + /** + * Build error code. + * + * @return the error code + */ + public ErrorCode build() { + return builder.build(); + } + +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/ToscaErrorCodes.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/ToscaErrorCodes.java new file mode 100644 index 0000000000..099f0771f2 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/ToscaErrorCodes.java @@ -0,0 +1,36 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.errors; + +public class ToscaErrorCodes { + + static final String INVALID_SUBSTITUTE_NODE_TEMPLATE = "INVALID_SUBSTITUTE_NODE_TEMPLATE"; + static final String INVALID_SUBSTITUTION_SERVICE_TEMPLATE = + "INVALID_SUBSTITUTION_SERVICE_TEMPLATE"; + static final String TOSCA_ENTRY_NOT_FOUND = "TOSCA_ENTRY_NOT_FOUND"; + static final String MISSING_SUBSTITUTION_MAPPING_FOR_REQ_CAP = + "MISSING_SUBSTITUTION_MAPPING_FOR_REQ_CAP"; + static final String TOSCA_INVALID_SUBSTITUTE_NODE_TEMPLATE = + "TOSCA_INVALID_SUBSTITUTE_NODE_TEMPLATE"; + static final String TOSCA_INVALID_ADD_ACTION_NULL_ENTITY = "TOSCA_INVALID_ADD_ACTION_NULL_ENTITY"; + + +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/ToscaInvalidEntryNotFoundErrorBuilder.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/ToscaInvalidEntryNotFoundErrorBuilder.java new file mode 100644 index 0000000000..7e05d18755 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/ToscaInvalidEntryNotFoundErrorBuilder.java @@ -0,0 +1,55 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.errors; + +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; + +/** + * The type Tosca invalid entry not found error builder. + */ +public class ToscaInvalidEntryNotFoundErrorBuilder { + // + private static final String ENTRY_NOT_FOUND_MSG = + "Invalid Tosca model data, missing '%s' entry for '%s' id %s"; + private final ErrorCode.ErrorCodeBuilder builder = new ErrorCode.ErrorCodeBuilder(); + + /** + * Instantiates a new Tosca invalid entry not found error builder. + * + * @param entryName the entry name + * @param entryId the entry id + */ + public ToscaInvalidEntryNotFoundErrorBuilder(String entryName, String entryId) { + builder.withId(ToscaErrorCodes.TOSCA_ENTRY_NOT_FOUND); + builder.withCategory(ErrorCategory.APPLICATION); + builder.withMessage(String.format(ENTRY_NOT_FOUND_MSG, entryName, entryName, entryId)); + } + + /** + * Build error code. + * + * @return the error code + */ + public ErrorCode build() { + return builder.build(); + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/ToscaInvalidSubstituteNodeTemplateErrorBuilder.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/ToscaInvalidSubstituteNodeTemplateErrorBuilder.java new file mode 100644 index 0000000000..5913e5ffba --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/ToscaInvalidSubstituteNodeTemplateErrorBuilder.java @@ -0,0 +1,55 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.errors; + +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; + + +/** + * The type Tosca invalid substitute node template error builder. + */ +public class ToscaInvalidSubstituteNodeTemplateErrorBuilder { + private static final String INVALID_SUBSTITUTE_NODE_TEMPLATE_MSG = + "Invalid substitute node template, directives with substitutable value must be defined. " + + "node template id %s"; + private final ErrorCode.ErrorCodeBuilder builder = new ErrorCode.ErrorCodeBuilder(); + + /** + * Instantiates a new Tosca invalid substitute node template error builder. + * + * @param nodeTemplateId the node template id + */ + public ToscaInvalidSubstituteNodeTemplateErrorBuilder(String nodeTemplateId) { + builder.withId(ToscaErrorCodes.TOSCA_INVALID_SUBSTITUTE_NODE_TEMPLATE); + builder.withCategory(ErrorCategory.APPLICATION); + builder.withMessage(String.format(INVALID_SUBSTITUTE_NODE_TEMPLATE_MSG, nodeTemplateId)); + } + + /** + * Build error code. + * + * @return the error code + */ + public ErrorCode build() { + return builder.build(); + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/ToscaInvalidSubstituteNodeTemplatePropertiesErrorBuilder.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/ToscaInvalidSubstituteNodeTemplatePropertiesErrorBuilder.java new file mode 100644 index 0000000000..90c681efc9 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/ToscaInvalidSubstituteNodeTemplatePropertiesErrorBuilder.java @@ -0,0 +1,59 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.errors; + +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; +import org.openecomp.sdc.tosca.services.ToscaConstants; + + +/** + * The type Tosca invalid substitute node template properties error builder. + */ +public class ToscaInvalidSubstituteNodeTemplatePropertiesErrorBuilder { + + private static final String INVALID_SUBSTITUTE_NODE_TEMPLATE_MSG = + "Invalid Substitute Node Template %s, mandatory map property %s with mandatory " + + "key %s must be defined."; + private final ErrorCode.ErrorCodeBuilder builder = new ErrorCode.ErrorCodeBuilder(); + + /** + * Instantiates a new Tosca invalid substitute node template properties error builder. + * + * @param nodeTemplateId the node template id + */ + public ToscaInvalidSubstituteNodeTemplatePropertiesErrorBuilder(String nodeTemplateId) { + builder.withId(ToscaErrorCodes.INVALID_SUBSTITUTE_NODE_TEMPLATE); + builder.withCategory(ErrorCategory.APPLICATION); + builder.withMessage(String.format(INVALID_SUBSTITUTE_NODE_TEMPLATE_MSG, nodeTemplateId, + ToscaConstants.SERVICE_TEMPLATE_FILTER_PROPERTY_NAME, + ToscaConstants.SUBSTITUTE_SERVICE_TEMPLATE_PROPERTY_NAME)); + } + + /** + * Build error code. + * + * @return the error code + */ + public ErrorCode build() { + return builder.build(); + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/ToscaInvalidSubstitutionServiceTemplateErrorBuilder.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/ToscaInvalidSubstitutionServiceTemplateErrorBuilder.java new file mode 100644 index 0000000000..c240992597 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/ToscaInvalidSubstitutionServiceTemplateErrorBuilder.java @@ -0,0 +1,57 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.errors; + +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; + + +/** + * The type Tosca invalid substitution service template error builder. + */ +public class ToscaInvalidSubstitutionServiceTemplateErrorBuilder { + + private static final String INVALID_SUBSTITUTION_SERVICE_TEMPLATE_MSG = + "Invalid Substitution Service Template %s, missing mandatory file 'Node type' " + + "in substitution mapping."; + private final ErrorCode.ErrorCodeBuilder builder = new ErrorCode.ErrorCodeBuilder(); + + /** + * Instantiates a new Tosca invalid substitution service template error builder. + * + * @param serviceTemplateFileName the service template file name + */ + public ToscaInvalidSubstitutionServiceTemplateErrorBuilder(String serviceTemplateFileName) { + builder.withId(ToscaErrorCodes.INVALID_SUBSTITUTION_SERVICE_TEMPLATE); + builder.withCategory(ErrorCategory.APPLICATION); + builder.withMessage( + String.format(INVALID_SUBSTITUTION_SERVICE_TEMPLATE_MSG, serviceTemplateFileName)); + } + + /** + * Build error code. + * + * @return the error code + */ + public ErrorCode build() { + return builder.build(); + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/ToscaMissingSubstitutionMappingForReqCapErrorBuilder.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/ToscaMissingSubstitutionMappingForReqCapErrorBuilder.java new file mode 100644 index 0000000000..74392cdcdb --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/ToscaMissingSubstitutionMappingForReqCapErrorBuilder.java @@ -0,0 +1,88 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.errors; + +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; + +/** + * The type Tosca missing substitution mapping for req cap error builder. + */ +public class ToscaMissingSubstitutionMappingForReqCapErrorBuilder { + + private static final String MISSING_SUBSTITUTION_MAPPING_FOR_REQ_CAP_MSG = + "Invalid Substitution, Missing Substitution Mapping for %s with Id %s."; + private final ErrorCode.ErrorCodeBuilder builder = new ErrorCode.ErrorCodeBuilder(); + + /** + * Instantiates a new Tosca missing substitution mapping for req cap error builder. + * + * @param exposedEntry the exposed entry + * @param id the id + */ + public ToscaMissingSubstitutionMappingForReqCapErrorBuilder(MappingExposedEntry exposedEntry, + String id) { + builder.withId(ToscaErrorCodes.MISSING_SUBSTITUTION_MAPPING_FOR_REQ_CAP); + builder.withCategory(ErrorCategory.APPLICATION); + builder.withMessage(String + .format(MISSING_SUBSTITUTION_MAPPING_FOR_REQ_CAP_MSG, exposedEntry.getDisplayName(), id)); + } + + /** + * Build error code. + * + * @return the error code + */ + public ErrorCode build() { + return builder.build(); + } + + /** + * The enum Mapping exposed entry. + */ + public enum MappingExposedEntry { + + /** + * Capability mapping exposed entry. + */ + CAPABILITY("Capability"), + /** + * Requirement mapping exposed entry. + */ + REQUIREMENT("Requirement"),; + + private String displayName; + + MappingExposedEntry(String displayName) { + this.displayName = displayName; + } + + /** + * Gets display name. + * + * @return the display name + */ + public String getDisplayName() { + return displayName; + } + + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/ToscaNodeTypeNotFoundErrorBuilder.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/ToscaNodeTypeNotFoundErrorBuilder.java new file mode 100644 index 0000000000..3d51970d50 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/errors/ToscaNodeTypeNotFoundErrorBuilder.java @@ -0,0 +1,46 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.errors; + +import org.openecomp.sdc.common.errors.ErrorCategory; +import org.openecomp.sdc.common.errors.ErrorCode; + +public class ToscaNodeTypeNotFoundErrorBuilder { + private static final String ENTRY_NOT_FOUND_MSG = + "NodeType '%s' or one of its derivedFrom node type hierarchy, " + + "is not defined in tosca service model"; + private final ErrorCode.ErrorCodeBuilder builder = new ErrorCode.ErrorCodeBuilder(); + + /** + * Instantiates a new Tosca node type not found error builder. + * + * @param nodeType the node type + */ + public ToscaNodeTypeNotFoundErrorBuilder(String nodeType) { + builder.withId(ToscaErrorCodes.TOSCA_ENTRY_NOT_FOUND); + builder.withCategory(ErrorCategory.APPLICATION); + builder.withMessage(String.format(ENTRY_NOT_FOUND_MSG, nodeType)); + } + + public ErrorCode build() { + return builder.build(); + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/exceptions/CsarCreationErrorBuilder.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/exceptions/CsarCreationErrorBuilder.java new file mode 100644 index 0000000000..c7b9bc2da4 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/exceptions/CsarCreationErrorBuilder.java @@ -0,0 +1,43 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.exceptions; + +import org.openecomp.sdc.common.errors.BaseErrorBuilder; +import org.openecomp.sdc.common.errors.ErrorCategory; + +/** + * The type Csar creation error builder. + */ +public class CsarCreationErrorBuilder extends BaseErrorBuilder { + + private static final String MANDATORY_PROPERTY_IS_MISSING_MSG = + "Failed to create CSAR file from ToscaServiceModel"; + private static final String ZIP_FILE_CREATION = "ZIP_FILE_CREATION"; + + /** + * Instantiates a new Csar creation error builder. + */ + public CsarCreationErrorBuilder() { + getErrorCodeBuilder().withId(ZIP_FILE_CREATION); + getErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION); + getErrorCodeBuilder().withMessage(MANDATORY_PROPERTY_IS_MISSING_MSG); + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/exceptions/CsarMissingEntryPointErrorBuilder.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/exceptions/CsarMissingEntryPointErrorBuilder.java new file mode 100644 index 0000000000..9b9257ad33 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/exceptions/CsarMissingEntryPointErrorBuilder.java @@ -0,0 +1,44 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.exceptions; + +import org.openecomp.sdc.common.errors.BaseErrorBuilder; +import org.openecomp.sdc.common.errors.ErrorCategory; + +/** + * The type Csar missing entry point error builder. + */ +public class CsarMissingEntryPointErrorBuilder extends BaseErrorBuilder { + + private static final String MANDATORY_PROPERTY_IS_MISSING_MSG = + "Failed to create CSAR file from ToscaServiceModel,missing mandatory " + + "EntryDefinitionServiceTemplate "; + private static final String ZIP_FILE_CREATION = "ZIP_FILE_CREATION__MISSING_ENTRY_DEFINITION"; + + /** + * Instantiates a new Csar missing entry point error builder. + */ + public CsarMissingEntryPointErrorBuilder() { + getErrorCodeBuilder().withId(ZIP_FILE_CREATION); + getErrorCodeBuilder().withCategory(ErrorCategory.APPLICATION); + getErrorCodeBuilder().withMessage(MANDATORY_PROPERTY_IS_MISSING_MSG); + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/DataModelUtil.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/DataModelUtil.java new file mode 100644 index 0000000000..d0d7ccf621 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/DataModelUtil.java @@ -0,0 +1,588 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.services; + +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.tosca.datatypes.ToscaFunctions; +import org.openecomp.sdc.tosca.datatypes.model.AttributeDefinition; +import org.openecomp.sdc.tosca.datatypes.model.Constraint; +import org.openecomp.sdc.tosca.datatypes.model.EntrySchema; +import org.openecomp.sdc.tosca.datatypes.model.GroupDefinition; +import org.openecomp.sdc.tosca.datatypes.model.Metadata; +import org.openecomp.sdc.tosca.datatypes.model.NodeTemplate; +import org.openecomp.sdc.tosca.datatypes.model.NodeType; +import org.openecomp.sdc.tosca.datatypes.model.PolicyDefinition; +import org.openecomp.sdc.tosca.datatypes.model.PropertyDefinition; +import org.openecomp.sdc.tosca.datatypes.model.RelationshipTemplate; +import org.openecomp.sdc.tosca.datatypes.model.RequirementAssignment; +import org.openecomp.sdc.tosca.datatypes.model.RequirementDefinition; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.datatypes.model.Status; +import org.openecomp.sdc.tosca.datatypes.model.SubstitutionMapping; +import org.openecomp.sdc.tosca.datatypes.model.TopologyTemplate; +import org.openecomp.sdc.tosca.datatypes.model.heatextend.ParameterDefinitionExt; +import org.openecomp.sdc.tosca.errors.InvalidAddActionNullEntityErrorBuilder; +import org.openecomp.sdc.tosca.errors.InvalidRequirementAssignmentErrorBuilder; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.Collections; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.stream.Collectors; + +/** + * The type Data model util. + */ +public class DataModelUtil { + + /** + * Add substitution mapping. + * + * @param serviceTemplate the service template + * @param substitutionMapping the substitution mapping + */ + public static void addSubstitutionMapping(ServiceTemplate serviceTemplate, + SubstitutionMapping substitutionMapping) { + if (serviceTemplate == null) { + throw new CoreException( + new InvalidAddActionNullEntityErrorBuilder("Substitution Mapping", "Service Template") + .build()); + } + + if (serviceTemplate.getTopology_template() == null) { + serviceTemplate.setTopology_template(new TopologyTemplate()); + } + serviceTemplate.getTopology_template().setSubstitution_mappings(substitutionMapping); + } + + /** + * Add substitution mapping req. + * + * @param serviceTemplate the service template + * @param substitutionMappingRequirementId the substitution mapping requirement id + * @param substitutionMappingRequirementList the substitution mapping requirement list + */ + public static void addSubstitutionMappingReq(ServiceTemplate serviceTemplate, + String substitutionMappingRequirementId, + List substitutionMappingRequirementList) { + if (serviceTemplate == null) { + throw new CoreException( + new InvalidAddActionNullEntityErrorBuilder("Substitution Mapping Requirements", + "Service Template").build()); + } + + if (serviceTemplate.getTopology_template() == null) { + serviceTemplate.setTopology_template(new TopologyTemplate()); + } + if (serviceTemplate.getTopology_template().getSubstitution_mappings() == null) { + serviceTemplate.getTopology_template().setSubstitution_mappings(new SubstitutionMapping()); + } + if (serviceTemplate.getTopology_template().getSubstitution_mappings().getRequirements() + == null) { + serviceTemplate.getTopology_template().getSubstitution_mappings() + .setRequirements(new HashMap<>()); + } + + serviceTemplate.getTopology_template().getSubstitution_mappings().getRequirements() + .put(substitutionMappingRequirementId, substitutionMappingRequirementList); + } + + /** + * Add node template. + * + * @param serviceTemplate the service template + * @param nodeTemplateId the node template id + * @param nodeTemplate the node template + */ + public static void addNodeTemplate(ServiceTemplate serviceTemplate, String nodeTemplateId, + NodeTemplate nodeTemplate) { + if (serviceTemplate == null) { + throw new CoreException( + new InvalidAddActionNullEntityErrorBuilder("Node Template", "Service Template").build()); + } + TopologyTemplate topologyTemplate = serviceTemplate.getTopology_template(); + if (Objects.isNull(topologyTemplate)) { + topologyTemplate = new TopologyTemplate(); + serviceTemplate.setTopology_template(topologyTemplate); + } + if (topologyTemplate.getNode_templates() == null) { + topologyTemplate.setNode_templates(new HashMap<>()); + } + topologyTemplate.getNode_templates().put(nodeTemplateId, nodeTemplate); + } + + /** + * Add policy definition. + * + * @param serviceTemplate the service template + * @param policyId the policy id + * @param policyDefinition the policy definition + */ + public static void addPolicyDefinition(ServiceTemplate serviceTemplate, String policyId, + PolicyDefinition policyDefinition) { + if (serviceTemplate == null) { + throw new CoreException( + new InvalidAddActionNullEntityErrorBuilder("Policy Definition", "Service Template") + .build()); + } + TopologyTemplate topologyTemplate = serviceTemplate.getTopology_template(); + if (Objects.isNull(topologyTemplate)) { + topologyTemplate = new TopologyTemplate(); + serviceTemplate.setTopology_template(topologyTemplate); + } + if (topologyTemplate.getPolicies() == null) { + topologyTemplate.setPolicies(new HashMap<>()); + } + topologyTemplate.getPolicies().put(policyId, policyDefinition); + } + + /** + * Add node type. + * + * @param serviceTemplate the service template + * @param nodeTypeId the node type id + * @param nodeType the node type + */ + public static void addNodeType(ServiceTemplate serviceTemplate, String nodeTypeId, + NodeType nodeType) { + if (serviceTemplate == null) { + throw new CoreException( + new InvalidAddActionNullEntityErrorBuilder("Node Type", "Service Template").build()); + } + if (serviceTemplate.getNode_types() == null) { + serviceTemplate.setNode_types(new HashMap<>()); + } + serviceTemplate.getNode_types().put(nodeTypeId, nodeType); + } + + /** + * Add relationship template. + * + * @param serviceTemplate the service template + * @param relationshipTemplateId the relationship template id + * @param relationshipTemplate the relationship template + */ + public static void addRelationshipTemplate(ServiceTemplate serviceTemplate, + String relationshipTemplateId, + RelationshipTemplate relationshipTemplate) { + if (serviceTemplate == null) { + throw new CoreException( + new InvalidAddActionNullEntityErrorBuilder("Relationship Template", "Service Template") + .build()); + } + if (serviceTemplate.getTopology_template() == null) { + serviceTemplate.setTopology_template(new TopologyTemplate()); + } + if (serviceTemplate.getTopology_template().getRelationship_templates() == null) { + serviceTemplate.getTopology_template().setRelationship_templates(new HashMap<>()); + } + serviceTemplate.getTopology_template().getRelationship_templates() + .put(relationshipTemplateId, relationshipTemplate); + } + + /** + * Add requirement assignment. + * + * @param nodeTemplate the node template + * @param requirementId the requirement id + * @param requirementAssignment the requirement assignment + */ + public static void addRequirementAssignment(NodeTemplate nodeTemplate, String requirementId, + RequirementAssignment requirementAssignment) { + if (nodeTemplate == null) { + throw new CoreException( + new InvalidAddActionNullEntityErrorBuilder("Requirement Assignment", "Node Template") + .build()); + } + if (requirementAssignment.getNode() == null) { + throw new CoreException(new InvalidRequirementAssignmentErrorBuilder(requirementId).build()); + } + + if (nodeTemplate.getRequirements() == null) { + nodeTemplate.setRequirements(new ArrayList<>()); + } + Map requirement = new HashMap<>(); + requirement.put(requirementId, requirementAssignment); + nodeTemplate.getRequirements().add(requirement); + } + + /** + * Gets node template. + * + * @param serviceTemplate the service template + * @param nodeTemplateId the node template id + * @return the node template + */ + public static NodeTemplate getNodeTemplate(ServiceTemplate serviceTemplate, + String nodeTemplateId) { + if (serviceTemplate == null + || serviceTemplate.getTopology_template() == null + || serviceTemplate.getTopology_template().getNode_templates() == null) { + return null; + } + return serviceTemplate.getTopology_template().getNode_templates().get(nodeTemplateId); + } + + /** + * Gets node type. + * + * @param serviceTemplate the service template + * @param nodeTypeId the node type id + * @return the node type + */ + public static NodeType getNodeType(ServiceTemplate serviceTemplate, String nodeTypeId) { + if (serviceTemplate == null || serviceTemplate.getNode_types() == null) { + return null; + } + return serviceTemplate.getNode_types().get(nodeTypeId); + } + + /** + * Add group definition to topology template. + * + * @param serviceTemplate the service template + * @param groupName the group name + * @param group the group + */ + public static void addGroupDefinitionToTopologyTemplate(ServiceTemplate serviceTemplate, + String groupName, GroupDefinition group) { + if (serviceTemplate == null) { + throw new CoreException( + new InvalidAddActionNullEntityErrorBuilder("Group Definition", "Service Template") + .build()); + } + + TopologyTemplate topologyTemplate = serviceTemplate.getTopology_template(); + if (Objects.isNull(topologyTemplate)) { + topologyTemplate = new TopologyTemplate(); + serviceTemplate.setTopology_template(topologyTemplate); + } + if (topologyTemplate.getGroups() == null) { + topologyTemplate.setGroups(new HashMap<>()); + } + if (serviceTemplate.getTopology_template().getGroups() == null) { + Map groups = new HashMap<>(); + serviceTemplate.getTopology_template().setGroups(groups); + } + serviceTemplate.getTopology_template().getGroups().put(groupName, group); + } + + /** + * Create property definition property definition. + * + * @param type the type + * @param description the description + * @param required the required + * @param constraints the constraints + * @param status the status + * @param entrySchema the entry schema + * @param defaultVal the default val + * @return the property definition + */ + public static PropertyDefinition createPropertyDefinition(String type, String description, + boolean required, + List constraints, + Status status, + EntrySchema entrySchema, + Object defaultVal) { + PropertyDefinition propDef = new PropertyDefinition(); + propDef.setType(type); + propDef.setDescription(description); + propDef.setRequired(required); + propDef.setConstraints(constraints); + if (status != null) { + propDef.setStatus(status); + } + propDef.setEntry_schema(entrySchema); + propDef.set_default(defaultVal); + + return propDef; + } + + /** + * Create requirement requirement definition. + * + * @param capability the capability + * @param node the node + * @param relationship the relationship + * @param occurrences the occurrences + * @return the requirement definition + */ + public static RequirementDefinition createRequirement(String capability, String node, + String relationship, Object[] occurrences) { + RequirementDefinition requirementDefinition = new RequirementDefinition(); + requirementDefinition.setCapability(capability); + requirementDefinition.setNode(node); + requirementDefinition.setRelationship(relationship); + if (occurrences != null) { + requirementDefinition.setOccurrences(occurrences); + } + return requirementDefinition; + } + + /** + * Create attribute definition attribute definition. + * + * @param type the type + * @param description the description + * @param status the status + * @param entrySchema the entry schema + * @param defaultVal the default val + * @return the attribute definition + */ + public static AttributeDefinition createAttributeDefinition(String type, String description, + Status status, + EntrySchema entrySchema, + Object defaultVal) { + AttributeDefinition attributeDef = new AttributeDefinition(); + attributeDef.setType(type); + + if (description != null) { + attributeDef.setDescription(description); + } + if (status != null) { + attributeDef.setStatus(status); + } + attributeDef.setEntry_schema(entrySchema); + attributeDef.set_default(defaultVal); + + return attributeDef; + } + + /** + * Create valid values constraint constraint. + * + * @param values the values + * @return the constraint + */ + public static Constraint createValidValuesConstraint(Object... values) { + Constraint validValues = new Constraint(); + for (Object value : values) { + validValues.addValidValue(value); + } + return validValues; + } + + /** + * Create metadata metadata. + * + * @param templateName the template name + * @param templateVersion the template version + * @param templateAuthor the template author + * @return the metadata + */ + public static Metadata createMetadata(String templateName, String templateVersion, + String templateAuthor) { + Metadata metadata = new Metadata(); + metadata.setTemplate_name(templateName); + metadata.setTemplate_version(templateVersion); + metadata.setTemplate_author(templateAuthor); + + return metadata; + } + + /** + * Create entry schema entry schema. + * + * @param type the type + * @param description the description + * @param constraints the constraints + * @return the entry schema + */ + public static EntrySchema createEntrySchema(String type, String description, + List constraints) { + EntrySchema entrySchema = new EntrySchema(); + entrySchema.setType(type); + entrySchema.setDescription(description); + entrySchema.setConstraints(constraints); + return entrySchema; + } + + /** + * Create valid values constraints list list. + * + * @param values the values + * @return the list + */ + public static List createValidValuesConstraintsList(String... values) { + List constraints; + Constraint validValues; + constraints = new ArrayList<>(); + validValues = DataModelUtil.createValidValuesConstraint(values); + constraints.add(validValues); + return constraints; + } + + /** + * Create greater or equal constrain constraint. + * + * @param value the value + * @return the constraint + */ + public static Constraint createGreaterOrEqualConstrain(Object value) { + + Constraint constraint = new Constraint(); + constraint.setGreater_or_equal(value); + return constraint; + } + + /** + * Gets constrain list. + * + * @param constrains the constrains + * @return the constrain list + */ + public static List getConstrainList(Constraint... constrains) { + return Arrays.asList(constrains); + + } + + /** + * Create get input property value from list parameter map. + * + * @param inputPropertyListName the input property list name + * @param indexInTheList the index in the list + * @param nestedPropertyName the nested property name + * @return the map + */ + public static Map createGetInputPropertyValueFromListParameter(String inputPropertyListName, + int indexInTheList, + String... nestedPropertyName) { + List propertyList = new ArrayList<>(); + propertyList.add(inputPropertyListName); + propertyList.add(indexInTheList); + if (nestedPropertyName != null) { + Collections.addAll(propertyList, nestedPropertyName); + } + Map getInputProperty = new HashMap<>(); + getInputProperty.put(ToscaFunctions.GET_INPUT.getDisplayName(), propertyList); + return getInputProperty; + } + + /** + * Convert property def to parameter def parameter definition ext. + * + * @param propertyDefinition the property definition + * @return the parameter definition ext + */ + public static ParameterDefinitionExt convertPropertyDefToParameterDef( + PropertyDefinition propertyDefinition) { + if (propertyDefinition == null) { + return null; + } + + ParameterDefinitionExt parameterDefinition = new ParameterDefinitionExt(); + parameterDefinition.setType(propertyDefinition.getType()); + parameterDefinition.setDescription(propertyDefinition.getDescription()); + parameterDefinition.setRequired(propertyDefinition.getRequired()); + parameterDefinition.set_default(propertyDefinition.get_default()); + parameterDefinition.setStatus(propertyDefinition.getStatus()); + parameterDefinition.setConstraints(propertyDefinition.getConstraints()); + parameterDefinition.setEntry_schema(propertyDefinition.getEntry_schema()); + parameterDefinition.setHidden(false); + parameterDefinition.setImmutable(false); + + return parameterDefinition; + } + + /** + * Convert attribute def to parameter def parameter definition ext. + * + * @param attributeDefinition the attribute definition + * @param outputValue the output value + * @return the parameter definition ext + */ + public static ParameterDefinitionExt convertAttributeDefToParameterDef( + AttributeDefinition attributeDefinition, Map outputValue) { + if (attributeDefinition == null) { + return null; + } + ParameterDefinitionExt parameterDefinition = new ParameterDefinitionExt(); + parameterDefinition.setDescription(attributeDefinition.getDescription()); + parameterDefinition.setValue(outputValue); + return parameterDefinition; + } + + /** + * Clone constraints list. + * + * @param constraints the constraints + * @return the list + */ + public static List cloneConstraints(List constraints) { + if (constraints == null) { + return null; + } + return constraints.stream().map(Constraint::clone).collect(Collectors.toList()); + } + + /** + * Clone valid source types list. + * + * @param validSourceTypes the valid source types + * @return the list + */ + public static List cloneValidSourceTypes(List validSourceTypes) { + if (validSourceTypes == null) { + return null; + } + return validSourceTypes.stream().collect(Collectors.toList()); + } + + /** + * Clone property definitions map. + * + * @param propertyDefinitions the property definitions + * @return the map + */ + public static Map clonePropertyDefinitions( + Map propertyDefinitions) { + if (propertyDefinitions == null) { + return null; + } + Map clonedProperties = new HashMap<>(); + for (String propertyKey : propertyDefinitions.keySet()) { + clonedProperties.put(propertyKey, propertyDefinitions.get(propertyKey).clone()); + } + return clonedProperties; + } + + /** + * Clone attribute definitions map. + * + * @param attributeDefinitions the attribute definitions + * @return the map + */ + public static Map cloneAttributeDefinitions( + Map attributeDefinitions) { + if (attributeDefinitions == null) { + return null; + } + Map clonedAttributeDefinitions = new HashMap<>(); + for (String attributeKey : attributeDefinitions.keySet()) { + clonedAttributeDefinitions.put(attributeKey, attributeDefinitions.get(attributeKey).clone()); + } + return clonedAttributeDefinitions; + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/ToscaAnalyzerService.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/ToscaAnalyzerService.java new file mode 100644 index 0000000000..271c471922 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/ToscaAnalyzerService.java @@ -0,0 +1,66 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.services; + +import org.openecomp.sdc.tosca.datatypes.ToscaElementTypes; +import org.openecomp.sdc.tosca.datatypes.ToscaServiceModel; +import org.openecomp.sdc.tosca.datatypes.model.NodeTemplate; +import org.openecomp.sdc.tosca.datatypes.model.RequirementAssignment; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; + +import java.util.List; +import java.util.Map; +import java.util.Optional; + +public interface ToscaAnalyzerService { + + /* + node template with type equal to node type or derived from node type + */ + Map getNodeTemplatesByType(ServiceTemplate serviceTemplate, String nodeType, + ToscaServiceModel toscaServiceModel); + + boolean isTypeOf(NodeTemplate nodeTemplate, String nodeType, ServiceTemplate serviceTemplate, + ToscaServiceModel toscaServiceModel); + + List getRequirements(NodeTemplate nodeTemplate, String requirementId); + + Optional getNodeTemplateById(ServiceTemplate serviceTemplate, + String nodeTemplateId); + + Optional getSubstituteServiceTemplateName(String substituteNodeTemplateId, + NodeTemplate substitutableNodeTemplate); + + Map getSubstitutableNodeTemplates(ServiceTemplate serviceTemplate); + + Optional> getSubstitutionMappedNodeTemplateByExposedReq( + String substituteServiceTemplateFileName, ServiceTemplate substituteServiceTemplate, + String requirementId); + + /* + match only for the input which is not null + */ + boolean isDesiredRequirementAssignment(RequirementAssignment requirementAssignment, + String capability, String node, String relationship); + + Object getFlatEntity(ToscaElementTypes elementType, String type, ServiceTemplate serviceTemplate, + ToscaServiceModel toscaModel); +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/ToscaConstants.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/ToscaConstants.java new file mode 100644 index 0000000000..27cf07e166 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/ToscaConstants.java @@ -0,0 +1,65 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.services; + + +public class ToscaConstants { + + //TOSCA Node Types prefix + public static final String NODES_PREFIX = "org.openecomp.resource.vfc.nodes.heat."; + public static final String NODES_SUBSTITUTION_PREFIX + = "org.openecomp.resource.abstract.nodes.heat."; + + //TOSCA Requirement Ids + public static final String DEPENDS_ON_REQUIREMENT_ID = "dependency"; + public static final String BINDING_REQUIREMENT_ID = "binding"; + public static final String LINK_REQUIREMENT_ID = "link"; + public static final String LOCAL_STORAGE_REQUIREMENT_ID = "local_storage"; + public static final String NETWORK_REQUIREMENT_ID = "network"; + public static final String PORT_REQUIREMENT_ID = "port"; + + //TOSCA Capability Ids + public static final String BINDING_CAPABILITY_ID = "binding"; + public static final String LINK_CAPABILITY_ID = "link"; + public static final String HOST_CAPABILITY_ID = "host"; + public static final String ENDPOINT_CAPABILITY_ID = "endpoint"; + public static final String OS_CAPABILITY_ID = "os"; + public static final String SCALABLE_CAPABILITY_ID = "scalable"; + + //General + public static final String TOSCA_DEFINITIONS_VERSION = "tosca_simple_yaml_1_0_0"; + public static final String MODELABLE_ENTITY_NAME_SELF = "SELF"; + public static final String NODE_TEMPLATE_DIRECTIVE_SUBSTITUTABLE = "substitutable"; + public static final String NATIVE_TYPES_SERVICE_TEMPLATE_NAME = "NativeTypesServiceTemplate"; + public static final String UNBOUNDED = "UNBOUNDED"; + + //properties + public static final String SERVICE_TEMPLATE_FILTER_PROPERTY_NAME = "service_template_filter"; + public static final String SUBSTITUTE_SERVICE_TEMPLATE_PROPERTY_NAME = + "substitute_service_template"; + public static final String COUNT_PROPERTY_NAME = "count"; + public static final String INDEX_VALUE_PROPERTY_NAME = "index_value"; + public static final String SCALING_ENABLED_PROPERTY_NAME = "scaling_enabled"; + + public static final String DHCP_ENABLED_PROPERTY_NAME = "dhcp_enabled"; + + +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/ToscaFileOutputService.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/ToscaFileOutputService.java new file mode 100644 index 0000000000..7ec2fffa2b --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/ToscaFileOutputService.java @@ -0,0 +1,34 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.services; + +import org.openecomp.core.utilities.file.FileContentHandler; +import org.openecomp.sdc.tosca.datatypes.ToscaServiceModel; + +public interface ToscaFileOutputService { + byte[] createOutputFile(ToscaServiceModel toscaServiceModel, + FileContentHandler externalArtifacts); + + String createMetaFile(String entryDefinitionsFileName); + + String getArtifactsFolderName(); + +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/ToscaNativeTypesServiceTemplate.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/ToscaNativeTypesServiceTemplate.java new file mode 100644 index 0000000000..013d761168 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/ToscaNativeTypesServiceTemplate.java @@ -0,0 +1,309 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.services; + +import org.openecomp.sdc.tosca.datatypes.ToscaCapabilityType; +import org.openecomp.sdc.tosca.datatypes.ToscaDataType; +import org.openecomp.sdc.tosca.datatypes.ToscaNodeType; +import org.openecomp.sdc.tosca.datatypes.ToscaRelationshipType; + +import org.openecomp.sdc.tosca.datatypes.model.AttributeDefinition; +import org.openecomp.sdc.tosca.datatypes.model.CapabilityDefinition; +import org.openecomp.sdc.tosca.datatypes.model.InterfaceDefinition; +import org.openecomp.sdc.tosca.datatypes.model.NodeType; +import org.openecomp.sdc.tosca.datatypes.model.PropertyDefinition; +import org.openecomp.sdc.tosca.datatypes.model.PropertyType; +import org.openecomp.sdc.tosca.datatypes.model.RequirementDefinition; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +/** + * The type Tosca native types service template. + */ +public class ToscaNativeTypesServiceTemplate { + /** + * Create service template service template. + * + * @return the service template + */ + public static ServiceTemplate createServiceTemplate() { + ServiceTemplate nativeNodeTypesServiceTemplate = new ServiceTemplate(); + nativeNodeTypesServiceTemplate + .setTosca_definitions_version(ToscaConstants.TOSCA_DEFINITIONS_VERSION); + nativeNodeTypesServiceTemplate.setMetadata(DataModelUtil + .createMetadata(ToscaConstants.NATIVE_TYPES_SERVICE_TEMPLATE_NAME, "1.0.0", null)); + nativeNodeTypesServiceTemplate.setDescription("TOSCA Native Node Types"); + nativeNodeTypesServiceTemplate.setNode_types(createNativeNodeTypes()); + return nativeNodeTypesServiceTemplate; + } + + private static Map createNativeNodeTypes() { + Map nativeNodeTypes = new HashMap<>(); + nativeNodeTypes.put(ToscaNodeType.COMPUTE.getDisplayName(), createToscaNodesComputeNodeType()); + nativeNodeTypes.put(ToscaNodeType.ROOT.getDisplayName(), createToscaNodesRootNodeType()); + nativeNodeTypes + .put(ToscaNodeType.NETWORK_PORT.getDisplayName(), createToscaNodesPortsNodeType()); + nativeNodeTypes + .put(ToscaNodeType.BLOCK_STORAGE.getDisplayName(), createToscaNodesBlockStorageNodeType()); + nativeNodeTypes.put(ToscaNodeType.NETWORK.getDisplayName(), createToscaNodesNetworkNodeType()); + return nativeNodeTypes; + } + + private static NodeType createToscaNodesComputeNodeType() { + NodeType computeNodeType = new NodeType(); + computeNodeType.setDerived_from(ToscaNodeType.ROOT.getDisplayName()); + computeNodeType.setAttributes(createComputeAttributes()); + computeNodeType.setRequirements(createComputeRequirements()); + computeNodeType.setCapabilities(createComputeCapabilities()); + return computeNodeType; + } + + private static NodeType createToscaNodesRootNodeType() { + NodeType computeNodeType = new NodeType(); + computeNodeType.setAttributes(createRootAttributes()); + computeNodeType.setInterfaces(createRootInterfaces()); + return computeNodeType; + } + + private static NodeType createToscaNodesPortsNodeType() { + NodeType computeNodeType = new NodeType(); + computeNodeType.setDerived_from(ToscaNodeType.ROOT.getDisplayName()); + computeNodeType.setProperties(createToscaNodesPortProperties()); + computeNodeType.setRequirements(createToscaNodesPortRequirements()); + return computeNodeType; + } + + private static NodeType createToscaNodesBlockStorageNodeType() { + NodeType computeNodeType = new NodeType(); + computeNodeType.setDerived_from(ToscaNodeType.ROOT.getDisplayName()); + computeNodeType.setProperties(createToscaNodesBlockStorageProperties()); + computeNodeType.setCapabilities(createToscaNodesBlockStorageCapabilities()); + return computeNodeType; + } + + private static NodeType createToscaNodesNetworkNodeType() { + NodeType computeNodeType = new NodeType(); + computeNodeType.setDerived_from(ToscaNodeType.ROOT.getDisplayName()); + computeNodeType.setProperties(createToscaNodesNetworkProperties()); + computeNodeType.setCapabilities(createToscaNodesNetworkCapabilities()); + return computeNodeType; + } + + private static Map createToscaNodesPortProperties() { + Map propertyDefinitionMap = new HashMap<>(); + propertyDefinitionMap.put("ip_address", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), null, false, null, null, + null, null)); + propertyDefinitionMap.put("order", DataModelUtil + .createPropertyDefinition(PropertyType.INTEGER.getDisplayName(), null, true, + DataModelUtil.getConstrainList(DataModelUtil.createGreaterOrEqualConstrain(0)), null, + null, 0)); + propertyDefinitionMap.put("is_default", DataModelUtil + .createPropertyDefinition(PropertyType.BOOLEAN.getDisplayName(), null, false, null, null, + null, false)); + propertyDefinitionMap.put("ip_range_start", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), null, false, null, null, + null, null)); + propertyDefinitionMap.put("ip_range_end", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), null, false, null, null, + null, null)); + return propertyDefinitionMap; + } + + private static Map createToscaNodesBlockStorageProperties() { + Map propertyDefinitionMap = new HashMap<>(); + propertyDefinitionMap.put("size", DataModelUtil + .createPropertyDefinition(PropertyType.SCALAR_UNIT_SIZE.getDisplayName(), null, false, + DataModelUtil.getConstrainList(DataModelUtil.createGreaterOrEqualConstrain("1 MB")), + null, null, null)); + propertyDefinitionMap.put("volume_id", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), null, false, null, null, + null, null)); + propertyDefinitionMap.put("snapshot_id", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), null, false, null, null, + null, null)); + return propertyDefinitionMap; + } + + private static Map createToscaNodesNetworkProperties() { + Map propertyDefinitionMap = new HashMap<>(); + propertyDefinitionMap.put("ip_version", DataModelUtil + .createPropertyDefinition(PropertyType.INTEGER.getDisplayName(), null, false, + DataModelUtil.getConstrainList(DataModelUtil.createValidValuesConstraint(4, 6)), null, + null, 4)); + propertyDefinitionMap.put("cidr", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), null, false, null, null, + null, null)); + propertyDefinitionMap.put("start_ip", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), null, false, null, null, + null, null)); + propertyDefinitionMap.put("end_ip", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), null, false, null, null, + null, null)); + propertyDefinitionMap.put("gateway_ip", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), null, false, null, null, + null, null)); + propertyDefinitionMap.put("network_name", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), null, false, null, null, + null, null)); + propertyDefinitionMap.put("network_id", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), null, false, null, null, + null, null)); + propertyDefinitionMap.put("segmentation_id", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), null, false, null, null, + null, null)); + propertyDefinitionMap.put("network_type", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), null, false, null, null, + null, null)); + propertyDefinitionMap.put("physical_network", DataModelUtil + .createPropertyDefinition(PropertyType.STRING.getDisplayName(), null, false, null, null, + null, null)); + propertyDefinitionMap.put("dhcp_enabled", DataModelUtil + .createPropertyDefinition(PropertyType.BOOLEAN.getDisplayName(), null, false, null, null, + null, true)); + + return propertyDefinitionMap; + } + + private static Map createRootInterfaces() { + return new HashMap<>(); + } + + private static Map createComputeCapabilities() { + Map computeCapabilities = new HashMap<>(); + computeCapabilities.put(ToscaConstants.HOST_CAPABILITY_ID, + createCapabilityDefinition(ToscaCapabilityType.CONTAINER.getDisplayName(), + createValidSourceTypes("tosca.nodes.SoftwareComponent"))); + computeCapabilities.put(ToscaConstants.ENDPOINT_CAPABILITY_ID, + createCapabilityDefinition(ToscaCapabilityType.ENDPOINT_ADMIN.getDisplayName(), null)); + computeCapabilities.put(ToscaConstants.OS_CAPABILITY_ID, + createCapabilityDefinition(ToscaCapabilityType.OPERATING_SYSTEM.getDisplayName(), null)); + computeCapabilities.put(ToscaConstants.SCALABLE_CAPABILITY_ID, + createCapabilityDefinition(ToscaCapabilityType.SCALABLE.getDisplayName(), null)); + computeCapabilities.put(ToscaConstants.BINDING_CAPABILITY_ID, + createCapabilityDefinition(ToscaCapabilityType.NETWORK_BINDABLE.getDisplayName(), null)); + return computeCapabilities; + } + + private static Map createToscaNodesBlockStorageCapabilities() { + Map computeCapabilities = new HashMap<>(); + computeCapabilities.put("attachment", + createCapabilityDefinition(ToscaCapabilityType.ATTACHMENT.getDisplayName(), null)); + return computeCapabilities; + } + + private static Map createToscaNodesNetworkCapabilities() { + Map computeCapabilities = new HashMap<>(); + computeCapabilities.put(ToscaConstants.LINK_CAPABILITY_ID, + createCapabilityDefinition(ToscaCapabilityType.NETWORK_LINKABLE.getDisplayName(), null)); + return computeCapabilities; + } + + private static List createValidSourceTypes(String... validSourceTypes) { + return Arrays.asList(validSourceTypes); + } + + private static CapabilityDefinition createCapabilityDefinition(String type, + List validSourceTypes) { + CapabilityDefinition capabilityDefinition = new CapabilityDefinition(); + capabilityDefinition.setType(type); + capabilityDefinition.setValid_source_types(validSourceTypes); + return capabilityDefinition; + } + + private static List> createComputeRequirements() { + List> computeRequirementList = new ArrayList<>(); + Map localStorageRequirement = new HashMap<>(); + localStorageRequirement.put("local_storage", DataModelUtil + .createRequirement(ToscaCapabilityType.ATTACHMENT.getDisplayName(), + ToscaNodeType.BLOCK_STORAGE.getDisplayName(), + ToscaRelationshipType.NATIVE_ATTACHES_TO.getDisplayName(), + createOccurrences(0, ToscaConstants.UNBOUNDED))); + computeRequirementList.add(localStorageRequirement); + return computeRequirementList; + } + + private static List> createToscaNodesPortRequirements() { + List> requirements = new ArrayList<>(); + + Map linkRequirement = new HashMap<>(); + linkRequirement.put(ToscaConstants.LINK_REQUIREMENT_ID, DataModelUtil + .createRequirement(ToscaCapabilityType.NETWORK_LINKABLE.getDisplayName(), + ToscaNodeType.ROOT.getDisplayName(), + ToscaRelationshipType.NETWORK_LINK_TO.getDisplayName(), null)); + requirements.add(linkRequirement); + + Map bindingRequirement = new HashMap<>(); + bindingRequirement.put(ToscaConstants.BINDING_REQUIREMENT_ID, DataModelUtil + .createRequirement(ToscaCapabilityType.NETWORK_BINDABLE.getDisplayName(), + ToscaNodeType.ROOT.getDisplayName(), + ToscaRelationshipType.NETWORK_BINDS_TO.getDisplayName(), null)); + requirements.add(bindingRequirement); + + return requirements; + } + + + private static Object[] createOccurrences(Object min, Object max) { + return new Object[]{min, max}; + + } + + private static Map createComputeAttributes() { + Map computeAttributesDefMap = new HashMap<>(); + computeAttributesDefMap.put("private_address", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), "private address", null, + null, null)); + computeAttributesDefMap.put("public_address", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), "public_address", null, + null, null)); + computeAttributesDefMap.put("networks", DataModelUtil + .createAttributeDefinition(PropertyType.MAP.getDisplayName(), "networks", null, + DataModelUtil + .createEntrySchema(ToscaDataType.NETWORK_NETWORK_INFO.getDisplayName(), null, null), + null)); + computeAttributesDefMap.put("ports", DataModelUtil + .createAttributeDefinition(PropertyType.MAP.getDisplayName(), "ports", null, DataModelUtil + .createEntrySchema(ToscaDataType.NETWORK_PORT_INFO.getDisplayName(), null, null), + null)); + return computeAttributesDefMap; + } + + private static Map createRootAttributes() { + Map attributesDefMap = new HashMap<>(); + attributesDefMap.put("tosca_id", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), "tosca id", null, null, + null)); + attributesDefMap.put("tosca_name", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), "tosca name", null, null, + null)); + attributesDefMap.put("state", DataModelUtil + .createAttributeDefinition(PropertyType.STRING.getDisplayName(), "state", null, null, + null)); + return attributesDefMap; + } + +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/ToscaUtil.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/ToscaUtil.java new file mode 100644 index 0000000000..4f9c70267d --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/ToscaUtil.java @@ -0,0 +1,151 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.services; + +import org.openecomp.sdc.tosca.datatypes.ToscaServiceModel; +import org.openecomp.sdc.tosca.datatypes.model.CapabilityDefinition; +import org.openecomp.sdc.tosca.datatypes.model.CapabilityType; +import org.openecomp.sdc.tosca.datatypes.model.NodeType; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.Set; +import java.util.UUID; + +/** + * The type Tosca util. + */ +public class ToscaUtil { + + /** + * Gets service template file name. + * + * @param serviceTemplate the service template + * @return the service template file name + */ + public static String getServiceTemplateFileName(ServiceTemplate serviceTemplate) { + if (serviceTemplate == null) { + return null; + } + if (serviceTemplate.getMetadata() == null) { + return UUID.randomUUID().toString() + "ServiceTemplate.yaml"; + } + return getServiceTemplateFileName(serviceTemplate.getMetadata().getTemplate_name()); + } + + /** + * Gets service template file name. + * + * @param templateName the template name + * @return the service template file name + */ + public static String getServiceTemplateFileName(String templateName) { + return (Objects.isNull(templateName) ? UUID.randomUUID().toString() : templateName) + + "ServiceTemplate.yaml"; + } + + /** + * Add service template to map with key file name. + * + * @param serviceTemplates the service templates + * @param commonServiceTemplate the common service template + */ + public static void addServiceTemplateToMapWithKeyFileName( + Map serviceTemplates, ServiceTemplate commonServiceTemplate) { + serviceTemplates + .put(ToscaUtil.getServiceTemplateFileName(commonServiceTemplate), commonServiceTemplate); + } + + /** + * Convert type to definition capability definition. + * + * @param type the type + * @param capabilityType the capability type + * @param properties the properties + * @param description the description + * @return the capability definition + */ + public static CapabilityDefinition convertTypeToDefinition(String type, + CapabilityType capabilityType, + Map properties, + String description) { + CapabilityDefinition capabilityDefinition = new CapabilityDefinition(); + capabilityDefinition.setAttributes(capabilityType.getAttributes()); + capabilityDefinition.setProperties(capabilityType.getProperties()); + if (description == null) { + capabilityDefinition.setDescription(capabilityType.getDescription()); + } else { + capabilityDefinition.setDescription(description); + } + capabilityDefinition.setType(type); + + capabilityDefinition.getProperties() + .entrySet() + .stream() + .filter(entry -> properties.containsKey(entry.getKey())) + .forEach(entry -> entry.getValue() + .set_default(properties.get(entry.getKey()))); + + + return capabilityDefinition; + + } + + /** + * Normalize component name node type map. + * + * @param toscaModel the tosca model + * @param components the components + * @return the map + */ + public static Map> normalizeComponentNameNodeType( + ToscaServiceModel toscaModel, Set components) { + + Map> normalizedData = new HashMap<>(); + toscaModel + .getServiceTemplates() + .entrySet().stream().filter(entry -> entry + .getValue() + .getNode_types() != null) + .forEach(entry -> entry + .getValue() + .getNode_types() + .entrySet().stream() + .filter(nodeTypeEntry -> components + .contains(nodeTypeEntry + .getKey())) + .forEach(nodeTypeEntry -> addNodeType(nodeTypeEntry.getKey(), nodeTypeEntry.getValue(), + normalizedData))); + return normalizedData; + } + + private static void addNodeType(String key, NodeType value, + Map> normalizedData) { + if (!normalizedData.containsKey(key)) { + normalizedData.put(key, new ArrayList<>()); + } + normalizedData.get(key).add(value); + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/impl/ToscaAnalyzerServiceImpl.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/impl/ToscaAnalyzerServiceImpl.java new file mode 100644 index 0000000000..a11bff4b6a --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/impl/ToscaAnalyzerServiceImpl.java @@ -0,0 +1,467 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.services.impl; + +import org.apache.commons.collections4.CollectionUtils; +import org.apache.commons.collections4.MapUtils; +import org.openecomp.core.utilities.CommonMethods; +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.tosca.datatypes.ToscaCapabilityType; +import org.openecomp.sdc.tosca.datatypes.ToscaElementTypes; +import org.openecomp.sdc.tosca.datatypes.ToscaNodeType; +import org.openecomp.sdc.tosca.datatypes.ToscaServiceModel; +import org.openecomp.sdc.tosca.datatypes.model.CapabilityType; +import org.openecomp.sdc.tosca.datatypes.model.Import; +import org.openecomp.sdc.tosca.datatypes.model.NodeTemplate; +import org.openecomp.sdc.tosca.datatypes.model.NodeType; +import org.openecomp.sdc.tosca.datatypes.model.RequirementAssignment; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.errors.ToscaInvalidEntryNotFoundErrorBuilder; +import org.openecomp.sdc.tosca.errors.ToscaInvalidSubstituteNodeTemplatePropertiesErrorBuilder; +import org.openecomp.sdc.tosca.errors.ToscaInvalidSubstitutionServiceTemplateErrorBuilder; +import org.openecomp.sdc.tosca.errors.ToscaNodeTypeNotFoundErrorBuilder; +import org.openecomp.sdc.tosca.services.ToscaAnalyzerService; +import org.openecomp.sdc.tosca.services.ToscaConstants; +import org.openecomp.sdc.tosca.services.yamlutil.ToscaExtensionYamlUtil; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; + +public class ToscaAnalyzerServiceImpl implements ToscaAnalyzerService { + /* + node template with type equal to node type or derived from node type. + */ + @Override + public Map getNodeTemplatesByType(ServiceTemplate serviceTemplate, + String nodeType, + ToscaServiceModel toscaServiceModel) { + Map nodeTemplates = new HashMap<>(); + + if (Objects.nonNull(serviceTemplate.getTopology_template()) + && MapUtils.isNotEmpty(serviceTemplate.getTopology_template().getNode_templates())) { + for (Map.Entry nodeTemplateEntry : serviceTemplate + .getTopology_template().getNode_templates().entrySet()) { + if (isTypeOf(nodeTemplateEntry.getValue(), nodeType, serviceTemplate, toscaServiceModel)) { + nodeTemplates.put(nodeTemplateEntry.getKey(), nodeTemplateEntry.getValue()); + } + + } + } + return nodeTemplates; + } + + @Override + public boolean isTypeOf(NodeTemplate nodeTemplate, String nodeType, + ServiceTemplate serviceTemplate, ToscaServiceModel toscaServiceModel) { + if (nodeTemplate == null) { + return false; + } + + if (isNodeTemplateOfTypeNodeType(nodeTemplate, nodeType)) { + return true; + } + + Optional nodeTypeExistInServiceTemplateHierarchy = + isNodeTypeExistInServiceTemplateHierarchy(nodeType, nodeTemplate.getType(), serviceTemplate, + toscaServiceModel, null); + return nodeTypeExistInServiceTemplateHierarchy.orElseThrow(() -> new CoreException( + new ToscaNodeTypeNotFoundErrorBuilder(nodeTemplate.getType()).build())); + } + + + private Optional isNodeTypeExistInServiceTemplateHierarchy(String nodeTypeToMatch, + String nodeTypeToSearch, + ServiceTemplate serviceTemplate, + ToscaServiceModel toscaServiceModel, + Set analyzedImportFiles) { + Map searchableNodeTypes = serviceTemplate.getNode_types(); + if (!MapUtils.isEmpty(searchableNodeTypes)) { + NodeType nodeType = searchableNodeTypes.get(nodeTypeToSearch); + if (Objects.nonNull(nodeType)) { + if (Objects.equals(nodeType.getDerived_from(), nodeTypeToMatch)) { + return Optional.of(true); + } else if (isNodeTypeIsToscaRoot(nodeType)) { + return Optional.of(false); + } else { + return isNodeTypeExistInServiceTemplateHierarchy(nodeTypeToMatch, + nodeType.getDerived_from(), serviceTemplate, toscaServiceModel, null); + } + } else { + return isNodeTypeExistInImports(nodeTypeToMatch, nodeTypeToSearch, serviceTemplate, + toscaServiceModel, analyzedImportFiles); + } + } + return isNodeTypeExistInImports(nodeTypeToMatch, nodeTypeToSearch, serviceTemplate, + toscaServiceModel, analyzedImportFiles); + + } + + private Optional isNodeTypeExistInImports(String nodeTypeToMatch, + String nodeTypeToSearch, + ServiceTemplate serviceTemplate, + ToscaServiceModel toscaServiceModel, + Set analyzedImportFiles) { + Map imports = serviceTemplate.getImports(); + if (imports == null) { + return Optional.empty(); + } + + analyzedImportFiles = createAnalyzedImportFilesSet(analyzedImportFiles); + for (Import anImport : imports.values()) { + if (Objects.isNull(anImport) || Objects.isNull(anImport.getFile())) { + throw new RuntimeException("import without file entry"); + } + String importFile = anImport.getFile(); + if (analyzedImportFiles.contains(importFile)) { + continue; + } + addImportFileToAnalyzedImportFilesSet(analyzedImportFiles, importFile); + ServiceTemplate template = toscaServiceModel.getServiceTemplates().get(importFile); + Optional nodeTypeExistInServiceTemplateHierarchy = + isNodeTypeExistInServiceTemplateHierarchy(nodeTypeToMatch, nodeTypeToSearch, template, + toscaServiceModel, analyzedImportFiles); + if (nodeTypeExistInServiceTemplateHierarchy.isPresent()) { + if (nodeTypeExistInServiceTemplateHierarchy.get()) { + return Optional.of(true); + } + } + } + return Optional.of(false); + } + + private Set addImportFileToAnalyzedImportFilesSet(Set analyzedImportFiles, + String importFile) { + analyzedImportFiles.add(importFile); + return analyzedImportFiles; + } + + private Set createAnalyzedImportFilesSet(Set analyzedImportFiles) { + if (Objects.isNull(analyzedImportFiles)) { + analyzedImportFiles = new HashSet<>(); + } + return analyzedImportFiles; + } + + private boolean isNodeTypeIsToscaRoot(NodeType stNodeType) { + return Objects.equals(stNodeType.getDerived_from(), ToscaNodeType.ROOT.getDisplayName()); + } + + private boolean isNodeTemplateOfTypeNodeType(NodeTemplate nodeTemplate, String nodeType) { + return Objects.equals(nodeTemplate.getType(), nodeType); + } + + @Override + public List getRequirements(NodeTemplate nodeTemplate, + String requirementId) { + List requirements = new ArrayList<>(); + List> requirementList = nodeTemplate.getRequirements(); + if (requirementList != null) { + requirementList.stream().filter(reqMap -> reqMap.get(requirementId) != null) + .forEach(reqMap -> { + ToscaExtensionYamlUtil toscaExtensionYamlUtil = new ToscaExtensionYamlUtil(); + RequirementAssignment reqAssignment = toscaExtensionYamlUtil + .yamlToObject(toscaExtensionYamlUtil.objectToYaml(reqMap.get(requirementId)), + RequirementAssignment.class); + requirements.add(reqAssignment); + }); + } + return requirements; + } + + @Override + public Optional getNodeTemplateById(ServiceTemplate serviceTemplate, + String nodeTemplateId) { + if ((serviceTemplate.getTopology_template() != null) + && (serviceTemplate.getTopology_template().getNode_templates() != null) + && (serviceTemplate.getTopology_template().getNode_templates() + .get(nodeTemplateId) != null)) { + return Optional + .of(serviceTemplate.getTopology_template().getNode_templates().get(nodeTemplateId)); + } + return Optional.empty(); + } + + @Override + public Optional getSubstituteServiceTemplateName(String substituteNodeTemplateId, + NodeTemplate substitutableNodeTemplate) { + if (!isSubstitutableNodeTemplate(substitutableNodeTemplate)) { + return Optional.empty(); + } + + if (substitutableNodeTemplate.getProperties() != null + && substitutableNodeTemplate.getProperties() + .get(ToscaConstants.SERVICE_TEMPLATE_FILTER_PROPERTY_NAME) != null) { + Object serviceTemplateFilter = substitutableNodeTemplate.getProperties() + .get(ToscaConstants.SERVICE_TEMPLATE_FILTER_PROPERTY_NAME); + if (serviceTemplateFilter != null && serviceTemplateFilter instanceof Map) { + Object substituteServiceTemplate = ((Map) serviceTemplateFilter) + .get(ToscaConstants.SUBSTITUTE_SERVICE_TEMPLATE_PROPERTY_NAME); + if (substituteServiceTemplate == null) { + throw new CoreException( + new ToscaInvalidSubstituteNodeTemplatePropertiesErrorBuilder(substituteNodeTemplateId) + .build()); + } + return Optional.of(substituteServiceTemplate.toString()); + } + } + throw new CoreException( + new ToscaInvalidSubstituteNodeTemplatePropertiesErrorBuilder(substituteNodeTemplateId) + .build()); + } + + @Override + public Map getSubstitutableNodeTemplates(ServiceTemplate serviceTemplate) { + Map substitutableNodeTemplates = new HashMap<>(); + + if (serviceTemplate == null + || serviceTemplate.getTopology_template() == null + || serviceTemplate.getTopology_template().getNode_templates() == null) { + return substitutableNodeTemplates; + } + + Map nodeTemplates = + serviceTemplate.getTopology_template().getNode_templates(); + for (String nodeTemplateId : nodeTemplates.keySet()) { + NodeTemplate nodeTemplate = nodeTemplates.get(nodeTemplateId); + if (isSubstitutableNodeTemplate(nodeTemplate)) { + substitutableNodeTemplates.put(nodeTemplateId, nodeTemplate); + } + } + + return substitutableNodeTemplates; + } + + private boolean isSubstitutableNodeTemplate(NodeTemplate nodeTemplate) { + return nodeTemplate.getDirectives() != null + && nodeTemplate.getDirectives().contains(ToscaConstants + .NODE_TEMPLATE_DIRECTIVE_SUBSTITUTABLE); + } + + private boolean isSubstitutionServiceTemplate(String substituteServiceTemplateFileName, + ServiceTemplate substituteServiceTemplate) { + if (substituteServiceTemplate != null + && substituteServiceTemplate.getTopology_template() != null + && substituteServiceTemplate.getTopology_template().getSubstitution_mappings() != null) { + if (substituteServiceTemplate.getTopology_template().getSubstitution_mappings() + .getNode_type() == null) { + throw new CoreException(new ToscaInvalidSubstitutionServiceTemplateErrorBuilder( + substituteServiceTemplateFileName).build()); + } + return true; + } + return false; + + } + + @Override + public Optional> getSubstitutionMappedNodeTemplateByExposedReq( + String substituteServiceTemplateFileName, ServiceTemplate substituteServiceTemplate, + String requirementId) { + if (isSubstitutionServiceTemplate(substituteServiceTemplateFileName, + substituteServiceTemplate)) { + Map> substitutionMappingRequirements = + substituteServiceTemplate.getTopology_template().getSubstitution_mappings() + .getRequirements(); + if (substitutionMappingRequirements != null) { + List requirementMapping = substitutionMappingRequirements.get(requirementId); + if (requirementMapping != null && !requirementMapping.isEmpty()) { + String mappedNodeTemplateId = requirementMapping.get(0); + Optional mappedNodeTemplate = + getNodeTemplateById(substituteServiceTemplate, mappedNodeTemplateId); + mappedNodeTemplate.orElseThrow(() -> new CoreException( + new ToscaInvalidEntryNotFoundErrorBuilder("Node Template", mappedNodeTemplateId) + .build())); + Map.Entry mappedNodeTemplateEntry = + new Map.Entry() { + @Override + public String getKey() { + return mappedNodeTemplateId; + } + + @Override + public NodeTemplate getValue() { + return mappedNodeTemplate.get(); + } + + @Override + public NodeTemplate setValue(NodeTemplate value) { + return null; + } + }; + return Optional.of(mappedNodeTemplateEntry); + } + } + } + return Optional.empty(); + } + + + /* + match only for the input which is not null + */ + @Override + public boolean isDesiredRequirementAssignment(RequirementAssignment requirementAssignment, + String capability, String node, + String relationship) { + if (capability != null) { + if (requirementAssignment.getCapability() == null + || !requirementAssignment.getCapability().equals(capability)) { + return false; + } + } + + if (node != null) { + if (requirementAssignment.getNode() == null + || !requirementAssignment.getNode().equals(node)) { + return false; + } + } + + if (relationship != null) { + if (requirementAssignment.getRelationship() == null + || !requirementAssignment.getRelationship().equals(relationship)) { + return false; + } + } + + return !(capability == null && node == null && relationship == null); + + } + + @Override + public Object getFlatEntity(ToscaElementTypes elementType, String typeId, + ServiceTemplate serviceTemplate, ToscaServiceModel toscaModel) { + Object returnEntity; + + switch (elementType) { + case CAPABILITY_TYPE: + returnEntity = new CapabilityType(); + break; + default: + throw new RuntimeException( + "Entity[" + elementType + "] id[" + typeId + "] flat not supported"); + } + + scanAnFlatEntity(elementType, typeId, returnEntity, serviceTemplate, toscaModel); + + + return returnEntity; + } + + private void scanAnFlatEntity(ToscaElementTypes elementType, String typeId, Object entity, + ServiceTemplate serviceTemplate, ToscaServiceModel toscaModel) { + + + boolean entityFound = + enrichEntityFromCurrentServiceTemplate(elementType, typeId, entity, serviceTemplate, + toscaModel); + if (!entityFound) { + Map imports = serviceTemplate.getImports(); + if (MapUtils.isEmpty(imports)) { + return; + } + for (Import importServiceTemplate : imports.values()) { + ServiceTemplate template = + toscaModel.getServiceTemplates().get(importServiceTemplate.getFile()); + scanAnFlatEntity(elementType, typeId, entity, template, toscaModel); + } + } + + + } + + private boolean enrichEntityFromCurrentServiceTemplate(ToscaElementTypes elementType, + String typeId, Object entity, + ServiceTemplate serviceTemplate, + ToscaServiceModel toscaModel) { + String derivedFrom; + switch (elementType) { + case CAPABILITY_TYPE: + if (serviceTemplate.getCapability_types() != null + && serviceTemplate.getCapability_types().containsKey(typeId)) { + + CapabilityType targetCapabilityType = ((CapabilityType) entity); + CapabilityType sourceCapabilityType = serviceTemplate.getCapability_types().get(typeId); + derivedFrom = sourceCapabilityType.getDerived_from(); + if (derivedFrom != null + && !ToscaCapabilityType.NFV_METRIC.getDisplayName().equals(derivedFrom)) { + scanAnFlatEntity(elementType, derivedFrom, entity, serviceTemplate, toscaModel); + } + combineCapabilityTypeInfo(sourceCapabilityType, targetCapabilityType); + } else { + return false; + } + break; + default: + throw new RuntimeException( + "Entity[" + elementType + "] id[" + typeId + "] flat not supported"); + } + + return true; + + + } + + private void combineCapabilityTypeInfo(CapabilityType sourceCapabilityType, + CapabilityType targetCapabilityType) { + if (MapUtils.isNotEmpty(sourceCapabilityType.getAttributes())) { + if (targetCapabilityType.getAttributes() == null) { + targetCapabilityType.setAttributes(new HashMap<>()); + } + targetCapabilityType.getAttributes().putAll(sourceCapabilityType.getAttributes()); + } + + if (MapUtils.isNotEmpty(sourceCapabilityType.getProperties())) { + if (targetCapabilityType.getProperties() == null) { + targetCapabilityType.setProperties(new HashMap<>()); + } + targetCapabilityType.getProperties().putAll(sourceCapabilityType.getProperties()); + } + + if (CollectionUtils.isNotEmpty(sourceCapabilityType.getValid_source_types())) { + if (targetCapabilityType.getValid_source_types() == null) { + targetCapabilityType.setValid_source_types(new ArrayList<>()); + } + targetCapabilityType.getValid_source_types() + .addAll(sourceCapabilityType.getValid_source_types()); + } + + if (CommonMethods.isEmpty(sourceCapabilityType.getDerived_from())) { + targetCapabilityType.setDerived_from(sourceCapabilityType.getDerived_from()); + } + if (CommonMethods.isEmpty(sourceCapabilityType.getDescription())) { + targetCapabilityType.setDescription(sourceCapabilityType.getDescription()); + } + if (CommonMethods.isEmpty(sourceCapabilityType.getVersion())) { + targetCapabilityType.setVersion(sourceCapabilityType.getVersion()); + } + + + } + + +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/impl/ToscaFileOutputServiceCsarImpl.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/impl/ToscaFileOutputServiceCsarImpl.java new file mode 100644 index 0000000000..d4c22f105f --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/impl/ToscaFileOutputServiceCsarImpl.java @@ -0,0 +1,158 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.services.impl; + +import org.openecomp.core.utilities.file.FileContentHandler; +import org.openecomp.core.utilities.file.FileUtils; +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.tosca.datatypes.ToscaServiceModel; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.exceptions.CsarCreationErrorBuilder; +import org.openecomp.sdc.tosca.exceptions.CsarMissingEntryPointErrorBuilder; +import org.openecomp.sdc.tosca.services.ToscaFileOutputService; + +import java.io.BufferedOutputStream; +import java.io.ByteArrayInputStream; +import java.io.ByteArrayOutputStream; +import java.io.File; +import java.io.IOException; +import java.io.InputStream; +import java.util.Map; +import java.util.zip.ZipEntry; +import java.util.zip.ZipOutputStream; + +public class ToscaFileOutputServiceCsarImpl implements ToscaFileOutputService { + static final String EXTERNAL_ARTIFACTS_FOLDER_NAME = "Artifacts"; + private static final String DEFINITIONS_FOLDER_NAME = "Definitions"; + private static final String ARTIFACTS_FOLDER_NAME = "Artifacts"; + //todo currently duplicated, to be changed when external artifacts are separated from internal + private static final String TOSCA_META_FOLDER_NAME = "TOSCA-Metadata"; + private static final String TOSCA_META_FILE_VERSION = "TOSCA-Meta-File-Version"; + private static final String TOSCA_META_FILE_VERSION_VALUE = "1.0"; + private static final String TOSCA_META_FILE_NAME = "TOSCA.meta"; + private static final String CSAR_VERSION = "CSAR-Version"; + private static final String CSAR_VERSION_VALUE = "1.1"; + private static final String CREATED_BY = "Created-By"; + private static final String CREATED_BY_VALUE = "ASDC Onboarding portal"; + private static final String ENTRY_DEFINITIONS = "Entry-Definitions"; + private static final String META_FILE_DELIMITER = ":"; + private static final String SPACE = " "; + private static final String FILE_SEPARATOR = File.separator; + + @Override + public byte[] createOutputFile(ToscaServiceModel toscaServiceModel, + FileContentHandler externalArtifacts) { + ByteArrayOutputStream baos = new ByteArrayOutputStream(); + try (ZipOutputStream zos = new ZipOutputStream(new BufferedOutputStream(baos))) { + packDefinitions(zos, toscaServiceModel.getServiceTemplates()); + FileContentHandler artifactFiles = toscaServiceModel.getArtifactFiles(); + if (artifactFiles != null && !artifactFiles.isEmpty()) { + packArtifacts(zos, artifactFiles); + } + if (toscaServiceModel.getEntryDefinitionServiceTemplate() == null) { + throw new CoreException(new CsarMissingEntryPointErrorBuilder().build()); + } + createAndPackToscaMetaFile(zos, toscaServiceModel.getEntryDefinitionServiceTemplate()); + if (externalArtifacts != null) { + packExternalArtifacts(zos, externalArtifacts); + } + } catch (IOException exc) { + throw new CoreException(new CsarCreationErrorBuilder().build(), exc); + } + return baos.toByteArray(); + } + + @Override + public String createMetaFile(String entryDefinitionsFileName) { + return TOSCA_META_FILE_VERSION + META_FILE_DELIMITER + SPACE + TOSCA_META_FILE_VERSION_VALUE + + System.lineSeparator() + + CSAR_VERSION + META_FILE_DELIMITER + SPACE + CSAR_VERSION_VALUE + System.lineSeparator() + + CREATED_BY + META_FILE_DELIMITER + SPACE + CREATED_BY_VALUE + System.lineSeparator() + + ENTRY_DEFINITIONS + META_FILE_DELIMITER + SPACE + DEFINITIONS_FOLDER_NAME + + FILE_SEPARATOR + entryDefinitionsFileName; + } + + @Override + public String getArtifactsFolderName() { + return ARTIFACTS_FOLDER_NAME; + } + + private void createAndPackToscaMetaFile(ZipOutputStream zos, String entryDefinitionsFileName) + throws IOException { + String metaFile = createMetaFile(entryDefinitionsFileName); + zos.putNextEntry( + new ZipEntry((TOSCA_META_FOLDER_NAME + FILE_SEPARATOR + TOSCA_META_FILE_NAME))); + writeBytesToZip(zos, new ByteArrayInputStream(metaFile.getBytes())); + } + + private void packDefinitions(ZipOutputStream zos, Map serviceTemplates) + throws IOException { + for (Map.Entry serviceTemplate : serviceTemplates.entrySet()) { + String fileName = serviceTemplate.getKey(); + zos.putNextEntry(new ZipEntry(DEFINITIONS_FOLDER_NAME + FILE_SEPARATOR + fileName)); + writeBytesToZip(zos, + FileUtils.convertToInputStream(serviceTemplate.getValue(), FileUtils.FileExtension.YAML)); + } + } + + private void packExternalArtifacts(ZipOutputStream zos, FileContentHandler externalArtifacts) { + + for (String filenameIncludingPath : externalArtifacts.getFileList()) { + try { + zos.putNextEntry(new ZipEntry(filenameIncludingPath)); + writeBytesToZip(zos, externalArtifacts.getFileContent(filenameIncludingPath)); + + } catch (IOException exc) { + throw new RuntimeException(exc); + } finally { + try { + zos.closeEntry(); + } catch (IOException ignore) { + //do nothing + } + } + } + + } + + private void packArtifacts(ZipOutputStream zos, FileContentHandler artifacts) { + + for (String fileName : artifacts.getFileList()) { + try { + zos.putNextEntry(new ZipEntry((ARTIFACTS_FOLDER_NAME + FILE_SEPARATOR + fileName))); + writeBytesToZip(zos, artifacts.getFileContent(fileName)); + + } catch (IOException exc) { + throw new RuntimeException(exc); + } finally { + try { + zos.closeEntry(); + } catch (IOException ignore) { + //do nothing + } + } + } + } + + private void writeBytesToZip(ZipOutputStream zos, InputStream is) throws IOException { + FileUtils.copy(is, zos); + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/yamlutil/ToscaExtensionYamlUtil.java b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/yamlutil/ToscaExtensionYamlUtil.java new file mode 100644 index 0000000000..a1c11c2483 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/main/java/org/openecomp/sdc/tosca/services/yamlutil/ToscaExtensionYamlUtil.java @@ -0,0 +1,93 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +package org.openecomp.sdc.tosca.services.yamlutil; + +import org.openecomp.core.utilities.yaml.YamlUtil; +import org.yaml.snakeyaml.constructor.Constructor; +import org.yaml.snakeyaml.introspector.Property; +import org.yaml.snakeyaml.introspector.PropertyUtils; +import org.yaml.snakeyaml.nodes.MappingNode; +import org.yaml.snakeyaml.nodes.NodeId; + +import java.beans.IntrospectionException; + +public class ToscaExtensionYamlUtil extends YamlUtil { + + @Override + public Constructor getConstructor(Class typClass) { + return new ToscaWithHeatExtensionConstructor(typClass); + } + + @Override + protected PropertyUtils getPropertyUtils() { + return new ToscaPropertyUtilsWithHeatExtension(); + } + + public class ToscaPropertyUtilsWithHeatExtension extends MyPropertyUtils { + @Override + public Property getProperty(Class type, String name) + throws IntrospectionException { + try { + if (type.equals( + Class.forName("org.openecomp.sdc.tosca.datatypes.model.ParameterDefinition"))) { + type = Class.forName( + "org.openecomp.sdc.tosca.datatypes.model.heatextend.ParameterDefinitionExt"); + } + } catch (ClassNotFoundException exception) { + throw new RuntimeException(exception); + } + return super.getProperty(type, name); + } + } + + protected class ToscaWithHeatExtensionConstructor extends StrictMapAppenderConstructor { + public ToscaWithHeatExtensionConstructor(Class theRoot) { + super(theRoot); + yamlClassConstructors.put(NodeId.mapping, new MyPersistentObjectConstruct()); + } + + class MyPersistentObjectConstruct extends ConstructMapping { + @Override + protected Object constructJavaBean2ndStep(MappingNode node, Object object) { + Class type = node.getType(); + try { + if (type.equals( + Class.forName("org.openecomp.sdc.tosca.datatypes.model.ParameterDefinition"))) { + Class extendHeatClass = Class.forName( + "org.openecomp.sdc.tosca.datatypes.model.heatextend.ParameterDefinitionExt"); + Object extendHeatObject = extendHeatClass.newInstance(); + // create JavaBean + return super.constructJavaBean2ndStep(node, extendHeatObject); + } else { + // create JavaBean + return super.constructJavaBean2ndStep(node, object); + } + } catch (ClassNotFoundException | InstantiationException + | IllegalAccessException exception) { + throw new RuntimeException(exception); + } + } + } + } +} + + + diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/test/java/org/openecomp/sdc/tosca/TestUtil.java b/openecomp-be/lib/openecomp-tosca-lib/src/test/java/org/openecomp/sdc/tosca/TestUtil.java new file mode 100644 index 0000000000..da3ae76f27 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/test/java/org/openecomp/sdc/tosca/TestUtil.java @@ -0,0 +1,71 @@ +package org.openecomp.sdc.tosca; + +import org.openecomp.sdc.tosca.datatypes.ToscaServiceModel; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.services.yamlutil.ToscaExtensionYamlUtil; + +import java.io.*; +import java.net.URL; +import java.nio.file.NotDirectoryException; +import java.util.HashMap; +import java.util.Map; + +public class TestUtil { + + public static ToscaServiceModel loadToscaServiceModel(String serviceTemplatesPath, + String globalServiceTemplatesPath, + String entryDefinitionServiceTemplate) + throws IOException { + ToscaExtensionYamlUtil toscaExtensionYamlUtil = new ToscaExtensionYamlUtil(); + Map serviceTemplates = new HashMap<>(); + if (entryDefinitionServiceTemplate == null) { + entryDefinitionServiceTemplate = "MainServiceTemplate.yaml"; + } + + loadServiceTemplates(serviceTemplatesPath, toscaExtensionYamlUtil, serviceTemplates); + if (globalServiceTemplatesPath != null) { + loadServiceTemplates(globalServiceTemplatesPath, toscaExtensionYamlUtil, serviceTemplates); + } + + return new ToscaServiceModel(null, serviceTemplates, entryDefinitionServiceTemplate); + } + + private static void loadServiceTemplates(String serviceTemplatesPath, + ToscaExtensionYamlUtil toscaExtensionYamlUtil, + Map serviceTemplates) + throws IOException { + URL urlFile = TestUtil.class.getResource(serviceTemplatesPath); + if (urlFile != null) { + File pathFile = new File(urlFile.getFile()); + File[] files = pathFile.listFiles(); + if (files != null) { + addServiceTemplateFiles(serviceTemplates, files, toscaExtensionYamlUtil); + } else { + throw new NotDirectoryException(serviceTemplatesPath); + } + } else { + throw new NotDirectoryException(serviceTemplatesPath); + } + } + + private static void addServiceTemplateFiles(Map serviceTemplates, + File[] files, + ToscaExtensionYamlUtil toscaExtensionYamlUtil) + throws IOException { + for (File file : files) { + try (InputStream yamlFile = new FileInputStream(file)) { + ServiceTemplate serviceTemplateFromYaml = + toscaExtensionYamlUtil.yamlToObject(yamlFile, ServiceTemplate.class); + serviceTemplates.put(file.getName(), serviceTemplateFromYaml); + try { + yamlFile.close(); + } catch (IOException ignore) { + } + } catch (FileNotFoundException e) { + throw e; + } catch (IOException e) { + throw e; + } + } + } +} diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/test/java/org/openecomp/sdc/tosca/datatypes/PropertyTypeTest.java b/openecomp-be/lib/openecomp-tosca-lib/src/test/java/org/openecomp/sdc/tosca/datatypes/PropertyTypeTest.java new file mode 100644 index 0000000000..470dd9784a --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/test/java/org/openecomp/sdc/tosca/datatypes/PropertyTypeTest.java @@ -0,0 +1,20 @@ +package org.openecomp.sdc.tosca.datatypes; + +import org.openecomp.sdc.tosca.datatypes.model.PropertyType; +import org.junit.Assert; +import org.junit.Test; + +public class PropertyTypeTest { + @Test + public void shouldReturnNullWhenDisplayNameDoesNotExistForAnyProperty() { + String s = "blabla"; + Assert.assertEquals(PropertyType.getPropertyTypeByDisplayName(s), null); + } + + @Test + public void shouldReturnApproppriatePropertyTypeWhenDisplayNameExist() { + String s = "scalar-unit.size"; + Assert + .assertEquals(PropertyType.getPropertyTypeByDisplayName(s), PropertyType.SCALAR_UNIT_SIZE); + } +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/test/java/org/openecomp/sdc/tosca/datatypes/ToscaModelTest.java b/openecomp-be/lib/openecomp-tosca-lib/src/test/java/org/openecomp/sdc/tosca/datatypes/ToscaModelTest.java new file mode 100644 index 0000000000..13b05543fb --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/test/java/org/openecomp/sdc/tosca/datatypes/ToscaModelTest.java @@ -0,0 +1,282 @@ +package org.openecomp.sdc.tosca.datatypes; + +import org.openecomp.sdc.tosca.datatypes.model.ArtifactType; +import org.openecomp.sdc.tosca.datatypes.model.AttributeDefinition; +import org.openecomp.sdc.tosca.datatypes.model.CapabilityAssignment; +import org.openecomp.sdc.tosca.datatypes.model.CapabilityDefinition; +import org.openecomp.sdc.tosca.datatypes.model.Constraint; +import org.openecomp.sdc.tosca.datatypes.model.Directive; +import org.openecomp.sdc.tosca.datatypes.model.Import; +import org.openecomp.sdc.tosca.datatypes.model.Metadata; +import org.openecomp.sdc.tosca.datatypes.model.NodeFilter; +import org.openecomp.sdc.tosca.datatypes.model.NodeTemplate; +import org.openecomp.sdc.tosca.datatypes.model.NodeType; +import org.openecomp.sdc.tosca.datatypes.model.ParameterDefinition; +import org.openecomp.sdc.tosca.datatypes.model.PropertyDefinition; +import org.openecomp.sdc.tosca.datatypes.model.PropertyType; +import org.openecomp.sdc.tosca.datatypes.model.RequirementAssignment; +import org.openecomp.sdc.tosca.datatypes.model.RequirementDefinition; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.datatypes.model.SubstitutionMapping; +import org.openecomp.sdc.tosca.datatypes.model.TopologyTemplate; +import org.openecomp.sdc.tosca.datatypes.model.heatextend.ParameterDefinitionExt; +import org.openecomp.sdc.tosca.services.DataModelUtil; +import org.openecomp.sdc.tosca.services.ToscaConstants; +import org.openecomp.sdc.tosca.services.yamlutil.ToscaExtensionYamlUtil; +import org.openecomp.core.utilities.yaml.YamlUtil; +import org.junit.Assert; +import org.junit.Test; + + +import java.io.InputStream; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + + +public class ToscaModelTest { + + @Test + public void testServiceTemplateJavaToYaml() { + + ServiceTemplate serviceTemplate = new ServiceTemplate(); + Metadata metadata = new Metadata(); + metadata.setTemplate_author("OPENECOMP"); + metadata.setTemplate_name("Test"); + metadata.setTemplate_version("1.0.0"); + serviceTemplate.setTosca_definitions_version("tosca_simple_yaml_1_0_0"); + serviceTemplate.setDescription("testing desc tosca service template"); + serviceTemplate.setMetadata(metadata); + + Import fileImport1 = new Import(); + fileImport1.setFile("path1/path2/file1.yaml"); + Import fileImport2 = new Import(); + fileImport2.setFile("path1/path2/file2.yaml"); + Map imports = new HashMap<>(); + imports.put("myfile1", fileImport1); + imports.put("myfile2", fileImport2); + serviceTemplate.setImports(imports); + + ArtifactType artifact = new ArtifactType(); + artifact.setMime_type("application/java-archive"); + ArrayList ext = new ArrayList<>(); + ext.add("yaml"); + ext.add("xml"); + artifact.setFile_ext(ext); + Map artifactTypes = new HashMap<>(); + artifactTypes.put("one_artifact", artifact); + serviceTemplate.setArtifact_types(artifactTypes); + + NodeType nodeType = new NodeType(); + nodeType.setDerived_from("tosca.nodes.Root"); + nodeType.setVersion("1.0.0"); + nodeType.setDescription("tosca compute test"); + + PropertyDefinition propDef1 = new PropertyDefinition(); + propDef1.setType("integer"); + propDef1.setDescription("Number of CPUs requested for a software node instance"); + propDef1.setRequired(true); + propDef1.set_default(1); + + Constraint graterOrEqual = new Constraint(); + graterOrEqual.setGreater_or_equal((float) 5.0); + Constraint constraintEqual = new Constraint(); + constraintEqual.setEqual(5); + Constraint greater_than = new Constraint(); + greater_than.setGreater_than(6.02); + Constraint inRange = new Constraint(); + inRange.setIn_range(new Object[2]); + inRange.getIn_range()[0] = 0; + inRange.getIn_range()[1] = ToscaConstants.UNBOUNDED; + + List constraints = new ArrayList<>(); + constraints.add(graterOrEqual); + constraints.add(constraintEqual); + constraints.add(greater_than); + constraints.add(inRange); + propDef1.setConstraints(constraints); + + Map properties = new HashMap<>(); + properties.put("cpu_num", propDef1); + nodeType.setProperties(properties); + + Map attributesDef = new HashMap<>(); + AttributeDefinition attDef = new AttributeDefinition(); + attDef.setType(PropertyType.STRING.getDisplayName()); + attDef.set_default("hi"); + attributesDef.put("attDef1", attDef); + nodeType.setAttributes(attributesDef); + + Map reqsDef = new HashMap<>(); + RequirementDefinition reqDef = new RequirementDefinition(); + reqDef.setCapability("tosca.cap1"); + reqDef.getOccurrences()[0] = 5; + reqsDef.put("re1", reqDef); + List> reqList = new ArrayList<>(); + reqList.add(reqsDef); + nodeType.setRequirements(reqList); + + + Map capsDef = new HashMap<>(); + CapabilityDefinition capdef = new CapabilityDefinition(); + capdef.setType("tosca.cap"); + List vvSource = new ArrayList<>(); + vvSource.add("node1"); + vvSource.add("node2"); + capdef.setValid_source_types(vvSource); + capsDef.put("cap1", capdef); + nodeType.setCapabilities(capsDef); + + Map nodeTypes = new HashMap<>(); + nodeTypes.put("compute_node_type", nodeType); + serviceTemplate.setNode_types(nodeTypes); + + TopologyTemplate topologyTemplate = new TopologyTemplate(); + topologyTemplate.setDescription("topologi template descroption"); + Map inputs = new HashMap<>(); + ParameterDefinition paramDef = new ParameterDefinition(); + paramDef.setType(PropertyType.STRING.getDisplayName()); + paramDef.setDescription("desc"); + paramDef.set_default("my default val"); + paramDef.setRequired(false); + paramDef.setEntry_schema(DataModelUtil.createEntrySchema("tosca.myType", null, null)); + List paramConstraint = new ArrayList<>(); + Constraint paramConst1 = new Constraint(); + paramConst1.setGreater_than(6); + Constraint paramConst2 = new Constraint(); + paramConst2.setGreater_or_equal(9); + paramConstraint.add(paramConst1); + paramConstraint.add(paramConst2); + paramDef.setConstraints(paramConstraint); + inputs.put("inParam1", paramDef); + topologyTemplate.setInputs(inputs); + + Map nodeTemplates = new HashMap<>(); + NodeTemplate nodeTemplate = new NodeTemplate(); + nodeTemplate.setType("nodeTypeRef"); + List directives = new ArrayList<>(); + directives.add(Directive.SELECTABLE.getDisplayName()); + directives.add(Directive.SUBSTITUTABLE.getDisplayName()); + nodeTemplate.setDirectives(directives); + Map nodeTemplateProperties = new HashMap<>(); + nodeTemplateProperties.put("prop1", "abcd"); + nodeTemplateProperties.put("prop2", "{ get_input: my_mysql_rootpw }"); + nodeTemplate.setProperties(nodeTemplateProperties); + Map nodeTemplateAtts = new HashMap<>(); + nodeTemplateAtts.put("att1", "att1Val"); + nodeTemplateAtts.put("att2", "{ get_input: my_mysql_rootpw }"); + nodeTemplate.setAttributes(nodeTemplateAtts); + + + RequirementAssignment reqAssignment1 = new RequirementAssignment(); + reqAssignment1.setNode("nodeA"); + reqAssignment1.setCapability("capA"); + reqAssignment1.setRelationship("relationB"); + Object[] reqAssOccurrences = new Object[2]; + reqAssOccurrences[0] = 1; + reqAssOccurrences[1] = 2; + reqAssignment1.setOccurrences(reqAssOccurrences); + NodeFilter reqNodeFilter = new NodeFilter(); + List propConstrain1 = new ArrayList<>(); + Constraint propConst1 = new Constraint(); + propConst1.setGreater_or_equal(9); + propConstrain1.add(propConst1); + List propConstrain2 = new ArrayList<>(); + Constraint propConst2 = new Constraint(); + propConst2.setMin_length(1); + propConstrain2.add(propConst2); + Constraint propConst3 = new Constraint(); + propConst3.setMax_length(2); + propConstrain2.add(propConst3); + Map> nodeFilterProp = new HashMap<>(); + nodeFilterProp.put("propName1", propConstrain1); + nodeFilterProp.put("propName2", propConstrain2); + reqNodeFilter.setProperties(nodeFilterProp); + reqAssignment1.setNode_filter(reqNodeFilter); + + RequirementAssignment reqAssignment2 = new RequirementAssignment(); + reqAssignment2.setNode("nodeA"); + reqAssignment2.setCapability("capA"); + reqAssignment2.setRelationship("relationB"); + Map nodeTemplateRequirement1 = new HashMap<>(); + Map nodeTemplateRequirement2 = new HashMap<>(); + nodeTemplateRequirement1.put("req1", reqAssignment1); + nodeTemplateRequirement2.put("req2", reqAssignment2); + nodeTemplate.setRequirements(new ArrayList<>()); + nodeTemplate.getRequirements().add(nodeTemplateRequirement1); + nodeTemplate.getRequirements().add(nodeTemplateRequirement2); + + Map nodeTemplateCapability = new HashMap<>(); + CapabilityAssignment capAss = new CapabilityAssignment(); + Map capProps = new HashMap<>(); + capProps.put("num_cpus", "{ get_input: cpus }"); + capAss.setProperties(capProps); + Map capAtts = new HashMap<>(); + capAtts.put("num_cpus", "66"); + capAss.setAttributes(capAtts); + nodeTemplateCapability.put("cap1", capAss); + nodeTemplate.setCapabilities(new ArrayList<>()); + nodeTemplate.getCapabilities().add(nodeTemplateCapability); + + NodeFilter nodeTemplateNodeFilter = new NodeFilter(); + Map> ntProp = new HashMap<>(); + Constraint c1 = new Constraint(); + c1.setEqual("1 MB"); + List consList = new ArrayList<>(); + consList.add(c1); + ntProp.put("test1", consList); + nodeTemplateNodeFilter.setProperties(ntProp); + nodeTemplate.setNode_filter(nodeTemplateNodeFilter); + nodeTemplates.put("firatNodeTemplate", nodeTemplate); + topologyTemplate.setNode_templates(nodeTemplates); + + SubstitutionMapping subMap = new SubstitutionMapping(); + subMap.setNode_type("myNodeType.node"); + Map> mapCapabilities = new HashMap<>(); + List NodeCap = new ArrayList<>(); + NodeCap.add("database"); + NodeCap.add("database_endpoint"); + mapCapabilities.put("database_endpoint", NodeCap); + subMap.setCapabilities(mapCapabilities); + topologyTemplate.setSubstitution_mappings(subMap); + serviceTemplate.setTopology_template(topologyTemplate); + + String yaml = new YamlUtil().objectToYaml(serviceTemplate); + ServiceTemplate serviceTemplateFromYaml = + new YamlUtil().yamlToObject(yaml, ServiceTemplate.class); + Assert.assertNotNull(serviceTemplateFromYaml); + } + + + @Test + public void testYamlToServiceTemplateObj() { + InputStream yamlFile = new YamlUtil().loadYamlFileIs("/mock/model/serviceTemplate.yaml"); + ServiceTemplate serviceTemplateFromYaml = + new YamlUtil().yamlToObject(yamlFile, ServiceTemplate.class); + Assert.assertNotNull(serviceTemplateFromYaml); + } + + + @Test + public void testYamlToServiceTemplateIncludingHeatExtend() { + ToscaExtensionYamlUtil toscaExtensionYamlUtil = new ToscaExtensionYamlUtil(); + InputStream yamlFile = + toscaExtensionYamlUtil.loadYamlFileIs("/mock/model/serviceTemplateHeatExtend.yaml"); + ServiceTemplate serviceTemplateFromYaml = + toscaExtensionYamlUtil.yamlToObject(yamlFile, ServiceTemplate.class); + ParameterDefinitionExt parameterDefinitionExt = + (ParameterDefinitionExt) serviceTemplateFromYaml.getTopology_template().getInputs() + .get("inParam1"); + Assert.assertNotNull(parameterDefinitionExt.getLabel()); + String backToYamlString = toscaExtensionYamlUtil.objectToYaml(serviceTemplateFromYaml); + Assert.assertNotNull(backToYamlString); + } + +} + + + + + + diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/test/java/org/openecomp/sdc/tosca/datatypes/model/CapabilityDefinitionTest.java b/openecomp-be/lib/openecomp-tosca-lib/src/test/java/org/openecomp/sdc/tosca/datatypes/model/CapabilityDefinitionTest.java new file mode 100644 index 0000000000..2b0f88fdea --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/test/java/org/openecomp/sdc/tosca/datatypes/model/CapabilityDefinitionTest.java @@ -0,0 +1,101 @@ +package org.openecomp.sdc.tosca.datatypes.model; + +import org.openecomp.sdc.tosca.services.ToscaConstants; +import org.openecomp.core.utilities.yaml.YamlUtil; +import org.junit.Assert; +import org.junit.Test; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +public class CapabilityDefinitionTest { + + @Test + public void cloneTest() { + CapabilityDefinition capDef1 = new CapabilityDefinition(); + Map attributes = new HashMap<>(); + attributes.put("key1", getAttributeDefinition()); + capDef1.setAttributes(attributes); + + capDef1.setDescription("This is my desc"); + capDef1.setOccurrences(getMockOccurrences()); + + Map properties = new HashMap<>(); + PropertyDefinition propertyDefinition = getMockPropertyDefinition(); + properties.put("key1", propertyDefinition); + capDef1.setProperties(properties); + capDef1.setType("My Type"); + List valid_source_types = new ArrayList<>(); + valid_source_types.add("nonono"); + capDef1.setValid_source_types(valid_source_types); + + CapabilityDefinition capDef2 = capDef1.clone(); + NodeType nodeType = new NodeType(); + nodeType.setCapabilities(new HashMap<>()); + nodeType.getCapabilities().put("cap1", capDef1); + nodeType.getCapabilities().put("cap2", capDef2); + + String yamlString = new YamlUtil().objectToYaml(nodeType); + Boolean passResult = !yamlString.contains("&") && !yamlString.contains("*"); + Assert.assertEquals(true, passResult); + } + + private PropertyDefinition getMockPropertyDefinition() { + PropertyDefinition propertyDefinition = new PropertyDefinition(); + propertyDefinition.setConstraints(getMockConstraints()); + propertyDefinition.setDescription("desc"); + propertyDefinition.setType("typeProp"); + propertyDefinition.set_default(5); + propertyDefinition.setEntry_schema(getMockEntrySchema()); + propertyDefinition.setRequired(false); + propertyDefinition.setStatus(Status.UNSUPPORTED); + return propertyDefinition; + } + + private Object[] getMockOccurrences() { + Object[] occurrences = new Object[2]; + occurrences[0] = 2; + occurrences[1] = ToscaConstants.UNBOUNDED; + return occurrences; + } + + private ArtifactDefinition getMockArtifactDefinition() { + ArtifactDefinition artifactDefinition = new ArtifactDefinition(); + artifactDefinition.setType("type1"); + artifactDefinition.setDescription("description of OPENECOMP def"); + artifactDefinition.setDeploy_path("my deployment path"); + artifactDefinition.setFile("my file"); + artifactDefinition.setRepository("my repository"); + return artifactDefinition; + } + + private AttributeDefinition getAttributeDefinition() { + AttributeDefinition attributeDefinition = new AttributeDefinition(); + attributeDefinition.setDescription("desc1"); + attributeDefinition.setType("type1"); + attributeDefinition.set_default("none"); + attributeDefinition.setEntry_schema(getMockEntrySchema()); + attributeDefinition.setStatus(Status.UNSUPPORTED); + return attributeDefinition; + } + + private EntrySchema getMockEntrySchema() { + EntrySchema entrySchema = new EntrySchema(); + entrySchema.setType("string"); + entrySchema.setDescription("string for string"); + List constraints = getMockConstraints(); + entrySchema.setConstraints(constraints); + return entrySchema; + } + + private List getMockConstraints() { + List constraints = new ArrayList<>(); + Constraint constraint = new Constraint(); + constraint.setEqual("5"); + constraints.add(constraint); + return constraints; + } + +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/test/java/org/openecomp/sdc/tosca/datatypes/model/RequirementDefinitionTest.java b/openecomp-be/lib/openecomp-tosca-lib/src/test/java/org/openecomp/sdc/tosca/datatypes/model/RequirementDefinitionTest.java new file mode 100644 index 0000000000..3109a8abff --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/test/java/org/openecomp/sdc/tosca/datatypes/model/RequirementDefinitionTest.java @@ -0,0 +1,40 @@ +package org.openecomp.sdc.tosca.datatypes.model; + +import org.openecomp.core.utilities.yaml.YamlUtil; +import org.junit.Assert; +import org.junit.Test; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +public class RequirementDefinitionTest { + + @Test + public void cloneTest() { + RequirementDefinition reqDef1 = new RequirementDefinition(); + reqDef1.setNode("node1"); + reqDef1.setRelationship("my Relationship"); + reqDef1.setCapability("capabilities"); + reqDef1.setOccurrences(new Object[]{1, 1}); + + RequirementDefinition reqDef2 = reqDef1.clone(); + NodeType nodeType = new NodeType(); + + List> requirements = new ArrayList<>(); + Map reqMap1 = new HashMap<>(); + reqMap1.put("req1", reqDef1); + requirements.add(reqMap1); + Map reqMap2 = new HashMap<>(); + reqMap2.put("req2", reqDef2); + requirements.add(reqMap2); + nodeType.setRequirements(requirements); + + String yamlString = new YamlUtil().objectToYaml(nodeType); + Boolean passResult = !yamlString.contains("&") && !yamlString.contains("*"); + Assert.assertEquals(true, passResult); + } + + +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/test/java/org/openecomp/sdc/tosca/services/DataModelUtilTest.java b/openecomp-be/lib/openecomp-tosca-lib/src/test/java/org/openecomp/sdc/tosca/services/DataModelUtilTest.java new file mode 100644 index 0000000000..893f7a1a5e --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/test/java/org/openecomp/sdc/tosca/services/DataModelUtilTest.java @@ -0,0 +1,104 @@ +package org.openecomp.sdc.tosca.services; + +import org.openecomp.sdc.common.errors.CoreException; +import org.junit.Rule; +import org.junit.Test; +import org.junit.rules.ExpectedException; +import org.junit.runner.RunWith; +import org.mockito.runners.MockitoJUnitRunner; +import org.openecomp.sdc.tosca.datatypes.model.GroupDefinition; +import org.openecomp.sdc.tosca.datatypes.model.NodeTemplate; +import org.openecomp.sdc.tosca.datatypes.model.NodeType; +import org.openecomp.sdc.tosca.datatypes.model.PolicyDefinition; +import org.openecomp.sdc.tosca.datatypes.model.RelationshipTemplate; +import org.openecomp.sdc.tosca.datatypes.model.RequirementAssignment; +import org.openecomp.sdc.tosca.datatypes.model.SubstitutionMapping; + +import java.util.ArrayList; + +@RunWith(MockitoJUnitRunner.class) +public class DataModelUtilTest { + + @Rule + public ExpectedException thrown = ExpectedException.none(); + + @Test + public void testAddSubstitutionMapping() throws Exception { + thrown.expect(CoreException.class); + thrown.expectMessage( + "Invalid action, can't add 'Substitution Mapping' to 'Service Template', 'Service Template' entity is NULL."); + DataModelUtil.addSubstitutionMapping(null, new SubstitutionMapping()); + } + + @Test + public void testAddSubstitutionMappingReq() throws Exception { + thrown.expect(CoreException.class); + thrown.expectMessage( + "Invalid action, can't add 'Substitution Mapping Requirements' to 'Service Template', 'Service Template' entity is NULL."); + DataModelUtil.addSubstitutionMappingReq(null, "123", new ArrayList<>()); + } + + @Test + public void testAddNodeTemplate() throws Exception { + thrown.expect(CoreException.class); + thrown.expectMessage( + "Invalid action, can't add 'Node Template' to 'Service Template', 'Service Template' entity is NULL."); + DataModelUtil.addNodeTemplate(null, "123", new NodeTemplate()); + } + + @Test + public void testAddPolicyDefinition() throws Exception { + thrown.expect(CoreException.class); + thrown.expectMessage( + "Invalid action, can't add 'Policy Definition' to 'Service Template', 'Service Template' entity is NULL."); + DataModelUtil.addPolicyDefinition(null, "123", new PolicyDefinition()); + } + + @Test + public void testAddNodeType() throws Exception { + thrown.expect(CoreException.class); + thrown.expectMessage( + "Invalid action, can't add 'Node Type' to 'Service Template', 'Service Template' entity is NULL."); + DataModelUtil.addNodeType(null, "123", new NodeType()); + } + + @Test + public void testAddRelationshipTemplate() throws Exception { + thrown.expect(CoreException.class); + thrown.expectMessage( + "Invalid action, can't add 'Relationship Template' to 'Service Template', 'Service Template' entity is NULL."); + DataModelUtil.addRelationshipTemplate(null, "123", new RelationshipTemplate()); + } + + @Test + public void testAddRequirementAssignment() throws Exception { + thrown.expect(CoreException.class); + thrown.expectMessage( + "Invalid action, can't add 'Requirement Assignment' to 'Node Template', 'Node Template' entity is NULL."); + DataModelUtil.addRequirementAssignment(null, "123", new RequirementAssignment()); + } + + @Test + public void testGetNodeTemplate() throws Exception { + thrown.expect(CoreException.class); + thrown.expectMessage( + "Invalid action, can't add 'Node Template' to 'Service Template', 'Service Template' entity is NULL."); + DataModelUtil.addNodeTemplate(null, "123", new NodeTemplate()); + } + + @Test + public void testGetNodeType() throws Exception { + thrown.expect(CoreException.class); + thrown.expectMessage( + "Invalid action, can't add 'Node Type' to 'Service Template', 'Service Template' entity is NULL."); + DataModelUtil.addNodeType(null, "123", new NodeType()); + } + + @Test + public void testAddGroupToTopologyTemplate() throws Exception { + thrown.expect(CoreException.class); + thrown.expectMessage( + "Invalid action, can't add 'Group Definition' to 'Service Template', 'Service Template' entity is NULL."); + DataModelUtil.addGroupDefinitionToTopologyTemplate(null, "123", new GroupDefinition()); + } +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/test/java/org/openecomp/sdc/tosca/services/impl/ToscaAnalyzerServiceImplTest.java b/openecomp-be/lib/openecomp-tosca-lib/src/test/java/org/openecomp/sdc/tosca/services/impl/ToscaAnalyzerServiceImplTest.java new file mode 100644 index 0000000000..47f0bd9aef --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/test/java/org/openecomp/sdc/tosca/services/impl/ToscaAnalyzerServiceImplTest.java @@ -0,0 +1,472 @@ +package org.openecomp.sdc.tosca.services.impl; + +import org.openecomp.sdc.common.errors.CoreException; +import org.openecomp.sdc.tosca.TestUtil; +import org.openecomp.sdc.tosca.datatypes.ToscaNodeType; +import org.openecomp.sdc.tosca.datatypes.ToscaServiceModel; +import org.openecomp.sdc.tosca.services.ToscaAnalyzerService; +import org.openecomp.sdc.tosca.services.ToscaConstants; +import org.openecomp.sdc.tosca.services.yamlutil.ToscaExtensionYamlUtil; +import org.junit.Before; +import org.junit.BeforeClass; +import org.junit.Rule; +import org.junit.Test; +import org.junit.rules.ExpectedException; +import org.junit.runner.RunWith; +import org.mockito.Mock; +import org.mockito.MockitoAnnotations; +import org.mockito.runners.MockitoJUnitRunner; +import org.openecomp.sdc.tosca.datatypes.model.Import; +import org.openecomp.sdc.tosca.datatypes.model.NodeTemplate; +import org.openecomp.sdc.tosca.datatypes.model.NodeType; +import org.openecomp.sdc.tosca.datatypes.model.RequirementAssignment; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.datatypes.model.SubstitutionMapping; +import org.openecomp.sdc.tosca.datatypes.model.TopologyTemplate; + +import java.io.IOException; +import java.io.InputStream; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.Optional; + +import static org.junit.Assert.*; +import static org.mockito.Mockito.when; + +@RunWith(MockitoJUnitRunner.class) +public class ToscaAnalyzerServiceImplTest { + /* + Dictionary: + SrvTmp: ServiceTemplate + NdTmp: NodeTemplate + NdTy: NodeType + */ + + private static ToscaAnalyzerService toscaAnalyzerService; + private static ToscaServiceModel toscaServiceModel; + @Rule + public ExpectedException thrown = ExpectedException.none(); + + @Mock + NodeTemplate nodeTemplateMock; + @Mock + ToscaServiceModel toscaServiceModelMock; + + @BeforeClass + public static void onlyOnceSetUp() throws IOException { + toscaAnalyzerService = new ToscaAnalyzerServiceImpl(); + toscaServiceModel = TestUtil.loadToscaServiceModel("/mock/analyzerService/toscasubstitution/", + "/mock/globalServiceTemplates/", null); + } + + @Before + public void init() throws IOException { + MockitoAnnotations.initMocks(this); + } + + @Test + public void testGetRequirements() throws Exception { + ToscaExtensionYamlUtil toscaExtensionYamlUtil = new ToscaExtensionYamlUtil(); + InputStream yamlFile = toscaExtensionYamlUtil + .loadYamlFileIs("/mock/analyzerService/NestedServiceTemplateReqTest.yaml"); + ServiceTemplate serviceTemplateFromYaml = + toscaExtensionYamlUtil.yamlToObject(yamlFile, ServiceTemplate.class); + + NodeTemplate port_0 = + serviceTemplateFromYaml.getTopology_template().getNode_templates().get("cmaui_port_0"); + List reqList = + toscaAnalyzerService.getRequirements(port_0, ToscaConstants.BINDING_REQUIREMENT_ID); + assertEquals(1, reqList.size()); + + reqList.clear(); + NodeTemplate port_1 = + serviceTemplateFromYaml.getTopology_template().getNode_templates().get("cmaui1_port_1"); + reqList = toscaAnalyzerService.getRequirements(port_1, ToscaConstants.LINK_REQUIREMENT_ID); + assertEquals(2, reqList.size()); + + reqList.clear(); + reqList = toscaAnalyzerService.getRequirements(port_0, ToscaConstants.LINK_REQUIREMENT_ID); + assertEquals(0, reqList.size()); + } + + @Test + public void testGetNodeTemplateById() throws Exception { + ServiceTemplate emptyServiceTemplate = new ServiceTemplate(); + Optional nodeTemplate = + toscaAnalyzerService.getNodeTemplateById(emptyServiceTemplate, "test_net222"); + assertEquals(false, nodeTemplate.isPresent()); + + ServiceTemplate mainServiceTemplate = toscaServiceModel.getServiceTemplates() + .get(toscaServiceModel.getEntryDefinitionServiceTemplate()); + nodeTemplate = toscaAnalyzerService.getNodeTemplateById(mainServiceTemplate, "test_net"); + assertEquals(true, nodeTemplate.isPresent()); + + nodeTemplate = toscaAnalyzerService.getNodeTemplateById(mainServiceTemplate, "test_net222"); + assertEquals(false, nodeTemplate.isPresent()); + } + + @Test + public void testGetSubstituteServiceTemplateName() throws Exception { + thrown.expect(CoreException.class); + thrown.expectMessage( + "Invalid Substitute Node Template invalid2, mandatory map property service_template_filter with mandatory key substitute_service_template must be defined."); + + ServiceTemplate mainServiceTemplate = toscaServiceModel.getServiceTemplates() + .get(toscaServiceModel.getEntryDefinitionServiceTemplate()); + Optional notSubstitutableNodeTemplate = + toscaAnalyzerService.getNodeTemplateById(mainServiceTemplate, "test_net"); + Optional substituteServiceTemplateName = toscaAnalyzerService + .getSubstituteServiceTemplateName("test_net", notSubstitutableNodeTemplate.get()); + assertEquals(false, substituteServiceTemplateName.isPresent()); + + Optional substitutableNodeTemplate = + toscaAnalyzerService.getNodeTemplateById(mainServiceTemplate, "test_nested"); + substituteServiceTemplateName = toscaAnalyzerService + .getSubstituteServiceTemplateName("test_nested", substitutableNodeTemplate.get()); + assertEquals(true, substituteServiceTemplateName.isPresent()); + assertEquals("nestedServiceTemplate.yaml", substituteServiceTemplateName.get()); + + NodeTemplate invalidSubstitutableNodeTemplate1 = new NodeTemplate(); + substituteServiceTemplateName = toscaAnalyzerService + .getSubstituteServiceTemplateName("invalid1", invalidSubstitutableNodeTemplate1); + assertEquals(false, substituteServiceTemplateName.isPresent()); + + + NodeTemplate invalidSubstitutableNodeTemplate2 = substitutableNodeTemplate.get(); + Object serviceTemplateFilter = invalidSubstitutableNodeTemplate2.getProperties() + .get(ToscaConstants.SERVICE_TEMPLATE_FILTER_PROPERTY_NAME); + ((Map) serviceTemplateFilter).clear(); + toscaAnalyzerService + .getSubstituteServiceTemplateName("invalid2", invalidSubstitutableNodeTemplate2); + + + } + + + @Test + public void testGetSubstitutableNodeTemplates() throws Exception { + ToscaExtensionYamlUtil toscaExtensionYamlUtil = new ToscaExtensionYamlUtil(); + InputStream yamlFile = toscaExtensionYamlUtil + .loadYamlFileIs("/mock/analyzerService/ServiceTemplateSubstituteTest.yaml"); + ServiceTemplate serviceTemplateFromYaml = + toscaExtensionYamlUtil.yamlToObject(yamlFile, ServiceTemplate.class); + + Map substitutableNodeTemplates = + toscaAnalyzerService.getSubstitutableNodeTemplates(serviceTemplateFromYaml); + assertEquals(2, substitutableNodeTemplates.size()); + assertNotNull(substitutableNodeTemplates.get("test_nested1")); + assertNotNull(substitutableNodeTemplates.get("test_nested2")); + + ServiceTemplate emptyServiceTemplate = new ServiceTemplate(); + emptyServiceTemplate.setTopology_template(new TopologyTemplate()); + substitutableNodeTemplates = + toscaAnalyzerService.getSubstitutableNodeTemplates(emptyServiceTemplate); + assertEquals(0, substitutableNodeTemplates.size()); + + yamlFile = toscaExtensionYamlUtil + .loadYamlFileIs("/mock/analyzerService/NestedServiceTemplateReqTest.yaml"); + serviceTemplateFromYaml = toscaExtensionYamlUtil.yamlToObject(yamlFile, ServiceTemplate.class); + substitutableNodeTemplates = + toscaAnalyzerService.getSubstitutableNodeTemplates(serviceTemplateFromYaml); + assertEquals(0, substitutableNodeTemplates.size()); + } + + @Test + public void testGetSubstitutionMappedNodeTemplateByExposedReq() throws Exception { + thrown.expect(CoreException.class); + thrown.expectMessage( + "Invalid Tosca model data, missing 'Node Template' entry for 'Node Template' id cmaui_port_9"); + ToscaExtensionYamlUtil toscaExtensionYamlUtil = new ToscaExtensionYamlUtil(); + InputStream yamlFile = toscaExtensionYamlUtil + .loadYamlFileIs("/mock/analyzerService/NestedServiceTemplateReqTest.yaml"); + ServiceTemplate nestedServiceTemplateFromYaml = + toscaExtensionYamlUtil.yamlToObject(yamlFile, ServiceTemplate.class); + + Optional> mappedNodeTemplate = toscaAnalyzerService + .getSubstitutionMappedNodeTemplateByExposedReq("NestedServiceTemplateSubstituteTest.yaml", + nestedServiceTemplateFromYaml, "local_storage_server_cmaui"); + assertEquals("server_cmaui", mappedNodeTemplate.get().getKey()); + assertNotNull(mappedNodeTemplate.get().getValue()); + + mappedNodeTemplate = toscaAnalyzerService + .getSubstitutionMappedNodeTemplateByExposedReq("NestedServiceTemplateSubstituteTest.yaml", + nestedServiceTemplateFromYaml, "link_cmaui_port_invalid"); + assertEquals("server_cmaui", mappedNodeTemplate.get().getKey()); + assertNotNull(mappedNodeTemplate.get().getValue()); + + ServiceTemplate mainServiceTemplate = toscaServiceModel.getServiceTemplates() + .get(toscaServiceModel.getEntryDefinitionServiceTemplate()); + mappedNodeTemplate = toscaAnalyzerService.getSubstitutionMappedNodeTemplateByExposedReq( + toscaServiceModel.getEntryDefinitionServiceTemplate(), mainServiceTemplate, + "local_storage_server_cmaui"); + assertEquals(false, mappedNodeTemplate.isPresent()); + } + + @Test + public void invalidSubstitutableMapping() throws Exception { + thrown.expect(CoreException.class); + thrown.expectMessage( + "Invalid Substitution Service Template invalidMappingServiceTemplate.yaml, missing mandatory file 'Node type' in substitution mapping."); + ServiceTemplate invalidMappingServiceTemplate = new ServiceTemplate(); + invalidMappingServiceTemplate.setTopology_template(new TopologyTemplate()); + invalidMappingServiceTemplate.getTopology_template() + .setSubstitution_mappings(new SubstitutionMapping()); + toscaAnalyzerService + .getSubstitutionMappedNodeTemplateByExposedReq("invalidMappingServiceTemplate.yaml", + invalidMappingServiceTemplate, "local_storage_server_cmaui"); + } + + @Test + public void substitutableMappingWithNoReqMap() throws Exception { + ServiceTemplate mainServiceTemplate = toscaServiceModel.getServiceTemplates() + .get(toscaServiceModel.getEntryDefinitionServiceTemplate()); + ServiceTemplate emptyReqMapping = new ServiceTemplate(); + emptyReqMapping.setTopology_template(new TopologyTemplate()); + emptyReqMapping.getTopology_template().setSubstitution_mappings(new SubstitutionMapping()); + emptyReqMapping.getTopology_template().getSubstitution_mappings().setNode_type("temp"); + Optional> mappedNodeTemplate = toscaAnalyzerService + .getSubstitutionMappedNodeTemplateByExposedReq( + toscaServiceModel.getEntryDefinitionServiceTemplate(), mainServiceTemplate, + "local_storage_server_cmaui"); + assertEquals(false, mappedNodeTemplate.isPresent()); + } + + @Test + public void testGetSubstitutionMappedNodeTemplateByExposedReqInvalid() throws Exception { + thrown.expect(CoreException.class); + thrown.expectMessage( + "Invalid Tosca model data, missing 'Node Template' entry for 'Node Template' id cmaui_port_9"); + ToscaExtensionYamlUtil toscaExtensionYamlUtil = new ToscaExtensionYamlUtil(); + InputStream yamlFile = toscaExtensionYamlUtil + .loadYamlFileIs("/mock/analyzerService/NestedServiceTemplateReqTest.yaml"); + ServiceTemplate nestedServiceTemplateFromYaml = + toscaExtensionYamlUtil.yamlToObject(yamlFile, ServiceTemplate.class); + + toscaAnalyzerService + .getSubstitutionMappedNodeTemplateByExposedReq("NestedServiceTemplateSubstituteTest.yaml", + nestedServiceTemplateFromYaml, "link_cmaui_port_invalid"); + } + + @Test + public void testIsDesiredRequirementAssignmentMatch() throws Exception { + + RequirementAssignment requirementAssignment = new RequirementAssignment(); + String capability = "Test.Capability"; + String node = "Test.node"; + String relationship = "Test.relationship"; + requirementAssignment.setCapability(capability); + requirementAssignment.setNode(node); + requirementAssignment.setRelationship(relationship); + + assertEquals(true, toscaAnalyzerService + .isDesiredRequirementAssignment(requirementAssignment, capability, node, relationship)); + assertEquals(true, toscaAnalyzerService + .isDesiredRequirementAssignment(requirementAssignment, null, node, relationship)); + assertEquals(true, toscaAnalyzerService + .isDesiredRequirementAssignment(requirementAssignment, capability, null, relationship)); + assertEquals(true, toscaAnalyzerService + .isDesiredRequirementAssignment(requirementAssignment, capability, node, null)); + assertEquals(true, toscaAnalyzerService + .isDesiredRequirementAssignment(requirementAssignment, null, null, relationship)); + assertEquals(true, toscaAnalyzerService + .isDesiredRequirementAssignment(requirementAssignment, capability, null, null)); + assertEquals(true, toscaAnalyzerService + .isDesiredRequirementAssignment(requirementAssignment, null, node, null)); + + } + + @Test + public void testIsDesiredRequirementAssignmentNoMatch() throws Exception { + + RequirementAssignment requirementAssignment = new RequirementAssignment(); + String capability = "Test.Capability"; + String node = "Test.node"; + String relationship = "Test.relationship"; + requirementAssignment.setCapability(capability); + requirementAssignment.setNode(node); + requirementAssignment.setRelationship(relationship); + + assertEquals(false, toscaAnalyzerService + .isDesiredRequirementAssignment(requirementAssignment, "no", node, relationship)); + assertEquals(false, toscaAnalyzerService + .isDesiredRequirementAssignment(requirementAssignment, "no", "no", relationship)); + assertEquals(false, toscaAnalyzerService + .isDesiredRequirementAssignment(requirementAssignment, "no", "no", "no")); + assertEquals(false, toscaAnalyzerService + .isDesiredRequirementAssignment(requirementAssignment, capability, "no", relationship)); + assertEquals(false, toscaAnalyzerService + .isDesiredRequirementAssignment(requirementAssignment, capability, node, "no")); + assertEquals(false, toscaAnalyzerService + .isDesiredRequirementAssignment(requirementAssignment, capability, "no", "no")); + assertEquals(false, toscaAnalyzerService + .isDesiredRequirementAssignment(requirementAssignment, "no", null, null)); + assertEquals(false, toscaAnalyzerService + .isDesiredRequirementAssignment(requirementAssignment, null, null, null)); + + + } + + @Test + public void shouldReturnFalseIfNdTmpIsNull() { + assertFalse(toscaAnalyzerService + .isTypeOf(null, ToscaNodeType.NETWORK.getDisplayName(), new ServiceTemplate(), + toscaServiceModelMock)); + } + + @Test + public void shouldReturnTrueIfNdTmpTypeIsOfRequestedType() { + NodeTemplate nodeTemplate = new NodeTemplate(); + ToscaNodeType nodeTypeToSearch = ToscaNodeType.BLOCK_STORAGE; + nodeTemplate.setType(nodeTypeToSearch.getDisplayName()); + assertTrue(toscaAnalyzerService + .isTypeOf(nodeTemplate, nodeTypeToSearch.getDisplayName(), new ServiceTemplate(), + toscaServiceModelMock)); + } + + @Test + public void shouldReturnTrueIfNdTmpTypeIsFoundInSrvTmpNdTyAndNdTyDerivedFromRequestedType() { + String typeToMatch = ToscaNodeType.CINDER_VOLUME.getDisplayName(); + when(nodeTemplateMock.getType()).thenReturn(typeToMatch); + Map stNodeTypes = new HashMap<>(); + addNodeType(stNodeTypes, ToscaNodeType.COMPUTE.getDisplayName(), new NodeType()); + NodeType nodeType = createNodeType(ToscaNodeType.BLOCK_STORAGE.getDisplayName()); + addNodeType(stNodeTypes, typeToMatch, nodeType); + ServiceTemplate serviceTemplate = new ServiceTemplate(); + serviceTemplate.setNode_types(stNodeTypes); + assertTrue(toscaAnalyzerService + .isTypeOf(nodeTemplateMock, ToscaNodeType.BLOCK_STORAGE.getDisplayName(), serviceTemplate, + toscaServiceModelMock)); + + } + + @Test + public void shouldThrowCoreExceptionForInvalidNodeType() { + thrown.expect(CoreException.class); + thrown.expectMessage( + "NodeType 'AAA' or one of its derivedFrom node type hierarchy, is not defined in tosca service model"); + when(nodeTemplateMock.getType()).thenReturn("AAA"); + Map stNodeTypes = new HashMap<>(); + addNodeType(stNodeTypes, "notImportant", new NodeType()); + ServiceTemplate serviceTemplate = new ServiceTemplate(); + serviceTemplate.setNode_types(stNodeTypes); + toscaAnalyzerService + .isTypeOf(nodeTemplateMock, ToscaNodeType.COMPUTE.getDisplayName(), serviceTemplate, + toscaServiceModelMock); + } + + @Test + public void shouldThrowCoreExceptionForInvalidNodeType2Level() { + thrown.expect(CoreException.class); + thrown.expectMessage( + "NodeType 'A' or one of its derivedFrom node type hierarchy, is not defined in tosca service model"); + String typeToMatch = "A"; + when(nodeTemplateMock.getType()).thenReturn(typeToMatch); + Map stNodeTypes = new HashMap<>(); + addNodeType(stNodeTypes, "notImportant", new NodeType()); + addNodeType(stNodeTypes, "A", createNodeType("ADerivedFromB")); + addNodeType(stNodeTypes, "ADerivedFromB'", createNodeType("BDerivedFromC")); + ServiceTemplate serviceTemplate = new ServiceTemplate(); + serviceTemplate.setNode_types(stNodeTypes); + assertTrue(toscaAnalyzerService + .isTypeOf(nodeTemplateMock, "BDerivedFromC", serviceTemplate, toscaServiceModelMock)); + } + + @Test + public void shouldReturnTrueIfNdTmpTypeIsFoundInSrvTmpNdTyAndNotDerivedFromRequestedTypeBut2ndLevelDerivedFromMatch() { + String typeToMatch = "A"; + when(nodeTemplateMock.getType()).thenReturn(typeToMatch); + Map stNodeTypes = new HashMap<>(); + addNodeType(stNodeTypes, "notImportant", new NodeType()); + addNodeType(stNodeTypes, "A", createNodeType("ADerivedFromB")); + addNodeType(stNodeTypes, "ADerivedFromB", createNodeType("BDerivedFromC")); + ServiceTemplate serviceTemplate = new ServiceTemplate(); + serviceTemplate.setNode_types(stNodeTypes); + assertTrue(toscaAnalyzerService + .isTypeOf(nodeTemplateMock, "BDerivedFromC", serviceTemplate, toscaServiceModelMock)); + } + + private NodeType createNodeType(String derivedFrom) { + NodeType nodeType = new NodeType(); + nodeType.setDerived_from(derivedFrom); + return nodeType; + } + + private void addNodeType(Map stNodeTypes, String key, NodeType nodeType) { + stNodeTypes.put(key, nodeType); + } + + @Test + public void shouldReturnTrueIfNdTmpTypeIsFoundInSrvTmpNdTyButRequestedTypeNotMatchButFoundIn1stLevelImports() { + String typeToMatch = ToscaNodeType.CINDER_VOLUME.getDisplayName(); + when(nodeTemplateMock.getType()).thenReturn(typeToMatch); + ServiceTemplate mainST = new ServiceTemplate(); + Map imports = new HashMap<>(); + Import anImport = new Import(); + anImport.setFile("mainImport"); + imports.put("bla bla", anImport); + mainST.setImports(imports); + + //create searchable service template + Map stNodeTypes = new HashMap<>(); + addNodeType(stNodeTypes, ToscaNodeType.COMPUTE.getDisplayName(), new NodeType()); + NodeType nodeType = createNodeType(ToscaNodeType.BLOCK_STORAGE.getDisplayName()); + addNodeType(stNodeTypes, typeToMatch, nodeType); + ServiceTemplate serviceTemplate = new ServiceTemplate(); + serviceTemplate.setNode_types(stNodeTypes); + + // add service templates to tosca service model + Map serviceTemplates = toscaServiceModelMock.getServiceTemplates(); + serviceTemplates.put("testMainServiceTemplate", mainST); + serviceTemplates.put("mainImport", serviceTemplate); + when(toscaServiceModelMock.getServiceTemplates()).thenReturn(serviceTemplates); + + assertTrue(toscaAnalyzerService + .isTypeOf(nodeTemplateMock, ToscaNodeType.BLOCK_STORAGE.getDisplayName(), mainST, + toscaServiceModelMock)); + } + + @Test + public void shouldReturnTrueIfNdTmpTypeIsFoundInSrvTmpNdTyButRequestedTypeNotMatchButFoundIn2ndLevelImports() { + String typeToMatch = ToscaNodeType.CINDER_VOLUME.getDisplayName(); + when(nodeTemplateMock.getType()).thenReturn(typeToMatch); + ServiceTemplate mainST = new ServiceTemplate(); + Map imports = new HashMap<>(); + Import anImport = new Import(); + anImport.setFile("refToMainImport"); + imports.put("bla bla", anImport); + mainST.setImports(imports); + + //create searchable service template + Map stNodeTypes = new HashMap<>(); + addNodeType(stNodeTypes, ToscaNodeType.COMPUTE.getDisplayName(), new NodeType()); + NodeType nodeType = createNodeType(ToscaNodeType.BLOCK_STORAGE.getDisplayName()); + addNodeType(stNodeTypes, typeToMatch, nodeType); + ServiceTemplate serviceTemplate = new ServiceTemplate(); + serviceTemplate.setNode_types(stNodeTypes); + + // create 1st level service template with import only + ServiceTemplate firstLevelST = new ServiceTemplate(); + Map firstLevelImports = new HashMap<>(); + Import firstLevelImport = new Import(); + firstLevelImport.setFile("mainImport"); + firstLevelImports.put("bla bla 2", firstLevelImport); + + firstLevelST.setImports(firstLevelImports); + + // add service templates to tosca service model + Map serviceTemplates = toscaServiceModelMock.getServiceTemplates(); + serviceTemplates.put("testMainServiceTemplate", mainST); + serviceTemplates.put("refToMainImport", firstLevelST); + serviceTemplates.put("mainImport", serviceTemplate); + when(toscaServiceModelMock.getServiceTemplates()).thenReturn(serviceTemplates); + + assertTrue(toscaAnalyzerService + .isTypeOf(nodeTemplateMock, ToscaNodeType.BLOCK_STORAGE.getDisplayName(), mainST, + toscaServiceModelMock)); + } + + // not found at all should throw core exception + + +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/test/java/org/openecomp/sdc/tosca/services/impl/ToscaFileOutputServiceCsarImplTest.java b/openecomp-be/lib/openecomp-tosca-lib/src/test/java/org/openecomp/sdc/tosca/services/impl/ToscaFileOutputServiceCsarImplTest.java new file mode 100644 index 0000000000..963b8a6f57 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/test/java/org/openecomp/sdc/tosca/services/impl/ToscaFileOutputServiceCsarImplTest.java @@ -0,0 +1,150 @@ +package org.openecomp.sdc.tosca.services.impl; + +import org.openecomp.sdc.tosca.datatypes.ToscaServiceModel; +import org.openecomp.sdc.tosca.datatypes.model.Metadata; +import org.openecomp.sdc.tosca.datatypes.model.ServiceTemplate; +import org.openecomp.sdc.tosca.services.ToscaUtil; +import org.openecomp.core.utilities.file.FileContentHandler; +import org.junit.Assert; +import org.junit.Test; + +import java.io.File; +import java.io.FileOutputStream; +import java.io.IOException; +import java.nio.file.Files; +import java.nio.file.Paths; +import java.util.Enumeration; +import java.util.HashMap; +import java.util.Map; +import java.util.zip.ZipEntry; +import java.util.zip.ZipFile; + +public class ToscaFileOutputServiceCsarImplTest { + + private ToscaFileOutputServiceCsarImpl toscaFileOutputServiceCsarImpl = + new ToscaFileOutputServiceCsarImpl(); + + @Test + public void testCreationMetaFile() { + String createdMeta = toscaFileOutputServiceCsarImpl.createMetaFile("entryFile.yaml"); + String expectedMeta = + "TOSCA-Meta-File-Version: 1.0\n" + + "CSAR-Version: 1.1\n" + + "Created-By: ASDC Onboarding portal\n" + + "Entry-Definitions: Definitions" + File.separator + "entryFile.yaml"; + Assert.assertEquals(createdMeta.replaceAll("\\s+", ""), expectedMeta.replaceAll("\\s+", "")); + } + + @Test + public void testCSARFileCreationWithExternalArtifacts() throws IOException { + ServiceTemplate mainServiceTemplate = new ServiceTemplate(); + Metadata metadata1 = new Metadata(); + metadata1.setTemplate_author("OPENECOMP"); + metadata1.setTemplate_name("ST1"); + metadata1.setTemplate_version("1.0.0"); + mainServiceTemplate.setTosca_definitions_version("tosca_simple_yaml_1_0_0"); + mainServiceTemplate.setDescription("testing desc tosca service template"); + mainServiceTemplate.setMetadata(metadata1); + + ServiceTemplate additionalServiceTemplate = new ServiceTemplate(); + Metadata metadata2 = new Metadata(); + metadata2.setTemplate_author("OPENECOMP"); + metadata2.setTemplate_name("ST2"); + metadata2.setTemplate_version("1.0.0"); + additionalServiceTemplate.setTosca_definitions_version("tosca_simple_yaml_1_0_0"); + additionalServiceTemplate.setDescription("testing desc tosca service template"); + additionalServiceTemplate.setMetadata(metadata2); + + Map definitionsInput = new HashMap<>(); + definitionsInput + .put(ToscaUtil.getServiceTemplateFileName(mainServiceTemplate), mainServiceTemplate); + definitionsInput.put(ToscaUtil.getServiceTemplateFileName(additionalServiceTemplate), + additionalServiceTemplate); + + + Map dummyHeatArtifacts = new HashMap<>(); + String file1Content = "this is file number 1"; + String file2Content = "this is file number 2"; + String file1 = "file1.xml"; + dummyHeatArtifacts.put(file1, file1Content.getBytes()); + String file2 = "file2.yml"; + dummyHeatArtifacts.put(file2, file2Content.getBytes()); + + + FileContentHandler heatFiles = new FileContentHandler(); + heatFiles.putAll(dummyHeatArtifacts); + Map licenseArtifacts = new HashMap<>(); + + FileContentHandler licenseArtifactsFiles = new FileContentHandler(); + + licenseArtifacts.put( + ToscaFileOutputServiceCsarImpl.EXTERNAL_ARTIFACTS_FOLDER_NAME + File.separator + + "license-file-1.xml", file1Content.getBytes()); + licenseArtifacts.put( + ToscaFileOutputServiceCsarImpl.EXTERNAL_ARTIFACTS_FOLDER_NAME + File.separator + + "license-file-2.xml", file1Content.getBytes()); + + licenseArtifactsFiles.putAll(licenseArtifacts); + + byte[] csarFile = toscaFileOutputServiceCsarImpl.createOutputFile( + new ToscaServiceModel(heatFiles, definitionsInput, + ToscaUtil.getServiceTemplateFileName(mainServiceTemplate)), licenseArtifactsFiles); + + String resultFileName = "resultFile.zip"; + File file = new File(resultFileName); + FileOutputStream fos = new FileOutputStream(file); + fos.write(csarFile); + fos.close(); + + ZipFile zipFile = new ZipFile(resultFileName); + + Enumeration entries = zipFile.entries(); + + int count = 0; + while (entries.hasMoreElements()) { + count++; + entries.nextElement(); + } + Assert.assertEquals(7, count); + zipFile.close(); + Files.delete(Paths.get(file.getPath())); + } + + @Test + public void testCSARFileCreation_noArtifacts() throws IOException { + ServiceTemplate serviceTemplate = new ServiceTemplate(); + Metadata metadata = new Metadata(); + metadata.setTemplate_author("OPENECOMP"); + metadata.setTemplate_name("Test"); + metadata.setTemplate_version("1.0.0"); + serviceTemplate.setTosca_definitions_version("tosca_simple_yaml_1_0_0"); + serviceTemplate.setDescription("testing desc tosca service template"); + serviceTemplate.setMetadata(metadata); + Map definitionsInput = new HashMap<>(); + String serviceTemplateFileName = ToscaUtil.getServiceTemplateFileName(serviceTemplate); + definitionsInput.put(serviceTemplateFileName, serviceTemplate); + byte[] csarFile = toscaFileOutputServiceCsarImpl + .createOutputFile(new ToscaServiceModel(null, definitionsInput, serviceTemplateFileName), + null); + + + String resultFileName = "resultFile.zip"; + File file = new File(resultFileName); + FileOutputStream fos = new FileOutputStream(file); + fos.write(csarFile); + fos.close(); + + ZipFile zipFile = new ZipFile(resultFileName); + + Enumeration entries = zipFile.entries(); + + int count = 0; + while (entries.hasMoreElements()) { + count++; + entries.nextElement(); + } + Assert.assertEquals(2, count); + zipFile.close(); + Files.delete(Paths.get(file.getPath())); + } +} \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/analyzerService/NestedServiceTemplateReqTest.yaml b/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/analyzerService/NestedServiceTemplateReqTest.yaml new file mode 100644 index 0000000000..f64cb709f0 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/analyzerService/NestedServiceTemplateReqTest.yaml @@ -0,0 +1,176 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested +imports: + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + nested: + file: GlobalSubstitutionTypesServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui_image: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + p1: + hidden: false + immutable: false + type: string + description: UID of OAM network + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + security_group_name: + hidden: false + immutable: false + description: not impotrtant + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + node_templates: + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui_image + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + name: + get_input: + - cmaui_names + - 0 + cmaui_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: p1 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + cmaui1_port_1: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - subnet: subnetNameVal + ip_address: + get_input: + - cmaui_oam_ips + - 1 + - subnet: subnetNameVal2 + ip_address: + get_input: + - cmaui_oam_ips + - 1 + network: jsa_net + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: jsa_net1 + relationship: tosca.relationships.network.LinksTo + - link: + capability: tosca.capabilities.network.Linkable + node: jsa_net2 + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + jsa_net1: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + shared: true + network_name: + get_input: jsa_net_name + jsa_net2: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + shared: true + network_name: + get_input: jsa_net_name + groups: + nested: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested.yml + description: cmaui server template for vMMSC + members: + - server_cmaui + - cmaui_port_0 + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested + capabilities: + host_server_cmaui: + - server_cmaui + - host + os_server_cmaui: + - server_cmaui + - os + endpoint_server_cmaui: + - server_cmaui + - endpoint + binding_server_cmaui: + - server_cmaui + - binding + scalable_server_cmaui: + - server_cmaui + - scalable + attachment_cmaui_port_0: + - cmaui_port_0 + - attachment + requirements: + local_storage_server_cmaui: + - server_cmaui + - local_storage + link_cmaui_port_0: + - cmaui_port_0 + - link + link_cmaui_port_invalid: + - cmaui_port_9 + - link diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/analyzerService/ServiceTemplateSubstituteTest.yaml b/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/analyzerService/ServiceTemplateSubstituteTest.yaml new file mode 100644 index 0000000000..c4df76a1aa --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/analyzerService/ServiceTemplateSubstituteTest.yaml @@ -0,0 +1,89 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml +topology_template: + inputs: + shared_network_id: + hidden: false + immutable: false + type: string + description: network name of jsa log network + jsa_net_name: + hidden: false + immutable: false + type: string + description: network name of jsa log network + node_templates: + test_net: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + shared: true + network_name: + get_input: jsa_net_name + test_nested1: + type: org.openecomp.resource.abstract.nodes.heat.nested + directives: + - substitutable + properties: + p1: + get_input: shared_network_id + service_template_filter: + substitute_service_template: nestedServiceTemplate.yaml + requirements: + - link_cmaui_port_0: + capability: tosca.capabilities.network.Linkable + node: test_net + relationship: tosca.relationships.network.LinksTo + test_nested2: + type: org.openecomp.resource.abstract.nodes.heat.nested + directives: + - substitutable + properties: + p1: + get_input: shared_network_id + service_template_filter: + substitute_service_template: nestedServiceTemplate.yaml + requirements: + - link_cmaui_port_0: + capability: tosca.capabilities.network.Linkable + node: test_net + relationship: tosca.relationships.network.LinksTo + groups: + addOn: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/addOn.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - test_nested + main: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/main.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - test_net + outputs: + shared_network_id: + value: test_net \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/analyzerService/toscasubstitution/MainServiceTemplate.yaml b/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/analyzerService/toscasubstitution/MainServiceTemplate.yaml new file mode 100644 index 0000000000..65b90ef5b1 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/analyzerService/toscasubstitution/MainServiceTemplate.yaml @@ -0,0 +1,75 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Main +imports: + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml +topology_template: + inputs: + shared_network_id: + hidden: false + immutable: false + type: string + description: network name of jsa log network + jsa_net_name: + hidden: false + immutable: false + type: string + description: network name of jsa log network + node_templates: + test_net: + type: org.openecomp.resource.vl.nodes.heat.network.neutron.Net + properties: + shared: true + network_name: + get_input: jsa_net_name + test_nested: + type: org.openecomp.resource.abstract.nodes.heat.nested + directives: + - substitutable + properties: + p1: + get_input: shared_network_id + service_template_filter: + substitute_service_template: nestedServiceTemplate.yaml + requirements: + - link_cmaui_port_0: + capability: tosca.capabilities.network.Linkable + node: test_net + relationship: tosca.relationships.network.LinksTo + groups: + addOn: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/addOn.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - test_nested + main: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/main.yml + description: | + Version 2.0 02-09-2016 (Authors: John Doe, user PROD) + members: + - test_net + outputs: + shared_network_id: + value: test_net \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/analyzerService/toscasubstitution/nestedServiceTemplate.yaml b/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/analyzerService/toscasubstitution/nestedServiceTemplate.yaml new file mode 100644 index 0000000000..cd27e7ba1a --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/analyzerService/toscasubstitution/nestedServiceTemplate.yaml @@ -0,0 +1,130 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: nested +imports: + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml + nested: + file: GlobalSubstitutionTypesServiceTemplate.yaml +node_types: + org.openecomp.resource.vfc.nodes.heat.cmaui_image: + derived_from: org.openecomp.resource.vfc.nodes.heat.nova.Server +topology_template: + inputs: + cmaui_names: + hidden: false + immutable: false + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + p1: + hidden: false + immutable: false + type: string + description: UID of OAM network + cmaui_image: + hidden: false + immutable: false + type: string + description: Image for CMAUI server + cmaui_flavor: + hidden: false + immutable: false + type: string + description: Flavor for CMAUI server + security_group_name: + hidden: false + immutable: false + description: not impotrtant + availability_zone_0: + label: availabilityzone name + hidden: false + immutable: false + type: string + description: availabilityzone name + node_templates: + server_cmaui: + type: org.openecomp.resource.vfc.nodes.heat.cmaui_image + properties: + flavor: + get_input: cmaui_flavor + availability_zone: + get_input: availability_zone_0 + image: + get_input: cmaui_image + name: + get_input: + - cmaui_names + - 0 + cmaui_port_0: + type: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + properties: + replacement_policy: AUTO + security_groups: + - get_input: security_group_name + fixed_ips: + - ip_address: + get_input: + - cmaui_oam_ips + - 0 + network: + get_input: p1 + requirements: + - binding: + capability: tosca.capabilities.network.Bindable + node: server_cmaui + relationship: tosca.relationships.network.BindsTo + groups: + nested: + type: org.openecomp.groups.heat.HeatStack + properties: + heat_file: ../Artifacts/nested.yml + description: cmaui server template for vMMSC + members: + - server_cmaui + - cmaui_port_0 + substitution_mappings: + node_type: org.openecomp.resource.abstract.nodes.heat.nested + capabilities: + host_server_cmaui: + - server_cmaui + - host + os_server_cmaui: + - server_cmaui + - os + endpoint_server_cmaui: + - server_cmaui + - endpoint + binding_server_cmaui: + - server_cmaui + - binding + scalable_server_cmaui: + - server_cmaui + - scalable + attachment_cmaui_port_0: + - cmaui_port_0 + - attachment + requirements: + local_storage_server_cmaui: + - server_cmaui + - local_storage + link_cmaui_port_0: + - cmaui_port_0 + - link \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/AbstractSubstituteGlobalTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/AbstractSubstituteGlobalTypesServiceTemplate.yaml new file mode 100644 index 0000000000..8813b0abf6 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/AbstractSubstituteGlobalTypesServiceTemplate.yaml @@ -0,0 +1,47 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: AbstractSubstituteGlobalTypes + template_version: 1.0.0 +description: Abstract Substitute Global Types +imports: + common_definitions: + file: CommonGlobalTypesServiceTemplate.yaml +data_types: + org.openecomp.datatypes.heat.substitution.SubstitutionFilter: + derived_from: tosca.datatypes.Root + description: Substitution Filter + properties: + substitute_service_template: + type: string + description: Substitute Service Template + required: true + status: SUPPORTED + index_variable: + type: string + description: Index variable + required: false + default: '%index%' + status: SUPPORTED + constraints: + - min_length: 3 + count: + type: string + description: Count + required: false + default: 1 + status: SUPPORTED + mandatory: + type: boolean + description: Mandatory + required: false + default: true + status: SUPPORTED +node_types: + org.openecomp.resource.abstract.nodes.AbstractSubstitute: + derived_from: tosca.nodes.Root + properties: + service_template_filter: + type: org.openecomp.datatypes.heat.substitution.SubstitutionFilter + description: Substitution Filter + required: true + status: SUPPORTED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/CinderVolumeGlobalTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/CinderVolumeGlobalTypesServiceTemplate.yaml new file mode 100644 index 0000000000..3ef94f22e7 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/CinderVolumeGlobalTypesServiceTemplate.yaml @@ -0,0 +1,176 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: CinderVolumeGlobalTypes + template_version: 1.0.0 +description: Cinder Volume TOSCA Global Types +relationship_types: + org.openecomp.relationships.heat.cinder.VolumeAttachesTo: + derived_from: tosca.relationships.AttachesTo + description: This type represents an attachment relationship for associating volume + properties: + volume_id: + type: string + description: The ID of the volume to be attached + required: true + status: SUPPORTED + location: + type: string + description: The location where the volume is exposed on the instance, mountpoint + required: false + status: SUPPORTED + instance_uuid: + type: string + description: The ID of the server to which the volume attaches + required: true + status: SUPPORTED + attributes: + show: + type: string + description: Detailed information about resource + status: SUPPORTED +node_types: + org.openecomp.resource.vfc.nodes.heat.cinder.Volume: + derived_from: tosca.nodes.BlockStorage + properties: + availability_zone: + type: string + description: The availability zone in which the volume will be created + required: false + status: SUPPORTED + image: + type: string + description: If specified, the name or ID of the image to create the volume from + required: false + status: SUPPORTED + metadata: + type: map + description: Key/value pairs to associate with the volume + required: false + status: SUPPORTED + entry_schema: + type: string + volume_type: + type: string + description: If specified, the type of volume to use, mapping to a specific backend + required: false + status: SUPPORTED + description: + type: string + description: A description of the volume + required: false + status: SUPPORTED + device_type: + type: string + description: Device type + required: false + status: SUPPORTED + constraints: + - valid_values: + - cdrom + - disk + disk_bus: + type: string + description: 'Bus of the device: hypervisor driver chooses a suitable default + if omitted' + required: false + status: SUPPORTED + constraints: + - valid_values: + - ide + - lame_bus + - scsi + - usb + - virtio + backup_id: + type: string + description: If specified, the backup to create the volume from + required: false + status: SUPPORTED + source_volid: + type: string + description: If specified, the volume to use as source + required: false + status: SUPPORTED + boot_index: + type: integer + description: Integer used for ordering the boot disks + required: false + status: SUPPORTED + size: + type: scalar-unit.size + description: The requested storage size (default unit is MB) + required: false + status: SUPPORTED + constraints: + - greater_or_equal: 1 GB + read_only: + type: boolean + description: Enables or disables read-only access mode of volume + required: false + status: SUPPORTED + name: + type: string + description: A name used to distinguish the volume + required: false + status: SUPPORTED + scheduler_hints: + type: map + description: Arbitrary key-value pairs specified by the client to help the Cinder scheduler creating a volume + required: false + status: SUPPORTED + entry_schema: + type: string + swap_size: + type: scalar-unit.size + description: The size of the swap, in MB + required: false + status: SUPPORTED + delete_on_termination: + type: boolean + description: Indicate whether the volume should be deleted when the server is terminated + required: false + status: SUPPORTED + multiattach: + type: boolean + description: Whether allow the volume to be attached more than once + required: false + status: SUPPORTED + attributes: + display_description: + type: string + description: Description of the volume + status: SUPPORTED + attachments: + type: string + description: The list of attachments of the volume + status: SUPPORTED + entry_schema: + type: string + encrypted: + type: boolean + description: Boolean indicating if the volume is encrypted or not + status: SUPPORTED + show: + type: string + description: Detailed information about resource + status: SUPPORTED + created_at: + type: timestamp + description: The timestamp indicating volume creation + status: SUPPORTED + display_name: + type: string + description: Name of the volume + status: SUPPORTED + metadata_values: + type: map + description: Key/value pairs associated with the volume in raw dict form + status: SUPPORTED + bootable: + type: boolean + description: Boolean indicating if the volume can be booted or not + status: SUPPORTED + status: + type: string + description: The current status of the volume + status: SUPPORTED diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/CommonGlobalTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/CommonGlobalTypesServiceTemplate.yaml new file mode 100644 index 0000000000..1a183e9c50 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/CommonGlobalTypesServiceTemplate.yaml @@ -0,0 +1,210 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: CommonGlobalTypes + template_version: 1.0.0 +description: TOSCA Global Types +data_types: + org.openecomp.datatypes.heat.network.AddressPair: + derived_from: tosca.datatypes.Root + description: MAC/IP address pairs + properties: + mac_address: + type: string + description: MAC address + required: false + status: SUPPORTED + ip_address: + type: string + description: IP address + required: false + status: SUPPORTED + org.openecomp.datatypes.heat.network.subnet.HostRoute: + derived_from: tosca.datatypes.Root + description: Host route info for the subnet + properties: + destination: + type: string + description: The destination for static route + required: false + status: SUPPORTED + nexthop: + type: string + description: The next hop for the destination + required: false + status: SUPPORTED + org.openecomp.datatypes.heat.network.neutron.Subnet: + derived_from: tosca.datatypes.Root + description: A subnet represents an IP address block that can be used for assigning IP addresses to virtual instances + properties: + tenant_id: + type: string + description: The ID of the tenant who owns the network + required: false + status: SUPPORTED + enable_dhcp: + type: boolean + description: Set to true if DHCP is enabled and false if DHCP is disabled + required: false + default: true + status: SUPPORTED + ipv6_address_mode: + type: string + description: IPv6 address mode + required: false + status: SUPPORTED + constraints: + - valid_values: + - dhcpv6-stateful + - dhcpv6-stateless + - slaac + ipv6_ra_mode: + type: string + description: IPv6 RA (Router Advertisement) mode + required: false + status: SUPPORTED + constraints: + - valid_values: + - dhcpv6-stateful + - dhcpv6-stateless + - slaac + value_specs: + type: map + description: Extra parameters to include in the request + required: false + default: { + } + status: SUPPORTED + entry_schema: + type: string + allocation_pools: + type: list + description: The start and end addresses for the allocation pools + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.AllocationPool + subnetpool: + type: string + description: The name or ID of the subnet pool + required: false + status: SUPPORTED + dns_nameservers: + type: list + description: A specified set of DNS name servers to be used + required: false + default: [ + ] + status: SUPPORTED + entry_schema: + type: string + host_routes: + type: list + description: The gateway IP address + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.subnet.HostRoute + ip_version: + type: integer + description: The gateway IP address + required: false + default: 4 + status: SUPPORTED + constraints: + - valid_values: + - '4' + - '6' + name: + type: string + description: The name of the subnet + required: false + status: SUPPORTED + prefixlen: + type: integer + description: Prefix length for subnet allocation from subnet pool + required: false + status: SUPPORTED + constraints: + - greater_or_equal: 0 + cidr: + type: string + description: The CIDR + required: false + status: SUPPORTED + gateway_ip: + type: string + description: The gateway IP address + required: false + status: SUPPORTED + org.openecomp.datatypes.heat.network.AllocationPool: + derived_from: tosca.datatypes.Root + description: The start and end addresses for the allocation pool + properties: + start: + type: string + description: Start address for the allocation pool + required: false + status: SUPPORTED + end: + type: string + description: End address for the allocation pool + required: false + status: SUPPORTED +relationship_types: + org.openecomp.relationships.AttachesTo: + derived_from: tosca.relationships.Root + description: This type represents an attachment relationship +group_types: + org.openecomp.groups.heat.HeatStack: + derived_from: tosca.groups.Root + description: Grouped all heat resources which are in the same heat stack + properties: + heat_file: + type: string + description: Heat file which associate to this group/heat stack + required: true + status: SUPPORTED + description: + type: string + description: Heat file description + required: false + status: SUPPORTED +policy_types: + org.openecomp.policies.placement.Colocate: + derived_from: tosca.policy.placement + description: Keep associated nodes (groups of nodes) based upon affinity value + properties: + name: + type: string + description: The name of the policy + required: false + status: SUPPORTED + affinity: + type: string + description: affinity + required: true + status: SUPPORTED + constraints: + - valid_values: + - host + - region + - compute + org.openecomp.policies.placement.Antilocate: + derived_from: tosca.policy.placement + description: My placement policy for separation based upon container type value + properties: + name: + type: string + description: The name of the policy + required: false + status: SUPPORTED + container_type: + type: string + description: container type + required: false + status: SUPPORTED + constraints: + - valid_values: + - host + - region + - compute diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/ContrailNetworkRuleGlobalTypeServiceTemplate.yaml b/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/ContrailNetworkRuleGlobalTypeServiceTemplate.yaml new file mode 100644 index 0000000000..98317310fa --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/ContrailNetworkRuleGlobalTypeServiceTemplate.yaml @@ -0,0 +1,117 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: ContrailNetworkRuleGlobalType + template_version: 1.0.0 +description: Contrail Network Rule Global Types +imports: + common_definitions: + file: CommonGlobalTypesServiceTemplate.yaml +data_types: + org.openecomp.datatypes.heat.contrail.network.rule.PortPairs: + derived_from: tosca.datatypes.Root + description: source and destination port pairs + properties: + start_port: + type: string + description: Start port + required: false + status: SUPPORTED + end_port: + type: string + description: End port + required: false + status: SUPPORTED + org.openecomp.datatypes.heat.contrail.network.rule.Rule: + derived_from: tosca.datatypes.Root + description: policy rule + properties: + src_ports: + type: list + description: Source ports + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.contrail.network.rule.PortPairs + protocol: + type: string + description: Protocol + required: false + status: SUPPORTED + dst_addresses: + type: list + description: Destination addresses + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.contrail.network.rule.VirtualNetwork + apply_service: + type: string + description: Service to apply + required: false + status: SUPPORTED + dst_ports: + type: list + description: Destination ports + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.contrail.network.rule.PortPairs + src_addresses: + type: list + description: Source addresses + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.contrail.network.rule.VirtualNetwork + direction: + type: string + description: Direction + required: false + status: SUPPORTED + org.openecomp.datatypes.heat.contrail.network.rule.RuleList: + derived_from: tosca.datatypes.Root + description: list of policy rules + properties: + policy_rule: + type: list + description: Contrail network rule + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.contrail.network.rule.Rule + org.openecomp.datatypes.heat.contrail.network.rule.VirtualNetwork: + derived_from: tosca.datatypes.Root + description: source and destination addresses + properties: + virtual_network: + type: string + description: Virtual network + required: false + status: SUPPORTED +node_types: + org.openecomp.resource.nodes.heat.network.contrail.NetworkRules: + derived_from: tosca.nodes.Root + properties: + entries: + type: org.openecomp.datatypes.heat.contrail.network.rule.RuleList + description: A symbolic name for this contrail network rule + required: false + status: SUPPORTED + name: + type: string + description: A symbolic name for this contrail network rule + required: false + status: SUPPORTED + attributes: + fq_name: + type: string + description: fq_name + status: SUPPORTED + requirements: + - network: + capability: tosca.capabilities.Attachment + node: tosca.nodes.network.Network + relationship: org.openecomp.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml b/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml new file mode 100644 index 0000000000..0927e3dd0e --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml @@ -0,0 +1,71 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: ContrailVirtualNetworkGlobalType + template_version: 1.0.0 +description: Contrail Virtual Network Global Types +imports: + common_definitions: + file: CommonGlobalTypesServiceTemplate.yaml +node_types: + org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork: + derived_from: tosca.nodes.network.Network + properties: + shared: + type: string + description: Is virtual network shared + required: false + status: SUPPORTED + forwarding_mode: + type: string + description: forwarding mode of the virtual network + required: false + status: SUPPORTED + external: + type: string + description: Is virtual network external + required: false + status: SUPPORTED + flood_unknown_unicast: + type: string + description: flood L2 packets on network + required: false + status: SUPPORTED + route_targets: + type: list + description: route targets associated with the virtual network + required: false + status: SUPPORTED + entry_schema: + type: string + subnets: + type: map + description: Network related subnets + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.neutron.Subnet + attributes: + subnets_name: + type: list + description: Subnets name of this network + status: SUPPORTED + entry_schema: + type: string + subnets_show: + type: map + description: Detailed information about each subnet + status: SUPPORTED + entry_schema: + type: string + subnets: + type: map + description: Network related subnets + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.neutron.Subnet + capabilities: + attachment: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/GlobalSubstitutionTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/GlobalSubstitutionTypesServiceTemplate.yaml new file mode 100644 index 0000000000..08c47bc646 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/GlobalSubstitutionTypesServiceTemplate.yaml @@ -0,0 +1,93 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: GlobalSubstitutionTypes +imports: + NeutronPortGlobalTypes: + file: NeutronPortGlobalTypesServiceTemplate.yaml + NeutronNetGlobalTypes: + file: NeutronNetGlobalTypesServiceTemplate.yaml + CommonGlobalTypes: + file: CommonGlobalTypesServiceTemplate.yaml + CinderVolumeGlobalTypes: + file: CinderVolumeGlobalTypesServiceTemplate.yaml + ContrailNetworkRuleGlobalType: + file: ContrailNetworkRuleGlobalTypeServiceTemplate.yaml + NeutronSecurityRulesGlobalTypes: + file: NeutronSecurityRulesGlobalTypesServiceTemplate.yaml + NovaServerGlobalTypes: + file: NovaServerGlobalTypesServiceTemplate.yaml + ContrailVirtualNetworkGlobalType: + file: ContrailVirtualNetworkGlobalTypeServiceTemplate.yaml + AbstractSubstituteGlobalTypes: + file: AbstractSubstituteGlobalTypesServiceTemplate.yaml +node_types: + org.openecomp.resource.abstract.nodes.heat.nested: + derived_from: org.openecomp.resource.abstract.nodes.AbstractSubstitute + properties: + cmaui_names: + type: list + description: CMAUI1, CMAUI2 server names + entry_schema: + type: String + p1: + type: string + description: UID of OAM network + cmaui_image: + type: string + description: Image for CMAUI server + cmaui_flavor: + type: string + description: Flavor for CMAUI server + security_group_name: + description: not impotrtant + availability_zone_0: + type: string + description: availabilityzone name + requirements: + - local_storage_server_cmaui: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + - link_cmaui_port_0: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + occurrences: + - 1 + - 1 + capabilities: + host_server_cmaui: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + os_server_cmaui: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + endpoint_server_cmaui: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + binding_server_cmaui: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + scalable_server_cmaui: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + attachment_cmaui_port_0: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/NativeTypesServiceTemplateServiceTemplate.yaml b/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/NativeTypesServiceTemplateServiceTemplate.yaml new file mode 100644 index 0000000000..e7dfd49ed9 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/NativeTypesServiceTemplateServiceTemplate.yaml @@ -0,0 +1,194 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: NativeTypesServiceTemplate + template_version: 1.0.0 +description: TOSCA Native Node Types +node_types: + tosca.nodes.Compute: + derived_from: tosca.nodes.Root + attributes: + private_address: + type: string + description: private address + status: SUPPORTED + public_address: + type: string + description: public_address + status: SUPPORTED + networks: + type: map + description: networks + status: SUPPORTED + entry_schema: + type: tosca.datatypes.network.NetworkInfo + ports: + type: map + description: ports + status: SUPPORTED + entry_schema: + type: tosca.datatypes.network.PortInfo + requirements: + - local_storage: + capability: tosca.capabilities.Attachment + node: tosca.nodes.BlockStorage + relationship: tosca.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED + capabilities: + scalable: + type: tosca.capabilities.Scalable + occurrences: + - 1 + - UNBOUNDED + endpoint: + type: tosca.capabilities.Endpoint.Admin + occurrences: + - 1 + - UNBOUNDED + os: + type: tosca.capabilities.OperatingSystem + occurrences: + - 1 + - UNBOUNDED + host: + type: tosca.capabilities.Container + valid_source_types: + - tosca.nodes.SoftwareComponent + occurrences: + - 1 + - UNBOUNDED + binding: + type: tosca.capabilities.network.Bindable + occurrences: + - 1 + - UNBOUNDED + tosca.nodes.network.Port: + derived_from: tosca.nodes.Root + properties: + ip_range_end: + type: string + required: false + status: SUPPORTED + ip_range_start: + type: string + required: false + status: SUPPORTED + ip_address: + type: string + required: false + status: SUPPORTED + is_default: + type: boolean + required: false + default: false + status: SUPPORTED + order: + type: integer + required: true + default: 0 + status: SUPPORTED + constraints: + - greater_or_equal: 0 + requirements: + - link: + capability: tosca.capabilities.network.Linkable + node: tosca.nodes.Root + relationship: tosca.relationships.network.LinksTo + - binding: + capability: tosca.capabilities.network.Bindable + node: tosca.nodes.Root + relationship: tosca.relationships.network.BindsTo + tosca.nodes.Root: + attributes: + tosca_name: + type: string + description: tosca name + status: SUPPORTED + state: + type: string + description: state + status: SUPPORTED + tosca_id: + type: string + description: tosca id + status: SUPPORTED + interfaces: { + } + tosca.nodes.network.Network: + derived_from: tosca.nodes.Root + properties: + physical_network: + type: string + required: false + status: SUPPORTED + segmentation_id: + type: string + required: false + status: SUPPORTED + network_id: + type: string + required: false + status: SUPPORTED + ip_version: + type: integer + required: false + default: 4 + status: SUPPORTED + constraints: + - valid_values: + - 4 + - 6 + start_ip: + type: string + required: false + status: SUPPORTED + network_name: + type: string + required: false + status: SUPPORTED + cidr: + type: string + required: false + status: SUPPORTED + gateway_ip: + type: string + required: false + status: SUPPORTED + network_type: + type: string + required: false + status: SUPPORTED + end_ip: + type: string + required: false + status: SUPPORTED + capabilities: + link: + type: tosca.capabilities.network.Linkable + occurrences: + - 1 + - UNBOUNDED + tosca.nodes.BlockStorage: + derived_from: tosca.nodes.Root + properties: + size: + type: scalar-unit.size + required: false + status: SUPPORTED + constraints: + - greater_or_equal: 1 MB + volume_id: + type: string + required: false + status: SUPPORTED + snapshot_id: + type: string + required: false + status: SUPPORTED + capabilities: + attachment: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/NeutronNetGlobalTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/NeutronNetGlobalTypesServiceTemplate.yaml new file mode 100644 index 0000000000..e80e2727c7 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/NeutronNetGlobalTypesServiceTemplate.yaml @@ -0,0 +1,97 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: NeutronNetGlobalTypes + template_version: 1.0.0 +description: Neutron Network TOSCA Global Types +imports: + common_definitions: + file: CommonGlobalTypesServiceTemplate.yaml +node_types: + org.openecomp.resource.vl.nodes.heat.network.neutron.Net: + derived_from: tosca.nodes.network.Network + properties: + dhcp_agent_ids: + type: list + description: The IDs of the DHCP agent to schedule the network + required: false + status: SUPPORTED + entry_schema: + type: string + tenant_id: + type: string + description: The ID of the tenant which will own the network + required: false + status: SUPPORTED + port_security_enabled: + type: boolean + description: Flag to enable/disable port security on the network + required: false + status: SUPPORTED + shared: + type: boolean + description: Whether this network should be shared across all tenants + required: false + default: false + status: SUPPORTED + admin_state_up: + type: boolean + description: A boolean value specifying the administrative status of the network + required: false + default: true + status: SUPPORTED + qos_policy: + type: string + description: The name or ID of QoS policy to attach to this network + required: false + status: SUPPORTED + subnets: + type: map + description: Network related subnets + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.neutron.Subnet + value_specs: + type: map + description: Extra parameters to include in the request + required: false + default: { + } + status: SUPPORTED + entry_schema: + type: string + attributes: + qos_policy_id: + type: string + description: The QoS policy ID attached to this network + status: SUPPORTED + show: + type: string + description: Detailed information about resource + status: SUPPORTED + subnets_name: + type: list + description: Subnets name of this network + status: SUPPORTED + entry_schema: + type: string + subnets: + type: map + description: Network related subnets + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.neutron.Subnet + mtu: + type: scalar-unit.size + description: The maximum transmission unit size(in bytes) for the network + status: SUPPORTED + status: + type: string + description: The status of the network + status: SUPPORTED + capabilities: + attachment: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/NeutronPortGlobalTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/NeutronPortGlobalTypesServiceTemplate.yaml new file mode 100644 index 0000000000..a337d6ed18 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/NeutronPortGlobalTypesServiceTemplate.yaml @@ -0,0 +1,151 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: NeutronPortGlobalTypes + template_version: 1.0.0 +description: Neutron Port TOSCA Global Types +imports: + common_definitions: + file: CommonGlobalTypesServiceTemplate.yaml +data_types: + org.openecomp.datatypes.heat.neutron.port.FixedIps: + derived_from: tosca.datatypes.Root + description: subnet/ip_address + properties: + subnet: + type: string + description: Subnet in which to allocate the IP address for this port + required: false + status: SUPPORTED + ip_address: + type: string + description: IP address desired in the subnet for this port + required: false + status: SUPPORTED +node_types: + org.openecomp.resource.cp.nodes.heat.network.neutron.Port: + derived_from: tosca.nodes.network.Port + properties: + port_security_enabled: + type: boolean + description: Flag to enable/disable port security on the network + required: false + status: SUPPORTED + device_id: + type: string + description: Device ID of this port + required: false + status: SUPPORTED + qos_policy: + type: string + description: The name or ID of QoS policy to attach to this network + required: false + status: SUPPORTED + allowed_address_pairs: + type: list + description: Additional MAC/IP address pairs allowed to pass through the port + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.AddressPair + binding:vnic_type: + type: string + description: The vnic type to be bound on the neutron port + required: false + status: SUPPORTED + constraints: + - valid_values: + - macvtap + - direct + - normal + value_specs: + type: map + description: Extra parameters to include in the request + required: false + default: { + } + status: SUPPORTED + entry_schema: + type: string + device_owner: + type: string + description: Name of the network owning the port + required: false + status: SUPPORTED + network: + type: string + description: Network this port belongs to + required: false + status: SUPPORTED + replacement_policy: + type: string + description: Policy on how to respond to a stack-update for this resource + required: false + default: AUTO + status: SUPPORTED + constraints: + - valid_values: + - REPLACE_ALWAYS + - AUTO + security_groups: + type: list + description: List of security group names or IDs + required: false + status: SUPPORTED + entry_schema: + type: string + fixed_ips: + type: list + description: Desired IPs for this port + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.neutron.port.FixedIps + mac_address: + type: string + description: MAC address to give to this port + required: false + status: SUPPORTED + admin_state_up: + type: boolean + description: A boolean value specifying the administrative status of the network + required: false + default: true + status: SUPPORTED + name: + type: string + description: A symbolic name for this port + required: false + status: SUPPORTED + attributes: + tenant_id: + type: string + description: Tenant owning the port + status: SUPPORTED + network_id: + type: string + description: Unique identifier for the network owning the port + status: SUPPORTED + qos_policy_id: + type: string + description: The QoS policy ID attached to this network + status: SUPPORTED + show: + type: string + description: Detailed information about resource + status: SUPPORTED + subnets: + type: list + description: Subnets of this network + status: SUPPORTED + entry_schema: + type: string + status: + type: string + description: The status of the network + status: SUPPORTED + capabilities: + attachment: + type: tosca.capabilities.Attachment + occurrences: + - 1 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/NeutronSecurityRulesGlobalTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/NeutronSecurityRulesGlobalTypesServiceTemplate.yaml new file mode 100644 index 0000000000..49c9a102c8 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/NeutronSecurityRulesGlobalTypesServiceTemplate.yaml @@ -0,0 +1,116 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: NeutronSecurityRulesGlobalTypes + template_version: 1.0.0 +description: Neutron Security Rules TOSCA Global Types +imports: + common_definitions: + file: CommonGlobalTypesServiceTemplate.yaml +data_types: + org.openecomp.datatypes.heat.network.neutron.SecurityRules.Rule: + derived_from: tosca.datatypes.Root + description: Rules Pairs + properties: + remote_group_id: + type: string + description: The remote group ID to be associated with this security group rule + required: false + status: SUPPORTED + protocol: + type: string + description: The protocol that is matched by the security group rule + required: false + status: SUPPORTED + constraints: + - valid_values: + - tcp + - udp + - icmp + ethertype: + type: string + description: Ethertype of the traffic + required: false + default: IPv4 + status: SUPPORTED + constraints: + - valid_values: + - IPv4 + - IPv6 + port_range_max: + type: integer + description: 'The maximum port number in the range that is matched by the + security group rule. ' + required: false + status: SUPPORTED + constraints: + - in_range: + - 0 + - 65535 + remote_ip_prefix: + type: string + description: The remote IP prefix (CIDR) to be associated with this security group rule + required: false + status: SUPPORTED + remote_mode: + type: string + description: Whether to specify a remote group or a remote IP prefix + required: false + default: remote_ip_prefix + status: SUPPORTED + constraints: + - valid_values: + - remote_ip_prefix + - remote_group_id + direction: + type: string + description: The direction in which the security group rule is applied + required: false + default: ingress + status: SUPPORTED + constraints: + - valid_values: + - egress + - ingress + port_range_min: + type: integer + description: The minimum port number in the range that is matched by the security group rule. + required: false + status: SUPPORTED + constraints: + - in_range: + - 0 + - 65535 +node_types: + org.openecomp.resource.nodes.heat.network.neutron.SecurityRules: + derived_from: tosca.nodes.Root + properties: + description: + type: string + description: Description of the security group + required: false + status: SUPPORTED + name: + type: string + description: A symbolic name for this security group, which is not required to be unique. + required: false + status: SUPPORTED + rules: + type: list + description: List of security group rules + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.neutron.SecurityRules.Rule + attributes: + show: + type: string + description: Detailed information about resource + status: SUPPORTED + requirements: + - port: + capability: tosca.capabilities.Attachment + node: org.openecomp.resource.cp.nodes.heat.network.neutron.Port + relationship: org.openecomp.relationships.AttachesTo + occurrences: + - 0 + - UNBOUNDED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/NovaServerGlobalTypesServiceTemplate.yaml b/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/NovaServerGlobalTypesServiceTemplate.yaml new file mode 100644 index 0000000000..2253a1e4af --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/globalServiceTemplates/NovaServerGlobalTypesServiceTemplate.yaml @@ -0,0 +1,249 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: NovaServerGlobalTypes + template_version: 1.0.0 +description: Nova Server TOSCA Global Types +imports: + common_definitions: + file: CommonGlobalTypesServiceTemplate.yaml +data_types: + org.openecomp.datatypes.heat.novaServer.network.PortExtraProperties: + derived_from: tosca.datatypes.Root + description: Nova server network expand properties for port + properties: + port_security_enabled: + type: boolean + description: Flag to enable/disable port security on the port + required: false + status: SUPPORTED + mac_address: + type: string + description: MAC address to give to this port + required: false + status: SUPPORTED + admin_state_up: + type: boolean + description: The administrative state of this port + required: false + default: true + status: SUPPORTED + qos_policy: + type: string + description: The name or ID of QoS policy to attach to this port + required: false + status: SUPPORTED + allowed_address_pairs: + type: list + description: Additional MAC/IP address pairs allowed to pass through the port + required: false + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.network.AddressPair + binding:vnic_type: + type: string + description: The vnic type to be bound on the neutron port + required: false + status: SUPPORTED + constraints: + - valid_values: + - macvtap + - direct + - normal + value_specs: + type: map + description: Extra parameters to include in the request + required: false + default: { + } + status: SUPPORTED + entry_schema: + type: string + org.openecomp.datatypes.heat.novaServer.network.AddressInfo: + derived_from: tosca.datatypes.network.NetworkInfo + description: Network addresses with corresponding port id + properties: + port_id: + type: string + description: Port id + required: false + status: SUPPORTED +node_types: + org.openecomp.resource.vfc.nodes.heat.nova.Server: + derived_from: tosca.nodes.Compute + properties: + admin_pass: + type: string + description: The administrator password for the server + required: false + status: SUPPORTED + availability_zone: + type: string + description: Availability zone to create servers in + required: false + status: SUPPORTED + image: + type: string + description: The ID or name of the image to boot with + required: false + status: SUPPORTED + image_update_policy: + type: string + description: Policy on how to apply an image-id update + required: false + default: REBUILD + status: SUPPORTED + constraints: + - valid_values: + - REBUILD_PRESERVE_EPHEMERAL + - REPLACE + - REBUILD + metadata: + type: map + description: Arbitrary key/value metadata to store for this server + required: false + status: SUPPORTED + constraints: + - max_length: 255 + entry_schema: + type: string + constraints: + - max_length: 255 + user_data_update_policy: + type: string + description: Policy on how to apply a user_data update + required: false + default: REPLACE + status: SUPPORTED + constraints: + - valid_values: + - REPLACE + - IGNORE + flavor_update_policy: + type: string + description: Policy on how to apply a flavor update + required: false + default: RESIZE + status: SUPPORTED + constraints: + - valid_values: + - RESIZE + - REPLACE + user_data: + type: string + description: User data script to be executed by cloud-init + required: false + default: '' + status: SUPPORTED + flavor: + type: string + description: The ID or name of the flavor to boot onto + required: true + status: SUPPORTED + key_name: + type: string + description: Name of keypair to inject into the server + required: false + status: SUPPORTED + reservation_id: + type: string + description: A UUID for the set of servers being requested + required: false + status: SUPPORTED + security_groups: + type: list + description: List of security group names or IDs + required: false + default: [ + ] + status: SUPPORTED + entry_schema: + type: string + config_drive: + type: boolean + description: enable config drive on the server + required: false + status: SUPPORTED + personality: + type: map + description: A map of files to create/overwrite on the server upon boot + required: false + default: { + } + status: SUPPORTED + entry_schema: + type: string + software_config_transport: + type: string + description: How the server should receive the metadata required for software configuration + required: false + default: POLL_SERVER_CFN + status: SUPPORTED + constraints: + - valid_values: + - POLL_SERVER_CFN + - POLL_SERVER_HEAT + - POLL_TEMP_URL + - ZAQAR_MESSAGE + user_data_format: + type: string + description: How the user_data should be formatted for the server + required: false + default: HEAT_CFNTOOLS + status: SUPPORTED + constraints: + - valid_values: + - SOFTWARE_CONFIG + - RAW + - HEAT_CFNTOOLS + diskConfig: + type: string + description: Control how the disk is partitioned when the server is created + required: false + status: SUPPORTED + constraints: + - valid_values: + - AUTO + - MANUAL + name: + type: string + description: Server name + required: false + status: SUPPORTED + scheduler_hints: + type: map + description: Arbitrary key-value pairs specified by the client to help boot a server + required: false + status: SUPPORTED + entry_schema: + type: string + attributes: + accessIPv4: + type: string + description: The manually assigned alternative public IPv4 address of the server + status: SUPPORTED + addresses: + type: map + description: A dict of all network addresses with corresponding port_id + status: SUPPORTED + entry_schema: + type: org.openecomp.datatypes.heat.novaServer.network.AddressInfo + accessIPv6: + type: string + description: The manually assigned alternative public IPv6 address of the server + status: SUPPORTED + instance_name: + type: string + description: AWS compatible instance name + status: SUPPORTED + name: + type: string + description: Name of the server + status: SUPPORTED + show: + type: string + description: Detailed information about resource + status: SUPPORTED + console_urls: + type: string + description: URLs of servers consoles + status: SUPPORTED \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/model/serviceTemplate.yaml b/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/model/serviceTemplate.yaml new file mode 100644 index 0000000000..612bc2d2fa --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/model/serviceTemplate.yaml @@ -0,0 +1,116 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Test + template_author: OPENECOMP + template_version: 1.0.0 +description: testing desc tosca service template +imports: + myfile1: + file: path1/path2/file1.yaml + myfile2: + file: path1/path2/file2.yaml +artifact_types: + one_artifact: + mime_type: application/java-archive + file_ext: + - yaml + - xml +node_types: + compute_node_type: + derived_from: tosca.nodes.Root + version: 1.0.0 + description: tosca compute test + properties: + cpu_num: + type: integer + description: Number of CPUs requested for a software node instance + required: true + default: 1 + status: SUPPORTED + constraints: + - greater_or_equal: 5.0 + - equal: 5 + - greater_than: 6.02 + - in_range: + - 0 + - UNBOUNDED + attributes: + attDef1: + type: string + default: hi + status: SUPPORTED + requirements: + - re1: + capability: tosca.cap1 + occurrences: + - 5 + - 1 + capabilities: + cap1: + type: tosca.cap + valid_source_types: + - node1 + - node2 + occurrences: + - 1 + - UNBOUNDED +topology_template: + description: topologi template descroption + inputs: + inParam1: + type: string + description: desc + required: false + default: my default val + constraints: + - greater_than: 6 + - greater_or_equal: 9 + entry_schema: + type: tosca.myType + node_templates: + firatNodeTemplate: + type: nodeTypeRef + directives: + - selectable + - substitutable + properties: + prop2: '{ get_input: my_mysql_rootpw }' + prop1: abcd + attributes: + att2: '{ get_input: my_mysql_rootpw }' + att1: att1Val + requirements: + - req1: + capability: capA + node: nodeA + relationship: relationB + node_filter: + properties: + propName1: + - greater_or_equal: 9 + propName2: + - min_length: 1 + - max_length: 2 + occurrences: + - 1 + - 2 + - req2: + capability: capA + node: nodeA + relationship: relationB + capabilities: + - cap1: + properties: + num_cpus: '{ get_input: cpus }' + attributes: + num_cpus: '66' + node_filter: + properties: + test1: + - equal: 1 MB + substitution_mappings: + node_type: myNodeType.node + capabilities: + database_endpoint: + - database + - database_endpoint diff --git a/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/model/serviceTemplateHeatExtend.yaml b/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/model/serviceTemplateHeatExtend.yaml new file mode 100644 index 0000000000..4515e3dee3 --- /dev/null +++ b/openecomp-be/lib/openecomp-tosca-lib/src/test/resources/mock/model/serviceTemplateHeatExtend.yaml @@ -0,0 +1,117 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +metadata: + template_name: Test + template_author: OPENECOMP + template_version: 1.0.0 +description: testing desc tosca service template +imports: + myfile1: + file: path1/path2/file1.yaml + myfile2: + file: path1/path2/file2.yaml +artifact_types: + one_artifact: + mime_type: application/java-archive + file_ext: + - yaml + - xml +node_types: + compute_node_type: + derived_from: tosca.nodes.Root + version: 1.0.0 + description: tosca compute test + properties: + cpu_num: + type: integer + description: Number of CPUs requested for a software node instance + required: true + default: 1 + status: SUPPORTED + constraints: + - greater_or_equal: 5.0 + - equal: 5 + - greater_than: 6.02 + - in_range: + - 0 + - UNBOUNDED + attributes: + attDef1: + type: string + default: hi + status: SUPPORTED + requirements: + - re1: + capability: tosca.cap1 + occurrences: + - 5 + - 1 + capabilities: + cap1: + type: tosca.cap + valid_source_types: + - node1 + - node2 + occurrences: + - 1 + - UNBOUNDED +topology_template: + description: topologi template descroption + inputs: + inParam1: + type: string + description: desc + required: false + default: my default val + label: my label + constraints: + - greater_than: 6 + - greater_or_equal: 9 + entry_schema: + type: tosca.myType + node_templates: + firatNodeTemplate: + type: nodeTypeRef + directives: + - selectable + - substitutable + properties: + prop2: '{ get_input: my_mysql_rootpw }' + prop1: abcd + attributes: + att2: '{ get_input: my_mysql_rootpw }' + att1: att1Val + requirements: + - req1: + capability: capA + node: nodeA + relationship: relationB + node_filter: + properties: + propName1: + - greater_or_equal: 9 + propName2: + - min_length: 1 + - max_length: 2 + occurrences: + - 1 + - 2 + - req2: + capability: capA + node: nodeA + relationship: relationB + capabilities: + - cap1: + properties: + num_cpus: '{ get_input: cpus }' + attributes: + num_cpus: '66' + node_filter: + properties: + test1: + - equal: 1 MB + substitution_mappings: + node_type: myNodeType.node + capabilities: + database_endpoint: + - database + - database_endpoint diff --git a/openecomp-be/lib/pom.xml b/openecomp-be/lib/pom.xml new file mode 100644 index 0000000000..9665bd47c4 --- /dev/null +++ b/openecomp-be/lib/pom.xml @@ -0,0 +1,30 @@ + + 4.0.0 + + + openecomp-sdc + org.openecomp.sdc + 1.0.0-SNAPSHOT + + + openecomp-sdc-lib + openecomp-sdc-lib + pom + + + openecomp-core-lib + openecomp-common-lib + openecomp-sdc-versioning-lib + openecomp-sdc-vendor-license-lib + openecomp-sdc-vendor-software-product-lib + openecomp-sdc-translator-lib + openecomp-sdc-model-lib + openecomp-sdc-validation-lib + openecomp-sdc-datatypes-lib + openecomp-heat-lib + openecomp-tosca-lib + openecomp-sdc-action-lib + openecomp-sdc-enrichment-lib + + \ No newline at end of file diff --git a/openecomp-be/logs/ASDC/Debug.1.log.zip b/openecomp-be/logs/ASDC/Debug.1.log.zip new file mode 100644 index 0000000000000000000000000000000000000000..80f2f013bd95d7a5c2cb55f36e7e532e0bb83ffc GIT binary patch literal 146911 zcmbrmbyQVhw=XORlF}WU?vm~E#_`uH+Mg~qM%xte%xtLg4nb=tM zSUK6)nJsNh4qNnM3F|7i?uF2A_%FR0owbv+z-mkj8+gQnpanHPK8m@E^;uM^O3ihg z{&niG7$R1ZN7ahtBkLGR==ZNz6G-K|&a9&?xm35I5&N{i@p#y~Uk&f=ahv3~rR#d% zZyqjOR6S0H(L9~R4%&>SKcwG1QO}ubf=4gvSiB#$g}v{DeV$gr(jPY>pWN;@3fgv` z81C8hE-zS&o{n}7!S|kzlL>6;%u?NsO5p1ZA}@lkKH$e0#;21NA7Q-6y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FZu5)QUvo(kp%|MvH32_v=zZCRIkmaHY&UL zmAJ91vvgk18cbx2fftw=di|}C*J(5npS;a(D~OA&Wbc3c_&Eg!Nfl4hR6tbuJjGys zh3bN0FIsd~0}ocT36sKl17edd*EO63XugTiCLT>_q8995?{&XwH+p;+Ns={6Ug;p0 zF8lInTJVdz=f&D#Qu;xG0r{QQ;IM@e)BA>XZ_FV zLM@eJlAzeJ;0~UgWfj~e3V+HwAg{aLQ@(Y}O`QtY?>jH30q0|Bgo&<{h50Tc7Ab?PB8vi zd)QXzF_*Qib`zzxZHx08kBz>9nfC*D3L42rWO$U-S~J8HR4GRvs7fytsApTK3j{wW zMcpaUq832p9L|Y13mKm2oy`6Een7TL)S*4%t^Y|?39n`Q{ zbrIx|>_BhE$aSbe;As3g$1%(~_-@q)dSb>*xj2ZASS6NUAsWpSOzL-+eQbLNr#`ro zW75}NsLdZcQ{$d5`tSz9i>`QguTKqX14YcbTlA8(9@&6E%|mgSD?YxrwwjoM|mc-;+ZeN(z+FX=3DT#>&ag!OOzI!NSR5z`?`G#cE}1 XrYwho3j1XQ;GZ<`JplOgAkhB;SoULC literal 0 HcmV?d00001 diff --git a/openecomp-be/logs/ASDC/Debug.2.log.zip b/openecomp-be/logs/ASDC/Debug.2.log.zip new file mode 100644 index 0000000000000000000000000000000000000000..eec96198c0242b221c944394087361488e48924e GIT binary patch literal 130246 zcmce;Wk6iZwl#_ccL)|d1b25QK!UrwySoN!Ab5g11a}B-!8Jf|cZUw{@^zEF&)w&q zd*A#1yvO>nnwDCts%F)kbBr;U!bfNrYzTOGc!+n=lF|_W_`?Ui7B@9=HD_dHX5nOD zVP;_F(r4jf=V7$5H$Q6AO?V?&LFvLJsKS1#-PLqLe`lYk zgRP6j$zgkW#xVJ@F(KbOcAC)b`=cvPeN_Lk_x8g^f)C&Db|(*8=?i|JZ5M7Y3;F5d zMEYp@^504Fq%aiRDqcFqp+&!+ETfO{8(T5$w&d&}YA;JnxION8+I{9;&i3Ho?`ZXq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00001 diff --git a/openecomp-be/logs/ASDC/Debug.3.log.zip b/openecomp-be/logs/ASDC/Debug.3.log.zip new file mode 100644 index 0000000000000000000000000000000000000000..5230f444f7c36518c8b8ba728981ff72f3497631 GIT binary patch literal 158231 zcmc$`byU?~w>3@*NGshXCEeZKNOyN5-AGDG3rHhKmvnb`cXxNgdk*OLxzBU&JKp=p zZ;YRxF&rLL&Svkm*P3h2xsIG9I0Om^G&D4bc%+Cp$bb2T3HY;+k-nn|4FerL3pG6* zH64o%Ju5RCjirsrL8HcJY|*i8&t~L%+!O609MJZ)#0x1lyl}&k%}Nn3a@Q;UuCh@G zbwdphtRw3kqzuGoC%z%hrzfYayVX#U&7K~2cc-V< zP@>CeI1w@t5j>uEv71?Ep7x$8XjyhV-U(<*k0t20Bq=yS$exS$tlRz?~;|+-4ce#T;;cH@~_3CXhJ;7ai;NA@X^iK?}~c5 z&D5UQO3L@vE2e3mx1ZTG-yfPfc-WcKsw;U6Y)$*!^*d-A-+G)(9zQ3BEyv$JTvgNB zIFdi@ubjA?ZQYz;kayswsSgT2Hb(k+C#XHzahU$bUy{FPbWI4$>3wj!$fq=qdZx4V z&U%-YN_zgR1mDHFdvmzB%xeC*<|--%<%iox=gs1UIL;sUiJaGi)L1OPD2Wug5|mFh zl@w9GQnFy4J1Q?ym5A7!-#RX)4Dp7_ZI4c0CI}}oF&>l0MunO~F4~*@Rroo~07nrf&k*F9ck*u44m5tgd`rewy9C{e*+}mg- z`~k|G{K5uhm%7@Kkvx%T_#+W@cQ2x7}N!p9Cyqg3+`km z);`QOe5Cbsy)=33e!2m-Ub=yXt2gX$GxG3Z0}m86{H<^<#%}otTA1egA(VFM7y=0+ zd}MrBiTYLCIz4l&~Z(yF93`>OD&=X~*U6uUz^nRAZd6%e9 z4UfcS-wlY}o3IT^yv01v;>c7k9yl*g2WgR2M-D-efqe%>Nl?JDPi?C|mSZR$ke6Ta z3Ez#fWrm366GetZ4ZWG*U9;)FoPvSikn4f?lF@%AMZlI8A7_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we+ literal 0 HcmV?d00001 diff --git a/openecomp-be/pom.xml b/openecomp-be/pom.xml new file mode 100644 index 0000000000..4b7e7e80f0 --- /dev/null +++ b/openecomp-be/pom.xml @@ -0,0 +1,158 @@ + + 4.0.0 + + + org.openecomp.sdc + sdc-main + 1.0.0-SNAPSHOT + + + org.openecomp.sdc + openecomp-sdc + + openecomp-sdc + pom + http://maven.apache.org + + + + 4.1.3.RELEASE + 1.9.13 + 4.4.1 + 3.1.8 + 2.0.1 + 1 + 2.5 + 2.1.9 + 1.5.3 + 6.9.10 + 1.8 + 1.8 + 2.5 + 1.3.0 + 1.10 + 2.6 + 3.2.4 + 3.0.1-b04 + 5.3.1.Final + + 3.0.6 + + + + + + + /api + /lib + /configuration + /tools/swagger-ui + /backend + + + + + + + + + + + org.apache.maven.plugins + maven-compiler-plugin + 2.5.1 + true + + ${java.source} + ${java.target} + + + + + + + + + + + + + commons-beanutils + commons-beanutils + 1.9.3 + + + + com.beust + jcommander + 1.58 + + + + org.apache.httpcomponents + httpasyncclient + 4.1.2 + + + + com.sun.xml.bind + jaxb-impl + 2.2.11 + + + + org.beanshell + bsh + 2.0b5 + + + + commons-digester + commons-digester + 2.1 + + + + com.fasterxml + classmate + 1.3.3 + + + + org.codehaus.janino + janino + ${janino.version} + provided + + + + + + + diff --git a/openecomp-be/readMe.txt b/openecomp-be/readMe.txt new file mode 100644 index 0000000000..04838502b5 --- /dev/null +++ b/openecomp-be/readMe.txt @@ -0,0 +1,42 @@ +# OpenECOMP SDC Onboarding(back-end) + +--- +--- + +# Introduction + +SDC is the component within the design time environment that provides multiple organizations the ability to create and manage ECOMP assets in terms of “models”. SDC asset models are generally categorized into four object types: Resource, Service, Product and Offer. + +# Compiling Onboarding be war + +###SDC can be compiled easily with a `mvn clean install`. Integration tests are started with the following profile + `-P with-integration-tests` + +###Location of war : \sdc\openecomp-be\api\openecomp-sdc-rest-webapp\onboarding-rest-war\target\onboarding-be-1.0-SNAPSHOT.war + +# Starting SDC + +Steps : + +### Copy onboarding war on jetty server : onboarding-be.war + +###open rpm +###install jetty +###run installJettyBase.sh +###copy jvm.properties to base +###export variables +###run startJetty.sh + +# Accessing SDC + +You can access SDC at the following link : http://:/sdc1/proxy-designer1#/onboardVendor + +# Logging + +SDC Onboarding supports EELF Logger, which is of the following types : + +### Error +### Debug +### Metrics +### Audit + diff --git a/openecomp-be/tools/build/scripts/action_library_client/action_library_client.py b/openecomp-be/tools/build/scripts/action_library_client/action_library_client.py new file mode 100644 index 0000000000..7d6e32e4a8 --- /dev/null +++ b/openecomp-be/tools/build/scripts/action_library_client/action_library_client.py @@ -0,0 +1,704 @@ +#!/usr/bin/python + +############################################################################## +# +# action_library_client.py +# +# A command-line client for the SDC Action Library. +# +# +# Usage: +# +# Usage: action_library_client.py [--help] [--url ] [--in ] +# [--out ] [--config ] +# [--log ] [--uuid ] +# [--curl] [--dryrun] [--verbose] [--version] +# [--list | --create | --update= | --delete | +# --checkout | --undocheckout | --checkin | --submit] +# +# Optional arguments: +# --help Show this help message and exit +# --url REST endpoint URL +# --in Path to JSON input file (else STDIN) +# --out Path to JSON output file (else STDOUT or logfile) +# --config Path to configuration file +# --log Path to logfile (else STDOUT) +# --uuid Action UUID, (=='actionInvariantUUID') +# --curl Use curl transport impl +# --dryrun Describe what will happen, execute nothing +# --verbose Verbose diagnostic output +# --version Print script version and exit +# --list List actions +# --create Create new action (requires --in) +# --update Update existing action (requires --uuid, --in) +# --delete Delete existing action (requires --uuid) +# --checkout Create minor version candidate (requires --uuid) +# --undocheckout Discard minor version candidate (requires --uuid) +# --checkin Create minor version from candidate (requires --uuid) +# --submit Create next major version (requires --uuid) +# +# For example: +# +# ./action_library_client.py --url http://10.147.97.199:8080 --list +# +# Output: +# - Return values: +# - 0 - OK +# - 1 - GENERAL_ERROR +# - 2 - ARGUMENTS_ERROR +# - 3 - HTTP_FORBIDDEN_ERROR +# - 4 - HTTP_BAD_REQUEST_ERROR +# - 5 - HTTP_GENERAL_ERROR +# - 6 - PROCESS_ERROR +# - JSON - to stdout: +# - Delimited by "----------" +# - Delimiter overrideable with ALC_JSON_DELIMITER setting. +# +# Configuration/env settings: +# - ALC_HTTP_USER - HTTP BASIC username +# - ALC_HTTP_PASS - HTTP BASIC password +# - ALC_HTTP_INSECURE - allow untrusted SSL (server) connections. +# - ALC_TIMEOUT_SECONDS - invocation (e.g. HTTP) timeout in seconds. +# - ALC_JSON_DELIMITER - JSON delimiter in ouput. +# - ALC_ECOMP_INSTANCE_ID - X-ECOMP-InstanceID header +# +# Configuration by 0600-mode INI file (section "action_library_client") is preferred. +# +# See: +# http://10.147.97.199:8080/api-docs/ - REST API Swagger docs +# https://www.python.org/dev/peps/pep-0008/ - style guide +# ../doc/SDC_Action_Lib_API_AID_1610_13.pdf - REST API dev guide +# +# Version history: +# - 1.0.0 November 28th 2016, LP, initial impl. +# - 1.0.1 November 29th 2016, LP, constants, documentation, add --version. +# - 1.0.2 November 29th 2016, LP, logging to files, stream-handling. +# - 1.0.3 November 30th 2016, LP, optionally read config from env or config file. +# - 1.1.0 December 3rd 2016, LP, backport from Python 3.4.2 to 2.6.6(!). +# +############################################################################## + + +import sys +import os +import logging +import base64 +import tempfile +import uuid +import json +import ssl +import urllib2 +import subprocess +import ConfigParser +from abc import abstractmethod + + +############################################################################### + + +class Constants(object): + """Common constants, for want of a better language feature...""" + # Values. + VERSION = "1.1.0" + APPLICATION = "action_library_client" + ACTIONS_URI = "onboarding-api/workflow/v1.0/actions" + ECOMP_INSTANCE_ID = "sdc_alc" + TIMEOUT_SECONDS_DEFAULT = 30 + JSON_DELIMITER_DEFAULT = "----------" + LOG_FORMAT = "%(name)s\t%(levelname)s\t%(asctime)s\t%(message)s" + # Env variable names. + ENV_HTTP_USER = "ALC_HTTP_USER" + ENV_HTTP_PASS = "ALC_HTTP_PASS" + ENV_HTTP_INSECURE = "ALC_HTTP_INSECURE" + ENV_HTTP_CAFILE = "ALC_HTTP_CAFILE" + ENV_TIMEOUT_SECONDS = "ALC_TIMEOUT_SECONDS" + ENV_JSON_DELIMITER = "ALC_JSON_DELIMITER" + ENV_ECOMP_INSTANCE_ID = "ALC_ECOMP_INSTANCE_ID" + + +############################################################################### + + +class ResponseCodes(object): + """Responses returned by IRESTClient impls.""" + OK = 0 + GENERAL_ERROR = 1 + ARGUMENTS_ERROR = 2 + HTTP_NOT_FOUND_ERROR = 3 + HTTP_FORBIDDEN_ERROR = 4 + HTTP_BAD_REQUEST_ERROR = 5 + HTTP_GENERAL_ERROR = 6 + PROCESS_GENERAL_ERROR = 9 + + +############################################################################### + + +class FinalizeStatus(object): + """Finalization operations.""" + Checkout = "Checkout" + UndoCheckout = "Undo_Checkout" + CheckIn = "Checkin" + Submit = "Submit" + + +############################################################################### + + +class ArgsDict(dict): + """A dict which makes attributes accessible as properties.""" + def __getattr__(self, attr): + return self[attr] + + def __setattr__(self, attr, value): + self[attr] = value + + +############################################################################### + + +class ArgumentParser(object): + """A minimal reimpl of the argparse library, core in later Python releases""" + ACTIONS = ["list", "create", "update", "delete", "checkout", "undocheckout", "checkin", "submit"] + PARMS = ["url", "in", "out", "config", "log", "uuid"] + OTHER = ["curl", "dryrun", "verbose", "version", "help"] + + def parse_args(self, clargs): + """Parse command-line args, returning a dict that exposes everything as properties.""" + args = ArgsDict() + args.action = None + for arg in self.ACTIONS + self.PARMS + self.OTHER: + args[arg] = None + skip = False + try: + for i, clarg in enumerate(clargs): + if skip: + skip = False + continue + if not clarg.startswith("--"): + raise Exception("Invalid argument: {0}".format(clarg)) + arg = str(clarg[2:]) + if arg in self.ACTIONS: + if args.action: + raise Exception("Duplicate actions: --{0}, {1}".format(args.action, clarg)) + args.action = arg + elif arg in self.PARMS: + try: + args[arg] = clargs[i + 1] + skip = True + except IndexError: + raise Exception("Option {0} requires an argument".format(clarg)) + elif arg in self.OTHER: + args[arg] = True + else: + raise Exception("Invalid argument: {0}".format(clarg)) + + # Check action args. + + if args.action: + if not args.url: + raise Exception("--url required for every action") + if not args.uuid: + if args.action not in ["create", "list"]: + raise Exception("--uuid required for every action EXCEPT --list/--create") + + # Read from file or stdin, and replace the problematic "in" + # property with "infile". + + if args.action in ["create", "update"]: + if args["in"]: + args.infile = open(args["in"], mode="r") + else: + args.infile = sys.stdin + + except Exception as e: + print(e) + ArgumentParser.usage() + sys.exit(ResponseCodes.ARGUMENTS_ERROR) + return args + + @staticmethod + def usage(): + """Print usage message.""" + print("" + + "Usage: action_library_client.py [--help] [--url ] [--in ]\n" + + " [--out ] [--config ]\n" + + " [--log ] [--uuid ]\n" + + " [--curl] [--dryrun] [--verbose] [--version]\n" + + " [--list | --create | --update= | --delete |\n" + + " --checkout | --undocheckout | --checkin | --submit]\n" + + "\n" + + "Optional arguments:\n" + + " --help Show this help message and exit\n" + + " --url REST endpoint URL\n" + + " --in Path to JSON input file (else STDIN)\n" + + " --out Path to JSON output file (else STDOUT or logfile)\n" + + " --config Path to configuration file\n" + + " --log Path to logfile (else STDOUT)\n" + + " --uuid Action UUID, (=='actionInvariantUUID')\n" + + " --curl Use curl transport impl\n" + + " --dryrun Describe what will happen, execute nothing\n" + + " --verbose Verbose diagnostic output\n" + + " --version Print script version and exit\n" + + " --list List actions\n" + + " --create Create new action (requires --in)\n" + + " --update Update existing action (requires --uuid, --in)\n" + + " --delete Delete existing action (requires --uuid)\n" + + " --checkout Create minor version candidate (requires --uuid)\n" + + " --undocheckout Discard minor version candidate (requires --uuid)\n" + + " --checkin Create minor version from candidate (requires --uuid)\n" + + " --submit Create next major version (requires --uuid)") + + +############################################################################### + + +class Settings(object): + """Settings read from (optional) configfile, or environment.""" + + def __init__(self, args): + """Construct for command-line args.""" + self.config = ConfigParser.ConfigParser() + if args.config: + self.config.read(args.config) + + def get(self, name, default_value=None): + """Get setting from configfile or environment""" + try: + return self.config.get(Constants.APPLICATION, name) + except (KeyError, ConfigParser.NoSectionError, ConfigParser.NoOptionError): + try: + return os.environ[name] + except KeyError: + return default_value + + +############################################################################### + + +# Python3: metaclass=ABCMeta +class IRESTClient(object): + """Base class for local, proxy and dryrun impls.""" + + def __init__(self, args): + self.args = args + self.logger = Runner.get_logger() + self.settings = Settings(args) + + @abstractmethod + def list(self): + """Abstract list operation.""" + pass + + @abstractmethod + def create(self): + """Abstract list operation.""" + pass + + @abstractmethod + def update(self): + """Abstract list operation.""" + pass + + @abstractmethod + def delete(self): + """Abstract list operation.""" + pass + + @abstractmethod + def version(self, status): + """Abstract list operation.""" + pass + + @staticmethod + def new_uuid(): + """Generate UUID.""" + return str(uuid.uuid4()) + + def get_timeout_seconds(self): + """Get request timeout in seconds.""" + return self.settings.get(Constants.ENV_TIMEOUT_SECONDS, + Constants.TIMEOUT_SECONDS_DEFAULT) + + def get_http_insecure(self): + """Get whether SSL certificate checks are (inadvisably) disabled.""" + return True if self.settings.get(Constants.ENV_HTTP_INSECURE) else False + + def get_http_cafile(self): + """Get optional CA file for SSL server cert validation""" + if not self.get_http_insecure(): + return self.settings.get(Constants.ENV_HTTP_CAFILE) + + def get_basic_credentials(self): + """Generate Authorization: header.""" + usr = self.settings.get(Constants.ENV_HTTP_USER) + pwd = self.settings.get(Constants.ENV_HTTP_PASS) + if usr and pwd: + return base64.b64encode(bytes("{0}:{1}".format(usr, pwd))).decode("ascii") + else: + raise Exception("REST service credentials not found") + + def make_service_url(self): + """Generate service URL based on command-line arguments.""" + url = self.args.url + if "/onboarding-api/" not in url: + separator = "" if url.endswith("/") else "/" + url = "{0}{1}{2}".format(url, separator, str(Constants.ACTIONS_URI)) + if self.args.uuid: + separator = "" if url.endswith("/") else "/" + url = "{0}{1}{2}".format(url, separator, self.args.uuid) + return url + + def log_json_response(self, method, json_dict): + """Log JSON response regardless of transport.""" + json_str = json.dumps(json_dict, indent=4) + delimiter = self.settings.get(Constants.ENV_JSON_DELIMITER, Constants.JSON_DELIMITER_DEFAULT) + self.logger.info("HTTP {0} JSON response:\n{1}\n{2}\n{3}\n".format(method, delimiter, json_str, delimiter)) + if self.args.out: + with open(self.args.out, "w") as tmp: + tmp.write(json_str) + tmp.flush() + elif self.args.log: + # Directly to stdout if logging is sent to a file. + print(json_str) + + def log_action(self, action, status=None): + """Debug action before invocation.""" + url = self.make_service_url() + name = status if status else self.__get_name() + self.logger.debug("{0}::{1}({2})".format(name, action, url)) + + @staticmethod + def _get_result_from_http_response(code): + """Get script returncode from HTTP error.""" + if code == 400: + return ResponseCodes.HTTP_BAD_REQUEST_ERROR + elif code == 403: + return ResponseCodes.HTTP_FORBIDDEN_ERROR + elif code == 404: + return ResponseCodes.HTTP_NOT_FOUND_ERROR + return ResponseCodes.HTTP_GENERAL_ERROR + + def __get_name(self): + """Get classname for diags""" + return type(self).__name__ + + +############################################################################### + + +class NativeRESTClient(IRESTClient): + """In-process IRESTClient impl.""" + + def list(self): + """In-process list impl.""" + self.log_action("list") + return self.__exec(method="GET", expect_json=True) + + def create(self): + """In-process create impl.""" + self.log_action("create") + json_bytes = bytes(self.args.infile.read()) + return self.__exec(method="POST", json_bytes=json_bytes, expect_json=True) + + def update(self): + """In-process update impl.""" + self.log_action("update") + json_bytes = bytes(self.args.infile.read()) + return self.__exec(method="PUT", json_bytes=json_bytes, expect_json=True) + + def delete(self): + """In-process delete impl.""" + self.log_action("delete") + return self.__exec(method="DELETE") + + def version(self, status): + """In-process version impl.""" + self.log_action("version", status) + json_bytes = bytes(json.dumps({"status": status})) + return self.__exec(method="POST", json_bytes=json_bytes, expect_json=True) + + def __exec(self, method, json_bytes=None, expect_json=None): + """Build command, execute it, validate and return response.""" + try: + url = self.make_service_url() + timeout = float(self.get_timeout_seconds()) + cafile = self.get_http_cafile() + headers = { + "Content-Type": "application/json", + "Accept": "application/json", + "Authorization": "Basic {0}".format(self.get_basic_credentials()), + "X-ECOMP-InstanceID": Constants.ECOMP_INSTANCE_ID, + "X-ECOMP-RequestID": IRESTClient.new_uuid() + } + + handler = urllib2.HTTPHandler + if hasattr(ssl, 'create_default_context'): + ctx = ssl.create_default_context(cafile=cafile) + if self.get_http_insecure(): + ctx.check_hostname = False + ctx.verify_mode = ssl.CERT_NONE + handler = urllib2.HTTPSHandler(context=ctx) if url.lower().startswith("https") else urllib2.HTTPHandler + + self.logger.debug("URL {0} {1}: {2}".format(url, method, json_bytes)) + + opener = urllib2.build_opener(handler) + request = urllib2.Request(url, data=json_bytes, headers=headers) + request.get_method = lambda: method + + f = None + try: + f = opener.open(request, timeout=timeout) + return self.__handle_response(f, method, expect_json) + finally: + if f: + f.close() + + except urllib2.HTTPError as err: + self.logger.exception(err) + return IRESTClient._get_result_from_http_response(err.getcode()) + except urllib2.URLError as err: + self.logger.exception(err) + return ResponseCodes.HTTP_GENERAL_ERROR + + def __handle_response(self, f, method, expect_json): + """Devolve response handling because of the """ + self.logger.debug("HTTP {0} status {1}, reason:\n{2}".format(method, f.getcode(), f.info())) + if expect_json: + # JSON responses get "returned", but actually it's the logging that + # most callers will be looking for. + json_body = json.loads(f.read().decode("utf-8")) + self.log_json_response(method, json_body) + return json_body + # Not JSON, but the operation succeeded, so return True. + return ResponseCodes.OK + + +############################################################################### + + +class CURLRESTClient(IRESTClient): + """Remote/curl IRESTClient impl.""" + + def list(self): + """curl list impl""" + self.log_action("list") + return self._exec(method="GET", expect_json=True) + + def create(self): + """curl create impl""" + self.log_action("create") + data_args = ["--data", "@{0}".format(self.args.infile.name)] + return self._exec(method="POST", extra_args=data_args, expect_json=True) + + def update(self): + """curl update impl""" + self.log_action("update") + data_args = ["--data", "@{0}".format(self.args.infile.name)] + return self._exec(method="PUT", extra_args=data_args, expect_json=True) + + def delete(self): + """curl delete impl""" + self.log_action("delete") + return self._exec(method="DELETE", expect_json=False) + + def version(self, status): + """curl version impl""" + self.log_action("version", status) + with tempfile.NamedTemporaryFile(mode="w", delete=False) as tmp: + tmp.write(json.dumps({"status": status})) + tmp.flush() + data_args = ["--data", "@{0}".format(tmp.name)] + return self._exec(method="POST", extra_args=data_args, expect_json=True) + + def make_curl_cmd(self, method, url, extra_args): + """Build curl command without executing.""" + cmd = ["curl", "-i", "-s", "-X", method] + if self.get_http_insecure(): + cmd.append("-k") + cmd.extend(["--connect-timeout", str(self.get_timeout_seconds())]) + cmd.extend(["--header", "Accept: application/json"]) + cmd.extend(["--header", "Content-Type: application/json"]) + cmd.extend(["--header", "Authorization: Basic {0}".format(self.get_basic_credentials())]) + cmd.extend(["--header", "X-ECOMP-InstanceID: {0}".format(Constants.ECOMP_INSTANCE_ID)]) + cmd.extend(["--header", "X-ECOMP-RequestID: {0}".format(IRESTClient.new_uuid())]) + if extra_args: + for extra_arg in extra_args: + cmd.append(extra_arg) + cmd.append("{0}".format(url)) + return cmd + + @staticmethod + def debug_curl_cmd(cmd): + """Debug curl command, for diags and dryrun.""" + buf = "" + for token in cmd: + if token is "curl" or token.startswith("-"): + buf = "{0}{1} ".format(buf, token) + else: + buf = "{0}\"{1}\" ".format(buf, token) + return buf + + def _exec(self, method, extra_args=None, expect_json=None): + """Execute action. + + Build command, invoke curl, validate and return response. + Overridden by DryRunRESTClient. + """ + url = self.make_service_url() + cmd = self.make_curl_cmd(method, url, extra_args) + self.logger.info("Executing: {0}".format(CURLRESTClient.debug_curl_cmd(cmd))) + + try: + output = subprocess.check_output(cmd, stderr=subprocess.STDOUT).decode() + if not expect_json: + return ResponseCodes.OK + try: + separator = output.index("\r\n\r\n{") + self.logger.debug("HTTP preamble:\n{0}".format(output[:separator])) + json_body = json.loads(output[(separator+4):]) + self.log_json_response(method, json_body) + return json_body + except ValueError: + self.logger.warning("Couldn't find HTTP separator in curl output:\n{}".format(output)) + code = CURLRESTClient.__get_http_code(output) + return IRESTClient._get_result_from_http_response(code) + except subprocess.CalledProcessError as err: + self.logger.exception(err) + return ResponseCodes.PROCESS_GENERAL_ERROR + + @staticmethod + def __get_http_code(output): + """Attempt to guess HTTP result from (error) output.""" + for line in output.splitlines(): + if line.startswith("HTTP"): + tokens = line.split() + if len(tokens) > 2: + try: + return int(tokens[1]) + except ValueError: + pass + return ResponseCodes.HTTP_GENERAL_ERROR + + +############################################################################### + + +class DryRunRESTClient(CURLRESTClient): + """Neutered IRESTClient impl; only logs.""" + + def _exec(self, method, extra_args=None, expect_json=None): + """Override.""" + url = self.make_service_url() + cmd = self.make_curl_cmd(method, url, extra_args) + self.logger.info("[DryRun] {0}".format(CURLRESTClient.debug_curl_cmd(cmd))) + + +############################################################################### + + +class Runner(object): + """A bunch of static housekeeping supporting the launcher.""" + + @staticmethod + def get_logger(): + """Get logger instance.""" + return logging.getLogger(Constants.APPLICATION) + + @staticmethod + def get_rest_client(args): + """Get the configured REST client impl, local, remote or dryrun.""" + if args.dryrun: + return DryRunRESTClient(args) + elif args.curl: + return CURLRESTClient(args) + else: + return NativeRESTClient(args) + + @staticmethod + def execute(args): + """Execute the requested action.""" + client = Runner.get_rest_client(args) + if args.version: + print(Constants.VERSION) + elif args.help: + ArgumentParser.usage() + elif args.action == "list": + return client.list() + elif args.action == "create": + return client.create() + elif args.action == "update": + return client.update() + elif args.action == "delete": + return client.delete() + elif args.action == "checkout": + return client.version(FinalizeStatus.Checkout) + elif args.action == "checkin": + return client.version(FinalizeStatus.CheckIn) + elif args.action == "undocheckout": + return client.version(FinalizeStatus.UndoCheckout) + elif args.action == "submit": + return client.version(FinalizeStatus.Submit) + else: + logger = Runner.get_logger() + logger.info("No action specified. Try --help.") + + @staticmethod + def parse_args(raw): + """Parse command-line args, returning dict.""" + return ArgumentParser().parse_args(raw) + + +############################################################################### + + +def execute(raw): + """Delegate which executes minus error-handling, exposed for unit-testing.""" + + # Intercept Python 2.X. + + if not (sys.version_info[0] == 2 and sys.version_info[1] >= 6): + raise EnvironmentError("Python 2.6/2.7 required") + + # Parse command-line args. + + args = Runner.parse_args(raw) + + # Redirect logging to a file (freeing up STDIN) if directed. + + logging.basicConfig(level=logging.INFO, filename=args.log, format=Constants.LOG_FORMAT) + + # Set loglevel. + + logger = Runner.get_logger() + if args.verbose: + logger.setLevel(logging.DEBUG) + logger.debug("Parsed arguments: {0}".format(args)) + + # Execute request. + + return Runner.execute(args) + + +############################################################################### + + +def main(raw): + """Execute for command-line arguments.""" + + logger = Runner.get_logger() + try: + result = execute(raw) + result_code = result if isinstance(result, int) else ResponseCodes.OK + logger.debug("Execution complete. Returning result {0} ({1})".format(result, result_code)) + sys.exit(result_code) + except Exception as err: + logger.exception(err) + sys.exit(ResponseCodes.GENERAL_ERROR) + + +############################################################################### + + +if __name__ == "__main__": + main(sys.argv[1:]) diff --git a/openecomp-be/tools/build/scripts/action_library_client/doc/TESTPLAN.TXT b/openecomp-be/tools/build/scripts/action_library_client/doc/TESTPLAN.TXT new file mode 100644 index 0000000000..be6a77c847 --- /dev/null +++ b/openecomp-be/tools/build/scripts/action_library_client/doc/TESTPLAN.TXT @@ -0,0 +1,10 @@ +1. Unit + integration tests. +2. Reading credentials from configfile. +3. Writing output to logfile, response to stdout. +4. Reading JSON from stdin. +5. TLS URL, success, failure (if Python checks, and with insecure mode enabled). +6. Auth failure. +7. Print help, version. +8. Python 2.6/2.7 sanity (whichever isn't primary) +9. Run BASH example scripts. +10. Run Python example script(s). diff --git a/openecomp-be/tools/build/scripts/action_library_client/test/scenarios/Backout.json b/openecomp-be/tools/build/scripts/action_library_client/test/scenarios/Backout.json new file mode 100644 index 0000000000..12b7b4dd2c --- /dev/null +++ b/openecomp-be/tools/build/scripts/action_library_client/test/scenarios/Backout.json @@ -0,0 +1,45 @@ +{ + "name": "Backout", + "displayName": "Backout", + "description": "MCAP Backout", + "vendorList": ["BROCADE"], + "categoryList": ["Upgrade"], + "endpointURI": "engine-rest/process-definition/key/Backout/start", + "supportedModels": [{ + "versionID": "AA56B177-9383-4934-8543-0F91A7A04971", + "versionInvariantUUID": "CC87B177-9383-4934-8543-0F91A7A07193", + "name": "vCE", + "version": "2.1", + "category": "cpe" + }], + "supportedComponents": [{ + "ID": "BB47B177-9383-4934-8543-0F91A7A06448", + "componentName": "appc" + }], + "inputParameters": [{ + "name": "VNF_NAME", + "description": "VNF name", + "type": "STRING", + "max-length": "50", + "optional": true, + "allowed_values": ["string1", "string2"] + }], + "outputParameters": [{ + "name": "STATUS", + "defaultValue": "Default Value", + "type": "STRING", + "description": "The status of execution" + }], + "operationalData": { + "outageDuration": "0", + "approxDuration": "5", + "staticFields": {}, + "updatableFields": {} + }, + "serverList": [{ + "name": "appcserver", + "hostName": "cm-server1.client.com", + "port": "666" + }], + "updatedBy": "AUTHusername" +} diff --git a/openecomp-be/tools/build/scripts/action_library_client/test/scenarios/Copy_image.json b/openecomp-be/tools/build/scripts/action_library_client/test/scenarios/Copy_image.json new file mode 100644 index 0000000000..06da2ae48f --- /dev/null +++ b/openecomp-be/tools/build/scripts/action_library_client/test/scenarios/Copy_image.json @@ -0,0 +1,45 @@ +{ + "name": "Copy_image", + "displayName": "Copy_image", + "description": "MCAP Copy Image", + "vendorList": ["BROCADE"], + "categoryList": ["Upgrade"], + "endpointURI": "engine-rest/process-definition/key/Copy_image/start", + "supportedModels": [{ + "versionID": "AA56B177-9383-4934-8543-0F91A7A04971", + "versionInvariantUUID": "CC87B177-9383-4934-8543-0F91A7A07193", + "name": "vCE", + "version": "2.1", + "category": "cpe" + }], + "supportedComponents": [{ + "ID": "BB47B177-9383-4934-8543-0F91A7A06448", + "componentName": "appc" + }], + "inputParameters": [{ + "name": "VNF_NAME", + "description": "VNF name", + "type": "STRING", + "max-length": "50", + "optional": true, + "allowed_values": ["string1", "string2"] + }], + "outputParameters": [{ + "name": "STATUS", + "defaultValue": "Default Value", + "type": "STRING", + "description": "The status of execution" + }], + "operationalData": { + "outageDuration": "0", + "approxDuration": "5", + "staticFields": {}, + "updatableFields": {} + }, + "serverList": [{ + "name": "appcserver", + "hostName": "cm-server1.client.com", + "port": "666" + }], + "updatedBy": "AUTHusername" +} diff --git a/openecomp-be/tools/build/scripts/action_library_client/test/scenarios/Healthcheck.json b/openecomp-be/tools/build/scripts/action_library_client/test/scenarios/Healthcheck.json new file mode 100644 index 0000000000..b1be8f77df --- /dev/null +++ b/openecomp-be/tools/build/scripts/action_library_client/test/scenarios/Healthcheck.json @@ -0,0 +1,45 @@ +{ + "name": "Healthcheck", + "displayName": "Healthcheck", + "description": "MCAP Healthcheck", + "vendorList": ["BROCADE"], + "categoryList": ["Upgrade"], + "endpointURI": "engine-rest/process-definition/key/Healthcheck/start", + "supportedModels": [{ + "versionID": "AA56B177-9383-4934-8543-0F91A7A04971", + "versionInvariantUUID": "CC87B177-9383-4934-8543-0F91A7A07193", + "name": "vCE", + "version": "2.1", + "category": "cpe" + }], + "supportedComponents": [{ + "ID": "BB47B177-9383-4934-8543-0F91A7A06448", + "componentName": "appc" + }], + "inputParameters": [{ + "name": "VNF_NAME", + "description": "VNF name", + "type": "STRING", + "max-length": "50", + "optional": true, + "allowed_values": ["string1", "string2"] + }], + "outputParameters": [{ + "name": "STATUS", + "defaultValue": "Default Value", + "type": "STRING", + "description": "The status of execution" + }], + "operationalData": { + "outageDuration": "0", + "approxDuration": "5", + "staticFields": {}, + "updatableFields": {} + }, + "serverList": [{ + "name": "appcserver", + "hostName": "cm-server1.client.com", + "port": "666" + }], + "updatedBy": "AUTHusername" +} diff --git a/openecomp-be/tools/build/scripts/action_library_client/test/scenarios/Reboot.json b/openecomp-be/tools/build/scripts/action_library_client/test/scenarios/Reboot.json new file mode 100644 index 0000000000..72cbb659e3 --- /dev/null +++ b/openecomp-be/tools/build/scripts/action_library_client/test/scenarios/Reboot.json @@ -0,0 +1,45 @@ +{ + "name": "Reboot", + "displayName": "Reboot", + "description": "MCAP Reboot", + "vendorList": ["BROCADE"], + "categoryList": ["Upgrade"], + "endpointURI": "engine-rest/process-definition/key/Reboot/start", + "supportedModels": [{ + "versionID": "AA56B177-9383-4934-8543-0F91A7A04971", + "versionInvariantUUID": "CC87B177-9383-4934-8543-0F91A7A07193", + "name": "vCE", + "version": "2.1", + "category": "cpe" + }], + "supportedComponents": [{ + "ID": "BB47B177-9383-4934-8543-0F91A7A06448", + "componentName": "appc" + }], + "inputParameters": [{ + "name": "VNF_NAME", + "description": "VNF name", + "type": "STRING", + "max-length": "50", + "optional": true, + "allowed_values": ["string1", "string2"] + }], + "outputParameters": [{ + "name": "STATUS", + "defaultValue": "Default Value", + "type": "STRING", + "description": "The status of execution" + }], + "operationalData": { + "outageDuration": "0", + "approxDuration": "5", + "staticFields": {}, + "updatableFields": {} + }, + "serverList": [{ + "name": "appcserver", + "hostName": "cm-server1.client.com", + "port": "666" + }], + "updatedBy": "AUTHusername" +} diff --git a/openecomp-be/tools/build/scripts/action_library_client/test/seq.txt b/openecomp-be/tools/build/scripts/action_library_client/test/seq.txt new file mode 100644 index 0000000000..b18fcc5ba2 --- /dev/null +++ b/openecomp-be/tools/build/scripts/action_library_client/test/seq.txt @@ -0,0 +1 @@ +535 \ No newline at end of file diff --git a/openecomp-be/tools/build/scripts/action_library_client/test/test_action_library_client.py b/openecomp-be/tools/build/scripts/action_library_client/test/test_action_library_client.py new file mode 100644 index 0000000000..dc1161c184 --- /dev/null +++ b/openecomp-be/tools/build/scripts/action_library_client/test/test_action_library_client.py @@ -0,0 +1,154 @@ +import unittest +import os +import tempfile +import ConfigParser +import action_library_client as ALC + + +class D(dict): + + def __init__(self, *args, **kwargs): + super(D, self).__init__(*args, **kwargs) + self.__dict__ = self + + +class UnitTest(unittest.TestCase): + + def __write_config_file(self, map): + with tempfile.NamedTemporaryFile(mode="w", delete=False) as tmp: + config = ConfigParser.ConfigParser() + config.add_section("action_library_client") + for k, v in map.items(): + section = config.set("action_library_client", k, v) + config.write(tmp) + tmp.flush() + return tmp.name + + def test_argument_parser(self): + # nothing = ALC.ArgumentParser().parse_args([]) + # self.assertEquals(nothing.help, None) + # self.assertEquals(nothing.version, None) + # self.assertEquals(nothing.verbose, None) + # + # help = ALC.ArgumentParser().parse_args(["--help"]) + # self.assertEquals(help.help, True) + + uuidx = ALC.ArgumentParser().parse_args(["--uuid", "abc"]) + self.assertEquals(uuidx.uuid, "abc") + + + def test_settings_get(self): + + os.environ["a"] = "aa" + os.environ["b"] = "WILL_BE_OVERRIDDEN" + + section = dict() + section['ALC_HTTP_USER'] = "batman" + section['ECOMP_INSTANCE_ID'] = "acdc" + section['b'] = "bb" + filename = self.__write_config_file(section) + + # with tempfile.NamedTemporaryFile(mode="w", delete=False) as tmp: + # config = configparser.ConfigParser() + # config.add_section("action_library_client") + # section = config["action_library_client"] + # config.write(tmp) + # tmp.flush() + + settings = ALC.Settings(ALC.Runner.parse_args(["--config", filename])) + self.assertEquals("aa", settings.get("a")) + self.assertEquals("bb", settings.get("b")) + self.assertEquals("batman", settings.get("ALC_HTTP_USER")) + self.assertEquals("batman", settings.get(ALC.Constants.ENV_HTTP_USER)) + self.assertEquals("ALC_ECOMP_INSTANCE_ID", settings.get("c", ALC.Constants.ENV_ECOMP_INSTANCE_ID)) + + os.remove(filename) + + def test_parse_args(self): + c1 = ALC.Runner.parse_args(["--version"]) + with tempfile.NamedTemporaryFile(mode="w", delete=False) as tmp: + config = ConfigParser.ConfigParser() + config.add_section("action_library_client") + config.set("action_library_client", "ALC_HTTP_USER", "batman") + config.write(tmp) + tmp.flush() + self.assertEquals(c1.version, True) + + def test_get_http_insecure(self): + c = ALC.DryRunRESTClient(ALC.Runner.parse_args([])) + self.assertEquals(False, c.get_http_insecure()) + + def test_get_http_cafile(self): + c1 = ALC.DryRunRESTClient(ALC.Runner.parse_args([])) + self.assertEquals(False, c1.get_http_insecure()) + self.assertIsNone(c1.get_http_cafile()) + + filename = self.__write_config_file({"ALC_HTTP_CAFILE": "/tmp/x"}) + c2 = ALC.DryRunRESTClient(ALC.Runner.parse_args(["--config", filename])) + self.assertEquals(False, c2.get_http_insecure()) + self.assertEquals("/tmp/x", c2.get_http_cafile()) + + def test_get_timeout_seconds(self): + args = ALC.Runner.parse_args(["--version"]) + self.assertEquals(30, ALC.DryRunRESTClient(args).get_timeout_seconds()) + + def test_get_basic_credentials(self): + try: + saved_user = os.environ["ALC_HTTP_USER"] + saved_pass = os.environ["ALC_HTTP_PASS"] + except KeyError: + saved_user = "" + saved_pass = "" + try: + os.environ["ALC_HTTP_USER"] = "AUTH-DELETE" + os.environ["ALC_HTTP_PASS"] = "test" + c = ALC.DryRunRESTClient(ALC.Runner.parse_args([])) + c1 = c.get_basic_credentials() + self.assertEqual(c1, "QVVUSC1ERUxFVEU6dGVzdA==") + os.environ["ALC_HTTP_USER"] = "AUTH-DELETE" + os.environ["ALC_HTTP_PASS"] = "death" + c2 = c.get_basic_credentials() + self.assertNotEqual(c2, "QVVUSC1ERUxFVEU6dGVzdA==") + finally: + os.environ["ALC_HTTP_USER"] = saved_user + os.environ["ALC_HTTP_PASS"] = saved_pass + + def test_get_rest_client(self): + uuid = ALC.IRESTClient.new_uuid() + c1 = ALC.Runner.get_rest_client(ALC.Runner.parse_args(["--dryrun"])) + self.assertTrue(isinstance(c1, ALC.DryRunRESTClient)) + c2 = ALC.Runner.get_rest_client(ALC.Runner.parse_args(["--curl"])) + self.assertTrue(isinstance(c2, ALC.CURLRESTClient)) + c3 = ALC.Runner.get_rest_client(ALC.Runner.parse_args(["--uuid", uuid])) + self.assertTrue(isinstance(c3, ALC.NativeRESTClient)) + + def test_get_logger(self): + logger = ALC.Runner.get_logger() + logger.info("idotlogger") + + def test_new_uuid(self): + uuid = ALC.IRESTClient.new_uuid() + self.assertEqual(len(uuid), 36) + + def test_make_service_url(self): + uuid = ALC.IRESTClient.new_uuid() + + args1 = ALC.Runner.parse_args(["--url", "http://banana"]) + client1 = ALC.DryRunRESTClient(args1) + self.assertEqual(client1.make_service_url(), + "http://banana/onboarding-api/workflow/v1.0/actions") + + args2 = ALC.Runner.parse_args(["--url", "http://banana/"]) + client2 = ALC.DryRunRESTClient(args2) + self.assertEqual(client2.make_service_url(), + "http://banana/onboarding-api/workflow/v1.0/actions") + + args3 = ["--url", "http://banana/onboarding-api/workflow/v1.1/actions", "--uuid", uuid] + client3 = ALC.DryRunRESTClient(ALC.Runner.parse_args(args3)) + self.assertEqual(client3.make_service_url(), + "http://banana/onboarding-api/workflow/v1.1/actions/{}".format(uuid)) + + def test_debug_curl_cmd(self): + cmd = ["curl", "--header", "banana", "http://something/somewhere"] + debug = ALC.CURLRESTClient.debug_curl_cmd(cmd) + self.assertEqual("curl --header \"banana\" \"http://something/somewhere\" ", debug) \ No newline at end of file diff --git a/openecomp-be/tools/build/scripts/action_library_client/test/test_action_library_client_integration.py b/openecomp-be/tools/build/scripts/action_library_client/test/test_action_library_client_integration.py new file mode 100644 index 0000000000..b6418e617e --- /dev/null +++ b/openecomp-be/tools/build/scripts/action_library_client/test/test_action_library_client_integration.py @@ -0,0 +1,329 @@ +import sys +import os +import unittest +import uuid +import json +import tempfile +import action_library_client + +class IntegrationTest(unittest.TestCase): + + HTTP = "http://10.147.97.199:8080" + HTTPS = "https://10.147.97.199:8443" + + def setUp(self): + os.environ["ALC_HTTP_USER"] = "AUTH-DELETE" + os.environ["ALC_HTTP_PASS"] = "test" + + def tearDown(self): + os.environ["ALC_HTTP_INSECURE"] = "" + os.environ["ALC_HTTP_USER"] = "" + os.environ["ALC_HTTP_PASS"] = "" + + @staticmethod + def __prepare(testcase, name): + with open(testcase, 'r') as fin: + jsonk = json.loads(fin.read()) + jsonk['name'] = name + with tempfile.NamedTemporaryFile(mode='w', delete=False) as temp: + temp.write(json.dumps(jsonk)) + temp.flush() + return temp.name + + @staticmethod + def __get_sequence(): + with open(r'./seq.txt', 'r+') as f: + value = int(f.read()) + f.seek(0) + f.write(str(value + 1)) + return value + + def __print_separator(self): + logger = action_library_client.Runner.get_logger() + logger.info("==================================================") + + def __list(self, stdargs): + logger = action_library_client.Runner.get_logger() + list_response = action_library_client.execute(["--list"] + stdargs) + logger.info("--list response: {}".format(list_response)) + self.assertTrue(isinstance(list_response, dict)) + return list_response + + def __get_action(self, list_response, ai_uuid): + for action in list_response['actionList']: + if action['actionInvariantUUID'] == ai_uuid: + return action + + def __create_delete(self, extraargs): + + logger = action_library_client.Runner.get_logger() + + # Setup. + + seq = IntegrationTest.__get_sequence() + name = "Backout{}".format(seq) + path = IntegrationTest.__prepare("scenarios/Backout.json", name) + stdargs = ["--url", self.HTTP, "--verbose"] + if extraargs: + stdargs.extend(extraargs) + + # List actions. + + self.__print_separator() + list_response1 = self.__list(stdargs) + self.assertTrue(isinstance(list_response1, dict)) + + # CREATE action. + + self.__print_separator() + create_response = action_library_client.execute(["--create", "--in", path] + stdargs) + logger.info("--create response: {}".format(create_response)) + self.assertTrue(isinstance(create_response, dict)) + ai_uuid = create_response['actionInvariantUUID'] + self.assertTrue(ai_uuid) + self.assertEquals(create_response['status'], 'Locked') + self.assertEquals(create_response['version'], '0.1') + + # UPDATE action #1. + + self.__print_separator() + update_response1 = action_library_client.execute(["--update", "--in", path, "--uuid", ai_uuid] + stdargs) + logger.info("--update response: {}".format(update_response1)) + self.assertTrue(isinstance(update_response1, dict)) + + # UPDATE action #2. + + self.__print_separator() + update_response2 = action_library_client.execute(["--update", "--in", path, "--uuid", ai_uuid] + stdargs) + logger.info("--update response: {}".format(update_response2)) + self.assertTrue(isinstance(update_response2, dict)) + + # CHECKOUT action (usage unknown). + + self.__print_separator() + try: + action_library_client.execute(["--checkout", "--uuid", ai_uuid] + stdargs) + self.fail("--checkout should fail") + except Exception as err: + print(err) + + # CHECKIN action. + + self.__print_separator() + checkin_response = action_library_client.execute(["--checkin", "--in", path, "--uuid", ai_uuid] + stdargs) + logger.info("--checkin response: {}".format(checkin_response)) + self.assertTrue(isinstance(checkin_response, dict)) + self.assertEquals(checkin_response['status'], 'Available') + self.assertEquals(checkin_response['version'], '0.1') + + # SUBMIT action. + + self.__print_separator() + submit_response = action_library_client.execute(["--submit", "--in", path, "--uuid", ai_uuid] + stdargs) + logger.info("--submit response: {}".format(submit_response)) + self.assertTrue(isinstance(submit_response, dict)) + self.assertEquals(submit_response['status'], 'Final') + self.assertEquals(submit_response['version'], '1.0') + + # LIST again + + self.__print_separator() + list_response2 = self.__list(stdargs) + action_found2 = self.__get_action(list_response2, ai_uuid) + self.assertTrue(action_found2) + + # DELETE action. + + self.__print_separator() + delete_response = action_library_client.execute(["--delete", "--uuid", ai_uuid] + stdargs) + logger.info("--delete response: {}".format(delete_response)) + self.assertEqual(delete_response, action_library_client.ResponseCodes.OK) + + # LIST yet again + + self.__print_separator() + list_response3 = self.__list(stdargs) + action_found3 = self.__get_action(list_response3, ai_uuid) + self.assertFalse(action_found3) + + def __create_undo(self, extraargs): + + # Setup + + logger = action_library_client.Runner.get_logger() + seq = IntegrationTest.__get_sequence() + name = "Backout{}".format(seq) + path = IntegrationTest.__prepare("scenarios/Backout.json", name) + stdargs = ["--url", self.HTTP, "--verbose"] + + # CREATE action. + + self.__print_separator() + create_response = action_library_client.execute(["--create", "--in", path] + stdargs + extraargs) + logger.info("--create response: {}".format(create_response)) + self.assertTrue(isinstance(create_response, dict)) + ai_uuid = create_response['actionInvariantUUID'] + self.assertTrue(ai_uuid) + self.assertEquals(create_response['status'], 'Locked') + self.assertEquals(create_response['version'], '0.1') + + # UNDOCHECKOUT action + + self.__print_separator() + undocheckout_response = action_library_client.execute(["--undocheckout", "--uuid", ai_uuid] + stdargs + extraargs) + self.assertTrue(isinstance(undocheckout_response, dict)) + + def __create_list(self, extraargs): + # Setup + + logger = action_library_client.Runner.get_logger() + seq = IntegrationTest.__get_sequence() + name = "Backout{}".format(seq) + path = IntegrationTest.__prepare("scenarios/Backout.json", name) + stdargs = ["--url", self.HTTP, "--verbose"] + + # CREATE action. + + self.__print_separator() + create_response = action_library_client.execute(["--create", "--in", path] + stdargs + extraargs) + logger.info("--create response: {}".format(create_response)) + self.assertTrue(isinstance(create_response, dict)) + ai_uuid = create_response['actionInvariantUUID'] + self.assertTrue(ai_uuid) + self.assertEquals(create_response['status'], 'Locked') + self.assertEquals(create_response['version'], '0.1') + + # CHECKIN action. + + self.__print_separator() + checkin_response = action_library_client.execute(["--checkin", "--in", path, "--uuid", ai_uuid] + + stdargs + extraargs) + logger.info("--checkin response: {}".format(checkin_response)) + self.assertTrue(isinstance(checkin_response, dict)) + self.assertEquals(checkin_response['status'], 'Available') + self.assertEquals(checkin_response['version'], '0.1') + + try: + # LIST. + + self.__print_separator() + list_response1 = self.__list(stdargs + extraargs) + action_found1 = self.__get_action(list_response1, ai_uuid) + self.assertTrue(action_found1) + + # LIST with UUID. + + self.__print_separator() + list_response2 = self.__list(stdargs + extraargs + ["--uuid", ai_uuid]) + self.assertFalse(hasattr(list_response2, 'actionList')) + self.assertEquals(len(list_response2['versions']), 1) + + # LIST with bad UUID. + + self.__print_separator() + list_response3 = action_library_client.execute(["--list"] + stdargs + extraargs + + ["--uuid", "where_the_wind_blows"]) + if isinstance(list_response3, int): + self.assertEquals(action_library_client.ResponseCodes.HTTP_NOT_FOUND_ERROR, list_response3) + else: + self.assertEquals("ACT1045", list_response3["code"]) + + finally: + + # DELETE action + + self.__print_separator() + action_library_client.execute(["--delete", "--uuid", ai_uuid] + stdargs + extraargs) + + def __http_secure(self, extraargs): + os.environ["ALC_HTTP_INSECURE"] = "" + try: + self.__list(["--url", self.HTTPS, "--verbose"] + extraargs) + if not (sys.version_info[0] == 2 and sys.version_info[1] == 6): + self.fail("Should fail (non-2.6) for TLS + secure") + except Exception: + pass + + def __http_insecure(self, extraargs): + os.environ["ALC_HTTP_INSECURE"] = True + self.__list(["--url", self.HTTPS, "--verbose"] + extraargs) + + def __no_credentials(self, extraargs): + + args = ["--url", self.HTTP] + extraargs + self.__list(args) + print("OK") + + os.environ["ALC_HTTP_USER"] = "" + os.environ["ALC_HTTP_PASS"] = "" + try: + action_library_client.execute(["--list"] + args) + self.fail("Should fail for missing credentials") + except Exception as e: + self.assertEquals("REST service credentials not found", e.message) + + def __bad_credentials(self, extraargs): + + args = ["--url", self.HTTP] + extraargs + self.__list(args) + + os.environ["ALC_HTTP_USER"] = "wakey_wakey" + os.environ["ALC_HTTP_PASS"] = "rise_and_shine" + code = action_library_client.execute(["--list"] + args) + self.assertEquals(action_library_client.ResponseCodes.HTTP_FORBIDDEN_ERROR, code) + + ################################################################################ + + def test_https_insecure_local_fail(self): + self.__http_secure([]) + + def test_https_insecure_remote_fail(self): + self.__http_secure(["--curl"]) + + def test_https_native(self): + self.__http_secure([]) + + def test_https_curl(self): + self.__http_secure(["--curl"]) + + def test_undo_checkout_native(self): + self.__create_undo([]) + + def test_undo_checkout_curl(self): + self.__create_undo(["--curl"]) + + def test_create_delete_native(self): + self.__create_delete([]) + + def test_create_delete_curl(self): + self.__create_delete(["--curl"]) + + def test_create_list_native(self): + self.__create_list([]) + + def test_create_list_curl(self): + self.__create_list(["--curl"]) + + def test_bad_credentials_native(self): + self.__bad_credentials([]) + + def test_bad_credentials_curl(self): + self.__bad_credentials(["--curl"]) + # + def test_no_credentials_native(self): + self.__no_credentials([]) + + def test_no_credentials_curl(self): + self.__no_credentials(["--curl"]) + + def test_create_to_delete_dryrun(self): + ai_uuid = str(uuid.uuid4()) + path = IntegrationTest.__prepare("scenarios/Backout.json", "Backout{}".format("001")) + stdargs = ["--url", self.HTTP, "--verbose", "--dryrun"] + action_library_client.execute(["--create", "--in", path] + stdargs) + action_library_client.execute(["--update", "--in", path, "--uuid", ai_uuid] + stdargs) + action_library_client.execute(["--checkout", "--uuid", ai_uuid] + stdargs) + action_library_client.execute(["--undocheckout", "--uuid", ai_uuid] + stdargs) + action_library_client.execute(["--checkin", "--uuid", ai_uuid] + stdargs) + action_library_client.execute(["--submit", "--uuid", ai_uuid] + stdargs) + action_library_client.execute(["--list"] + stdargs) diff --git a/openecomp-be/tools/build/scripts/cassandra-commands.json b/openecomp-be/tools/build/scripts/cassandra-commands.json new file mode 100644 index 0000000000..8354ff2532 --- /dev/null +++ b/openecomp-be/tools/build/scripts/cassandra-commands.json @@ -0,0 +1,76 @@ +{ + "create": { + "version": "CREATE TYPE IF NOT EXISTS version (major int, minor int)", + "user_candidate_version": "CREATE TYPE IF NOT EXISTS user_candidate_version (version frozen, user text)", + "version_info": "CREATE TABLE IF NOT EXISTS version_info (entity_type text, entity_id text, active_version frozen, status text, candidate frozen, viewable_versions set>, latest_final_version frozen, PRIMARY KEY (entity_type, entity_id))", + "version_info_deleted": "CREATE TABLE IF NOT EXISTS version_info_deleted (entity_type text, entity_id text, active_version frozen, status text, candidate frozen, viewable_versions set>, latest_final_version frozen, PRIMARY KEY (entity_type, entity_id))", + "unique_value" : "CREATE TABLE IF NOT EXISTS unique_value (type text, value text, PRIMARY KEY ((type, value)))", + "choice_or_other": "CREATE TYPE IF NOT EXISTS choice_or_other (result text)", + "multi_choice_or_other": "CREATE TYPE IF NOT EXISTS multi_choice_or_other (results set)", + "vendor_license_model": "CREATE TABLE IF NOT EXISTS vendor_license_model (vlm_id text, version frozen, vendor_name text, description text, icon text, PRIMARY KEY ((vlm_id, version)))", + "license_agreement": "CREATE TABLE IF NOT EXISTS license_agreement (vlm_id text, version frozen, la_id text, name text, description text, lic_term frozen, req_const text, fg_ids set, PRIMARY KEY ((vlm_id, version), la_id))", + "feature_group": "CREATE TABLE IF NOT EXISTS feature_group (vlm_id text, version frozen, fg_id text, name text, description text, part_num text, ep_ids set, lkg_ids set, ref_la_ids set, PRIMARY KEY ((vlm_id, version), fg_id))", + "license_key_group": "CREATE TABLE IF NOT EXISTS license_key_group (vlm_id text, version frozen, lkg_id text,name text,description text, type text, operational_scope frozen, ref_fg_ids set, version_uuid text, PRIMARY KEY ((vlm_id, version), lkg_id))", + "entitlement_pool": "CREATE TABLE IF NOT EXISTS entitlement_pool (vlm_id text, version frozen, ep_id text,name text,description text,threshold float,threshold_unit text,entitlement_metric frozen,increments text,aggregation_func frozen, operational_scope frozen, time frozen,manufacturer_ref_num text,ref_fg_ids set, version_uuid text, PRIMARY KEY ((vlm_id, version), ep_id))", + "vsp_information": "CREATE TABLE IF NOT EXISTS vsp_information (VSP_ID text, version frozen, NAME text,DESCRIPTION text,CATEGORY text,SUB_CATEGORY text,ICON text,PACKAGE_NAME text,PACKAGE_VERSION text,vendor_name text, vendor_id text,LICENSE_AGREEMENT text,FEATURE_GROUPS list,VALIDATION_DATA text,CONTENT_DATA blob, questionnaire_data text, vlm_version frozen, PRIMARY KEY ((VSP_ID, version)))", + "package_details": "CREATE TABLE IF NOT EXISTS package_details (VSP_ID text, version frozen,DISPLAY_NAME text,vsp_name text,vsp_description text,VENDOR_NAME text,CATEGORY text,SUB_CATEGORY text,VENDOR_RELEASE text,PACKAGE_CHECKSUM text,PACKAGE_TYPE text,TRANSLATE_CONTENT blob,PRIMARY KEY ((VSP_ID, version)))", + "vsp_network": "CREATE TABLE IF NOT EXISTS vsp_network (vsp_id text, version frozen, network_id text, composition_data text, questionnaire_data text, PRIMARY KEY ((vsp_id, version), network_id))", + "vsp_component": "CREATE TABLE IF NOT EXISTS vsp_component (vsp_id text, version frozen, component_id text, composition_data text, questionnaire_data text, PRIMARY KEY ((vsp_id, version), component_id))", + "vsp_component_nic": "CREATE TABLE IF NOT EXISTS vsp_component_nic (vsp_id text, version frozen, component_id text, nic_id text, composition_data text, questionnaire_data text, PRIMARY KEY ((vsp_id, version), component_id, nic_id))", + "vsp_process" : "CREATE TABLE IF NOT EXISTS vsp_process (vsp_id text, version frozen, component_id text, process_id text, name text, description text, artifact_name text, artifact blob, PRIMARY KEY ((vsp_id, version), component_id, process_id))", + "vsp_service_artifact" : "CREATE TABLE IF NOT EXISTS vsp_service_artifact (vsp_id text, version frozen, name text, content_data blob, PRIMARY KEY ((vsp_id, version), name))", + "vsp_service_template" : "CREATE TABLE IF NOT EXISTS vsp_service_template (vsp_id text, version frozen, base_name text static, name text, content_data blob, PRIMARY KEY ((vsp_id, version), name))", + "vsp_enriched_service_template" : "CREATE TABLE IF NOT EXISTS vsp_enriched_service_template (vsp_id text, version frozen, base_name text static, name text, content_data blob, PRIMARY KEY ((vsp_id, version), name))", + "vsp_enriched_service_artifact" : "CREATE TABLE IF NOT EXISTS vsp_enriched_service_artifact (vsp_id text, version frozen, name text, content_data blob, PRIMARY KEY ((vsp_id, version), name))", + "application_config" : "CREATE TABLE IF NOT EXISTS application_config (namespace text, key text, value text, PRIMARY KEY (namespace, key))", + "action" : "CREATE TABLE IF NOT EXISTS dox.Action (actionUUID text, actionInvariantUUID text, version frozen, status text, name text, vendor_list set, category_list set, timestamp timestamp, user text, supportedModels set, supportedComponents set, data text, PRIMARY KEY ((actionInvariantUUID, version)))", + "supportedComponents_index" : "CREATE INDEX IF NOT EXISTS action_supportedComponents ON dox.Action (supportedComponents)", + "category_list_index" : "CREATE INDEX IF NOT EXISTS action_category_list ON dox.Action (category_list)", + "supportedModels_index" : "CREATE INDEX IF NOT EXISTS action_supportedModels ON dox.Action (supportedModels)", + "vendor_list_index" : "CREATE INDEX IF NOT EXISTS action_vendor_list ON dox.Action (vendor_list)", + "actionUUID_index" : "CREATE INDEX IF NOT EXISTS action_actionUUID ON dox.Action (actionUUID)", + "ecomp_component": "CREATE TABLE IF NOT EXISTS dox.ecompcomponent(id text PRIMARY KEY, name text)", + "vsp_component_artifact": "CREATE TABLE IF NOT EXISTS vsp_component_artifact (vsp_id text, version frozen, component_id text, artifact_type text, artifact_id text, name text, description text, artifact blob, PRIMARY KEY ((vsp_id, version), component_id, artifact_type, artifact_id))", + "name_index": "CREATE INDEX IF NOT EXISTS action_name ON dox.Action (name)", + "action_artifact":"CREATE TABLE IF NOT EXISTS action_artifact(artifactuuid text, effective_version int, artifact blob, PRIMARY KEY(artifactuuid, effective_version)) WITH CLUSTERING ORDER BY (effective_version DESC)" + }, + "drop": { + "version_info": "DROP TABLE IF EXISTS version_info", + "version_info_deleted": "DROP TABLE IF EXISTS version_info_deleted", + "unique_value": "DROP TABLE IF EXISTS unique_value", + "entitlement_pool": "DROP TABLE IF EXISTS entitlement_pool", + "vendor_license_model": "DROP TABLE IF EXISTS vendor_license_model", + "license_agreement": "DROP TABLE IF EXISTS license_agreement", + "feature_group": "DROP TABLE IF EXISTS feature_group", + "license_key_group": "DROP TABLE IF EXISTS license_key_group", + "vsp_information": "DROP TABLE IF EXISTS vsp_information", + "package_details": "DROP TABLE IF EXISTS package_details", + "vsp_network": "DROP TABLE IF EXISTS vsp_network", + "vsp_component": "DROP TABLE IF EXISTS vsp_component", + "vsp_component_nic": "DROP TABLE IF EXISTS vsp_component_nic", + "vsp_process":"DROP TABLE IF EXISTS vsp_process", + "choice_or_other": "DROP TYPE IF EXISTS choice_or_other", + "multi_choice_or_other": "DROP TYPE IF EXISTS multi_choice_or_other", + "application_config" : "DROP TABLE IF EXISTS application_config", + "vsp_service_artifact" :"DROP TABLE IF EXISTS vsp_service_artifact", + "vsp_service_template" :"DROP TABLE IF EXISTS vsp_service_template", + "vsp_enriched_service_artifact" :"DROP TABLE IF EXISTS vsp_enriched_service_artifact", + "vsp_enriched_service_template" :"DROP TABLE IF EXISTS vsp_enriched_service_template", + "action" : "DROP TABLE IF EXISTS action", + "supportedComponents_index" : "DROP INDEX IF EXISTS dox.action_supportedComponents", + "category_list_index" : "DROP INDEX IF EXISTS dox.action_category_list", + "supportedModels_index" : "DROP INDEX IF EXISTS dox.action_supportedModels", + "vendor_list_index" : "DROP INDEX IF EXISTS dox.action_vendor_list", + "actionUUID_index" : "DROP INDEX IF EXISTS dox.action_actionUUID", + "name_index" : "DROP INDEX IF EXISTS dox.action_name", + "ecomp_component": "DROP TABLE IF EXISTS dox.ecompcomponent", + "vsp_component_artifact": "DROP TABLE IF EXISTS dox.vsp_component_artifact", + "action_artifact":"DROP TABLE IF EXISTS action_artifact" + }, + "alter": { + "vsp_information": "ALTER TABLE vsp_information ADD questionnaire_data text", + "vsp_information_1": "ALTER TABLE vsp_information ADD vlm_version frozen", + "entitlement_pool": "alter table entitlement_pool ADD version_uuid text", + "license_key_group": "alter table license_key_group ADD version_uuid text" + } +} diff --git a/openecomp-be/tools/build/scripts/generate-application-config-insert-cql.sh b/openecomp-be/tools/build/scripts/generate-application-config-insert-cql.sh new file mode 100644 index 0000000000..e4e1ff0075 --- /dev/null +++ b/openecomp-be/tools/build/scripts/generate-application-config-insert-cql.sh @@ -0,0 +1,64 @@ +#/bin/sh + +############################################################################## +### +### generate-application-config-insert-cql.sh +### +### A script that generates the CQL commands to INSERT validation schemas to the application_config table. +### We keep the schemas FTL files under a folder - this folder will be parsed and INSERT commands will be created. +### +### If the path is 'schemaTemplates/composition/myFile.ftl' the result KEY will be: composition.myFile . +### +### Usage: +### +### ./generate-application-config-insert-cql.sh +### +### +### Author: Avi Ziv +### Version 1.0 for OPENECOMP +### Date: 10 Aug 2016 +### +############################################################################## + +#GLOBALS + +APP_CONFIG_TABLE='application_config' + +#### Functions - Start #### +usage() { echo "Usage: $0 , for example: $0 vsp.schemaTemplates schemaTemplates/" 1>&2; exit 1; } + +getFileContent() +{ + file=$1 + str=$(<$file) + echo $str +} + + +main() +{ + namespace=$1 + path=$2 + for fileName in $(find ${path} -type f) + do + value=$(getFileContent ${fileName}) + onlyFilename=$(basename $fileName) + name="${onlyFilename%.*}" + tempPath=$(dirname $fileName) + keyColumn=$(basename $tempPath).$name + echo "INSERT INTO $APP_CONFIG_TABLE (namespace,key,value) VALUES ('$namespace', '$keyColumn', '$value');" + done + + +exit 0 +} + +#### Functions - End #### + +# Check arguements +if [ "$#" -lt 2 ] || [ "$#" -gt 2 ]; then + usage +fi + + +main $1 $2 diff --git a/openecomp-be/tools/build/scripts/generate-cassandra-alter-cql.sh b/openecomp-be/tools/build/scripts/generate-cassandra-alter-cql.sh new file mode 100644 index 0000000000..827b3ab330 --- /dev/null +++ b/openecomp-be/tools/build/scripts/generate-cassandra-alter-cql.sh @@ -0,0 +1,40 @@ +#!/bin/sh + +############################################################################## +### +### generate-cassandra-alter-cql.sh +### +### A script that generates the CQL commands of ALTER for the Cassnadra init. +### +### Usage: +### +### ./generate-cassandra-alter-cql.sh cassandra-commands.json +### +### +### Author: Avi Ziv +### Version 2.0 for OPENECOMP +### Date: 21 Sep 2016 +### +############################################################################## + +#GLOBALS + +RUN_PATH=$(cd "$(dirname "$0")" && pwd) + +#### Functions - Start #### +usage() { echo "Usage: $0 , for example: $0 cassandra-commands.json" 1>&2; exit 1; } + +main() +{ + echo "USE dox;" + $RUN_PATH/parse-json.py -t alter -f $1 +} + +#### Functions - End #### + +# Check arguements +if [ "$#" -lt 1 ] || [ "$#" -gt 1 ]; then + usage +fi + +main $1 diff --git a/openecomp-be/tools/build/scripts/generate-cassandra-drop-cql.sh b/openecomp-be/tools/build/scripts/generate-cassandra-drop-cql.sh new file mode 100644 index 0000000000..ddbf846b30 --- /dev/null +++ b/openecomp-be/tools/build/scripts/generate-cassandra-drop-cql.sh @@ -0,0 +1,40 @@ +#!/bin/sh + +############################################################################## +### +### generate-cassandra-drop-cql.sh +### +### A script that generates the CQL commands of DROP for the Cassnadra init. +### +### Usage: +### +### ./generate-cassandra-init-cql.sh cassandra-commands.json +### +### +### Author: Avi Ziv +### Version 1.0 for OPENECOMP +### Date: 21 Sep 2016 +### +############################################################################## + +#GLOBALS + +RUN_PATH=$(cd "$(dirname "$0")" && pwd) + +#### Functions - Start #### +usage() { echo "Usage: $0 , for example: $0 cassandra-commands.json" 1>&2; exit 1; } + +main() +{ + echo "USE dox;" + $RUN_PATH/parse-json.py -t drop -f $1 +} + +#### Functions - End #### + +# Check arguements +if [ "$#" -lt 1 ] || [ "$#" -gt 1 ]; then + usage +fi + +main $1 diff --git a/openecomp-be/tools/build/scripts/generate-cassandra-init-cql.sh b/openecomp-be/tools/build/scripts/generate-cassandra-init-cql.sh new file mode 100644 index 0000000000..65af5a51ae --- /dev/null +++ b/openecomp-be/tools/build/scripts/generate-cassandra-init-cql.sh @@ -0,0 +1,44 @@ +#!/bin/sh + +############################################################################## +### +### generate-cassandra-init-cql.sh +### +### A script that generates the CQL commands of CREATE for the Cassnadra init. +### +### Usage: +### +### ./generate-cassandra-init-cql.sh cassandra-commands.json +### +### +### Author: Avi Ziv +### Version 2.0 for OPENECOMP +### Date: 21 Sep 2016, added support for keyspace yes/no for OPENECOMP DevOps build +### +############################################################################## + +#GLOBALS + +RUN_PATH=$(cd "$(dirname "$0")" && pwd) + +#### Functions - Start #### +usage() { echo "Usage: $0 keyspace yes/no, for example: $0 cassandra-commands.json keyspace yes" 1>&2; exit 1; } + +main() +{ + if [ $3 == 'yes' ]; then + echo "CREATE KEYSPACE IF NOT EXISTS dox WITH REPLICATION = { 'class' : 'SimpleStrategy', 'replication_factor' : 3 };" + fi + echo "USE dox;" + $RUN_PATH/parse-json.py -t create -f $1 + +} + +#### Functions - End #### + +# Check arguements +if [ "$#" -lt 1 ] || [ "$#" -gt 3 ]; then + usage +fi + +main $1 $2 $3 diff --git a/openecomp-be/tools/build/scripts/parse-json.py b/openecomp-be/tools/build/scripts/parse-json.py new file mode 100644 index 0000000000..46537ceac5 --- /dev/null +++ b/openecomp-be/tools/build/scripts/parse-json.py @@ -0,0 +1,83 @@ +#!/usr/bin/python + +############################################################################## +### +### parse-json.py +### +### A utility to parse a cassnadra-commands file and return the commands per type +### An Example for a json file: +### { +### "create":{ +### "choice_or_other":"CREATE TYPE IF NOT EXISTS choice_or_other (results text)", +### "vendor_license_model": "CREATE TABLE IF NOT EXISTS vendor_license_model (vlm_id text PRIMARY KEY, name text, description text, icon text)", +### "license_agreement": "CREATE TABLE IF NOT EXISTS license_agreement (vlm_id text, la_id text, name text, description text, type text, contract text, req_const text, fg_ids set, PRIMARY KEY (vlm_id, la_id))", +### "feature_group": "CREATE TABLE IF NOT EXISTS feature_group (vlm_id text, fg_id text, name text, description text, ep_ids set, lkg_ids set, refd_by_las set, PRIMARY KEY (vlm_id, fg_id))", +### "license_key_group": "CREATE TABLE IF NOT EXISTS license_key_group (vlm_id text,lkg_id text,name text,description text, type text, operational_scope text, ref_fgs set,PRIMARY KEY (vlm_id, lkg_id))", +### } +### } +### +### The return for "create" will be: +### CREATE TYPE IF NOT EXISTS choice_or_other (results text) +### CREATE TABLE IF NOT EXISTS vendor_license_model (vlm_id text PRIMARY KEY, name text, description text, icon text) +### CREATE TABLE IF NOT EXISTS license_agreement (vlm_id text, la_id text, name text, description text, type text, contract text, req_const text, fg_ids set, PRIMARY KEY (vlm_id, la_id)) +### CREATE TABLE IF NOT EXISTS feature_group (vlm_id text, fg_id text, name text, description text, ep_ids set, lkg_ids set, refd_by_las set, PRIMARY KEY (vlm_id, fg_id)) +### CREATE TABLE IF NOT EXISTS license_key_group (vlm_id text,lkg_id text,name text,description text, type text, operational_scope text, ref_fgs set,PRIMARY KEY (vlm_id, lkg_id)) +### Usage: +### +### parse-json.py -t create -f cassandra-commands.json +### +### For example: +### +### +### Author: Avi Ziv +### Version 1.0 +### Date: 3 May 2016 +### +############################################################################## + +import sys, getopt +import json as json +from collections import OrderedDict + + +def readJsonFile(file, type): + with open(file, 'r') as f: + data = json.load(f, object_pairs_hook=OrderedDict) + return data[type] + +def printJsonTypeEntries(jsonData): + for i in jsonData.keys(): + print jsonData[i] + ';' + + +def usage(): + print 'parseJsonFile.py [-f & -t (OpenStack types)" + }, + { + "name": "memory", + "type": "Gauge", + "unit": "MB", + "category": "compute", + "description": "Volume of RAM allocated to the instance" + }, + { + "name": "memory.usage", + "type": "Gauge", + "unit": "MB", + "category": "compute", + "description": "Volume of RAM used by the instance from the amount of its allocated memory" + }, + { + "name": "memory.resident", + "type": "Gauge", + "unit": "MB", + "category": "compute", + "description": "Volume of RAM used by the instance on the physical machine" + }, + { + "name": "cpu", + "type": "Cumulative", + "unit": "ns", + "category": "compute", + "description": "CPU time used" + }, + { + "name": "cpu_util", + "type": "Gauge", + "unit": "%", + "category": "compute", + "description": "Average CPU utilization" + }, + { + "name": "cpu.delta", + "type": "Delta", + "unit": "ns", + "category": "compute", + "description": "CPU time used since previous datapoint" + }, + { + "name": "vcpus", + "type": "Gauge", + "unit": "ms", + "category": "compute", + "description": "Average disk latency" + } + ] +} \ No newline at end of file diff --git a/openecomp-be/tools/install/database/schemaTemplates/composition/component.ftl b/openecomp-be/tools/install/database/schemaTemplates/composition/component.ftl new file mode 100644 index 0000000000..1c0cb4eb8a --- /dev/null +++ b/openecomp-be/tools/install/database/schemaTemplates/composition/component.ftl @@ -0,0 +1,28 @@ +{ + "$schema": "http://json-schema.org/draft-04/schema#", + "type": "object", + "properties": { + "name": { + "type": "string"<#if !manual>, + "enum": [ + "${component.name}" + ], + "default": "${component.name}" + }, + "displayName": { + "type": "string"<#if !manual && component.displayName??>, + "enum": [ + "${component.displayName}" + ], + "default": "${component.displayName}" + }, + "description": { + "type": "string" + } + }, + "additionalProperties": false, + "required": [ + "name"<#if !manual && component.displayName??>, + "displayName" + ] +} \ No newline at end of file diff --git a/openecomp-be/tools/install/database/schemaTemplates/composition/network.ftl b/openecomp-be/tools/install/database/schemaTemplates/composition/network.ftl new file mode 100644 index 0000000000..1193992923 --- /dev/null +++ b/openecomp-be/tools/install/database/schemaTemplates/composition/network.ftl @@ -0,0 +1,25 @@ +{ + "$schema": "http://json-schema.org/draft-04/schema#", + "type": "object", + "properties": { + "name": { + "type": "string"<#if !manual>, + "enum": [ + "${network.name}" + ], + "default": "${network.name}" + }, + "dhcp": { + "type": "boolean"<#if !manual>, + "enum": [ + ${network.dhcp?c} + ], + "default": ${network.dhcp?c} + } + }, + "additionalProperties": false, + "required": [ + "name", + "dhcp" + ] +} \ No newline at end of file diff --git a/openecomp-be/tools/install/database/schemaTemplates/composition/nic.ftl b/openecomp-be/tools/install/database/schemaTemplates/composition/nic.ftl new file mode 100644 index 0000000000..6111348f88 --- /dev/null +++ b/openecomp-be/tools/install/database/schemaTemplates/composition/nic.ftl @@ -0,0 +1,36 @@ +{ + "$schema": "http://json-schema.org/draft-04/schema#", + "type": "object", + "properties": { + "name": { + "type": "string"<#if !manual>, + "enum": [ + "${nic.name}" + ], + "default": "${nic.name}" + + }, + "description": { + "type": "string" + }<#if !manual><#if nic.networkId??>, + "networkId": { + "type": "string", + "enum": [ + "${nic.networkId}" + ], + "default": "${nic.networkId}" + } + <#else>, + "networkId": { + "type": "string", + "enum": [<#list networkIds as networkId> + "${networkId}"<#sep>, + ] + } + + }, + "additionalProperties": false, + "required": [ + "name" + ] +} \ No newline at end of file diff --git a/openecomp-be/tools/install/database/schemaTemplates/questionnaire/component.ftl b/openecomp-be/tools/install/database/schemaTemplates/questionnaire/component.ftl new file mode 100644 index 0000000000..540afca430 --- /dev/null +++ b/openecomp-be/tools/install/database/schemaTemplates/questionnaire/component.ftl @@ -0,0 +1,327 @@ +{ + "$schema": "http://json-schema.org/draft-04/schema#", + "type": "object", + "properties": { + "general": { + "type": "object", + "properties": { + "hypervisor": { + "type": "object", + "properties": { + "hypervisor": { + "type": "string", + "enum": [ + "KVM", + "VMWare ESXi" + ], + "default": "KVM" + }, + "drivers": { + "type": "string", + "maxLength": 300, + "pattern": "^[A-Za-z0-9_,-]*$" + }, + "containerFeaturesDescription": { + "type": "string", + "maxLength": 1000, + "pattern": "^[A-Za-z0-9_, -]*$" + } + }, + "additionalProperties": false + }, + "image": { + "type": "object", + "properties": { + "format": { + "type": "string", + "enum": [ + "aki", + "ami", + "ari", + "iso", + "qcow2", + "raw", + "vdi", + "vhd", + "vmdk" + ], + "default": "qcow2" + }, + "providedBy": { + "type": "string", + "enum": [ + "Vendor" + ], + "default": "Vendor" + }, + "bootDiskSizePerVM": { + "type": "number", + "maximum": 100 + }, + "ephemeralDiskSizePerVM": { + "type": "number", + "maximum": 400 + } + }, + "additionalProperties": false + }, + "recovery": { + "type": "object", + "properties": { + "pointObjective": { + "type": "number", + "minimum": 0, + "exclusiveMinimum": true, + "maximum": 15, + "exclusiveMaximum ": true + }, + "timeObjective": { + "type": "number", + "minimum": 0, + "exclusiveMinimum": true, + "maximum": 300, + "exclusiveMaximum ": true + }, + "vmProcessFailuresHandling": { + "type": "string" + } + }, + "additionalProperties": false + }, + "dnsConfiguration": { + "type": "string" + }, + "vmCloneUsage": { + "type": "string", + "maximum": 300 + } + }, + "additionalProperties": false + }, + "compute": { + "type": "object", + "properties": { + "vmSizing": { + "type": "object", + "properties": { + "numOfCPUs": { + "type": "number", + "minimum": 0, + "exclusiveMinimum": true, + "maximum": 16, + "default": 2 + }, + "fileSystemSizeGB": { + "type": "number", + "minimum": 0, + "exclusiveMinimum": true, + "default": 5 + }, + "persistentStorageVolumeSize": { + "type": "number", + "minimum": 0, + "exclusiveMinimum": true + }, + "IOOperationsPerSec": { + "type": "number", + "minimum": 0, + "exclusiveMinimum": true + } + }, + "additionalProperties": false + }, + "numOfVMs": { + "type": "object", + "properties": { + "minimum": { + "type": "number", + "minimum": 0, + "exclusiveMinimum": true, + "maximum": 100 + }, + "maximum": { + "type": "number", + "minimum": <#if (componentQuestionnaireData.compute.numOfVMs.minimum)?? + && (componentQuestionnaireData.compute.numOfVMs.minimum)?is_number + && ((componentQuestionnaireData.compute.numOfVMs.minimum) > 0 + && (componentQuestionnaireData.compute.numOfVMs.minimum) <= 100)> + ${componentQuestionnaireData.compute.numOfVMs.minimum}<#else> + 0 , + "exclusiveMinimum": true, + "maximum": 100 + }, + "CpuOverSubscriptionRatio": { + "type": "string", + "enum": [ + "1:1", + "4:1", + "16:1" + ], + "default": "4:1" + }, + "MemoryRAM": { + "type": "string", + "enum": [ + "2 GB", + "4 GB", + "8 GB" + ], + "default": "2 GB" + } + }, + "additionalProperties": false + }, + "guestOS": { + "type": "object", + "properties": { + "name": { + "type": "string", + "maxLength": 50 + }, + "bitSize": { + "type": "number", + "enum": [ + 64, + 32 + ], + "default": 64 + }, + "tools": { + "type": "string" + } + }, + "additionalProperties": false + } + }, + "additionalProperties": false + }, + "highAvailabilityAndLoadBalancing": { + "type": "object", + "properties": { + "failureLoadDistribution": { + "type": "string", + "maxLength": 1000 + }, + "nkModelImplementation": { + "type": "string", + "maxLength": 1000 + }, + "architectureChoice": { + "type": "string", + "maxLength": 1000 + }, + "slaRequirements": { + "type": "string", + "maxLength": 1000 + }, + "horizontalScaling": { + "type": "string", + "maxLength": 1000 + }, + "loadDistributionMechanism": { + "type": "string", + "maxLength": 1000 + } + }, + "additionalProperties": false + }, + "network": { + "type": "object", + "properties": { + "networkCapacity": { + "type": "object", + "properties": { + "protocolWithHighestTrafficProfileAcrossAllNICs": { + "type": "string", + "enum": [ + "", + "TCP", + "UDP", + "SCTP", + "IPsec" + ], + "default": "" + }, + "networkTransactionsPerSecond": { + "type": "number" + } + }, + "additionalProperties": false + } + }, + "additionalProperties": false + }, + "storage": { + "type": "object", + "properties": { + "backup": { + "type": "object", + "properties": { + "backupType": { + "type": "string", + "enum": [ + "On Site", + "Off Site" + ], + "default": "On Site" + }, + "backupStorageSize": { + "type": "number" + }, + "backupSolution": { + "type": "string" + }, + "backupNIC": { + "type": "string", + "enum": [ + "", <#if nicNames??><#list nicNames as nicName> + "${nicName}"<#sep>, + ], + "default": "" + } + }, + "additionalProperties": false + }, + "snapshotBackup": { + "type": "object", + "properties": { + "snapshotFrequency": { + "type": "number", + "default": 24, + "minimum": 1, + "exclusiveMinimum": true + } + }, + "additionalProperties": false + }, + "logBackup": { + "type": "object", + "properties": { + "sizeOfLogFiles": { + "type": "number", + "maximum": 5, + "exclusiveMaximum": true + }, + "logBackupFrequency": { + "type": "number", + "maximum": 4, + "exclusiveMaximum": true + }, + "logRetentionPeriod": { + "type": "number", + "maximum": 15, + "exclusiveMaximum": true + }, + "logFileLocation": { + "type": "string", + "maxLength": 300 + } + }, + "additionalProperties": false + } + }, + "additionalProperties": false + } + }, + "additionalProperties": false +} \ No newline at end of file diff --git a/openecomp-be/tools/install/database/schemaTemplates/questionnaire/nic.ftl b/openecomp-be/tools/install/database/schemaTemplates/questionnaire/nic.ftl new file mode 100644 index 0000000000..f5ea08b98a --- /dev/null +++ b/openecomp-be/tools/install/database/schemaTemplates/questionnaire/nic.ftl @@ -0,0 +1,120 @@ +{ + "$schema": "http://json-schema.org/draft-04/schema#", + "type": "object", + "properties": { + "protocols": { + "type": "object", + "properties": { + "protocols": { + "type": "array", + "items": { + "type": "string", + "enum": [ + "", + "TCP", + "UDP", + "SCTP", + "IPsec" + ], + "default": "" + }, + "minItems": 1 + }, + "protocolWithHighestTrafficProfile": { + "$ref": "#/properties/protocols/properties/protocols/items" + } + }, + "additionalProperties": false + }, + "ipConfiguration": { + "type": "object", + "properties": { + "ipv4Required": { + "type": "boolean", + "default": true + }, + "ipv6Required": { + "type": "boolean", + "default": false + } + }, + "additionalProperties": false + }, + "network": { + "type": "object", + "properties": { + "networkDescription": { + "type": "string", + "pattern": "[A-Za-z]+", + "maxLength": 300 + } + }, + "additionalProperties": false + }, + "sizing": { + "type": "object", + "definitions": { + "peakAndAvg": { + "type": "object", + "properties": { + "peak": { + "type": "number" + }, + "avg": { + "type": "number" + } + }, + "additionalProperties": false + }, + "packetsAndBytes": { + "type": "object", + "properties": { + "packets": { + "$ref": "#/properties/sizing/definitions/peakAndAvg" + }, + "bytes": { + "$ref": "#/properties/sizing/definitions/peakAndAvg" + } + }, + "additionalProperties": false + } + }, + "properties": { + "describeQualityOfService": { + "type": "string" + }, + "inflowTrafficPerSecond": { + "$ref": "#/properties/sizing/definitions/packetsAndBytes" + }, + "outflowTrafficPerSecond": { + "$ref": "#/properties/sizing/definitions/packetsAndBytes" + }, + "flowLength": { + "$ref": "#/properties/sizing/definitions/packetsAndBytes" + }, + "acceptableJitter": { + "type": "object", + "properties": { + "mean": { + "type": "number" + }, + "max": { + "type": "number" + }, + "variable": { + "type": "number" + } + }, + "additionalProperties": false + }, + "acceptablePacketLoss": { + "type": "number", + "minimum": 0, + "maximum": 100 + } + }, + "additionalProperties": false + } + }, + "additionalProperties": false +} \ No newline at end of file diff --git a/openecomp-be/tools/install/database/schemaTemplates/questionnaire/vsp.ftl b/openecomp-be/tools/install/database/schemaTemplates/questionnaire/vsp.ftl new file mode 100644 index 0000000000..6b1502c4a2 --- /dev/null +++ b/openecomp-be/tools/install/database/schemaTemplates/questionnaire/vsp.ftl @@ -0,0 +1,89 @@ +{ + "$schema": "http://json-schema.org/draft-04/schema#", + "type": "object", + "properties": { + "general": { + "type": "object", + "properties": { + "affinityData": { + "type": "string", + "enum": [ + "", + "Affinity", + "Anti Affinity", + "None" + ], + "default": "" + }, + "availability": { + "type": "object", + "properties": { + "useAvailabilityZonesForHighAvailability": { + "type": "boolean", + "default": false + } + }, + "additionalProperties": false + }, + "regionsData": { + "type": "object", + "properties": { + "multiRegion": { + "type": "boolean", + "default": false + }, + "regions": { + "type": "array", + "items": { + "type": "string", + "enum": [ + "", + "1", + "2", + "3", + "4", + "5", + "6", + "7", + "8", + "9" + ], + "default": "" + } + } + }, + "additionalProperties": false + }, + "storageDataReplication": { + "type": "object", + "properties": { + "storageReplicationAcrossRegion": { + "type": "boolean", + "default": false + }, + "storageReplicationSize": { + "type": "number", + "maximum": 100, + "exclusiveMaximum": true + }, + "storageReplicationFrequency": { + "type": "number", + "minimum": 5 + }, + "storageReplicationSource": { + "type": "string", + "maxLength": 300 + }, + "storageReplicationDestination": { + "type": "string", + "maxLength": 300 + } + }, + "additionalProperties": false + } + }, + "additionalProperties": false + } + }, + "additionalProperties": false +} \ No newline at end of file diff --git a/openecomp-be/tools/migration/1607_to_1610.py b/openecomp-be/tools/migration/1607_to_1610.py new file mode 100644 index 0000000000..2cec48b04d --- /dev/null +++ b/openecomp-be/tools/migration/1607_to_1610.py @@ -0,0 +1,281 @@ +#!/usr/bin/python +import os +import sys,json,datetime,time,types,httplib,re +import mimetypes + +DEFAULT_HOST = "127.0.0.1" +OPENECOMP_BE = "127.0.0.1" + +HOST = DEFAULT_HOST +DEFAULT_PORT = "8080" +DEFAULT_USERNAME = "cs0008" +DEFAULT_PASSWORD = "cs0008" + +ONBOARD_BASE_PATH = "/onboarding-api/v1.0" +VSP_LIST_PATH = "{0}/vendor-software-products".format(ONBOARD_BASE_PATH) +VSP_ACTIONS_PATH = "{0}/vendor-software-products/{{vspId}}/actions".format(ONBOARD_BASE_PATH) +VSP_UPLOAD_PATH = "{0}/vendor-software-products/{{vspId}}/upload".format(ONBOARD_BASE_PATH) +VSP_DOWNLOAD_PATH = "{0}/vendor-software-products/{{vspId}}/downloadHeat".format(ONBOARD_BASE_PATH) +VSP_GET_URL = "{0}/vendor-software-products/{{vspId}}".format(ONBOARD_BASE_PATH) + +def main(argv): + username=DEFAULT_USERNAME + password=DEFAULT_PASSWORD + host=DEFAULT_HOST + + if not argv: + print "Going to use default values" + else: + if argv[0].lower() == 'h' or argv[0].lower() == '-h': + printHelp() + return + + if argv[0] == '-ip': + host=argv[1] + else: + if argv[0].lower() == '-a' and '/' not in argv[1]: + print '\n>>> Error: Credentials required (username/password)\n' + printHelp() + return + + else: + creds = argv[1].split('/') + username = creds[0] + password = creds[1] # not used + + try: + cmdIp=argv[2] + host=argv[3] + except IndexError: + host=DEFAULT_HOST + print "Going to use user defined values" + Service.server(host) + + webHandler=WebHandler(host=host, port=DEFAULT_PORT) + response, headers = webHandler.rest(url=VSP_LIST_PATH, method='GET', data=None, attuid=username) + jResult = json.loads(response) + jSrvices = jResult["results"] + reportFileName = 'upgradereport.csv' #datetime.now() + reportFile = open(reportFileName, 'w') + reportFile.write(Service.header()) + + for jService in jSrvices: + serviceName = jService["name"] + vendorName = jService["vendorName"] + vspId = jService["id"] + status = jService["status"] + if status != "Locked": + lockingUser = "None" + else: + lockingUser = jService["lockingUser"] + + service = Service(serviceName=serviceName, vspId=vspId, vendorName=vendorName, lockingUser=lockingUser ) + print service + # Will try to GET the service + res = service.Get() + if res == 500: + serviceMigration(service, status, username) + else: + print "Service {0} was tested and does not need a migration".format(serviceName) + + reportFile.write(service.line()) + reportFile.close() + + +def serviceMigration(service, serviceStatus, username): + print "Service {0} was tested and it needs a migration".format(service.serviceName) + print "Service {0} - Migration start" + if serviceStatus == "Locked": + print "Service {0} is locked - forcing checkin".format(service.serviceName) + service.Checkin() + print "Doing new checkout" + service.Checkout(username) + + zipName = service.DownloadHeat() + if not zipName: + print "no heat found" + service.uploadStatus = "no heat found" + else: + uploadResponse = service.UploadHeat(zipName) + uploadResults = json.loads(uploadResponse) + if uploadResults['status'] == 'Success' and uploadResults['errors'].__len__() == 0: + service.uploadStatus = "Heat uploaded successfully" + else: + service.uploadStatus = "Heat uploaded with errors" + print "Doing new checkin" + service.Checkin() + + print "Service {0} - Migration end" + + +def printHelp(): + print("Upgrade script Help:") + print("==================================") + print("1607_to_1610 -h --> get help") + print("1607_to_1610 -a / [-ip {ip}]") + print("Example: 1607_to_1610 -a root/secret") + +class Service(object): + def __init__(self, serviceName, vspId ,vendorName, lockingUser): + self.serviceName = serviceName + self.vspId = vspId + self.vendorName = vendorName + self.lockingUser = lockingUser + self.webHandler = WebHandler(host=Service.serveraddress, port=DEFAULT_PORT) # Schema? + self.uploadStatus = "not started" + + def __repr__(self): + return 'Name: {0}, Id: {1}, Vendor: {2}, locked by: {3}, status {4}'.format(self.serviceName, self.vspId ,self.vendorName, self.lockingUser, self.uploadStatus) + @classmethod + def header(cls): + return 'Name,Id,Vendor,locked-by,status\n' + + @classmethod + def server(cls, address): + cls.serveraddress=address + + def line(self): + return '{0},{1},{2},{3},{4}\n'.format(self.serviceName, self.vspId ,self.vendorName, self.lockingUser, self.uploadStatus) + + def Checkout(self, attuid): + # /v1.0/vendor-software-products/{vspId}/actions + urlpath=VSP_ACTIONS_PATH.format(vspId=self.vspId) + response, headers = self.webHandler.rest( url=urlpath, method='PUT', data={"action": "Checkout"}, attuid=attuid) + self.lockingUser=attuid #we will later use this user to checkin + return response + + def Checkin(self): + # /v1.0/vendor-software-products/{vspId}/actions + urlpath = VSP_ACTIONS_PATH.format(vspId=self.vspId) + response, headers = self.webHandler.rest(url=urlpath, method='PUT', data={"action": "Checkin"}, attuid=self.lockingUser) + return response + + def Get(self): + # /v1.0/vendor-software-products/{vspId} + urlpath = VSP_GET_URL.format(vspId=self.vspId) + try: + response, headers = self.webHandler.rest(url=urlpath, method='GET', data=None, attuid=self.lockingUser) + except HttpError as e: + print e.message + response = e.status + return response + + def UploadHeat(self, zipName): + #/v1.0/vendor-software-products/{vspId}/upload + urlpath = VSP_UPLOAD_PATH.format(vspId=self.vspId) + try: + fields = [] + with open(zipName, 'rb') as fin: + buffer = fin.read() + fin.close() + files = [('upload', 'heatfile.zip', buffer)] + response = self.webHandler.post_multipart('HTTP', urlpath, fields, files, self.lockingUser) + + return response + finally: + print "done upload" + + def DownloadHeat(self): + urlpath=VSP_DOWNLOAD_PATH.format(vspId=self.vspId) + try: + response, headers = self.webHandler.rest(url=urlpath, method='Get', data=None, attuid=self.lockingUser, accept='application/octet-stream') + except HttpError as e: + if e.status == 404: + return "" + + for (key, value) in headers: + if key.lower() == "content-disposition": + file_name = value[value.index('=')+1:] + break + heatsDir= os.path.join(os.path.dirname(__file__), 'heats') + if not os.path.exists(heatsDir): + os.makedirs(heatsDir) + file_name = os.path.join(heatsDir, file_name) + with open(file_name, "wb") as fout: + fout.write(response) + fout.close() + + return file_name + + + +class WebHandler(object): + def __init__(self, host, port): + self.host = host + self.port = port + + def rest(self, url, method, data, attuid, accept='application/json', content_type='application/json'): + connection = httplib.HTTPConnection(host=self.host, port=self.port) + + try: + headers = {'Content-Type':content_type ,'Accept':accept} + headers['USER_ID'] = attuid + + connection.request(method=method, headers=headers, body=json.dumps(data), url=url) + response = connection.getresponse() + if response.status not in range(200, 300): + raise HttpError(status= response.status, message=response.reason) + + return response.read(), response.getheaders() + finally: + connection.close() + + def post_multipart(self, scheme, selector, fields, files, attuid): + """ + Post fields and files to an http host as multipart/form-data. + fields is a sequence of (name, value) elements for regular form fields. + files is a sequence of (name, filename, value) elements for data to be uploaded as files + Return the server's response page. + """ + content_type, body = self.encode_multipart_form_data(fields, files) + if scheme and scheme.lower() == "http": + h = httplib.HTTP(self.host, self.port) + else: + h = httplib.HTTPS(self.host, self.port) + h.putrequest('POST', selector) + h.putheader('content-type', content_type) + h.putheader('content-length', str(len(body))) + h.putheader('Accept', 'application/json') + h.putheader('USER_ID', attuid) + + h.endheaders() + h.send(body) + errcode, errmsg, headers = h.getreply() + print errcode, errmsg, headers + return h.file.read() + + def encode_multipart_form_data(self, fields, files): + LIMIT = '----------lImIt_of_THE_fIle_eW_$' + CRLF = '\r\n' + L = [] + for (key, value) in fields: + L.append('--' + LIMIT) + L.append('Content-Disposition: form-data; name="%s"' % key) + L.append('') + L.append(value) + for (key, filename, value) in files: + L.append('--' + LIMIT) + L.append('Content-Disposition: form-data; name="%s"; filename="%s"' % (key, filename)) + L.append('Content-Type: %s' % self.get_content_type(filename)) + L.append('') + L.append(value) + L.append('--' + LIMIT + '--') + L.append('') + body = CRLF.join(L) + content_type = 'multipart/form-data; boundary=%s' % LIMIT + return content_type, body + + def get_content_type(self, filename): + return mimetypes.guess_type(filename)[0] or 'application/octet-stream' + +class HttpError(Exception): + def __init__(self, status, message): + self.status = status + self.message=message + def __str__(self): + return repr(self.value, self.message) + +if __name__ == "__main__": + main(sys.argv[1:]) + + diff --git a/openecomp-be/tools/migration/README b/openecomp-be/tools/migration/README new file mode 100644 index 0000000000..7bca1f3f5e --- /dev/null +++ b/openecomp-be/tools/migration/README @@ -0,0 +1,88 @@ +Info - + Name: 1607 to 1610 ASDC VSP migration tool + Version: 4.0 + Date: 15 Sep, 2016 + +General - + This is a utility used for migration of VSP data from ASDC version 1607 to version 1610. + This utility will be executed post upgrade process to 1610. + This utility must run from the ASDC backend (BE) machine. + + From version 3.0 the tool can be run several times without changing a VSP version more then once, the first time. + Once the VSP is "fixed" it will not be migrated by this tool. + +Concept - + Once migrating ASDC from 1607 to 1610 changes were made in the VSP load/validation. + In order to support these changes and force a valid HEAT file upload, the migration process should be + run on the existing data. + Not doing so will result in VSPs that will not open for update action. + + The migration will run on VSPs that were upgraded from 1607 to 1610 and are not able to be retrieved. + +Pre ASDC upgrade requisite - + In order to achieve the best result from this tool users must check-in ALL VSPs. + +Limitations - + + * Will not work if user did not create a first version of the VSP, i.e. at least one time check-in action. + * Once run, user must checkout a VSP, go to General and re select a license model version. + + +Usage - + + Note: There are default values if the script is run without arguments. + The values are credentials: cs0008/cs0008, with host: 127.0.0.1 + 1607_to_1610 -h --> get help + 1607_to_1610 -a / [-ip {ip}] + Example: + using cassandra on localhost - 1607_to_1610 -a root/secret + using cassandra on remote host - 1607_to_1610 -a root/secert -ip 10.147.97.191 + + Result: + The migration result will be listed in a CSV file: upgradereport.csv + "None" is an indication that the VSP was not in a checkout status prior to the upgrade. + + Exmample for a valid output: + + Name: VSP-OK, Id: 9DB0E1563B22481D911ECD33989E1FDD, Vendor: OPENECOMP, locked by: None, status not started + Service VSP-OK was tested and does not need a migration + Name: VSP02-Checkout, Id: 8DF8D65535414AAAA23682E2532675E6, Vendor: OPENECOMP, locked by: cs0008, status not started + Server Error + Service VSP02-Checkout was tested and it needs a migration + Service VSP02 - Migration start + Service VSP02-Checkout is locked - forcing checkin + Doing new checkout + 200 OK Content-Type: application/json + Date: Thu, 08 Sep 2016 13:25:21 GMT + Server: Jetty(9.3.6.v20151106) + + done upload + Doing new checkin + Service VSP-EMPTY - Migration end + Name: VSP-EMPTY, Id: D26892D2839746E18075EF49C4586320, Vendor: OPENECOMP, locked by: None, status not started + Service VSP-EMPTY was tested and does not need a migration + Name: VSP01, Id: 98F5DDFD4F684086801E86A88A0D77AB, Vendor: OPENECOMP, locked by: None, status not started + Server Error + Service VSP01 was tested and it needs a migration + Service VSP-EMPTY - Migration start + Doing new checkout + 200 OK Content-Type: application/json + Date: Thu, 08 Sep 2016 13:25:22 GMT + Server: Jetty(9.3.6.v20151106) + + done upload + Doing new checkin + Service {0} - Migration end + + Example for a case with no migration needed: + + Name: VSP-OK, Id: 9DB0E1563B22481D911ECD33989E1FDD, Vendor: OPENECOMP, locked by: None, status not started + Service VSP-OK was tested and does not need a migration + Name: VSP02-Checkout, Id: 8DF8D65535414AAAA23682E2532675E6, Vendor: OPENECOMP, locked by: None, status not started + Service VSP02-Checkout was tested and does not need a migration + Name: VSP-EMPTY, Id: D26892D2839746E18075EF49C4586320, Vendor: OPENECOMP, locked by: None, status not started + Service VSP-EMPTY was tested and does not need a migration + Name: VSP01, Id: 98F5DDFD4F684086801E86A88A0D77AB, Vendor: OPENECOMP, locked by: None, status not started + Service VSP01 was tested and does not need a migration + + diff --git a/openecomp-be/tools/scripts/generate-manifest.py b/openecomp-be/tools/scripts/generate-manifest.py new file mode 100644 index 0000000000..87968e0f89 --- /dev/null +++ b/openecomp-be/tools/scripts/generate-manifest.py @@ -0,0 +1,435 @@ +#!/usr/bin/python + +############################################################################## +### +### generate-manifest.py +### +### A Vendor utility to generate a valid heat zip manifest file for the AT&T onboarding. +### +### Usage: +### +### generate-manifest.py [-f|--folder] vendor-heat-directory [-n|--name] manifest-name [-d|--description] manifet-description +### +### For example: +### +### ./generate-manifest.py --folder ./vota --name vOTA --description "HOT template to create vOTA server" +### +### Help: +### The script is doing the following: +### 1) Split the files into different types +### a. .env files +### b. Network files (anything containing the string network) +### c. Volume files (anything containing the string volume) +### d. Top level Heat files +### e. Other types +### 2) Match env files to heat files – looking for same name ignoring suffix and extension +### 3) Match Network childs +### a. Look for Top level heats which name is a substring of the name of the Network heat name. +### 4) Match Volume childs +### a. Look for Top level heats which name is a substring of the name of the Volume heat name. +### 5) Generate the JSON file from the above +### +### +### Author: Avi Ziv +### Version 1.4 for OPENECOMP 1.0 +### Date: 13 July 2016 (c) OPENECOMP +### +############################################################################## + +# import os,sys,getopt,json,re +import os, sys, getopt, re +from collections import OrderedDict +from json import JSONEncoder +import json + +VERSION = "1.4" +ENV_EXT = ".env" +SHELL_EXT = ".sh" +YAML_EXT = [".yaml", ".yml"] +# VERSION_DELIMITER_PATTERN='_v\d{*}.\d{*}' +# VERSION_DELIMITER_PATTERN='_v*.*' +#v1.0 +VERSION_DELIMITER_PATTERN = '_v\d+.\d+' +#07_12_2016 +VERSION_DELIMITER_PATTERN2 = '_\d+-\d+-\d+' + +# types +HEAT = "HEAT" +HEAT_BASE = "HEAT_BASE" +HEAT_NET = "HEAT_NET" +HEAT_VOL = "HEAT_VOL" +HEAT_ENV = "HEAT_ENV" +SHELL = "SHELL" +OTHER = "OTHER" + +globalVolumeVal = "VOLUME" +globalNetworkVal = "NETWORK" +globalBaseVal = "BASE" + + +def version(): + return VERSION + + +def usage(): + print ('usage: ' + sys.argv[0] + ' [-f|--folder] vendor-heat-directory [-n|--name] manifest-name [-d|--description] manifet-description' ) + + +def header(): + print ("\nASDC Vendor manifest file generator, version " + version() + "\n") + + +def getEnvVariables(value, defaultValue): + try: + eVal = os.environ[value] + return eVal + except KeyError: + print ("Missing ${" + value + "} envirunment variable. Using default value: " + defaultValue) + return defaultValue + + +def getF(listFiles): + print ("Analyzing files ...") + foundABase = False + files = listFiles + jsons = {} + lOfEnvs = {} + lOfVolumes = {} + lOfNetworks = {} + lOfHeats = {} + lOfShels = {} + lOfArtifacts = {} + + for f in files: + fullFilename = f[1] + fObj = ManifestFileInfo(fullFilename) + if fObj.isEnv(): + lOfEnvs[fObj.file_name] = fObj + elif fObj.isShell(): + lOfShels[fObj.file_name] = fObj + elif fObj.isVolume(): + lOfVolumes[fObj.file_name] = fObj + elif fObj.isNetwork(): + lOfNetworks[fObj.file_name] = fObj + elif (fObj.isYaml() and not fObj.isBase()): + lOfHeats[fObj.file_name] = fObj + elif fObj.isArtifact(): + lOfArtifacts[fObj.file_name] = fObj + elif (fObj.isBase() and fObj.isYaml()): + foundABase = True + lOfHeats[fObj.file_name] = fObj + + jsons['heats'] = lOfHeats + jsons['envs'] = lOfEnvs + jsons['shells'] = lOfShels + jsons['volumes'] = lOfVolumes + jsons['networks'] = lOfNetworks + jsons['artifacts'] = lOfArtifacts + + if not foundABase: + print (">>> Warning: No Base was found") + return jsons + +def loadFilesToList(folder): + print ("Analyzing files in folder: << " + folder + " >>") + files = os.listdir(folder) + listOfFiles = [] + for f in files: + if os.path.isdir(os.path.join(folder, f)): + ConsoleLogger.warning("Sub folders are ignored by this script, you may want to remove it before archiving") + continue + + filename, file_extension = os.path.splitext(f) + if filename == 'MANIFEST': + ConsoleLogger.warning("Your folder already contains a manifest file that will be overridden") + continue + listOfFiles.append([filename, f]) + return listOfFiles + + +def make(files): + flist = [] + dEnvs = {} + dEnvs = files['envs'] + dHeats = files['heats'] + dNetworks = files['networks'] + dVolumes = files['volumes'] + dArtifacts = files['artifacts'] + dShells = files['shells'] + + env_items = dEnvs.items() + for fileItem in env_items: + env_name = fileItem[1].file_name + env_base = fileItem[1].base_file_name + if env_name in dHeats: + dHeats[env_name].add(fileItem[1]) + continue + + if env_name in dNetworks.items(): + dNetworks[env_name].add(fileItem[1]) + continue + + if env_name in dVolumes.items(): + dVolumes[env_name[0]].add(env_name[1]) + continue + + for fName in dHeats: + heat_base = dHeats[fName].base_file_name + if env_base in heat_base: + dHeats[fName].add(dEnvs[env_name]) + break + else: + for fName in dNetworks: + net_base = dNetworks[fName].base_file_name + if env_base in net_base: + dNetworks[fName].add(dEnvs[env_name]) + break + else: + for fName in dVolumes: + vol_base = dVolumes[fName].base_file_name + if env_base in vol_base: + dVolumes[fName].add(dEnvs[env_name]) + break + + else: + flist.append(dEnvs[env_name]) + + for fName in dVolumes: + vol_base = dVolumes[fName].base_file_name + for hfName in dHeats: + heat_base = dHeats[hfName].base_file_name + if heat_base in vol_base: + dHeats[hfName].add(dVolumes[fName]) + break + else: + flist.append(dVolumes[fName]) + + for fName in dNetworks: + net_base = dNetworks[fName].base_file_name + for hfName in dHeats: + heat_base = dHeats[hfName].base_file_name + if heat_base in net_base: + dHeats[hfName].add(dNetworks[fName]) + break + else: + flist.append(dNetworks[fName]) + + for fName in dHeats: + flist.append(dHeats[fName]) + for fName in dShells: + flist.append(dShells[fName]) + for fName in dArtifacts: + flist.append(dArtifacts[fName]) + + print ("\n------------------------------------------------------------\n") + return flist + + +def generate(folder, name, description): + print ("Checking envirunment variables ...") + global globalVolumeVal + globalVolumeVal = getEnvVariables("VOLUME", globalVolumeVal) + + global globalNetworkVal + globalNetworkVal = getEnvVariables("NETWORK", globalNetworkVal) + + global globalBaseVal + globalBaseVal = getEnvVariables("BASE", globalBaseVal) + + YamlTabCleaner(folder).cleanYamlTabs() + + print ("Generating manifest file ...") + jsons = getF(loadFilesToList(folder)) + + lFiles = make(jsons) + manifest = Manifest(name, description, '1.0', lFiles) + output_json = json.dumps(manifest, default=jdefault, indent=4, sort_keys=False) + + f = open(os.path.join(folder, 'MANIFEST.json'), 'w') + f.write(output_json) + print("MANIFEST file created") + + +################ + +def jdefault(obj): + if hasattr(obj, '__json__'): + return obj.__json__() + else: + return obj.__dict__ + + +class ManifestFileInfo(object): + def __init__(self, filename): + self.name = filename + self.base = 'false' + self.data = [] + self.file_name, self.file_extension = os.path.splitext(filename) + self.base_file_name = re.sub(VERSION_DELIMITER_PATTERN, '', self.file_name) + self.base_file_name = re.sub(VERSION_DELIMITER_PATTERN2, '', self.base_file_name) + + if self.isEnv(): + self.heat_type = Types.ENV + elif self.isShell(): + self.heat_type = Types.SHELL + elif self.isVolume(): + self.heat_type = Types.VOL + elif self.isNetwork(): + self.heat_type = Types.NET + elif self.isYaml() and not self.isBase(): + self.heat_type = Types.HEAT + elif self.isArtifact(): + self.heat_type = Types.OTHER + elif (self.isBase() and self.isYaml()): + self.heat_type = Types.HEAT + self.base = 'true' + + def set(self, data): + self.data = data + + def add(self, item): + self.data.append(item) + + def isYaml(self): + return any(val in self.file_extension.lower() for val in YAML_EXT) + + def isEnv(self): + return self.file_extension.lower() == ENV_EXT.lower() + + def isShell(self): + return self.file_extension.lower() == SHELL_EXT.lower() + + def isVolume(self): + res = globalVolumeVal.lower() in self.file_name.lower() + return res + + def isNetwork(self): + res = globalNetworkVal.lower() in self.file_name.lower() + return res + + def isBase(self): + res = globalBaseVal.lower() in self.file_name.lower() + return res + + def isArtifact(self): + return (not self.isBase() and not self.isVolume() and not self.isNetwork() and not self.isEnv()) + + def isHEAT(self): + return ((self.heat_type == Types.HEAT) | (self.heat_type == Types.BASE) | (self.heat_type == Types.NET) | ( + self.heat_type == Types.VOL)) + + def __json__(self): + dict = OrderedDict( + [('file', self.name), ('type', self.heat_type)]) + if self.isHEAT(): + dict['isBase'] = self.base + if self.data != []: + dict['data'] = self.data + + return dict + + +class Manifest(object): + def __init__(self, name, description, version, data): + self.name = name + self.description = description + self.version = version + self.data = data + + def add(self, data): + self.data.append(data) + + def __json__(self): + return OrderedDict([('name', self.name), ('description', self.description), ('data', self.data)]) + + +class YamlTabCleaner(object): + def __init__(self, folder): + self.folder = folder + + def replaceTabs(self, sourceFile, targetFile): + with open(sourceFile, "rt") as fin: + if '\t' in fin.read(): + print("\'tab\' character was found in the file: " + sourceFile + "\na clean version of the file can be found under \'clean\' folder") + target = os.path.dirname(targetFile) + if not os.path.exists(target): + os.makedirs(target) + fin.seek(0) + with open(targetFile, "wt") as fout: + for line in fin: + fout.write(line.replace('\t', ' ')) + + def cleanYamlTabs(self): + included_extenstions = ['yml', 'yaml'] + files = [fn for fn in os.listdir(self.folder) + if any(fn.endswith(ext) for ext in included_extenstions)] + target = os.path.join(self.folder, "clean") + for file in files: + self.replaceTabs(os.path.join(self.folder, file), os.path.join(target, file)) + +class ConsoleLogger(object): + @classmethod + def error(cls, message): + print(">>> Error: " + message) + + @classmethod + def warning(cls, message): + print(">>> Warning: " + message) + + + @classmethod + def info(cls, message): + print(">>> Info: " + message) + + +def enum(**named_values): + return type('Enum', (), named_values) + + +################ + +def main(argv): + action = '' + folderName = '.' + name = '' + description = '' + version = '' + + try: + opts, args = getopt.getopt(argv, "h:f:n:d", ["folder=", "name=", "description=", ]) + except getopt.GetoptError as err: + # print help information and exit: + print ('>>>>' + str(err)) + usage() + sys.exit(2) + for opt, arg in opts: + if opt == '-h': + usage() + sys.exit() + elif opt in ('-f', '--folder'): + action = 'generate' + if not arg: + print ("Error: missing heat files directory") + usage() + sys.exit(2) + else: + folderName = arg + elif opt in ('-n', '--name'): + name = arg + elif opt in ('-d', '--description'): + description = arg + else: + usage() + + if action == 'generate': + generate(folderName, name, description) + sys.exit() + else: + usage() + + +if __name__ == "__main__": + header() + Types = enum(HEAT='HEAT', BASE='HEAT_BASE', NET='HEAT_NET', VOL='HEAT_VOL', ENV='HEAT_ENV', SHELL='SHELL', + OTHER='OTHER') + main(sys.argv[1:]) diff --git a/openecomp-be/tools/swagger-ui/WEB-INF/jetty-web.xml b/openecomp-be/tools/swagger-ui/WEB-INF/jetty-web.xml new file mode 100644 index 0000000000..11f2d9ec9e --- /dev/null +++ b/openecomp-be/tools/swagger-ui/WEB-INF/jetty-web.xml @@ -0,0 +1,8 @@ + + + + + /api-docs + diff --git a/openecomp-be/tools/swagger-ui/api-docs/api.html b/openecomp-be/tools/swagger-ui/api-docs/api.html new file mode 100644 index 0000000000..35bf7db136 --- /dev/null +++ b/openecomp-be/tools/swagger-ui/api-docs/api.html @@ -0,0 +1,13140 @@ + + +API Document + + +

+#Rest API + + +## HTTP:///onboarding-api + + +Rest API Documentation + + + +**Version** v1.0, build #${buildNumber} + + + + + + + + + + + + +# APIs + + +## /v1.0/application-configuration + + + + + + +### POST + + +<a id="insertToTable">Insert JSON schema into application config table</a> + + + + + + + + + +#### Request + + +**Content-Type: ** multipart/form-data + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>namespace</th> + <td>query</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>key</th> + <td>query</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + <a href="#/definitions/InputStream">InputStream</a> + </td> + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + + + + +## /v1.0/application-configuration/{namespace} + + +### GET + +<a id="getListOfConfigurationByNamespaceFromTable">Get List of keys and values by namespace</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>namespace</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + + + + + + + +## /v1.0/application-configuration/{namespace}/{key} + + +### GET + +<a id="getFromTable">Get JSON schema by namespace and key</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>namespace</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>key</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| 200 | successful operation | <a href="#/definitions/ConfigurationDataDto">ConfigurationDataDto</a>| + + + + + + + + + + + + + + + + + +## /v1.0/validation/{type}/validate + + + + + + +### POST + + +<a id="validateFile">Validate a package</a> + + + + + + + + + +#### Request + + +**Content-Type: ** multipart/form-data + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>type</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + <a href="#/definitions/InputStream">InputStream</a> + </td> + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + + + + +## /v1.0/vendor-license-models + + +### GET + +<a id="listLicenseModels">List vendor license models</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>versionFilter</th> + <td>query</td> + <td>no</td> + <td>Currently supported value: &#x27;Final&#x27; - only vendor License models with final versions will be return - with their latest final version</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| 200 | successful operation | Array[<a href="#/definitions/VendorLicenseModelEntity">VendorLicenseModelEntity</a>]| + + + + + + +### POST + + +<a id="createLicenseModel">Create vendor license model</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + <a href="#/definitions/VendorLicenseModelRequest">VendorLicenseModelRequest</a> + </td> + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + + + + +## /v1.0/vendor-license-models/{vlmId} + + +### GET + +<a id="getLicenseModel">Get vendor license model</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vlmId</th> + <td>path</td> + <td>yes</td> + <td>Vendor license model Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>version</th> + <td>query</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| 200 | successful operation | <a href="#/definitions/VendorLicenseModelEntity">VendorLicenseModelEntity</a>| + + + + +### PUT + +<a id="updateLicenseModel">Update vendor license model</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + <a href="#/definitions/VendorLicenseModelRequest">VendorLicenseModelRequest</a> + </td> + +</tr> + +<tr> + <th>vlmId</th> + <td>path</td> + <td>yes</td> + <td>Vendor license model Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + +### DELETE + +<a id="deleteLicenseModel">Delete vendor license model</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vlmId</th> + <td>path</td> + <td>yes</td> + <td>Vendor license model Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + +## /v1.0/vendor-license-models/{vlmId}/actions + + + + +### PUT + +<a id="actOnLicenseModel">Update vendor license model</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + <a href="#/definitions/VendorLicenseModelActionRequestDto">VendorLicenseModelActionRequestDto</a> + </td> + +</tr> + +<tr> + <th>vlmId</th> + <td>path</td> + <td>yes</td> + <td>Vendor license model Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + + + + + +## /v1.0/vendor-license-models/{vlmId}/entitlement-pools + + +### GET + +<a id="listEntitlementPools">List vendor entitlement pools</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vlmId</th> + <td>path</td> + <td>yes</td> + <td>Vendor license model Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>version</th> + <td>query</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| 200 | successful operation | Array[<a href="#/definitions/EntitlementPoolEntity">EntitlementPoolEntity</a>]| + + + + + + +### POST + + +<a id="createEntitlementPool">Create vendor entitlement pool</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + <a href="#/definitions/EntitlementPoolRequest">EntitlementPoolRequest</a> + </td> + +</tr> + +<tr> + <th>vlmId</th> + <td>path</td> + <td>yes</td> + <td>Vendor license model Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + + + + +## /v1.0/vendor-license-models/{vlmId}/entitlement-pools/{entitlementPoolId} + + +### GET + +<a id="getEntitlementPool">Get vendor entitlement pool</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vlmId</th> + <td>path</td> + <td>yes</td> + <td>Vendor license model Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>version</th> + <td>query</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>entitlementPoolId</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| 200 | successful operation | <a href="#/definitions/EntitlementPoolEntity">EntitlementPoolEntity</a>| + + + + +### PUT + +<a id="updateEntitlementPool">Update vendor entitlement pool</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + <a href="#/definitions/EntitlementPoolRequest">EntitlementPoolRequest</a> + </td> + +</tr> + +<tr> + <th>vlmId</th> + <td>path</td> + <td>yes</td> + <td>Vendor license model Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>entitlementPoolId</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + +### DELETE + +<a id="deleteEntitlementPool">Delete vendor entitlement pool</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vlmId</th> + <td>path</td> + <td>yes</td> + <td>Vendor license model Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>entitlementPoolId</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + +## /v1.0/vendor-license-models/{vlmId}/feature-groups + + +### GET + +<a id="listFeatureGroups">List vendor feature groups</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vlmId</th> + <td>path</td> + <td>yes</td> + <td>Vendor license model Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>version</th> + <td>query</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| 200 | successful operation | Array[<a href="#/definitions/FeatureGroupEntity">FeatureGroupEntity</a>]| + + + + + + +### POST + + +<a id="createFeatureGroup">Create vendor feature group</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + <a href="#/definitions/FeatureGroupRequest">FeatureGroupRequest</a> + </td> + +</tr> + +<tr> + <th>vlmId</th> + <td>path</td> + <td>yes</td> + <td>Vendor license model Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + + + + +## /v1.0/vendor-license-models/{vlmId}/feature-groups/{featureGroupId} + + +### GET + +<a id="getFeatureGroup">Get vendor feature group</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vlmId</th> + <td>path</td> + <td>yes</td> + <td>Vendor license model Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>version</th> + <td>query</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>featureGroupId</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| 200 | successful operation | <a href="#/definitions/FeatureGroupModel">FeatureGroupModel</a>| + + + + +### PUT + +<a id="updateFeatureGroup">Update vendor feature group</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + <a href="#/definitions/FeatureGroupUpdateRequest">FeatureGroupUpdateRequest</a> + </td> + +</tr> + +<tr> + <th>vlmId</th> + <td>path</td> + <td>yes</td> + <td>Vendor license model Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>featureGroupId</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + +### DELETE + +<a id="deleteFeatureGroup">Delete vendor feature group</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vlmId</th> + <td>path</td> + <td>yes</td> + <td>Vendor license model Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>featureGroupId</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + +## /v1.0/vendor-license-models/{vlmId}/license-agreements + + +### GET + +<a id="listLicenseAgreements">List vendor license agreements</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vlmId</th> + <td>path</td> + <td>yes</td> + <td>Vendor license model Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>version</th> + <td>query</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| 200 | successful operation | Array[<a href="#/definitions/LicenseAgreementEntity">LicenseAgreementEntity</a>]| + + + + + + +### POST + + +<a id="createLicenseAgreement">Create vendor license agreement</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + <a href="#/definitions/LicenseAgreementRequest">LicenseAgreementRequest</a> + </td> + +</tr> + +<tr> + <th>vlmId</th> + <td>path</td> + <td>yes</td> + <td>Vendor license model Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + + + + +## /v1.0/vendor-license-models/{vlmId}/license-agreements/{licenseAgreementId} + + +### GET + +<a id="getLicenseAgreement">Get vendor license agreement</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vlmId</th> + <td>path</td> + <td>yes</td> + <td>Vendor license model Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>version</th> + <td>query</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>licenseAgreementId</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| 200 | successful operation | <a href="#/definitions/LicenseAgreementModel">LicenseAgreementModel</a>| + + + + +### PUT + +<a id="updateLicenseAgreement">Update vendor license agreement</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + <a href="#/definitions/LicenseAgreementUpdateRequest">LicenseAgreementUpdateRequest</a> + </td> + +</tr> + +<tr> + <th>vlmId</th> + <td>path</td> + <td>yes</td> + <td>Vendor license model Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>licenseAgreementId</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + +### DELETE + +<a id="deleteLicenseAgreement">Delete vendor license agreement</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vlmId</th> + <td>path</td> + <td>yes</td> + <td>Vendor license model Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>licenseAgreementId</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + +## /v1.0/vendor-license-models/{vlmId}/license-key-groups + + +### GET + +<a id="listLicenseKeyGroups">List vendor license key groups</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vlmId</th> + <td>path</td> + <td>yes</td> + <td>Vendor license model Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>version</th> + <td>query</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| 200 | successful operation | Array[<a href="#/definitions/LicenseKeyGroupEntityDto">LicenseKeyGroupEntityDto</a>]| + + + + + + +### POST + + +<a id="createLicenseKeyGroup">Create vendor license key group</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + <a href="#/definitions/LicenseKeyGroupRequestDto">LicenseKeyGroupRequestDto</a> + </td> + +</tr> + +<tr> + <th>vlmId</th> + <td>path</td> + <td>yes</td> + <td>Vendor license model Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + + + + +## /v1.0/vendor-license-models/{vlmId}/license-key-groups/{licenseKeyGroupId} + + +### GET + +<a id="getLicenseKeyGroup">Get vendor license key group</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vlmId</th> + <td>path</td> + <td>yes</td> + <td>Vendor license model Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>version</th> + <td>query</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>licenseKeyGroupId</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| 200 | successful operation | <a href="#/definitions/LicenseKeyGroupEntityDto">LicenseKeyGroupEntityDto</a>| + + + + +### PUT + +<a id="updateLicenseKeyGroup">Update vendor license key group</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + <a href="#/definitions/LicenseKeyGroupRequestDto">LicenseKeyGroupRequestDto</a> + </td> + +</tr> + +<tr> + <th>vlmId</th> + <td>path</td> + <td>yes</td> + <td>Vendor license model Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>licenseKeyGroupId</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + +### DELETE + +<a id="deleteLicenseKeyGroup">Delete vendor license key group</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vlmId</th> + <td>path</td> + <td>yes</td> + <td>Vendor license model Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>licenseKeyGroupId</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + +## /v1.0/vendor-software-products + + +### GET + +<a id="getVspList">Get list of vendor software products and their description</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>versionFilter</th> + <td>query</td> + <td>no</td> + <td>Currently supported values: &#x27;Final&#x27; - only vendor software products with final version will be return - with their latest final version</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + +### POST + + +<a id="createNewVsp">Create a new vendor software product</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + <a href="#/definitions/VspDescriptionDto">VspDescriptionDto</a> + </td> + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| 200 | successful operation | <a href="#/definitions/VspCreationDto">VspCreationDto</a>| + + + + + + + + + + + + + + +## /v1.0/vendor-software-products/packages + + +### GET + +<a id="listPackages">Get list of translated CSAR files details</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>category</th> + <td>query</td> + <td>no</td> + <td>Category</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>subCategory</th> + <td>query</td> + <td>no</td> + <td>Sub-category</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| 200 | successful operation | Array[<a href="#/definitions/PackageInfoDto">PackageInfoDto</a>]| + + + + + + + + + + + + + + + + + +## /v1.0/vendor-software-products/packages/{vspId} + + +### GET + +<a id="getTranslatedFile">Get translated CSAR file</a> + +Exports translated file to a zip file + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>version</th> + <td>query</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/octet-stream + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| 200 | successful operation | <a href="#/definitions/File">File</a>| + + + + + + + + + + + + + + + + + +## /v1.0/vendor-software-products/{vspId} + + +### GET + +<a id="getVspDetails">Get details of a vendor software product</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>version</th> + <td>query</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + +### PUT + +<a id="updateVsp">Update an existing vendor software product</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + <a href="#/definitions/VspDescriptionDto">VspDescriptionDto</a> + </td> + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + +### DELETE + +<a id="deleteVsp">Deletes vendor software product by given id</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + +## /v1.0/vendor-software-products/{vspId}/actions + + + + +### PUT + +<a id="actOnVendorSoftwareProduct">Actions on a vendor software product</a> + +Performs one of the following actions on a vendor software product: |Checkout: Locks it for edits by other users. Only the locking user sees the edited version.|Undo_Checkout: Unlocks it and deletes the edits that were done.|Checkin: Unlocks it and activates the edited version to all users.| Submit: Finalize its active version.|Create_Package: Creates a CSAR zip file.| + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + <a href="#/definitions/VersionSoftwareProductActionRequestDto">VersionSoftwareProductActionRequestDto</a> + </td> + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + + + + + +## /v1.0/vendor-software-products/{vspId}/components + + +### GET + +<a id="list">List vendor software product components</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>version</th> + <td>query</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| 200 | successful operation | Array[<a href="#/definitions/ComponentDto">ComponentDto</a>]| + + + + + + +### POST + + +<a id="create">Create a vendor software product component</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + <a href="#/definitions/ComponentRequestDto">ComponentRequestDto</a> + </td> + +</tr> + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + +### DELETE + +<a id="deleteList">Delete vendor software product components</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + +## /v1.0/vendor-software-products/{vspId}/components/{componentId} + + +### GET + +<a id="get">Get vendor software product component</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>componentId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product component Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>version</th> + <td>query</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| 200 | successful operation | <a href="#/definitions/ComponentData">ComponentData</a>| + + + + +### PUT + +<a id="update">Update vendor software product component</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + <a href="#/definitions/ComponentRequestDto">ComponentRequestDto</a> + </td> + +</tr> + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>componentId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product component Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + +### DELETE + +<a id="delete">Delete vendor software product component</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>componentId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product component Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + +## /v1.0/vendor-software-products/{vspId}/components/{componentId}/monitors/snmp + + +### GET + +<a id="list">Get the filenames of uploaded MIB definitions</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>componentId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product component Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| 200 | successful operation | <a href="#/definitions/MibUploadStatusDto">MibUploadStatusDto</a>| + + + + + + + + +### DELETE + +<a id="deletePollMibFile">Delete vendor software product MIB Poll Definitions file</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>componentId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product component Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + +## /v1.0/vendor-software-products/{vspId}/components/{componentId}/monitors/snmp-trap + + + + + + + + +### DELETE + +<a id="deleteTrapMibFile">Delete vendor software product MIB Trap Definitions file</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>componentId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product component Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + +## /v1.0/vendor-software-products/{vspId}/components/{componentId}/monitors/snmp-trap/upload + + + + + + +### POST + + +<a id="uploadTrapMibFile">Upload vendor software product MIB Trap Definitions file</a> + + + + + + + + + +#### Request + + +**Content-Type: ** multipart/form-data + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + <a href="#/definitions/Attachment">Attachment</a> + </td> + +</tr> + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>componentId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product component Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + + + + +## /v1.0/vendor-software-products/{vspId}/components/{componentId}/monitors/snmp/upload + + + + + + +### POST + + +<a id="uploadPollMibFile">Upload vendor software product MIB Poll Definitions file</a> + + + + + + + + + +#### Request + + +**Content-Type: ** multipart/form-data + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + <a href="#/definitions/Attachment">Attachment</a> + </td> + +</tr> + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>componentId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product component Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + + + + +## /v1.0/vendor-software-products/{vspId}/components/{componentId}/nics + + +### GET + +<a id="list">List vendor software product component NICs</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>componentId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product component Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>version</th> + <td>query</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| 200 | successful operation | Array[<a href="#/definitions/NicDto">NicDto</a>]| + + + + + + +### POST + + +<a id="create">Create a vendor software product NIC</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + <a href="#/definitions/NicRequestDto">NicRequestDto</a> + </td> + +</tr> + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>componentId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product component Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + + + + +## /v1.0/vendor-software-products/{vspId}/components/{componentId}/nics/{nicId} + + +### GET + +<a id="get">Get vendor software product NIC</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>componentId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product component Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>nicId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product NIC Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>version</th> + <td>query</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| 200 | successful operation | <a href="#/definitions/NicDto">NicDto</a>| + + + + +### PUT + +<a id="update">Update vendor software product NIC</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + <a href="#/definitions/NicRequestDto">NicRequestDto</a> + </td> + +</tr> + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>componentId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product component Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>nicId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product NIC Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + +### DELETE + +<a id="delete">Delete vendor software product NIC</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>componentId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product component Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>nicId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product NIC Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + +## /v1.0/vendor-software-products/{vspId}/components/{componentId}/nics/{nicId}/questionnaire + + +### GET + +<a id="getQuestionnaire">Get vendor software product component NIC questionnaire</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>componentId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product component Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>nicId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product NIC Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>version</th> + <td>query</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| 200 | successful operation | <a href="#/definitions/QuestionnaireResponseDto">QuestionnaireResponseDto</a>| + + + + +### PUT + +<a id="updateQuestionnaire">Update vendor software product component NIC questionnaire</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + + </td> + +</tr> + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>componentId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product component Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>nicId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product NIC Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + + + + + +## /v1.0/vendor-software-products/{vspId}/components/{componentId}/processes + + +### GET + +<a id="list">List vendor software product component processes</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>componentId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product component Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>version</th> + <td>query</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| 200 | successful operation | Array[<a href="#/definitions/ProcessEntityDto">ProcessEntityDto</a>]| + + + + + + +### POST + + +<a id="create">Create a vendor software product process</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + <a href="#/definitions/ProcessRequestDto">ProcessRequestDto</a> + </td> + +</tr> + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>componentId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product component Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + +### DELETE + +<a id="deleteList">Delete vendor software product processes</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>componentId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product component Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + +## /v1.0/vendor-software-products/{vspId}/components/{componentId}/processes/{processId} + + +### GET + +<a id="get">Get vendor software product process</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>componentId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product component Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>processId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product process Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>version</th> + <td>query</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| 200 | successful operation | <a href="#/definitions/ProcessEntityDto">ProcessEntityDto</a>| + + + + +### PUT + +<a id="update">Update vendor software product process</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + <a href="#/definitions/ProcessRequestDto">ProcessRequestDto</a> + </td> + +</tr> + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>componentId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product component Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>processId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product process Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + +### DELETE + +<a id="delete">Delete vendor software product process</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>componentId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product component Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>processId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product process Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + +## /v1.0/vendor-software-products/{vspId}/components/{componentId}/processes/{processId}/upload + + +### GET + +<a id="getUploadedFile">Get vendor software product process uploaded file</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>componentId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product component Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>processId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product process Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>version</th> + <td>query</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/octet-stream + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + +### POST + + +<a id="uploadFile">Update vendor software product process upload</a> + + + + + + + + + +#### Request + + +**Content-Type: ** multipart/form-data + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + <a href="#/definitions/Attachment">Attachment</a> + </td> + +</tr> + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>componentId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product component Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>processId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product process Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + +### DELETE + +<a id="deleteUploadedFile">Delete vendor software product process uploaded file</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>componentId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product component Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>processId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product process Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + +## /v1.0/vendor-software-products/{vspId}/components/{componentId}/questionnaire + + +### GET + +<a id="getQuestionnaire">Get vendor software product component questionnaire</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>componentId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product component Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>version</th> + <td>query</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| 200 | successful operation | <a href="#/definitions/QuestionnaireResponseDto">QuestionnaireResponseDto</a>| + + + + +### PUT + +<a id="updateQuestionnaire">Update vendor software product component questionnaire</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + + </td> + +</tr> + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>componentId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product component Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + + + + + +## /v1.0/vendor-software-products/{vspId}/downloadHeat + + +### GET + +<a id="getLatestHeatPackage">Get uploaded HEAT file</a> + +Downloads the latest HEAT package + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/octet-stream + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| 200 | successful operation | <a href="#/definitions/File">File</a>| + + + + + + + + + + + + + + + + + +## /v1.0/vendor-software-products/{vspId}/networks + + +### GET + +<a id="list">List vendor software product networks</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>version</th> + <td>query</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| 200 | successful operation | Array[<a href="#/definitions/NetworkDto">NetworkDto</a>]| + + + + + + +### POST + + +<a id="create">Create a vendor software product network</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + <a href="#/definitions/NetworkRequestDto">NetworkRequestDto</a> + </td> + +</tr> + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + + + + +## /v1.0/vendor-software-products/{vspId}/networks/{networkId} + + +### GET + +<a id="get">Get vendor software product network</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>networkId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product network Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>version</th> + <td>query</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| 200 | successful operation | <a href="#/definitions/NetworkDto">NetworkDto</a>| + + + + +### PUT + +<a id="update">Update vendor software product network</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + <a href="#/definitions/NetworkRequestDto">NetworkRequestDto</a> + </td> + +</tr> + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>networkId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product network Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + +### DELETE + +<a id="delete">Delete vendor software product network</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>networkId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product network Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + +## /v1.0/vendor-software-products/{vspId}/processes + + +### GET + +<a id="list">List vendor software product processes</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>version</th> + <td>query</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| 200 | successful operation | Array[<a href="#/definitions/ProcessEntityDto">ProcessEntityDto</a>]| + + + + + + +### POST + + +<a id="create">Create a vendor software product process</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + <a href="#/definitions/ProcessRequestDto">ProcessRequestDto</a> + </td> + +</tr> + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + +### DELETE + +<a id="deleteList">Delete vendor software product processes</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + +## /v1.0/vendor-software-products/{vspId}/processes/{processId} + + +### GET + +<a id="get">Get vendor software product process</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>processId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product process Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>version</th> + <td>query</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| 200 | successful operation | <a href="#/definitions/ProcessEntityDto">ProcessEntityDto</a>| + + + + +### PUT + +<a id="update">Update vendor software product process</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + <a href="#/definitions/ProcessRequestDto">ProcessRequestDto</a> + </td> + +</tr> + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>processId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product process Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + +### DELETE + +<a id="delete">Delete vendor software product process</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>processId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product process Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + +## /v1.0/vendor-software-products/{vspId}/processes/{processId}/upload + + +### GET + +<a id="getUploadedFile">Get vendor software product process uploaded file</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>processId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product process Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>version</th> + <td>query</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/octet-stream + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + +### POST + + +<a id="uploadFile">Update vendor software product process upload</a> + + + + + + + + + +#### Request + + +**Content-Type: ** multipart/form-data + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + <a href="#/definitions/Attachment">Attachment</a> + </td> + +</tr> + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>processId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product process Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + +### DELETE + +<a id="deleteUploadedFile">Delete vendor software product process uploaded file</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>processId</th> + <td>path</td> + <td>yes</td> + <td>Vendor software product process Id</td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + +## /v1.0/vendor-software-products/{vspId}/questionnaire + + +### GET + +<a id="getQuestionnaire">Get vendor software product questionnaire</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>version</th> + <td>query</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| 200 | successful operation | <a href="#/definitions/QuestionnaireResponseDto">QuestionnaireResponseDto</a>| + + + + +### PUT + +<a id="updateQuestionnaire">Update vendor software product questionnaire</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + + </td> + +</tr> + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + + + + + +## /v1.0/vendor-software-products/{vspId}/upload + + + + + + +### POST + + +<a id="uploadFile">Uploads a HEAT package to translate</a> + + + + + + + + + +#### Request + + +**Content-Type: ** multipart/form-data + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vspId</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + <a href="#/definitions/InputStream">InputStream</a> + </td> + +</tr> + +<tr> + <th>USER_ID</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| 200 | successful operation | <a href="#/definitions/UploadFileResponseDto">UploadFileResponseDto</a>| + + + + + + + + + + + + + + +## /workflow/v1.0/actions + + +### GET + +<a id="getFilteredActions">List Filtered Actions </a> + +Get list of actions based on a filter criteria | If no filter is sent all actions will be returned + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>vendor</th> + <td>query</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>category</th> + <td>query</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>name</th> + <td>query</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>modelId</th> + <td>query</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>componentId</th> + <td>query</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + +### POST + + +<a id="createAction">Create a new Action</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + + </td> + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + + + + +## /workflow/v1.0/actions/components + + +### GET + +<a id="getEcompComponents">List ECOMP Components supported by Action Library</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + + + + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + + + + + + + +## /workflow/v1.0/actions/{actionInvariantUUID} + + +### GET + +<a id="getActionsByActionInvariantUuId">List Actions For Given Action Invariant UUID</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>actionInvariantUUID</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>version</th> + <td>query</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + +### PUT + +<a id="updateAction">Update an existing action</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>actionInvariantUUID</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + + </td> + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + +### POST + + +<a id="actOnAction">Actions on a action</a> + +Performs one of the following actions on a action: |Checkout: Locks it for edits by other users. Only the locking user sees the edited version.|Undo_Checkout: Unlocks it and deletes the edits that were done.|Checkin: Unlocks it and activates the edited version to all users.| Submit: Finalize its active version.| + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>actionInvariantUUID</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + + </td> + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + +### DELETE + +<a id="deleteAction">Delete Action</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>actionInvariantUUID</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + +## /workflow/v1.0/actions/{actionInvariantUUID}/artifacts + + + + + + +### POST + + +<a id="uploadArtifact">Upload new Artifact</a> + + + + + + + + + +#### Request + + +**Content-Type: ** multipart/form-data + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>actionInvariantUUID</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + + </td> + +</tr> + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + + </td> + +</tr> + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + + </td> + +</tr> + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + + </td> + +</tr> + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + + </td> + +</tr> + +<tr> + <th>Content-MD5</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + <a href="#/definitions/Attachment">Attachment</a> + </td> + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + + + + +## /workflow/v1.0/actions/{actionInvariantUUID}/artifacts/{artifactUUID} + + + + +### PUT + +<a id="updateArtifact">Update an existing artifact</a> + + + + + + + + + +#### Request + + +**Content-Type: ** multipart/form-data + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>actionInvariantUUID</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>artifactUUID</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + + </td> + +</tr> + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + + </td> + +</tr> + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + + </td> + +</tr> + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + + </td> + +</tr> + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + + </td> + +</tr> + +<tr> + <th>Content-MD5</th> + <td>header</td> + <td>no</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>body</th> + <td>body</td> + <td>no</td> + <td></td> + <td> - </td> + + <td> + + <a href="#/definitions/Attachment">Attachment</a> + </td> + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + +### DELETE + +<a id="deleteArtifact">Delete Artifact</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>actionInvariantUUID</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>artifactUUID</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/json + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + +## /workflow/v1.0/actions/{actionUUID}/artifacts/{artifactUUID} + + +### GET + +<a id="downloadArtifact">Downloads artifact for action</a> + + + + + + + + + +#### Request + + +**Content-Type: ** application/json + +##### Parameters + +<table border="1"> + <tr> + <th>Name</th> + <th>Located in</th> + <th>Required</th> + <th>Description</th> + <th>Default</th> + <th>Schema</th> + </tr> + + + +<tr> + <th>actionUUID</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + +<tr> + <th>artifactUUID</th> + <td>path</td> + <td>yes</td> + <td></td> + <td> - </td> + + + <td>string </td> + + +</tr> + + +</table> + + + +#### Response + +**Content-Type: ** application/octet-stream + + +| Status Code | Reason | Response Model | +|-------------|-------------|----------------| +| default | successful operation | - | + + + + + + + + + + + + + + + + + + +# Definitions + +## <a name="/definitions/Attachment">Attachment</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>headers</td> + <td> + + + object + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>object</td> + <td> + + + object + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>contentType</td> + <td> + + <a href="#/definitions/MediaType">MediaType</a> + + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>contentDisposition</td> + <td> + + <a href="#/definitions/ContentDisposition">ContentDisposition</a> + + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>dataHandler</td> + <td> + + <a href="#/definitions/DataHandler">DataHandler</a> + + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>contentId</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/ChoiceOrOtherDtoAggregationFunction">ChoiceOrOtherDtoAggregationFunction</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>choice</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>other</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/ChoiceOrOtherDtoEntitlementMetric">ChoiceOrOtherDtoEntitlementMetric</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>choice</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>other</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/ChoiceOrOtherDtoEntitlementTime">ChoiceOrOtherDtoEntitlementTime</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>choice</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>other</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/ChoiceOrOtherDtoLicenseTerm">ChoiceOrOtherDtoLicenseTerm</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>choice</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>other</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/CommandInfo">CommandInfo</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>commandClass</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>commandName</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/ComponentData">ComponentData</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>name</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>description</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>displayName</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/ComponentDto">ComponentDto</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>name</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>displayName</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>description</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>id</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/ComponentRequestDto">ComponentRequestDto</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>name</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>displayName</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>description</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/ConfigurationDataDto">ConfigurationDataDto</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>value</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>timeStamp</td> + <td> + + + integer (int64) + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/ContentDisposition">ContentDisposition</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>type</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>parameters</td> + <td> + + + object + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>filename</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/DataFlavor">DataFlavor</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>mimeType</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>humanPresentableName</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>subType</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>defaultRepresentationClassAsString</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>primaryType</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>flavorJavaFileListType</td> + <td> + + + boolean + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>flavorRemoteObjectType</td> + <td> + + + boolean + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>flavorSerializedObjectType</td> + <td> + + + boolean + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>flavorTextType</td> + <td> + + + boolean + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>mimeTypeSerializedObject</td> + <td> + + + boolean + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>representationClassByteBuffer</td> + <td> + + + boolean + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>representationClassCharBuffer</td> + <td> + + + boolean + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>representationClassInputStream</td> + <td> + + + boolean + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>representationClassReader</td> + <td> + + + boolean + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>representationClassRemote</td> + <td> + + + boolean + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>representationClassSerializable</td> + <td> + + + boolean + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/DataHandler">DataHandler</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>dataSource</td> + <td> + + <a href="#/definitions/DataSource">DataSource</a> + + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>name</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>inputStream</td> + <td> + + <a href="#/definitions/InputStream">InputStream</a> + + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>content</td> + <td> + + + object + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>contentType</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>outputStream</td> + <td> + + <a href="#/definitions/OutputStream">OutputStream</a> + + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>allCommands</td> + <td> + + + array[<a href="#/definitions/CommandInfo">CommandInfo</a>] + + + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>preferredCommands</td> + <td> + + + array[<a href="#/definitions/CommandInfo">CommandInfo</a>] + + + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>transferDataFlavors</td> + <td> + + + array[<a href="#/definitions/DataFlavor">DataFlavor</a>] + + + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/DataSource">DataSource</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>name</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>inputStream</td> + <td> + + <a href="#/definitions/InputStream">InputStream</a> + + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>contentType</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>outputStream</td> + <td> + + <a href="#/definitions/OutputStream">OutputStream</a> + + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/EntitlementPoolEntity">EntitlementPoolEntity</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>name</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>description</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>thresholdValue</td> + <td> + + + integer (int32) + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>thresholdUnits</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>entitlementMetric</td> + <td> + + <a href="#/definitions/ChoiceOrOtherDtoEntitlementMetric">ChoiceOrOtherDtoEntitlementMetric</a> + + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>increments</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>aggregationFunction</td> + <td> + + <a href="#/definitions/ChoiceOrOtherDtoAggregationFunction">ChoiceOrOtherDtoAggregationFunction</a> + + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>operationalScope</td> + <td> + + <a href="#/definitions/MultiChoiceOrOtherDtoOperationalScope">MultiChoiceOrOtherDtoOperationalScope</a> + + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>time</td> + <td> + + <a href="#/definitions/ChoiceOrOtherDtoEntitlementTime">ChoiceOrOtherDtoEntitlementTime</a> + + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>manufacturerReferenceNumber</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>id</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>referencingFeatureGroups</td> + <td> + + + array[string] + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/EntitlementPoolRequest">EntitlementPoolRequest</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>name</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>description</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>thresholdValue</td> + <td> + + + integer (int32) + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>thresholdUnits</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>entitlementMetric</td> + <td> + + <a href="#/definitions/ChoiceOrOtherDtoEntitlementMetric">ChoiceOrOtherDtoEntitlementMetric</a> + + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>increments</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>aggregationFunction</td> + <td> + + <a href="#/definitions/ChoiceOrOtherDtoAggregationFunction">ChoiceOrOtherDtoAggregationFunction</a> + + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>operationalScope</td> + <td> + + <a href="#/definitions/MultiChoiceOrOtherDtoOperationalScope">MultiChoiceOrOtherDtoOperationalScope</a> + + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>time</td> + <td> + + <a href="#/definitions/ChoiceOrOtherDtoEntitlementTime">ChoiceOrOtherDtoEntitlementTime</a> + + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>manufacturerReferenceNumber</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/ErrorMessage">ErrorMessage</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>level</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>message</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/FeatureGroupEntity">FeatureGroupEntity</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>name</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>description</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>partNumber</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>id</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>licenseKeyGroupsIds</td> + <td> + + + array[string] + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>entitlementPoolsIds</td> + <td> + + + array[string] + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>referencingLicenseAgreements</td> + <td> + + + array[string] + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/FeatureGroupModel">FeatureGroupModel</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>name</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>description</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>partNumber</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>id</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>referencingLicenseAgreements</td> + <td> + + + array[string] + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>licenseKeyGroups</td> + <td> + + + array[<a href="#/definitions/LicenseKeyGroupEntityDto">LicenseKeyGroupEntityDto</a>] + + + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>entitlementPools</td> + <td> + + + array[<a href="#/definitions/EntitlementPoolEntity">EntitlementPoolEntity</a>] + + + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/FeatureGroupRequest">FeatureGroupRequest</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>name</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>description</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>partNumber</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>addedLicenseKeyGroupsIds</td> + <td> + + + array[string] + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>addedEntitlementPoolsIds</td> + <td> + + + array[string] + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/FeatureGroupUpdateRequest">FeatureGroupUpdateRequest</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>name</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>description</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>partNumber</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>addedLicenseKeyGroupsIds</td> + <td> + + + array[string] + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>addedEntitlementPoolsIds</td> + <td> + + + array[string] + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>removedLicenseKeyGroupsIds</td> + <td> + + + array[string] + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>removedEntitlementPoolsIds</td> + <td> + + + array[string] + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/File">File</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>path</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>name</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>canonicalPath</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>parent</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>absolute</td> + <td> + + + boolean + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>absoluteFile</td> + <td> + + <a href="#/definitions/File">File</a> + + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>absolutePath</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>canonicalFile</td> + <td> + + <a href="#/definitions/File">File</a> + + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>freeSpace</td> + <td> + + + integer (int64) + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>parentFile</td> + <td> + + <a href="#/definitions/File">File</a> + + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>totalSpace</td> + <td> + + + integer (int64) + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>usableSpace</td> + <td> + + + integer (int64) + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>directory</td> + <td> + + + boolean + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>file</td> + <td> + + + boolean + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>hidden</td> + <td> + + + boolean + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/InputStream">InputStream</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + +</table> + +## <a name="/definitions/LicenseAgreementEntity">LicenseAgreementEntity</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>name</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>description</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>licenseTerm</td> + <td> + + <a href="#/definitions/ChoiceOrOtherDtoLicenseTerm">ChoiceOrOtherDtoLicenseTerm</a> + + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>requirementsAndConstrains</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>id</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>featureGroupsIds</td> + <td> + + + array[string] + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/LicenseAgreementModel">LicenseAgreementModel</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>name</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>description</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>licenseTerm</td> + <td> + + <a href="#/definitions/ChoiceOrOtherDtoLicenseTerm">ChoiceOrOtherDtoLicenseTerm</a> + + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>requirementsAndConstrains</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>id</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>featureGroups</td> + <td> + + + array[<a href="#/definitions/FeatureGroupEntity">FeatureGroupEntity</a>] + + + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/LicenseAgreementRequest">LicenseAgreementRequest</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>name</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>description</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>licenseTerm</td> + <td> + + <a href="#/definitions/ChoiceOrOtherDtoLicenseTerm">ChoiceOrOtherDtoLicenseTerm</a> + + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>requirementsAndConstrains</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>addedFeatureGroupsIds</td> + <td> + + + array[string] + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/LicenseAgreementUpdateRequest">LicenseAgreementUpdateRequest</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>name</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>description</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>licenseTerm</td> + <td> + + <a href="#/definitions/ChoiceOrOtherDtoLicenseTerm">ChoiceOrOtherDtoLicenseTerm</a> + + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>requirementsAndConstrains</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>addedFeatureGroupsIds</td> + <td> + + + array[string] + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>removedFeatureGroupsIds</td> + <td> + + + array[string] + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/LicenseKeyGroupEntityDto">LicenseKeyGroupEntityDto</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>name</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>description</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>type</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>operationalScope</td> + <td> + + <a href="#/definitions/MultiChoiceOrOtherDtoOperationalScope">MultiChoiceOrOtherDtoOperationalScope</a> + + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>id</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>referencingFeatureGroups</td> + <td> + + + array[string] + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/LicenseKeyGroupRequestDto">LicenseKeyGroupRequestDto</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>name</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>description</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>type</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>operationalScope</td> + <td> + + <a href="#/definitions/MultiChoiceOrOtherDtoOperationalScope">MultiChoiceOrOtherDtoOperationalScope</a> + + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/LicensingData">LicensingData</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>licenseAgreement</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>featureGroups</td> + <td> + + + array[string] + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/MediaType">MediaType</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>type</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>subtype</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>parameters</td> + <td> + + + object + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>wildcardSubtype</td> + <td> + + + boolean + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>wildcardType</td> + <td> + + + boolean + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/MibUploadStatusDto">MibUploadStatusDto</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>snmpTrap</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>snmpPoll</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/MultiChoiceOrOtherDtoOperationalScope">MultiChoiceOrOtherDtoOperationalScope</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>choices</td> + <td> + + + array[string] + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>other</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/NetworkDto">NetworkDto</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>name</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>dhcp</td> + <td> + + + boolean + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>id</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/NetworkRequestDto">NetworkRequestDto</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>name</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>dhcp</td> + <td> + + + boolean + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/NicDto">NicDto</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>name</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>description</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>networkId</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>id</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>networkName</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/NicRequestDto">NicRequestDto</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>name</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>description</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>networkId</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/OutputStream">OutputStream</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + +</table> + +## <a name="/definitions/PackageInfoDto">PackageInfoDto</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>displayName</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>description</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>vspName</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>version</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>packageId</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>category</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>subCategory</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>vendorName</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>vendorRelease</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>packageChecksum</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>packageType</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/ProcessEntityDto">ProcessEntityDto</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>name</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>description</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>id</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>artifactName</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/ProcessRequestDto">ProcessRequestDto</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>name</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>description</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/QuestionnaireResponseDto">QuestionnaireResponseDto</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>schema</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>data</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/UploadFileResponseDto">UploadFileResponseDto</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>fileNames</td> + <td> + + + array[string] + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>errors</td> + <td> + + + object + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>status</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/VendorLicenseModelActionRequestDto">VendorLicenseModelActionRequestDto</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>action</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/VendorLicenseModelEntity">VendorLicenseModelEntity</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>vendorName</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>description</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>iconRef</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>id</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>version</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>status</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>lockingUser</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>viewableVersions</td> + <td> + + + array[string] + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>finalVersions</td> + <td> + + + array[string] + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/VendorLicenseModelRequest">VendorLicenseModelRequest</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>vendorName</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>description</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>iconRef</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/VersionSoftwareProductActionRequestDto">VersionSoftwareProductActionRequestDto</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>action</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/VspCreationDto">VspCreationDto</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>vspId</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + +## <a name="/definitions/VspDescriptionDto">VspDescriptionDto</a> + +<table border="1"> + <tr> + <th>name</th> + <th>type</th> + <th>required</th> + <th>description</th> + <th>example</th> + </tr> + + <tr> + <td>name</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>description</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>icon</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>category</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>subCategory</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>vendorName</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>vendorId</td> + <td> + + + string + + </td> + <td>required</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>licensingVersion</td> + <td> + + + string + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + + <tr> + <td>licensingData</td> + <td> + + <a href="#/definitions/LicensingData">LicensingData</a> + + + </td> + <td>optional</td> + <td>-</td> + <td></td> + </tr> + +</table> + + + + + \ No newline at end of file diff --git a/openecomp-be/tools/swagger-ui/api-docs/api.json b/openecomp-be/tools/swagger-ui/api-docs/api.json new file mode 100644 index 0000000000..8396339628 --- /dev/null +++ b/openecomp-be/tools/swagger-ui/api-docs/api.json @@ -0,0 +1,4676 @@ +{ + "swagger" : "2.0", + "info" : { + "description" : "Rest API Documentation", + "version" : "v1.0, build #${buildNumber}", + "title" : "Rest API", + "termsOfService" : "http://www.github.com/kongchen/swagger-maven-plugin" + }, + "basePath" : "/onboarding-api", + "tags" : [ { + "name" : "Vendor License Models" + }, { + "name" : "Vendor License Model - Entitlement Pools" + }, { + "name" : "Vendor Software Product Processes" + }, { + "name" : "Application Configuration" + }, { + "name" : "Actions" + }, { + "name" : "Vendor License Model - License Key Groups" + }, { + "name" : "Vendor Software Product Component Processes" + }, { + "name" : "Vendor Software Product Components" + }, { + "name" : "Validation" + }, { + "name" : "Vendor Software Product Component MIB Uploads" + }, { + "name" : "Vendor License Model - License Agreements" + }, { + "name" : "Vendor Software Product Networks" + }, { + "name" : "Vendor Software Products" + }, { + "name" : "Vendor Software Product Component NICs" + }, { + "name" : "Vendor License Model - Feature Groups" + } ], + "schemes" : [ "http" ], + "paths" : { + "/v1.0/application-configuration" : { + "post" : { + "tags" : [ "Application Configuration" ], + "summary" : "Insert JSON schema into application config table", + "description" : "", + "operationId" : "insertToTable", + "consumes" : [ "multipart/form-data" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "namespace", + "in" : "query", + "required" : false, + "type" : "string" + }, { + "name" : "key", + "in" : "query", + "required" : false, + "type" : "string" + }, { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "$ref" : "#/definitions/InputStream" + } + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/v1.0/application-configuration/{namespace}" : { + "get" : { + "tags" : [ "Application Configuration" ], + "summary" : "Get List of keys and values by namespace", + "description" : "", + "operationId" : "getListOfConfigurationByNamespaceFromTable", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "namespace", + "in" : "path", + "required" : true, + "type" : "string" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/v1.0/application-configuration/{namespace}/{key}" : { + "get" : { + "tags" : [ "Application Configuration" ], + "summary" : "Get JSON schema by namespace and key", + "description" : "", + "operationId" : "getFromTable", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "namespace", + "in" : "path", + "required" : true, + "type" : "string" + }, { + "name" : "key", + "in" : "path", + "required" : true, + "type" : "string" + } ], + "responses" : { + "200" : { + "description" : "successful operation", + "schema" : { + "$ref" : "#/definitions/ConfigurationDataDto" + } + } + } + } + }, + "/v1.0/validation/{type}/validate" : { + "post" : { + "tags" : [ "Validation" ], + "summary" : "Validate a package", + "description" : "", + "operationId" : "validateFile", + "consumes" : [ "multipart/form-data" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "type", + "in" : "path", + "required" : true, + "type" : "string" + }, { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "$ref" : "#/definitions/InputStream" + } + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/v1.0/vendor-license-models" : { + "get" : { + "tags" : [ "Vendor License Models" ], + "summary" : "List vendor license models", + "description" : "", + "operationId" : "listLicenseModels", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "versionFilter", + "in" : "query", + "description" : "Currently supported value: 'Final' - only vendor License models with final versions will be return - with their latest final version", + "required" : false, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "200" : { + "description" : "successful operation", + "schema" : { + "type" : "array", + "items" : { + "$ref" : "#/definitions/VendorLicenseModelEntity" + } + } + } + } + }, + "post" : { + "tags" : [ "Vendor License Models" ], + "summary" : "Create vendor license model", + "description" : "", + "operationId" : "createLicenseModel", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "$ref" : "#/definitions/VendorLicenseModelRequest" + } + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/v1.0/vendor-license-models/{vlmId}" : { + "get" : { + "tags" : [ "Vendor License Models" ], + "summary" : "Get vendor license model", + "description" : "", + "operationId" : "getLicenseModel", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vlmId", + "in" : "path", + "description" : "Vendor license model Id", + "required" : true, + "type" : "string" + }, { + "name" : "version", + "in" : "query", + "required" : false, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "200" : { + "description" : "successful operation", + "schema" : { + "$ref" : "#/definitions/VendorLicenseModelEntity" + } + } + } + }, + "put" : { + "tags" : [ "Vendor License Models" ], + "summary" : "Update vendor license model", + "description" : "", + "operationId" : "updateLicenseModel", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "$ref" : "#/definitions/VendorLicenseModelRequest" + } + }, { + "name" : "vlmId", + "in" : "path", + "description" : "Vendor license model Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + }, + "delete" : { + "tags" : [ "Vendor License Models" ], + "summary" : "Delete vendor license model", + "description" : "", + "operationId" : "deleteLicenseModel", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vlmId", + "in" : "path", + "description" : "Vendor license model Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/v1.0/vendor-license-models/{vlmId}/actions" : { + "put" : { + "tags" : [ "Vendor License Models" ], + "summary" : "Update vendor license model", + "description" : "", + "operationId" : "actOnLicenseModel", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "$ref" : "#/definitions/VendorLicenseModelActionRequestDto" + } + }, { + "name" : "vlmId", + "in" : "path", + "description" : "Vendor license model Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/v1.0/vendor-license-models/{vlmId}/entitlement-pools" : { + "get" : { + "tags" : [ "Vendor License Model - Entitlement Pools" ], + "summary" : "List vendor entitlement pools", + "description" : "", + "operationId" : "listEntitlementPools", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vlmId", + "in" : "path", + "description" : "Vendor license model Id", + "required" : true, + "type" : "string" + }, { + "name" : "version", + "in" : "query", + "required" : false, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "200" : { + "description" : "successful operation", + "schema" : { + "type" : "array", + "items" : { + "$ref" : "#/definitions/EntitlementPoolEntity" + } + } + } + } + }, + "post" : { + "tags" : [ "Vendor License Model - Entitlement Pools" ], + "summary" : "Create vendor entitlement pool", + "description" : "", + "operationId" : "createEntitlementPool", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "$ref" : "#/definitions/EntitlementPoolRequest" + } + }, { + "name" : "vlmId", + "in" : "path", + "description" : "Vendor license model Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/v1.0/vendor-license-models/{vlmId}/entitlement-pools/{entitlementPoolId}" : { + "get" : { + "tags" : [ "Vendor License Model - Entitlement Pools" ], + "summary" : "Get vendor entitlement pool", + "description" : "", + "operationId" : "getEntitlementPool", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vlmId", + "in" : "path", + "description" : "Vendor license model Id", + "required" : true, + "type" : "string" + }, { + "name" : "version", + "in" : "query", + "required" : false, + "type" : "string" + }, { + "name" : "entitlementPoolId", + "in" : "path", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "200" : { + "description" : "successful operation", + "schema" : { + "$ref" : "#/definitions/EntitlementPoolEntity" + } + } + } + }, + "put" : { + "tags" : [ "Vendor License Model - Entitlement Pools" ], + "summary" : "Update vendor entitlement pool", + "description" : "", + "operationId" : "updateEntitlementPool", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "$ref" : "#/definitions/EntitlementPoolRequest" + } + }, { + "name" : "vlmId", + "in" : "path", + "description" : "Vendor license model Id", + "required" : true, + "type" : "string" + }, { + "name" : "entitlementPoolId", + "in" : "path", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + }, + "delete" : { + "tags" : [ "Vendor License Model - Entitlement Pools" ], + "summary" : "Delete vendor entitlement pool", + "description" : "", + "operationId" : "deleteEntitlementPool", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vlmId", + "in" : "path", + "description" : "Vendor license model Id", + "required" : true, + "type" : "string" + }, { + "name" : "entitlementPoolId", + "in" : "path", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/v1.0/vendor-license-models/{vlmId}/feature-groups" : { + "get" : { + "tags" : [ "Vendor License Model - Feature Groups" ], + "summary" : "List vendor feature groups", + "description" : "", + "operationId" : "listFeatureGroups", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vlmId", + "in" : "path", + "description" : "Vendor license model Id", + "required" : true, + "type" : "string" + }, { + "name" : "version", + "in" : "query", + "required" : false, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "200" : { + "description" : "successful operation", + "schema" : { + "type" : "array", + "items" : { + "$ref" : "#/definitions/FeatureGroupEntity" + } + } + } + } + }, + "post" : { + "tags" : [ "Vendor License Model - Feature Groups" ], + "summary" : "Create vendor feature group", + "description" : "", + "operationId" : "createFeatureGroup", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "$ref" : "#/definitions/FeatureGroupRequest" + } + }, { + "name" : "vlmId", + "in" : "path", + "description" : "Vendor license model Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/v1.0/vendor-license-models/{vlmId}/feature-groups/{featureGroupId}" : { + "get" : { + "tags" : [ "Vendor License Model - Feature Groups" ], + "summary" : "Get vendor feature group", + "description" : "", + "operationId" : "getFeatureGroup", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vlmId", + "in" : "path", + "description" : "Vendor license model Id", + "required" : true, + "type" : "string" + }, { + "name" : "version", + "in" : "query", + "required" : false, + "type" : "string" + }, { + "name" : "featureGroupId", + "in" : "path", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "200" : { + "description" : "successful operation", + "schema" : { + "$ref" : "#/definitions/FeatureGroupModel" + } + } + } + }, + "put" : { + "tags" : [ "Vendor License Model - Feature Groups" ], + "summary" : "Update vendor feature group", + "description" : "", + "operationId" : "updateFeatureGroup", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "$ref" : "#/definitions/FeatureGroupUpdateRequest" + } + }, { + "name" : "vlmId", + "in" : "path", + "description" : "Vendor license model Id", + "required" : true, + "type" : "string" + }, { + "name" : "featureGroupId", + "in" : "path", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + }, + "delete" : { + "tags" : [ "Vendor License Model - Feature Groups" ], + "summary" : "Delete vendor feature group", + "description" : "", + "operationId" : "deleteFeatureGroup", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vlmId", + "in" : "path", + "description" : "Vendor license model Id", + "required" : true, + "type" : "string" + }, { + "name" : "featureGroupId", + "in" : "path", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/v1.0/vendor-license-models/{vlmId}/license-agreements" : { + "get" : { + "tags" : [ "Vendor License Model - License Agreements" ], + "summary" : "List vendor license agreements", + "description" : "", + "operationId" : "listLicenseAgreements", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vlmId", + "in" : "path", + "description" : "Vendor license model Id", + "required" : true, + "type" : "string" + }, { + "name" : "version", + "in" : "query", + "required" : false, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "200" : { + "description" : "successful operation", + "schema" : { + "type" : "array", + "items" : { + "$ref" : "#/definitions/LicenseAgreementEntity" + } + } + } + } + }, + "post" : { + "tags" : [ "Vendor License Model - License Agreements" ], + "summary" : "Create vendor license agreement", + "description" : "", + "operationId" : "createLicenseAgreement", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "$ref" : "#/definitions/LicenseAgreementRequest" + } + }, { + "name" : "vlmId", + "in" : "path", + "description" : "Vendor license model Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/v1.0/vendor-license-models/{vlmId}/license-agreements/{licenseAgreementId}" : { + "get" : { + "tags" : [ "Vendor License Model - License Agreements" ], + "summary" : "Get vendor license agreement", + "description" : "", + "operationId" : "getLicenseAgreement", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vlmId", + "in" : "path", + "description" : "Vendor license model Id", + "required" : true, + "type" : "string" + }, { + "name" : "version", + "in" : "query", + "required" : false, + "type" : "string" + }, { + "name" : "licenseAgreementId", + "in" : "path", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "200" : { + "description" : "successful operation", + "schema" : { + "$ref" : "#/definitions/LicenseAgreementModel" + } + } + } + }, + "put" : { + "tags" : [ "Vendor License Model - License Agreements" ], + "summary" : "Update vendor license agreement", + "description" : "", + "operationId" : "updateLicenseAgreement", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "$ref" : "#/definitions/LicenseAgreementUpdateRequest" + } + }, { + "name" : "vlmId", + "in" : "path", + "description" : "Vendor license model Id", + "required" : true, + "type" : "string" + }, { + "name" : "licenseAgreementId", + "in" : "path", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + }, + "delete" : { + "tags" : [ "Vendor License Model - License Agreements" ], + "summary" : "Delete vendor license agreement", + "description" : "", + "operationId" : "deleteLicenseAgreement", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vlmId", + "in" : "path", + "description" : "Vendor license model Id", + "required" : true, + "type" : "string" + }, { + "name" : "licenseAgreementId", + "in" : "path", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/v1.0/vendor-license-models/{vlmId}/license-key-groups" : { + "get" : { + "tags" : [ "Vendor License Model - License Key Groups" ], + "summary" : "List vendor license key groups", + "description" : "", + "operationId" : "listLicenseKeyGroups", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vlmId", + "in" : "path", + "description" : "Vendor license model Id", + "required" : true, + "type" : "string" + }, { + "name" : "version", + "in" : "query", + "required" : false, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "200" : { + "description" : "successful operation", + "schema" : { + "type" : "array", + "items" : { + "$ref" : "#/definitions/LicenseKeyGroupEntityDto" + } + } + } + } + }, + "post" : { + "tags" : [ "Vendor License Model - License Key Groups" ], + "summary" : "Create vendor license key group", + "description" : "", + "operationId" : "createLicenseKeyGroup", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "$ref" : "#/definitions/LicenseKeyGroupRequestDto" + } + }, { + "name" : "vlmId", + "in" : "path", + "description" : "Vendor license model Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/v1.0/vendor-license-models/{vlmId}/license-key-groups/{licenseKeyGroupId}" : { + "get" : { + "tags" : [ "Vendor License Model - License Key Groups" ], + "summary" : "Get vendor license key group", + "description" : "", + "operationId" : "getLicenseKeyGroup", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vlmId", + "in" : "path", + "description" : "Vendor license model Id", + "required" : true, + "type" : "string" + }, { + "name" : "version", + "in" : "query", + "required" : false, + "type" : "string" + }, { + "name" : "licenseKeyGroupId", + "in" : "path", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "200" : { + "description" : "successful operation", + "schema" : { + "$ref" : "#/definitions/LicenseKeyGroupEntityDto" + } + } + } + }, + "put" : { + "tags" : [ "Vendor License Model - License Key Groups" ], + "summary" : "Update vendor license key group", + "description" : "", + "operationId" : "updateLicenseKeyGroup", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "$ref" : "#/definitions/LicenseKeyGroupRequestDto" + } + }, { + "name" : "vlmId", + "in" : "path", + "description" : "Vendor license model Id", + "required" : true, + "type" : "string" + }, { + "name" : "licenseKeyGroupId", + "in" : "path", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + }, + "delete" : { + "tags" : [ "Vendor License Model - License Key Groups" ], + "summary" : "Delete vendor license key group", + "description" : "", + "operationId" : "deleteLicenseKeyGroup", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vlmId", + "in" : "path", + "description" : "Vendor license model Id", + "required" : true, + "type" : "string" + }, { + "name" : "licenseKeyGroupId", + "in" : "path", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/v1.0/vendor-software-products" : { + "get" : { + "tags" : [ "Vendor Software Products" ], + "summary" : "Get list of vendor software products and their description", + "description" : "", + "operationId" : "getVspList", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "versionFilter", + "in" : "query", + "description" : "Currently supported values: 'Final' - only vendor software products with final version will be return - with their latest final version", + "required" : false, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + }, + "post" : { + "tags" : [ "Vendor Software Products" ], + "summary" : "Create a new vendor software product", + "description" : "", + "operationId" : "createNewVsp", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "$ref" : "#/definitions/VspDescriptionDto" + } + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "200" : { + "description" : "successful operation", + "schema" : { + "$ref" : "#/definitions/VspCreationDto" + } + } + } + } + }, + "/v1.0/vendor-software-products/packages" : { + "get" : { + "tags" : [ "Vendor Software Products" ], + "summary" : "Get list of translated CSAR files details", + "description" : "", + "operationId" : "listPackages", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "category", + "in" : "query", + "description" : "Category", + "required" : false, + "type" : "string" + }, { + "name" : "subCategory", + "in" : "query", + "description" : "Sub-category", + "required" : false, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "200" : { + "description" : "successful operation", + "schema" : { + "type" : "array", + "items" : { + "$ref" : "#/definitions/PackageInfoDto" + } + } + } + } + } + }, + "/v1.0/vendor-software-products/packages/{vspId}" : { + "get" : { + "tags" : [ "Vendor Software Products" ], + "summary" : "Get translated CSAR file", + "description" : "Exports translated file to a zip file", + "operationId" : "getTranslatedFile", + "consumes" : [ "application/json" ], + "produces" : [ "application/octet-stream" ], + "parameters" : [ { + "name" : "vspId", + "in" : "path", + "required" : true, + "type" : "string" + }, { + "name" : "version", + "in" : "query", + "required" : false, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "200" : { + "description" : "successful operation", + "schema" : { + "$ref" : "#/definitions/File" + } + } + } + } + }, + "/v1.0/vendor-software-products/{vspId}" : { + "get" : { + "tags" : [ "Vendor Software Products" ], + "summary" : "Get details of a vendor software product", + "description" : "", + "operationId" : "getVspDetails", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vspId", + "in" : "path", + "required" : true, + "type" : "string" + }, { + "name" : "version", + "in" : "query", + "required" : false, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + }, + "put" : { + "tags" : [ "Vendor Software Products" ], + "summary" : "Update an existing vendor software product", + "description" : "", + "operationId" : "updateVsp", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vspId", + "in" : "path", + "required" : true, + "type" : "string" + }, { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "$ref" : "#/definitions/VspDescriptionDto" + } + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + }, + "delete" : { + "tags" : [ "Vendor Software Products" ], + "summary" : "Deletes vendor software product by given id", + "description" : "", + "operationId" : "deleteVsp", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vspId", + "in" : "path", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/v1.0/vendor-software-products/{vspId}/actions" : { + "put" : { + "tags" : [ "Vendor Software Products" ], + "summary" : "Actions on a vendor software product", + "description" : "Performs one of the following actions on a vendor software product: |Checkout: Locks it for edits by other users. Only the locking user sees the edited version.|Undo_Checkout: Unlocks it and deletes the edits that were done.|Checkin: Unlocks it and activates the edited version to all users.| Submit: Finalize its active version.|Create_Package: Creates a CSAR zip file.|", + "operationId" : "actOnVendorSoftwareProduct", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vspId", + "in" : "path", + "required" : true, + "type" : "string" + }, { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "$ref" : "#/definitions/VersionSoftwareProductActionRequestDto" + } + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/v1.0/vendor-software-products/{vspId}/components" : { + "get" : { + "tags" : [ "Vendor Software Product Components" ], + "summary" : "List vendor software product components", + "description" : "", + "operationId" : "list", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "version", + "in" : "query", + "required" : false, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "200" : { + "description" : "successful operation", + "schema" : { + "type" : "array", + "items" : { + "$ref" : "#/definitions/ComponentDto" + } + } + } + } + }, + "post" : { + "tags" : [ "Vendor Software Product Components" ], + "summary" : "Create a vendor software product component", + "description" : "", + "operationId" : "create", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "$ref" : "#/definitions/ComponentRequestDto" + } + }, { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + }, + "delete" : { + "tags" : [ "Vendor Software Product Components" ], + "summary" : "Delete vendor software product components", + "description" : "", + "operationId" : "deleteList", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/v1.0/vendor-software-products/{vspId}/components/{componentId}" : { + "get" : { + "tags" : [ "Vendor Software Product Components" ], + "summary" : "Get vendor software product component", + "description" : "", + "operationId" : "get", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "componentId", + "in" : "path", + "description" : "Vendor software product component Id", + "required" : true, + "type" : "string" + }, { + "name" : "version", + "in" : "query", + "required" : false, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "200" : { + "description" : "successful operation", + "schema" : { + "$ref" : "#/definitions/ComponentData" + } + } + } + }, + "put" : { + "tags" : [ "Vendor Software Product Components" ], + "summary" : "Update vendor software product component", + "description" : "", + "operationId" : "update", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "$ref" : "#/definitions/ComponentRequestDto" + } + }, { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "componentId", + "in" : "path", + "description" : "Vendor software product component Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + }, + "delete" : { + "tags" : [ "Vendor Software Product Components" ], + "summary" : "Delete vendor software product component", + "description" : "", + "operationId" : "delete", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "componentId", + "in" : "path", + "description" : "Vendor software product component Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/v1.0/vendor-software-products/{vspId}/components/{componentId}/monitors/snmp" : { + "get" : { + "tags" : [ "Vendor Software Product Component MIB Uploads" ], + "summary" : "Get the filenames of uploaded MIB definitions", + "description" : "", + "operationId" : "list", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "componentId", + "in" : "path", + "description" : "Vendor software product component Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "200" : { + "description" : "successful operation", + "schema" : { + "$ref" : "#/definitions/MibUploadStatusDto" + } + } + } + }, + "delete" : { + "tags" : [ "Vendor Software Product Component MIB Uploads" ], + "summary" : "Delete vendor software product MIB Poll Definitions file", + "description" : "", + "operationId" : "deletePollMibFile", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "componentId", + "in" : "path", + "description" : "Vendor software product component Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/v1.0/vendor-software-products/{vspId}/components/{componentId}/monitors/snmp-trap" : { + "delete" : { + "tags" : [ "Vendor Software Product Component MIB Uploads" ], + "summary" : "Delete vendor software product MIB Trap Definitions file", + "description" : "", + "operationId" : "deleteTrapMibFile", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "componentId", + "in" : "path", + "description" : "Vendor software product component Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/v1.0/vendor-software-products/{vspId}/components/{componentId}/monitors/snmp-trap/upload" : { + "post" : { + "tags" : [ "Vendor Software Product Component MIB Uploads" ], + "summary" : "Upload vendor software product MIB Trap Definitions file", + "description" : "", + "operationId" : "uploadTrapMibFile", + "consumes" : [ "multipart/form-data" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "$ref" : "#/definitions/Attachment" + } + }, { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "componentId", + "in" : "path", + "description" : "Vendor software product component Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/v1.0/vendor-software-products/{vspId}/components/{componentId}/monitors/snmp/upload" : { + "post" : { + "tags" : [ "Vendor Software Product Component MIB Uploads" ], + "summary" : "Upload vendor software product MIB Poll Definitions file", + "description" : "", + "operationId" : "uploadPollMibFile", + "consumes" : [ "multipart/form-data" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "$ref" : "#/definitions/Attachment" + } + }, { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "componentId", + "in" : "path", + "description" : "Vendor software product component Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/v1.0/vendor-software-products/{vspId}/components/{componentId}/nics" : { + "get" : { + "tags" : [ "Vendor Software Product Component NICs" ], + "summary" : "List vendor software product component NICs", + "description" : "", + "operationId" : "list", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "componentId", + "in" : "path", + "description" : "Vendor software product component Id", + "required" : true, + "type" : "string" + }, { + "name" : "version", + "in" : "query", + "required" : false, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "200" : { + "description" : "successful operation", + "schema" : { + "type" : "array", + "items" : { + "$ref" : "#/definitions/NicDto" + } + } + } + } + }, + "post" : { + "tags" : [ "Vendor Software Product Component NICs" ], + "summary" : "Create a vendor software product NIC", + "description" : "", + "operationId" : "create", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "$ref" : "#/definitions/NicRequestDto" + } + }, { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "componentId", + "in" : "path", + "description" : "Vendor software product component Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/v1.0/vendor-software-products/{vspId}/components/{componentId}/nics/{nicId}" : { + "get" : { + "tags" : [ "Vendor Software Product Component NICs" ], + "summary" : "Get vendor software product NIC", + "description" : "", + "operationId" : "get", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "componentId", + "in" : "path", + "description" : "Vendor software product component Id", + "required" : true, + "type" : "string" + }, { + "name" : "nicId", + "in" : "path", + "description" : "Vendor software product NIC Id", + "required" : true, + "type" : "string" + }, { + "name" : "version", + "in" : "query", + "required" : false, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "200" : { + "description" : "successful operation", + "schema" : { + "$ref" : "#/definitions/NicDto" + } + } + } + }, + "put" : { + "tags" : [ "Vendor Software Product Component NICs" ], + "summary" : "Update vendor software product NIC", + "description" : "", + "operationId" : "update", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "$ref" : "#/definitions/NicRequestDto" + } + }, { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "componentId", + "in" : "path", + "description" : "Vendor software product component Id", + "required" : true, + "type" : "string" + }, { + "name" : "nicId", + "in" : "path", + "description" : "Vendor software product NIC Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + }, + "delete" : { + "tags" : [ "Vendor Software Product Component NICs" ], + "summary" : "Delete vendor software product NIC", + "description" : "", + "operationId" : "delete", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "componentId", + "in" : "path", + "description" : "Vendor software product component Id", + "required" : true, + "type" : "string" + }, { + "name" : "nicId", + "in" : "path", + "description" : "Vendor software product NIC Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/v1.0/vendor-software-products/{vspId}/components/{componentId}/nics/{nicId}/questionnaire" : { + "get" : { + "tags" : [ "Vendor Software Product Component NICs" ], + "summary" : "Get vendor software product component NIC questionnaire", + "description" : "", + "operationId" : "getQuestionnaire", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "componentId", + "in" : "path", + "description" : "Vendor software product component Id", + "required" : true, + "type" : "string" + }, { + "name" : "nicId", + "in" : "path", + "description" : "Vendor software product NIC Id", + "required" : true, + "type" : "string" + }, { + "name" : "version", + "in" : "query", + "required" : false, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "200" : { + "description" : "successful operation", + "schema" : { + "$ref" : "#/definitions/QuestionnaireResponseDto" + } + } + } + }, + "put" : { + "tags" : [ "Vendor Software Product Component NICs" ], + "summary" : "Update vendor software product component NIC questionnaire", + "description" : "", + "operationId" : "updateQuestionnaire", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "type" : "string" + } + }, { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "componentId", + "in" : "path", + "description" : "Vendor software product component Id", + "required" : true, + "type" : "string" + }, { + "name" : "nicId", + "in" : "path", + "description" : "Vendor software product NIC Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/v1.0/vendor-software-products/{vspId}/components/{componentId}/processes" : { + "get" : { + "tags" : [ "Vendor Software Product Component Processes" ], + "summary" : "List vendor software product component processes", + "description" : "", + "operationId" : "list", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "componentId", + "in" : "path", + "description" : "Vendor software product component Id", + "required" : true, + "type" : "string" + }, { + "name" : "version", + "in" : "query", + "required" : false, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "200" : { + "description" : "successful operation", + "schema" : { + "type" : "array", + "items" : { + "$ref" : "#/definitions/ProcessEntityDto" + } + } + } + } + }, + "post" : { + "tags" : [ "Vendor Software Product Component Processes" ], + "summary" : "Create a vendor software product process", + "description" : "", + "operationId" : "create", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "$ref" : "#/definitions/ProcessRequestDto" + } + }, { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "componentId", + "in" : "path", + "description" : "Vendor software product component Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + }, + "delete" : { + "tags" : [ "Vendor Software Product Component Processes" ], + "summary" : "Delete vendor software product processes", + "description" : "", + "operationId" : "deleteList", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "componentId", + "in" : "path", + "description" : "Vendor software product component Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/v1.0/vendor-software-products/{vspId}/components/{componentId}/processes/{processId}" : { + "get" : { + "tags" : [ "Vendor Software Product Component Processes" ], + "summary" : "Get vendor software product process", + "description" : "", + "operationId" : "get", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "componentId", + "in" : "path", + "description" : "Vendor software product component Id", + "required" : true, + "type" : "string" + }, { + "name" : "processId", + "in" : "path", + "description" : "Vendor software product process Id", + "required" : true, + "type" : "string" + }, { + "name" : "version", + "in" : "query", + "required" : false, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "200" : { + "description" : "successful operation", + "schema" : { + "$ref" : "#/definitions/ProcessEntityDto" + } + } + } + }, + "put" : { + "tags" : [ "Vendor Software Product Component Processes" ], + "summary" : "Update vendor software product process", + "description" : "", + "operationId" : "update", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "$ref" : "#/definitions/ProcessRequestDto" + } + }, { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "componentId", + "in" : "path", + "description" : "Vendor software product component Id", + "required" : true, + "type" : "string" + }, { + "name" : "processId", + "in" : "path", + "description" : "Vendor software product process Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + }, + "delete" : { + "tags" : [ "Vendor Software Product Component Processes" ], + "summary" : "Delete vendor software product process", + "description" : "", + "operationId" : "delete", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "componentId", + "in" : "path", + "description" : "Vendor software product component Id", + "required" : true, + "type" : "string" + }, { + "name" : "processId", + "in" : "path", + "description" : "Vendor software product process Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/v1.0/vendor-software-products/{vspId}/components/{componentId}/processes/{processId}/upload" : { + "get" : { + "tags" : [ "Vendor Software Product Component Processes" ], + "summary" : "Get vendor software product process uploaded file", + "description" : "", + "operationId" : "getUploadedFile", + "consumes" : [ "application/json" ], + "produces" : [ "application/octet-stream" ], + "parameters" : [ { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "componentId", + "in" : "path", + "description" : "Vendor software product component Id", + "required" : true, + "type" : "string" + }, { + "name" : "processId", + "in" : "path", + "description" : "Vendor software product process Id", + "required" : true, + "type" : "string" + }, { + "name" : "version", + "in" : "query", + "required" : false, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + }, + "post" : { + "tags" : [ "Vendor Software Product Component Processes" ], + "summary" : "Update vendor software product process upload", + "description" : "", + "operationId" : "uploadFile", + "consumes" : [ "multipart/form-data" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "$ref" : "#/definitions/Attachment" + } + }, { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "componentId", + "in" : "path", + "description" : "Vendor software product component Id", + "required" : true, + "type" : "string" + }, { + "name" : "processId", + "in" : "path", + "description" : "Vendor software product process Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + }, + "delete" : { + "tags" : [ "Vendor Software Product Component Processes" ], + "summary" : "Delete vendor software product process uploaded file", + "description" : "", + "operationId" : "deleteUploadedFile", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "componentId", + "in" : "path", + "description" : "Vendor software product component Id", + "required" : true, + "type" : "string" + }, { + "name" : "processId", + "in" : "path", + "description" : "Vendor software product process Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/v1.0/vendor-software-products/{vspId}/components/{componentId}/questionnaire" : { + "get" : { + "tags" : [ "Vendor Software Product Components" ], + "summary" : "Get vendor software product component questionnaire", + "description" : "", + "operationId" : "getQuestionnaire", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "componentId", + "in" : "path", + "description" : "Vendor software product component Id", + "required" : true, + "type" : "string" + }, { + "name" : "version", + "in" : "query", + "required" : false, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "200" : { + "description" : "successful operation", + "schema" : { + "$ref" : "#/definitions/QuestionnaireResponseDto" + } + } + } + }, + "put" : { + "tags" : [ "Vendor Software Product Components" ], + "summary" : "Update vendor software product component questionnaire", + "description" : "", + "operationId" : "updateQuestionnaire", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "type" : "string" + } + }, { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "componentId", + "in" : "path", + "description" : "Vendor software product component Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/v1.0/vendor-software-products/{vspId}/downloadHeat" : { + "get" : { + "tags" : [ "Vendor Software Products" ], + "summary" : "Get uploaded HEAT file", + "description" : "Downloads the latest HEAT package", + "operationId" : "getLatestHeatPackage", + "consumes" : [ "application/json" ], + "produces" : [ "application/octet-stream" ], + "parameters" : [ { + "name" : "vspId", + "in" : "path", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "200" : { + "description" : "successful operation", + "schema" : { + "$ref" : "#/definitions/File" + } + } + } + } + }, + "/v1.0/vendor-software-products/{vspId}/networks" : { + "get" : { + "tags" : [ "Vendor Software Product Networks" ], + "summary" : "List vendor software product networks", + "description" : "", + "operationId" : "list", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "version", + "in" : "query", + "required" : false, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "200" : { + "description" : "successful operation", + "schema" : { + "type" : "array", + "items" : { + "$ref" : "#/definitions/NetworkDto" + } + } + } + } + }, + "post" : { + "tags" : [ "Vendor Software Product Networks" ], + "summary" : "Create a vendor software product network", + "description" : "", + "operationId" : "create", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "$ref" : "#/definitions/NetworkRequestDto" + } + }, { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/v1.0/vendor-software-products/{vspId}/networks/{networkId}" : { + "get" : { + "tags" : [ "Vendor Software Product Networks" ], + "summary" : "Get vendor software product network", + "description" : "", + "operationId" : "get", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "networkId", + "in" : "path", + "description" : "Vendor software product network Id", + "required" : true, + "type" : "string" + }, { + "name" : "version", + "in" : "query", + "required" : false, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "200" : { + "description" : "successful operation", + "schema" : { + "$ref" : "#/definitions/NetworkDto" + } + } + } + }, + "put" : { + "tags" : [ "Vendor Software Product Networks" ], + "summary" : "Update vendor software product network", + "description" : "", + "operationId" : "update", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "$ref" : "#/definitions/NetworkRequestDto" + } + }, { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "networkId", + "in" : "path", + "description" : "Vendor software product network Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + }, + "delete" : { + "tags" : [ "Vendor Software Product Networks" ], + "summary" : "Delete vendor software product network", + "description" : "", + "operationId" : "delete", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "networkId", + "in" : "path", + "description" : "Vendor software product network Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/v1.0/vendor-software-products/{vspId}/processes" : { + "get" : { + "tags" : [ "Vendor Software Product Processes" ], + "summary" : "List vendor software product processes", + "description" : "", + "operationId" : "list", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "version", + "in" : "query", + "required" : false, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "200" : { + "description" : "successful operation", + "schema" : { + "type" : "array", + "items" : { + "$ref" : "#/definitions/ProcessEntityDto" + } + } + } + } + }, + "post" : { + "tags" : [ "Vendor Software Product Processes" ], + "summary" : "Create a vendor software product process", + "description" : "", + "operationId" : "create", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "$ref" : "#/definitions/ProcessRequestDto" + } + }, { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + }, + "delete" : { + "tags" : [ "Vendor Software Product Processes" ], + "summary" : "Delete vendor software product processes", + "description" : "", + "operationId" : "deleteList", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/v1.0/vendor-software-products/{vspId}/processes/{processId}" : { + "get" : { + "tags" : [ "Vendor Software Product Processes" ], + "summary" : "Get vendor software product process", + "description" : "", + "operationId" : "get", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "processId", + "in" : "path", + "description" : "Vendor software product process Id", + "required" : true, + "type" : "string" + }, { + "name" : "version", + "in" : "query", + "required" : false, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "200" : { + "description" : "successful operation", + "schema" : { + "$ref" : "#/definitions/ProcessEntityDto" + } + } + } + }, + "put" : { + "tags" : [ "Vendor Software Product Processes" ], + "summary" : "Update vendor software product process", + "description" : "", + "operationId" : "update", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "$ref" : "#/definitions/ProcessRequestDto" + } + }, { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "processId", + "in" : "path", + "description" : "Vendor software product process Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + }, + "delete" : { + "tags" : [ "Vendor Software Product Processes" ], + "summary" : "Delete vendor software product process", + "description" : "", + "operationId" : "delete", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "processId", + "in" : "path", + "description" : "Vendor software product process Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/v1.0/vendor-software-products/{vspId}/processes/{processId}/upload" : { + "get" : { + "tags" : [ "Vendor Software Product Processes" ], + "summary" : "Get vendor software product process uploaded file", + "description" : "", + "operationId" : "getUploadedFile", + "consumes" : [ "application/json" ], + "produces" : [ "application/octet-stream" ], + "parameters" : [ { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "processId", + "in" : "path", + "description" : "Vendor software product process Id", + "required" : true, + "type" : "string" + }, { + "name" : "version", + "in" : "query", + "required" : false, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + }, + "post" : { + "tags" : [ "Vendor Software Product Processes" ], + "summary" : "Update vendor software product process upload", + "description" : "", + "operationId" : "uploadFile", + "consumes" : [ "multipart/form-data" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "$ref" : "#/definitions/Attachment" + } + }, { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "processId", + "in" : "path", + "description" : "Vendor software product process Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + }, + "delete" : { + "tags" : [ "Vendor Software Product Processes" ], + "summary" : "Delete vendor software product process uploaded file", + "description" : "", + "operationId" : "deleteUploadedFile", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vspId", + "in" : "path", + "description" : "Vendor software product Id", + "required" : true, + "type" : "string" + }, { + "name" : "processId", + "in" : "path", + "description" : "Vendor software product process Id", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/v1.0/vendor-software-products/{vspId}/questionnaire" : { + "get" : { + "tags" : [ "Vendor Software Products" ], + "summary" : "Get vendor software product questionnaire", + "description" : "", + "operationId" : "getQuestionnaire", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vspId", + "in" : "path", + "required" : true, + "type" : "string" + }, { + "name" : "version", + "in" : "query", + "required" : false, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "200" : { + "description" : "successful operation", + "schema" : { + "$ref" : "#/definitions/QuestionnaireResponseDto" + } + } + } + }, + "put" : { + "tags" : [ "Vendor Software Products" ], + "summary" : "Update vendor software product questionnaire", + "description" : "", + "operationId" : "updateQuestionnaire", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "type" : "string" + } + }, { + "name" : "vspId", + "in" : "path", + "required" : true, + "type" : "string" + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/v1.0/vendor-software-products/{vspId}/upload" : { + "post" : { + "tags" : [ "Vendor Software Products" ], + "summary" : "Uploads a HEAT package to translate", + "description" : "", + "operationId" : "uploadFile", + "consumes" : [ "multipart/form-data" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vspId", + "in" : "path", + "required" : true, + "type" : "string" + }, { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "$ref" : "#/definitions/InputStream" + } + }, { + "name" : "USER_ID", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + } ], + "responses" : { + "200" : { + "description" : "successful operation", + "schema" : { + "$ref" : "#/definitions/UploadFileResponseDto" + } + } + } + } + }, + "/workflow/v1.0/actions" : { + "get" : { + "tags" : [ "Actions" ], + "summary" : "List Filtered Actions ", + "description" : "Get list of actions based on a filter criteria | If no filter is sent all actions will be returned", + "operationId" : "getFilteredActions", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "vendor", + "in" : "query", + "required" : false, + "type" : "string" + }, { + "name" : "category", + "in" : "query", + "required" : false, + "type" : "string" + }, { + "name" : "name", + "in" : "query", + "required" : false, + "type" : "string" + }, { + "name" : "modelId", + "in" : "query", + "required" : false, + "type" : "string" + }, { + "name" : "componentId", + "in" : "query", + "required" : false, + "type" : "string" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + }, + "post" : { + "tags" : [ "Actions" ], + "summary" : "Create a new Action", + "description" : "", + "operationId" : "createAction", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "type" : "string" + } + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/workflow/v1.0/actions/components" : { + "get" : { + "tags" : [ "Actions" ], + "summary" : "List ECOMP Components supported by Action Library", + "description" : "", + "operationId" : "getEcompComponents", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/workflow/v1.0/actions/{actionInvariantUUID}" : { + "get" : { + "tags" : [ "Actions" ], + "summary" : "List Actions For Given Action Invariant UUID", + "description" : "", + "operationId" : "getActionsByActionInvariantUuId", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "actionInvariantUUID", + "in" : "path", + "required" : true, + "type" : "string" + }, { + "name" : "version", + "in" : "query", + "required" : false, + "type" : "string" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + }, + "post" : { + "tags" : [ "Actions" ], + "summary" : "Actions on a action", + "description" : "Performs one of the following actions on a action: |Checkout: Locks it for edits by other users. Only the locking user sees the edited version.|Undo_Checkout: Unlocks it and deletes the edits that were done.|Checkin: Unlocks it and activates the edited version to all users.| Submit: Finalize its active version.|", + "operationId" : "actOnAction", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "actionInvariantUUID", + "in" : "path", + "required" : true, + "type" : "string" + }, { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "type" : "string" + } + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + }, + "put" : { + "tags" : [ "Actions" ], + "summary" : "Update an existing action", + "description" : "", + "operationId" : "updateAction", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "actionInvariantUUID", + "in" : "path", + "required" : true, + "type" : "string" + }, { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "type" : "string" + } + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + }, + "delete" : { + "tags" : [ "Actions" ], + "summary" : "Delete Action", + "description" : "", + "operationId" : "deleteAction", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "actionInvariantUUID", + "in" : "path", + "required" : true, + "type" : "string" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/workflow/v1.0/actions/{actionInvariantUUID}/artifacts" : { + "post" : { + "tags" : [ "Actions" ], + "summary" : "Upload new Artifact", + "description" : "", + "operationId" : "uploadArtifact", + "consumes" : [ "multipart/form-data" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "actionInvariantUUID", + "in" : "path", + "required" : true, + "type" : "string" + }, { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "type" : "string" + } + }, { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "type" : "string" + } + }, { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "type" : "string" + } + }, { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "type" : "string" + } + }, { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "type" : "string" + } + }, { + "name" : "Content-MD5", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + }, { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "$ref" : "#/definitions/Attachment" + } + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/workflow/v1.0/actions/{actionInvariantUUID}/artifacts/{artifactUUID}" : { + "put" : { + "tags" : [ "Actions" ], + "summary" : "Update an existing artifact", + "description" : "", + "operationId" : "updateArtifact", + "consumes" : [ "multipart/form-data" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "actionInvariantUUID", + "in" : "path", + "required" : true, + "type" : "string" + }, { + "name" : "artifactUUID", + "in" : "path", + "required" : true, + "type" : "string" + }, { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "type" : "string" + } + }, { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "type" : "string" + } + }, { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "type" : "string" + } + }, { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "type" : "string" + } + }, { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "type" : "string" + } + }, { + "name" : "Content-MD5", + "in" : "header", + "required" : false, + "type" : "string", + "default" : "" + }, { + "in" : "body", + "name" : "body", + "required" : false, + "schema" : { + "$ref" : "#/definitions/Attachment" + } + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + }, + "delete" : { + "tags" : [ "Actions" ], + "summary" : "Delete Artifact", + "description" : "", + "operationId" : "deleteArtifact", + "consumes" : [ "application/json" ], + "produces" : [ "application/json" ], + "parameters" : [ { + "name" : "actionInvariantUUID", + "in" : "path", + "required" : true, + "type" : "string" + }, { + "name" : "artifactUUID", + "in" : "path", + "required" : true, + "type" : "string" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + }, + "/workflow/v1.0/actions/{actionUUID}/artifacts/{artifactUUID}" : { + "get" : { + "tags" : [ "Actions" ], + "summary" : "Downloads artifact for action", + "description" : "", + "operationId" : "downloadArtifact", + "consumes" : [ "application/json" ], + "produces" : [ "application/octet-stream" ], + "parameters" : [ { + "name" : "actionUUID", + "in" : "path", + "required" : true, + "type" : "string" + }, { + "name" : "artifactUUID", + "in" : "path", + "required" : true, + "type" : "string" + } ], + "responses" : { + "default" : { + "description" : "successful operation" + } + } + } + } + }, + "definitions" : { + "Attachment" : { + "type" : "object", + "properties" : { + "headers" : { + "type" : "object", + "additionalProperties" : { + "type" : "array", + "items" : { + "type" : "string" + } + } + }, + "object" : { + "type" : "object" + }, + "contentType" : { + "$ref" : "#/definitions/MediaType" + }, + "contentDisposition" : { + "$ref" : "#/definitions/ContentDisposition" + }, + "dataHandler" : { + "$ref" : "#/definitions/DataHandler" + }, + "contentId" : { + "type" : "string" + } + } + }, + "ChoiceOrOtherDtoAggregationFunction" : { + "type" : "object", + "required" : [ "choice", "other" ], + "properties" : { + "choice" : { + "type" : "string", + "enum" : [ "Peak", "Average", "Other" ] + }, + "other" : { + "type" : "string" + } + } + }, + "ChoiceOrOtherDtoEntitlementMetric" : { + "type" : "object", + "required" : [ "choice", "other" ], + "properties" : { + "choice" : { + "type" : "string", + "enum" : [ "Software_Instances_Count", "Core", "CPU", "Trunks", "User", "Subscribers", "Tenants", "Tokens", "Seats", "Units_TB", "Units_MB", "Units_GB", "Other" ] + }, + "other" : { + "type" : "string" + } + } + }, + "ChoiceOrOtherDtoEntitlementTime" : { + "type" : "object", + "required" : [ "choice", "other" ], + "properties" : { + "choice" : { + "type" : "string", + "enum" : [ "Hour", "Day", "Month", "Quarter", "Year", "Other" ] + }, + "other" : { + "type" : "string" + } + } + }, + "ChoiceOrOtherDtoLicenseTerm" : { + "type" : "object", + "required" : [ "choice", "other" ], + "properties" : { + "choice" : { + "type" : "string", + "enum" : [ "Fixed_Term", "Perpetual", "Unlimited", "Other" ] + }, + "other" : { + "type" : "string" + } + } + }, + "CommandInfo" : { + "type" : "object", + "properties" : { + "commandClass" : { + "type" : "string" + }, + "commandName" : { + "type" : "string" + } + } + }, + "ComponentData" : { + "type" : "object", + "properties" : { + "name" : { + "type" : "string" + }, + "description" : { + "type" : "string" + }, + "displayName" : { + "type" : "string" + } + } + }, + "ComponentDto" : { + "type" : "object", + "properties" : { + "name" : { + "type" : "string" + }, + "displayName" : { + "type" : "string" + }, + "description" : { + "type" : "string" + }, + "id" : { + "type" : "string" + } + } + }, + "ComponentRequestDto" : { + "type" : "object", + "properties" : { + "name" : { + "type" : "string" + }, + "displayName" : { + "type" : "string" + }, + "description" : { + "type" : "string" + } + } + }, + "ConfigurationDataDto" : { + "type" : "object", + "properties" : { + "value" : { + "type" : "string" + }, + "timeStamp" : { + "type" : "integer", + "format" : "int64" + } + } + }, + "ContentDisposition" : { + "type" : "object", + "properties" : { + "type" : { + "type" : "string" + }, + "parameters" : { + "type" : "object", + "additionalProperties" : { + "type" : "string" + } + }, + "filename" : { + "type" : "string" + } + } + }, + "DataFlavor" : { + "type" : "object", + "properties" : { + "mimeType" : { + "type" : "string" + }, + "humanPresentableName" : { + "type" : "string" + }, + "subType" : { + "type" : "string" + }, + "defaultRepresentationClassAsString" : { + "type" : "string" + }, + "primaryType" : { + "type" : "string" + }, + "flavorJavaFileListType" : { + "type" : "boolean", + "default" : false + }, + "flavorRemoteObjectType" : { + "type" : "boolean", + "default" : false + }, + "flavorSerializedObjectType" : { + "type" : "boolean", + "default" : false + }, + "flavorTextType" : { + "type" : "boolean", + "default" : false + }, + "mimeTypeSerializedObject" : { + "type" : "boolean", + "default" : false + }, + "representationClassByteBuffer" : { + "type" : "boolean", + "default" : false + }, + "representationClassCharBuffer" : { + "type" : "boolean", + "default" : false + }, + "representationClassInputStream" : { + "type" : "boolean", + "default" : false + }, + "representationClassReader" : { + "type" : "boolean", + "default" : false + }, + "representationClassRemote" : { + "type" : "boolean", + "default" : false + }, + "representationClassSerializable" : { + "type" : "boolean", + "default" : false + } + } + }, + "DataHandler" : { + "type" : "object", + "properties" : { + "dataSource" : { + "$ref" : "#/definitions/DataSource" + }, + "name" : { + "type" : "string" + }, + "inputStream" : { + "$ref" : "#/definitions/InputStream" + }, + "content" : { + "type" : "object" + }, + "contentType" : { + "type" : "string" + }, + "outputStream" : { + "$ref" : "#/definitions/OutputStream" + }, + "allCommands" : { + "type" : "array", + "items" : { + "$ref" : "#/definitions/CommandInfo" + } + }, + "preferredCommands" : { + "type" : "array", + "items" : { + "$ref" : "#/definitions/CommandInfo" + } + }, + "transferDataFlavors" : { + "type" : "array", + "items" : { + "$ref" : "#/definitions/DataFlavor" + } + } + } + }, + "DataSource" : { + "type" : "object", + "properties" : { + "name" : { + "type" : "string" + }, + "inputStream" : { + "$ref" : "#/definitions/InputStream" + }, + "contentType" : { + "type" : "string" + }, + "outputStream" : { + "$ref" : "#/definitions/OutputStream" + } + } + }, + "EntitlementPoolEntity" : { + "type" : "object", + "required" : [ "aggregationFunction", "description", "entitlementMetric", "manufacturerReferenceNumber", "name", "operationalScope", "thresholdUnits", "thresholdValue", "time" ], + "properties" : { + "name" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 120 + }, + "description" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 1000 + }, + "thresholdValue" : { + "type" : "integer", + "format" : "int32" + }, + "thresholdUnits" : { + "type" : "string", + "enum" : [ "Absolute", "Percentage" ] + }, + "entitlementMetric" : { + "$ref" : "#/definitions/ChoiceOrOtherDtoEntitlementMetric" + }, + "increments" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 120 + }, + "aggregationFunction" : { + "$ref" : "#/definitions/ChoiceOrOtherDtoAggregationFunction" + }, + "operationalScope" : { + "$ref" : "#/definitions/MultiChoiceOrOtherDtoOperationalScope" + }, + "time" : { + "$ref" : "#/definitions/ChoiceOrOtherDtoEntitlementTime" + }, + "manufacturerReferenceNumber" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 100 + }, + "id" : { + "type" : "string" + }, + "referencingFeatureGroups" : { + "type" : "array", + "uniqueItems" : true, + "items" : { + "type" : "string" + } + } + } + }, + "EntitlementPoolRequest" : { + "type" : "object", + "required" : [ "aggregationFunction", "description", "entitlementMetric", "manufacturerReferenceNumber", "name", "operationalScope", "thresholdUnits", "thresholdValue", "time" ], + "properties" : { + "name" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 120 + }, + "description" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 1000 + }, + "thresholdValue" : { + "type" : "integer", + "format" : "int32" + }, + "thresholdUnits" : { + "type" : "string", + "enum" : [ "Absolute", "Percentage" ] + }, + "entitlementMetric" : { + "$ref" : "#/definitions/ChoiceOrOtherDtoEntitlementMetric" + }, + "increments" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 120 + }, + "aggregationFunction" : { + "$ref" : "#/definitions/ChoiceOrOtherDtoAggregationFunction" + }, + "operationalScope" : { + "$ref" : "#/definitions/MultiChoiceOrOtherDtoOperationalScope" + }, + "time" : { + "$ref" : "#/definitions/ChoiceOrOtherDtoEntitlementTime" + }, + "manufacturerReferenceNumber" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 100 + } + } + }, + "ErrorMessage" : { + "type" : "object", + "properties" : { + "level" : { + "type" : "string", + "enum" : [ "ERROR", "WARNING", "INFO" ] + }, + "message" : { + "type" : "string" + } + } + }, + "FeatureGroupEntity" : { + "type" : "object", + "required" : [ "description", "name", "partNumber" ], + "properties" : { + "name" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 120 + }, + "description" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 1000 + }, + "partNumber" : { + "type" : "string" + }, + "id" : { + "type" : "string" + }, + "licenseKeyGroupsIds" : { + "type" : "array", + "uniqueItems" : true, + "items" : { + "type" : "string" + } + }, + "entitlementPoolsIds" : { + "type" : "array", + "uniqueItems" : true, + "items" : { + "type" : "string" + } + }, + "referencingLicenseAgreements" : { + "type" : "array", + "uniqueItems" : true, + "items" : { + "type" : "string" + } + } + } + }, + "FeatureGroupModel" : { + "type" : "object", + "required" : [ "description", "name", "partNumber" ], + "properties" : { + "name" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 120 + }, + "description" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 1000 + }, + "partNumber" : { + "type" : "string" + }, + "id" : { + "type" : "string" + }, + "referencingLicenseAgreements" : { + "type" : "array", + "uniqueItems" : true, + "items" : { + "type" : "string" + } + }, + "licenseKeyGroups" : { + "type" : "array", + "items" : { + "$ref" : "#/definitions/LicenseKeyGroupEntityDto" + } + }, + "entitlementPools" : { + "type" : "array", + "items" : { + "$ref" : "#/definitions/EntitlementPoolEntity" + } + } + } + }, + "FeatureGroupRequest" : { + "type" : "object", + "required" : [ "description", "name", "partNumber" ], + "properties" : { + "name" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 120 + }, + "description" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 1000 + }, + "partNumber" : { + "type" : "string" + }, + "addedLicenseKeyGroupsIds" : { + "type" : "array", + "uniqueItems" : true, + "items" : { + "type" : "string" + } + }, + "addedEntitlementPoolsIds" : { + "type" : "array", + "uniqueItems" : true, + "items" : { + "type" : "string" + } + } + } + }, + "FeatureGroupUpdateRequest" : { + "type" : "object", + "required" : [ "description", "name", "partNumber" ], + "properties" : { + "name" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 120 + }, + "description" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 1000 + }, + "partNumber" : { + "type" : "string" + }, + "addedLicenseKeyGroupsIds" : { + "type" : "array", + "uniqueItems" : true, + "items" : { + "type" : "string" + } + }, + "addedEntitlementPoolsIds" : { + "type" : "array", + "uniqueItems" : true, + "items" : { + "type" : "string" + } + }, + "removedLicenseKeyGroupsIds" : { + "type" : "array", + "uniqueItems" : true, + "items" : { + "type" : "string" + } + }, + "removedEntitlementPoolsIds" : { + "type" : "array", + "uniqueItems" : true, + "items" : { + "type" : "string" + } + } + } + }, + "File" : { + "type" : "object", + "properties" : { + "path" : { + "type" : "string" + }, + "name" : { + "type" : "string" + }, + "canonicalPath" : { + "type" : "string" + }, + "parent" : { + "type" : "string" + }, + "absolute" : { + "type" : "boolean", + "default" : false + }, + "absoluteFile" : { + "$ref" : "#/definitions/File" + }, + "absolutePath" : { + "type" : "string" + }, + "canonicalFile" : { + "$ref" : "#/definitions/File" + }, + "freeSpace" : { + "type" : "integer", + "format" : "int64" + }, + "parentFile" : { + "$ref" : "#/definitions/File" + }, + "totalSpace" : { + "type" : "integer", + "format" : "int64" + }, + "usableSpace" : { + "type" : "integer", + "format" : "int64" + }, + "directory" : { + "type" : "boolean", + "default" : false + }, + "file" : { + "type" : "boolean", + "default" : false + }, + "hidden" : { + "type" : "boolean", + "default" : false + } + } + }, + "InputStream" : { + "type" : "object" + }, + "LicenseAgreementEntity" : { + "type" : "object", + "required" : [ "description", "licenseTerm", "name" ], + "properties" : { + "name" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 120 + }, + "description" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 1000 + }, + "licenseTerm" : { + "$ref" : "#/definitions/ChoiceOrOtherDtoLicenseTerm" + }, + "requirementsAndConstrains" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 1000 + }, + "id" : { + "type" : "string" + }, + "featureGroupsIds" : { + "type" : "array", + "uniqueItems" : true, + "items" : { + "type" : "string" + } + } + } + }, + "LicenseAgreementModel" : { + "type" : "object", + "required" : [ "description", "licenseTerm", "name" ], + "properties" : { + "name" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 120 + }, + "description" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 1000 + }, + "licenseTerm" : { + "$ref" : "#/definitions/ChoiceOrOtherDtoLicenseTerm" + }, + "requirementsAndConstrains" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 1000 + }, + "id" : { + "type" : "string" + }, + "featureGroups" : { + "type" : "array", + "uniqueItems" : true, + "items" : { + "$ref" : "#/definitions/FeatureGroupEntity" + } + } + } + }, + "LicenseAgreementRequest" : { + "type" : "object", + "required" : [ "description", "licenseTerm", "name" ], + "properties" : { + "name" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 120 + }, + "description" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 1000 + }, + "licenseTerm" : { + "$ref" : "#/definitions/ChoiceOrOtherDtoLicenseTerm" + }, + "requirementsAndConstrains" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 1000 + }, + "addedFeatureGroupsIds" : { + "type" : "array", + "uniqueItems" : true, + "items" : { + "type" : "string" + } + } + } + }, + "LicenseAgreementUpdateRequest" : { + "type" : "object", + "required" : [ "description", "licenseTerm", "name" ], + "properties" : { + "name" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 120 + }, + "description" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 1000 + }, + "licenseTerm" : { + "$ref" : "#/definitions/ChoiceOrOtherDtoLicenseTerm" + }, + "requirementsAndConstrains" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 1000 + }, + "addedFeatureGroupsIds" : { + "type" : "array", + "uniqueItems" : true, + "items" : { + "type" : "string" + } + }, + "removedFeatureGroupsIds" : { + "type" : "array", + "uniqueItems" : true, + "items" : { + "type" : "string" + } + } + } + }, + "LicenseKeyGroupEntityDto" : { + "type" : "object", + "required" : [ "description", "name", "operationalScope", "type" ], + "properties" : { + "name" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 120 + }, + "description" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 1000 + }, + "type" : { + "type" : "string", + "enum" : [ "Universal", "Unique", "One_Time" ] + }, + "operationalScope" : { + "$ref" : "#/definitions/MultiChoiceOrOtherDtoOperationalScope" + }, + "id" : { + "type" : "string" + }, + "referencingFeatureGroups" : { + "type" : "array", + "uniqueItems" : true, + "items" : { + "type" : "string" + } + } + } + }, + "LicenseKeyGroupRequestDto" : { + "type" : "object", + "required" : [ "description", "name", "operationalScope", "type" ], + "properties" : { + "name" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 120 + }, + "description" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 1000 + }, + "type" : { + "type" : "string", + "enum" : [ "Universal", "Unique", "One_Time" ] + }, + "operationalScope" : { + "$ref" : "#/definitions/MultiChoiceOrOtherDtoOperationalScope" + } + } + }, + "LicensingData" : { + "type" : "object", + "properties" : { + "licenseAgreement" : { + "type" : "string" + }, + "featureGroups" : { + "type" : "array", + "items" : { + "type" : "string" + } + } + } + }, + "MediaType" : { + "type" : "object", + "properties" : { + "type" : { + "type" : "string" + }, + "subtype" : { + "type" : "string" + }, + "parameters" : { + "type" : "object", + "additionalProperties" : { + "type" : "string" + } + }, + "wildcardSubtype" : { + "type" : "boolean", + "default" : false + }, + "wildcardType" : { + "type" : "boolean", + "default" : false + } + } + }, + "MibUploadStatusDto" : { + "type" : "object", + "properties" : { + "snmpTrap" : { + "type" : "string" + }, + "snmpPoll" : { + "type" : "string" + } + } + }, + "MultiChoiceOrOtherDtoOperationalScope" : { + "type" : "object", + "required" : [ "choices", "other" ], + "properties" : { + "choices" : { + "type" : "array", + "uniqueItems" : true, + "items" : { + "type" : "string", + "enum" : [ "Network_Wide", "Availability_Zone", "Data_Center", "Tenant", "VM", "CPU", "Core", "Other" ] + } + }, + "other" : { + "type" : "string" + } + } + }, + "NetworkDto" : { + "type" : "object", + "required" : [ "dhcp", "name" ], + "properties" : { + "name" : { + "type" : "string" + }, + "dhcp" : { + "type" : "boolean", + "default" : false + }, + "id" : { + "type" : "string" + } + } + }, + "NetworkRequestDto" : { + "type" : "object", + "required" : [ "dhcp", "name" ], + "properties" : { + "name" : { + "type" : "string" + }, + "dhcp" : { + "type" : "boolean", + "default" : false + } + } + }, + "NicDto" : { + "type" : "object", + "properties" : { + "name" : { + "type" : "string" + }, + "description" : { + "type" : "string" + }, + "networkId" : { + "type" : "string" + }, + "id" : { + "type" : "string" + }, + "networkName" : { + "type" : "string" + } + } + }, + "NicRequestDto" : { + "type" : "object", + "properties" : { + "name" : { + "type" : "string" + }, + "description" : { + "type" : "string" + }, + "networkId" : { + "type" : "string" + } + } + }, + "OutputStream" : { + "type" : "object" + }, + "PackageInfoDto" : { + "type" : "object", + "properties" : { + "displayName" : { + "type" : "string" + }, + "description" : { + "type" : "string" + }, + "vspName" : { + "type" : "string" + }, + "version" : { + "type" : "string" + }, + "packageId" : { + "type" : "string" + }, + "category" : { + "type" : "string" + }, + "subCategory" : { + "type" : "string" + }, + "vendorName" : { + "type" : "string" + }, + "vendorRelease" : { + "type" : "string" + }, + "packageChecksum" : { + "type" : "string" + }, + "packageType" : { + "type" : "string" + } + } + }, + "ProcessEntityDto" : { + "type" : "object", + "required" : [ "name" ], + "properties" : { + "name" : { + "type" : "string" + }, + "description" : { + "type" : "string" + }, + "id" : { + "type" : "string" + }, + "artifactName" : { + "type" : "string" + } + } + }, + "ProcessRequestDto" : { + "type" : "object", + "required" : [ "name" ], + "properties" : { + "name" : { + "type" : "string" + }, + "description" : { + "type" : "string" + } + } + }, + "QuestionnaireResponseDto" : { + "type" : "object", + "properties" : { + "schema" : { + "type" : "string" + }, + "data" : { + "type" : "string" + } + } + }, + "UploadFileResponseDto" : { + "type" : "object", + "properties" : { + "fileNames" : { + "type" : "array", + "items" : { + "type" : "string" + } + }, + "errors" : { + "type" : "object", + "additionalProperties" : { + "type" : "array", + "items" : { + "$ref" : "#/definitions/ErrorMessage" + } + } + }, + "status" : { + "type" : "string", + "enum" : [ "Success", "Failure" ] + } + } + }, + "VendorLicenseModelActionRequestDto" : { + "type" : "object", + "properties" : { + "action" : { + "type" : "string", + "enum" : [ "Checkout", "Undo_Checkout", "Checkin", "Submit" ] + } + } + }, + "VendorLicenseModelEntity" : { + "type" : "object", + "required" : [ "description", "iconRef", "vendorName" ], + "properties" : { + "vendorName" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 25 + }, + "description" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 1000 + }, + "iconRef" : { + "type" : "string" + }, + "id" : { + "type" : "string" + }, + "version" : { + "type" : "string" + }, + "status" : { + "type" : "string", + "enum" : [ "Available", "Locked", "Final" ] + }, + "lockingUser" : { + "type" : "string" + }, + "viewableVersions" : { + "type" : "array", + "items" : { + "type" : "string" + } + }, + "finalVersions" : { + "type" : "array", + "items" : { + "type" : "string" + } + } + } + }, + "VendorLicenseModelRequest" : { + "type" : "object", + "required" : [ "description", "iconRef", "vendorName" ], + "properties" : { + "vendorName" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 25 + }, + "description" : { + "type" : "string", + "minLength" : 0, + "maxLength" : 1000 + }, + "iconRef" : { + "type" : "string" + } + } + }, + "VersionSoftwareProductActionRequestDto" : { + "type" : "object", + "properties" : { + "action" : { + "type" : "string", + "enum" : [ "Checkout", "Undo_Checkout", "Checkin", "Submit", "Create_Package" ] + } + } + }, + "VspCreationDto" : { + "type" : "object", + "properties" : { + "vspId" : { + "type" : "string" + } + } + }, + "VspDescriptionDto" : { + "type" : "object", + "required" : [ "category", "description", "name", "subCategory", "vendorId", "vendorName" ], + "properties" : { + "name" : { + "type" : "string" + }, + "description" : { + "type" : "string" + }, + "icon" : { + "type" : "string" + }, + "category" : { + "type" : "string" + }, + "subCategory" : { + "type" : "string" + }, + "vendorName" : { + "type" : "string" + }, + "vendorId" : { + "type" : "string" + }, + "licensingVersion" : { + "type" : "string" + }, + "licensingData" : { + "$ref" : "#/definitions/LicensingData" + } + } + } + } +} \ No newline at end of file diff --git a/openecomp-be/tools/swagger-ui/assembly/swagger.xml b/openecomp-be/tools/swagger-ui/assembly/swagger.xml new file mode 100644 index 0000000000..769cc64840 --- /dev/null +++ b/openecomp-be/tools/swagger-ui/assembly/swagger.xml @@ -0,0 +1,76 @@ + + + war + + false + + + + css + /css + + + fonts + /fonts + + + images + /images + + + lang + /lang + + + lib + /lib + + + WEB-INF + /WEB-INF + + + . + / + + index.html + o2c.html + swagger-ui.js + swagger-ui.min.js + + + + ./target + /css + + ${ncso.style.css.file} + + + + ./target + /fonts + + SourceSansPro-Light.otf + SourceSansPro-Regular.otf + SourceSansPro-Semibold.otf + + + + ./target + / + + ${api.json.file} + + + + ./target + /images + + favicon.ico + + + + \ No newline at end of file diff --git a/openecomp-be/tools/swagger-ui/css/ncso-style.css b/openecomp-be/tools/swagger-ui/css/ncso-style.css new file mode 100644 index 0000000000..fd1283918f --- /dev/null +++ b/openecomp-be/tools/swagger-ui/css/ncso-style.css @@ -0,0 +1,8659 @@ +/*! + * Bootstrap v3.3.2 (http://getbootstrap.com) + * Copyright 2011-2015 Twitter, Inc. + * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) + */ +/*! normalize.css v3.0.2 | MIT License | git.io/normalize */ +html { + font-family: sans-serif; + -webkit-text-size-adjust: 100%; + -ms-text-size-adjust: 100%; } + +body { + margin: 0; } + +article, aside, details, figcaption, figure, footer, header, hgroup, main, menu, nav, section, summary { + display: block; } + +audio, canvas, progress, video { + display: inline-block; + vertical-align: baseline; } + +audio:not([controls]) { + display: none; + height: 0; } + +[hidden], template { + display: none; } + +a { + background-color: transparent; } + +a:active, a:hover { + outline: 0; } + +abbr[title] { + border-bottom: 1px dotted; } + +b, strong { + font-weight: 700; } + +dfn { + font-style: italic; } + +h1 { + margin: .67em 0; + font-size: 2em; } + +mark { + color: #000; + background: #ff0; } + +small { + font-size: 80%; } + +sub, sup { + position: relative; + font-size: 75%; + line-height: 0; + vertical-align: baseline; } + +sup { + top: -.5em; } + +sub { + bottom: -.25em; } + +img { + border: 0; } + +svg:not(:root) { + overflow: hidden; } + +figure { + margin: 1em 40px; } + +hr { + height: 0; + -webkit-box-sizing: content-box; + -moz-box-sizing: content-box; + box-sizing: content-box; } + +pre { + overflow: auto; } + +code, kbd, pre, samp { + font-family: monospace, monospace; + font-size: 1em; } + +button, input, optgroup, select, textarea { + margin: 0; + font: inherit; + color: inherit; } + +button { + overflow: visible; } + +button, select { + text-transform: none; } + +button, html input[type=button], input[type=reset], input[type=submit] { + -webkit-appearance: button; + cursor: pointer; } + +button[disabled], html input[disabled] { + cursor: default; } + +button::-moz-focus-inner, input::-moz-focus-inner { + padding: 0; + border: 0; } + +input { + line-height: normal; } + +input[type=checkbox], input[type=radio] { + -webkit-box-sizing: border-box; + -moz-box-sizing: border-box; + box-sizing: border-box; + padding: 0; } + +input[type=number]::-webkit-inner-spin-button, input[type=number]::-webkit-outer-spin-button { + height: auto; } + +input[type=search] { + -webkit-box-sizing: content-box; + -moz-box-sizing: content-box; + box-sizing: content-box; + -webkit-appearance: textfield; } + +input[type=search]::-webkit-search-cancel-button, input[type=search]::-webkit-search-decoration { + -webkit-appearance: none; } + +fieldset { + padding: 0.35em 0.625em 0.75em; + margin: 0 2px; + border: 1px solid silver; } + +legend { + padding: 0; + border: 0; } + +textarea { + overflow: auto; } + +optgroup { + font-weight: 700; } + +table { + border-spacing: 0; + border-collapse: collapse; } + +td, th { + padding: 0; } + +/*! Source: https://github.com/h5bp/html5-boilerplate/blob/master/src/css/main.css */ +@media print { + *, :after, :before { + color: #000 !important; + text-shadow: none !important; + background: 0 0 !important; + -webkit-box-shadow: none !important; + box-shadow: none !important; } + a, a:visited { + text-decoration: underline; } + a[href]:after { + content: " (" attr(href) ")"; } + abbr[title]:after { + content: " (" attr(title) ")"; } + a[href^="javascript:"]:after, a[href^="#"]:after { + content: ""; } + blockquote, pre { + border: 1px solid #999; + page-break-inside: avoid; } + thead { + display: table-header-group; } + img, tr { + page-break-inside: avoid; } + img { + max-width: 100% !important; } + h2, h3, p { + orphans: 3; + widows: 3; } + h2, h3 { + page-break-after: avoid; } + select { + background: #fff !important; } + .navbar { + display: none; } + .btn > .caret, .dropup > .btn > .caret { + border-top-color: #000 !important; } } + +/*@font-face { + font-family: 'Glyphicons Halflings'; + src: url(../fonts/glyphicons-halflings-regular.eot); + src: url(../fonts/glyphicons-halflings-regular.eot?#iefix) format('embedded-opentype'), url(../fonts/glyphicons-halflings-regular.woff2) format('woff2'), url(../fonts/glyphicons-halflings-regular.woff) format('woff'), url(../fonts/glyphicons-halflings-regular.ttf) format('truetype'), url(../fonts/glyphicons-halflings-regular.svg#glyphicons_halflingsregular) format('svg') +}*/ +.glyphicon { + position: relative; + top: 1px; + display: inline-block; + font-family: 'Glyphicons Halflings'; + font-style: normal; + font-weight: 400; + line-height: 1; + -webkit-font-smoothing: antialiased; + -moz-osx-font-smoothing: grayscale; } + +.glyphicon-asterisk:before { + content: "\2a"; } + +.glyphicon-plus:before { + content: "\2b"; } + +.glyphicon-eur:before, .glyphicon-euro:before { + content: "\20ac"; } + +.glyphicon-minus:before { + content: "\2212"; } + +.glyphicon-cloud:before { + content: "\2601"; } + +.glyphicon-envelope:before { + content: "\2709"; } + +.glyphicon-pencil:before { + content: "\270f"; } + +.glyphicon-glass:before { + content: "\e001"; } + +.glyphicon-music:before { + content: "\e002"; } + +.glyphicon-search:before { + content: "\e003"; } + +.glyphicon-heart:before { + content: "\e005"; } + +.glyphicon-star:before { + content: "\e006"; } + +.glyphicon-star-empty:before { + content: "\e007"; } + +.glyphicon-user:before { + content: "\e008"; } + +.glyphicon-film:before { + content: "\e009"; } + +.glyphicon-th-large:before { + content: "\e010"; } + +.glyphicon-th:before { + content: "\e011"; } + +.glyphicon-th-list:before { + content: "\e012"; } + +.glyphicon-ok:before { + content: "\e013"; } + +.glyphicon-remove:before { + content: "\e014"; } + +.glyphicon-zoom-in:before { + content: "\e015"; } + +.glyphicon-zoom-out:before { + content: "\e016"; } + +.glyphicon-off:before { + content: "\e017"; } + +.glyphicon-signal:before { + content: "\e018"; } + +.glyphicon-cog:before { + content: "\e019"; } + +.glyphicon-trash:before { + content: "\e020"; } + +.glyphicon-home:before { + content: "\e021"; } + +.glyphicon-file:before { + content: "\e022"; } + +.glyphicon-time:before { + content: "\e023"; } + +.glyphicon-road:before { + content: "\e024"; } + +.glyphicon-download-alt:before { + content: "\e025"; } + +.glyphicon-download:before { + content: "\e026"; } + +.glyphicon-upload:before { + content: "\e027"; } + +.glyphicon-inbox:before { + content: "\e028"; } + +.glyphicon-play-circle:before { + content: "\e029"; } + +.glyphicon-repeat:before { + content: "\e030"; } + +.glyphicon-refresh:before { + content: "\e031"; } + +.glyphicon-list-alt:before { + content: "\e032"; } + +.glyphicon-lock:before { + content: "\e033"; } + +.glyphicon-flag:before { + content: "\e034"; } + +.glyphicon-headphones:before { + content: "\e035"; } + +.glyphicon-volume-off:before { + content: "\e036"; } + +.glyphicon-volume-down:before { + content: "\e037"; } + +.glyphicon-volume-up:before { + content: "\e038"; } + +.glyphicon-qrcode:before { + content: "\e039"; } + +.glyphicon-barcode:before { + content: "\e040"; } + +.glyphicon-tag:before { + content: "\e041"; } + +.glyphicon-tags:before { + content: "\e042"; } + +.glyphicon-book:before { + content: "\e043"; } + +.glyphicon-bookmark:before { + content: "\e044"; } + +.glyphicon-print:before { + content: "\e045"; } + +.glyphicon-camera:before { + content: "\e046"; } + +.glyphicon-font:before { + content: "\e047"; } + +.glyphicon-bold:before { + content: "\e048"; } + +.glyphicon-italic:before { + content: "\e049"; } + +.glyphicon-text-height:before { + content: "\e050"; } + +.glyphicon-text-width:before { + content: "\e051"; } + +.glyphicon-align-left:before { + content: "\e052"; } + +.glyphicon-align-center:before { + content: "\e053"; } + +.glyphicon-align-right:before { + content: "\e054"; } + +.glyphicon-align-justify:before { + content: "\e055"; } + +.glyphicon-list:before { + content: "\e056"; } + +.glyphicon-indent-left:before { + content: "\e057"; } + +.glyphicon-indent-right:before { + content: "\e058"; } + +.glyphicon-facetime-video:before { + content: "\e059"; } + +.glyphicon-picture:before { + content: "\e060"; } + +.glyphicon-map-marker:before { + content: "\e062"; } + +.glyphicon-adjust:before { + content: "\e063"; } + +.glyphicon-tint:before { + content: "\e064"; } + +.glyphicon-edit:before { + content: "\e065"; } + +.glyphicon-share:before { + content: "\e066"; } + +.glyphicon-check:before { + content: "\e067"; } + +.glyphicon-move:before { + content: "\e068"; } + +.glyphicon-step-backward:before { + content: "\e069"; } + +.glyphicon-fast-backward:before { + content: "\e070"; } + +.glyphicon-backward:before { + content: "\e071"; } + +.glyphicon-play:before { + content: "\e072"; } + +.glyphicon-pause:before { + content: "\e073"; } + +.glyphicon-stop:before { + content: "\e074"; } + +.glyphicon-forward:before { + content: "\e075"; } + +.glyphicon-fast-forward:before { + content: "\e076"; } + +.glyphicon-step-forward:before { + content: "\e077"; } + +.glyphicon-eject:before { + content: "\e078"; } + +.glyphicon-chevron-left:before { + content: "\e079"; } + +.glyphicon-chevron-right:before { + content: "\e080"; } + +.glyphicon-plus-sign:before { + content: "\e081"; } + +.glyphicon-minus-sign:before { + content: "\e082"; } + +.glyphicon-remove-sign:before { + content: "\e083"; } + +.glyphicon-ok-sign:before { + content: "\e084"; } + +.glyphicon-question-sign:before { + content: "\e085"; } + +.glyphicon-info-sign:before { + content: "\e086"; } + +.glyphicon-screenshot:before { + content: "\e087"; } + +.glyphicon-remove-circle:before { + content: "\e088"; } + +.glyphicon-ok-circle:before { + content: "\e089"; } + +.glyphicon-ban-circle:before { + content: "\e090"; } + +.glyphicon-arrow-left:before { + content: "\e091"; } + +.glyphicon-arrow-right:before { + content: "\e092"; } + +.glyphicon-arrow-up:before { + content: "\e093"; } + +.glyphicon-arrow-down:before { + content: "\e094"; } + +.glyphicon-share-alt:before { + content: "\e095"; } + +.glyphicon-resize-full:before { + content: "\e096"; } + +.glyphicon-resize-small:before { + content: "\e097"; } + +.glyphicon-exclamation-sign:before { + content: "\e101"; } + +.glyphicon-gift:before { + content: "\e102"; } + +.glyphicon-leaf:before { + content: "\e103"; } + +.glyphicon-fire:before { + content: "\e104"; } + +.glyphicon-eye-open:before { + content: "\e105"; } + +.glyphicon-eye-close:before { + content: "\e106"; } + +.glyphicon-warning-sign:before { + content: "\e107"; } + +.glyphicon-plane:before { + content: "\e108"; } + +.glyphicon-calendar:before { + content: "\e109"; } + +.glyphicon-random:before { + content: "\e110"; } + +.glyphicon-comment:before { + content: "\e111"; } + +.glyphicon-magnet:before { + content: "\e112"; } + +.glyphicon-chevron-up:before { + content: "\e113"; } + +.glyphicon-chevron-down:before { + content: "\e114"; } + +.glyphicon-retweet:before { + content: "\e115"; } + +.glyphicon-shopping-cart:before { + content: "\e116"; } + +.glyphicon-folder-close:before { + content: "\e117"; } + +.glyphicon-folder-open:before { + content: "\e118"; } + +.glyphicon-resize-vertical:before { + content: "\e119"; } + +.glyphicon-resize-horizontal:before { + content: "\e120"; } + +.glyphicon-hdd:before { + content: "\e121"; } + +.glyphicon-bullhorn:before { + content: "\e122"; } + +.glyphicon-bell:before { + content: "\e123"; } + +.glyphicon-certificate:before { + content: "\e124"; } + +.glyphicon-thumbs-up:before { + content: "\e125"; } + +.glyphicon-thumbs-down:before { + content: "\e126"; } + +.glyphicon-hand-right:before { + content: "\e127"; } + +.glyphicon-hand-left:before { + content: "\e128"; } + +.glyphicon-hand-up:before { + content: "\e129"; } + +.glyphicon-hand-down:before { + content: "\e130"; } + +.glyphicon-circle-arrow-right:before { + content: "\e131"; } + +.glyphicon-circle-arrow-left:before { + content: "\e132"; } + +.glyphicon-circle-arrow-up:before { + content: "\e133"; } + +.glyphicon-circle-arrow-down:before { + content: "\e134"; } + +.glyphicon-globe:before { + content: "\e135"; } + +.glyphicon-wrench:before { + content: "\e136"; } + +.glyphicon-tasks:before { + content: "\e137"; } + +.glyphicon-filter:before { + content: "\e138"; } + +.glyphicon-briefcase:before { + content: "\e139"; } + +.glyphicon-fullscreen:before { + content: "\e140"; } + +.glyphicon-dashboard:before { + content: "\e141"; } + +.glyphicon-paperclip:before { + content: "\e142"; } + +.glyphicon-heart-empty:before { + content: "\e143"; } + +.glyphicon-link:before { + content: "\e144"; } + +.glyphicon-phone:before { + content: "\e145"; } + +.glyphicon-pushpin:before { + content: "\e146"; } + +.glyphicon-usd:before { + content: "\e148"; } + +.glyphicon-gbp:before { + content: "\e149"; } + +.glyphicon-sort:before { + content: "\e150"; } + +.glyphicon-sort-by-alphabet:before { + content: "\e151"; } + +.glyphicon-sort-by-alphabet-alt:before { + content: "\e152"; } + +.glyphicon-sort-by-order:before { + content: "\e153"; } + +.glyphicon-sort-by-order-alt:before { + content: "\e154"; } + +.glyphicon-sort-by-attributes:before { + content: "\e155"; } + +.glyphicon-sort-by-attributes-alt:before { + content: "\e156"; } + +.glyphicon-unchecked:before { + content: "\e157"; } + +.glyphicon-expand:before { + content: "\e158"; } + +.glyphicon-collapse-down:before { + content: "\e159"; } + +.glyphicon-collapse-up:before { + content: "\e160"; } + +.glyphicon-log-in:before { + content: "\e161"; } + +.glyphicon-flash:before { + content: "\e162"; } + +.glyphicon-log-out:before { + content: "\e163"; } + +.glyphicon-new-window:before { + content: "\e164"; } + +.glyphicon-record:before { + content: "\e165"; } + +.glyphicon-save:before { + content: "\e166"; } + +.glyphicon-open:before { + content: "\e167"; } + +.glyphicon-saved:before { + content: "\e168"; } + +.glyphicon-import:before { + content: "\e169"; } + +.glyphicon-export:before { + content: "\e170"; } + +.glyphicon-send:before { + content: "\e171"; } + +.glyphicon-floppy-disk:before { + content: "\e172"; } + +.glyphicon-floppy-saved:before { + content: "\e173"; } + +.glyphicon-floppy-remove:before { + content: "\e174"; } + +.glyphicon-floppy-save:before { + content: "\e175"; } + +.glyphicon-floppy-open:before { + content: "\e176"; } + +.glyphicon-credit-card:before { + content: "\e177"; } + +.glyphicon-transfer:before { + content: "\e178"; } + +.glyphicon-cutlery:before { + content: "\e179"; } + +.glyphicon-header:before { + content: "\e180"; } + +.glyphicon-compressed:before { + content: "\e181"; } + +.glyphicon-earphone:before { + content: "\e182"; } + +.glyphicon-phone-alt:before { + content: "\e183"; } + +.glyphicon-tower:before { + content: "\e184"; } + +.glyphicon-stats:before { + content: "\e185"; } + +.glyphicon-sd-video:before { + content: "\e186"; } + +.glyphicon-hd-video:before { + content: "\e187"; } + +.glyphicon-subtitles:before { + content: "\e188"; } + +.glyphicon-sound-stereo:before { + content: "\e189"; } + +.glyphicon-sound-dolby:before { + content: "\e190"; } + +.glyphicon-sound-5-1:before { + content: "\e191"; } + +.glyphicon-sound-6-1:before { + content: "\e192"; } + +.glyphicon-sound-7-1:before { + content: "\e193"; } + +.glyphicon-copyright-mark:before { + content: "\e194"; } + +.glyphicon-registration-mark:before { + content: "\e195"; } + +.glyphicon-cloud-download:before { + content: "\e197"; } + +.glyphicon-cloud-upload:before { + content: "\e198"; } + +.glyphicon-tree-conifer:before { + content: "\e199"; } + +.glyphicon-tree-deciduous:before { + content: "\e200"; } + +.glyphicon-cd:before { + content: "\e201"; } + +.glyphicon-save-file:before { + content: "\e202"; } + +.glyphicon-open-file:before { + content: "\e203"; } + +.glyphicon-level-up:before { + content: "\e204"; } + +.glyphicon-copy:before { + content: "\e205"; } + +.glyphicon-paste:before { + content: "\e206"; } + +.glyphicon-alert:before { + content: "\e209"; } + +.glyphicon-equalizer:before { + content: "\e210"; } + +.glyphicon-king:before { + content: "\e211"; } + +.glyphicon-queen:before { + content: "\e212"; } + +.glyphicon-pawn:before { + content: "\e213"; } + +.glyphicon-bishop:before { + content: "\e214"; } + +.glyphicon-knight:before { + content: "\e215"; } + +.glyphicon-baby-formula:before { + content: "\e216"; } + +.glyphicon-tent:before { + content: "\26fa"; } + +.glyphicon-blackboard:before { + content: "\e218"; } + +.glyphicon-bed:before { + content: "\e219"; } + +.glyphicon-apple:before { + content: "\f8ff"; } + +.glyphicon-erase:before { + content: "\e221"; } + +.glyphicon-hourglass:before { + content: "\231b"; } + +.glyphicon-lamp:before { + content: "\e223"; } + +.glyphicon-duplicate:before { + content: "\e224"; } + +.glyphicon-piggy-bank:before { + content: "\e225"; } + +.glyphicon-scissors:before { + content: "\e226"; } + +.glyphicon-bitcoin:before { + content: "\e227"; } + +.glyphicon-yen:before { + content: "\00a5"; } + +.glyphicon-ruble:before { + content: "\20bd"; } + +.glyphicon-scale:before { + content: "\e230"; } + +.glyphicon-ice-lolly:before { + content: "\e231"; } + +.glyphicon-ice-lolly-tasted:before { + content: "\e232"; } + +.glyphicon-education:before { + content: "\e233"; } + +.glyphicon-option-horizontal:before { + content: "\e234"; } + +.glyphicon-option-vertical:before { + content: "\e235"; } + +.glyphicon-menu-hamburger:before { + content: "\e236"; } + +.glyphicon-modal-window:before { + content: "\e237"; } + +.glyphicon-oil:before { + content: "\e238"; } + +.glyphicon-grain:before { + content: "\e239"; } + +.glyphicon-sunglasses:before { + content: "\e240"; } + +.glyphicon-text-size:before { + content: "\e241"; } + +.glyphicon-text-color:before { + content: "\e242"; } + +.glyphicon-text-background:before { + content: "\e243"; } + +.glyphicon-object-align-top:before { + content: "\e244"; } + +.glyphicon-object-align-bottom:before { + content: "\e245"; } + +.glyphicon-object-align-horizontal:before { + content: "\e246"; } + +.glyphicon-object-align-left:before { + content: "\e247"; } + +.glyphicon-object-align-vertical:before { + content: "\e248"; } + +.glyphicon-object-align-right:before { + content: "\e249"; } + +.glyphicon-triangle-right:before { + content: "\e250"; } + +.glyphicon-triangle-left:before { + content: "\e251"; } + +.glyphicon-triangle-bottom:before { + content: "\e252"; } + +.glyphicon-triangle-top:before { + content: "\e253"; } + +.glyphicon-console:before { + content: "\e254"; } + +.glyphicon-superscript:before { + content: "\e255"; } + +.glyphicon-subscript:before { + content: "\e256"; } + +.glyphicon-menu-left:before { + content: "\e257"; } + +.glyphicon-menu-right:before { + content: "\e258"; } + +.glyphicon-menu-down:before { + content: "\e259"; } + +.glyphicon-menu-up:before { + content: "\e260"; } + +/** { + -webkit-box-sizing: border-box; + -moz-box-sizing: border-box; + box-sizing: border-box +} +*/ +:after, :before { + -webkit-box-sizing: border-box; + -moz-box-sizing: border-box; + box-sizing: border-box; } + +html { + font-size: 10px; + -webkit-tap-highlight-color: transparent; } + +body { + color: #333; + background-color: #fff; } + +button, input, select, textarea { + font-family: inherit; + font-size: inherit; + line-height: inherit; } + +a { + color: #337ab7; + text-decoration: none; } + +a:focus, a:hover { + color: #23527c; + text-decoration: underline; } + +a:focus { + outline: thin dotted; + outline: 5px auto -webkit-focus-ring-color; + outline-offset: -2px; } + +figure { + margin: 0; } + +img { + vertical-align: middle; } + +.carousel-inner > .item > a > img, .carousel-inner > .item > img, .img-responsive, .thumbnail a > img, .thumbnail > img { + display: block; + max-width: 100%; + height: auto; } + +.img-rounded { + border-radius: 6px; } + +.img-thumbnail { + display: inline-block; + max-width: 100%; + height: auto; + padding: 4px; + line-height: 1.42857143; + background-color: #fff; + border: 1px solid #ddd; + border-radius: 4px; + -webkit-transition: all 0.2s ease-in-out; + -o-transition: all 0.2s ease-in-out; + transition: all 0.2s ease-in-out; } + +.img-circle { + border-radius: 50%; } + +hr { + margin-top: 20px; + margin-bottom: 20px; + border: 0; + border-top: 1px solid #eee; } + +.sr-only { + position: absolute; + width: 1px; + height: 1px; + padding: 0; + margin: -1px; + overflow: hidden; + clip: rect(0, 0, 0, 0); + border: 0; } + +.sr-only-focusable:active, .sr-only-focusable:focus { + position: static; + width: auto; + height: auto; + margin: 0; + overflow: visible; + clip: auto; } + +.h1, .h2, .h3, .h4, .h5, .h6, h1, h2, h3, h4, h5, h6 { + font-family: inherit; + font-weight: 500; + line-height: 1.1; + color: inherit; } + +.h1 .small, .h1 small, .h2 .small, .h2 small, .h3 .small, .h3 small, .h4 .small, .h4 small, .h5 .small, .h5 small, .h6 .small, .h6 small, h1 .small, h1 small, h2 .small, h2 small, h3 .small, h3 small, h4 .small, h4 small, h5 .small, h5 small, h6 .small, h6 small { + font-weight: 400; + line-height: 1; + color: #777; } + +.h1, .h2, .h3, h1, h2, h3 { + margin-top: 20px; + margin-bottom: 10px; } + +.h1 .small, .h1 small, .h2 .small, .h2 small, .h3 .small, .h3 small, h1 .small, h1 small, h2 .small, h2 small, h3 .small, h3 small { + font-size: 65%; } + +.h4, .h5, .h6, h4, h5, h6 { + margin-top: 10px; + margin-bottom: 10px; } + +.h4 .small, .h4 small, .h5 .small, .h5 small, .h6 .small, .h6 small, h4 .small, h4 small, h5 .small, h5 small, h6 .small, h6 small { + font-size: 75%; } + +.h1, h1 { + font-size: 36px; } + +.h2, h2 { + font-size: 30px; } + +.h3, h3 { + font-size: 24px; } + +.h4, h4 { + font-size: 18px; } + +.h5, h5 { + font-size: 14px; } + +.h6, h6 { + font-size: 12px; } + +p { + margin: 0 0 10px; } + +.lead { + margin-bottom: 20px; + font-size: 16px; + font-weight: 300; + line-height: 1.4; } + +@media (min-width: 768px) { + .lead { + font-size: 21px; } } + +.small, small { + font-size: 85%; } + +.mark, mark { + padding: .2em; + background-color: #fcf8e3; } + +.text-left { + text-align: left; } + +.text-right { + text-align: right; } + +.text-center { + text-align: center; } + +.text-justify { + text-align: justify; } + +.text-nowrap { + white-space: nowrap; } + +.text-lowercase { + text-transform: lowercase; } + +.text-uppercase { + text-transform: uppercase; } + +.text-capitalize { + text-transform: capitalize; } + +.text-muted { + color: #777; } + +.text-primary { + color: #337ab7; } + +a.text-primary:hover { + color: #286090; } + +.text-success { + color: #3c763d; } + +a.text-success:hover { + color: #2b542c; } + +.text-info { + color: #31708f; } + +a.text-info:hover { + color: #245269; } + +.text-warning { + color: #8a6d3b; } + +a.text-warning:hover { + color: #66512c; } + +.text-danger { + color: #a94442; } + +a.text-danger:hover { + color: #843534; } + +.bg-primary { + color: #fff; + background-color: #337ab7; } + +a.bg-primary:hover { + background-color: #286090; } + +.bg-success { + background-color: #dff0d8; } + +a.bg-success:hover { + background-color: #c1e2b3; } + +.bg-info { + background-color: #d9edf7; } + +a.bg-info:hover { + background-color: #afd9ee; } + +.bg-warning { + background-color: #fcf8e3; } + +a.bg-warning:hover { + background-color: #f7ecb5; } + +.bg-danger { + background-color: #f2dede; } + +a.bg-danger:hover { + background-color: #e4b9b9; } + +.page-header { + padding-bottom: 9px; + margin: 40px 0 20px; + border-bottom: 1px solid #eee; } + +ol, ul { + margin-top: 0; + margin-bottom: 10px; } + +ol ol, ol ul, ul ol, ul ul { + margin-bottom: 0; } + +.list-unstyled { + padding-left: 0; + list-style: none; } + +.list-inline { + padding-left: 0; + margin-left: -5px; + list-style: none; } + +.list-inline > li { + display: inline-block; + padding-right: 5px; + padding-left: 5px; } + +dl { + margin-top: 0; + margin-bottom: 20px; } + +dd, dt { + line-height: 1.42857143; } + +dt { + font-weight: 700; } + +dd { + margin-left: 0; } + +@media (min-width: 768px) { + .dl-horizontal dt { + float: left; + width: 160px; + overflow: hidden; + clear: left; + text-align: right; + text-overflow: ellipsis; + white-space: nowrap; } + .dl-horizontal dd { + margin-left: 180px; } } + +abbr[data-original-title], abbr[title] { + cursor: help; + border-bottom: 1px dotted #777; } + +.initialism { + font-size: 90%; + text-transform: uppercase; } + +blockquote { + padding: 10px 20px; + margin: 0 0 20px; + font-size: 17.5px; + border-left: 5px solid #eee; } + +blockquote ol:last-child, blockquote p:last-child, blockquote ul:last-child { + margin-bottom: 0; } + +blockquote .small, blockquote footer, blockquote small { + display: block; + font-size: 80%; + line-height: 1.42857143; + color: #777; } + +blockquote .small:before, blockquote footer:before, blockquote small:before { + content: '\2014 \00A0'; } + +.blockquote-reverse, blockquote.pull-right { + padding-right: 15px; + padding-left: 0; + text-align: right; + border-right: 5px solid #eee; + border-left: 0; } + +.blockquote-reverse .small:before, .blockquote-reverse footer:before, .blockquote-reverse small:before, blockquote.pull-right .small:before, blockquote.pull-right footer:before, blockquote.pull-right small:before { + content: ''; } + +.blockquote-reverse .small:after, .blockquote-reverse footer:after, .blockquote-reverse small:after, blockquote.pull-right .small:after, blockquote.pull-right footer:after, blockquote.pull-right small:after { + content: '\00A0 \2014'; } + +address { + margin-bottom: 20px; + font-style: normal; + line-height: 1.42857143; } + +code, kbd, pre, samp { + font-family: Menlo, Monaco, Consolas, "Courier New", monospace; } + +code { + padding: 2px 4px; + font-size: 90%; + color: #c7254e; + background-color: #f9f2f4; + border-radius: 4px; } + +kbd { + padding: 2px 4px; + font-size: 90%; + color: #fff; + background-color: #333; + border-radius: 3px; + -webkit-box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.25); + box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.25); } + +kbd kbd { + padding: 0; + font-size: 100%; + font-weight: 700; + -webkit-box-shadow: none; + box-shadow: none; } + +pre { + display: block; + padding: 9.5px; + margin: 0 0 10px; + font-size: 13px; + line-height: 1.42857143; + color: #333; + word-break: break-all; + word-wrap: break-word; + background-color: #f5f5f5; + border: 1px solid #ccc; + border-radius: 4px; } + +pre code { + padding: 0; + font-size: inherit; + color: inherit; + white-space: pre-wrap; + background-color: transparent; + border-radius: 0; } + +.pre-scrollable { + max-height: 340px; + overflow-y: scroll; } + +.container { + padding-right: 15px; + padding-left: 15px; + margin-right: auto; + margin-left: auto; } + +@media (min-width: 768px) { + .container { + width: 750px; } } + +@media (min-width: 992px) { + .container { + width: 970px; } } + +@media (min-width: 1200px) { + .container { + width: 1170px; } } + +.container-fluid { + padding-right: 15px; + padding-left: 15px; + margin-right: auto; + margin-left: auto; } + +.row { + margin-right: -15px; + margin-left: -15px; } + +.col-lg-1, .col-lg-10, .col-lg-11, .col-lg-12, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-md-1, .col-md-10, .col-md-11, .col-md-12, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-sm-1, .col-sm-10, .col-sm-11, .col-sm-12, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-xs-1, .col-xs-10, .col-xs-11, .col-xs-12, .col-xs-2, .col-xs-3, .col-xs-4, .col-xs-5, .col-xs-6, .col-xs-7, .col-xs-8, .col-xs-9 { + position: relative; + min-height: 1px; + padding-right: 15px; + padding-left: 15px; } + +.col-xs-1, .col-xs-10, .col-xs-11, .col-xs-12, .col-xs-2, .col-xs-3, .col-xs-4, .col-xs-5, .col-xs-6, .col-xs-7, .col-xs-8, .col-xs-9 { + float: left; } + +.col-xs-12 { + width: 100%; } + +.col-xs-11 { + width: 91.66666667%; } + +.col-xs-10 { + width: 83.33333333%; } + +.col-xs-9 { + width: 75%; } + +.col-xs-8 { + width: 66.66666667%; } + +.col-xs-7 { + width: 58.33333333%; } + +.col-xs-6 { + width: 50%; } + +.col-xs-5 { + width: 41.66666667%; } + +.col-xs-4 { + width: 33.33333333%; } + +.col-xs-3 { + width: 25%; } + +.col-xs-2 { + width: 16.66666667%; } + +.col-xs-1 { + width: 8.33333333%; } + +.col-xs-pull-12 { + right: 100%; } + +.col-xs-pull-11 { + right: 91.66666667%; } + +.col-xs-pull-10 { + right: 83.33333333%; } + +.col-xs-pull-9 { + right: 75%; } + +.col-xs-pull-8 { + right: 66.66666667%; } + +.col-xs-pull-7 { + right: 58.33333333%; } + +.col-xs-pull-6 { + right: 50%; } + +.col-xs-pull-5 { + right: 41.66666667%; } + +.col-xs-pull-4 { + right: 33.33333333%; } + +.col-xs-pull-3 { + right: 25%; } + +.col-xs-pull-2 { + right: 16.66666667%; } + +.col-xs-pull-1 { + right: 8.33333333%; } + +.col-xs-pull-0 { + right: auto; } + +.col-xs-push-12 { + left: 100%; } + +.col-xs-push-11 { + left: 91.66666667%; } + +.col-xs-push-10 { + left: 83.33333333%; } + +.col-xs-push-9 { + left: 75%; } + +.col-xs-push-8 { + left: 66.66666667%; } + +.col-xs-push-7 { + left: 58.33333333%; } + +.col-xs-push-6 { + left: 50%; } + +.col-xs-push-5 { + left: 41.66666667%; } + +.col-xs-push-4 { + left: 33.33333333%; } + +.col-xs-push-3 { + left: 25%; } + +.col-xs-push-2 { + left: 16.66666667%; } + +.col-xs-push-1 { + left: 8.33333333%; } + +.col-xs-push-0 { + left: auto; } + +.col-xs-offset-12 { + margin-left: 100%; } + +.col-xs-offset-11 { + margin-left: 91.66666667%; } + +.col-xs-offset-10 { + margin-left: 83.33333333%; } + +.col-xs-offset-9 { + margin-left: 75%; } + +.col-xs-offset-8 { + margin-left: 66.66666667%; } + +.col-xs-offset-7 { + margin-left: 58.33333333%; } + +.col-xs-offset-6 { + margin-left: 50%; } + +.col-xs-offset-5 { + margin-left: 41.66666667%; } + +.col-xs-offset-4 { + margin-left: 33.33333333%; } + +.col-xs-offset-3 { + margin-left: 25%; } + +.col-xs-offset-2 { + margin-left: 16.66666667%; } + +.col-xs-offset-1 { + margin-left: 8.33333333%; } + +.col-xs-offset-0 { + margin-left: 0; } + +@media (min-width: 768px) { + .col-sm-1, .col-sm-10, .col-sm-11, .col-sm-12, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9 { + float: left; } + .col-sm-12 { + width: 98%; } + .col-sm-11 { + width: 91.66666667%; } + .col-sm-10 { + width: 83.33333333%; } + .col-sm-9 { + width: 75%; } + .col-sm-8 { + width: 66.66666667%; } + .col-sm-7 { + width: 58.33333333%; } + .col-sm-6 { + width: 48%; } + .col-sm-5 { + width: 41.66666667%; } + .col-sm-4 { + width: 33.33333333%; } + .col-sm-3 { + width: 25%; } + .col-sm-2 { + width: 16.66666667%; } + .col-sm-1 { + width: 8.33333333%; } + .col-sm-pull-12 { + right: 100%; } + .col-sm-pull-11 { + right: 91.66666667%; } + .col-sm-pull-10 { + right: 83.33333333%; } + .col-sm-pull-9 { + right: 75%; } + .col-sm-pull-8 { + right: 66.66666667%; } + .col-sm-pull-7 { + right: 58.33333333%; } + .col-sm-pull-6 { + right: 50%; } + .col-sm-pull-5 { + right: 41.66666667%; } + .col-sm-pull-4 { + right: 33.33333333%; } + .col-sm-pull-3 { + right: 25%; } + .col-sm-pull-2 { + right: 16.66666667%; } + .col-sm-pull-1 { + right: 8.33333333%; } + .col-sm-pull-0 { + right: auto; } + .col-sm-push-12 { + left: 100%; } + .col-sm-push-11 { + left: 91.66666667%; } + .col-sm-push-10 { + left: 83.33333333%; } + .col-sm-push-9 { + left: 75%; } + .col-sm-push-8 { + left: 66.66666667%; } + .col-sm-push-7 { + left: 58.33333333%; } + .col-sm-push-6 { + left: 50%; } + .col-sm-push-5 { + left: 41.66666667%; } + .col-sm-push-4 { + left: 33.33333333%; } + .col-sm-push-3 { + left: 25%; } + .col-sm-push-2 { + left: 16.66666667%; } + .col-sm-push-1 { + left: 8.33333333%; } + .col-sm-push-0 { + left: auto; } + .col-sm-offset-12 { + margin-left: 100%; } + .col-sm-offset-11 { + margin-left: 91.66666667%; } + .col-sm-offset-10 { + margin-left: 83.33333333%; } + .col-sm-offset-9 { + margin-left: 75%; } + .col-sm-offset-8 { + margin-left: 66.66666667%; } + .col-sm-offset-7 { + margin-left: 58.33333333%; } + .col-sm-offset-6 { + margin-left: 50%; } + .col-sm-offset-5 { + margin-left: 41.66666667%; } + .col-sm-offset-4 { + margin-left: 33.33333333%; } + .col-sm-offset-3 { + margin-left: 25%; } + .col-sm-offset-2 { + margin-left: 16.66666667%; } + .col-sm-offset-1 { + margin-left: 8.33333333%; } + .col-sm-offset-0 { + margin-left: 0; } } + +@media (min-width: 992px) { + .col-md-1, .col-md-10, .col-md-11, .col-md-12, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9 { + float: left; } + .col-md-12 { + width: 100%; } + .col-md-11 { + width: 91.66666667%; } + .col-md-10 { + width: 83.33333333%; } + .col-md-9 { + width: 75%; } + .col-md-8 { + width: 66.66666667%; } + .col-md-7 { + width: 58.33333333%; } + .col-md-6 { + width: 50%; } + .col-md-5 { + width: 41.66666667%; } + .col-md-4 { + width: 33.33333333%; } + .col-md-3 { + width: 25%; } + .col-md-2 { + width: 16.66666667%; } + .col-md-1 { + width: 8.33333333%; } + .col-md-pull-12 { + right: 100%; } + .col-md-pull-11 { + right: 91.66666667%; } + .col-md-pull-10 { + right: 83.33333333%; } + .col-md-pull-9 { + right: 75%; } + .col-md-pull-8 { + right: 66.66666667%; } + .col-md-pull-7 { + right: 58.33333333%; } + .col-md-pull-6 { + right: 50%; } + .col-md-pull-5 { + right: 41.66666667%; } + .col-md-pull-4 { + right: 33.33333333%; } + .col-md-pull-3 { + right: 25%; } + .col-md-pull-2 { + right: 16.66666667%; } + .col-md-pull-1 { + right: 8.33333333%; } + .col-md-pull-0 { + right: auto; } + .col-md-push-12 { + left: 100%; } + .col-md-push-11 { + left: 91.66666667%; } + .col-md-push-10 { + left: 83.33333333%; } + .col-md-push-9 { + left: 75%; } + .col-md-push-8 { + left: 66.66666667%; } + .col-md-push-7 { + left: 58.33333333%; } + .col-md-push-6 { + left: 50%; } + .col-md-push-5 { + left: 41.66666667%; } + .col-md-push-4 { + left: 33.33333333%; } + .col-md-push-3 { + left: 25%; } + .col-md-push-2 { + left: 16.66666667%; } + .col-md-push-1 { + left: 8.33333333%; } + .col-md-push-0 { + left: auto; } + .col-md-offset-12 { + margin-left: 100%; } + .col-md-offset-11 { + margin-left: 91.66666667%; } + .col-md-offset-10 { + margin-left: 83.33333333%; } + .col-md-offset-9 { + margin-left: 75%; } + .col-md-offset-8 { + margin-left: 66.66666667%; } + .col-md-offset-7 { + margin-left: 58.33333333%; } + .col-md-offset-6 { + margin-left: 50%; } + .col-md-offset-5 { + margin-left: 41.66666667%; } + .col-md-offset-4 { + margin-left: 33.33333333%; } + .col-md-offset-3 { + margin-left: 25%; } + .col-md-offset-2 { + margin-left: 16.66666667%; } + .col-md-offset-1 { + margin-left: 8.33333333%; } + .col-md-offset-0 { + margin-left: 0; } } + +@media (min-width: 1200px) { + .col-lg-1, .col-lg-10, .col-lg-11, .col-lg-12, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9 { + float: left; } + .col-lg-12 { + width: 100%; } + .col-lg-11 { + width: 91.66666667%; } + .col-lg-10 { + width: 83.33333333%; } + .col-lg-9 { + width: 75%; } + .col-lg-8 { + width: 66.66666667%; } + .col-lg-7 { + width: 58.33333333%; } + .col-lg-6 { + width: 50%; } + .col-lg-5 { + width: 41.66666667%; } + .col-lg-4 { + width: 33.33333333%; } + .col-lg-3 { + width: 25%; } + .col-lg-2 { + width: 16.66666667%; } + .col-lg-1 { + width: 8.33333333%; } + .col-lg-pull-12 { + right: 100%; } + .col-lg-pull-11 { + right: 91.66666667%; } + .col-lg-pull-10 { + right: 83.33333333%; } + .col-lg-pull-9 { + right: 75%; } + .col-lg-pull-8 { + right: 66.66666667%; } + .col-lg-pull-7 { + right: 58.33333333%; } + .col-lg-pull-6 { + right: 50%; } + .col-lg-pull-5 { + right: 41.66666667%; } + .col-lg-pull-4 { + right: 33.33333333%; } + .col-lg-pull-3 { + right: 25%; } + .col-lg-pull-2 { + right: 16.66666667%; } + .col-lg-pull-1 { + right: 8.33333333%; } + .col-lg-pull-0 { + right: auto; } + .col-lg-push-12 { + left: 100%; } + .col-lg-push-11 { + left: 91.66666667%; } + .col-lg-push-10 { + left: 83.33333333%; } + .col-lg-push-9 { + left: 75%; } + .col-lg-push-8 { + left: 66.66666667%; } + .col-lg-push-7 { + left: 58.33333333%; } + .col-lg-push-6 { + left: 50%; } + .col-lg-push-5 { + left: 41.66666667%; } + .col-lg-push-4 { + left: 33.33333333%; } + .col-lg-push-3 { + left: 25%; } + .col-lg-push-2 { + left: 16.66666667%; } + .col-lg-push-1 { + left: 8.33333333%; } + .col-lg-push-0 { + left: auto; } + .col-lg-offset-12 { + margin-left: 100%; } + .col-lg-offset-11 { + margin-left: 91.66666667%; } + .col-lg-offset-10 { + margin-left: 83.33333333%; } + .col-lg-offset-9 { + margin-left: 75%; } + .col-lg-offset-8 { + margin-left: 66.66666667%; } + .col-lg-offset-7 { + margin-left: 58.33333333%; } + .col-lg-offset-6 { + margin-left: 50%; } + .col-lg-offset-5 { + margin-left: 41.66666667%; } + .col-lg-offset-4 { + margin-left: 33.33333333%; } + .col-lg-offset-3 { + margin-left: 25%; } + .col-lg-offset-2 { + margin-left: 16.66666667%; } + .col-lg-offset-1 { + margin-left: 8.33333333%; } + .col-lg-offset-0 { + margin-left: 0; } } + +table { + background-color: transparent; } + +caption { + padding-top: 8px; + padding-bottom: 8px; + color: #777; + text-align: left; } + +th { + text-align: left; } + +.table { + width: 100%; + max-width: 100%; + margin-bottom: 20px; } + +.table > tbody > tr > td, .table > tbody > tr > th, .table > tfoot > tr > td, .table > tfoot > tr > th, .table > thead > tr > td, .table > thead > tr > th { + padding: 8px; + line-height: 1.42857143; + vertical-align: top; } + +.table > thead > tr > th { + vertical-align: bottom; } + +.table > caption + thead > tr:first-child > td, .table > caption + thead > tr:first-child > th, .table > colgroup + thead > tr:first-child > td, .table > colgroup + thead > tr:first-child > th, .table > thead:first-child > tr:first-child > td, .table > thead:first-child > tr:first-child > th { + border-top: 0; } + +.table .table { + background-color: #fff; } + +.table-condensed > tbody > tr > td, .table-condensed > tbody > tr > th, .table-condensed > tfoot > tr > td, .table-condensed > tfoot > tr > th, .table-condensed > thead > tr > td, .table-condensed > thead > tr > th { + padding: 5px; } + +.table-bordered > thead > tr > td, .table-bordered > thead > tr > th { + border-bottom-width: 1px; } + +table col[class*=col-] { + position: static; + display: table-column; + float: none; } + +table td[class*=col-], table th[class*=col-] { + position: static; + display: table-cell; + float: none; } + +.table-responsive { + min-height: .01%; + overflow-x: auto; } + +@media screen and (max-width: 767px) { + .table-responsive { + width: 100%; + margin-bottom: 15px; + overflow-y: hidden; + -ms-overflow-style: -ms-autohiding-scrollbar; } + .table-responsive > .table { + margin-bottom: 0; } + .table-responsive > .table > tbody > tr > td, .table-responsive > .table > tbody > tr > th, .table-responsive > .table > tfoot > tr > td, .table-responsive > .table > tfoot > tr > th, .table-responsive > .table > thead > tr > td, .table-responsive > .table > thead > tr > th { + white-space: nowrap; } + .table-responsive > .table-bordered { + border: 0; } + .table-responsive > .table-bordered > tbody > tr > td:first-child, .table-responsive > .table-bordered > tbody > tr > th:first-child, .table-responsive > .table-bordered > tfoot > tr > td:first-child, .table-responsive > .table-bordered > tfoot > tr > th:first-child, .table-responsive > .table-bordered > thead > tr > td:first-child, .table-responsive > .table-bordered > thead > tr > th:first-child { + border-left: 0; } + .table-responsive > .table-bordered > tbody > tr > td:last-child, .table-responsive > .table-bordered > tbody > tr > th:last-child, .table-responsive > .table-bordered > tfoot > tr > td:last-child, .table-responsive > .table-bordered > tfoot > tr > th:last-child, .table-responsive > .table-bordered > thead > tr > td:last-child, .table-responsive > .table-bordered > thead > tr > th:last-child { + border-right: 0; } + .table-responsive > .table-bordered > tbody > tr:last-child > td, .table-responsive > .table-bordered > tbody > tr:last-child > th, .table-responsive > .table-bordered > tfoot > tr:last-child > td, .table-responsive > .table-bordered > tfoot > tr:last-child > th { + border-bottom: 0; } } + +input[type=search] { + -webkit-box-sizing: border-box; + -moz-box-sizing: border-box; + box-sizing: border-box; } + +input[type=checkbox], input[type=radio] { + margin: 4px 0 0; + margin-top: 1px \9; + line-height: normal; } + +input[type=range] { + display: block; + width: 100%; } + +select[multiple], select[size] { + height: auto; } + +input[type=file]:focus, input[type=checkbox]:focus, input[type=radio]:focus { + outline: thin dotted; + outline: 5px auto -webkit-focus-ring-color; + outline-offset: -2px; } + +output { + display: block; + padding-top: 7px; + font-size: 14px; + line-height: 1.42857143; + color: #555; } + +.form-control { + display: block; + width: 100%; + height: 34px; + padding: 6px 12px; + font-size: 14px; + line-height: 1.42857143; + color: #555; + background-color: #fff; + background-image: none; + border: 1px solid #ccc; + border-radius: 4px; } + +.form-control:focus { + border-color: #66afe9; + outline: 0; } + +.form-control::-moz-placeholder { + color: #999; + opacity: 1; } + +.form-control:-ms-input-placeholder { + color: #999; } + +.form-control::-webkit-input-placeholder { + color: #999; } + +.form-control[disabled], .form-control[readonly], fieldset[disabled] .form-control { + cursor: not-allowed; + background-color: #eee; + opacity: 1; } + +textarea.form-control { + height: auto; } + +input[type=search] { + -webkit-appearance: none; } + +@media screen and (-webkit-min-device-pixel-ratio: 0) { + input[type=date], input[type=time], input[type=datetime-local], input[type=month] { + line-height: 34px; } + .input-group-sm input[type=date], .input-group-sm input[type=time], .input-group-sm input[type=datetime-local], .input-group-sm input[type=month], input[type=date].input-sm, input[type=time].input-sm, input[type=datetime-local].input-sm, input[type=month].input-sm { + line-height: 30px; } + .input-group-lg input[type=date], .input-group-lg input[type=time], .input-group-lg input[type=datetime-local], .input-group-lg input[type=month], input[type=date].input-lg, input[type=time].input-lg, input[type=datetime-local].input-lg, input[type=month].input-lg { + line-height: 46px; } } + +.form-group { + margin-bottom: 15px; } + +.checkbox, .radio { + position: relative; + display: block; + margin-top: 10px; + margin-bottom: 10px; } + +.checkbox label, .radio label { + min-height: 20px; + padding-left: 20px; + margin-bottom: 0; + font-weight: 400; + cursor: pointer; } + +.checkbox input[type=checkbox], .checkbox-inline input[type=checkbox], .radio input[type=radio], .radio-inline input[type=radio] { + position: absolute; + margin-top: 4px \9; + margin-left: -20px; } + +.checkbox + .checkbox, .radio + .radio { + margin-top: -5px; } + +.checkbox-inline, .radio-inline { + display: inline-block; + padding-left: 20px; + margin-bottom: 0; + font-weight: 400; + vertical-align: middle; + cursor: pointer; } + +.checkbox-inline + .checkbox-inline, .radio-inline + .radio-inline { + margin-top: 0; + margin-left: 10px; } + +fieldset[disabled] input[type=checkbox], fieldset[disabled] input[type=radio], input[type=checkbox].disabled, input[type=checkbox][disabled], input[type=radio].disabled, input[type=radio][disabled] { + cursor: not-allowed; } + +.checkbox-inline.disabled, .radio-inline.disabled, fieldset[disabled] .checkbox-inline, fieldset[disabled] .radio-inline { + cursor: not-allowed; } + +.checkbox.disabled label, .radio.disabled label, fieldset[disabled] .checkbox label, fieldset[disabled] .radio label { + cursor: not-allowed; } + +.form-control-static { + padding-top: 7px; + padding-bottom: 7px; + margin-bottom: 0; } + +.form-control-static.input-lg, .form-control-static.input-sm { + padding-right: 0; + padding-left: 0; } + +.input-sm { + height: 30px; + padding: 5px 10px; + font-size: 12px; + line-height: 1.5; + border-radius: 3px; } + +select.input-sm { + height: 30px; + line-height: 30px; } + +select[multiple].input-sm, textarea.input-sm { + height: auto; } + +.form-group-sm .form-control { + height: 30px; + padding: 5px 10px; + font-size: 12px; + line-height: 1.5; + border-radius: 3px; } + +select.form-group-sm .form-control { + height: 30px; + line-height: 30px; } + +select[multiple].form-group-sm .form-control, textarea.form-group-sm .form-control { + height: auto; } + +.form-group-sm .form-control-static { + height: 30px; + padding: 5px 10px; + font-size: 12px; + line-height: 1.5; } + +.input-lg { + height: 46px; + padding: 10px 16px; + font-size: 18px; + line-height: 1.3333333; + border-radius: 6px; } + +select.input-lg { + height: 46px; + line-height: 46px; } + +select[multiple].input-lg, textarea.input-lg { + height: auto; } + +.form-group-lg .form-control { + height: 46px; + padding: 10px 16px; + font-size: 18px; + line-height: 1.3333333; + border-radius: 6px; } + +select.form-group-lg .form-control { + height: 46px; + line-height: 46px; } + +select[multiple].form-group-lg .form-control, textarea.form-group-lg .form-control { + height: auto; } + +.form-group-lg .form-control-static { + height: 46px; + padding: 10px 16px; + font-size: 18px; + line-height: 1.3333333; } + +.has-feedback { + position: relative; } + +.has-feedback .form-control { + padding-right: 42.5px; } + +.form-control-feedback { + position: absolute; + top: 0; + right: 0; + z-index: 2; + display: block; + width: 34px; + height: 34px; + line-height: 34px; + text-align: center; + pointer-events: none; } + +.input-lg + .form-control-feedback { + width: 46px; + height: 46px; + line-height: 46px; } + +.input-sm + .form-control-feedback { + width: 30px; + height: 30px; + line-height: 30px; } + +.has-success .checkbox, .has-success .checkbox-inline, .has-success .control-label, .has-success .help-block, .has-success .radio, .has-success .radio-inline, .has-success.checkbox label, .has-success.checkbox-inline label, .has-success.radio label, .has-success.radio-inline label { + color: #3c763d; } + +.has-success .form-control { + border-color: #3c763d; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); } + +.has-success .form-control:focus { + border-color: #2b542c; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #67b168; + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #67b168; } + +.has-success .input-group-addon { + color: #3c763d; + background-color: #dff0d8; + border-color: #3c763d; } + +.has-success .form-control-feedback { + color: #3c763d; } + +.has-warning .checkbox, .has-warning .checkbox-inline, .has-warning .control-label, .has-warning .help-block, .has-warning .radio, .has-warning .radio-inline, .has-warning.checkbox label, .has-warning.checkbox-inline label, .has-warning.radio label, .has-warning.radio-inline label { + color: #8a6d3b; } + +.has-warning .form-control { + border-color: #8a6d3b; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); } + +.has-warning .form-control:focus { + border-color: #66512c; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #c0a16b; + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #c0a16b; } + +.has-warning .input-group-addon { + color: #8a6d3b; + background-color: #fcf8e3; + border-color: #8a6d3b; } + +.has-warning .form-control-feedback { + color: #8a6d3b; } + +.has-error .checkbox, .has-error .checkbox-inline, .has-error .control-label, .has-error .help-block, .has-error .radio, .has-error .radio-inline, .has-error.checkbox label, .has-error.checkbox-inline label, .has-error.radio label, .has-error.radio-inline label { + color: #a94442; } + +.has-error .form-control { + border-color: #a94442; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); } + +.has-error .form-control:focus { + border-color: #843534; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #ce8483; + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #ce8483; } + +.has-error .input-group-addon { + color: #a94442; + background-color: #f2dede; + border-color: #a94442; } + +.has-error .form-control-feedback { + color: #a94442; } + +.has-feedback label ~ .form-control-feedback { + top: 25px; } + +.has-feedback label.sr-only ~ .form-control-feedback { + top: 0; } + +.help-block { + display: block; + margin-top: 5px; + margin-bottom: 10px; + color: #737373; } + +@media (min-width: 768px) { + .form-inline .form-group { + display: inline-block; + margin-bottom: 0; + vertical-align: middle; } + .form-inline .form-control { + display: inline-block; + width: auto; + vertical-align: middle; } + .form-inline .form-control-static { + display: inline-block; } + .form-inline .input-group { + display: inline-table; + vertical-align: middle; } + .form-inline .input-group .form-control, .form-inline .input-group .input-group-addon, .form-inline .input-group .input-group-btn { + width: auto; } + .form-inline .input-group > .form-control { + width: 100%; } + .form-inline .control-label { + margin-bottom: 0; + vertical-align: middle; } + .form-inline .checkbox, .form-inline .radio { + display: inline-block; + margin-top: 0; + margin-bottom: 0; + vertical-align: middle; } + .form-inline .checkbox label, .form-inline .radio label { + padding-left: 0; } + .form-inline .checkbox input[type=checkbox], .form-inline .radio input[type=radio] { + position: relative; + margin-left: 0; } + .form-inline .has-feedback .form-control-feedback { + top: 0; } } + +.form-horizontal .checkbox, .form-horizontal .checkbox-inline, .form-horizontal .radio, .form-horizontal .radio-inline { + padding-top: 7px; + margin-top: 0; + margin-bottom: 0; } + +.form-horizontal .checkbox, .form-horizontal .radio { + min-height: 27px; } + +.form-horizontal .form-group { + margin-right: -15px; + margin-left: -15px; } + +@media (min-width: 768px) { + .form-horizontal .control-label { + padding-top: 7px; + margin-bottom: 0; + text-align: right; } } + +.form-horizontal .has-feedback .form-control-feedback { + right: 15px; } + +@media (min-width: 768px) { + .form-horizontal .form-group-lg .control-label { + padding-top: 14.33px; } } + +@media (min-width: 768px) { + .form-horizontal .form-group-sm .control-label { + padding-top: 6px; } } + +.btn { + display: inline-block; + padding: 6px 12px; + margin-bottom: 0; + font-size: 14px; + font-weight: 400; + line-height: 1.42857143; + text-align: center; + white-space: nowrap; + vertical-align: middle; + -ms-touch-action: manipulation; + touch-action: manipulation; + cursor: pointer; + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; + background-image: none; + border: 1px solid transparent; + border-radius: 4px; } + +.btn.active.focus, .btn.active:focus, .btn.focus, .btn:active.focus, .btn:active:focus, .btn:focus { + outline: thin dotted; + outline: 5px auto -webkit-focus-ring-color; + outline-offset: -2px; } + +.btn.focus, .btn:focus, .btn:hover { + color: #333; + text-decoration: none; } + +.btn.active, .btn:active { + background-image: none; + outline: 0; + -webkit-box-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125); + box-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125); } + +.btn.disabled, .btn[disabled], fieldset[disabled] .btn { + pointer-events: none; + cursor: not-allowed; + filter: alpha(opacity=65); + -webkit-box-shadow: none; + box-shadow: none; + opacity: .65; } + +.btn-default { + color: #333; + background-color: #fff; + border-color: #ccc; } + +.btn-default.active, .btn-default.focus, .btn-default:active, .btn-default:focus, .btn-default:hover, .open > .dropdown-toggle.btn-default { + color: #333; + background-color: #e6e6e6; + border-color: #adadad; } + +.btn-default.active, .btn-default:active, .open > .dropdown-toggle.btn-default { + background-image: none; } + +.btn-default.disabled, .btn-default.disabled.active, .btn-default.disabled.focus, .btn-default.disabled:active, .btn-default.disabled:focus, .btn-default.disabled:hover, .btn-default[disabled], .btn-default[disabled].active, .btn-default[disabled].focus, .btn-default[disabled]:active, .btn-default[disabled]:focus, .btn-default[disabled]:hover, fieldset[disabled] .btn-default, fieldset[disabled] .btn-default.active, fieldset[disabled] .btn-default.focus, fieldset[disabled] .btn-default:active, fieldset[disabled] .btn-default:focus, fieldset[disabled] .btn-default:hover { + background-color: #fff; + border-color: #ccc; } + +.btn-default .badge { + color: #fff; + background-color: #333; } + +.btn-primary { + color: #fff; + background-color: #337ab7; + border-color: #2e6da4; } + +.btn-primary.active, .btn-primary.focus, .btn-primary:active, .btn-primary:focus, .btn-primary:hover, .open > .dropdown-toggle.btn-primary { + color: #fff; + background-color: #286090; + border-color: #204d74; } + +.btn-primary.active, .btn-primary:active, .open > .dropdown-toggle.btn-primary { + background-image: none; } + +.btn-primary.disabled, .btn-primary.disabled.active, .btn-primary.disabled.focus, .btn-primary.disabled:active, .btn-primary.disabled:focus, .btn-primary.disabled:hover, .btn-primary[disabled], .btn-primary[disabled].active, .btn-primary[disabled].focus, .btn-primary[disabled]:active, .btn-primary[disabled]:focus, .btn-primary[disabled]:hover, fieldset[disabled] .btn-primary, fieldset[disabled] .btn-primary.active, fieldset[disabled] .btn-primary.focus, fieldset[disabled] .btn-primary:active, fieldset[disabled] .btn-primary:focus, fieldset[disabled] .btn-primary:hover { + background-color: #337ab7; + border-color: #2e6da4; } + +.btn-primary .badge { + color: #337ab7; + background-color: #fff; } + +.btn-success { + color: #fff; + background-color: #5cb85c; + border-color: #4cae4c; } + +.btn-success.active, .btn-success.focus, .btn-success:active, .btn-success:focus, .btn-success:hover, .open > .dropdown-toggle.btn-success { + color: #fff; + background-color: #449d44; + border-color: #398439; } + +.btn-success.active, .btn-success:active, .open > .dropdown-toggle.btn-success { + background-image: none; } + +.btn-success.disabled, .btn-success.disabled.active, .btn-success.disabled.focus, .btn-success.disabled:active, .btn-success.disabled:focus, .btn-success.disabled:hover, .btn-success[disabled], .btn-success[disabled].active, .btn-success[disabled].focus, .btn-success[disabled]:active, .btn-success[disabled]:focus, .btn-success[disabled]:hover, fieldset[disabled] .btn-success, fieldset[disabled] .btn-success.active, fieldset[disabled] .btn-success.focus, fieldset[disabled] .btn-success:active, fieldset[disabled] .btn-success:focus, fieldset[disabled] .btn-success:hover { + background-color: #5cb85c; + border-color: #4cae4c; } + +.btn-success .badge { + color: #5cb85c; + background-color: #fff; } + +.btn-info { + color: #fff; + background-color: #5bc0de; + border-color: #46b8da; } + +.btn-info.active, .btn-info.focus, .btn-info:active, .btn-info:focus, .btn-info:hover, .open > .dropdown-toggle.btn-info { + color: #fff; + background-color: #31b0d5; + border-color: #269abc; } + +.btn-info.active, .btn-info:active, .open > .dropdown-toggle.btn-info { + background-image: none; } + +.btn-info.disabled, .btn-info.disabled.active, .btn-info.disabled.focus, .btn-info.disabled:active, .btn-info.disabled:focus, .btn-info.disabled:hover, .btn-info[disabled], .btn-info[disabled].active, .btn-info[disabled].focus, .btn-info[disabled]:active, .btn-info[disabled]:focus, .btn-info[disabled]:hover, fieldset[disabled] .btn-info, fieldset[disabled] .btn-info.active, fieldset[disabled] .btn-info.focus, fieldset[disabled] .btn-info:active, fieldset[disabled] .btn-info:focus, fieldset[disabled] .btn-info:hover { + background-color: #5bc0de; + border-color: #46b8da; } + +.btn-info .badge { + color: #5bc0de; + background-color: #fff; } + +.btn-warning { + color: #fff; + background-color: #f0ad4e; + border-color: #eea236; } + +.btn-warning.active, .btn-warning.focus, .btn-warning:active, .btn-warning:focus, .btn-warning:hover, .open > .dropdown-toggle.btn-warning { + color: #fff; + background-color: #ec971f; + border-color: #d58512; } + +.btn-warning.active, .btn-warning:active, .open > .dropdown-toggle.btn-warning { + background-image: none; } + +.btn-warning.disabled, .btn-warning.disabled.active, .btn-warning.disabled.focus, .btn-warning.disabled:active, .btn-warning.disabled:focus, .btn-warning.disabled:hover, .btn-warning[disabled], .btn-warning[disabled].active, .btn-warning[disabled].focus, .btn-warning[disabled]:active, .btn-warning[disabled]:focus, .btn-warning[disabled]:hover, fieldset[disabled] .btn-warning, fieldset[disabled] .btn-warning.active, fieldset[disabled] .btn-warning.focus, fieldset[disabled] .btn-warning:active, fieldset[disabled] .btn-warning:focus, fieldset[disabled] .btn-warning:hover { + background-color: #f0ad4e; + border-color: #eea236; } + +.btn-warning .badge { + color: #f0ad4e; + background-color: #fff; } + +.btn-danger { + color: #fff; + background-color: #d9534f; + border-color: #d43f3a; } + +.btn-danger.active, .btn-danger.focus, .btn-danger:active, .btn-danger:focus, .btn-danger:hover, .open > .dropdown-toggle.btn-danger { + color: #fff; + background-color: #c9302c; + border-color: #ac2925; } + +.btn-danger.active, .btn-danger:active, .open > .dropdown-toggle.btn-danger { + background-image: none; } + +.btn-danger.disabled, .btn-danger.disabled.active, .btn-danger.disabled.focus, .btn-danger.disabled:active, .btn-danger.disabled:focus, .btn-danger.disabled:hover, .btn-danger[disabled], .btn-danger[disabled].active, .btn-danger[disabled].focus, .btn-danger[disabled]:active, .btn-danger[disabled]:focus, .btn-danger[disabled]:hover, fieldset[disabled] .btn-danger, fieldset[disabled] .btn-danger.active, fieldset[disabled] .btn-danger.focus, fieldset[disabled] .btn-danger:active, fieldset[disabled] .btn-danger:focus, fieldset[disabled] .btn-danger:hover { + background-color: #d9534f; + border-color: #d43f3a; } + +.btn-danger .badge { + color: #d9534f; + background-color: #fff; } + +.btn-link { + font-weight: 400; + color: #337ab7; + border-radius: 0; } + +.btn-link, .btn-link.active, .btn-link:active, .btn-link[disabled], fieldset[disabled] .btn-link { + background-color: transparent; + -webkit-box-shadow: none; + box-shadow: none; } + +.btn-link, .btn-link:active, .btn-link:focus, .btn-link:hover { + border-color: transparent; } + +.btn-link:focus, .btn-link:hover { + color: #23527c; + text-decoration: underline; + background-color: transparent; } + +.btn-link[disabled]:focus, .btn-link[disabled]:hover, fieldset[disabled] .btn-link:focus, fieldset[disabled] .btn-link:hover { + color: #777; + text-decoration: none; } + +.btn-group-lg > .btn, .btn-lg { + padding: 10px 16px; + font-size: 18px; + line-height: 1.3333333; + border-radius: 6px; } + +.btn-group-sm > .btn, .btn-sm { + padding: 5px 10px; + font-size: 12px; + line-height: 1.5; + border-radius: 3px; } + +.btn-group-xs > .btn, .btn-xs { + padding: 1px 5px; + font-size: 12px; + line-height: 1.5; + border-radius: 3px; } + +.btn-block { + display: block; + width: 100%; } + +.btn-block + .btn-block { + margin-top: 5px; } + +input[type=button].btn-block, input[type=reset].btn-block, input[type=submit].btn-block { + width: 100%; } + +.fade { + opacity: 0; + -webkit-transition: opacity 0.15s linear; + -o-transition: opacity 0.15s linear; + transition: opacity 0.15s linear; } + +.fade.in { + opacity: 1; } + +.collapse { + display: none; + visibility: hidden; } + +.collapse.in { + display: block; + visibility: visible; } + +tr.collapse.in { + display: table-row; } + +tbody.collapse.in { + display: table-row-group; } + +.collapsing { + position: relative; + height: 0; + overflow: hidden; + -webkit-transition-timing-function: ease; + -o-transition-timing-function: ease; + transition-timing-function: ease; + -webkit-transition-duration: .35s; + -o-transition-duration: .35s; + transition-duration: .35s; + -webkit-transition-property: height, visibility; + -o-transition-property: height, visibility; + transition-property: height, visibility; } + +.caret { + display: inline-block; + width: 0; + height: 0; + margin-left: 2px; + vertical-align: middle; + border-top: 4px solid; + border-right: 4px solid transparent; + border-left: 4px solid transparent; } + +.dropdown, .dropup { + position: relative; } + +.dropdown-toggle:focus { + outline: 0; } + +.dropdown-menu { + position: absolute; + top: 100%; + left: 0; + z-index: 1000; + display: none; + float: left; + min-width: 160px; + padding: 5px 0; + margin: 2px 0 0; + font-size: 14px; + text-align: left; + list-style: none; + background-color: #fff; + -webkit-background-clip: padding-box; + background-clip: padding-box; + border: 1px solid #ccc; + border: 1px solid rgba(0, 0, 0, 0.15); + border-radius: 4px; + -webkit-box-shadow: 0 6px 12px rgba(0, 0, 0, 0.175); + box-shadow: 0 6px 12px rgba(0, 0, 0, 0.175); } + +.dropdown-menu.pull-right { + right: 0; + left: auto; } + +.dropdown-menu .divider { + height: 1px; + margin: 9px 0; + overflow: hidden; + background-color: #e5e5e5; } + +.dropdown-menu > li > a { + display: block; + padding: 3px 20px; + clear: both; + font-weight: 400; + line-height: 1.42857143; + color: #333; + white-space: nowrap; } + +.dropdown-menu > li > a:focus, .dropdown-menu > li > a:hover { + color: #262626; + text-decoration: none; + background-color: #f5f5f5; } + +.dropdown-menu > .active > a, .dropdown-menu > .active > a:focus, .dropdown-menu > .active > a:hover { + color: #fff; + text-decoration: none; + background-color: #337ab7; + outline: 0; } + +.dropdown-menu > .disabled > a, .dropdown-menu > .disabled > a:focus, .dropdown-menu > .disabled > a:hover { + color: #777; } + +.dropdown-menu > .disabled > a:focus, .dropdown-menu > .disabled > a:hover { + text-decoration: none; + cursor: not-allowed; + background-color: transparent; + background-image: none; + filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); } + +.open > .dropdown-menu { + display: block; } + +.open > a { + outline: 0; } + +.dropdown-menu-right { + right: 0; + left: auto; } + +.dropdown-menu-left { + right: auto; + left: 0; } + +.dropdown-header { + display: block; + padding: 3px 20px; + font-size: 12px; + line-height: 1.42857143; + color: #777; + white-space: nowrap; } + +.dropdown-backdrop { + position: fixed; + top: 0; + right: 0; + bottom: 0; + left: 0; + z-index: 990; } + +.pull-right > .dropdown-menu { + right: 0; + left: auto; } + +.dropup .caret, .navbar-fixed-bottom .dropdown .caret { + content: ""; + border-top: 0; + border-bottom: 4px solid; } + +.dropup .dropdown-menu, .navbar-fixed-bottom .dropdown .dropdown-menu { + top: auto; + bottom: 100%; + margin-bottom: 2px; } + +@media (min-width: 768px) { + .navbar-right .dropdown-menu { + right: 0; + left: auto; } + .navbar-right .dropdown-menu-left { + right: auto; + left: 0; } } + +.btn-group, .btn-group-vertical { + position: relative; + display: inline-block; + vertical-align: middle; } + +.btn-group-vertical > .btn, .btn-group > .btn { + position: relative; + float: left; } + +.btn-group-vertical > .btn.active, .btn-group-vertical > .btn:active, .btn-group-vertical > .btn:focus, .btn-group-vertical > .btn:hover, .btn-group > .btn.active, .btn-group > .btn:active, .btn-group > .btn:focus, .btn-group > .btn:hover { + z-index: 2; } + +.btn-group .btn + .btn, .btn-group .btn + .btn-group, .btn-group .btn-group + .btn, .btn-group .btn-group + .btn-group { + margin-left: -1px; } + +.btn-toolbar { + margin-left: -5px; } + +.btn-toolbar .btn-group, .btn-toolbar .input-group { + float: left; } + +.btn-toolbar > .btn, .btn-toolbar > .btn-group, .btn-toolbar > .input-group { + margin-left: 5px; } + +.btn-group > .btn:not(:first-child):not(:last-child):not(.dropdown-toggle) { + border-radius: 0; } + +.btn-group > .btn:first-child { + margin-left: 0; } + +.btn-group > .btn:first-child:not(:last-child):not(.dropdown-toggle) { + border-top-right-radius: 0; + border-bottom-right-radius: 0; } + +.btn-group > .btn:last-child:not(:first-child), .btn-group > .dropdown-toggle:not(:first-child) { + border-top-left-radius: 0; + border-bottom-left-radius: 0; } + +.btn-group > .btn-group { + float: left; } + +.btn-group > .btn-group:not(:first-child):not(:last-child) > .btn { + border-radius: 0; } + +.btn-group > .btn-group:first-child:not(:last-child) > .btn:last-child, .btn-group > .btn-group:first-child:not(:last-child) > .dropdown-toggle { + border-top-right-radius: 0; + border-bottom-right-radius: 0; } + +.btn-group > .btn-group:last-child:not(:first-child) > .btn:first-child { + border-top-left-radius: 0; + border-bottom-left-radius: 0; } + +.btn-group .dropdown-toggle:active, .btn-group.open .dropdown-toggle { + outline: 0; } + +.btn-group > .btn + .dropdown-toggle { + padding-right: 8px; + padding-left: 8px; } + +.btn-group > .btn-lg + .dropdown-toggle { + padding-right: 12px; + padding-left: 12px; } + +.btn-group.open .dropdown-toggle { + -webkit-box-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125); + box-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125); } + +.btn-group.open .dropdown-toggle.btn-link { + -webkit-box-shadow: none; + box-shadow: none; } + +.btn .caret { + margin-left: 0; } + +.btn-lg .caret { + border-width: 5px 5px 0; + border-bottom-width: 0; } + +.dropup .btn-lg .caret { + border-width: 0 5px 5px; } + +.btn-group-vertical > .btn, .btn-group-vertical > .btn-group, .btn-group-vertical > .btn-group > .btn { + display: block; + float: none; + width: 100%; + max-width: 100%; } + +.btn-group-vertical > .btn-group > .btn { + float: none; } + +.btn-group-vertical > .btn + .btn, .btn-group-vertical > .btn + .btn-group, .btn-group-vertical > .btn-group + .btn, .btn-group-vertical > .btn-group + .btn-group { + margin-top: -1px; + margin-left: 0; } + +.btn-group-vertical > .btn:not(:first-child):not(:last-child) { + border-radius: 0; } + +.btn-group-vertical > .btn:first-child:not(:last-child) { + border-top-right-radius: 4px; + border-bottom-right-radius: 0; + border-bottom-left-radius: 0; } + +.btn-group-vertical > .btn:last-child:not(:first-child) { + border-top-left-radius: 0; + border-top-right-radius: 0; + border-bottom-left-radius: 4px; } + +.btn-group-vertical > .btn-group:not(:first-child):not(:last-child) > .btn { + border-radius: 0; } + +.btn-group-vertical > .btn-group:first-child:not(:last-child) > .btn:last-child, .btn-group-vertical > .btn-group:first-child:not(:last-child) > .dropdown-toggle { + border-bottom-right-radius: 0; + border-bottom-left-radius: 0; } + +.btn-group-vertical > .btn-group:last-child:not(:first-child) > .btn:first-child { + border-top-left-radius: 0; + border-top-right-radius: 0; } + +.btn-group-justified { + display: table; + width: 100%; + table-layout: fixed; + border-collapse: separate; } + +.btn-group-justified > .btn, .btn-group-justified > .btn-group { + display: table-cell; + float: none; + width: 1%; } + +.btn-group-justified > .btn-group .btn { + width: 100%; } + +.btn-group-justified > .btn-group .dropdown-menu { + left: auto; } + +[data-toggle=buttons] > .btn input[type=checkbox], [data-toggle=buttons] > .btn input[type=radio], [data-toggle=buttons] > .btn-group > .btn input[type=checkbox], [data-toggle=buttons] > .btn-group > .btn input[type=radio] { + position: absolute; + clip: rect(0, 0, 0, 0); + pointer-events: none; } + +.input-group { + position: relative; + display: table; + border-collapse: separate; } + +.input-group[class*=col-] { + float: none; + padding-right: 0; + padding-left: 0; } + +.input-group .form-control { + position: relative; + z-index: 2; + float: left; + width: 100%; + margin-bottom: 0; } + +.input-group-lg > .form-control, .input-group-lg > .input-group-addon, .input-group-lg > .input-group-btn > .btn { + height: 46px; + padding: 10px 16px; + font-size: 18px; + line-height: 1.3333333; + border-radius: 6px; } + +select.input-group-lg > .form-control, select.input-group-lg > .input-group-addon, select.input-group-lg > .input-group-btn > .btn { + height: 46px; + line-height: 46px; } + +select[multiple].input-group-lg > .form-control, select[multiple].input-group-lg > .input-group-addon, select[multiple].input-group-lg > .input-group-btn > .btn, textarea.input-group-lg > .form-control, textarea.input-group-lg > .input-group-addon, textarea.input-group-lg > .input-group-btn > .btn { + height: auto; } + +.input-group-sm > .form-control, .input-group-sm > .input-group-addon, .input-group-sm > .input-group-btn > .btn { + height: 30px; + padding: 5px 10px; + font-size: 12px; + line-height: 1.5; + border-radius: 3px; } + +select.input-group-sm > .form-control, select.input-group-sm > .input-group-addon, select.input-group-sm > .input-group-btn > .btn { + height: 30px; + line-height: 30px; } + +select[multiple].input-group-sm > .form-control, select[multiple].input-group-sm > .input-group-addon, select[multiple].input-group-sm > .input-group-btn > .btn, textarea.input-group-sm > .form-control, textarea.input-group-sm > .input-group-addon, textarea.input-group-sm > .input-group-btn > .btn { + height: auto; } + +.input-group .form-control, .input-group-addon, .input-group-btn { + display: table-cell; } + +.input-group .form-control:not(:first-child):not(:last-child), .input-group-addon:not(:first-child):not(:last-child), .input-group-btn:not(:first-child):not(:last-child) { + border-radius: 0; } + +.input-group-addon, .input-group-btn { + width: 1%; + white-space: nowrap; + vertical-align: middle; } + +.input-group-addon { + padding: 6px 12px; + font-size: 14px; + font-weight: 400; + line-height: 1; + color: #555; + text-align: center; + background-color: #eee; + border: 1px solid #ccc; + border-radius: 4px; } + +.input-group-addon.input-sm { + padding: 5px 10px; + font-size: 12px; + border-radius: 3px; } + +.input-group-addon.input-lg { + padding: 10px 16px; + font-size: 18px; + border-radius: 6px; } + +.input-group-addon input[type=checkbox], .input-group-addon input[type=radio] { + margin-top: 0; } + +.input-group .form-control:first-child, .input-group-addon:first-child, .input-group-btn:first-child > .btn, .input-group-btn:first-child > .btn-group > .btn, .input-group-btn:first-child > .dropdown-toggle, .input-group-btn:last-child > .btn-group:not(:last-child) > .btn, .input-group-btn:last-child > .btn:not(:last-child):not(.dropdown-toggle) { + border-top-right-radius: 0; + border-bottom-right-radius: 0; } + +.input-group-addon:first-child { + border-right: 0; } + +.input-group .form-control:last-child, .input-group-addon:last-child, .input-group-btn:first-child > .btn-group:not(:first-child) > .btn, .input-group-btn:first-child > .btn:not(:first-child), .input-group-btn:last-child > .btn, .input-group-btn:last-child > .btn-group > .btn, .input-group-btn:last-child > .dropdown-toggle { + border-top-left-radius: 0; + border-bottom-left-radius: 0; } + +.input-group-addon:last-child { + border-left: 0; } + +.input-group-btn { + position: relative; + font-size: 0; + white-space: nowrap; } + +.input-group-btn > .btn { + position: relative; } + +.input-group-btn > .btn + .btn { + margin-left: -1px; } + +.input-group-btn > .btn:active, .input-group-btn > .btn:focus, .input-group-btn > .btn:hover { + z-index: 2; } + +.input-group-btn:first-child > .btn, .input-group-btn:first-child > .btn-group { + margin-right: -1px; } + +.input-group-btn:last-child > .btn, .input-group-btn:last-child > .btn-group { + margin-left: -1px; } + +.nav { + padding-left: 0; + margin-bottom: 0; + list-style: none; } + +.nav > li { + position: relative; + display: block; } + +.nav > li > a { + position: relative; + display: block; + padding: 10px 15px; } + +.nav > li > a:focus, .nav > li > a:hover { + text-decoration: none; + background-color: #eee; } + +.nav > li.disabled > a { + color: #777; } + +.nav > li.disabled > a:focus, .nav > li.disabled > a:hover { + color: #777; + text-decoration: none; + cursor: not-allowed; + background-color: transparent; } + +.nav .open > a, .nav .open > a:focus, .nav .open > a:hover { + background-color: #eee; + border-color: #337ab7; } + +.nav .nav-divider { + height: 1px; + margin: 9px 0; + overflow: hidden; + background-color: #e5e5e5; } + +.nav > li > a > img { + max-width: none; } + +.nav-tabs { + border-bottom: 1px solid #ddd; } + +.nav-tabs > li { + float: left; + margin-bottom: -1px; } + +.nav-tabs > li > a { + margin-right: 2px; + line-height: 1.42857143; + border: 1px solid transparent; + border-radius: 4px 4px 0 0; } + +.nav-tabs > li > a:hover { + border-color: #eee #eee #ddd; } + +.nav-tabs > li.active > a, .nav-tabs > li.active > a:focus, .nav-tabs > li.active > a:hover { + color: #555; + cursor: default; + background-color: #fff; + border: 1px solid #ddd; + border-bottom-color: transparent; } + +.nav-tabs.nav-justified { + width: 100%; + border-bottom: 0; } + +.nav-tabs.nav-justified > li { + float: none; } + +.nav-tabs.nav-justified > li > a { + margin-bottom: 5px; + text-align: center; } + +.nav-tabs.nav-justified > .dropdown .dropdown-menu { + top: auto; + left: auto; } + +@media (min-width: 768px) { + .nav-tabs.nav-justified > li { + display: table-cell; + width: 1%; } + .nav-tabs.nav-justified > li > a { + margin-bottom: 0; } } + +.nav-tabs.nav-justified > li > a { + margin-right: 0; + border-radius: 4px; } + +.nav-tabs.nav-justified > .active > a, .nav-tabs.nav-justified > .active > a:focus, .nav-tabs.nav-justified > .active > a:hover { + border: 1px solid #ddd; } + +@media (min-width: 768px) { + .nav-tabs.nav-justified > li > a { + border-bottom: 1px solid #ddd; + border-radius: 4px 4px 0 0; } + .nav-tabs.nav-justified > .active > a, .nav-tabs.nav-justified > .active > a:focus, .nav-tabs.nav-justified > .active > a:hover { + border-bottom-color: #fff; } } + +.nav-pills > li { + float: left; } + +.nav-pills > li > a { + border-radius: 4px; } + +.nav-pills > li + li { + margin-left: 2px; } + +.nav-pills > li.active > a, .nav-pills > li.active > a:focus, .nav-pills > li.active > a:hover { + color: #fff; + background-color: #337ab7; } + +.nav-stacked > li { + float: none; } + +.nav-stacked > li + li { + margin-top: 2px; + margin-left: 0; } + +.nav-justified { + width: 100%; } + +.nav-justified > li { + float: none; } + +.nav-justified > li > a { + margin-bottom: 5px; + text-align: center; } + +.nav-justified > .dropdown .dropdown-menu { + top: auto; + left: auto; } + +@media (min-width: 768px) { + .nav-justified > li { + display: table-cell; + width: 1%; } + .nav-justified > li > a { + margin-bottom: 0; } } + +.nav-tabs-justified { + border-bottom: 0; } + +.nav-tabs-justified > li > a { + margin-right: 0; + border-radius: 4px; } + +.nav-tabs-justified > .active > a, .nav-tabs-justified > .active > a:focus, .nav-tabs-justified > .active > a:hover { + border: 1px solid #ddd; } + +@media (min-width: 768px) { + .nav-tabs-justified > li > a { + border-bottom: 1px solid #ddd; + border-radius: 4px 4px 0 0; } + .nav-tabs-justified > .active > a, .nav-tabs-justified > .active > a:focus, .nav-tabs-justified > .active > a:hover { + border-bottom-color: #fff; } } + +.tab-content > .tab-pane { + display: none; + visibility: hidden; } + +.tab-content > .active { + display: block; + visibility: visible; } + +.nav-tabs .dropdown-menu { + margin-top: -1px; + border-top-left-radius: 0; + border-top-right-radius: 0; } + +.navbar { + position: relative; + min-height: 50px; + margin-bottom: 20px; + border: 1px solid transparent; } + +@media (min-width: 768px) { + .navbar { + border-radius: 4px; } } + +@media (min-width: 768px) { + .navbar-header { + float: left; } } + +.navbar-collapse { + padding-right: 15px; + padding-left: 15px; + overflow-x: visible; + -webkit-overflow-scrolling: touch; + border-top: 1px solid transparent; + -webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1); + box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1); } + +.navbar-collapse.in { + overflow-y: auto; } + +@media (min-width: 768px) { + .navbar-collapse { + width: auto; + border-top: 0; + -webkit-box-shadow: none; + box-shadow: none; } + .navbar-collapse.collapse { + display: block !important; + height: auto !important; + padding-bottom: 0; + overflow: visible !important; + visibility: visible !important; } + .navbar-collapse.in { + overflow-y: visible; } + .navbar-fixed-bottom .navbar-collapse, .navbar-fixed-top .navbar-collapse, .navbar-static-top .navbar-collapse { + padding-right: 0; + padding-left: 0; } } + +.navbar-fixed-bottom .navbar-collapse, .navbar-fixed-top .navbar-collapse { + max-height: 340px; } + +@media (max-device-width: 480px) and (orientation: landscape) { + .navbar-fixed-bottom .navbar-collapse, .navbar-fixed-top .navbar-collapse { + max-height: 200px; } } + +.container-fluid > .navbar-collapse, .container-fluid > .navbar-header, .container > .navbar-collapse, .container > .navbar-header { + margin-right: -15px; + margin-left: -15px; } + +@media (min-width: 768px) { + .container-fluid > .navbar-collapse, .container-fluid > .navbar-header, .container > .navbar-collapse, .container > .navbar-header { + margin-right: 0; + margin-left: 0; } } + +.navbar-static-top { + z-index: 1000; + border-width: 0 0 1px; } + +@media (min-width: 768px) { + .navbar-static-top { + border-radius: 0; } } + +.navbar-fixed-bottom, .navbar-fixed-top { + position: fixed; + right: 0; + left: 0; + z-index: 1030; } + +@media (min-width: 768px) { + .navbar-fixed-bottom, .navbar-fixed-top { + border-radius: 0; } } + +.navbar-fixed-top { + top: 0; + border-width: 0 0 1px; } + +.navbar-fixed-bottom { + bottom: 0; + margin-bottom: 0; + border-width: 1px 0 0; } + +.navbar-brand { + float: left; + height: 50px; + padding: 15px 15px; + font-size: 18px; + line-height: 20px; } + +.navbar-brand:focus, .navbar-brand:hover { + text-decoration: none; } + +.navbar-brand > img { + display: block; } + +@media (min-width: 768px) { + .navbar > .container .navbar-brand, .navbar > .container-fluid .navbar-brand { + margin-left: -15px; } } + +.navbar-toggle { + position: relative; + float: right; + padding: 9px 10px; + margin-top: 8px; + margin-right: 15px; + margin-bottom: 8px; + background-color: transparent; + background-image: none; + border: 1px solid transparent; + border-radius: 4px; } + +.navbar-toggle:focus { + outline: 0; } + +.navbar-toggle .icon-bar { + display: block; + width: 22px; + height: 2px; + border-radius: 1px; } + +.navbar-toggle .icon-bar + .icon-bar { + margin-top: 4px; } + +@media (min-width: 768px) { + .navbar-toggle { + display: none; } } + +.navbar-nav { + margin: 7.5px -15px; } + +.navbar-nav > li > a { + padding-top: 10px; + padding-bottom: 10px; + line-height: 20px; } + +@media (max-width: 767px) { + .navbar-nav .open .dropdown-menu { + position: static; + float: none; + width: auto; + margin-top: 0; + background-color: transparent; + border: 0; + -webkit-box-shadow: none; + box-shadow: none; } + .navbar-nav .open .dropdown-menu .dropdown-header, .navbar-nav .open .dropdown-menu > li > a { + padding: 5px 15px 5px 25px; } + .navbar-nav .open .dropdown-menu > li > a { + line-height: 20px; } + .navbar-nav .open .dropdown-menu > li > a:focus, .navbar-nav .open .dropdown-menu > li > a:hover { + background-image: none; } } + +@media (min-width: 768px) { + .navbar-nav { + float: left; + margin: 0; } + .navbar-nav > li { + float: left; } + .navbar-nav > li > a { + padding-top: 15px; + padding-bottom: 15px; } } + +.navbar-form { + padding: 10px 15px; + margin-top: 8px; + margin-right: -15px; + margin-bottom: 8px; + margin-left: -15px; + border-top: 1px solid transparent; + border-bottom: 1px solid transparent; + -webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 1px 0 rgba(255, 255, 255, 0.1); + box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 1px 0 rgba(255, 255, 255, 0.1); } + +@media (min-width: 768px) { + .navbar-form .form-group { + display: inline-block; + margin-bottom: 0; + vertical-align: middle; } + .navbar-form .form-control { + display: inline-block; + width: auto; + vertical-align: middle; } + .navbar-form .form-control-static { + display: inline-block; } + .navbar-form .input-group { + display: inline-table; + vertical-align: middle; } + .navbar-form .input-group .form-control, .navbar-form .input-group .input-group-addon, .navbar-form .input-group .input-group-btn { + width: auto; } + .navbar-form .input-group > .form-control { + width: 100%; } + .navbar-form .control-label { + margin-bottom: 0; + vertical-align: middle; } + .navbar-form .checkbox, .navbar-form .radio { + display: inline-block; + margin-top: 0; + margin-bottom: 0; + vertical-align: middle; } + .navbar-form .checkbox label, .navbar-form .radio label { + padding-left: 0; } + .navbar-form .checkbox input[type=checkbox], .navbar-form .radio input[type=radio] { + position: relative; + margin-left: 0; } + .navbar-form .has-feedback .form-control-feedback { + top: 0; } } + +@media (max-width: 767px) { + .navbar-form .form-group { + margin-bottom: 5px; } + .navbar-form .form-group:last-child { + margin-bottom: 0; } } + +@media (min-width: 768px) { + .navbar-form { + width: auto; + padding-top: 0; + padding-bottom: 0; + margin-right: 0; + margin-left: 0; + border: 0; + -webkit-box-shadow: none; + box-shadow: none; } } + +.navbar-nav > li > .dropdown-menu { + margin-top: 0; + border-top-left-radius: 0; + border-top-right-radius: 0; } + +.navbar-fixed-bottom .navbar-nav > li > .dropdown-menu { + margin-bottom: 0; + border-top-left-radius: 4px; + border-top-right-radius: 4px; + border-bottom-right-radius: 0; + border-bottom-left-radius: 0; } + +.navbar-btn { + margin-top: 8px; + margin-bottom: 8px; } + +.navbar-btn.btn-sm { + margin-top: 10px; + margin-bottom: 10px; } + +.navbar-btn.btn-xs { + margin-top: 14px; + margin-bottom: 14px; } + +.navbar-text { + margin-top: 15px; + margin-bottom: 15px; } + +@media (min-width: 768px) { + .navbar-text { + float: left; + margin-right: 15px; + margin-left: 15px; } } + +@media (min-width: 768px) { + .navbar-left { + float: left !important; } + .navbar-right { + float: right !important; + margin-right: -15px; } + .navbar-right ~ .navbar-right { + margin-right: 0; } } + +.navbar-default { + background-color: #f8f8f8; + border-color: #e7e7e7; } + +.navbar-default .navbar-brand { + color: #777; } + +.navbar-default .navbar-brand:focus, .navbar-default .navbar-brand:hover { + color: #5e5e5e; + background-color: transparent; } + +.navbar-default .navbar-text { + color: #777; } + +.navbar-default .navbar-nav > li > a { + color: #777; } + +.navbar-default .navbar-nav > li > a:focus, .navbar-default .navbar-nav > li > a:hover { + color: #333; + background-color: transparent; } + +.navbar-default .navbar-nav > .active > a, .navbar-default .navbar-nav > .active > a:focus, .navbar-default .navbar-nav > .active > a:hover { + color: #555; + background-color: #e7e7e7; } + +.navbar-default .navbar-nav > .disabled > a, .navbar-default .navbar-nav > .disabled > a:focus, .navbar-default .navbar-nav > .disabled > a:hover { + color: #ccc; + background-color: transparent; } + +.navbar-default .navbar-toggle { + border-color: #ddd; } + +.navbar-default .navbar-toggle:focus, .navbar-default .navbar-toggle:hover { + background-color: #ddd; } + +.navbar-default .navbar-toggle .icon-bar { + background-color: #888; } + +.navbar-default .navbar-collapse, .navbar-default .navbar-form { + border-color: #e7e7e7; } + +.navbar-default .navbar-nav > .open > a, .navbar-default .navbar-nav > .open > a:focus, .navbar-default .navbar-nav > .open > a:hover { + color: #555; + background-color: #e7e7e7; } + +@media (max-width: 767px) { + .navbar-default .navbar-nav .open .dropdown-menu > li > a { + color: #777; } + .navbar-default .navbar-nav .open .dropdown-menu > li > a:focus, .navbar-default .navbar-nav .open .dropdown-menu > li > a:hover { + color: #333; + background-color: transparent; } + .navbar-default .navbar-nav .open .dropdown-menu > .active > a, .navbar-default .navbar-nav .open .dropdown-menu > .active > a:focus, .navbar-default .navbar-nav .open .dropdown-menu > .active > a:hover { + color: #555; + background-color: #e7e7e7; } + .navbar-default .navbar-nav .open .dropdown-menu > .disabled > a, .navbar-default .navbar-nav .open .dropdown-menu > .disabled > a:focus, .navbar-default .navbar-nav .open .dropdown-menu > .disabled > a:hover { + color: #ccc; + background-color: transparent; } } + +.navbar-default .navbar-link { + color: #777; } + +.navbar-default .navbar-link:hover { + color: #333; } + +.navbar-default .btn-link { + color: #777; } + +.navbar-default .btn-link:focus, .navbar-default .btn-link:hover { + color: #333; } + +.navbar-default .btn-link[disabled]:focus, .navbar-default .btn-link[disabled]:hover, fieldset[disabled] .navbar-default .btn-link:focus, fieldset[disabled] .navbar-default .btn-link:hover { + color: #ccc; } + +.navbar-inverse { + background-color: #222; + border-color: #080808; } + +.navbar-inverse .navbar-brand { + color: #9d9d9d; } + +.navbar-inverse .navbar-brand:focus, .navbar-inverse .navbar-brand:hover { + color: #fff; + background-color: transparent; } + +.navbar-inverse .navbar-text { + color: #9d9d9d; } + +.navbar-inverse .navbar-nav > li > a { + color: #9d9d9d; } + +.navbar-inverse .navbar-nav > li > a:focus, .navbar-inverse .navbar-nav > li > a:hover { + color: #fff; + background-color: transparent; } + +.navbar-inverse .navbar-nav > .active > a, .navbar-inverse .navbar-nav > .active > a:focus, .navbar-inverse .navbar-nav > .active > a:hover { + color: #fff; + background-color: #080808; } + +.navbar-inverse .navbar-nav > .disabled > a, .navbar-inverse .navbar-nav > .disabled > a:focus, .navbar-inverse .navbar-nav > .disabled > a:hover { + color: #444; + background-color: transparent; } + +.navbar-inverse .navbar-toggle { + border-color: #333; } + +.navbar-inverse .navbar-toggle:focus, .navbar-inverse .navbar-toggle:hover { + background-color: #333; } + +.navbar-inverse .navbar-toggle .icon-bar { + background-color: #fff; } + +.navbar-inverse .navbar-collapse, .navbar-inverse .navbar-form { + border-color: #101010; } + +.navbar-inverse .navbar-nav > .open > a, .navbar-inverse .navbar-nav > .open > a:focus, .navbar-inverse .navbar-nav > .open > a:hover { + color: #fff; + background-color: #080808; } + +@media (max-width: 767px) { + .navbar-inverse .navbar-nav .open .dropdown-menu > .dropdown-header { + border-color: #080808; } + .navbar-inverse .navbar-nav .open .dropdown-menu .divider { + background-color: #080808; } + .navbar-inverse .navbar-nav .open .dropdown-menu > li > a { + color: #9d9d9d; } + .navbar-inverse .navbar-nav .open .dropdown-menu > li > a:focus, .navbar-inverse .navbar-nav .open .dropdown-menu > li > a:hover { + color: #fff; + background-color: transparent; } + .navbar-inverse .navbar-nav .open .dropdown-menu > .active > a, .navbar-inverse .navbar-nav .open .dropdown-menu > .active > a:focus, .navbar-inverse .navbar-nav .open .dropdown-menu > .active > a:hover { + color: #fff; + background-color: #080808; } + .navbar-inverse .navbar-nav .open .dropdown-menu > .disabled > a, .navbar-inverse .navbar-nav .open .dropdown-menu > .disabled > a:focus, .navbar-inverse .navbar-nav .open .dropdown-menu > .disabled > a:hover { + color: #444; + background-color: transparent; } } + +.navbar-inverse .navbar-link { + color: #9d9d9d; } + +.navbar-inverse .navbar-link:hover { + color: #fff; } + +.navbar-inverse .btn-link { + color: #9d9d9d; } + +.navbar-inverse .btn-link:focus, .navbar-inverse .btn-link:hover { + color: #fff; } + +.navbar-inverse .btn-link[disabled]:focus, .navbar-inverse .btn-link[disabled]:hover, fieldset[disabled] .navbar-inverse .btn-link:focus, fieldset[disabled] .navbar-inverse .btn-link:hover { + color: #444; } + +.breadcrumb { + padding: 8px 15px; + margin-bottom: 20px; + list-style: none; + background-color: #f5f5f5; + border-radius: 4px; } + +.breadcrumb > li { + display: inline-block; } + +.breadcrumb > li + li:before { + padding: 0 5px; + color: #ccc; + content: "/\00a0"; } + +.breadcrumb > .active { + color: #777; } + +.pagination { + display: inline-block; + padding-left: 0; + margin: 20px 0; + border-radius: 4px; } + +.pagination > li { + display: inline; } + +.pagination > li > a, .pagination > li > span { + position: relative; + float: left; + padding: 6px 12px; + margin-left: -1px; + line-height: 1.42857143; + text-decoration: none; } + +.pagination > li:first-child > a, .pagination > li:first-child > span { + margin-left: 0; + border-top-left-radius: 4px; + border-bottom-left-radius: 4px; } + +.pagination > li:last-child > a, .pagination > li:last-child > span { + border-top-right-radius: 4px; + border-bottom-right-radius: 4px; } + +.pagination > .active > a, .pagination > .active > a:focus, .pagination > .active > a:hover, .pagination > .active > span, .pagination > .active > span:focus, .pagination > .active > span:hover { + z-index: 2; + cursor: default; } + +.pagination > .disabled > a, .pagination > .disabled > a:focus, .pagination > .disabled > a:hover, .pagination > .disabled > span, .pagination > .disabled > span:focus, .pagination > .disabled > span:hover { + cursor: not-allowed; } + +.pagination-lg > li > a, .pagination-lg > li > span { + padding: 10px 16px; + font-size: 18px; } + +.pagination-lg > li:first-child > a, .pagination-lg > li:first-child > span { + border-top-left-radius: 6px; + border-bottom-left-radius: 6px; } + +.pagination-lg > li:last-child > a, .pagination-lg > li:last-child > span { + border-top-right-radius: 6px; + border-bottom-right-radius: 6px; } + +.pagination-sm > li > a, .pagination-sm > li > span { + padding: 5px 10px; + font-size: 12px; } + +.pagination-sm > li:first-child > a, .pagination-sm > li:first-child > span { + border-top-left-radius: 3px; + border-bottom-left-radius: 3px; } + +.pagination-sm > li:last-child > a, .pagination-sm > li:last-child > span { + border-top-right-radius: 3px; + border-bottom-right-radius: 3px; } + +.pager { + padding-left: 0; + margin: 20px 0; + text-align: center; + list-style: none; } + +.pager li { + display: inline; } + +.pager li > a, .pager li > span { + display: inline-block; + padding: 5px 14px; + background-color: #fff; + border: 1px solid #ddd; + border-radius: 15px; } + +.pager li > a:focus, .pager li > a:hover { + text-decoration: none; + background-color: #eee; } + +.pager .next > a, .pager .next > span { + float: right; } + +.pager .previous > a, .pager .previous > span { + float: left; } + +.pager .disabled > a, .pager .disabled > a:focus, .pager .disabled > a:hover, .pager .disabled > span { + color: #777; + cursor: not-allowed; + background-color: #fff; } + +.label { + display: inline; + /* padding: .2em .6em .3em; */ + font-size: 75%; + /* font-weight: 700;*/ + line-height: 1; + /* color: #fff;*/ + text-align: center; + white-space: nowrap; + vertical-align: baseline; + border-radius: .25em; } + +a.label:focus, a.label:hover { + color: #fff; + text-decoration: none; + cursor: pointer; } + +.label:empty { + display: none; } + +.btn .label { + position: relative; + top: -1px; } + +.label-default { + background-color: #777; } + +.label-default[href]:focus, .label-default[href]:hover { + background-color: #5e5e5e; } + +.label-primary { + background-color: #337ab7; } + +.label-primary[href]:focus, .label-primary[href]:hover { + background-color: #286090; } + +.label-success { + background-color: #5cb85c; } + +.label-success[href]:focus, .label-success[href]:hover { + background-color: #449d44; } + +.label-info { + background-color: #5bc0de; } + +.label-info[href]:focus, .label-info[href]:hover { + background-color: #31b0d5; } + +.label-warning { + background-color: #f0ad4e; } + +.label-warning[href]:focus, .label-warning[href]:hover { + background-color: #ec971f; } + +.label-danger { + background-color: #d9534f; } + +.label-danger[href]:focus, .label-danger[href]:hover { + background-color: #c9302c; } + +.badge { + display: inline-block; + min-width: 10px; + padding: 3px 7px; + font-size: 12px; + font-weight: 700; + line-height: 1; + color: #fff; + text-align: center; + white-space: nowrap; + vertical-align: baseline; + background-color: #777; + border-radius: 10px; } + +.badge:empty { + display: none; } + +.btn .badge { + position: relative; + top: -1px; } + +.btn-xs .badge { + top: 0; + padding: 1px 5px; } + +a.badge:focus, a.badge:hover { + color: #fff; + text-decoration: none; + cursor: pointer; } + +.list-group-item.active > .badge, .nav-pills > .active > a > .badge { + color: #337ab7; + background-color: #fff; } + +.list-group-item > .badge { + float: right; } + +.list-group-item > .badge + .badge { + margin-right: 5px; } + +.nav-pills > li > a > .badge { + margin-left: 3px; } + +.jumbotron { + padding: 30px 15px; + margin-bottom: 30px; + color: inherit; + background-color: #eee; } + +.jumbotron .h1, .jumbotron h1 { + color: inherit; } + +.jumbotron p { + margin-bottom: 15px; + font-size: 21px; + font-weight: 200; } + +.jumbotron > hr { + border-top-color: #d5d5d5; } + +.container .jumbotron, .container-fluid .jumbotron { + border-radius: 6px; } + +.jumbotron .container { + max-width: 100%; } + +@media screen and (min-width: 768px) { + .jumbotron { + padding: 48px 0; } + .container .jumbotron, .container-fluid .jumbotron { + padding-right: 60px; + padding-left: 60px; } + .jumbotron .h1, .jumbotron h1 { + font-size: 63px; } } + +.thumbnail { + display: block; + padding: 4px; + margin-bottom: 20px; + line-height: 1.42857143; + background-color: #fff; + border: 1px solid #ddd; + border-radius: 4px; + -webkit-transition: border 0.2s ease-in-out; + -o-transition: border 0.2s ease-in-out; + transition: border 0.2s ease-in-out; } + +.thumbnail a > img, .thumbnail > img { + margin-right: auto; + margin-left: auto; } + +a.thumbnail.active, a.thumbnail:focus, a.thumbnail:hover { + border-color: #337ab7; } + +.thumbnail .caption { + padding: 9px; + color: #333; } + +.alert { + padding: 15px; + margin-bottom: 20px; + border: 1px solid transparent; + border-radius: 4px; } + +.alert h4 { + margin-top: 0; + color: inherit; } + +.alert .alert-link { + font-weight: 700; } + +.alert > p, .alert > ul { + margin-bottom: 0; } + +.alert > p + p { + margin-top: 5px; } + +.alert-dismissable, .alert-dismissible { + padding-right: 35px; } + +.alert-dismissable .close, .alert-dismissible .close { + position: relative; + top: -2px; + right: -21px; + color: inherit; } + +.alert-success { + color: #3c763d; + background-color: #dff0d8; + border-color: #d6e9c6; } + +.alert-success hr { + border-top-color: #c9e2b3; } + +.alert-success .alert-link { + color: #2b542c; } + +.alert-info { + color: #31708f; + background-color: #d9edf7; + border-color: #bce8f1; } + +.alert-info hr { + border-top-color: #a6e1ec; } + +.alert-info .alert-link { + color: #245269; } + +.alert-warning { + color: #8a6d3b; + background-color: #fcf8e3; + border-color: #faebcc; } + +.alert-warning hr { + border-top-color: #f7e1b5; } + +.alert-warning .alert-link { + color: #66512c; } + +.alert-danger { + color: #a94442; + background-color: #f2dede; + border-color: #ebccd1; } + +.alert-danger hr { + border-top-color: #e4b9c0; } + +.alert-danger .alert-link { + color: #843534; } + +@-webkit-keyframes progress-bar-stripes { + from { + background-position: 40px 0; } + to { + background-position: 0 0; } } + +@-o-keyframes progress-bar-stripes { + from { + background-position: 40px 0; } + to { + background-position: 0 0; } } + +@keyframes progress-bar-stripes { + from { + background-position: 40px 0; } + to { + background-position: 0 0; } } + +.progress { + height: 20px; + margin-bottom: 20px; + overflow: hidden; + background-color: #f5f5f5; + border-radius: 4px; + -webkit-box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1); + box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1); } + +.progress-bar { + float: left; + width: 0; + height: 100%; + font-size: 12px; + line-height: 20px; + color: #fff; + text-align: center; + background-color: #337ab7; + -webkit-box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.15); + box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.15); + -webkit-transition: width 0.6s ease; + -o-transition: width 0.6s ease; + transition: width 0.6s ease; } + +.progress-bar-striped, .progress-striped .progress-bar { + background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + -webkit-background-size: 40px 40px; + background-size: 40px 40px; } + +.progress-bar.active, .progress.active .progress-bar { + -webkit-animation: progress-bar-stripes 2s linear infinite; + -o-animation: progress-bar-stripes 2s linear infinite; + animation: progress-bar-stripes 2s linear infinite; } + +.progress-bar-success { + background-color: #5cb85c; } + +.progress-striped .progress-bar-success { + background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); } + +.progress-bar-info { + background-color: #5bc0de; } + +.progress-striped .progress-bar-info { + background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); } + +.progress-bar-warning { + background-color: #f0ad4e; } + +.progress-striped .progress-bar-warning { + background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); } + +.progress-bar-danger { + background-color: #d9534f; } + +.progress-striped .progress-bar-danger { + background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); } + +.media { + margin-top: 15px; } + +.media:first-child { + margin-top: 0; } + +.media, .media-body { + overflow: hidden; + zoom: 1; } + +.media-body { + width: 10000px; } + +.media-object { + display: block; } + +.media-right, .media > .pull-right { + padding-left: 10px; } + +.media-left, .media > .pull-left { + padding-right: 10px; } + +.media-body, .media-left, .media-right { + display: table-cell; + vertical-align: top; } + +.media-middle { + vertical-align: middle; } + +.media-bottom { + vertical-align: bottom; } + +.media-heading { + margin-top: 0; + margin-bottom: 5px; } + +.media-list { + padding-left: 0; + list-style: none; } + +.list-group { + padding-left: 0; + margin-bottom: 20px; } + +.list-group-item { + position: relative; + display: block; + padding: 10px 15px; + margin-bottom: -1px; + background-color: #fff; + border: 1px solid #ddd; } + +.list-group-item:first-child { + border-top-left-radius: 4px; + border-top-right-radius: 4px; } + +.list-group-item:last-child { + margin-bottom: 0; + border-bottom-right-radius: 4px; + border-bottom-left-radius: 4px; } + +a.list-group-item { + color: #555; } + +a.list-group-item .list-group-item-heading { + color: #333; } + +a.list-group-item:focus, a.list-group-item:hover { + color: #555; + text-decoration: none; + background-color: #f5f5f5; } + +.list-group-item.disabled, .list-group-item.disabled:focus, .list-group-item.disabled:hover { + color: #777; + cursor: not-allowed; + background-color: #eee; } + +.list-group-item.disabled .list-group-item-heading, .list-group-item.disabled:focus .list-group-item-heading, .list-group-item.disabled:hover .list-group-item-heading { + color: inherit; } + +.list-group-item.disabled .list-group-item-text, .list-group-item.disabled:focus .list-group-item-text, .list-group-item.disabled:hover .list-group-item-text { + color: #777; } + +.list-group-item.active, .list-group-item.active:focus, .list-group-item.active:hover { + z-index: 2; + color: #fff; + background-color: #337ab7; + border-color: #337ab7; } + +.list-group-item.active .list-group-item-heading, .list-group-item.active .list-group-item-heading > .small, .list-group-item.active .list-group-item-heading > small, .list-group-item.active:focus .list-group-item-heading, .list-group-item.active:focus .list-group-item-heading > .small, .list-group-item.active:focus .list-group-item-heading > small, .list-group-item.active:hover .list-group-item-heading, .list-group-item.active:hover .list-group-item-heading > .small, .list-group-item.active:hover .list-group-item-heading > small { + color: inherit; } + +.list-group-item.active .list-group-item-text, .list-group-item.active:focus .list-group-item-text, .list-group-item.active:hover .list-group-item-text { + color: #c7ddef; } + +.list-group-item-success { + color: #3c763d; + background-color: #dff0d8; } + +a.list-group-item-success { + color: #3c763d; } + +a.list-group-item-success .list-group-item-heading { + color: inherit; } + +a.list-group-item-success:focus, a.list-group-item-success:hover { + color: #3c763d; + background-color: #d0e9c6; } + +a.list-group-item-success.active, a.list-group-item-success.active:focus, a.list-group-item-success.active:hover { + color: #fff; + background-color: #3c763d; + border-color: #3c763d; } + +.list-group-item-info { + color: #31708f; + background-color: #d9edf7; } + +a.list-group-item-info { + color: #31708f; } + +a.list-group-item-info .list-group-item-heading { + color: inherit; } + +a.list-group-item-info:focus, a.list-group-item-info:hover { + color: #31708f; + background-color: #c4e3f3; } + +a.list-group-item-info.active, a.list-group-item-info.active:focus, a.list-group-item-info.active:hover { + color: #fff; + background-color: #31708f; + border-color: #31708f; } + +.list-group-item-warning { + color: #8a6d3b; + background-color: #fcf8e3; } + +a.list-group-item-warning { + color: #8a6d3b; } + +a.list-group-item-warning .list-group-item-heading { + color: inherit; } + +a.list-group-item-warning:focus, a.list-group-item-warning:hover { + color: #8a6d3b; + background-color: #faf2cc; } + +a.list-group-item-warning.active, a.list-group-item-warning.active:focus, a.list-group-item-warning.active:hover { + color: #fff; + background-color: #8a6d3b; + border-color: #8a6d3b; } + +.list-group-item-danger { + color: #a94442; + background-color: #f2dede; } + +a.list-group-item-danger { + color: #a94442; } + +a.list-group-item-danger .list-group-item-heading { + color: inherit; } + +a.list-group-item-danger:focus, a.list-group-item-danger:hover { + color: #a94442; + background-color: #ebcccc; } + +a.list-group-item-danger.active, a.list-group-item-danger.active:focus, a.list-group-item-danger.active:hover { + color: #fff; + background-color: #a94442; + border-color: #a94442; } + +.list-group-item-heading { + margin-top: 0; + margin-bottom: 5px; } + +.list-group-item-text { + margin-bottom: 0; + line-height: 1.3; } + +.panel { + margin-bottom: 20px; + background-color: #fff; + border: 1px solid transparent; + border-radius: 4px; + -webkit-box-shadow: 0 1px 1px rgba(0, 0, 0, 0.05); + box-shadow: 0 1px 1px rgba(0, 0, 0, 0.05); } + +.panel-body { + padding: 15px; } + +.panel-heading { + padding: 10px 15px; + border-bottom: 1px solid transparent; + border-top-left-radius: 3px; + border-top-right-radius: 3px; } + +.panel-heading > .dropdown .dropdown-toggle { + color: inherit; } + +.panel-title { + margin-top: 0; + margin-bottom: 0; + font-size: 16px; + color: inherit; } + +.panel-title > .small, .panel-title > .small > a, .panel-title > a, .panel-title > small, .panel-title > small > a { + color: inherit; } + +.panel-footer { + padding: 10px 15px; + background-color: #f5f5f5; + border-top: 1px solid #ddd; + border-bottom-right-radius: 3px; + border-bottom-left-radius: 3px; } + +.panel > .list-group, .panel > .panel-collapse > .list-group { + margin-bottom: 0; } + +.panel > .list-group .list-group-item, .panel > .panel-collapse > .list-group .list-group-item { + border-width: 1px 0; + border-radius: 0; } + +.panel > .list-group:first-child .list-group-item:first-child, .panel > .panel-collapse > .list-group:first-child .list-group-item:first-child { + border-top: 0; + border-top-left-radius: 3px; + border-top-right-radius: 3px; } + +.panel > .list-group:last-child .list-group-item:last-child, .panel > .panel-collapse > .list-group:last-child .list-group-item:last-child { + border-bottom: 0; + border-bottom-right-radius: 3px; + border-bottom-left-radius: 3px; } + +.panel-heading + .list-group .list-group-item:first-child { + border-top-width: 0; } + +.list-group + .panel-footer { + border-top-width: 0; } + +.panel > .panel-collapse > .table, .panel > .table, .panel > .table-responsive > .table { + margin-bottom: 0; } + +.panel > .panel-collapse > .table caption, .panel > .table caption, .panel > .table-responsive > .table caption { + padding-right: 15px; + padding-left: 15px; } + +.panel > .table-responsive:first-child > .table:first-child, .panel > .table:first-child { + border-top-left-radius: 3px; + border-top-right-radius: 3px; } + +.panel > .table-responsive:first-child > .table:first-child > tbody:first-child > tr:first-child, .panel > .table-responsive:first-child > .table:first-child > thead:first-child > tr:first-child, .panel > .table:first-child > tbody:first-child > tr:first-child, .panel > .table:first-child > thead:first-child > tr:first-child { + border-top-left-radius: 3px; + border-top-right-radius: 3px; } + +.panel > .table-responsive:first-child > .table:first-child > tbody:first-child > tr:first-child td:first-child, .panel > .table-responsive:first-child > .table:first-child > tbody:first-child > tr:first-child th:first-child, .panel > .table-responsive:first-child > .table:first-child > thead:first-child > tr:first-child td:first-child, .panel > .table-responsive:first-child > .table:first-child > thead:first-child > tr:first-child th:first-child, .panel > .table:first-child > tbody:first-child > tr:first-child td:first-child, .panel > .table:first-child > tbody:first-child > tr:first-child th:first-child, .panel > .table:first-child > thead:first-child > tr:first-child td:first-child, .panel > .table:first-child > thead:first-child > tr:first-child th:first-child { + border-top-left-radius: 3px; } + +.panel > .table-responsive:first-child > .table:first-child > tbody:first-child > tr:first-child td:last-child, .panel > .table-responsive:first-child > .table:first-child > tbody:first-child > tr:first-child th:last-child, .panel > .table-responsive:first-child > .table:first-child > thead:first-child > tr:first-child td:last-child, .panel > .table-responsive:first-child > .table:first-child > thead:first-child > tr:first-child th:last-child, .panel > .table:first-child > tbody:first-child > tr:first-child td:last-child, .panel > .table:first-child > tbody:first-child > tr:first-child th:last-child, .panel > .table:first-child > thead:first-child > tr:first-child td:last-child, .panel > .table:first-child > thead:first-child > tr:first-child th:last-child { + border-top-right-radius: 3px; } + +.panel > .table-responsive:last-child > .table:last-child, .panel > .table:last-child { + border-bottom-right-radius: 3px; + border-bottom-left-radius: 3px; } + +.panel > .table-responsive:last-child > .table:last-child > tbody:last-child > tr:last-child, .panel > .table-responsive:last-child > .table:last-child > tfoot:last-child > tr:last-child, .panel > .table:last-child > tbody:last-child > tr:last-child, .panel > .table:last-child > tfoot:last-child > tr:last-child { + border-bottom-right-radius: 3px; + border-bottom-left-radius: 3px; } + +.panel > .table-responsive:last-child > .table:last-child > tbody:last-child > tr:last-child td:first-child, .panel > .table-responsive:last-child > .table:last-child > tbody:last-child > tr:last-child th:first-child, .panel > .table-responsive:last-child > .table:last-child > tfoot:last-child > tr:last-child td:first-child, .panel > .table-responsive:last-child > .table:last-child > tfoot:last-child > tr:last-child th:first-child, .panel > .table:last-child > tbody:last-child > tr:last-child td:first-child, .panel > .table:last-child > tbody:last-child > tr:last-child th:first-child, .panel > .table:last-child > tfoot:last-child > tr:last-child td:first-child, .panel > .table:last-child > tfoot:last-child > tr:last-child th:first-child { + border-bottom-left-radius: 3px; } + +.panel > .table-responsive:last-child > .table:last-child > tbody:last-child > tr:last-child td:last-child, .panel > .table-responsive:last-child > .table:last-child > tbody:last-child > tr:last-child th:last-child, .panel > .table-responsive:last-child > .table:last-child > tfoot:last-child > tr:last-child td:last-child, .panel > .table-responsive:last-child > .table:last-child > tfoot:last-child > tr:last-child th:last-child, .panel > .table:last-child > tbody:last-child > tr:last-child td:last-child, .panel > .table:last-child > tbody:last-child > tr:last-child th:last-child, .panel > .table:last-child > tfoot:last-child > tr:last-child td:last-child, .panel > .table:last-child > tfoot:last-child > tr:last-child th:last-child { + border-bottom-right-radius: 3px; } + +.panel > .panel-body + .table, .panel > .panel-body + .table-responsive, .panel > .table + .panel-body, .panel > .table-responsive + .panel-body { + border-top: 1px solid #ddd; } + +.panel > .table > tbody:first-child > tr:first-child td, .panel > .table > tbody:first-child > tr:first-child th { + border-top: 0; } + +.panel > .table-bordered, .panel > .table-responsive > .table-bordered { + border: 0; } + +.panel > .table-bordered > tbody > tr > td:first-child, .panel > .table-bordered > tbody > tr > th:first-child, .panel > .table-bordered > tfoot > tr > td:first-child, .panel > .table-bordered > tfoot > tr > th:first-child, .panel > .table-bordered > thead > tr > td:first-child, .panel > .table-bordered > thead > tr > th:first-child, .panel > .table-responsive > .table-bordered > tbody > tr > td:first-child, .panel > .table-responsive > .table-bordered > tbody > tr > th:first-child, .panel > .table-responsive > .table-bordered > tfoot > tr > td:first-child, .panel > .table-responsive > .table-bordered > tfoot > tr > th:first-child, .panel > .table-responsive > .table-bordered > thead > tr > td:first-child, .panel > .table-responsive > .table-bordered > thead > tr > th:first-child { + border-left: 0; } + +.panel > .table-bordered > tbody > tr > td:last-child, .panel > .table-bordered > tbody > tr > th:last-child, .panel > .table-bordered > tfoot > tr > td:last-child, .panel > .table-bordered > tfoot > tr > th:last-child, .panel > .table-bordered > thead > tr > td:last-child, .panel > .table-bordered > thead > tr > th:last-child, .panel > .table-responsive > .table-bordered > tbody > tr > td:last-child, .panel > .table-responsive > .table-bordered > tbody > tr > th:last-child, .panel > .table-responsive > .table-bordered > tfoot > tr > td:last-child, .panel > .table-responsive > .table-bordered > tfoot > tr > th:last-child, .panel > .table-responsive > .table-bordered > thead > tr > td:last-child, .panel > .table-responsive > .table-bordered > thead > tr > th:last-child { + border-right: 0; } + +.panel > .table-bordered > tbody > tr:first-child > td, .panel > .table-bordered > tbody > tr:first-child > th, .panel > .table-bordered > thead > tr:first-child > td, .panel > .table-bordered > thead > tr:first-child > th, .panel > .table-responsive > .table-bordered > tbody > tr:first-child > td, .panel > .table-responsive > .table-bordered > tbody > tr:first-child > th, .panel > .table-responsive > .table-bordered > thead > tr:first-child > td, .panel > .table-responsive > .table-bordered > thead > tr:first-child > th { + border-bottom: 0; } + +.panel > .table-bordered > tbody > tr:last-child > td, .panel > .table-bordered > tbody > tr:last-child > th, .panel > .table-bordered > tfoot > tr:last-child > td, .panel > .table-bordered > tfoot > tr:last-child > th, .panel > .table-responsive > .table-bordered > tbody > tr:last-child > td, .panel > .table-responsive > .table-bordered > tbody > tr:last-child > th, .panel > .table-responsive > .table-bordered > tfoot > tr:last-child > td, .panel > .table-responsive > .table-bordered > tfoot > tr:last-child > th { + border-bottom: 0; } + +.panel > .table-responsive { + margin-bottom: 0; + border: 0; } + +.panel-group { + margin-bottom: 20px; } + +.panel-group .panel { + margin-bottom: 0; + border-radius: 4px; } + +.panel-group .panel + .panel { + margin-top: 5px; } + +.panel-group .panel-heading { + border-bottom: 0; } + +.panel-group .panel-heading + .panel-collapse > .list-group, .panel-group .panel-heading + .panel-collapse > .panel-body { + border-top: 1px solid #ddd; } + +.panel-group .panel-footer { + border-top: 0; } + +.panel-group .panel-footer + .panel-collapse .panel-body { + border-bottom: 1px solid #ddd; } + +.panel-default { + border-color: #ddd; } + +.panel-default > .panel-heading { + color: #333; + background-color: #f5f5f5; + border-color: #ddd; } + +.panel-default > .panel-heading + .panel-collapse > .panel-body { + border-top-color: #ddd; } + +.panel-default > .panel-heading .badge { + color: #f5f5f5; + background-color: #333; } + +.panel-default > .panel-footer + .panel-collapse > .panel-body { + border-bottom-color: #ddd; } + +.panel-primary { + border-color: #337ab7; } + +.panel-primary > .panel-heading { + color: #fff; + background-color: #337ab7; + border-color: #337ab7; } + +.panel-primary > .panel-heading + .panel-collapse > .panel-body { + border-top-color: #337ab7; } + +.panel-primary > .panel-heading .badge { + color: #337ab7; + background-color: #fff; } + +.panel-primary > .panel-footer + .panel-collapse > .panel-body { + border-bottom-color: #337ab7; } + +.panel-success { + border-color: #d6e9c6; } + +.panel-success > .panel-heading { + color: #3c763d; + background-color: #dff0d8; + border-color: #d6e9c6; } + +.panel-success > .panel-heading + .panel-collapse > .panel-body { + border-top-color: #d6e9c6; } + +.panel-success > .panel-heading .badge { + color: #dff0d8; + background-color: #3c763d; } + +.panel-success > .panel-footer + .panel-collapse > .panel-body { + border-bottom-color: #d6e9c6; } + +.panel-info { + border-color: #bce8f1; } + +.panel-info > .panel-heading { + color: #31708f; + background-color: #d9edf7; + border-color: #bce8f1; } + +.panel-info > .panel-heading + .panel-collapse > .panel-body { + border-top-color: #bce8f1; } + +.panel-info > .panel-heading .badge { + color: #d9edf7; + background-color: #31708f; } + +.panel-info > .panel-footer + .panel-collapse > .panel-body { + border-bottom-color: #bce8f1; } + +.panel-warning { + border-color: #faebcc; } + +.panel-warning > .panel-heading { + color: #8a6d3b; + background-color: #fcf8e3; + border-color: #faebcc; } + +.panel-warning > .panel-heading + .panel-collapse > .panel-body { + border-top-color: #faebcc; } + +.panel-warning > .panel-heading .badge { + color: #fcf8e3; + background-color: #8a6d3b; } + +.panel-warning > .panel-footer + .panel-collapse > .panel-body { + border-bottom-color: #faebcc; } + +.panel-danger { + border-color: #ebccd1; } + +.panel-danger > .panel-heading { + color: #a94442; + background-color: #f2dede; + border-color: #ebccd1; } + +.panel-danger > .panel-heading + .panel-collapse > .panel-body { + border-top-color: #ebccd1; } + +.panel-danger > .panel-heading .badge { + color: #f2dede; + background-color: #a94442; } + +.panel-danger > .panel-footer + .panel-collapse > .panel-body { + border-bottom-color: #ebccd1; } + +.embed-responsive { + position: relative; + display: block; + height: 0; + padding: 0; + overflow: hidden; } + +.embed-responsive .embed-responsive-item, .embed-responsive embed, .embed-responsive iframe, .embed-responsive object, .embed-responsive video { + position: absolute; + top: 0; + bottom: 0; + left: 0; + width: 100%; + height: 100%; + border: 0; } + +.embed-responsive.embed-responsive-16by9 { + padding-bottom: 56.25%; } + +.embed-responsive.embed-responsive-4by3 { + padding-bottom: 75%; } + +.well { + min-height: 20px; + padding: 19px; + margin-bottom: 20px; + background-color: #f5f5f5; + border: 1px solid #e3e3e3; + border-radius: 4px; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.05); + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.05); } + +.well blockquote { + border-color: #ddd; + border-color: rgba(0, 0, 0, 0.15); } + +.well-lg { + padding: 24px; + border-radius: 6px; } + +.well-sm { + padding: 9px; + border-radius: 3px; } + +.close { + float: right; + font-size: 21px; + font-weight: 700; + line-height: 1; + color: #000; + text-shadow: 0 1px 0 #fff; + filter: alpha(opacity=20); + opacity: .2; } + +.close:focus, .close:hover { + color: #000; + text-decoration: none; + cursor: pointer; + filter: alpha(opacity=50); + opacity: .5; } + +button.close { + -webkit-appearance: none; + padding: 0; + cursor: pointer; + background: 0 0; + border: 0; } + +.modal-open { + overflow: hidden; } + +.modal { + position: fixed; + top: 0; + right: 0; + bottom: 0; + left: 0; + z-index: 1040; + display: none; + overflow: hidden; + -webkit-overflow-scrolling: touch; + outline: 0; } + +.modal.fade .modal-dialog { + -webkit-transition: -webkit-transform 0.3s ease-out; + -o-transition: -o-transform 0.3s ease-out; + transition: transform 0.3s ease-out; + -webkit-transform: translate(0, -25%); + -ms-transform: translate(0, -25%); + -o-transform: translate(0, -25%); + transform: translate(0, -25%); } + +.modal.in .modal-dialog { + -webkit-transform: translate(0, 0); + -ms-transform: translate(0, 0); + -o-transform: translate(0, 0); + transform: translate(0, 0); } + +.modal-open .modal { + overflow-x: hidden; + overflow-y: auto; } + +.modal-dialog { + position: relative; + width: auto; + margin: 10px; } + +.modal-content { + position: relative; + background-color: #fff; + -webkit-background-clip: padding-box; + background-clip: padding-box; + border: 1px solid #999; + border: 1px solid rgba(0, 0, 0, 0.2); + border-radius: 6px; + outline: 0; + -webkit-box-shadow: 0 3px 9px rgba(0, 0, 0, 0.5); + box-shadow: 0 3px 9px rgba(0, 0, 0, 0.5); } + +.modal-backdrop { + position: absolute; + top: 0; + right: 0; + left: 0; + background-color: #000; } + +.modal-backdrop.fade { + filter: alpha(opacity=0); + opacity: 0; } + +.modal-backdrop.in { + filter: alpha(opacity=50); + opacity: .5; } + +.modal-header { + min-height: 16.43px; + padding: 15px; + border-bottom: 1px solid #e5e5e5; } + +.modal-header .close { + margin-top: -2px; } + +.modal-title { + margin: 0; + line-height: 1.42857143; } + +.modal-body { + position: relative; + padding: 15px; } + +.modal-footer { + padding: 15px; + text-align: right; + border-top: 1px solid #e5e5e5; } + +.modal-footer .btn + .btn { + margin-bottom: 0; + margin-left: 5px; } + +.modal-footer .btn-group .btn + .btn { + margin-left: -1px; } + +.modal-footer .btn-block + .btn-block { + margin-left: 0; } + +.modal-scrollbar-measure { + position: absolute; + top: -9999px; + width: 50px; + height: 50px; + overflow: scroll; } + +@media (min-width: 768px) { + .modal-dialog { + width: 600px; + margin: 30px auto; } + .modal-content { + -webkit-box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5); + box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5); } + .modal-sm { + width: 300px; } } + +@media (min-width: 992px) { + .modal-lg { + width: 900px; } } + +.tooltip { + position: absolute; + z-index: 1070; + display: block; + font-family: "Helvetica Neue", Helvetica, Arial, sans-serif; + font-size: 12px; + font-weight: 400; + line-height: 1.4; + visibility: visible; + filter: alpha(opacity=0); + opacity: 0; } + +.tooltip.in { + filter: alpha(opacity=90); + opacity: .9; } + +.tooltip.top { + padding: 5px 0; + margin-top: -3px; } + +.tooltip.right { + padding: 0 5px; + margin-left: 3px; } + +.tooltip.bottom { + padding: 5px 0; + margin-top: 3px; } + +.tooltip.left { + padding: 0 5px; + margin-left: -3px; } + +.tooltip-inner { + max-width: 200px; + padding: 3px 8px; + color: #fff; + text-align: center; + text-decoration: none; + background-color: #000; + border-radius: 4px; } + +.tooltip-arrow { + position: absolute; + width: 0; + height: 0; + border-color: transparent; + border-style: solid; } + +.tooltip.top .tooltip-arrow { + bottom: 0; + left: 50%; + margin-left: -5px; + border-width: 5px 5px 0; + border-top-color: #000; } + +.tooltip.top-left .tooltip-arrow { + right: 5px; + bottom: 0; + margin-bottom: -5px; + border-width: 5px 5px 0; + border-top-color: #000; } + +.tooltip.top-right .tooltip-arrow { + bottom: 0; + left: 5px; + margin-bottom: -5px; + border-width: 5px 5px 0; + border-top-color: #000; } + +.tooltip.right .tooltip-arrow { + top: 50%; + left: 0; + margin-top: -5px; + border-width: 5px 5px 5px 0; + border-right-color: #000; } + +.tooltip.left .tooltip-arrow { + top: 50%; + right: 0; + margin-top: -5px; + border-width: 5px 0 5px 5px; + border-left-color: #000; } + +.tooltip.bottom .tooltip-arrow { + top: 0; + left: 50%; + margin-left: -5px; + border-width: 0 5px 5px; + border-bottom-color: #000; } + +.tooltip.bottom-left .tooltip-arrow { + top: 0; + right: 5px; + margin-top: -5px; + border-width: 0 5px 5px; + border-bottom-color: #000; } + +.tooltip.bottom-right .tooltip-arrow { + top: 0; + left: 5px; + margin-top: -5px; + border-width: 0 5px 5px; + border-bottom-color: #000; } + +.popover { + position: absolute; + top: 0; + left: 0; + z-index: 1060; + display: none; + max-width: 276px; + padding: 1px; + font-family: "Helvetica Neue", Helvetica, Arial, sans-serif; + font-size: 14px; + font-weight: 400; + line-height: 1.42857143; + text-align: left; + white-space: normal; + background-color: #fff; + -webkit-background-clip: padding-box; + background-clip: padding-box; + border: 1px solid #ccc; + border: 1px solid rgba(0, 0, 0, 0.2); + border-radius: 6px; + -webkit-box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2); + box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2); } + +.popover.top { + margin-top: -10px; } + +.popover.right { + margin-left: 10px; } + +.popover.bottom { + margin-top: 10px; } + +.popover.left { + margin-left: -10px; } + +.popover-title { + padding: 8px 14px; + margin: 0; + font-size: 14px; + background-color: #f7f7f7; + border-bottom: 1px solid #ebebeb; + border-radius: 5px 5px 0 0; } + +.popover-content { + padding: 9px 14px; } + +.popover > .arrow, .popover > .arrow:after { + position: absolute; + display: block; + width: 0; + height: 0; + border-color: transparent; + border-style: solid; } + +.popover > .arrow { + border-width: 11px; } + +.popover > .arrow:after { + content: ""; + border-width: 10px; } + +.popover.top > .arrow { + bottom: -11px; + left: 50%; + margin-left: -11px; + border-top-color: #999; + border-top-color: rgba(0, 0, 0, 0.25); + border-bottom-width: 0; } + +.popover.top > .arrow:after { + bottom: 1px; + margin-left: -10px; + content: " "; + border-top-color: #fff; + border-bottom-width: 0; } + +.popover.right > .arrow { + top: 50%; + left: -11px; + margin-top: -11px; + border-right-color: #999; + border-right-color: rgba(0, 0, 0, 0.25); + border-left-width: 0; } + +.popover.right > .arrow:after { + bottom: -10px; + left: 1px; + content: " "; + border-right-color: #fff; + border-left-width: 0; } + +.popover.bottom > .arrow { + top: -11px; + left: 50%; + margin-left: -11px; + border-top-width: 0; + border-bottom-color: #999; + border-bottom-color: rgba(0, 0, 0, 0.25); } + +.popover.bottom > .arrow:after { + top: 1px; + margin-left: -10px; + content: " "; + border-top-width: 0; + border-bottom-color: #fff; } + +.popover.left > .arrow { + top: 50%; + right: -11px; + margin-top: -11px; + border-right-width: 0; + border-left-color: #999; + border-left-color: rgba(0, 0, 0, 0.25); } + +.popover.left > .arrow:after { + right: 1px; + bottom: -10px; + content: " "; + border-right-width: 0; + border-left-color: #fff; } + +.carousel { + position: relative; } + +.carousel-inner { + position: relative; + width: 100%; + overflow: hidden; } + +.carousel-inner > .item { + position: relative; + display: none; + -webkit-transition: .6s ease-in-out left; + -o-transition: .6s ease-in-out left; + transition: .6s ease-in-out left; } + +.carousel-inner > .item > a > img, .carousel-inner > .item > img { + line-height: 1; } + +@media all and (transform-3d), (-webkit-transform-3d) { + .carousel-inner > .item { + -webkit-transition: -webkit-transform 0.6s ease-in-out; + -o-transition: -o-transform 0.6s ease-in-out; + transition: transform 0.6s ease-in-out; + -webkit-backface-visibility: hidden; + backface-visibility: hidden; + -webkit-perspective: 1000; + perspective: 1000; } + .carousel-inner > .item.active.right, .carousel-inner > .item.next { + left: 0; + -webkit-transform: translate3d(100%, 0, 0); + transform: translate3d(100%, 0, 0); } + .carousel-inner > .item.active.left, .carousel-inner > .item.prev { + left: 0; + -webkit-transform: translate3d(-100%, 0, 0); + transform: translate3d(-100%, 0, 0); } + .carousel-inner > .item.active, .carousel-inner > .item.next.left, .carousel-inner > .item.prev.right { + left: 0; + -webkit-transform: translate3d(0, 0, 0); + transform: translate3d(0, 0, 0); } } + +.carousel-inner > .active, .carousel-inner > .next, .carousel-inner > .prev { + display: block; } + +.carousel-inner > .active { + left: 0; } + +.carousel-inner > .next, .carousel-inner > .prev { + position: absolute; + top: 0; + width: 100%; } + +.carousel-inner > .next { + left: 100%; } + +.carousel-inner > .prev { + left: -100%; } + +.carousel-inner > .next.left, .carousel-inner > .prev.right { + left: 0; } + +.carousel-inner > .active.left { + left: -100%; } + +.carousel-inner > .active.right { + left: 100%; } + +.carousel-control { + position: absolute; + top: 0; + bottom: 0; + left: 0; + width: 15%; + font-size: 20px; + color: #fff; + text-align: center; + text-shadow: 0 1px 2px rgba(0, 0, 0, 0.6); + filter: alpha(opacity=50); + opacity: .5; } + +.carousel-control.left { + background-image: -webkit-linear-gradient(left, rgba(0, 0, 0, 0.5) 0, rgba(0, 0, 0, 0.0001) 100%); + background-image: -o-linear-gradient(left, rgba(0, 0, 0, 0.5) 0, rgba(0, 0, 0, 0.0001) 100%); + background-image: -webkit-gradient(linear, left top, right top, from(rgba(0, 0, 0, 0.5)), to(rgba(0, 0, 0, 0.0001))); + background-image: linear-gradient(to right, rgba(0, 0, 0, 0.5) 0, rgba(0, 0, 0, 0.0001) 100%); + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#80000000', endColorstr='#00000000', GradientType=1); + background-repeat: repeat-x; } + +.carousel-control.right { + right: 0; + left: auto; + background-image: -webkit-linear-gradient(left, rgba(0, 0, 0, 0.0001) 0, rgba(0, 0, 0, 0.5) 100%); + background-image: -o-linear-gradient(left, rgba(0, 0, 0, 0.0001) 0, rgba(0, 0, 0, 0.5) 100%); + background-image: -webkit-gradient(linear, left top, right top, from(rgba(0, 0, 0, 0.0001)), to(rgba(0, 0, 0, 0.5))); + background-image: linear-gradient(to right, rgba(0, 0, 0, 0.0001) 0, rgba(0, 0, 0, 0.5) 100%); + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#00000000', endColorstr='#80000000', GradientType=1); + background-repeat: repeat-x; } + +.carousel-control:focus, .carousel-control:hover { + color: #fff; + text-decoration: none; + filter: alpha(opacity=90); + outline: 0; + opacity: .9; } + +.carousel-control .glyphicon-chevron-left, .carousel-control .glyphicon-chevron-right, .carousel-control .icon-next, .carousel-control .icon-prev { + position: absolute; + top: 50%; + z-index: 5; + display: inline-block; } + +.carousel-control .glyphicon-chevron-left, .carousel-control .icon-prev { + left: 50%; + margin-left: -10px; } + +.carousel-control .glyphicon-chevron-right, .carousel-control .icon-next { + right: 50%; + margin-right: -10px; } + +.carousel-control .icon-next, .carousel-control .icon-prev { + width: 20px; + height: 20px; + margin-top: -10px; + font-family: serif; + line-height: 1; } + +.carousel-control .icon-prev:before { + content: '\2039'; } + +.carousel-control .icon-next:before { + content: '\203a'; } + +.carousel-indicators { + position: absolute; + bottom: 10px; + left: 50%; + z-index: 15; + width: 60%; + padding-left: 0; + margin-left: -30%; + text-align: center; + list-style: none; } + +.carousel-indicators li { + display: inline-block; + width: 10px; + height: 10px; + margin: 1px; + text-indent: -999px; + cursor: pointer; + background-color: #000 \9; + background-color: transparent; + border: 1px solid #fff; + border-radius: 10px; } + +.carousel-indicators .active { + width: 12px; + height: 12px; + margin: 0; + background-color: #fff; } + +.carousel-caption { + position: absolute; + right: 15%; + bottom: 20px; + left: 15%; + z-index: 10; + padding-top: 20px; + padding-bottom: 20px; + color: #fff; + text-align: center; + text-shadow: 0 1px 2px rgba(0, 0, 0, 0.6); } + +.carousel-caption .btn { + text-shadow: none; } + +@media screen and (min-width: 768px) { + .carousel-control .glyphicon-chevron-left, .carousel-control .glyphicon-chevron-right, .carousel-control .icon-next, .carousel-control .icon-prev { + width: 30px; + height: 30px; + margin-top: -15px; + font-size: 30px; } + .carousel-control .glyphicon-chevron-left, .carousel-control .icon-prev { + margin-left: -15px; } + .carousel-control .glyphicon-chevron-right, .carousel-control .icon-next { + margin-right: -15px; } + .carousel-caption { + right: 20%; + left: 20%; + padding-bottom: 30px; } + .carousel-indicators { + bottom: 20px; } } + +.btn-group-vertical > .btn-group:after, .btn-group-vertical > .btn-group:before, .btn-toolbar:after, .btn-toolbar:before, .clearfix:after, .clearfix:before, .container-fluid:after, .container-fluid:before, .container:after, .container:before, .dl-horizontal dd:after, .dl-horizontal dd:before, .form-horizontal .form-group:after, .form-horizontal .form-group:before, .modal-footer:after, .modal-footer:before, .nav:after, .nav:before, .navbar-collapse:after, .navbar-collapse:before, .navbar-header:after, .navbar-header:before, .navbar:after, .navbar:before, .pager:after, .pager:before, .panel-body:after, .panel-body:before, .row:after, .row:before { + display: table; + content: " "; } + +.btn-group-vertical > .btn-group:after, .btn-toolbar:after, .clearfix:after, .container-fluid:after, .container:after, .dl-horizontal dd:after, .form-horizontal .form-group:after, .modal-footer:after, .nav:after, .navbar-collapse:after, .navbar-header:after, .navbar:after, .pager:after, .panel-body:after, .row:after { + clear: both; } + +.center-block { + display: block; + margin-right: auto; + margin-left: auto; } + +.pull-right { + float: right !important; } + +.pull-left { + float: left !important; } + +.invisible { + visibility: hidden; } + +.text-hide { + font: 0/0 a; + color: transparent; + text-shadow: none; + background-color: transparent; + border: 0; } + +.hidden { + display: none !important; + visibility: hidden !important; } + +.affix { + position: fixed; } + +@-ms-viewport { + width: device-width; } + +.visible-lg, .visible-md, .visible-sm, .visible-xs { + display: none !important; } + +.visible-lg-block, .visible-lg-inline, .visible-lg-inline-block, .visible-md-block, .visible-md-inline, .visible-md-inline-block, .visible-sm-block, .visible-sm-inline, .visible-sm-inline-block, .visible-xs-block, .visible-xs-inline, .visible-xs-inline-block { + display: none !important; } + +@media (max-width: 767px) { + .visible-xs { + display: block !important; } + table.visible-xs { + display: table; } + tr.visible-xs { + display: table-row !important; } + td.visible-xs, th.visible-xs { + display: table-cell !important; } } + +@media (max-width: 767px) { + .visible-xs-block { + display: block !important; } } + +@media (max-width: 767px) { + .visible-xs-inline { + display: inline !important; } } + +@media (max-width: 767px) { + .visible-xs-inline-block { + display: inline-block !important; } } + +@media (min-width: 768px) and (max-width: 991px) { + .visible-sm { + display: block !important; } + table.visible-sm { + display: table; } + tr.visible-sm { + display: table-row !important; } + td.visible-sm, th.visible-sm { + display: table-cell !important; } } + +@media (min-width: 768px) and (max-width: 991px) { + .visible-sm-block { + display: block !important; } } + +@media (min-width: 768px) and (max-width: 991px) { + .visible-sm-inline { + display: inline !important; } } + +@media (min-width: 768px) and (max-width: 991px) { + .visible-sm-inline-block { + display: inline-block !important; } } + +@media (min-width: 992px) and (max-width: 1199px) { + .visible-md { + display: block !important; } + table.visible-md { + display: table; } + tr.visible-md { + display: table-row !important; } + td.visible-md, th.visible-md { + display: table-cell !important; } } + +@media (min-width: 992px) and (max-width: 1199px) { + .visible-md-block { + display: block !important; } } + +@media (min-width: 992px) and (max-width: 1199px) { + .visible-md-inline { + display: inline !important; } } + +@media (min-width: 992px) and (max-width: 1199px) { + .visible-md-inline-block { + display: inline-block !important; } } + +@media (min-width: 1200px) { + .visible-lg { + display: block !important; } + table.visible-lg { + display: table; } + tr.visible-lg { + display: table-row !important; } + td.visible-lg, th.visible-lg { + display: table-cell !important; } } + +@media (min-width: 1200px) { + .visible-lg-block { + display: block !important; } } + +@media (min-width: 1200px) { + .visible-lg-inline { + display: inline !important; } } + +@media (min-width: 1200px) { + .visible-lg-inline-block { + display: inline-block !important; } } + +@media (max-width: 767px) { + .hidden-xs { + display: none !important; } } + +@media (min-width: 768px) and (max-width: 991px) { + .hidden-sm { + display: none !important; } } + +@media (min-width: 992px) and (max-width: 1199px) { + .hidden-md { + display: none !important; } } + +@media (min-width: 1200px) { + .hidden-lg { + display: none !important; } } + +.visible-print { + display: none !important; } + +@media print { + .visible-print { + display: block !important; } + table.visible-print { + display: table; } + tr.visible-print { + display: table-row !important; } + td.visible-print, th.visible-print { + display: table-cell !important; } } + +.visible-print-block { + display: none !important; } + +@media print { + .visible-print-block { + display: block !important; } } + +.visible-print-inline { + display: none !important; } + +@media print { + .visible-print-inline { + display: inline !important; } } + +.visible-print-inline-block { + display: none !important; } + +@media print { + .visible-print-inline-block { + display: inline-block !important; } } + +@media print { + .hidden-print { + display: none !important; } } + +/* Private */ +/* Variables */ +/* Precision rounding function */ +/* Scale */ +/* Prefix */ +/* Value Prefix*/ +/* Font size */ +/* Box sizing */ +/* Borders & Shadows */ +/* Opacity */ +/* Ellipsis */ +/* Vertical placement of multuple lines of text */ +/* transform-rotate */ +/* transform-scale */ +/**/ +/* Clearfix */ +/* Bottom positioning */ +/* Fonts */ +@font-face { + font-family: SourceSanPro-Light; + src: url("../fonts/SourceSansPro-Light.otf"); } + +@font-face { + font-family: SourceSanPro-Regular; + src: url("../fonts/SourceSansPro-Regular.otf"); } + +@font-face { + font-family: SourceSanPro-Semibold; + src: url("../fonts/SourceSansPro-Semibold.otf"); } + +.nfv-heading-1, .nfv-header .header-content-wrapper .header-title .main-title, .nfv-header .header-content-wrapper .header-title .version-select, .service-overview-tab .service-metrics .service-metric .metric-details .metric-value { + font-family: "SourceSanPro-Light"; + font-size: 32px; } + +.nfv-heading-2, .nfv-wizard-header .wizard .nfv-wizard-steps .wizard-step .step-item, .launch-service-wizard .nfv-wizard-content .select-service-title, .launch-service-wizard .nfv-wizard-content .launch-service-title, .launch-service-wizard .nfv-wizard-content .parameters-service-title, .service-overview-tab .service-detailed-info .service-tasks .list-header, .service-overview-tab .service-detailed-info .service-events .list-header, .service-overview-tab .service-detailed-info .service-performance .services-performance-header, .nfv-landing-page .landing-page-view h2 { + font-family: "SourceSanPro-Light"; + font-size: 27px; } + +.nfv-heading-3 { + font-family: "SourceSanPro-Light"; + font-size: 25px; } + +.nfv-heading-4, .service-attributes .form-container .form-element--label, .modify-service-wizard .impact-view .impact-view-title { + font-family: "SourceSanPro-Regular"; + font-size: 22px; } + +.nfv-body-1, .ui-dialog[role="dialog"] .ui-dialog-titlebar .ui-dialog-title, .nfv-header .header-content-wrapper .header-title .version-select select, .nfv-wizard-header .wizard .nfv-wizard-steps .wizard-step .step-title, .nfv-tabpanel .nfv-tabs-v1 .ui-state-default .ui-tabs-anchor, .nfv-tabpanel .nfv-tabs-v1 .ui-state-default.ui-state-active .ui-tabs-anchor, .nfv-tabpanel .nfv-tabs-v2 .ui-state-default .ui-tabs-anchor, .nfv-tabpanel .nfv-tabs-v2 .ui-state-default.ui-state-active .ui-tabs-anchor, .nfv-tabpanel .nfv-tabs-v3 .ui-state-default .ui-tabs-anchor, .nfv-tabpanel .nfv-tabs-v3 .ui-state-default.ui-state-active .ui-tabs-anchor, .nfv-tabpanel .nfv-tabs .ui-state-default .ui-tabs-anchor, .nfv-tabpanel .nfv-tabs .ui-state-default.ui-state-active .ui-tabs-anchor, body.theme2 .nfv-tabs-v3 .ui-state-default .ui-tabs-anchor, body.theme2 .nfv-tabs-v3 .ui-state-default.ui-state-active .ui-tabs-anchor, .notification .notification-header, .notification .notification-content .notification-main, .service-overview-tab .service-metrics .service-metric .metric-details .desc, .service-overview-tab .service-detailed-info .service-tasks .task-list-item .task-message, .service-overview-tab .service-detailed-info .service-events .event-list-item .event-item-content .event-message, .nfv-landing-page .landing-page-view .lists-box .events ul > li time, .nfv-landing-page .landing-page-view .lists-box .services ul > li > h3 { + font-family: "SourceSanPro-Regular"; + font-size: 15px; } + +.nfv-body-2, .nfv-header .tasks-notifications-container .notifications-popup .notifications-popup-header, .nfv-button-link .uxf-button .ui-button-text, .nfv-button-link.ui-button-text-only .ui-button-text, .LS-error, .nfv-wizard-header .wizard .nfv-wizard-steps .wizard-step.active .step-title, .nfv-balloon .balloon-header .balloon-title, .network-topology-view .right-pane-controller .header .node-attributes-title, .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .node-attribute-list-item:first-child .node-attribute, .network-topology-view .right-pane-controller .node-attributes .nfv-collapsible-item .nfv-collapsible-content .kpi-item .kpi-item-value, .network-topology-view .right-pane-controller .node-attributes .nfv-collapsible-item .nfv-collapsible-content .kpi-item .kpi-item-name, body.theme2 .network-topology-view .right-pane-controller .node-attributes .nfv-collapsible-item .nfv-collapsible-content .kpi-item .kpi-item-value, body.theme2 .network-topology-view .right-pane-controller .node-attributes .nfv-collapsible-item .nfv-collapsible-content .kpi-item .kpi-item-name, .service-overview-tab .service-metrics .service-status .service-details .status, .system-tasks .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item, .tasks-notifications-container .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item, .system-tasks .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .serviceTitles .serviceName, .tasks-notifications-container .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .serviceTitles .serviceName, .system-tasks .task-details-container .task-details-header, .tasks-notifications-container .task-details-container .task-details-header, .system-tasks .task-details-container .task-details-header .serviceTitles .serviceName, .tasks-notifications-container .task-details-container .task-details-header .serviceTitles .serviceName { + font-family: "SourceSanPro-Semibold"; + font-size: 15px; } + +.nfv-body-3, input, .nfv-header .header-content-wrapper .header-title .sub-title, .ui-state-default.ui-button .ui-button-text, +.ui-widget-content .ui-state-default.ui-button .ui-button-text, +.ui-widget-header .ui-state-default.ui-button .ui-button-text, .nfv-link, .uxf-selectinput select, .form-element select, .nfv-balloon .balloon-content .node-attribute, .network-graph .element.nfvo .label, .tree-graph .node text, .nfv-pagination a, .uxf-pagination a, .notification .notification-content .notification-secondary, .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .node-attribute-list-item .node-attribute, .service-attributes .form-element .form-element--label, .service-attributes .form-element .form-element--error-message, .launch-service-wizard .nfv-wizard-content .service-list-item .service-name .service-version, .service-overview-tab .service-metrics .service-status .service-details .service-times, .service-overview-tab .service-detailed-info .service-tasks .list-header .recent-notice, .service-overview-tab .service-detailed-info .service-events .list-header .recent-notice, .service-overview-tab .service-detailed-info .service-tasks .task-list-item .task-time .due, body.theme2 .service-overview-tab .service-detailed-info .service-tasks .task-list-item .task-time .due, .system-tasks .tasks-list-container .filters, .tasks-notifications-container .tasks-list-container .filters, .system-tasks .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .serviceTitles .customer, .tasks-notifications-container .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .serviceTitles .customer, .system-tasks .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .contentPreview, .tasks-notifications-container .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .contentPreview, .system-tasks .task-details-container .task-details-header .serviceTitles .customer, .tasks-notifications-container .task-details-container .task-details-header .serviceTitles .customer, .system-tasks .task-details-container .task-details-header .dueDateGroup, .tasks-notifications-container .task-details-container .task-details-header .dueDateGroup, .system-tasks .task-details-container .task-details-header .description, .tasks-notifications-container .task-details-container .task-details-header .description, .nfv-landing-page .landing-page-view h2 .see-all-link span, .nfv-landing-page .landing-page-view .lists-box .events ul > li .event-message p, .nfv-landing-page .landing-page-view .lists-box .events ul > li .machine-id, .nfv-landing-page .landing-page-view .lists-box .services ul > li > label, .nfv-landing-page .landing-page-view .lists-box .services ul > li > time { + font-family: "SourceSanPro-Regular"; + font-size: 13px; } + +.nfv-body-4, .nfv-header .tasks-notifications-container .notifications-popup .notifications-popup-user-menu .version-and-build, .service-attributes .form-element input, .service-attributes .form-element select, .service-overview-tab .service-detailed-info .service-tasks .see-all-link, .service-overview-tab .service-detailed-info .service-events .see-all-link, .service-overview-tab .service-detailed-info .service-tasks .task-list-item .task-time .time, .service-overview-tab .service-detailed-info .service-events .event-list-item .event-item-content .event-item-data .event-time { + font-family: "SourceSanPro-Semibold"; + font-size: 13px; } + +.nfv-body-5, .tree-graph .node text.sub-title, .color-legend .statuses .legend, .color-legend .states .legend, .color-legend .statuses .new, .color-legend .states .new, .network-topology-view .right-pane-controller .kpi-graph .header .node-attributes-title, .network-topology-view .right-pane-controller .kpi-graph .header .toggle, .system-tasks .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .contentPreview .action-taken .label, .tasks-notifications-container .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .contentPreview .action-taken .label, .system-tasks .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .serviceParams .label, .tasks-notifications-container .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .serviceParams .label { + font-family: "SourceSanPro-Regular"; + font-size: 11px; } + +.nfv-body-6, .network-graph .element.nfvo .port > .port-label, .color-legend .statuses .title, .color-legend .states .title, .system-tasks .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .contentPreview .action-taken .value, .tasks-notifications-container .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .contentPreview .action-taken .value, .system-tasks .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .serviceParams .value, .tasks-notifications-container .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .serviceParams .value { + font-family: "SourceSanPro-Semibold"; + font-size: 11px; } + +/* light theme */ +/* Textures */ +/* Dimensions */ +/* Dimensions */ +.ui-state-disabled { + pointer-events: none; } + +.ui-icon { + display: inline-block; } + +.ui-widget-content { + background: #ffffff; + color: #1a2531; + border: none; } + .ui-widget-content a { + color: #419ef1; } + +.uxf-progressbar { + color: #ffffff; + height: 20px; + margin: 5px 0; } + .uxf-progressbar > div[data-uxf-point="remaining"] { + background: #ffffff; + border: none; + -webkit-box-shadow: inset 0 1px 2px 1px #ffffff; + -moz-box-shadow: inset 0 1px 2px 1px #ffffff; + box-shadow: inset 0 1px 2px 1px #ffffff; } + .uxf-progressbar > div[data-uxf-point="progress"] { + border: none; } + .uxf-progressbar .nfv-normal { + background: #1a2531; } + .uxf-progressbar .nfv-critical { + background: #e65353; } + .uxf-progressbar .progress-text { + line-height: 30px; + text-align: center; + color: #ffffff; } + +.nfv-white-bg.uxf-progressbar > div[data-uxf-point="remaining"] { + background: #ffffff; + border: none; } + +.ui-tabs { + margin: 0; + padding: 0; } + .ui-tabs .ui-tabs-nav { + padding: 0; + margin: 0; } + .ui-tabs .ui-tabs-panel { + padding: 0; + margin: 0; } + +.ui-accordion .ui-accordion-content { + padding: 0; + margin: 0; } + +.ui-helper-reset { + line-height: 1.25; } + +.ui-widget { + font-size: 100%; + font-family: "SourceSanPro-Regular"; } + .ui-widget input { + font-family: "SourceSanPro-Regular"; } + .ui-widget select { + font-family: "SourceSanPro-Regular"; } + +.ui-dialog[role="dialog"] { + left: 50%; + min-width: 400px; + top: 50%; + transform: translate(-50%, -50%); + z-index: 1002; + -webkit-box-shadow: none; + -moz-box-shadow: none; + box-shadow: none; } + @media only screen and (min-width: 1224px) { + .ui-dialog[role="dialog"] { + min-width: 500px; } } + .ui-dialog[role="dialog"] .ui-dialog-titlebar { + background: #ecf1f5; + color: #253244; + padding: 0.5em 1em; } + .ui-dialog[role="dialog"] .ui-dialog-titlebar .ui-dialog-title { + text-align: left; + font-weight: normal; } + .ui-dialog[role="dialog"] .ui-dialog-titlebar .ui-button { + display: none; } + .ui-dialog[role="dialog"] .ui-dialog-content { + padding: 20px 30px; + background: #ffffff; } + .ui-dialog[role="dialog"] .ui-dialog-buttonpane { + padding: 0; + margin: 0; } + .ui-dialog[role="dialog"] .ui-dialog-buttonpane button.ui-button { + min-width: 75px; + padding: 0; } + .ui-dialog[role="dialog"] .ui-dialog-buttonpane button.ui-button .ui-button-text { + padding: 3px 0; } + +.ui-widget-overlay { + background: rgba(26, 37, 49, 0.5); + opacity: 1; + filter: alpha(opacity = 100); + z-index: 1001; + position: fixed; } + +.ui-datepicker { + border: 1px solid #ffffff; } + .ui-datepicker .ui-state-default, .ui-datepicker .ui-widget-header { + color: #b9bab5; + background: #232323; } + .ui-datepicker .ui-state-highlight { + border: none; + background: #ffffff; + color: #e65353; } + +.ui-dialog-titlebar .ui-state-default.ui-button { + box-shadow: none; + background: transparent; + border: 0px; + border-radius: 0px; } + +.ui-dialog-titlebar .ui-state-default.ui-state-hover { + border: none; + background: #413a35 url(images/ui-bg_glass_0_413a35_1x400.png) 50% 50% repeat-x; + border-radius: 4px; } + +.ui-tooltip { + max-width: 350px; } + +body.theme2 .ui-widget-content { + background: #232323; + color: #b9bab5; + border: none; } + body.theme2 .ui-widget-content a { + color: #f4f6f1; } + +body.theme2 .uxf-progressbar { + color: #f4f6f1; } + body.theme2 .uxf-progressbar > div[data-uxf-point="remaining"] { + background: #333; } + body.theme2 .uxf-progressbar .nfv-normal { + background: #1a2531; } + body.theme2 .uxf-progressbar .nfv-critical { + background: #ff7c54; } + body.theme2 .uxf-progressbar .progress-text { + color: #f4f6f1; } + +body.theme2 .nfv-white-bg.uxf-progressbar > div[data-uxf-point="remaining"] { + background: #232323; } + +body.theme2 .ui-dialog .ui-widget-content { + background: #333; } + +body.theme2 .ui-dialog .ui-dialog-titlebar { + color: #8ccdf5; + background: #232323; } + +body.theme2 .ui-dialog .ui-dialog-content { + background: #333; } + +body.theme2 .ui-widget-overlay { + background: rgba(185, 186, 181, 0.3); } + +body.theme2 .ui-datepicker { + border: 1px solid #333; } + body.theme2 .ui-datepicker .ui-state-default, body.theme2 .ui-datepicker .ui-widget-header { + color: #b9bab5; + background: #232323; } + body.theme2 .ui-datepicker .ui-state-highlight { + border: none; + background: #232323; + color: #ff7c54; } + +body.theme2 .ui-dialog-titlebar .ui-state-default.ui-state-hover { + border: none; + background: #413a35 url(images/ui-bg_glass_0_413a35_1x400.png) 50% 50% repeat-x; + border-radius: 4px; } + +/* PX fallback for browsers that do not support REM units. */ +html { + font-size: 100%; } + +body { + font-weight: normal; + line-height: 1.25; + font-family: "SourceSanPro-Regular"; + background-color: #ffffff; + color: #1a2531; + /* scrollbar styling for Internet Explorer */ + scrollbar-face-color: #ff8a00; + scrollbar-track-color: #ecf1f5; + /* scrollbar styling for Google Chrome | Safari | Opera */ + /* Mozilla Firefox currently doesn't support scrollbar styling */ } + body ::-webkit-scrollbar { + width: 8px; + height: 8px; } + body ::-webkit-scrollbar-track { + background-color: transparent; + border-radius: 10px; } + body ::-webkit-scrollbar-thumb { + border-radius: 10px; + border: 1px solid #ecf1f5; + background-color: #253244; } + body.theme2 { + background-color: #232323; + color: #b9bab5; + scrollbar-face-color: #ff8a00; + scrollbar-track-color: #333; } + body.theme2 ::-webkit-scrollbar-thumb { + border: 1px solid #333; + background-color: #232323; } + +ul { + list-style: none; } + +h1, h2, h3, h4, h5, h6, ul { + margin: 0; + padding: 0; } + +input { + background: #ffffff; + border: 1px solid #445a75; + padding: 7px 10px; } + +fieldset { + border: none; } + +fieldset label { + display: inline-block; } + +.nfv-header { + background-color: #419ef1; + display: table; + height: 70px; + transition: background-color 0.4s; + width: 100%; } + .nfv-header .nfv-logo { + height: 70px; + padding: 0px 20px; + vertical-align: middle; + display: table-cell; + font-size: 20px; + white-space: nowrap; + background-color: #253244; } + .nfv-header .nfv-logo a { + color: #ffffff; } + .nfv-header .nfv-logo a:hover { + text-decoration: none; } + .nfv-header .header-content-wrapper { + display: table-cell; + vertical-align: middle; } + .nfv-header .header-content-wrapper .header-title { + display: table-cell; + vertical-align: middle; + padding-left: 30px; + color: #ffffff; + transition: color 0.4s; } + .nfv-header .header-content-wrapper .header-title .main-title { + display: inline-block; } + .nfv-header .header-content-wrapper .header-title .version-select { + display: inline-block; + margin-left: 8px; } + .nfv-header .header-content-wrapper .header-title .version-select select { + max-height: 35px; + background: transparent url("../images/images_theme_1/drop_down_down_arrow_white.png") no-repeat 100% 50%; + border: none; + min-width: initial; + padding-right: 15px; + color: inherit; + padding-left: 8px; } + .nfv-header .header-content-wrapper .header-title .version-select select option { + background-color: #419ef1; } + .nfv-header .user-details { + position: absolute; + right: 10px; + top: 25px; + width: 200px; } + .nfv-header .user-details .nfv-header-logged-user { + background-size: 30px 30px; + background-repeat: no-repeat; + color: #ffffff; + position: relative; } + .nfv-header .tasks-notifications-container { + position: absolute; + right: 220px; + top: 22px; } + .nfv-header .tasks-notifications-container .tasks-notification-icon { + color: #ffffff; + font-size: 20px; + position: absolute; + width: 25px; + height: 25px; + right: 0px; + top: 1px; + text-align: center; + cursor: pointer; } + .nfv-header .tasks-notifications-container .notification-counter { + display: table-cell; + position: relative; + float: right; + background-color: #e65353; + color: #ffffff; + border-radius: 5px; + width: 21px; + right: -11px; + top: -8px; + vertical-align: middle; + text-align: center; + font-size: 70%; } + .nfv-header .tasks-notifications-container .notifications-popup { + cursor: default; + position: absolute; + top: 43px; + right: -26px; + z-index: 102; + width: 350px; + min-height: 100px; + background-color: #ffffff; + border: 1px solid #a8bbdc; } + .nfv-header .tasks-notifications-container .notifications-popup:after, .nfv-header .tasks-notifications-container .notifications-popup:before { + bottom: 100%; + left: 93%; + border: solid transparent; + content: " "; + height: 0; + width: 0; + position: absolute; + pointer-events: none; } + .nfv-header .tasks-notifications-container .notifications-popup:after { + border-color: rgba(255, 255, 255, 0); + border-bottom-color: #ffffff; + border-width: 11px; + margin-left: -25px; } + .nfv-header .tasks-notifications-container .notifications-popup:before { + border-color: rgba(167, 179, 178, 0); + border-bottom-color: #a8bbdc; + border-width: 13px; + margin-left: -27px; } + .nfv-header .tasks-notifications-container .notifications-popup .notifications-popup-header { + height: 46px; + line-height: 46px; + padding-left: 48px; + padding-right: 20px; + border-bottom: 1px solid #a8bbdc; } + .nfv-header .tasks-notifications-container .notifications-popup .notifications-popup-header .nfv-link { + float: right; } + .nfv-header .tasks-notifications-container .notifications-popup .notifications-popup-content { + position: relative; + min-height: 400px; + max-height: 414px; + left: 21px; } + .nfv-header .tasks-notifications-container .notifications-popup .notifications-popup-user-menu { + position: absolute; + top: 0px; + border-right: 1px solid #a8bbdc; + background: #e1e8f1; + width: 35px; + min-height: 446px; + font-size: 25px; + text-align: center; } + .nfv-header .tasks-notifications-container .notifications-popup .notifications-popup-user-menu .settings, .nfv-header .tasks-notifications-container .notifications-popup .notifications-popup-user-menu .logout, .nfv-header .tasks-notifications-container .notifications-popup .notifications-popup-user-menu .theme-select { + cursor: pointer; + margin-top: 10px; } + .nfv-header .tasks-notifications-container .notifications-popup .notifications-popup-user-menu .settings { + color: #ff8a00; } + .nfv-header .tasks-notifications-container .notifications-popup .notifications-popup-user-menu .theme-select { + color: #445a75; } + .nfv-header .tasks-notifications-container .notifications-popup .notifications-popup-user-menu .version-and-build { + transform: rotate(270deg); + /* IE10 and Mozilla */ + -ms-transform: rotate(270deg); + /* IE 9 */ + -webkit-transform: rotate(270deg); + /* Safari and Chrome */ + top: 290px; + position: relative; + left: 0; + letter-spacing: 2px; } + .nfv-header .tasks-notifications-container .notifications-popup .notifications-popup-user-menu .logout { + color: #419ef1; + bottom: 0; + position: absolute; + left: 6px; } + +/* Themes */ +body.theme2 .nfv-header { + background-color: #333; } + body.theme2 .nfv-header .search-filter-input input[type="search"] { + background: #232323; + color: #f4f6f1; } + body.theme2 .nfv-header .nfv-logo { + background-color: #232323; } + body.theme2 .nfv-header .header-content-wrapper .header-title { + color: #9bdb69; } + body.theme2 .nfv-header .header-content-wrapper .version-select select { + color: #8ccdf5; } + body.theme2 .nfv-header .header-content-wrapper .version-select select option { + background-color: #333; } + body.theme2 .nfv-header .header-content-wrapper .sub-title { + color: #aaa6d9; } + body.theme2 .nfv-header .user-details .nfv-header-logged-user { + color: #f4f6f1; } + +body.theme2 .tasks-notifications-container .tasks-notification-icon { + color: #9bdb69; } + +body.theme2 .tasks-notifications-container .notification-counter { + background-color: #333; + color: #b9bab5; } + +body.theme2 .tasks-notifications-container .notifications-popup { + background-color: #333; + border: 1px solid #454544; + box-shadow: 0px 0px 5px 2px #b9bab5; } + body.theme2 .tasks-notifications-container .notifications-popup:after { + border-color: rgba(255, 255, 255, 0); + border-bottom-color: #232323; } + body.theme2 .tasks-notifications-container .notifications-popup:before { + border-color: rgba(167, 179, 178, 0); + border-bottom-color: #454544; } + body.theme2 .tasks-notifications-container .notifications-popup .notifications-popup-header { + border-bottom: 1px solid #454544; + background: #232323; } + body.theme2 .tasks-notifications-container .notifications-popup .notifications-popup-user-menu { + border-right: 1px solid #454544; + background: #232323; } + body.theme2 .tasks-notifications-container .notifications-popup .notifications-popup-user-menu .settings { + color: #aaa6d9; } + body.theme2 .tasks-notifications-container .notifications-popup .notifications-popup-user-menu .logout { + color: #ff7c54; } + body.theme2 .tasks-notifications-container .notifications-popup .notifications-popup-user-menu .theme-select { + color: #9bdb69; } + +.nfv-page { + overflow: hidden; + height: 100vh; + position: relative; } + .nfv-page .nfv-content { + background-color: #ffffff; + overflow: auto; + position: absolute; + top: 70px; + bottom: 0; + transition: background-color 0.2s; + width: 100%; } + +body.theme2 .nfv-page .nfv-content { + background-color: #232323; } + +.ui-dialog { + -webkit-box-shadow: 3px 5px 8px rgba(0, 0, 0, 0.6); + -moz-box-shadow: 3px 5px 8px rgba(0, 0, 0, 0.6); + box-shadow: 3px 5px 8px rgba(0, 0, 0, 0.6); } + .ui-dialog .nfv-content { + background: #ffffff; + color: #1a2531; + min-height: 0px; + width: auto; + margin: 0; + padding: 20px 35px 20px; + overflow-x: hidden; } + .ui-dialog .nfv-content p { + line-height: 1.6; } + +.ui-state-default.ui-button, +.ui-widget-content .ui-state-default.ui-button, +.ui-widget-header .ui-state-default.ui-button { + -webkit-border-radius: 2px; + border-radius: 2px; + color: #253244; + background: transparent; + min-width: 90px; + outline: none; } + .ui-state-default.ui-button .ui-button-text, + .ui-widget-content .ui-state-default.ui-button .ui-button-text, + .ui-widget-header .ui-state-default.ui-button .ui-button-text { + padding: 6px 10px; } + +.nfv-primary-button .ui-button.ui-widget, .nfv-secondary-button .ui-button.ui-widget, .ui-dialog[role="dialog"] .ui-dialog-buttonset .ui-button.ui-widget { + transition: background 0.4s, color 0.4s, border 0.4s; } + .nfv-primary-button .ui-button.ui-widget.ui-state-disabled, .nfv-secondary-button .ui-button.ui-widget.ui-state-disabled, .ui-dialog[role="dialog"] .ui-dialog-buttonset .ui-button.ui-widget.ui-state-disabled { + opacity: 0.5; + filter: alpha(opacity = 50); + background: transparent !important; + border: 1px solid #445a75; } + .nfv-primary-button .ui-button.ui-widget.ui-state-disabled .ui-button-text, .nfv-secondary-button .ui-button.ui-widget.ui-state-disabled .ui-button-text, .ui-dialog[role="dialog"] .ui-dialog-buttonset .ui-button.ui-widget.ui-state-disabled .ui-button-text { + color: #445a75 !important; } + +.nfv-primary-button .ui-button.ui-widget { + color: #253244; + background: #ff8a00; + border: none; } + .nfv-primary-button .ui-button.ui-widget:hover { + background: #a8bbdc; } + +.nfv-secondary-button .ui-button, .ui-dialog[role="dialog"] .ui-dialog-buttonset .ui-button { + color: #253244; + background: transparent; + border: 1px solid #253244; + min-width: 80px; } + .nfv-secondary-button .ui-button:hover, .ui-dialog[role="dialog"] .ui-dialog-buttonset .ui-button:hover { + color: #419ef1; + border: 1px solid #419ef1; } + +.nfv-button-link .uxf-button, .nfv-button-link.ui-button-text-only { + background: none; + border: none; + color: #253244; + box-shadow: none; } + .nfv-button-link .uxf-button.ui-button:hover, .nfv-button-link.ui-button-text-only.ui-button:hover { + background: none; } + .nfv-button-link .uxf-button .ui-button-text, .nfv-button-link.ui-button-text-only .ui-button-text { + padding: 0; + text-decoration: underline; } + +.nfv-button-link .ui-state-default.ui-button, +.nfv-button-link .ui-widget-content .ui-state-default.ui-button, +.nfv-button-link .ui-widget-header .ui-state-default.ui-button { + color: #253244; + background: none; } + +.nfv-button-link .ui-state-default.ui-state-hover, +.nfv-button-link .ui-widget-content .ui-state-default.ui-state-hover, +.nfv-button-link .ui-widget-header .ui-state-default.ui-state-hover { + box-shadow: none; } + +.nfv-button-link a { + background: none; } + +body.theme2 .ui-state-default.ui-button, +body.theme2 .ui-widget-content .ui-state-default.ui-button, +body.theme2 .ui-widget-header .ui-state-default.ui-button { + color: rgba(185, 186, 181, 0.5); } + +body.theme2 .nfv-primary-button .ui-button.ui-widget.ui-state-disabled, body.theme2 .nfv-secondary-button .ui-button.ui-widget.ui-state-disabled, body.theme2 .ui-dialog[role="dialog"] .ui-dialog-buttonset .ui-button.ui-widget.ui-state-disabled, .ui-dialog[role="dialog"] body.theme2 .ui-dialog-buttonset .ui-button.ui-widget.ui-state-disabled { + background: transparent !important; + border: 1px solid #2f2f2f; } + body.theme2 .nfv-primary-button .ui-button.ui-widget.ui-state-disabled .ui-button-text, body.theme2 .nfv-secondary-button .ui-button.ui-widget.ui-state-disabled .ui-button-text, body.theme2 .ui-dialog[role="dialog"] .ui-dialog-buttonset .ui-button.ui-widget.ui-state-disabled .ui-button-text, .ui-dialog[role="dialog"] body.theme2 .ui-dialog-buttonset .ui-button.ui-widget.ui-state-disabled .ui-button-text { + color: #b9bab5 !important; } + +body.theme2 .nfv-primary-button .ui-button.ui-widget { + color: #232323; + background: rgba(155, 219, 105, 0.8); } + body.theme2 .nfv-primary-button .ui-button.ui-widget:hover { + background: #9bdb69; + color: #232323; } + +body.theme2 .nfv-secondary-button .ui-button, body.theme2 .ui-dialog[role="dialog"] .ui-dialog-buttonset .ui-button, .ui-dialog[role="dialog"] body.theme2 .ui-dialog-buttonset .ui-button { + color: rgba(185, 186, 181, 0.7); + background: transparent; + border: 1px solid rgba(185, 186, 181, 0.7); } + body.theme2 .nfv-secondary-button .ui-button:hover, body.theme2 .ui-dialog[role="dialog"] .ui-dialog-buttonset .ui-button:hover, .ui-dialog[role="dialog"] body.theme2 .ui-dialog-buttonset .ui-button:hover { + color: #b9bab5; + border: 1px solid #b9bab5; + background: transparent; } + +body.theme2 .nfv-button-link .uxf-button, body.theme2 .nfv-button-link.ui-button-text-only { + color: #b9bab5; } + +body.theme2 .nfv-button-link .ui-state-default.ui-button, +body.theme2 .nfv-button-link .ui-widget-content .ui-state-default.ui-button, +body.theme2 .nfv-button-link .ui-widget-header .ui-state-default.ui-button { + color: #b9bab5; } + +a.nfv-button-link { + cursor: pointer; + padding: 0; + font-size: inherit; + text-decoration: underline; } + a.nfv-button-link:hover { + text-decoration: none; } + a.nfv-button-link.nfv-active { + text-decoration: none; + font-weight: bold; } + +.nfv-link { + color: #419ef1; + text-decoration: none; + cursor: pointer; } + .nfv-link:hover { + text-decoration: underline; } + .nfv-link.nfv-active { + text-decoration: none; + font-weight: bold; } + .nfv-link .uxf-button { + background: none; + border: none; + color: #419ef1; } + .nfv-link .uxf-button .ui-button-text { + padding: 0; + font-size: inherit; + text-decoration: none; } + .nfv-link .uxf-button .ui-button-text:hover { + text-decoration: none; } + +.nfv-checkbox-button input[type="checkbox"] { + display: none; } + .nfv-checkbox-button input[type="checkbox"]:checked + label:before { + font-family: FontAwesome; + content: "\f00c"; + text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.2); + font-size: 15px; + color: #419ef1; + text-align: center; + line-height: 15px; + font-weight: bold; } + +.nfv-checkbox-button label { + display: inline-block; + cursor: pointer; + position: relative; + padding-left: 25px; } + .nfv-checkbox-button label:before { + content: ""; + display: inline-block; + width: 16px; + height: 16px; + margin-right: 10px; + position: absolute; + left: 0; + bottom: 3px; + background-color: #ffffff; + border: 1px solid #445a75; } + +.nfv-radio-button input[type="radio"] { + display: none; } + .nfv-radio-button input[type="radio"]:checked + label:after { + opacity: 1; } + +.nfv-radio-button label { + display: inline-block; + cursor: pointer; + position: relative; + padding-left: 25px; } + .nfv-radio-button label:before { + content: ""; + display: inline-block; + width: 16px; + height: 16px; + margin-right: 10px; + position: absolute; + left: 0; + bottom: 3px; + background-color: #ffffff; + border: 1px solid #445a75; + -webkit-border-radius: 10px; + border-radius: 10px; } + .nfv-radio-button label:after { + opacity: 0; + content: ""; + background-color: #419ef1; + width: 10px; + height: 10PX; + border-radius: 10px; + position: absolute; + left: 3px; + top: 8px; + transition: opacity 0.2s; } + +.uxf-textinput input, .uxf-searchinput input { + border: none; + border-bottom: 1px solid #a8bbdc; + background: transparent; + outline: 0; } + .uxf-textinput input::-webkit-input-placeholder, .uxf-searchinput input::-webkit-input-placeholder { + color: #a8bbdc; } + .uxf-textinput input::-moz-placeholder, .uxf-searchinput input::-moz-placeholder { + color: #a8bbdc; } + +.form-element .form-element--error-message { + color: #e65353; + margin-left: 20px; } + +.form-element input.form-element--control { + height: 19px; + border-radius: 2px; + border: none; + border-bottom: 1px solid #a8bbdc; + outline: 0; } + .form-element input.form-element--control[disabled] { + opacity: 0.35; } + +.form-element select.form-element--control { + height: 35px; + border-radius: 2px; + border-color: #a8bbdc; } + +.nfv-mandatory label:after, .is-mandatory label:after { + content: '*'; + display: inline-block; + color: #e65353; } + +.nfv-mandatory-asterisk { + color: #e65353 !important; } + +.uxf-selectinput select, .form-element select { + color: #1a2531; + text-align: left; + min-width: 150px; + height: 35px !important; + padding-left: 10px; + padding-right: 17px; + appearance: none; + -moz-appearance: none; + -webkit-appearance: none; + background: url("../images/images_theme_1/drop_down_down_arrow.png") no-repeat 102% #ffffff; + border-radius: 3px; + border: 1px solid #a8bbdc; + outline: 0; } + +.uxf-selectinput .mlabel, .form-element .mlabel { + display: inline; + margin-right: 18px !important; } + +.LS-error { + display: none; + color: #e65353; + background-position: 0; + padding: 5px 0 5px 25px; } + +body.theme2 .nfv-link { + color: #f4f6f1; } + body.theme2 .nfv-link .uxf-button { + color: #f4f6f1; } + +body.theme2 .nfv-checkbox-button input[type=checkbox]:checked + label:before { + color: #9bdb69; } + +body.theme2 .nfv-checkbox-button label:before { + background-color: #333; + border: 1px solid #b9bab5; } + +body.theme2 .nfv-radio-button input[type="radio"]:checked + label:before { + color: #9bdb69; } + +body.theme2 .nfv-radio-button label:before { + background-color: #333; + border: 1px solid #b9bab5; } + +body.theme2 .nfv-radio-button label:after { + background-color: #9bdb69; } + +body.theme2 .uxf-textinput input, body.theme2 .uxf-searchinput input { + border-bottom: 1px solid #333; } + +body.theme2 .form-element .form-element--error-message { + color: #ff7c54; } + +body.theme2 .form-element input.form-element--control { + border-bottom: 1px solid #333; + background: #232323; } + +body.theme2 .form-element select.form-element--control { + border-color: #333; } + +body.theme2 .nfv-mandatory label:after, body.theme2 .is-mandatory label:after { + color: #ff7c54; } + +body.theme2 .nfv-mandatory-asterisk { + color: #ff7c54 !important; } + +body.theme2 .uxf-selectinput select, body.theme2 .form-element select { + color: #b9bab5; + background: url("../images/images_theme_1/drop_down_down_arrow.png") no-repeat 102% #232323; + border: 1px solid #333; } + +body.theme2 .LS-error { + color: #ff7c54; } + +body.theme2 .form-element-container > .form-element--label:first-child { + color: #9bdb69; } + +.nfv-wizard-header { + position: relative; + border-bottom: 1px solid rgba(168, 187, 220, 0.3); + padding: 0; + background: #ecf1f5; } + .nfv-wizard-header .wizard .nfv-wizard-steps { + padding: 10px 0; } + .nfv-wizard-header .wizard .nfv-wizard-steps .wizard-step { + display: inline-block; + text-align: center; } + .nfv-wizard-header .wizard .nfv-wizard-steps .wizard-step .step-item { + margin-left: 15px; } + .nfv-wizard-header .wizard .nfv-wizard-steps .wizard-step .step-title { + margin: 0 15px; + text-align: center; } + .nfv-wizard-header .wizard .nfv-wizard-steps .wizard-step .step-arrow { + font-size: 30px; } + .nfv-wizard-header .wizard .nfv-wizard-steps .wizard-step:first-child { + margin-left: 37px; } + .nfv-wizard-header .wizard .nfv-wizard-steps .wizard-step:first-child .step-item { + margin-left: 0; } + .nfv-wizard-header .wizard .nfv-wizard-steps .wizard-step:last-child .step-arrow { + display: none; } + .nfv-wizard-header .wizard .nfv-wizard-steps .wizard-step.active .step-item { + color: #419ef1; } + .nfv-wizard-header .wizard .nfv-wizard-steps .wizard-step.active .step-title { + color: #419ef1; } + +.wizard-nav-controls { + background: #ecf1f5; + padding: 12px 0; + border-top: 1px solid #445a75; + height: 38px; + position: fixed; + bottom: 0; + width: 100%; + z-index: 2; } + .wizard-nav-controls .nfv-button-link, .wizard-nav-controls .nfv-secondary-button, .wizard-nav-controls .ui-dialog[role="dialog"] .ui-dialog-buttonset, .ui-dialog[role="dialog"] .wizard-nav-controls .ui-dialog-buttonset, .wizard-nav-controls .nfv-primary-button { + display: inline-block; } + .wizard-nav-controls .nfv-secondary-button, .wizard-nav-controls .ui-dialog[role="dialog"] .ui-dialog-buttonset, .ui-dialog[role="dialog"] .wizard-nav-controls .ui-dialog-buttonset { + margin-left: 30px; } + .wizard-nav-controls .nfv-primary-button { + position: absolute; + top: 12px; + right: 2%; } + +body.theme2 .nfv-wizard-header { + border-bottom: 1px solid #454544; + background: #232323; } + body.theme2 .nfv-wizard-header .wizard .nfv-wizard-steps .wizard-step .step-arrow { + color: #9bdb69; } + body.theme2 .nfv-wizard-header .wizard .nfv-wizard-steps .wizard-step.active .step-item { + color: #8ccdf5; } + body.theme2 .nfv-wizard-header .wizard .nfv-wizard-steps .wizard-step.active .step-title { + color: #8ccdf5; } + +body.theme2 .wizard-nav-controls { + background: #333; + border-top: 1px solid #333; } + +.nfv-accordion .nfv-collapsible-item .nfv-collapsible-title { + background: #ecf1f5; + padding: 0px 10px; + height: 34px; + border: none; + border-bottom: 1px solid #a8bbdc; + margin-bottom: 10px; + display: table; + width: 99%; } + .nfv-accordion .nfv-collapsible-item .nfv-collapsible-title .nfv-collapsible-title-icon { + display: table-cell; + vertical-align: middle; + width: 14px; } + .nfv-accordion .nfv-collapsible-item .nfv-collapsible-title .nfv-collapsible-title-icon:before { + font-family: FontAwesome; + font-size: 15px; + content: "\f067"; + color: #1a2531; } + .nfv-accordion .nfv-collapsible-item .nfv-collapsible-title .nfv-collapsible-title-text { + display: table-cell; + vertical-align: middle; + padding-left: 15px; + font-size: 25px; + color: #1a2531; } + .nfv-accordion .nfv-collapsible-item .nfv-collapsible-title .nfv-collapsible-subtitle-text { + display: table-cell; + vertical-align: middle; + font-size: 22px; + color: #1a2531; + margin-left: 0.5em; } + .nfv-accordion .nfv-collapsible-item .nfv-collapsible-title.ui-state-active { + background: #ecf1f5; } + .nfv-accordion .nfv-collapsible-item .nfv-collapsible-title.ui-state-active .nfv-collapsible-title-icon:before { + content: "\f068"; } + +.nfv-accordion .nfv-collapsible-item .nfv-collapsible-content { + padding: 10px; } + +body.theme2 .nfv-accordion .nfv-collapsible-item .nfv-collapsible-title { + background: #333; + border-bottom: 1px solid #2f2f2f; } + body.theme2 .nfv-accordion .nfv-collapsible-item .nfv-collapsible-title .nfv-collapsible-title-icon:before { + color: #b9bab5; } + body.theme2 .nfv-accordion .nfv-collapsible-item .nfv-collapsible-title .nfv-collapsible-title-text { + color: #b9bab5; } + body.theme2 .nfv-accordion .nfv-collapsible-item .nfv-collapsible-title .nfv-collapsible-subtitle-text { + color: #b9bab5; } + body.theme2 .nfv-accordion .nfv-collapsible-item .nfv-collapsible-title.ui-state-active { + background: #333; } + +.nfv-tabpanel { + background: transparent; + border: none; } + .nfv-tabpanel .nfv-tabs-v1 { + border: none; + background: #e1e8f1; + border-radius: 0; + padding: 3px 0; } + .nfv-tabpanel .nfv-tabs-v1 .ui-state-default { + margin: 0 35px; + border: none; + background: transparent; } + .nfv-tabpanel .nfv-tabs-v1 .ui-state-default .ui-tabs-anchor { + color: #253244; + padding: .5em 0; + width: 100%; + text-align: center; } + .nfv-tabpanel .nfv-tabs-v1 .ui-state-default.ui-state-active .ui-tabs-anchor { + color: #ff8a00; + outline: 0; } + .nfv-tabpanel .nfv-tabs-v2 { + border: none; + background: #ffffff; + border-radius: 0; } + .nfv-tabpanel .nfv-tabs-v2 .ui-state-default { + margin: 0; + border: 1px solid #a8bbdc; + background: transparent; + width: 140px; } + .nfv-tabpanel .nfv-tabs-v2 .ui-state-default .ui-tabs-anchor { + color: #253244; + padding: .5em 0; + width: 100%; + text-align: center; } + .nfv-tabpanel .nfv-tabs-v2 .ui-state-default.ui-state-active { + border-bottom: none; } + .nfv-tabpanel .nfv-tabs-v2 .ui-state-default.ui-state-active .ui-tabs-anchor { + color: #ff8a00; + outline: 0; } + .nfv-tabpanel .nfv-tabs-v3 { + border: none; + background: #ffffff; + border-radius: 0; + padding: 16px 0; } + .nfv-tabpanel .nfv-tabs-v3 .ui-state-default { + margin: 0; + border: 1px solid #a8bbdc !important; + border-left: none !important; + background: transparent; + border-radius: 0; } + .nfv-tabpanel .nfv-tabs-v3 .ui-state-default:first-child { + border-bottom-left-radius: 2px; + border-top-left-radius: 2px; + border-left: 1px solid #a8bbdc !important; } + .nfv-tabpanel .nfv-tabs-v3 .ui-state-default:last-child { + border-bottom-right-radius: 2px; + border-top-right-radius: 2px; } + .nfv-tabpanel .nfv-tabs-v3 .ui-state-default .ui-tabs-anchor { + color: #253244; + padding: 6px 18px; + text-align: center; } + .nfv-tabpanel .nfv-tabs-v3 .ui-state-default.ui-state-active .ui-tabs-anchor { + background: #ecf1f5; + outline: 0; } + .nfv-tabpanel .nfv-tabs { + border: none; + background: transparent; } + .nfv-tabpanel .nfv-tabs .ui-state-default { + height: 40px; + background: #445a75; + border: 1px solid #a8bbdc; } + .nfv-tabpanel .nfv-tabs .ui-state-default .ui-tabs-anchor { + color: #253244; + padding: .5em 0; + width: 100%; + text-align: center; } + .nfv-tabpanel .nfv-tabs .ui-state-default.ui-state-active { + background: #ffffff; + border: 1px solid #ffffff; } + .nfv-tabpanel .nfv-tabs .ui-state-default.ui-state-active .ui-tabs-anchor { + color: #ff8a00; + outline: 0; } + .nfv-tabpanel .ui-tabs-panel { + border-top: 1px solid #a8bbdc; + padding: 20 55px; + background: #ffffff; } + .nfv-tabpanel.ui-tabs-vertical { + width: 100%; + height: 385; + border-top: 1px solid #a8bbdc; + border-bottom: 1px solid #a8bbdc; + overflow: hidden; + -webkit-border-top-left-radius: 0; + border-top-left-radius: 0; + -webkit-border-top-right-radius: 0; + border-top-right-radius: 0; } + .nfv-tabpanel.ui-tabs-vertical .nfv-tabs { + float: left; + width: 26%; + height: inherit; + overflow-y: auto; + overflow-x: hidden; } + .nfv-tabpanel.ui-tabs-vertical .nfv-tabs .ui-state-default { + clear: left; + width: 100%; + top: 0; + -webkit-border-top-left-radius: 0; + border-top-left-radius: 0; + -webkit-border-top-right-radius: 0; + border-top-right-radius: 0; + border-right: none; + border-left: none; + margin: 0 0 5px 0; } + .nfv-tabpanel.ui-tabs-vertical .nfv-tabs .ui-state-default .ui-tabs-anchor { + display: block; } + .nfv-tabpanel.ui-tabs-vertical .nfv-tabs .ui-state-default.ui-tabs-active { + padding-bottom: 0; + border-bottom: #a8bbdc 2px solid !important; + border-top: #a8bbdc 2px solid !important; + height: 36px; } + .nfv-tabpanel.ui-tabs-vertical .ui-tabs-panel { + float: right; + width: 65.1%; + border: none; + height: 345; + overflow-y: auto; } + +body.theme2 .nfv-tabpanel .nfv-tabs-v1 { + background-color: #232323; } + body.theme2 .nfv-tabpanel .nfv-tabs-v1 .ui-state-default .ui-tabs-anchor { + color: #b9bab5; } + body.theme2 .nfv-tabpanel .nfv-tabs-v1 .ui-state-default.ui-state-active .ui-tabs-anchor { + color: #9bdb69; } + +body.theme2 .nfv-tabs-v2 { + background: #232323; + border-bottom: 1px solid #2f2f2f; } + body.theme2 .nfv-tabs-v2 .ui-state-default { + border: 1px solid #2f2f2f; } + body.theme2 .nfv-tabs-v2 .ui-state-default .ui-tabs-anchor { + color: #b9bab5; } + body.theme2 .nfv-tabs-v2 .ui-state-default.ui-state-active .ui-tabs-anchor { + color: #9bdb69; } + +body.theme2 .nfv-tabs-v3 { + background: #232323; } + body.theme2 .nfv-tabs-v3 .ui-state-default { + border: 1px solid #2f2f2f !important; } + body.theme2 .nfv-tabs-v3 .ui-state-default:first-child { + border-bottom-left-radius: 2px; + border-top-left-radius: 2px; + border-left: 1px solid #2f2f2f !important; } + body.theme2 .nfv-tabs-v3 .ui-state-default:last-child { + border-bottom-right-radius: 2px; + border-top-right-radius: 2px; } + body.theme2 .nfv-tabs-v3 .ui-state-default .ui-tabs-anchor { + color: #b9bab5; } + body.theme2 .nfv-tabs-v3 .ui-state-default.ui-state-active .ui-tabs-anchor { + color: #9bdb69; + background: #232323; + outline: 0; } + +body.theme2 .nfv-tabs .ui-state-default { + height: 40px; + background: #232323; + border: 1px solid #2f2f2f; } + body.theme2 .nfv-tabs .ui-state-default .ui-tabs-anchor { + color: #b9bab5; } + body.theme2 .nfv-tabs .ui-state-default.ui-state-active { + background: #333; + border: 1px solid #2f2f2f; } + body.theme2 .nfv-tabs .ui-state-default.ui-state-active .ui-tabs-anchor { + color: #9bdb69; } + +body.theme2 .ui-tabs-panel { + border-top: 1px solid #2f2f2f; + background: #232323; } + +body.theme2.ui-tabs-vertical { + border-top: 1px solid #2f2f2f; + border-bottom: 1px solid #2f2f2f; } + body.theme2.ui-tabs-vertical .nfv-tabs .ui-state-default.ui-tabs-active { + border-bottom-color: #2f2f2f !important; + border-top-color: #2f2f2f !important; } + +.nfv-balloon { + min-width: 60px; + border: 1px solid #445a75; + box-shadow: 1px 2px 3px rgba(0, 0, 0, 0.35); + color: #1a2531; + background-color: #ffffff; + opacity: 1; + max-width: 350px; + z-index: 1; } + .nfv-balloon.ui-draggable-dragging { + z-index: 10; } + .nfv-balloon .balloon-header { + padding: 10px 22px 5px; + background-color: #a8bbdc; } + .nfv-balloon .balloon-header .balloon-title { + color: #253244; + margin-bottom: 10px; + margin-right: 23px; } + .nfv-balloon .balloon-header .ui-button { + position: absolute; + top: 10px; + right: 10px; + min-width: 20px; + margin-left: 20px; } + .nfv-balloon .balloon-content { + padding: 5px 22px 10px; + overflow: auto; + max-height: 250px; } + .nfv-balloon .balloon-content .node-attribute { + word-wrap: break-word; + padding: 10px 0; + border-bottom: 1px solid #445a75; } + +body.theme2 .nfv-balloon { + border: 1px solid #2f2f2f; + color: #b9bab5; + background-color: #333; + box-shadow: 0px 0px 6px 2px rgba(244, 246, 241, 0.8); } + body.theme2 .nfv-balloon .balloon-header { + background-color: #232323; } + body.theme2 .nfv-balloon .balloon-header .balloon-title { + color: #9bdb69; } + body.theme2 .nfv-balloon .balloon-content .node-attribute { + border-bottom: 1px solid #454544; } + +.network-graph .element.nfvo rect { + stroke-width: 2px; + stroke: #445a75; + fill: #ecf1f5; } + .network-graph .element.nfvo rect.rect-fadeout { + -webkit-animation: fadeout 0.25s; + -moz-animation: fadeout 0.25s; + -ms-animation: fadeout 0.25s; + -o-animation: fadeout 0.25s; + animation: fadeout 0.25s; } + +@keyframes fadeout { + from { + opacity: 1; } + to { + opacity: 0.2; } } + +@-moz-keyframes fadeout { + /* Firefox */ + from { + opacity: 1; } + to { + opacity: 0.2; } } + +@-webkit-keyframes fadeout { + /* Safari and Chrome */ + from { + opacity: 1; } + to { + opacity: 0.2; } } + +@-o-keyframes fadeout { + /* Opera */ + from { + opacity: 1; } + to { + opacity: 0.2; } } + .network-graph .element.nfvo rect.twins-container, .network-graph .element.nfvo rect.parent-container { + opacity: 0.5; + stroke-width: 1px; + fill: transparent; } + .network-graph .element.nfvo rect.node-title-frame { + fill: #a8bbdc; + stroke: #a8bbdc; } + .network-graph .element.nfvo rect.node-title-frame[status="removed"] { + fill: #a8bbdc; + stroke: #a8bbdc; } + .network-graph .element.nfvo rect.node-title-frame[status="completed"] { + fill: #1a2531; + stroke: #1a2531; } + .network-graph .element.nfvo rect.node-title-frame[status="in progress"] { + fill: #419ef1; + stroke: #419ef1; } + .network-graph .element.nfvo rect.node-title-frame[status="warning"] { + fill: #ff8a00; + stroke: #ff8a00; } + .network-graph .element.nfvo rect.node-title-frame[status="error"] { + fill: #e65353; + stroke: #e65353; } + .network-graph .element.nfvo rect.node-title-frame[status="down"] { + fill: #445a75; + stroke: #445a75; } + .network-graph .element.nfvo rect.main-rect[status="removed"] { + stroke: #a8bbdc; } + .network-graph .element.nfvo rect.main-rect[status="completed"] { + stroke: #1a2531; } + .network-graph .element.nfvo rect.main-rect[status="in progress"] { + stroke: #419ef1; } + .network-graph .element.nfvo rect.main-rect[status="warning"] { + stroke: #ff8a00; } + .network-graph .element.nfvo rect.main-rect[status="error"] { + stroke: #e65353; } + .network-graph .element.nfvo rect.main-rect[status="down"] { + stroke: #445a75; } + +.network-graph .element.nfvo path.right-arrow, .network-graph .element.nfvo path.left-arrow { + fill: transparent; + stroke: #ffffff; + stroke-width: 1.5px; + cursor: pointer; } + +.network-graph .element.nfvo .label { + fill: #ffffff; } + .network-graph .element.nfvo .label.twins-container-title { + fill: #344358; } + .network-graph .element.nfvo .label.sub-title { + font-size: 12px; } + +.network-graph .element.nfvo .port > .port-label { + opacity: 0; + z-index: 9999999; + fill: #1a2531; } + +.network-graph .element.nfvo .port > circle { + fill: #1a2531; + stroke: #ffffff; } + +.network-graph .element.nfvo .port:hover .port-label { + opacity: 1 !important; } + +.network-graph .link .connection { + stroke: #a8bbdc; + stroke-width: 2px; } + +.network-graph .link .marker-target { + stroke: #a8bbdc; + fill: #b9bab5; + stroke-width: 2px; } + +.network-graph .link .marker-source { + stroke: #b9bab5; + fill: #b9bab5; } + +.network-graph { + height: 690px; } + +.tree-graph .node { + cursor: pointer; } + .tree-graph .node circle { + stroke-width: 2px; + stroke: #445a75; + fill: #ecf1f5; } + .tree-graph .node text { + fill: #253244; + transform: rotate(-25deg); } + .tree-graph .node text.removed-node { + fill: rgba(37, 50, 68, 0.5); } + .tree-graph .node .nodeCircle.new-node { + stroke: #ff8a00; + stroke-dasharray: 4px; } + .tree-graph .node .nodeCircle.removed-node { + stroke: rgba(168, 187, 220, 0.5); } + .tree-graph .node .nodeCircle.has-children { + fill: #a8bbdc; } + +.tree-graph .link { + fill: none; + stroke: #a8bbdc; + stroke-width: 1.5px; } + +.link-tools .tool-remove { + display: none; } + +.marker-arrowheads .marker-arrowhead { + display: none; } + +.marker-vertex-group { + display: none; } + +.color-legend .statuses .legend, .color-legend .states .legend, .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .multi-node-status-cell .status { + position: relative; + margin: 0px 0px 12px 30px; } + .color-legend .statuses .legend::before, .color-legend .states .legend::before, .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .multi-node-status-cell .status::before { + width: 20px; + height: 20px; + position: absolute; + content: ""; + left: -30px; } + .color-legend .statuses .up.legend:before, .color-legend .states .up.legend:before, .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .multi-node-status-cell .up.status:before, .color-legend .statuses .completed.legend:before, .color-legend .states .completed.legend:before, .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .multi-node-status-cell .completed.status:before { + background: #1a2531; } + .color-legend .statuses .error.legend:before, .color-legend .states .error.legend:before, .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .multi-node-status-cell .error.status:before { + background: #e65353; } + .color-legend .statuses .warning.legend:before, .color-legend .states .warning.legend:before, .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .multi-node-status-cell .warning.status:before { + background: #ff8a00; } + .color-legend .statuses .down.legend:before, .color-legend .states .down.legend:before, .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .multi-node-status-cell .down.status:before { + background: #445a75; } + .color-legend .statuses .in-progress.legend:before, .color-legend .states .in-progress.legend:before, .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .multi-node-status-cell .in-progress.status:before { + background: #419ef1; } + .color-legend .statuses .deleted.legend:before, .color-legend .states .deleted.legend:before, .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .multi-node-status-cell .deleted.status:before { + background: #a8bbdc; } + .color-legend .statuses .modified.legend:before, .color-legend .states .modified.legend:before, .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .multi-node-status-cell .modified.status:before { + border: 2px solid #445a75; + box-shadow: 0px 0px 5px 2px #3ebd6b; } + +.color-legend { + padding: 10px; } + .color-legend .statuses .title, .color-legend .states .title { + text-decoration: underline; + margin: 10px 0; } + .color-legend .statuses .new .legend, .color-legend .states .new .legend { + margin-left: 17px; } + .color-legend .statuses .new .legend::before, .color-legend .states .new .legend::before { + width: 15px; + border: 2px solid #445a75; + opacity: 0.5; + left: -17px; } + +body.theme2 .tree-graph .node circle { + stroke: #b9bab5; + fill: #2f2f2f; } + +body.theme2 .tree-graph .node text { + fill: #8ccdf5; } + body.theme2 .tree-graph .node text.removed-node { + fill: rgba(140, 205, 245, 0.5); } + +body.theme2 .tree-graph .node .nodeCircle.new-node { + stroke: #f4f6f1; } + +body.theme2 .tree-graph .node .nodeCircle.removed-node { + stroke: rgba(170, 166, 217, 0.5); } + +body.theme2 .tree-graph .node .nodeCircle.has-children { + fill: #454544; } + +body.theme2 .tree-graph .link { + stroke: #b9bab5; } + +body.theme2 .network-graph .element.nfvo rect { + stroke: #b9bab5; + fill: #454544; } + body.theme2 .network-graph .element.nfvo rect.twins-container, body.theme2 .network-graph .element.nfvo rect.parent-container { + fill: transparent; } + body.theme2 .network-graph .element.nfvo rect.node-title-frame { + fill: #a8bbdc; } + body.theme2 .network-graph .element.nfvo rect.node-title-frame[status="removed"] { + fill: rgba(69, 69, 68, 0.7); + stroke: rgba(69, 69, 68, 0.7); } + body.theme2 .network-graph .element.nfvo rect.node-title-frame[status="completed"] { + fill: #b9bab5; + stroke: #b9bab5; } + body.theme2 .network-graph .element.nfvo rect.node-title-frame[status="in progress"] { + fill: #8ccdf5; + stroke: #8ccdf5; } + body.theme2 .network-graph .element.nfvo rect.node-title-frame[status="warning"] { + fill: #f7e385; + stroke: #f7e385; } + body.theme2 .network-graph .element.nfvo rect.node-title-frame[status="error"] { + fill: #ff7c54; + stroke: #ff7c54; } + body.theme2 .network-graph .element.nfvo rect.node-title-frame[status="down"] { + fill: #f4f6f1; + stroke: #f4f6f1; } + body.theme2 .network-graph .element.nfvo rect.main-rect[status="removed"] { + stroke: rgba(69, 69, 68, 0.7); } + body.theme2 .network-graph .element.nfvo rect.main-rect[status="completed"] { + stroke: #b9bab5; } + body.theme2 .network-graph .element.nfvo rect.main-rect[status="in progress"] { + stroke: #8ccdf5; } + body.theme2 .network-graph .element.nfvo rect.main-rect[status="warning"] { + stroke: #f7e385; } + body.theme2 .network-graph .element.nfvo rect.main-rect[status="error"] { + stroke: #ff7c54; } + body.theme2 .network-graph .element.nfvo rect.main-rect[status="down"] { + stroke: #f4f6f1; } + +body.theme2 .network-graph .element.nfvo path.right-arrow, body.theme2 .network-graph .element.nfvo path.left-arrow { + stroke: #232323; } + +body.theme2 .network-graph .element.nfvo .label { + fill: #232323; } + body.theme2 .network-graph .element.nfvo .label.twins-container-title { + fill: #f4f6f1; } + +body.theme2 .network-graph .element.nfvo .port > .port-label { + fill: #b9bab5; } + +body.theme2 .network-graph .element.nfvo .port > circle { + fill: #292929; + stroke: #f4f6f1; } + +body.theme2 .network-graph .link .connection { + stroke: #b9bab5; } + +body.theme2 .network-graph .link .marker-target { + stroke: #b9bab5; + fill: #b9bab5; } + +body.theme2 .network-graph .link .marker-source { + stroke: #b9bab5; + fill: #b9bab5; } + +body.theme2 .color-legend .statuses .up.legend:before, body.theme2 .color-legend .states .up.legend:before, body.theme2 .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .multi-node-status-cell .up.status:before, body.theme2 .color-legend .statuses .completed.legend:before, body.theme2 .color-legend .states .completed.legend:before, body.theme2 .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .multi-node-status-cell .completed.status:before { + background: #b9bab5; } + +body.theme2 .color-legend .statuses .error.legend:before, body.theme2 .color-legend .states .error.legend:before, body.theme2 .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .multi-node-status-cell .error.status:before { + background: #ff7c54; } + +body.theme2 .color-legend .statuses .warning.legend:before, body.theme2 .color-legend .states .warning.legend:before, body.theme2 .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .multi-node-status-cell .warning.status:before { + background: #f7e385; } + +body.theme2 .color-legend .statuses .down.legend:before, body.theme2 .color-legend .states .down.legend:before, body.theme2 .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .multi-node-status-cell .down.status:before { + background: #f4f6f1; } + +body.theme2 .color-legend .statuses .in-progress.legend:before, body.theme2 .color-legend .states .in-progress.legend:before, body.theme2 .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .multi-node-status-cell .in-progress.status:before { + background: #8ccdf5; } + +body.theme2 .color-legend .statuses .deleted.legend:before, body.theme2 .color-legend .states .deleted.legend:before, body.theme2 .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .multi-node-status-cell .deleted.status:before { + background: rgba(69, 69, 68, 0.7); } + +body.theme2 .color-legend .statuses .modified.legend:before, body.theme2 .color-legend .states .modified.legend:before, body.theme2 .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .multi-node-status-cell .modified.status:before { + border-color: #b9bab5; + box-shadow: 0px 0px 5px 2px #9bdb69; } + +body.theme2 .color-legend .statuses .new .legend::before, body.theme2 .color-legend .states .new .legend::before { + border-color: #b9bab5; } + +.nfv-pagination, .uxf-pagination { + text-align: right; } + .nfv-pagination .nfv-pagination-info, .uxf-pagination .nfv-pagination-info { + display: inline-block; + margin: 0 16px; } + .nfv-pagination .uxf-pagination-goto, .uxf-pagination .uxf-pagination-goto { + display: inline; } + .nfv-pagination a, .uxf-pagination a { + color: #1a2531; + cursor: pointer; + width: 33px; + height: 33px; + display: inline-block; + text-align: center; + border: 1px solid #a8bbdc; + line-height: 30px; } + .nfv-pagination a.uxf-pagination-page.active, .uxf-pagination a.uxf-pagination-page.active { + background-color: #a8bbdc; + border: 1px solid #a8bbdc; + font-weight: bold; + text-decoration: underline; } + .nfv-pagination .uxf-pagination-prev, .nfv-pagination .uxf-pagination-prev, .uxf-pagination .uxf-pagination-prev, .uxf-pagination .uxf-pagination-prev { + font-weight: bold; + color: #419ef1; + margin-right: -3px; } + .nfv-pagination .uxf-pagination-prev.disable, .nfv-pagination .uxf-pagination-prev.disable, .uxf-pagination .uxf-pagination-prev.disable, .uxf-pagination .uxf-pagination-prev.disable { + color: #445a75; } + .nfv-pagination .uxf-pagination-next, .nfv-pagination .uxf-pagination-next, .uxf-pagination .uxf-pagination-next, .uxf-pagination .uxf-pagination-next { + font-weight: bold; + color: #419ef1; + margin-left: -2px; } + .nfv-pagination .uxf-pagination-next.disable, .nfv-pagination .uxf-pagination-next.disable, .uxf-pagination .uxf-pagination-next.disable, .uxf-pagination .uxf-pagination-next.disable { + color: #445a75; } + +/* dataTable overrides */ +div.dataTables_paginate > ul.pagination > li > a { + border-radius: initial; + color: #1a2531; } + +div.dataTables_paginate > ul.pagination > li.active > a { + background-color: #a8bbdc; + border-color: #a8bbdc; } + +div.dataTables_paginate > ul.pagination > li.previous > a, +div.dataTables_paginate > ul.pagination > li.next > a { + color: #419ef1; } + +div.dataTables_paginate > ul.pagination > li.disabled > a { + background-color: transparent; + color: #445a75; } + div.dataTables_paginate > ul.pagination > li.disabled > a:hover { + color: initial; } + +body.theme2 { + /* dataTable overrides */ } + body.theme2 .nfv-pagination a, body.theme2 .uxf-pagination a { + color: #b9bab5; + border: 1px solid #2f2f2f; } + body.theme2 .nfv-pagination a.uxf-pagination-page.active, body.theme2 .uxf-pagination a.uxf-pagination-page.active { + background-color: #2f2f2f; + border: 1px solid #2f2f2f; } + body.theme2 .nfv-pagination .uxf-pagination-prev, body.theme2 .nfv-pagination .uxf-pagination-prev, body.theme2 .uxf-pagination .uxf-pagination-prev, body.theme2 .uxf-pagination .uxf-pagination-prev { + font-weight: bold; + color: #b9bab5; } + body.theme2 .nfv-pagination .uxf-pagination-prev.disable, body.theme2 .nfv-pagination .uxf-pagination-prev.disable, body.theme2 .uxf-pagination .uxf-pagination-prev.disable, body.theme2 .uxf-pagination .uxf-pagination-prev.disable { + color: #454544; } + body.theme2 .nfv-pagination .uxf-pagination-next, body.theme2 .nfv-pagination .uxf-pagination-next, body.theme2 .uxf-pagination .uxf-pagination-next, body.theme2 .uxf-pagination .uxf-pagination-next { + font-weight: bold; + color: #b9bab5; } + body.theme2 .nfv-pagination .uxf-pagination-next.disable, body.theme2 .nfv-pagination .uxf-pagination-next.disable, body.theme2 .uxf-pagination .uxf-pagination-next.disable, body.theme2 .uxf-pagination .uxf-pagination-next.disable { + color: #454544; } + body.theme2 div.dataTables_paginate > ul.pagination > li > a { + color: #b9bab5; } + body.theme2 div.dataTables_paginate > ul.pagination > li.active > a { + color: #9bdb69; + background-color: #333; + border-color: #333; } + body.theme2 div.dataTables_paginate > ul.pagination > li.previous > a, + body.theme2 div.dataTables_paginate > ul.pagination > li.next > a { + color: #b9bab5; } + body.theme2 div.dataTables_paginate > ul.pagination > li.disabled > a { + background-color: transparent; + color: #454544; } + +.nfv-notifications-manager { + position: fixed; + top: 40px; + width: 50%; + left: 25%; + z-index: 99999; } + +.notification { + position: relative; + padding-left: 5px; + padding-right: 5px; + height: 0px; + background: #ffffff; + border: 1px solid #419ef1; + border-top: 0; + line-height: 40px; + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; + color: #253244; } + .notification .notification-icon { + padding: 5px; + margin-right: 5px; + margin-left: 30px; + vertical-align: middle; + font-family: FontAwesome; } + .notification .notification-icon.error-icon:before { + content: "\f057"; + color: #e65353; } + .notification .notification-icon.success-icon:before { + content: "\f058"; + color: #3ebd6b; } + .notification .notification-icon.warning-icon:before { + content: "\f071"; + color: #ff8a00; } + .notification .notification-header { + display: inline; + margin-right: 5px; } + .notification .notification-header.error { + color: #e65353; } + .notification .notification-header::after { + content: "!"; } + .notification .notification-content.error { + color: #e65353; } + .notification .notification-content .notification-secondary { + display: block; + margin-left: 64px; + margin-right: 49px; + position: relative; + top: -13px; + color: #445a75; + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; + line-height: 19px; } + .notification .close-button { + position: absolute; + top: 0px; + right: 0px; + font-size: 36px; + color: #253244; + text-shadow: 0 1px 0 #ffffff; + opacity: 0.2; + filter: alpha(opacity=20); + vertical-align: middle; + height: 100%; + cursor: pointer !important; + margin-right: 30px; + margin-left: 17px; } + .notification .close-button:hover { + text-decoration: none; } + +body.theme2 .notification { + background: #454544; + border-color: #2f2f2f; + color: #b9bab5; } + body.theme2 .notification .notification-icon.error-icon:before { + color: #ff7c54; } + body.theme2 .notification .notification-icon.success-icon:before { + color: #9bdb69; } + body.theme2 .notification .notification-icon.warning-icon:before { + color: #f7e385; } + body.theme2 .notification .notification-content .notification-secondary { + color: #b9bab5; } + +body.theme2 .close-button { + color: #b9bab5; + text-shadow: 0 1px 0 #f4f6f1; } + +/* dataTable overrides */ +.data-table-wrapper { + position: relative; + transition: background-color 0.2s, color 0.2s, border 0.2s; } + .data-table-wrapper table.dataTable.table-striped > tbody > tr:nth-of-type(even) { + background-color: #ecf1f5; } + .data-table-wrapper table.dataTable.table-striped > tbody > tr:nth-of-type(odd) { + background-color: #e1e8f1; } + .data-table-wrapper table.dataTable.table-striped > tbody > tr:nth-of-type(even):hover, + .data-table-wrapper table.dataTable.table-striped > tbody > tr:nth-of-type(odd):hover { + background-color: #f6e6cd; } + .data-table-wrapper table.dataTable > thead > tr, + .data-table-wrapper table.dataTable > tbody > tr { + transition: background-color 0.2s; } + .data-table-wrapper table.dataTable > thead > tr > th, + .data-table-wrapper table.dataTable .dataTables_wrapper.no-footer .dataTables_scrollBody { + border-bottom: 1px solid #a8bbdc; } + .data-table-wrapper table.dataTable > tbody > tr > td, + .data-table-wrapper table.dataTable > thead > tr > th { + border-left: 1px solid #a8bbdc; + border-top: 1px solid #a8bbdc; } + .data-table-wrapper table.dataTable > tbody > tr:first-child > td { + border-top: none; } + .data-table-wrapper table.dataTable > tbody > tr > td:last-child, + .data-table-wrapper table.dataTable > thead > tr > th:last-child { + border-right: 1px solid #a8bbdc; } + .data-table-wrapper table.dataTable > tbody > tr:hover { + background-color: #f6e6cd; + cursor: pointer; } + .data-table-wrapper table.dataTable > tbody > tr > td.dataTables_empty { + pointer-events: none; } + .data-table-wrapper table.dataTable > thead > tr > th:hover { + background-color: #f6e6cd; } + .data-table-wrapper div.dataTables_wrapper { + bottom: 30px; + left: 30px; + position: absolute; + right: 30px; + top: 30px; + width: auto; } + .data-table-wrapper div.dataTables_wrapper label select, + .data-table-wrapper div.dataTables_wrapper label input { + outline: 0; + height: 30px; } + .data-table-wrapper div.dataTables_wrapper.no-footer .dataTables_scrollBody { + border-bottom: 1px solid rgba(168, 187, 220, 0.3); } + .data-table-wrapper div.dataTables_wrapper .ColVis_Button.ColVis_MasterButton { + background: none; + border: none; + box-shadow: none; + color: #ff8a00 !important; + font-family: FontAwesome; + font-size: 21px; + margin-left: 15px; + outline: 0px; } + .data-table-wrapper div.dataTables_wrapper .ColVis_Button.ColVis_MasterButton:before { + content: '\f013'; } + .data-table-wrapper div.dataTables_wrapper .ColVis_Button.ColVis_MasterButton span { + display: none; } + .data-table-wrapper .dataTables_wrapper .dataTables_length, + .data-table-wrapper .dataTables_wrapper .dataTables_filter, + .data-table-wrapper .dataTables_wrapper .dataTables_info, + .data-table-wrapper .dataTables_wrapper .dataTables_processing, + .data-table-wrapper .dataTables_wrapper .dataTables_paginate { + color: #1a2531; } + .data-table-wrapper .dataTables_wrapper .dataTables_length .form-control.input-sm { + appearance: none; + -moz-appearance: none; + -webkit-appearance: none; + background: url("../images/images_theme_1/drop_down_down_arrow.png") no-repeat 102% #ffffff; + padding: 0 17px 0 10px; + text-align: left; + border: 1px solid #a8bbdc; } + .data-table-wrapper .dataTables_wrapper .dataTables_filter .form-control.input-sm { + border-radius: 2px; + border: none; + border-bottom: 1px solid #a8bbdc; } + +body.theme2 .data-table-wrapper table.dataTable thead tr th { + color: #aaa6d9; } + +body.theme2 .data-table-wrapper table.dataTable.table-striped > tbody > tr:nth-of-type(even) { + background-color: #333; } + +body.theme2 .data-table-wrapper table.dataTable.table-striped > tbody > tr:nth-of-type(odd) { + background-color: #292929; } + +body.theme2 .data-table-wrapper table.dataTable.table-striped > tbody > tr:nth-of-type(even):hover, +body.theme2 .data-table-wrapper table.dataTable.table-striped > tbody > tr:nth-of-type(odd):hover { + background-color: #454544; } + +body.theme2 .data-table-wrapper table.dataTable > thead > tr, +body.theme2 .data-table-wrapper table.dataTable > tbody > tr { + transition: background-color 0.2s; } + +body.theme2 .data-table-wrapper table.dataTable > thead > tr > th, +body.theme2 .data-table-wrapper table.dataTable .dataTables_wrapper.no-footer .dataTables_scrollBody { + border-bottom: 1px solid #2f2f2f; } + +body.theme2 .data-table-wrapper table.dataTable > tbody > tr > td, +body.theme2 .data-table-wrapper table.dataTable > thead > tr > th { + border-left: 1px solid #2f2f2f; + border-top: 1px solid #2f2f2f; } + +body.theme2 .data-table-wrapper table.dataTable > tbody > tr:first-child > td { + border-top: none; } + +body.theme2 .data-table-wrapper table.dataTable > tbody > tr > td:last-child, +body.theme2 .data-table-wrapper table.dataTable > thead > tr > th:last-child { + border-right: 1px solid #2f2f2f; } + +body.theme2 .data-table-wrapper table.dataTable > tbody > tr:hover { + background-color: #454544; + cursor: pointer; } + +body.theme2 .data-table-wrapper table.dataTable > tbody > tr > td.dataTables_empty { + pointer-events: none; } + +body.theme2 .data-table-wrapper table.dataTable > thead > tr > th:hover { + background-color: #454544; } + +body.theme2 .data-table-wrapper .dataTables_wrapper .dataTables_length, +body.theme2 .data-table-wrapper .dataTables_wrapper .dataTables_filter, +body.theme2 .data-table-wrapper .dataTables_wrapper .dataTables_info, +body.theme2 .data-table-wrapper .dataTables_wrapper .dataTables_processing, +body.theme2 .data-table-wrapper .dataTables_wrapper .dataTables_paginate { + color: #8ccdf5; } + +body.theme2 .data-table-wrapper .dataTables_wrapper .dataTables_length .form-control.input-sm { + color: #b9bab5; + background: url("../images/images_theme_1/drop_down_down_arrow.png") no-repeat 102% #232323; + border: 1px solid #333; } + +body.theme2 .data-table-wrapper div.dataTables_wrapper.no-footer .dataTables_scrollBody { + border-bottom: 1px solid #454544; } + +body.theme2 .data-table-wrapper div.dataTables_wrapper label select, +body.theme2 .data-table-wrapper div.dataTables_wrapper label input { + background-color: #232323; + color: #b9bab5; } + +body.theme2 .data-table-wrapper div.dataTables_wrapper .ColVis_Button.ColVis_MasterButton { + color: #8ccdf5 !important; } + body.theme2 .data-table-wrapper div.dataTables_wrapper .ColVis_Button.ColVis_MasterButton span { + display: none; } + +.topology-view .controllers { + width: 50px; + z-index: 20; + position: fixed; } + .topology-view .controllers .tree-toggle-button, .topology-view .controllers .network-toggle-button, .topology-view .controllers .service-toggle-button { + border: none; + min-width: 50px; } + .topology-view .controllers .tree-toggle-button .ui-button-text, .topology-view .controllers .network-toggle-button .ui-button-text, .topology-view .controllers .service-toggle-button .ui-button-text { + font-size: 20px; + padding: 0; } + .topology-view .controllers .tree-toggle-button.active, .topology-view .controllers .network-toggle-button.active, .topology-view .controllers .service-toggle-button.active { + color: #419ef1; } + .topology-view .controllers .diff-ind { + display: inline-block; } + +.network-topology-view .color-legend-icon { + display: inline-block; + position: absolute; + bottom: 10px; + left: 30px; + font-size: 25px; } + +.network-topology-view .right-click-context-menu { + display: none; + position: fixed; + border: 1px solid #1a2531; + box-shadow: 0px 1px 7px #1a2531; + background: #ecf1f5; + padding: 15px; } + .network-topology-view .right-click-context-menu .context-menu-item { + padding-top: 4px; + border-bottom: 2px solid #ecf1f5; } + .network-topology-view .right-click-context-menu .context-menu-item:first-child { + padding-top: 0; } + .network-topology-view .right-click-context-menu .context-menu-item:hover { + cursor: pointer; + display: inline-block; + border-bottom: 2px solid #419ef1; } + +.network-topology-view .right-pane-controller { + position: fixed; + right: -28%; + width: 28%; + top: 0; + background: rgba(255, 255, 255, 0.95); + border: 1px solid #253244; + height: 97%; + box-shadow: -3px 3px 10px 0px #1a2531; + z-index: 100; } + .network-topology-view .right-pane-controller .header { + padding: 10px; + background: #445a75; + color: #ecf1f5; + cursor: move; } + .network-topology-view .right-pane-controller .header .node-attributes-title { + display: inline-block; } + .network-topology-view .right-pane-controller .header .toggle { + float: right; + display: inline-block; + cursor: pointer; + font-size: 22px; } + .network-topology-view .right-pane-controller .header .toggle * { + margin-left: 5px; } + .network-topology-view .right-pane-controller .header .toggle .minimize { + vertical-align: text-bottom; } + .network-topology-view .right-pane-controller .header .toggle .minimize:hover, .network-topology-view .right-pane-controller .header .toggle .hide:hover { + color: #ff8a00; } + .network-topology-view .right-pane-controller .node-attributes .nfv-tabs-v3 { + padding: 10px; } + .network-topology-view .right-pane-controller .node-attributes .node-attributes-list { + overflow: auto; + height: 71vh; } + .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .node-attribute-list-item { + display: table; + width: 100%; } + .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .node-attribute-list-item .node-attribute { + display: table-cell; + padding: 5px 0 5px 10px; + max-width: 0px; + text-overflow: ellipsis; + overflow: hidden; + white-space: nowrap; } + .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .node-attribute-list-item .node-attribute.name { + border-right: 1px solid #a8bbdc; } + .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .node-attribute-list-item:first-child { + border-top: 1px solid #a8bbdc; + border-bottom: 1px solid #a8bbdc; } + .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .node-attribute-list-item:last-child { + border-bottom: none; } + .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .node-attribute-list-item:nth-child(even) { + background: rgba(168, 187, 220, 0.2); } + .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .node-attribute-list-item:hover, .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .node-attribute-list-item.selected { + background: rgba(65, 158, 241, 0.5); } + .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .multi-node-item .node-attribute.name, .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .multi-node-header .node-attribute.name { + width: 85%; + text-align: center; } + .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .multi-node-item .node-attribute.value, .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .multi-node-header .node-attribute.value { + width: 15%; + text-align: center; } + .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .multi-node-status-cell .status::before { + border-radius: 50%; } + .network-topology-view .right-pane-controller .node-attributes .nfv-collapsible-item .nfv-collapsible-title { + margin-bottom: 0; + height: 50px; } + .network-topology-view .right-pane-controller .node-attributes .nfv-collapsible-item .nfv-collapsible-content .kpi-item { + display: inline-block; + margin: 0 22px; + text-align: center; } + .network-topology-view .right-pane-controller .node-attributes .nfv-collapsible-item .nfv-collapsible-content .kpi-item .kpi-item-icon { + width: 30px; + height: 30px; + background-position-y: -27px; } + .network-topology-view .right-pane-controller .node-attributes .nfv-collapsible-item .nfv-collapsible-content .kpi-item .kpi-item-icon.cpu { + background-image: url("../images/images_theme_1/cpu.png"); + background-repeat: no-repeat; } + .network-topology-view .right-pane-controller .node-attributes .nfv-collapsible-item .nfv-collapsible-content .kpi-item .kpi-item-icon.disk { + background-image: url("../images/images_theme_1/disk.png"); + background-repeat: no-repeat; } + .network-topology-view .right-pane-controller .node-attributes .nfv-collapsible-item .nfv-collapsible-content .kpi-item .kpi-item-icon.memory { + background-image: url("../images/images_theme_1/memory.png"); + background-repeat: no-repeat; } + .network-topology-view .right-pane-controller .node-attributes .nfv-collapsible-item .nfv-collapsible-content .kpi-item .kpi-item-icon.network { + background-image: url("../images/images_theme_1/network.png"); + background-repeat: no-repeat; } + .network-topology-view .right-pane-controller .node-attributes .nfv-collapsible-item .nfv-collapsible-content .kpi-item .kpi-item-name { + text-transform: uppercase; } + .network-topology-view .right-pane-controller .kpi-graph { + overflow: hidden; + left: -315px; + top: 200px; + box-shadow: -3px 3px 10px 0px #1a2531; } + .network-topology-view .right-pane-controller .kpi-graph .header { + padding: 5px; } + .network-topology-view .right-pane-controller .kpi-graph .kpi-graph-area { + background: #ffffff; + border: 1px solid #253244; } + .network-topology-view .right-pane-controller .kpi-graph .kpi-graph-area .highcharts-container { + margin-top: 20px; } + +body.theme2 .topology-view .tree-toggle-button.active, body.theme2 .topology-view .network-toggle-button.active, body.theme2 .topology-view .service-toggle-button.active { + color: #9bdb69; } + +body.theme2 .network-topology-view .color-legend-icon { + color: #f7e385; } + +body.theme2 .network-topology-view .right-click-context-menu { + border: 1px solid #b9bab5; + box-shadow: 0px 1px 7px #b9bab5; + background: #232323; } + body.theme2 .network-topology-view .right-click-context-menu .context-menu-item { + border-bottom: 2px solid #232323; } + body.theme2 .network-topology-view .right-click-context-menu .context-menu-item:hover { + border-bottom: 2px solid #8ccdf5; } + +body.theme2 .network-topology-view .right-pane-controller { + background: #232323; + border-color: #333; + box-shadow: -3px 3px 10px 0px #333; } + body.theme2 .network-topology-view .right-pane-controller .header { + background: #232323; + color: #9bdb69; } + body.theme2 .network-topology-view .right-pane-controller .header .toggle .minimize:hover, body.theme2 .network-topology-view .right-pane-controller .header .toggle .hide:hover { + color: #ff8a00; } + body.theme2 .network-topology-view .right-pane-controller .node-attributes .ui-tabs-panel { + border-color: transparent; } + body.theme2 .network-topology-view .right-pane-controller .node-attributes [id=tabs-kpi] .node-attributes-list .node-attribute-list-item:nth-child(even) { + background: inherit; } + body.theme2 .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .node-attribute-list-item .node-attribute.name { + border-right-color: #333; } + body.theme2 .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .node-attribute-list-item:first-child { + border-top: 1px solid #333; + border-bottom: 1px solid #333; + color: #aaa6d9; } + body.theme2 .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .node-attribute-list-item:nth-child(even) { + background: #292929; } + body.theme2 .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .node-attribute-list-item:hover, body.theme2 .network-topology-view .right-pane-controller .node-attributes .node-attributes-list .node-attribute-list-item.selected { + background: rgba(140, 205, 245, 0.5); } + body.theme2 .network-topology-view .right-pane-controller .node-attributes .nfv-collapsible-item .nfv-collapsible-content .kpi-item { + display: inline-block; + margin: 0 22px; + text-align: center; } + body.theme2 .network-topology-view .right-pane-controller .node-attributes .nfv-collapsible-item .nfv-collapsible-content .kpi-item .kpi-item-icon { + background-position-y: 0px; } + body.theme2 .network-topology-view .right-pane-controller .node-attributes .nfv-collapsible-item .nfv-collapsible-content .kpi-item .kpi-item-value { + color: #f4f6f1; } + body.theme2 .network-topology-view .right-pane-controller .node-attributes .nfv-collapsible-item .nfv-collapsible-content .kpi-item .kpi-item-name { + color: #9bdb69; } + body.theme2 .network-topology-view .right-pane-controller .kpi-graph { + box-shadow: -1px 1px 5px 0px #b9bab5; } + body.theme2 .network-topology-view .right-pane-controller .kpi-graph .kpi-graph-area { + background: #333; + border-color: #2f2f2f; } + body.theme2 .network-topology-view .right-pane-controller .kpi-graph .highcharts-container .highcharts-background { + fill: #333; } + body.theme2 .network-topology-view .right-pane-controller .kpi-graph .highcharts-container tspan { + fill: #f4f6f1; } + body.theme2 .network-topology-view .right-pane-controller .kpi-graph .highcharts-container .highcharts-tooltip rect:nth-child(4) { + fill: #232323; } + +.nfv-loader { + background-color: rgba(0, 0, 0, 0.65); + position: fixed; + top: 0; + left: 0; + z-index: 200001; + width: 100%; + height: 100%; } + .nfv-loader .loading { + width: 200px; + height: 200px; + position: absolute; + top: 40%; + left: 45%; } + .nfv-loader .loading .circle { + border-radius: 100%; + border-top: 5px solid #419ef1; + margin: auto; + transform-origin: 50%; + position: relative; } + .nfv-loader .loading .s_3 { + width: 200px; + height: 200px; + animation: rot_right 2s infinite linear; + -webkit-animation: rot_right 2s infinite linear; + transition: 2s; + -webkit-transition: 2s; } + .nfv-loader .loading .s_2 { + width: 150px; + height: 150px; + margin-top: 10px; + animation: rot_left 2s infinite linear; + -webkit-animation: rot_left 2s infinite linear; + transition: 2s; + -webkit-transition: 2s; + margin-top: -190px; } + .nfv-loader .loading .s_1 { + width: 100px; + height: 100px; + margin-top: 10px; + animation: rot_right 2s infinite linear; + -webkit-animation: rot_right 2s infinite linear; + transition: 2s; + -webkit-transition: 2s; + margin-top: -140px; } + +@keyframes rot_right { + from { + transform: rotate(0deg); } + to { + transform: rotate(360deg); } } + +@-webkit-keyframes rot_right { + from { + transform: rotate(0deg); } + to { + transform: rotate(360deg); } } + +@keyframes rot_left { + from { + transform: rotate(360deg); } + to { + transform: rotate(0deg); } } + +@-webkit-keyframes rot_left { + from { + transform: rotate(360deg); } + to { + transform: rotate(0deg); } } + .nfv-loader .loading .s_title { + border: 0; + color: white; + text-align: center; + margin-top: -60px; + animation: blink 2s infinite linear; + -webkit-animation: blink 2s infinite linear; + transition: 2s; + -webkit-transition: 2s; + letter-spacing: 1px; } + +@keyframes blink { + 0% { + opacity: 1; } + 50% { + opacity: 0.5; } + 100% { + opacity: 1; } } + +@-webkit-keyframes blink { + 0% { + opacity: 1; } + 50% { + opacity: 0.5; } + 100% { + opacity: 1; } } + +/* Components */ +.tasks-handler, .parameters-tab .tasks-handler { + position: absolute; + top: 0; + right: 0; + bottom: 0; + left: 170px; } + .tasks-handler .reject-button { + display: inline-block; + margin-top: 18px; } + .tasks-handler .right-side-buttons { + position: absolute; + display: inline-block; + top: 12px; + right: 2%; } + .tasks-handler .right-side-buttons .skip-to-end-button { + display: none; } + .tasks-handler .right-side-buttons .approve-button { + position: initial !important; + margin-left: 30px; } + +.not-editable { + pointer-events: none; } + .not-editable input, .not-editable select { + border: none; + background: #ffffff; } + +.service-attributes { + overflow-y: auto; + margin-top: 30px; + margin-bottom: 30px; } + .service-attributes .mandatory { + margin-bottom: 30px; } + .service-attributes .form-container .form-element--label { + margin-bottom: 15px; + border-left: none; + position: relative; } + .service-attributes .form-element { + padding-top: 20px; + border-left: 3px solid #419ef1; } + .service-attributes .form-element .form-element--label { + display: inline-block; + margin-right: 10px; + min-width: 200px; + padding-left: 20px; } + .service-attributes .form-element input { + min-width: 150px; } + .service-attributes .form-element select { + min-width: 172px; } + .service-attributes .form-element .form-element--error-message { + display: block; + margin-left: 235px; } + .service-attributes .form-element-container { + margin-bottom: 80px; } + .service-attributes .previous-value { + margin-left: 50px; } + .service-attributes .previous-value:before { + content: "Previous: "; } + +.orchestration-tree { + width: 120%; } + +.launch-service-wizard .nfv-wizard-content { + background: #ffffff; + padding-left: 30px; + padding-top: 30px; + position: absolute; + overflow-x: hidden; + overflow-y: auto; + top: 58px; + left: 0px; + bottom: 64px; + right: 0px; } + .launch-service-wizard .nfv-wizard-content .select-service-title, .launch-service-wizard .nfv-wizard-content .launch-service-title, .launch-service-wizard .nfv-wizard-content .parameters-service-title { + color: #253244; + margin-bottom: 30px; } + .launch-service-wizard .nfv-wizard-content .service-list-item { + display: inline-block; + background-color: rgba(236, 241, 245, 0.5); + padding-top: 15px; + width: 202px; + margin: 0 15px 15px 0; + height: 130px; + cursor: pointer; + transition: background-color 0.25s; } + .launch-service-wizard .nfv-wizard-content .service-list-item:hover { + background-color: #ecf1f5; } + .launch-service-wizard .nfv-wizard-content .service-list-item .service-image { + text-align: center; + font-size: 44px; } + .launch-service-wizard .nfv-wizard-content .service-list-item .service-name { + text-align: center; + display: block; + /* Fallback for non-webkit */ + display: -webkit-box; + max-width: 170px; + height: 49.5px; + /* Fallback for non-webkit */ + margin: 10px auto 0; + font-size: 15px; + line-height: 1.1; + -webkit-line-clamp: 3; + -webkit-box-orient: vertical; + overflow: hidden; + text-overflow: ellipsis; + word-wrap: break-word; } + +.launch-service-wizard .wizard-nav-controls .skip-to-end { + position: absolute; + right: 160px; } + +body.theme2 .not-editable input, body.theme2 .not-editable select { + background: #232323; } + +body.theme2 .service-attributes .form-container .form-element--label::before { + background-color: #333; } + +body.theme2 .service-attributes .form-element { + border-left: 3px solid #8ccdf5; } + +body.theme2 .launch-service-wizard .nfv-wizard-content { + background: #232323; + padding-left: 30px; } + body.theme2 .launch-service-wizard .nfv-wizard-content .select-service-title, body.theme2 .launch-service-wizard .nfv-wizard-content .launch-service-title, body.theme2 .launch-service-wizard .nfv-wizard-content .parameters-service-title { + color: #aaa6d9; } + body.theme2 .launch-service-wizard .nfv-wizard-content .service-list-item { + background-color: rgba(47, 47, 47, 0.8); } + body.theme2 .launch-service-wizard .nfv-wizard-content .service-list-item:hover { + background-color: #2f2f2f; } + +.system-events .dataTable .column.type .type-icon, .service-events-tab .service-events .dataTable .column.type .type-icon { + width: 100%; + height: 28px; + font-family: FontAwesome; + font-size: 20px; + text-align: center; } + .system-events .dataTable .column.type .type-icon.error, .service-events-tab .service-events .dataTable .column.type .type-icon.error { + color: #e65353; } + .system-events .dataTable .column.type .type-icon.error:before, .service-events-tab .service-events .dataTable .column.type .type-icon.error:before { + content: '\f05c'; } + .system-events .dataTable .column.type .type-icon.info, .service-events-tab .service-events .dataTable .column.type .type-icon.info { + color: #419ef1; } + .system-events .dataTable .column.type .type-icon.info:before, .service-events-tab .service-events .dataTable .column.type .type-icon.info:before { + content: '\f05a'; } + .system-events .dataTable .column.type .type-icon.warning, .service-events-tab .service-events .dataTable .column.type .type-icon.warning { + color: #419ef1; } + .system-events .dataTable .column.type .type-icon.warning:before, .service-events-tab .service-events .dataTable .column.type .type-icon.warning:before { + content: '\f071'; } + +.system-events .dataTable .column.message .column-cell-content .flexible-content, .service-events-tab .service-events .dataTable .column.message .column-cell-content .flexible-content { + display: flex; + flex-wrap: nowrap; } + .system-events .dataTable .column.message .column-cell-content .flexible-content .service-message, .service-events-tab .service-events .dataTable .column.message .column-cell-content .flexible-content .service-message { + flex-basis: 85%; + width: 50px; + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; + padding-right: 20px; } + .system-events .dataTable .column.message .column-cell-content .flexible-content .nfv-secondary-button, .service-events-tab .service-events .dataTable .column.message .column-cell-content .flexible-content .nfv-secondary-button, .system-events .dataTable .column.message .column-cell-content .flexible-content .ui-dialog[role="dialog"] .ui-dialog-buttonset, .ui-dialog[role="dialog"] .system-events .dataTable .column.message .column-cell-content .flexible-content .ui-dialog-buttonset, .service-events-tab .service-events .dataTable .column.message .column-cell-content .flexible-content .ui-dialog[role="dialog"] .ui-dialog-buttonset, .ui-dialog[role="dialog"] .service-events-tab .service-events .dataTable .column.message .column-cell-content .flexible-content .ui-dialog-buttonset { + flex-basis: 15%; + flex-shrik: 0; } + .system-events .dataTable .column.message .column-cell-content .flexible-content .nfv-secondary-button .uxf-button, .service-events-tab .service-events .dataTable .column.message .column-cell-content .flexible-content .nfv-secondary-button .uxf-button, .system-events .dataTable .column.message .column-cell-content .flexible-content .ui-dialog[role="dialog"] .ui-dialog-buttonset .uxf-button, .ui-dialog[role="dialog"] .system-events .dataTable .column.message .column-cell-content .flexible-content .ui-dialog-buttonset .uxf-button, .service-events-tab .service-events .dataTable .column.message .column-cell-content .flexible-content .ui-dialog[role="dialog"] .ui-dialog-buttonset .uxf-button, .ui-dialog[role="dialog"] .service-events-tab .service-events .dataTable .column.message .column-cell-content .flexible-content .ui-dialog-buttonset .uxf-button { + width: 75px; + min-width: 0; } + .system-events .dataTable .column.message .column-cell-content .flexible-content .nfv-secondary-button .ui-button-text, .service-events-tab .service-events .dataTable .column.message .column-cell-content .flexible-content .nfv-secondary-button .ui-button-text, .system-events .dataTable .column.message .column-cell-content .flexible-content .ui-dialog[role="dialog"] .ui-dialog-buttonset .ui-button-text, .ui-dialog[role="dialog"] .system-events .dataTable .column.message .column-cell-content .flexible-content .ui-dialog-buttonset .ui-button-text, .service-events-tab .service-events .dataTable .column.message .column-cell-content .flexible-content .ui-dialog[role="dialog"] .ui-dialog-buttonset .ui-button-text, .ui-dialog[role="dialog"] .service-events-tab .service-events .dataTable .column.message .column-cell-content .flexible-content .ui-dialog-buttonset .ui-button-text { + padding: 3px 0; } + +.system-events .dataTable .column.where .column-cell-content, .service-events-tab .service-events .dataTable .column.where .column-cell-content { + max-width: 160px; + min-width: 150px; } + +.system-events .dataTable .column.component .column-cell-content, .service-events-tab .service-events .dataTable .column.component .column-cell-content { + display: table-cell; + margin-right: 25px; + text-overflow: ellipsis; + overflow: hidden; + max-width: 170px; } + +body.theme2 .system-events .dataTable .column.type .type-icon.error, body.theme2 .service-events-tab .service-events .dataTable .column.type .type-icon.error, .service-events-tab body.theme2 .service-events .dataTable .column.type .type-icon.error { + color: #ff7c54; } + +body.theme2 .system-events .dataTable .column.type .type-icon.info, body.theme2 .service-events-tab .service-events .dataTable .column.type .type-icon.info, .service-events-tab body.theme2 .service-events .dataTable .column.type .type-icon.info { + color: #8ccdf5; } + +body.theme2 .system-events .dataTable .column.type .type-icon.warning, body.theme2 .service-events-tab .service-events .dataTable .column.type .type-icon.warning, .service-events-tab body.theme2 .service-events .dataTable .column.type .type-icon.warning { + color: #f7e385; } + +.service-details .activities-button { + float: right !important; } + .service-details .activities-button .uxf-button.ui-button.ui-widget.ui-state-default.ui-corner-all.ui-button-text-only { + border: 1px solid #253244; + color: #253244; + background-color: #ffffff; } + .service-details .activities-button .uxf-button.ui-button.ui-widget.ui-state-default.ui-corner-all.ui-button-text-only:hover { + color: #419ef1; + border: 1px solid #419ef1; } + @media screen and (max-width: 1024px) { + .service-details .activities-button .uxf-button { + margin: 8px; + min-width: 80px; } + .service-details .activities-button .uxf-button .ui-button-text { + padding: 0px 5px; } } + +@media screen and (max-width: 1024px) { + .service-details .nfv-tabs-v1 li.ui-state-default { + margin: 0 30px; } } + +.service-details .services-tabs { + left: 0px; + position: fixed; + right: 0px; + top: 70px; + transition: background-color 0.2s; + z-index: 100; } + +.service-details div[role="tabpanel"].ui-tabs-panel { + padding-top: 40px; } + +.service-details .workflow-view .refresh-button { + border: none; } + .service-details .workflow-view .refresh-button .ui-button-text { + font-size: 30px; + padding: 0; } + +/* service overview tab */ +.service-overview-tab .service-metrics { + padding: 14px 14px 0px 14px; } + .service-overview-tab .service-metrics .service-metric { + background-color: rgba(236, 241, 245, 0.5); + display: inline-block; + transition: background-color 0.2s; + padding: 10px; } + @media screen and (max-width: 1024px) { + .service-overview-tab .service-metrics .service-metric { + padding: 5px; } + .service-overview-tab .service-metrics .service-metric:first-child { + padding-top: 6px; } } + @media screen and (min-width: 1224px) { + .service-overview-tab .service-metrics .service-metric { + min-width: 150px; + margin-right: 12px; } } + .service-overview-tab .service-metrics .service-metric .vnf-icon, .service-overview-tab .service-metrics .service-metric .vm-icon { + font-size: 55px; + display: inline-block; + position: relative; + top: -5px; } + .service-overview-tab .service-metrics .service-metric .metric-details { + display: inline-block; + line-height: 1.0; + margin-left: 15px; } + .service-overview-tab .service-metrics .service-status .service-status-icon { + display: inline-block; + padding-right: 20px; + font-size: 55px; + position: relative; + top: -5px; } + .service-overview-tab .service-metrics .service-status .service-status-icon.active i:before { + color: #419ef1; + content: '\f046'; } + .service-overview-tab .service-metrics .service-status .service-status-icon.new i:before, + .service-overview-tab .service-metrics .service-status .service-status-icon.service-tree-created i:before, + .service-overview-tab .service-metrics .service-status .service-status-icon.service-tree-approved i:before, + .service-overview-tab .service-metrics .service-status .service-status-icon.workflow-created i:before, + .service-overview-tab .service-metrics .service-status .service-status-icon.workflow-started i:before { + color: #419ef1; + content: '\f017'; } + .service-overview-tab .service-metrics .service-status .service-status-icon.terminated i:before { + color: #419ef1; + content: '\f05e'; } + .service-overview-tab .service-metrics .service-status .service-status-icon.error i:before { + color: #e65353; + content: '\f05c'; } + .service-overview-tab .service-metrics .service-status .service-details { + display: inline-block; + border-left: 1px solid #454544; + padding-left: 20px; } + .service-overview-tab .service-metrics .service-status .service-details .status { + color: #419ef1; } + .service-overview-tab .service-metrics .service-status .service-details .service-times { + color: #1a2531; } + .service-overview-tab .service-metrics .service-status .service-details .service-times .service-time-value { + color: #419ef1; + float: right; + margin-left: 12px; } + +.service-overview-tab .service-detailed-info { + padding: 14px; } + .service-overview-tab .service-detailed-info .service-tasks, .service-overview-tab .service-detailed-info .service-events { + background: rgba(236, 241, 245, 0.5); } + @media screen and (min-width: 1224px) { + .service-overview-tab .service-detailed-info .service-tasks, .service-overview-tab .service-detailed-info .service-events { + display: inline-block; + vertical-align: top; } } + .service-overview-tab .service-detailed-info .service-tasks .list-header, .service-overview-tab .service-detailed-info .service-events .list-header { + color: #419ef1; + padding: 4px 30px; + border-bottom: 1px solid rgba(168, 187, 220, 0.3); + transition: color 0.2s, border 0.2s; } + .service-overview-tab .service-detailed-info .service-tasks .see-all-link, .service-overview-tab .service-detailed-info .service-events .see-all-link { + border-top: 1px solid rgba(168, 187, 220, 0.3); + padding: 11px 30px; } + @media screen and (min-width: 1224px) { + .service-overview-tab .service-detailed-info .service-tasks { + width: 34%; + margin-right: 14px; } } + @media screen and (max-width: 1024px) { + .service-overview-tab .service-detailed-info .service-tasks { + margin-bottom: 14px; } } + .service-overview-tab .service-detailed-info .service-tasks .service-tasks-list { + height: 260px; + overflow-y: auto; + overflow-x: hidden; } + .service-overview-tab .service-detailed-info .service-tasks .task-list-item { + border-bottom: 1px solid rgba(168, 187, 220, 0.3); } + .service-overview-tab .service-detailed-info .service-tasks .task-list-item .task-item-content { + cursor: pointer; + padding: 14px 30px; } + .service-overview-tab .service-detailed-info .service-tasks .task-list-item .task-time .due { + color: #445a75; } + .service-overview-tab .service-detailed-info .service-tasks .task-list-item .task-message { + overflow: hidden; + text-overflow: ellipsis; + width: 100%; + white-space: nowrap; + margin-top: 4px; } + .service-overview-tab .service-detailed-info .service-tasks .task-list-item:hover { + background: #f6e6cd; } + @media screen and (min-width: 1224px) { + .service-overview-tab .service-detailed-info .service-events { + width: 63.8%; } } + .service-overview-tab .service-detailed-info .service-events .service-events-list { + height: 260px; + overflow-y: auto; + overflow-x: hidden; } + .service-overview-tab .service-detailed-info .service-events .event-list-item { + border-bottom: 1px solid rgba(168, 187, 220, 0.3); } + .service-overview-tab .service-detailed-info .service-events .event-list-item .event-item-icon { + display: table-cell; + width: 28px; + height: 28px; + font-family: FontAwesome; + font-size: 20px; + text-align: center; } + .service-overview-tab .service-detailed-info .service-events .event-list-item .event-item-icon.error { + color: #e65353; } + .service-overview-tab .service-detailed-info .service-events .event-list-item .event-item-icon.error:before { + content: '\f05c'; } + .service-overview-tab .service-detailed-info .service-events .event-list-item .event-item-icon.info { + color: #419ef1; } + .service-overview-tab .service-detailed-info .service-events .event-list-item .event-item-icon.info:before { + content: '\f05a'; } + .service-overview-tab .service-detailed-info .service-events .event-list-item .event-item-icon.warning, .service-overview-tab .service-detailed-info .service-events .event-list-item .event-item-icon.warn { + color: #419ef1; } + .service-overview-tab .service-detailed-info .service-events .event-list-item .event-item-icon.warning:before, .service-overview-tab .service-detailed-info .service-events .event-list-item .event-item-icon.warn:before { + content: '\f071'; } + .service-overview-tab .service-detailed-info .service-events .event-list-item .event-item-content { + padding: 10px 30px; } + .service-overview-tab .service-detailed-info .service-events .event-list-item .event-item-content .event-item-data .event-time { + display: table-cell; + vertical-align: middle; + padding-left: 12px; } + .service-overview-tab .service-detailed-info .service-events .event-list-item .event-item-content .event-message { + overflow: hidden; + text-overflow: ellipsis; + width: 100%; + white-space: nowrap; + margin-top: 4px; + margin-left: 40px; } + .service-overview-tab .service-detailed-info .service-events .event-list-item:hover { + background: #f6e6cd; } + .service-overview-tab .service-detailed-info .service-performance { + margin-top: 20px; + text-align: center; } + .service-overview-tab .service-detailed-info .service-performance .services-performance-header { + padding: 10px; + color: #419ef1; } + .service-overview-tab .service-detailed-info .service-performance .services-performance-header .title { + display: inline-block; } + .service-overview-tab .service-detailed-info .service-performance .services-performance-header .scale-buttons { + display: inline-block; + float: right; + border: 1px solid #a8bbdc; } + .service-overview-tab .service-detailed-info .service-performance .services-performance-header .scale-buttons .scale-button { + min-width: 0; + width: 30px; + margin: 0; + border: none; } + .service-overview-tab .service-detailed-info .service-performance .services-performance-header .scale-buttons .scale-button .ui-button-text { + padding: 2px 5px; } + .service-overview-tab .service-detailed-info .service-performance .services-performance-header .scale-buttons .scale-button.active { + background: #419ef1; } + .service-overview-tab .service-detailed-info .service-performance .vm-chart { + margin: 0 auto; } + .service-overview-tab .service-detailed-info .service-performance svg { + padding: 0; } + +/* Service Events Tab */ +/* Service Parameters */ +.parameters-tab { + margin-left: 30px; } + .parameters-tab .edit-buttons-toolbar { + background: #ecf1f5; + padding: 12px 0; + border-top: 1px solid #445a75; + position: fixed; + bottom: 0; + left: 0; + width: 100%; + z-index: 3; } + .parameters-tab .edit-buttons-toolbar .edit, .parameters-tab .edit-buttons-toolbar .submit, .parameters-tab .edit-buttons-toolbar .discard { + display: inline-block; } + .parameters-tab .edit-buttons-toolbar .edit { + margin-left: 30px; } + .parameters-tab .edit-buttons-toolbar .submit { + position: absolute; + right: 160px; } + .parameters-tab .edit-buttons-toolbar .continue { + position: absolute; + top: 12px; + right: 20px; } + +body.theme2 { + /* Service Parameters */ } + body.theme2 .service-details .activities-button .uxf-button.ui-button.ui-widget.ui-state-default.ui-corner-all.ui-button-text-only { + border: 1px solid rgba(185, 186, 181, 0.7); + color: rgba(185, 186, 181, 0.7); + background-color: transparent; } + body.theme2 .service-details .activities-button .uxf-button.ui-button.ui-widget.ui-state-default.ui-corner-all.ui-button-text-only:hover { + color: #b9bab5; + border: 1px solid #b9bab5; } + body.theme2 .service-overview-tab .service-metrics .service-metric { + background-color: #333; } + body.theme2 .service-overview-tab .service-metrics .service-metric .vnf-icon, body.theme2 .service-overview-tab .service-metrics .service-metric .vm-icon { + color: #8ccdf5; } + body.theme2 .service-overview-tab .service-metrics .service-status .service-status-icon.active i:before { + color: #9bdb69; } + body.theme2 .service-overview-tab .service-metrics .service-status .service-status-icon.new i:before, + body.theme2 .service-overview-tab .service-metrics .service-status .service-status-icon.service-tree-created i:before, + body.theme2 .service-overview-tab .service-metrics .service-status .service-status-icon.service-tree-approved i:before, + body.theme2 .service-overview-tab .service-metrics .service-status .service-status-icon.workflow-created i:before, + body.theme2 .service-overview-tab .service-metrics .service-status .service-status-icon.workflow-started i:before { + color: #8ccdf5; } + body.theme2 .service-overview-tab .service-metrics .service-status .service-status-icon.terminated i:before { + color: #f7e385; } + body.theme2 .service-overview-tab .service-metrics .service-status .service-status-icon.error i:before { + color: #ff7c54; } + body.theme2 .service-overview-tab .service-metrics .service-status .service-details { + border-left: 1px solid #454544; } + body.theme2 .service-overview-tab .service-metrics .service-status .service-details .status { + color: #f4f6f1; } + body.theme2 .service-overview-tab .service-metrics .service-status .service-details .service-times { + color: #b9bab5; } + body.theme2 .service-overview-tab .service-metrics .service-status .service-details .service-times .service-time-value { + color: #f7e385; } + body.theme2 .service-overview-tab .service-detailed-info .service-tasks, body.theme2 .service-overview-tab .service-detailed-info .service-events { + background: #333; } + body.theme2 .service-overview-tab .service-detailed-info .service-tasks .list-header, body.theme2 .service-overview-tab .service-detailed-info .service-events .list-header { + color: #8ccdf5; + border-bottom: 1px solid #454544; } + body.theme2 .service-overview-tab .service-detailed-info .service-tasks .see-all-link, body.theme2 .service-overview-tab .service-detailed-info .service-events .see-all-link { + border-top: 1px solid #454544; } + body.theme2 .service-overview-tab .service-detailed-info .service-tasks .task-list-item { + border-bottom: 1px solid #454544; } + body.theme2 .service-overview-tab .service-detailed-info .service-tasks .task-list-item .task-time .due { + color: #f4f6f1; } + body.theme2 .service-overview-tab .service-detailed-info .service-tasks .task-list-item:hover { + background: #454544; } + body.theme2 .service-overview-tab .service-detailed-info .service-events .event-list-item { + border-bottom: 1px solid #454544; } + body.theme2 .service-overview-tab .service-detailed-info .service-events .event-list-item .event-item-icon.error { + color: #ff7c54; } + body.theme2 .service-overview-tab .service-detailed-info .service-events .event-list-item .event-item-icon.info { + color: #8ccdf5; } + body.theme2 .service-overview-tab .service-detailed-info .service-events .event-list-item .event-item-icon.warning, body.theme2 .service-overview-tab .service-detailed-info .service-events .event-list-item .event-item-icon.warn { + color: #f7e385; } + body.theme2 .service-overview-tab .service-detailed-info .service-events .event-list-item:hover { + background: #454544; } + body.theme2 .service-overview-tab .service-detailed-info .service-performance .services-performance-header { + color: #8ccdf5; } + body.theme2 .service-overview-tab .service-detailed-info .service-performance .services-performance-header .scale-buttons { + border: 1px solid #a8bbdc; } + body.theme2 .service-overview-tab .service-detailed-info .service-performance .services-performance-header .scale-buttons .scale-button.active { + background: #419ef1; } + body.theme2 .service-overview-tab .service-detailed-info .service-performance .highcharts-container .highcharts-background { + fill: #333; } + body.theme2 .service-overview-tab .service-detailed-info .service-performance .highcharts-container tspan { + fill: #f4f6f1; } + body.theme2 .service-overview-tab .service-detailed-info .service-performance .highcharts-container .highcharts-tooltip rect:nth-child(4) { + fill: #232323; } + body.theme2 .parameters-tab .edit-buttons-toolbar { + background: #333; + border-top: 1px solid #333; } + +.modify-service-wizard { + margin-left: -30px; } + .modify-service-wizard .nfv-wizard-header { + background: transparent; + border-bottom: none; } + .modify-service-wizard .impact-view { + padding: 40px; } + .modify-service-wizard .impact-view .impact-view-title { + margin-bottom: 30px; } + .modify-service-wizard .impact-view .impact-list .impact-item { + margin: 20px 0; } + .modify-service-wizard .impact-view .impact-list .impact-item .impact-item-icon { + background: url("../images/images_theme_1/cloud.png") no-repeat; + width: 67px; + height: 42px; + display: table-cell; + vertical-align: middle; } + .modify-service-wizard .impact-view .impact-list .impact-item .impact-item-text { + display: table-cell; + vertical-align: middle; + padding-left: 20px; } + .modify-service-wizard .impact-view .nfv-collapsible-title-text { + width: 20px; } + +.system-tasks .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .serviceTitles .serviceName, .tasks-notifications-container .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .serviceTitles .serviceName, .system-tasks .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .serviceTitles .customer, .tasks-notifications-container .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .serviceTitles .customer, .system-tasks .task-details-container .task-details-header .serviceTitles, .tasks-notifications-container .task-details-container .task-details-header .serviceTitles, .system-tasks .task-details-container .task-details-header .serviceTitles .serviceName, .system-tasks .task-details-container .task-details-header .serviceTitles .customer, .tasks-notifications-container .task-details-container .task-details-header .serviceTitles .serviceName, .tasks-notifications-container .task-details-container .task-details-header .serviceTitles .customer, .system-tasks .task-details-container .task-details-header .dueDateGroup, .tasks-notifications-container .task-details-container .task-details-header .dueDateGroup { + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; } + +.system-tasks .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .contentPreview, .tasks-notifications-container .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .contentPreview, .system-tasks .task-details-container .task-details-header .description, .tasks-notifications-container .task-details-container .task-details-header .description { + display: -webkit-box; + -webkit-line-clamp: 2; + line-height: 1.55; + -webkit-box-orient: vertical; + overflow: hidden; + text-overflow: ellipsis; } + +.system-tasks { + position: absolute; + bottom: 0; + top: 0; + right: 0; + left: 0; } + +.nfv-balloon.reject-balloon .reject-task-balloon { + width: 300px; + height: 220px; } + .nfv-balloon.reject-balloon .reject-task-balloon .reject-title, .nfv-balloon.reject-balloon .reject-task-balloon .buttons-container, .nfv-balloon.reject-balloon .reject-task-balloon .reject-reason { + padding-left: 14px; + padding-right: 14px; } + .nfv-balloon.reject-balloon .reject-task-balloon .reject-title { + padding-top: 10px; + padding-bottom: 10px; } + .nfv-balloon.reject-balloon .reject-task-balloon .buttons-container { + margin-top: 9px; + padding-top: 3px; + display: table; + width: 272px; + height: 40px; + background: #f6e6cd; } + .nfv-balloon.reject-balloon .reject-task-balloon .buttons-container .cancel-reject-btn-holder, .nfv-balloon.reject-balloon .reject-task-balloon .buttons-container .reject-btn-holder { + display: table-cell; + vertical-align: middle; } + .nfv-balloon.reject-balloon .reject-task-balloon .buttons-container .reject-btn-holder { + text-align: right; } + .nfv-balloon.reject-balloon .reject-task-balloon .reject-reason-text { + width: 99%; + height: 118px; } + .nfv-balloon.reject-balloon .reject-task-balloon .reject-reason-text.required { + border: 1px solid #e65353; } + +.system-tasks, .tasks-notifications-container { + color: #1a2531; } + .system-tasks .tasks-list-container, .tasks-notifications-container .tasks-list-container { + height: 100%; + width: 330px; + background: #ffffff; + overflow: hidden; } + .system-tasks .tasks-list-container .filters, .tasks-notifications-container .tasks-list-container .filters { + background-color: #ecf1f5; + height: 63px; + width: 100%; + display: table; + position: relative; + z-index: 5; + border-bottom: 2px solid #a8bbdc; } + .system-tasks .tasks-list-container .filters .select, .tasks-notifications-container .tasks-list-container .filters .select { + display: table-cell; + text-align: left; + vertical-align: middle; + position: relative; + padding-top: 5px; } + .system-tasks .tasks-list-container .filters .select select, .tasks-notifications-container .tasks-list-container .filters .select select { + min-width: 100px; } + .system-tasks .tasks-list-container .filters .tasks-list-footer, .system-tasks .tasks-list-container .filters .tasks-list-popup-footer, .tasks-notifications-container .tasks-list-container .filters .tasks-list-footer, .tasks-notifications-container .tasks-list-container .filters .tasks-list-popup-footer { + display: table-cell; + vertical-align: middle; } + .system-tasks .tasks-list-container .placeholder, .tasks-notifications-container .tasks-list-container .placeholder { + position: absolute; + left: 324px; + height: 110px; + width: 330px; + border-bottom: 1px solid #a8bbdc; + overflow: hidden; } + .system-tasks .tasks-list-container .placeholder .approve-bg, .tasks-notifications-container .tasks-list-container .placeholder .approve-bg { + position: absolute; + top: 0; + left: 0; + right: 0; + bottom: 0; + background-color: #3ebd6b; + opacity: 0.1; } + .system-tasks .tasks-list-container .placeholder .reject-bg, .tasks-notifications-container .tasks-list-container .placeholder .reject-bg { + position: absolute; + top: 0; + left: 0; + right: 0; + bottom: 0; + background-color: #e65353; + opacity: 0.1; } + .system-tasks .tasks-list-container .placeholder .replan-bg, .tasks-notifications-container .tasks-list-container .placeholder .replan-bg { + position: absolute; + top: 0; + left: 0; + right: 0; + bottom: 0; + background-color: #ff8a00; + opacity: 0.1; } + .system-tasks .tasks-list-container .placeholder .text, .tasks-notifications-container .tasks-list-container .placeholder .text { + position: absolute; + top: 44px; + left: 137px; + opacity: 1; } + .system-tasks .tasks-list-container .tasks-collection-container, .tasks-notifications-container .tasks-list-container .tasks-collection-container { + overflow-y: auto; + overflow-x: hidden; + width: 330px; + position: absolute; } + .system-tasks .tasks-list-container .tasks-collection-container.popup, .tasks-notifications-container .tasks-list-container .tasks-collection-container.popup { + top: 0px; + bottom: 0px; } + .system-tasks .tasks-list-container .tasks-collection-container.full-mode, .tasks-notifications-container .tasks-list-container .tasks-collection-container.full-mode { + top: 63px; + bottom: 0px; } + .system-tasks .tasks-list-container .tasks-collection-container.full-mode .task-list-item.active, .tasks-notifications-container .tasks-list-container .tasks-collection-container.full-mode .task-list-item.active { + background-color: #ecf1f5; + border-left: 5px solid #419ef1; + padding-left: 25px; } + .system-tasks .tasks-list-container .tasks-collection-container.full-mode .task-list-item.active .serviceParams, .tasks-notifications-container .tasks-list-container .tasks-collection-container.full-mode .task-list-item.active .serviceParams { + left: 165px; } + .system-tasks .tasks-list-container .tasks-collection-container .uxf-itemlist, .tasks-notifications-container .tasks-list-container .tasks-collection-container .uxf-itemlist { + list-style-type: none; + padding: 0px; + margin: 0px; } + .system-tasks .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item, .tasks-notifications-container .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item { + cursor: pointer; + position: relative; + top: 0; + height: 98px; + width: 300px; + padding-left: 30px; + padding-top: 12px; + background-color: #ffffff; + border-bottom: 1px solid #a8bbdc; } + .system-tasks .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item:hover, .tasks-notifications-container .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item:hover { + background-color: #ecf1f5; } + .system-tasks .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .serviceTitles, .tasks-notifications-container .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .serviceTitles { + width: 130px; } + .system-tasks .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .serviceTitles .customer, .tasks-notifications-container .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .serviceTitles .customer { + margin-top: 2px; } + .system-tasks .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .serviceTitles .customer::before, .tasks-notifications-container .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .serviceTitles .customer::before { + content: "("; } + .system-tasks .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .serviceTitles .customer::after, .tasks-notifications-container .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .serviceTitles .customer::after { + content: ")"; } + .system-tasks .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .contentPreview, .tasks-notifications-container .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .contentPreview { + word-spacing: 2px; + margin-top: 8px; + height: 37px; + width: 280px; } + .system-tasks .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .contentPreview .message, .tasks-notifications-container .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .contentPreview .message { + color: #445a75; + white-space: nowrap; + text-overflow: ellipsis; + overflow: hidden; } + .system-tasks .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .contentPreview .action-taken.action-taken-approve .value, .tasks-notifications-container .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .contentPreview .action-taken.action-taken-approve .value { + color: #3ebd6b; } + .system-tasks .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .contentPreview .action-taken.action-taken-cancel .value, .tasks-notifications-container .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .contentPreview .action-taken.action-taken-cancel .value { + color: #e65353; } + .system-tasks .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .serviceParams, .tasks-notifications-container .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .serviceParams { + position: absolute; + top: 12px; + left: 170px; } + .system-tasks .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .serviceParams .Default, .tasks-notifications-container .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .serviceParams .Default { + height: 18px; + line-height: 18px; } + .system-tasks .task-details-container, .tasks-notifications-container .task-details-container { + height: 100%; + background: #ffffff; + position: absolute; + top: 0px; + left: 330px; + right: 0; + border-left: 2px solid #a8bbdc; + overflow: hidden; } + .system-tasks .task-details-container .empty, .tasks-notifications-container .task-details-container .empty { + display: table; + position: absolute; + background: #ffffff; + width: 100%; + z-index: 100; + height: 100%; } + .system-tasks .task-details-container .empty span, .tasks-notifications-container .task-details-container .empty span { + display: table-cell; + text-align: center; + vertical-align: middle; } + .system-tasks .task-details-container .task-details-header, .tasks-notifications-container .task-details-container .task-details-header { + overflow: hidden; + position: absolute; + right: 0; + left: 0; + height: 61px; + background-color: #ecf1f5; + padding-left: 15px; } + .system-tasks .task-details-container .task-details-header .serviceTitles, .tasks-notifications-container .task-details-container .task-details-header .serviceTitles { + display: inline-block; + height: 47px; + padding-top: 11px; + padding-right: 10px; + border-right: 1px solid #a8bbdc; + width: 170px; } + .system-tasks .task-details-container .task-details-header .serviceTitles .customer::before, .tasks-notifications-container .task-details-container .task-details-header .serviceTitles .customer::before { + content: "("; } + .system-tasks .task-details-container .task-details-header .serviceTitles .customer::after, .tasks-notifications-container .task-details-container .task-details-header .serviceTitles .customer::after { + content: ")"; } + .system-tasks .task-details-container .task-details-header .serviceTitles .customer:empty, .tasks-notifications-container .task-details-container .task-details-header .serviceTitles .customer:empty { + display: none; } + .system-tasks .task-details-container .task-details-header .dueDateGroup, .tasks-notifications-container .task-details-container .task-details-header .dueDateGroup { + display: inline-block; + height: 47px; + padding: 11px 10px 0 10px; + border-right: 1px solid #a8bbdc; + width: 110px; } + .system-tasks .task-details-container .task-details-header .description, .tasks-notifications-container .task-details-container .task-details-header .description { + height: 40px; + padding: 11px 10px 10px 10px; + position: absolute; + top: 0; + left: 330px; + right: 300px; + border-right: 1px solid #a8bbdc; } + .system-tasks .task-details-container .buttons-container, .tasks-notifications-container .task-details-container .buttons-container { + float: right; + margin: 10px 30px 10px 0; } + .system-tasks .task-details-container .buttons-container .approve-btn, .system-tasks .task-details-container .buttons-container .reject-btn, .system-tasks .task-details-container .buttons-container .replan-btn, .tasks-notifications-container .task-details-container .buttons-container .approve-btn, .tasks-notifications-container .task-details-container .buttons-container .reject-btn, .tasks-notifications-container .task-details-container .buttons-container .replan-btn { + border: none; } + .system-tasks .task-details-container .buttons-container .approve-btn:before, .tasks-notifications-container .task-details-container .buttons-container .approve-btn:before { + font-family: FontAwesome; + content: "\f00c"; + color: #3ebd6b; } + .system-tasks .task-details-container .buttons-container .reject-btn:before, .tasks-notifications-container .task-details-container .buttons-container .reject-btn:before { + font-family: FontAwesome; + content: "\f00d"; + color: #e65353; } + .system-tasks .task-details-container .buttons-container .replan-btn:before, .tasks-notifications-container .task-details-container .buttons-container .replan-btn:before { + font-family: FontAwesome; + content: "\f021"; } + .system-tasks .task-details-container .task-details-tabs-container, .tasks-notifications-container .task-details-container .task-details-tabs-container { + position: absolute; + top: 61px; + bottom: 0px; + left: 0; + right: 0; } + .system-tasks .task-details-container .task-details-tabs-container .tree-graph, .tasks-notifications-container .task-details-container .task-details-tabs-container .tree-graph { + height: 667px; } + .system-tasks .task-details-container .task-details-tabs-container .tree-graph svg, .tasks-notifications-container .task-details-container .task-details-tabs-container .tree-graph svg { + border: none; } + .system-tasks .task-details-container .task-details-tabs-container .nfv-tabpanel, .tasks-notifications-container .task-details-container .task-details-tabs-container .nfv-tabpanel { + position: absolute; + top: 0px; + bottom: 0px; + left: 0px; + right: 0px; } + .system-tasks .task-details-container .task-details-tabs-container .nfv-tabpanel .nfv-tabs-v3, .tasks-notifications-container .task-details-container .task-details-tabs-container .nfv-tabpanel .nfv-tabs-v3 { + padding: 0; } + .system-tasks .task-details-container .task-details-tabs-container .nfv-tabpanel #tabs-parameters-tab, .tasks-notifications-container .task-details-container .task-details-tabs-container .nfv-tabpanel #tabs-parameters-tab { + position: absolute; + top: 42px; + left: 0px; + right: 0px; + bottom: 0px; + overflow-y: auto; } + +body.theme2 .nfv-balloon.reject-balloon { + border-color: #333; + background-color: #454544; } + body.theme2 .nfv-balloon.reject-balloon .reject-task-balloon .reject-title { + color: #f4f6f1; } + body.theme2 .nfv-balloon.reject-balloon .reject-task-balloon .buttons-container { + background: #333; } + body.theme2 .nfv-balloon.reject-balloon .reject-task-balloon .buttons-container .reject-btn-holder a { + color: #f4f6f1; + border-color: #f4f6f1; } + body.theme2 .nfv-balloon.reject-balloon .reject-task-balloon .buttons-container .reject-btn-holder a:hover { + border-color: #ff7c54; + color: #ff7c54; } + body.theme2 .nfv-balloon.reject-balloon .reject-task-balloon .reject-reason-text { + background-color: inherit; + border-color: inherit; + color: #f4f6f1; } + body.theme2 .nfv-balloon.reject-balloon .reject-task-balloon .reject-reason-text.required { + border: 1px solid #f7e385; } + +body.theme2 .system-tasks, body.theme2 .tasks-notifications-container { + color: #b9bab5; } + body.theme2 .system-tasks .tasks-list-container, body.theme2 .tasks-notifications-container .tasks-list-container { + background: #232323; } + body.theme2 .system-tasks .tasks-list-container .filters, body.theme2 .tasks-notifications-container .tasks-list-container .filters { + background-color: #232323; + border-bottom: 2px solid #454544; } + body.theme2 .system-tasks .tasks-list-container .placeholder, body.theme2 .tasks-notifications-container .tasks-list-container .placeholder { + border-bottom: 1px solid #454544; } + body.theme2 .system-tasks .tasks-list-container .placeholder .approve-bg, body.theme2 .tasks-notifications-container .tasks-list-container .placeholder .approve-bg { + background-color: #9bdb69; } + body.theme2 .system-tasks .tasks-list-container .placeholder .reject-bg, body.theme2 .tasks-notifications-container .tasks-list-container .placeholder .reject-bg { + background-color: #f7e385; } + body.theme2 .system-tasks .tasks-list-container .placeholder .replan-bg, body.theme2 .tasks-notifications-container .tasks-list-container .placeholder .replan-bg { + background-color: #8ccdf5; } + body.theme2 .system-tasks .tasks-list-container .tasks-collection-container.full-mode .task-list-item.active, body.theme2 .tasks-notifications-container .tasks-list-container .tasks-collection-container.full-mode .task-list-item.active { + background-color: #333; + border-left: 5px solid #f4f6f1; } + body.theme2 .system-tasks .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item, body.theme2 .tasks-notifications-container .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item { + background-color: #232323; + border-bottom: 1px solid #454544; } + body.theme2 .system-tasks .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .serviceTitles .serviceName, body.theme2 .tasks-notifications-container .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .serviceTitles .serviceName { + color: #8ccdf5; } + body.theme2 .system-tasks .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .serviceTitles .customer, body.theme2 .tasks-notifications-container .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .serviceTitles .customer { + color: #aaa6d9; } + body.theme2 .system-tasks .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item:hover, body.theme2 .tasks-notifications-container .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item:hover { + background-color: #333; } + body.theme2 .system-tasks .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .contentPreview .message, body.theme2 .tasks-notifications-container .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .contentPreview .message { + color: #b9bab5; } + body.theme2 .system-tasks .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .contentPreview .action-taken.action-taken-approve .value, body.theme2 .tasks-notifications-container .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .contentPreview .action-taken.action-taken-approve .value { + color: #9bdb69; } + body.theme2 .system-tasks .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .contentPreview .action-taken.action-taken-cancel .value, body.theme2 .tasks-notifications-container .tasks-list-container .tasks-collection-container .uxf-itemlist .task-list-item .contentPreview .action-taken.action-taken-cancel .value { + color: #f7e385; } + body.theme2 .system-tasks .task-details-container, body.theme2 .tasks-notifications-container .task-details-container { + background: #333; + border-left: 2px solid #454544; } + body.theme2 .system-tasks .task-details-container .empty, body.theme2 .tasks-notifications-container .task-details-container .empty { + background: #333; } + body.theme2 .system-tasks .task-details-container .task-details-header, body.theme2 .tasks-notifications-container .task-details-container .task-details-header { + background-color: #292929; + border-bottom: 2px solid #454544; } + body.theme2 .system-tasks .task-details-container .task-details-header .serviceTitles, body.theme2 .tasks-notifications-container .task-details-container .task-details-header .serviceTitles { + border-right: 1px solid #454544; } + body.theme2 .system-tasks .task-details-container .task-details-header .serviceTitles .serviceName, body.theme2 .tasks-notifications-container .task-details-container .task-details-header .serviceTitles .serviceName { + color: #8ccdf5; } + body.theme2 .system-tasks .task-details-container .task-details-header .serviceTitles .customer, body.theme2 .tasks-notifications-container .task-details-container .task-details-header .serviceTitles .customer { + color: #aaa6d9; } + body.theme2 .system-tasks .task-details-container .task-details-header .dueDateGroup, body.theme2 .tasks-notifications-container .task-details-container .task-details-header .dueDateGroup { + border-right: 1px solid #454544; } + body.theme2 .system-tasks .task-details-container .task-details-header .description, body.theme2 .tasks-notifications-container .task-details-container .task-details-header .description { + border-color: #454544; } + body.theme2 .system-tasks .approve-btn:before, body.theme2 .tasks-notifications-container .approve-btn:before { + color: #9bdb69; } + body.theme2 .system-tasks .reject-btn:before, body.theme2 .tasks-notifications-container .reject-btn:before { + color: #ff7c54; } + body.theme2 .system-tasks .replan-btn:before, body.theme2 .tasks-notifications-container .replan-btn:before { + color: #8ccdf5; } + +[data-uxf-point="settings-cp-add"] { + background-color: #ecf1f5; + left: 30px; + padding-left: 30px; + position: absolute; + top: 270px; + width: 190px; } + [data-uxf-point="settings-cp-add"] button.ui-state-default.ui-button { + border: none; + position: relative; + text-align: left; + width: 150px; } + [data-uxf-point="settings-cp-add"] button.ui-state-default.ui-button:before { + font-family: FontAwesome; + content: '\f067'; + position: absolute; + left: 0px; + top: 8px; + font-size: 10px; } + [data-uxf-point="settings-cp-add"] button.ui-state-default.ui-button:hover { + border: none; } + +.settings[data-uxf-point="settings-view"] { + background-color: #e1e8f1; + height: 100%; + /* DataTables modifications */ } + .settings[data-uxf-point="settings-view"] .image-controllers { + background-color: #ecf1f5; + margin: 30px 30px 0px 0px; + text-align: right; + padding: 3px 10px 2px 0; + border-bottom: 1px solid rgba(168, 187, 220, 0.3); } + .settings[data-uxf-point="settings-view"] .image-controllers .controller { + margin-left: 20px; + cursor: pointer; + transition: color 0.4s; } + .settings[data-uxf-point="settings-view"] .image-controllers .controller:hover { + color: #419ef1; } + .settings[data-uxf-point="settings-view"] .image-controllers .controller .fa { + margin-right: 5px; } + .settings[data-uxf-point="settings-view"] .nfv-tabpanel .nfv-tabs-v3 { + background-color: #ecf1f5; + border: none; + left: 30px; + position: absolute; + top: 30px; + width: 220px; } + .settings[data-uxf-point="settings-view"] .nfv-tabpanel .nfv-tabs-v3:after { + background-color: #ecf1f5; + content: ''; + height: 40px; + position: absolute; + right: -30px; + top: 0px; + width: 30px; } + .settings[data-uxf-point="settings-view"] .nfv-tabpanel .nfv-tabs-v3 .ui-state-disabled, + .settings[data-uxf-point="settings-view"] .nfv-tabpanel .nfv-tabs-v3 .ui-widget-content .ui-state-disabled, + .settings[data-uxf-point="settings-view"] .nfv-tabpanel .nfv-tabs-v3 .ui-widget-header .ui-state-disabled { + opacity: 1; } + .settings[data-uxf-point="settings-view"] .nfv-tabpanel .nfv-tabs-v3 li.ui-state-default { + border: none !important; + float: none; + line-height: 27px; } + .settings[data-uxf-point="settings-view"] .nfv-tabpanel .nfv-tabs-v3 li.ui-state-default.ui-tabs-active.ui-state-active { + color: #ff8a00; } + .settings[data-uxf-point="settings-view"] .nfv-tabpanel .nfv-tabs-v3 li.ui-state-default a.ui-tabs-anchor { + background-color: #ffffff; + display: block; + float: none; + margin: 5px 20px; + text-align: left; } + .settings[data-uxf-point="settings-view"] .nfv-tabpanel .nfv-tabs-v3 li.ui-state-default a.ui-tabs-anchor:hover { + text-decoration: underline; } + .settings[data-uxf-point="settings-view"] .nfv-tabpanel .nfv-tabs-v3 li.ui-state-default:nth-child(2) a.ui-tabs-anchor, + .settings[data-uxf-point="settings-view"] .nfv-tabpanel .nfv-tabs-v3 li.ui-state-default:nth-child(3) a.ui-tabs-anchor, + .settings[data-uxf-point="settings-view"] .nfv-tabpanel .nfv-tabs-v3 li.ui-state-default:nth-child(4) a.ui-tabs-anchor { + background-color: #ecf1f5; + margin: 0px 0px 0px 30px; } + .settings[data-uxf-point="settings-view"] .nfv-tabpanel .ui-tabs-panel { + border: none; + left: 280px; + position: absolute; + right: 10px; + background: transparent; } + .settings[data-uxf-point="settings-view"] #tabs-images .data-table-wrapper div.dataTables_wrapper { + top: 0px; } + .settings[data-uxf-point="settings-view"] .data-table-wrapper div.dataTables_wrapper { + left: 0px; } + .settings[data-uxf-point="settings-view"] .data-table-wrapper .dataTables_scroll { + background-color: #ecf1f5; } + .settings[data-uxf-point="settings-view"] .data-table-wrapper table.dataTable.table-bordered { + border: none; } + .settings[data-uxf-point="settings-view"] .data-table-wrapper table.dataTable > tbody > tr > td, + .settings[data-uxf-point="settings-view"] .data-table-wrapper table.dataTable > thead > tr > th { + border: none; } + .settings[data-uxf-point="settings-view"] .data-table-wrapper table.dataTable > tbody > tr > td:nth-last-child(1) { + color: #ff7c54; } + .settings[data-uxf-point="settings-view"] .data-table-wrapper table.dataTable > tbody > tr > td:nth-last-child(2) { + border-left: solid 1px #a8bbdc; + color: #8ccdf5; } + .settings[data-uxf-point="settings-view"] .data-table-wrapper table.dataTable > tbody > tr > td:nth-last-child(-n+2) { + font-size: 20px; + text-align: center; + width: 20px; } + .settings[data-uxf-point="settings-view"] .data-table-wrapper table.dataTable > thead > tr > th { + border-bottom: solid 1px #a8bbdc; } + .settings[data-uxf-point="settings-view"] .data-table-wrapper table.dataTable > thead > tr > th:hover { + background-color: transparent; } + +.add-setting-popup-module .form-container { + border-left: solid 3px #419ef1; + margin-bottom: 20px; + padding-left: 20px; } + .add-setting-popup-module .form-container + .nfv-primary-button { + float: right; } + .add-setting-popup-module .form-container .form-element { + margin-bottom: 15px; } + .add-setting-popup-module .form-container .form-element .form-element--label { + display: inline-block; + width: 200px; } + .add-setting-popup-module .form-container .form-element select { + padding-right: 10px; } + .add-setting-popup-module .form-container .form-element .form-element--control { + width: 290px; + box-sizing: content-box; + display: block; } + .add-setting-popup-module .form-container .form-element .form-element--error-message { + margin-left: 0px; } + +body.theme2 [data-uxf-point="settings-cp-add"] { + background-color: #333; } + +body.theme2 .settings[data-uxf-point="settings-view"] { + background-color: #232323; + /* DataTables modifications */ } + body.theme2 .settings[data-uxf-point="settings-view"] .image-controllers { + background-color: #333; + border-bottom: 1px solid #454544; } + body.theme2 .settings[data-uxf-point="settings-view"] .image-controllers .controller:hover { + color: #9bdb69; } + body.theme2 .settings[data-uxf-point="settings-view"] .nfv-tabpanel .nfv-tabs-v3 { + background-color: #333; } + body.theme2 .settings[data-uxf-point="settings-view"] .nfv-tabpanel .nfv-tabs-v3:after { + background-color: #333; } + body.theme2 .settings[data-uxf-point="settings-view"] .nfv-tabpanel .nfv-tabs-v3 li.ui-state-default { + border: none !important; } + body.theme2 .settings[data-uxf-point="settings-view"] .nfv-tabpanel .nfv-tabs-v3 li.ui-state-default.ui-tabs-active.ui-state-active a.ui-tabs-anchor { + color: #9bdb69; } + body.theme2 .settings[data-uxf-point="settings-view"] .nfv-tabpanel .nfv-tabs-v3 li.ui-state-default a.ui-tabs-anchor { + background-color: #232323; } + body.theme2 .settings[data-uxf-point="settings-view"] .nfv-tabpanel .nfv-tabs-v3 li.ui-state-default:nth-child(2) a.ui-tabs-anchor, + body.theme2 .settings[data-uxf-point="settings-view"] .nfv-tabpanel .nfv-tabs-v3 li.ui-state-default:nth-child(3) a.ui-tabs-anchor, + body.theme2 .settings[data-uxf-point="settings-view"] .nfv-tabpanel .nfv-tabs-v3 li.ui-state-default:nth-child(4) a.ui-tabs-anchor { + background-color: #333; } + body.theme2 .settings[data-uxf-point="settings-view"] > tbody > tr > td:nth-last-child(2) { + border-left: solid 1px #2f2f2f; } + body.theme2 .settings[data-uxf-point="settings-view"] > thead > tr > th { + border-bottom: solid 1px #2f2f2f; + color: #aaa6d9; } + body.theme2 .settings[data-uxf-point="settings-view"] > thead > tr > th:hover { + background-color: transparent; } + body.theme2 .settings[data-uxf-point="settings-view"] .data-table-wrapper .dataTables_scroll { + background-color: #333; } + body.theme2 .settings[data-uxf-point="settings-view"] .data-table-wrapper table.dataTable > tbody > tr > td:nth-last-child(1) { + color: #ff7c54; } + body.theme2 .settings[data-uxf-point="settings-view"] .data-table-wrapper table.dataTable > tbody > tr > td:nth-last-child(2) { + border-left: solid 1px #2f2f2f; + color: #8ccdf5; } + body.theme2 .settings[data-uxf-point="settings-view"] .data-table-wrapper table.dataTable > thead > tr > th { + border-bottom: solid 1px #2f2f2f; + color: #aaa6d9; } + +body.theme2 .add-setting-popup-module .form-container { + border-left: solid 3px #454544; } + +.service-termination-view .service-termination-subtitle { + margin: 30px 0; } + +.service-termination-view .uxf-input select { + min-width: 200px; } + +.service-termination-view .service-termination-controllers { + margin-top: 30px; } + +.service-termination-view .nfv-button-link { + display: inline-block; + float: left; } + +.service-termination-view .nfv-primary-button { + display: inline-block; + float: right; } + +.confirmation-popup-view .confirmation-popup-subtitle { + margin-bottom: 30px; + padding-left: 42px; + padding-top: 15px; + height: 35px; } + .confirmation-popup-view .confirmation-popup-subtitle:before { + content: "\f071"; + margin-right: 12px; + font-family: FontAwesome; + font-size: 18px; } + +.confirmation-popup-view .confirmation-popup-message { + background: #fcf3d4; + display: inline-block; } + +.confirmation-popup-view .confirmation-popup-controllers { + margin-top: 10px; } + .confirmation-popup-view .confirmation-popup-controllers .confirmation-popup-button { + display: inline-block; } + .confirmation-popup-view .confirmation-popup-controllers .confirmation-popup-button.nfv-primary-button { + float: right; } + +.nfv-anonymous-landing-page .nfv-content { + min-height: 595px; } + +.nfv-landing-page .landing-page-content { + height: 100%; + position: relative; + transition: background-color 0.4s, color 0.4s; } + +.nfv-landing-page .landing-page-view { + bottom: 0px; + left: 0px; + position: absolute; + right: 0px; + top: 0px; } + .nfv-landing-page .landing-page-view h2 { + box-sizing: border-box; + color: #253244; + float: left; + padding: 16px 20px; + position: relative; + width: 27%; + transition: color 0.2s; } + .nfv-landing-page .landing-page-view h2:nth-child(2) { + border-left: solid 2px #a8bbdc; + width: 73%; } + .nfv-landing-page .landing-page-view h2 [data-uxf-point="add-service-button"] { + color: #ff7c54; + font-size: 18px; + position: absolute; + right: 75px; + top: 50%; + transform: translateY(-50%); } + .nfv-landing-page .landing-page-view h2 [data-uxf-point="add-service-button"] button { + border: none; + min-width: initial; + position: absolute; + right: -3px; + width: 18px; } + .nfv-landing-page .landing-page-view h2 .see-all-link { + position: absolute; + right: 10px; + top: 40%; + transform: translateY(-50%); } + .nfv-landing-page .landing-page-view .search-filter-input { + position: fixed; + left: 420px; + top: 22px; } + .nfv-landing-page .landing-page-view .search-filter-input i.fa { + cursor: pointer; } + .nfv-landing-page .landing-page-view .search-filter-input input[type="search"] { + color: #1a2531; + border-bottom-color: #1a2531; + opacity: 0; + transition: width 0.4s, opacity 0.4s; + width: 20px; } + .nfv-landing-page .landing-page-view .search-filter-input input[type="search"]:focus { + width: 150px; + opacity: 1; } + .nfv-landing-page .landing-page-view .lists-box { + bottom: 0px; + left: 0px; + position: absolute; + right: 3px; + top: 0px; } + .nfv-landing-page .landing-page-view .lists-box .events { + border-left: solid 2px #a8bbdc; + left: 27%; + width: 73%; } + .nfv-landing-page .landing-page-view .lists-box .events ul > li { + display: table-row; + padding: 10px 20px; + transition: background-color 0.2s; + background-color: #ffffff; } + .nfv-landing-page .landing-page-view .lists-box .events ul > li:nth-child(even) { + background-color: #ecf1f5; } + .nfv-landing-page .landing-page-view .lists-box .events ul > li > * { + display: table-cell; + padding: 10px; } + .nfv-landing-page .landing-page-view .lists-box .events ul > li .status { + display: block; + font-size: 15px; + position: absolute; + right: 15px; + top: 20px; } + .nfv-landing-page .landing-page-view .lists-box .events ul > li .status.error { + color: #ff7c54; } + .nfv-landing-page .landing-page-view .lists-box .events ul > li .status.suspend { + color: #f7e385; } + .nfv-landing-page .landing-page-view .lists-box .events ul > li .event-message p { + position: relative; + display: block; + overflow: hidden; + height: 2.4em; + /* exactly two lines */ + line-height: 1.4; + margin: 0; + -webkit-box-orient: vertical; + display: -webkit-box; + -webkit-line-clamp: 2; } + .nfv-landing-page .landing-page-view .lists-box .events ul > li .event-message p:after { + /* fade out last line until multiline ellipsis (clamp) browsers' support */ + content: ""; + text-align: right; + position: absolute; + bottom: 0; + right: 0; + width: 40%; + height: 1.2em; + background: linear-gradient(to right, rgba(255, 255, 255, 0), #ffffff 80%); } + .nfv-landing-page .landing-page-view .lists-box .events ul > li:nth-child(even) .event-message p:after { + background: linear-gradient(to right, rgba(236, 241, 245, 0), #ecf1f5 80%); } + .nfv-landing-page .landing-page-view .lists-box .events ul > li time { + color: #253244; + text-align: center; + width: 80px; } + .nfv-landing-page .landing-page-view .lists-box .events ul > li .machine-id { + text-align: center; } + .nfv-landing-page .landing-page-view .lists-box .events ul > li .task-icon, .nfv-landing-page .landing-page-view .lists-box .events ul > li .type { + position: relative; } + .nfv-landing-page .landing-page-view .lists-box .events ul > li .task-icon:before, .nfv-landing-page .landing-page-view .lists-box .events ul > li .type:before { + position: absolute; + top: 50%; + transform: translateY(-50%); } + .nfv-landing-page .landing-page-view .lists-box .events ul > li .task-icon { + color: #8ccdf5; + cursor: pointer; + font-size: 17px; + height: 30px; + width: 10px; } + .nfv-landing-page .landing-page-view .lists-box .events ul > li .task-icon.empty { + background: none; + cursor: default; } + .nfv-landing-page .landing-page-view .lists-box .events ul > li .task-icon.empty:before { + content: ''; } + .nfv-landing-page .landing-page-view .lists-box .events ul > li .type { + width: 20px; } + .nfv-landing-page .landing-page-view .lists-box .events ul > li .type:before { + transform: translateY(-45%); } + .nfv-landing-page .landing-page-view .lists-box .list { + border-top: solid 1px rgba(168, 187, 220, 0.3); + bottom: 20px; + overflow-y: scroll; + position: absolute; + top: 65px; + transition: border 0.2s; } + .nfv-landing-page .landing-page-view .lists-box .list::after, .nfv-landing-page .landing-page-view .lists-box .list::before { + background: rgba(0, 0, 0, 0.6); + bottom: inherit; + content: ''; + height: 50px; + opacity: 0; + position: fixed; + transform: scale(1, 0.5); + transform-origin: bottom; + transition: opacity 0.2s, transform 0.2s; + width: inherit; + z-index: 1; } + .nfv-landing-page .landing-page-view .lists-box .list::after { + -moz-animation: loader-spin 5s infinite linear; + -ms-animation: loader-spin 5s infinite linear; + -webkit-animation: loader-spin 5s infinite linear; + background-color: transparent; + color: white; + content: '\21bb'; + font-size: 40px; + text-align: center; + transform-origin: center; + z-index: 2; } + .nfv-landing-page .landing-page-view .lists-box .list.loader-on::after, .nfv-landing-page .landing-page-view .lists-box .list.loader-on::before { + opacity: 1; + transform: scale(1, 1); } + .nfv-landing-page .landing-page-view .lists-box .services { + width: 27%; } + .nfv-landing-page .landing-page-view .lists-box .services ul > li { + border-left: 5px solid transparent; + border-bottom: solid 1px rgba(168, 187, 220, 0.3); + cursor: pointer; + padding: 10px; + position: relative; + transition: border 0.2s; } + .nfv-landing-page .landing-page-view .lists-box .services ul > li > h3 { + color: #253244; + transition: color 0.2s; } + .nfv-landing-page .landing-page-view .lists-box .services ul > li > label { + color: #1a2531; } + .nfv-landing-page .landing-page-view .lists-box .services ul > li > time { + display: block; + margin-top: 10px; + transition: color 0.2s; } + .nfv-landing-page .landing-page-view .lists-box .services ul > li .machine-id { + color: #f4f6f1; } + .nfv-landing-page .landing-page-view .lists-box .services ul > li > .status { + display: block; + font-size: 17px; + position: absolute; + right: 17px; + top: 15px; } + .nfv-landing-page .landing-page-view .lists-box .services ul > li > .status.active { + color: #9bdb69; } + .nfv-landing-page .landing-page-view .lists-box .services ul > li > .status.error { + color: #e65353; } + .nfv-landing-page .landing-page-view .lists-box .services ul > li > .status.new, .nfv-landing-page .landing-page-view .lists-box .services ul > li > .status.service-tree-created, .nfv-landing-page .landing-page-view .lists-box .services ul > li > .status.service-tree-approved { + color: #344358; } + .nfv-landing-page .landing-page-view .lists-box .services ul > li > .status.workflow-created, .nfv-landing-page .landing-page-view .lists-box .services ul > li > .status.workflow-started { + color: #419ef1; } + .nfv-landing-page .landing-page-view .lists-box .services ul > li > .status.suspended { + color: #419ef1; } + .nfv-landing-page .landing-page-view .lists-box .services ul > li > .status.terminated { + color: #a8bbdc; } + +body.theme2 .landing-page-view h2 { + color: #8ccdf5; } + body.theme2 .landing-page-view h2:nth-child(2) { + border-left: solid 2px #454544; } + body.theme2 .landing-page-view h2 .see-all-link span { + color: #f4f6f1; } + +body.theme2 .landing-page-view .search-filter-input input[type="search"] { + color: #b9bab5; + border-bottom-color: #454544; } + +body.theme2 .landing-page-view .lists-box .events { + border-left: solid 3px #454544; } + body.theme2 .landing-page-view .lists-box .events ul > li { + background-color: #232323; } + body.theme2 .landing-page-view .lists-box .events ul > li:nth-child(even) { + background-color: #292929; } + body.theme2 .landing-page-view .lists-box .events ul > li time { + color: #aaa6d9; } + body.theme2 .landing-page-view .lists-box .events ul > li .machine-id { + color: #f4f6f1; } + body.theme2 .landing-page-view .lists-box .events ul > li .event-message p:after { + background: linear-gradient(to right, rgba(35, 35, 35, 0), #232323 80%); } + body.theme2 .landing-page-view .lists-box .events ul > li:nth-child(even) .event-message p:after { + background: linear-gradient(to right, rgba(41, 41, 41, 0), #292929 80%); } + +body.theme2 .landing-page-view .lists-box .list { + border-top: solid 1px #454544; } + +body.theme2 .landing-page-view .lists-box .services ul > li { + border-bottom: solid 1px #454544; } + body.theme2 .landing-page-view .lists-box .services ul > li > label { + color: #f4f6f1; } + body.theme2 .landing-page-view .lists-box .services ul > li h3 { + color: #8ccdf5; } + body.theme2 .landing-page-view .lists-box .services ul > li > .status.active { + color: #9bdb69; } + body.theme2 .landing-page-view .lists-box .services ul > li > .status.error { + color: #ff7c54; } + body.theme2 .landing-page-view .lists-box .services ul > li > .status.new, body.theme2 .landing-page-view .lists-box .services ul > li > .status.service-tree-created, body.theme2 .landing-page-view .lists-box .services ul > li > .status.service-tree-approved { + color: #aaa6d9; } + body.theme2 .landing-page-view .lists-box .services ul > li > .status.workflow-created, body.theme2 .landing-page-view .lists-box .services ul > li > .status.workflow-started { + color: #8ccdf5; } + body.theme2 .landing-page-view .lists-box .services ul > li > .status.suspended { + color: #aaa6d9; } + body.theme2 .landing-page-view .lists-box .services ul > li > .status.terminated { + color: #b9bab5; } + +@-moz-keyframes loader-spin { + from { + transform: rotate(0deg); } + to { + transform: rotate(3600deg); } } + +@-ms-keyframes loader-spin { + from { + transform: rotate(0deg); } + to { + transform: rotate(3600deg); } } + +@-webkit-keyframes loader-spin { + from { + transform: rotate(0deg); } + to { + transform: rotate(3600deg); } } + +.graph-simulator-page h1, .graph-simulator-page h2, .graph-simulator-page h3, .graph-simulator-page h4 { + margin: 10px; } + +.graph-simulator-page .simulator-content { + padding-top: 20px; + padding-left: 20px; } + +.graph-simulator-page .input-label-first-fieldset { + min-width: 150px; } + +.graph-simulator-page .input-label-second-fieldset { + min-width: 150px; } + +.graph-simulator-page .first-fieldset, .graph-simulator-page .second-fieldset { + display: inline-block; + vertical-align: top; } + +.graph-simulator-page .warning { + color: red; } + +.graph-simulator-page .nfv-checkbox-button { + margin: 13px; } + +.graph-simulator-page .nfv-primary-button { + margin-bottom: 13px; } + +/*# sourceMappingURL=style.css.map */ \ No newline at end of file diff --git a/openecomp-be/tools/swagger-ui/css/print.css b/openecomp-be/tools/swagger-ui/css/print.css new file mode 100644 index 0000000000..c90e9f568e --- /dev/null +++ b/openecomp-be/tools/swagger-ui/css/print.css @@ -0,0 +1,1175 @@ +/* Original style from softwaremaniacs.org (c) Ivan Sagalaev */ +.swagger-section pre code { + display: block; + padding: 0.5em; + background: #F0F0F0; +} +.swagger-section pre code, +.swagger-section pre .subst, +.swagger-section pre .tag .title, +.swagger-section pre .lisp .title, +.swagger-section pre .clojure .built_in, +.swagger-section pre .nginx .title { + color: black; +} +.swagger-section pre .string, +.swagger-section pre .title, +.swagger-section pre .constant, +.swagger-section pre .parent, +.swagger-section pre .tag .value, +.swagger-section pre .rules .value, +.swagger-section pre .rules .value .number, +.swagger-section pre .preprocessor, +.swagger-section pre .ruby .symbol, +.swagger-section pre .ruby .symbol .string, +.swagger-section pre .aggregate, +.swagger-section pre .template_tag, +.swagger-section pre .django .variable, +.swagger-section pre .smalltalk .class, +.swagger-section pre .addition, +.swagger-section pre .flow, +.swagger-section pre .stream, +.swagger-section pre .bash .variable, +.swagger-section pre .apache .tag, +.swagger-section pre .apache .cbracket, +.swagger-section pre .tex .command, +.swagger-section pre .tex .special, +.swagger-section pre .erlang_repl .function_or_atom, +.swagger-section pre .markdown .header { + color: #800; +} +.swagger-section pre .comment, +.swagger-section pre .annotation, +.swagger-section pre .template_comment, +.swagger-section pre .diff .header, +.swagger-section pre .chunk, +.swagger-section pre .markdown .blockquote { + color: #888; +} +.swagger-section pre .number, +.swagger-section pre .date, +.swagger-section pre .regexp, +.swagger-section pre .literal, +.swagger-section pre .smalltalk .symbol, +.swagger-section pre .smalltalk .char, +.swagger-section pre .go .constant, +.swagger-section pre .change, +.swagger-section pre .markdown .bullet, +.swagger-section pre .markdown .link_url { + color: #080; +} +.swagger-section pre .label, +.swagger-section pre .javadoc, +.swagger-section pre .ruby .string, +.swagger-section pre .decorator, +.swagger-section pre .filter .argument, +.swagger-section pre .localvars, +.swagger-section pre .array, +.swagger-section pre .attr_selector, +.swagger-section pre .important, +.swagger-section pre .pseudo, +.swagger-section pre .pi, +.swagger-section pre .doctype, +.swagger-section pre .deletion, +.swagger-section pre .envvar, +.swagger-section pre .shebang, +.swagger-section pre .apache .sqbracket, +.swagger-section pre .nginx .built_in, +.swagger-section pre .tex .formula, +.swagger-section pre .erlang_repl .reserved, +.swagger-section pre .prompt, +.swagger-section pre .markdown .link_label, +.swagger-section pre .vhdl .attribute, +.swagger-section pre .clojure .attribute, +.swagger-section pre .coffeescript .property { + color: #8888ff; +} +.swagger-section pre .keyword, +.swagger-section pre .id, +.swagger-section pre .phpdoc, +.swagger-section pre .title, +.swagger-section pre .built_in, +.swagger-section pre .aggregate, +.swagger-section pre .css .tag, +.swagger-section pre .javadoctag, +.swagger-section pre .phpdoc, +.swagger-section pre .yardoctag, +.swagger-section pre .smalltalk .class, +.swagger-section pre .winutils, +.swagger-section pre .bash .variable, +.swagger-section pre .apache .tag, +.swagger-section pre .go .typename, +.swagger-section pre .tex .command, +.swagger-section pre .markdown .strong, +.swagger-section pre .request, +.swagger-section pre .status { + font-weight: bold; +} +.swagger-section pre .markdown .emphasis { + font-style: italic; +} +.swagger-section pre .nginx .built_in { + font-weight: normal; +} +.swagger-section pre .coffeescript .javascript, +.swagger-section pre .javascript .xml, +.swagger-section pre .tex .formula, +.swagger-section pre .xml .javascript, +.swagger-section pre .xml .vbscript, +.swagger-section pre .xml .css, +.swagger-section pre .xml .cdata { + opacity: 0.5; +} +.swagger-section .swagger-ui-wrap { + line-height: 1; + font-family: "Droid Sans", sans-serif; + max-width: 960px; + margin-left: auto; + margin-right: auto; +} +.swagger-section .swagger-ui-wrap b, +.swagger-section .swagger-ui-wrap strong { + font-family: "Droid Sans", sans-serif; + font-weight: bold; +} +.swagger-section .swagger-ui-wrap q, +.swagger-section .swagger-ui-wrap blockquote { + quotes: none; +} +.swagger-section .swagger-ui-wrap p { + line-height: 1.4em; + padding: 0 0 10px; + color: #333333; +} +.swagger-section .swagger-ui-wrap q:before, +.swagger-section .swagger-ui-wrap q:after, +.swagger-section .swagger-ui-wrap blockquote:before, +.swagger-section .swagger-ui-wrap blockquote:after { + content: none; +} +.swagger-section .swagger-ui-wrap .heading_with_menu h1, +.swagger-section .swagger-ui-wrap .heading_with_menu h2, +.swagger-section .swagger-ui-wrap .heading_with_menu h3, +.swagger-section .swagger-ui-wrap .heading_with_menu h4, +.swagger-section .swagger-ui-wrap .heading_with_menu h5, +.swagger-section .swagger-ui-wrap .heading_with_menu h6 { + display: block; + clear: none; + float: left; + -moz-box-sizing: border-box; + -webkit-box-sizing: border-box; + -ms-box-sizing: border-box; + box-sizing: border-box; + width: 60%; +} +.swagger-section .swagger-ui-wrap table { + border-collapse: collapse; + border-spacing: 0; +} +.swagger-section .swagger-ui-wrap table thead tr th { + padding: 5px; + font-size: 0.9em; + color: #666666; + border-bottom: 1px solid #999999; +} +.swagger-section .swagger-ui-wrap table tbody tr:last-child td { + border-bottom: none; +} +.swagger-section .swagger-ui-wrap table tbody tr.offset { + background-color: #f0f0f0; +} +.swagger-section .swagger-ui-wrap table tbody tr td { + padding: 6px; + font-size: 0.9em; + border-bottom: 1px solid #cccccc; + vertical-align: top; + line-height: 1.3em; +} +.swagger-section .swagger-ui-wrap ol { + margin: 0px 0 10px; + padding: 0 0 0 18px; + list-style-type: decimal; +} +.swagger-section .swagger-ui-wrap ol li { + padding: 5px 0px; + font-size: 0.9em; + color: #333333; +} +.swagger-section .swagger-ui-wrap ol, +.swagger-section .swagger-ui-wrap ul { + list-style: none; +} +.swagger-section .swagger-ui-wrap h1 a, +.swagger-section .swagger-ui-wrap h2 a, +.swagger-section .swagger-ui-wrap h3 a, +.swagger-section .swagger-ui-wrap h4 a, +.swagger-section .swagger-ui-wrap h5 a, +.swagger-section .swagger-ui-wrap h6 a { + text-decoration: none; +} +.swagger-section .swagger-ui-wrap h1 a:hover, +.swagger-section .swagger-ui-wrap h2 a:hover, +.swagger-section .swagger-ui-wrap h3 a:hover, +.swagger-section .swagger-ui-wrap h4 a:hover, +.swagger-section .swagger-ui-wrap h5 a:hover, +.swagger-section .swagger-ui-wrap h6 a:hover { + text-decoration: underline; +} +.swagger-section .swagger-ui-wrap h1 span.divider, +.swagger-section .swagger-ui-wrap h2 span.divider, +.swagger-section .swagger-ui-wrap h3 span.divider, +.swagger-section .swagger-ui-wrap h4 span.divider, +.swagger-section .swagger-ui-wrap h5 span.divider, +.swagger-section .swagger-ui-wrap h6 span.divider { + color: #aaaaaa; +} +.swagger-section .swagger-ui-wrap a { + color: #547f00; +} +.swagger-section .swagger-ui-wrap a img { + border: none; +} +.swagger-section .swagger-ui-wrap article, +.swagger-section .swagger-ui-wrap aside, +.swagger-section .swagger-ui-wrap details, +.swagger-section .swagger-ui-wrap figcaption, +.swagger-section .swagger-ui-wrap figure, +.swagger-section .swagger-ui-wrap footer, +.swagger-section .swagger-ui-wrap header, +.swagger-section .swagger-ui-wrap hgroup, +.swagger-section .swagger-ui-wrap menu, +.swagger-section .swagger-ui-wrap nav, +.swagger-section .swagger-ui-wrap section, +.swagger-section .swagger-ui-wrap summary { + display: block; +} +.swagger-section .swagger-ui-wrap pre { + font-family: "Anonymous Pro", "Menlo", "Consolas", "Bitstream Vera Sans Mono", "Courier New", monospace; + background-color: #fcf6db; + border: 1px solid #e5e0c6; + padding: 10px; +} +.swagger-section .swagger-ui-wrap pre code { + line-height: 1.6em; + background: none; +} +.swagger-section .swagger-ui-wrap .content > .content-type > div > label { + clear: both; + display: block; + color: #0F6AB4; + font-size: 1.1em; + margin: 0; + padding: 15px 0 5px; +} +.swagger-section .swagger-ui-wrap .content pre { + font-size: 12px; + margin-top: 5px; + padding: 5px; +} +.swagger-section .swagger-ui-wrap .icon-btn { + cursor: pointer; +} +.swagger-section .swagger-ui-wrap .info_title { + padding-bottom: 10px; + font-weight: bold; + font-size: 25px; +} +.swagger-section .swagger-ui-wrap .footer { + margin-top: 20px; +} +.swagger-section .swagger-ui-wrap p.big, +.swagger-section .swagger-ui-wrap div.big p { + font-size: 1em; + margin-bottom: 10px; +} +.swagger-section .swagger-ui-wrap form.fullwidth ol li.string input, +.swagger-section .swagger-ui-wrap form.fullwidth ol li.url input, +.swagger-section .swagger-ui-wrap form.fullwidth ol li.text textarea, +.swagger-section .swagger-ui-wrap form.fullwidth ol li.numeric input { + width: 500px !important; +} +.swagger-section .swagger-ui-wrap .info_license { + padding-bottom: 5px; +} +.swagger-section .swagger-ui-wrap .info_tos { + padding-bottom: 5px; +} +.swagger-section .swagger-ui-wrap .message-fail { + color: #cc0000; +} +.swagger-section .swagger-ui-wrap .info_url { + padding-bottom: 5px; +} +.swagger-section .swagger-ui-wrap .info_email { + padding-bottom: 5px; +} +.swagger-section .swagger-ui-wrap .info_name { + padding-bottom: 5px; +} +.swagger-section .swagger-ui-wrap .info_description { + padding-bottom: 10px; + font-size: 15px; +} +.swagger-section .swagger-ui-wrap .markdown ol li, +.swagger-section .swagger-ui-wrap .markdown ul li { + padding: 3px 0px; + line-height: 1.4em; + color: #333333; +} +.swagger-section .swagger-ui-wrap form.formtastic fieldset.inputs ol li.string input, +.swagger-section .swagger-ui-wrap form.formtastic fieldset.inputs ol li.url input, +.swagger-section .swagger-ui-wrap form.formtastic fieldset.inputs ol li.numeric input { + display: block; + padding: 4px; + width: auto; + clear: both; +} +.swagger-section .swagger-ui-wrap form.formtastic fieldset.inputs ol li.string input.title, +.swagger-section .swagger-ui-wrap form.formtastic fieldset.inputs ol li.url input.title, +.swagger-section .swagger-ui-wrap form.formtastic fieldset.inputs ol li.numeric input.title { + font-size: 1.3em; +} +.swagger-section .swagger-ui-wrap table.fullwidth { + width: 100%; +} +.swagger-section .swagger-ui-wrap .model-signature { + font-family: "Droid Sans", sans-serif; + font-size: 1em; + line-height: 1.5em; +} +.swagger-section .swagger-ui-wrap .model-signature .signature-nav a { + text-decoration: none; + color: #AAA; +} +.swagger-section .swagger-ui-wrap .model-signature .signature-nav a:hover { + text-decoration: underline; + color: black; +} +.swagger-section .swagger-ui-wrap .model-signature .signature-nav .selected { + color: black; + text-decoration: none; +} +.swagger-section .swagger-ui-wrap .model-signature .propType { + color: #5555aa; +} +.swagger-section .swagger-ui-wrap .model-signature pre:hover { + background-color: #ffffdd; +} +.swagger-section .swagger-ui-wrap .model-signature pre { + font-size: .85em; + line-height: 1.2em; + overflow: auto; + max-height: 200px; + cursor: pointer; +} +.swagger-section .swagger-ui-wrap .model-signature ul.signature-nav { + display: block; + margin: 0; + padding: 0; +} +.swagger-section .swagger-ui-wrap .model-signature ul.signature-nav li:last-child { + padding-right: 0; + border-right: none; +} +.swagger-section .swagger-ui-wrap .model-signature ul.signature-nav li { + float: left; + margin: 0 5px 5px 0; + padding: 2px 5px 2px 0; + border-right: 1px solid #ddd; +} +.swagger-section .swagger-ui-wrap .model-signature .propOpt { + color: #555; +} +.swagger-section .swagger-ui-wrap .model-signature .snippet small { + font-size: 0.75em; +} +.swagger-section .swagger-ui-wrap .model-signature .propOptKey { + font-style: italic; +} +.swagger-section .swagger-ui-wrap .model-signature .description .strong { + font-weight: bold; + color: #000; + font-size: .9em; +} +.swagger-section .swagger-ui-wrap .model-signature .description div { + font-size: 0.9em; + line-height: 1.5em; + margin-left: 1em; +} +.swagger-section .swagger-ui-wrap .model-signature .description .stronger { + font-weight: bold; + color: #000; +} +.swagger-section .swagger-ui-wrap .model-signature .description .propWrap .optionsWrapper { + border-spacing: 0; + position: absolute; + background-color: #ffffff; + border: 1px solid #bbbbbb; + display: none; + font-size: 11px; + max-width: 400px; + line-height: 30px; + color: black; + padding: 5px; + margin-left: 10px; +} +.swagger-section .swagger-ui-wrap .model-signature .description .propWrap .optionsWrapper th { + text-align: center; + background-color: #eeeeee; + border: 1px solid #bbbbbb; + font-size: 11px; + color: #666666; + font-weight: bold; + padding: 5px; + line-height: 15px; +} +.swagger-section .swagger-ui-wrap .model-signature .description .propWrap .optionsWrapper .optionName { + font-weight: bold; +} +.swagger-section .swagger-ui-wrap .model-signature .description .propDesc.markdown > p:first-child, +.swagger-section .swagger-ui-wrap .model-signature .description .propDesc.markdown > p:last-child { + display: inline; +} +.swagger-section .swagger-ui-wrap .model-signature .description .propDesc.markdown > p:not(:first-child):before { + display: block; + content: ''; +} +.swagger-section .swagger-ui-wrap .model-signature .description span:last-of-type.propDesc.markdown > p:only-child { + margin-right: -3px; +} +.swagger-section .swagger-ui-wrap .model-signature .propName { + font-weight: bold; +} +.swagger-section .swagger-ui-wrap .model-signature .signature-container { + clear: both; +} +.swagger-section .swagger-ui-wrap .body-textarea { + width: 300px; + height: 100px; + border: 1px solid #aaa; +} +.swagger-section .swagger-ui-wrap .markdown p code, +.swagger-section .swagger-ui-wrap .markdown li code { + font-family: "Anonymous Pro", "Menlo", "Consolas", "Bitstream Vera Sans Mono", "Courier New", monospace; + background-color: #f0f0f0; + color: black; + padding: 1px 3px; +} +.swagger-section .swagger-ui-wrap .required { + font-weight: bold; +} +.swagger-section .swagger-ui-wrap input.parameter { + width: 300px; + border: 1px solid #aaa; +} +.swagger-section .swagger-ui-wrap h1 { + color: black; + font-size: 1.5em; + line-height: 1.3em; + padding: 10px 0 10px 0; + font-family: "Droid Sans", sans-serif; + font-weight: bold; +} +.swagger-section .swagger-ui-wrap .heading_with_menu { + float: none; + clear: both; + overflow: hidden; + display: block; +} +.swagger-section .swagger-ui-wrap .heading_with_menu ul { + display: block; + clear: none; + float: right; + -moz-box-sizing: border-box; + -webkit-box-sizing: border-box; + -ms-box-sizing: border-box; + box-sizing: border-box; + margin-top: 10px; +} +.swagger-section .swagger-ui-wrap h2 { + color: black; + font-size: 1.3em; + padding: 10px 0 10px 0; +} +.swagger-section .swagger-ui-wrap h2 a { + color: black; +} +.swagger-section .swagger-ui-wrap h2 span.sub { + font-size: 0.7em; + color: #999999; + font-style: italic; +} +.swagger-section .swagger-ui-wrap h2 span.sub a { + color: #777777; +} +.swagger-section .swagger-ui-wrap span.weak { + color: #666666; +} +.swagger-section .swagger-ui-wrap .message-success { + color: #89BF04; +} +.swagger-section .swagger-ui-wrap caption, +.swagger-section .swagger-ui-wrap th, +.swagger-section .swagger-ui-wrap td { + text-align: left; + font-weight: normal; + vertical-align: middle; +} +.swagger-section .swagger-ui-wrap .code { + font-family: "Anonymous Pro", "Menlo", "Consolas", "Bitstream Vera Sans Mono", "Courier New", monospace; +} +.swagger-section .swagger-ui-wrap form.formtastic fieldset.inputs ol li.text textarea { + font-family: "Droid Sans", sans-serif; + height: 250px; + padding: 4px; + display: block; + clear: both; +} +.swagger-section .swagger-ui-wrap form.formtastic fieldset.inputs ol li.select select { + display: block; + clear: both; +} +.swagger-section .swagger-ui-wrap form.formtastic fieldset.inputs ol li.boolean { + float: none; + clear: both; + overflow: hidden; + display: block; +} +.swagger-section .swagger-ui-wrap form.formtastic fieldset.inputs ol li.boolean label { + display: block; + float: left; + clear: none; + margin: 0; + padding: 0; +} +.swagger-section .swagger-ui-wrap form.formtastic fieldset.inputs ol li.boolean input { + display: block; + float: left; + clear: none; + margin: 0 5px 0 0; +} +.swagger-section .swagger-ui-wrap form.formtastic fieldset.inputs ol li.required label { + color: black; +} +.swagger-section .swagger-ui-wrap form.formtastic fieldset.inputs ol li label { + display: block; + clear: both; + width: auto; + padding: 0 0 3px; + color: #666666; +} +.swagger-section .swagger-ui-wrap form.formtastic fieldset.inputs ol li label abbr { + padding-left: 3px; + color: #888888; +} +.swagger-section .swagger-ui-wrap form.formtastic fieldset.inputs ol li p.inline-hints { + margin-left: 0; + font-style: italic; + font-size: 0.9em; + margin: 0; +} +.swagger-section .swagger-ui-wrap form.formtastic fieldset.buttons { + margin: 0; + padding: 0; +} +.swagger-section .swagger-ui-wrap span.blank, +.swagger-section .swagger-ui-wrap span.empty { + color: #888888; + font-style: italic; +} +.swagger-section .swagger-ui-wrap .markdown h3 { + color: #547f00; +} +.swagger-section .swagger-ui-wrap .markdown h4 { + color: #666666; +} +.swagger-section .swagger-ui-wrap .markdown pre { + font-family: "Anonymous Pro", "Menlo", "Consolas", "Bitstream Vera Sans Mono", "Courier New", monospace; + background-color: #fcf6db; + border: 1px solid #e5e0c6; + padding: 10px; + margin: 0 0 10px 0; +} +.swagger-section .swagger-ui-wrap .markdown pre code { + line-height: 1.6em; +} +.swagger-section .swagger-ui-wrap div.gist { + margin: 20px 0 25px 0 !important; +} +.swagger-section .swagger-ui-wrap ul#resources { + font-family: "Droid Sans", sans-serif; + font-size: 0.9em; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource { + border-bottom: 1px solid #dddddd; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource:hover div.heading h2 a, +.swagger-section .swagger-ui-wrap ul#resources li.resource.active div.heading h2 a { + color: black; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource:hover div.heading ul.options li a, +.swagger-section .swagger-ui-wrap ul#resources li.resource.active div.heading ul.options li a { + color: #555555; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource:last-child { + border-bottom: none; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading { + border: 1px solid transparent; + float: none; + clear: both; + overflow: hidden; + display: block; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading ul.options { + overflow: hidden; + padding: 0; + display: block; + clear: none; + float: right; + margin: 14px 10px 0 0; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading ul.options li { + float: left; + clear: none; + margin: 0; + padding: 2px 10px; + border-right: 1px solid #dddddd; + color: #666666; + font-size: 0.9em; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading ul.options li a { + color: #aaaaaa; + text-decoration: none; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading ul.options li a:hover { + text-decoration: underline; + color: black; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading ul.options li a:hover, +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading ul.options li a:active, +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading ul.options li a.active { + text-decoration: underline; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading ul.options li:first-child, +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading ul.options li.first { + padding-left: 0; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading ul.options li:last-child, +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading ul.options li.last { + padding-right: 0; + border-right: none; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading ul.options:first-child, +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading ul.options.first { + padding-left: 0; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading h2 { + color: #999999; + padding-left: 0; + display: block; + clear: none; + float: left; + font-family: "Droid Sans", sans-serif; + font-weight: bold; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading h2 a { + color: #999999; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading h2 a:hover { + color: black; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation { + float: none; + clear: both; + overflow: hidden; + display: block; + margin: 0 0 10px; + padding: 0; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.heading { + float: none; + clear: both; + overflow: hidden; + display: block; + margin: 0; + padding: 0; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.heading h3 { + display: block; + clear: none; + float: left; + width: auto; + margin: 0; + padding: 0; + line-height: 1.1em; + color: black; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.heading h3 span.path { + padding-left: 10px; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.heading h3 span.path a { + color: black; + text-decoration: none; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.heading h3 span.path a:hover { + text-decoration: underline; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.heading h3 span.http_method a { + text-transform: uppercase; + text-decoration: none; + color: white; + display: inline-block; + width: 50px; + font-size: 0.7em; + text-align: center; + padding: 7px 0 4px; + -moz-border-radius: 2px; + -webkit-border-radius: 2px; + -o-border-radius: 2px; + -ms-border-radius: 2px; + -khtml-border-radius: 2px; + border-radius: 2px; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.heading h3 span { + margin: 0; + padding: 0; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.heading ul.options { + overflow: hidden; + padding: 0; + display: block; + clear: none; + float: right; + margin: 6px 10px 0 0; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.heading ul.options li { + float: left; + clear: none; + margin: 0; + padding: 2px 10px; + font-size: 0.9em; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.heading ul.options li a { + text-decoration: none; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.heading ul.options li.access { + color: black; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.content { + border-top: none; + padding: 10px; + -moz-border-radius-bottomleft: 6px; + -webkit-border-bottom-left-radius: 6px; + -o-border-bottom-left-radius: 6px; + -ms-border-bottom-left-radius: 6px; + -khtml-border-bottom-left-radius: 6px; + border-bottom-left-radius: 6px; + -moz-border-radius-bottomright: 6px; + -webkit-border-bottom-right-radius: 6px; + -o-border-bottom-right-radius: 6px; + -ms-border-bottom-right-radius: 6px; + -khtml-border-bottom-right-radius: 6px; + border-bottom-right-radius: 6px; + margin: 0 0 20px; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.content h4 { + font-size: 1.1em; + margin: 0; + padding: 15px 0 5px; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.content div.sandbox_header { + float: none; + clear: both; + overflow: hidden; + display: block; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.content div.sandbox_header a { + padding: 4px 0 0 10px; + display: inline-block; + font-size: 0.9em; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.content div.sandbox_header input.submit { + display: block; + clear: none; + float: left; + padding: 6px 8px; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.content div.sandbox_header span.response_throbber { + background-image: url('../images/throbber.gif'); + width: 128px; + height: 16px; + display: block; + clear: none; + float: right; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.content form input[type='text'].error { + outline: 2px solid black; + outline-color: #cc0000; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.content form select[name='parameterContentType'] { + max-width: 300px; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.content div.response div.block pre { + font-family: "Anonymous Pro", "Menlo", "Consolas", "Bitstream Vera Sans Mono", "Courier New", monospace; + padding: 10px; + font-size: 0.9em; + max-height: 400px; + overflow-y: auto; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.heading { + background-color: #f9f2e9; + border: 1px solid #f0e0ca; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.heading h3 span.http_method a { + background-color: #c5862b; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.heading ul.options li { + border-right: 1px solid #dddddd; + border-right-color: #f0e0ca; + color: #c5862b; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.heading ul.options li a { + color: #c5862b; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.content { + background-color: #faf5ee; + border: 1px solid #f0e0ca; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.content h4 { + color: #c5862b; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.content div.sandbox_header a { + color: #dcb67f; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.heading { + background-color: #fcffcd; + border: 1px solid black; + border-color: #ffd20f; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.heading h3 span.http_method a { + text-transform: uppercase; + background-color: #ffd20f; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.heading ul.options li { + border-right: 1px solid #dddddd; + border-right-color: #ffd20f; + color: #ffd20f; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.heading ul.options li a { + color: #ffd20f; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.content { + background-color: #fcffcd; + border: 1px solid black; + border-color: #ffd20f; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.content h4 { + color: #ffd20f; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.content div.sandbox_header a { + color: #6fc992; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.heading { + background-color: #f5e8e8; + border: 1px solid #e8c6c7; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.heading h3 span.http_method a { + text-transform: uppercase; + background-color: #a41e22; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.heading ul.options li { + border-right: 1px solid #dddddd; + border-right-color: #e8c6c7; + color: #a41e22; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.heading ul.options li a { + color: #a41e22; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.content { + background-color: #f7eded; + border: 1px solid #e8c6c7; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.content h4 { + color: #a41e22; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.content div.sandbox_header a { + color: #c8787a; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.heading { + background-color: #e7f6ec; + border: 1px solid #c3e8d1; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.heading h3 span.http_method a { + background-color: #10a54a; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.heading ul.options li { + border-right: 1px solid #dddddd; + border-right-color: #c3e8d1; + color: #10a54a; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.heading ul.options li a { + color: #10a54a; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.content { + background-color: #ebf7f0; + border: 1px solid #c3e8d1; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.content h4 { + color: #10a54a; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.content div.sandbox_header a { + color: #6fc992; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.heading { + background-color: #FCE9E3; + border: 1px solid #F5D5C3; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.heading h3 span.http_method a { + background-color: #D38042; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.heading ul.options li { + border-right: 1px solid #dddddd; + border-right-color: #f0cecb; + color: #D38042; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.heading ul.options li a { + color: #D38042; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.content { + background-color: #faf0ef; + border: 1px solid #f0cecb; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.content h4 { + color: #D38042; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.content div.sandbox_header a { + color: #dcb67f; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.heading { + background-color: #e7f0f7; + border: 1px solid #c3d9ec; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.heading h3 span.http_method a { + background-color: #0f6ab4; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.heading ul.options li { + border-right: 1px solid #dddddd; + border-right-color: #c3d9ec; + color: #0f6ab4; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.heading ul.options li a { + color: #0f6ab4; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.content { + background-color: #ebf3f9; + border: 1px solid #c3d9ec; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.content h4 { + color: #0f6ab4; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.content div.sandbox_header a { + color: #6fa5d2; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.options div.heading { + background-color: #e7f0f7; + border: 1px solid #c3d9ec; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.options div.heading h3 span.http_method a { + background-color: #0f6ab4; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.options div.heading ul.options li { + border-right: 1px solid #dddddd; + border-right-color: #c3d9ec; + color: #0f6ab4; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.options div.heading ul.options li a { + color: #0f6ab4; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.options div.content { + background-color: #ebf3f9; + border: 1px solid #c3d9ec; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.options div.content h4 { + color: #0f6ab4; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.options div.content div.sandbox_header a { + color: #6fa5d2; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.content, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.content, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.content, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.content, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.content, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.content { + border-top: none; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.heading ul.options li:last-child, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.heading ul.options li:last-child, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.heading ul.options li:last-child, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.heading ul.options li:last-child, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.heading ul.options li:last-child, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.heading ul.options li:last-child, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.heading ul.options li.last, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.heading ul.options li.last, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.heading ul.options li.last, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.heading ul.options li.last, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.heading ul.options li.last, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.heading ul.options li.last { + padding-right: 0; + border-right: none; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations ul.options li a:hover, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations ul.options li a:active, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations ul.options li a.active { + text-decoration: underline; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations ul.options li:first-child, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations ul.options li.first { + padding-left: 0; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations:first-child, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations.first { + padding-left: 0; +} +.swagger-section .swagger-ui-wrap p#colophon { + margin: 0 15px 40px 15px; + padding: 10px 0; + font-size: 0.8em; + border-top: 1px solid #dddddd; + font-family: "Droid Sans", sans-serif; + color: #999999; + font-style: italic; +} +.swagger-section .swagger-ui-wrap p#colophon a { + text-decoration: none; + color: #547f00; +} +.swagger-section .swagger-ui-wrap h3 { + color: black; + font-size: 1.1em; + padding: 10px 0 10px 0; +} +.swagger-section .swagger-ui-wrap .markdown ol, +.swagger-section .swagger-ui-wrap .markdown ul { + font-family: "Droid Sans", sans-serif; + margin: 5px 0 10px; + padding: 0 0 0 18px; + list-style-type: disc; +} +.swagger-section .swagger-ui-wrap form.form_box { + background-color: #ebf3f9; + border: 1px solid #c3d9ec; + padding: 10px; +} +.swagger-section .swagger-ui-wrap form.form_box label { + color: #0f6ab4 !important; +} +.swagger-section .swagger-ui-wrap form.form_box input[type=submit] { + display: block; + padding: 10px; +} +.swagger-section .swagger-ui-wrap form.form_box p.weak { + font-size: 0.8em; +} +.swagger-section .swagger-ui-wrap form.form_box p { + font-size: 0.9em; + padding: 0 0 15px; + color: #7e7b6d; +} +.swagger-section .swagger-ui-wrap form.form_box p a { + color: #646257; +} +.swagger-section .swagger-ui-wrap form.form_box p strong { + color: black; +} +.swagger-section .swagger-ui-wrap .operation-status td.markdown > p:last-child { + padding-bottom: 0; +} +.swagger-section .title { + font-style: bold; +} +.swagger-section .secondary_form { + display: none; +} +.swagger-section .main_image { + display: block; + margin-left: auto; + margin-right: auto; +} +.swagger-section .oauth_body { + margin-left: 100px; + margin-right: 100px; +} +.swagger-section .oauth_submit { + text-align: center; +} +.swagger-section .api-popup-dialog { + z-index: 10000; + position: absolute; + width: 500px; + background: #FFF; + padding: 20px; + border: 1px solid #ccc; + border-radius: 5px; + display: none; + font-size: 13px; + color: #777; +} +.swagger-section .api-popup-dialog .api-popup-title { + font-size: 24px; + padding: 10px 0; +} +.swagger-section .api-popup-dialog .api-popup-title { + font-size: 24px; + padding: 10px 0; +} +.swagger-section .api-popup-dialog p.error-msg { + padding-left: 5px; + padding-bottom: 5px; +} +.swagger-section .api-popup-dialog button.api-popup-authbtn { + height: 30px; +} +.swagger-section .api-popup-dialog button.api-popup-cancel { + height: 30px; +} +.swagger-section .api-popup-scopes { + padding: 10px 20px; +} +.swagger-section .api-popup-scopes li { + padding: 5px 0; + line-height: 20px; +} +.swagger-section .api-popup-scopes .api-scope-desc { + padding-left: 20px; + font-style: italic; +} +.swagger-section .api-popup-scopes li input { + position: relative; + top: 2px; +} +.swagger-section .api-popup-actions { + padding-top: 10px; +} +#header { + display: none; +} +.swagger-section .swagger-ui-wrap .model-signature pre { + max-height: none; +} +.swagger-section .swagger-ui-wrap .body-textarea { + width: 100px; +} +.swagger-section .swagger-ui-wrap input.parameter { + width: 100px; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading ul.options { + display: none; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints { + display: block !important; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.content { + display: block !important; +} diff --git a/openecomp-be/tools/swagger-ui/css/reset.css b/openecomp-be/tools/swagger-ui/css/reset.css new file mode 100644 index 0000000000..b2b078943c --- /dev/null +++ b/openecomp-be/tools/swagger-ui/css/reset.css @@ -0,0 +1,125 @@ +/* http://meyerweb.com/eric/tools/css/reset/ v2.0 | 20110126 */ +html, +body, +div, +span, +applet, +object, +iframe, +h1, +h2, +h3, +h4, +h5, +h6, +p, +blockquote, +pre, +a, +abbr, +acronym, +address, +big, +cite, +code, +del, +dfn, +em, +img, +ins, +kbd, +q, +s, +samp, +small, +strike, +strong, +sub, +sup, +tt, +var, +b, +u, +i, +center, +dl, +dt, +dd, +ol, +ul, +li, +fieldset, +form, +label, +legend, +table, +caption, +tbody, +tfoot, +thead, +tr, +th, +td, +article, +aside, +canvas, +details, +embed, +figure, +figcaption, +footer, +header, +hgroup, +menu, +nav, +output, +ruby, +section, +summary, +time, +mark, +audio, +video { + margin: 0; + padding: 0; + border: 0; + font-size: 100%; + font: inherit; + vertical-align: baseline; +} +/* HTML5 display-role reset for older browsers */ +article, +aside, +details, +figcaption, +figure, +footer, +header, +hgroup, +menu, +nav, +section { + display: block; +} +body { + line-height: 1; +} +ol, +ul { + list-style: none; +} +blockquote, +q { + quotes: none; +} +blockquote:before, +blockquote:after, +q:before, +q:after { + content: ''; + content: none; +} +table { + border-collapse: collapse; + border-spacing: 0; +} diff --git a/openecomp-be/tools/swagger-ui/css/screen.css b/openecomp-be/tools/swagger-ui/css/screen.css new file mode 100644 index 0000000000..96f54548c0 --- /dev/null +++ b/openecomp-be/tools/swagger-ui/css/screen.css @@ -0,0 +1,1282 @@ +/* Original style from softwaremaniacs.org (c) Ivan Sagalaev */ +.swagger-section pre code { + display: block; + padding: 0.5em; + background: #F0F0F0; +} +.swagger-section pre code, +.swagger-section pre .subst, +.swagger-section pre .tag .title, +.swagger-section pre .lisp .title, +.swagger-section pre .clojure .built_in, +.swagger-section pre .nginx .title { + color: black; +} +.swagger-section pre .string, +.swagger-section pre .title, +.swagger-section pre .constant, +.swagger-section pre .parent, +.swagger-section pre .tag .value, +.swagger-section pre .rules .value, +.swagger-section pre .rules .value .number, +.swagger-section pre .preprocessor, +.swagger-section pre .ruby .symbol, +.swagger-section pre .ruby .symbol .string, +.swagger-section pre .aggregate, +.swagger-section pre .template_tag, +.swagger-section pre .django .variable, +.swagger-section pre .smalltalk .class, +.swagger-section pre .addition, +.swagger-section pre .flow, +.swagger-section pre .stream, +.swagger-section pre .bash .variable, +.swagger-section pre .apache .tag, +.swagger-section pre .apache .cbracket, +.swagger-section pre .tex .command, +.swagger-section pre .tex .special, +.swagger-section pre .erlang_repl .function_or_atom, +.swagger-section pre .markdown .header { + color: #800; +} +.swagger-section pre .comment, +.swagger-section pre .annotation, +.swagger-section pre .template_comment, +.swagger-section pre .diff .header, +.swagger-section pre .chunk, +.swagger-section pre .markdown .blockquote { + color: #888; +} +.swagger-section pre .number, +.swagger-section pre .date, +.swagger-section pre .regexp, +.swagger-section pre .literal, +.swagger-section pre .smalltalk .symbol, +.swagger-section pre .smalltalk .char, +.swagger-section pre .go .constant, +.swagger-section pre .change, +.swagger-section pre .markdown .bullet, +.swagger-section pre .markdown .link_url { + color: #080; +} +.swagger-section pre .label, +.swagger-section pre .javadoc, +.swagger-section pre .ruby .string, +.swagger-section pre .decorator, +.swagger-section pre .filter .argument, +.swagger-section pre .localvars, +.swagger-section pre .array, +.swagger-section pre .attr_selector, +.swagger-section pre .important, +.swagger-section pre .pseudo, +.swagger-section pre .pi, +.swagger-section pre .doctype, +.swagger-section pre .deletion, +.swagger-section pre .envvar, +.swagger-section pre .shebang, +.swagger-section pre .apache .sqbracket, +.swagger-section pre .nginx .built_in, +.swagger-section pre .tex .formula, +.swagger-section pre .erlang_repl .reserved, +.swagger-section pre .prompt, +.swagger-section pre .markdown .link_label, +.swagger-section pre .vhdl .attribute, +.swagger-section pre .clojure .attribute, +.swagger-section pre .coffeescript .property { + color: #8888ff; +} +.swagger-section pre .keyword, +.swagger-section pre .id, +.swagger-section pre .phpdoc, +.swagger-section pre .title, +.swagger-section pre .built_in, +.swagger-section pre .aggregate, +.swagger-section pre .css .tag, +.swagger-section pre .javadoctag, +.swagger-section pre .phpdoc, +.swagger-section pre .yardoctag, +.swagger-section pre .smalltalk .class, +.swagger-section pre .winutils, +.swagger-section pre .bash .variable, +.swagger-section pre .apache .tag, +.swagger-section pre .go .typename, +.swagger-section pre .tex .command, +.swagger-section pre .markdown .strong, +.swagger-section pre .request, +.swagger-section pre .status { + font-weight: bold; +} +.swagger-section pre .markdown .emphasis { + font-style: italic; +} +.swagger-section pre .nginx .built_in { + font-weight: normal; +} +.swagger-section pre .coffeescript .javascript, +.swagger-section pre .javascript .xml, +.swagger-section pre .tex .formula, +.swagger-section pre .xml .javascript, +.swagger-section pre .xml .vbscript, +.swagger-section pre .xml .css, +.swagger-section pre .xml .cdata { + opacity: 0.5; +} +.swagger-section .swagger-ui-wrap { + line-height: 1; + font-family: "Droid Sans", sans-serif; + max-width: 960px; + margin-left: auto; + margin-right: auto; +} +.swagger-section .swagger-ui-wrap b, +.swagger-section .swagger-ui-wrap strong { + font-family: "Droid Sans", sans-serif; + font-weight: bold; +} +.swagger-section .swagger-ui-wrap q, +.swagger-section .swagger-ui-wrap blockquote { + quotes: none; +} +.swagger-section .swagger-ui-wrap p { + line-height: 1.4em; + padding: 0 0 10px; + color: #333333; +} +.swagger-section .swagger-ui-wrap q:before, +.swagger-section .swagger-ui-wrap q:after, +.swagger-section .swagger-ui-wrap blockquote:before, +.swagger-section .swagger-ui-wrap blockquote:after { + content: none; +} +.swagger-section .swagger-ui-wrap .heading_with_menu h1, +.swagger-section .swagger-ui-wrap .heading_with_menu h2, +.swagger-section .swagger-ui-wrap .heading_with_menu h3, +.swagger-section .swagger-ui-wrap .heading_with_menu h4, +.swagger-section .swagger-ui-wrap .heading_with_menu h5, +.swagger-section .swagger-ui-wrap .heading_with_menu h6 { + display: block; + clear: none; + float: left; + -moz-box-sizing: border-box; + -webkit-box-sizing: border-box; + -ms-box-sizing: border-box; + box-sizing: border-box; + width: 60%; +} +.swagger-section .swagger-ui-wrap table { + border-collapse: collapse; + border-spacing: 0; +} +.swagger-section .swagger-ui-wrap table thead tr th { + padding: 5px; + font-size: 0.9em; + color: #666666; + border-bottom: 1px solid #999999; +} +.swagger-section .swagger-ui-wrap table tbody tr:last-child td { + border-bottom: none; +} +.swagger-section .swagger-ui-wrap table tbody tr.offset { + background-color: #f0f0f0; +} +.swagger-section .swagger-ui-wrap table tbody tr td { + padding: 6px; + font-size: 0.9em; + border-bottom: 1px solid #cccccc; + vertical-align: top; + line-height: 1.3em; +} +.swagger-section .swagger-ui-wrap ol { + margin: 0px 0 10px; + padding: 0 0 0 18px; + list-style-type: decimal; +} +.swagger-section .swagger-ui-wrap ol li { + padding: 5px 0px; + font-size: 0.9em; + color: #333333; +} +.swagger-section .swagger-ui-wrap ol, +.swagger-section .swagger-ui-wrap ul { + list-style: none; +} +.swagger-section .swagger-ui-wrap h1 a, +.swagger-section .swagger-ui-wrap h2 a, +.swagger-section .swagger-ui-wrap h3 a, +.swagger-section .swagger-ui-wrap h4 a, +.swagger-section .swagger-ui-wrap h5 a, +.swagger-section .swagger-ui-wrap h6 a { + text-decoration: none; +} +.swagger-section .swagger-ui-wrap h1 a:hover, +.swagger-section .swagger-ui-wrap h2 a:hover, +.swagger-section .swagger-ui-wrap h3 a:hover, +.swagger-section .swagger-ui-wrap h4 a:hover, +.swagger-section .swagger-ui-wrap h5 a:hover, +.swagger-section .swagger-ui-wrap h6 a:hover { + text-decoration: underline; +} +.swagger-section .swagger-ui-wrap h1 span.divider, +.swagger-section .swagger-ui-wrap h2 span.divider, +.swagger-section .swagger-ui-wrap h3 span.divider, +.swagger-section .swagger-ui-wrap h4 span.divider, +.swagger-section .swagger-ui-wrap h5 span.divider, +.swagger-section .swagger-ui-wrap h6 span.divider { + color: #aaaaaa; +} +.swagger-section .swagger-ui-wrap a { + color: #547f00; +} +.swagger-section .swagger-ui-wrap a img { + border: none; +} +.swagger-section .swagger-ui-wrap article, +.swagger-section .swagger-ui-wrap aside, +.swagger-section .swagger-ui-wrap details, +.swagger-section .swagger-ui-wrap figcaption, +.swagger-section .swagger-ui-wrap figure, +.swagger-section .swagger-ui-wrap footer, +.swagger-section .swagger-ui-wrap header, +.swagger-section .swagger-ui-wrap hgroup, +.swagger-section .swagger-ui-wrap menu, +.swagger-section .swagger-ui-wrap nav, +.swagger-section .swagger-ui-wrap section, +.swagger-section .swagger-ui-wrap summary { + display: block; +} +.swagger-section .swagger-ui-wrap pre { + font-family: "Anonymous Pro", "Menlo", "Consolas", "Bitstream Vera Sans Mono", "Courier New", monospace; + background-color: #fcf6db; + border: 1px solid #e5e0c6; + padding: 10px; +} +.swagger-section .swagger-ui-wrap pre code { + line-height: 1.6em; + background: none; +} +.swagger-section .swagger-ui-wrap .content > .content-type > div > label { + clear: both; + display: block; + color: #0F6AB4; + font-size: 1.1em; + margin: 0; + padding: 15px 0 5px; +} +.swagger-section .swagger-ui-wrap .content pre { + font-size: 12px; + margin-top: 5px; + padding: 5px; +} +.swagger-section .swagger-ui-wrap .icon-btn { + cursor: pointer; +} +.swagger-section .swagger-ui-wrap .info_title { + padding-bottom: 10px; + font-weight: bold; + font-size: 25px; +} +.swagger-section .swagger-ui-wrap .footer { + margin-top: 20px; +} +.swagger-section .swagger-ui-wrap p.big, +.swagger-section .swagger-ui-wrap div.big p { + font-size: 1em; + margin-bottom: 10px; +} +.swagger-section .swagger-ui-wrap form.fullwidth ol li.string input, +.swagger-section .swagger-ui-wrap form.fullwidth ol li.url input, +.swagger-section .swagger-ui-wrap form.fullwidth ol li.text textarea, +.swagger-section .swagger-ui-wrap form.fullwidth ol li.numeric input { + width: 500px !important; +} +.swagger-section .swagger-ui-wrap .info_license { + padding-bottom: 5px; +} +.swagger-section .swagger-ui-wrap .info_tos { + padding-bottom: 5px; +} +.swagger-section .swagger-ui-wrap .message-fail { + color: #cc0000; +} +.swagger-section .swagger-ui-wrap .info_url { + padding-bottom: 5px; +} +.swagger-section .swagger-ui-wrap .info_email { + padding-bottom: 5px; +} +.swagger-section .swagger-ui-wrap .info_name { + padding-bottom: 5px; +} +.swagger-section .swagger-ui-wrap .info_description { + padding-bottom: 10px; + font-size: 15px; +} +.swagger-section .swagger-ui-wrap .markdown ol li, +.swagger-section .swagger-ui-wrap .markdown ul li { + padding: 3px 0px; + line-height: 1.4em; + color: #333333; +} +.swagger-section .swagger-ui-wrap form.formtastic fieldset.inputs ol li.string input, +.swagger-section .swagger-ui-wrap form.formtastic fieldset.inputs ol li.url input, +.swagger-section .swagger-ui-wrap form.formtastic fieldset.inputs ol li.numeric input { + display: block; + padding: 4px; + width: auto; + clear: both; +} +.swagger-section .swagger-ui-wrap form.formtastic fieldset.inputs ol li.string input.title, +.swagger-section .swagger-ui-wrap form.formtastic fieldset.inputs ol li.url input.title, +.swagger-section .swagger-ui-wrap form.formtastic fieldset.inputs ol li.numeric input.title { + font-size: 1.3em; +} +.swagger-section .swagger-ui-wrap table.fullwidth { + width: 100%; +} +.swagger-section .swagger-ui-wrap .model-signature { + font-family: "Droid Sans", sans-serif; + font-size: 1em; + line-height: 1.5em; +} +.swagger-section .swagger-ui-wrap .model-signature .signature-nav a { + text-decoration: none; + color: #AAA; +} +.swagger-section .swagger-ui-wrap .model-signature .signature-nav a:hover { + text-decoration: underline; + color: black; +} +.swagger-section .swagger-ui-wrap .model-signature .signature-nav .selected { + color: black; + text-decoration: none; +} +.swagger-section .swagger-ui-wrap .model-signature .propType { + color: #5555aa; +} +.swagger-section .swagger-ui-wrap .model-signature pre:hover { + background-color: #ffffdd; +} +.swagger-section .swagger-ui-wrap .model-signature pre { + font-size: .85em; + line-height: 1.2em; + overflow: auto; + max-height: 200px; + cursor: pointer; +} +.swagger-section .swagger-ui-wrap .model-signature ul.signature-nav { + display: block; + margin: 0; + padding: 0; +} +.swagger-section .swagger-ui-wrap .model-signature ul.signature-nav li:last-child { + padding-right: 0; + border-right: none; +} +.swagger-section .swagger-ui-wrap .model-signature ul.signature-nav li { + float: left; + margin: 0 5px 5px 0; + padding: 2px 5px 2px 0; + border-right: 1px solid #ddd; +} +.swagger-section .swagger-ui-wrap .model-signature .propOpt { + color: #555; +} +.swagger-section .swagger-ui-wrap .model-signature .snippet small { + font-size: 0.75em; +} +.swagger-section .swagger-ui-wrap .model-signature .propOptKey { + font-style: italic; +} +.swagger-section .swagger-ui-wrap .model-signature .description .strong { + font-weight: bold; + color: #000; + font-size: .9em; +} +.swagger-section .swagger-ui-wrap .model-signature .description div { + font-size: 0.9em; + line-height: 1.5em; + margin-left: 1em; +} +.swagger-section .swagger-ui-wrap .model-signature .description .stronger { + font-weight: bold; + color: #000; +} +.swagger-section .swagger-ui-wrap .model-signature .description .propWrap .optionsWrapper { + border-spacing: 0; + position: absolute; + background-color: #ffffff; + border: 1px solid #bbbbbb; + display: none; + font-size: 11px; + max-width: 400px; + line-height: 30px; + color: black; + padding: 5px; + margin-left: 10px; +} +.swagger-section .swagger-ui-wrap .model-signature .description .propWrap .optionsWrapper th { + text-align: center; + background-color: #eeeeee; + border: 1px solid #bbbbbb; + font-size: 11px; + color: #666666; + font-weight: bold; + padding: 5px; + line-height: 15px; +} +.swagger-section .swagger-ui-wrap .model-signature .description .propWrap .optionsWrapper .optionName { + font-weight: bold; +} +.swagger-section .swagger-ui-wrap .model-signature .description .propDesc.markdown > p:first-child, +.swagger-section .swagger-ui-wrap .model-signature .description .propDesc.markdown > p:last-child { + display: inline; +} +.swagger-section .swagger-ui-wrap .model-signature .description .propDesc.markdown > p:not(:first-child):before { + display: block; + content: ''; +} +.swagger-section .swagger-ui-wrap .model-signature .description span:last-of-type.propDesc.markdown > p:only-child { + margin-right: -3px; +} +.swagger-section .swagger-ui-wrap .model-signature .propName { + font-weight: bold; +} +.swagger-section .swagger-ui-wrap .model-signature .signature-container { + clear: both; +} +.swagger-section .swagger-ui-wrap .body-textarea { + width: 300px; + height: 100px; + border: 1px solid #aaa; +} +.swagger-section .swagger-ui-wrap .markdown p code, +.swagger-section .swagger-ui-wrap .markdown li code { + font-family: "Anonymous Pro", "Menlo", "Consolas", "Bitstream Vera Sans Mono", "Courier New", monospace; + background-color: #f0f0f0; + color: black; + padding: 1px 3px; +} +.swagger-section .swagger-ui-wrap .required { + font-weight: bold; +} +.swagger-section .swagger-ui-wrap input.parameter { + width: 300px; + border: 1px solid #aaa; +} +.swagger-section .swagger-ui-wrap h1 { + color: black; + font-size: 1.5em; + line-height: 1.3em; + padding: 10px 0 10px 0; + font-family: "Droid Sans", sans-serif; + font-weight: bold; +} +.swagger-section .swagger-ui-wrap .heading_with_menu { + float: none; + clear: both; + overflow: hidden; + display: block; +} +.swagger-section .swagger-ui-wrap .heading_with_menu ul { + display: block; + clear: none; + float: right; + -moz-box-sizing: border-box; + -webkit-box-sizing: border-box; + -ms-box-sizing: border-box; + box-sizing: border-box; + margin-top: 10px; +} +.swagger-section .swagger-ui-wrap h2 { + color: black; + font-size: 1.3em; + padding: 10px 0 10px 0; +} +.swagger-section .swagger-ui-wrap h2 a { + color: black; +} +.swagger-section .swagger-ui-wrap h2 span.sub { + font-size: 0.7em; + color: #999999; + font-style: italic; +} +.swagger-section .swagger-ui-wrap h2 span.sub a { + color: #777777; +} +.swagger-section .swagger-ui-wrap span.weak { + color: #666666; +} +.swagger-section .swagger-ui-wrap .message-success { + color: #89BF04; +} +.swagger-section .swagger-ui-wrap caption, +.swagger-section .swagger-ui-wrap th, +.swagger-section .swagger-ui-wrap td { + text-align: left; + font-weight: normal; + vertical-align: middle; +} +.swagger-section .swagger-ui-wrap .code { + font-family: "Anonymous Pro", "Menlo", "Consolas", "Bitstream Vera Sans Mono", "Courier New", monospace; +} +.swagger-section .swagger-ui-wrap form.formtastic fieldset.inputs ol li.text textarea { + font-family: "Droid Sans", sans-serif; + height: 250px; + padding: 4px; + display: block; + clear: both; +} +.swagger-section .swagger-ui-wrap form.formtastic fieldset.inputs ol li.select select { + display: block; + clear: both; +} +.swagger-section .swagger-ui-wrap form.formtastic fieldset.inputs ol li.boolean { + float: none; + clear: both; + overflow: hidden; + display: block; +} +.swagger-section .swagger-ui-wrap form.formtastic fieldset.inputs ol li.boolean label { + display: block; + float: left; + clear: none; + margin: 0; + padding: 0; +} +.swagger-section .swagger-ui-wrap form.formtastic fieldset.inputs ol li.boolean input { + display: block; + float: left; + clear: none; + margin: 0 5px 0 0; +} +.swagger-section .swagger-ui-wrap form.formtastic fieldset.inputs ol li.required label { + color: black; +} +.swagger-section .swagger-ui-wrap form.formtastic fieldset.inputs ol li label { + display: block; + clear: both; + width: auto; + padding: 0 0 3px; + color: #666666; +} +.swagger-section .swagger-ui-wrap form.formtastic fieldset.inputs ol li label abbr { + padding-left: 3px; + color: #888888; +} +.swagger-section .swagger-ui-wrap form.formtastic fieldset.inputs ol li p.inline-hints { + margin-left: 0; + font-style: italic; + font-size: 0.9em; + margin: 0; +} +.swagger-section .swagger-ui-wrap form.formtastic fieldset.buttons { + margin: 0; + padding: 0; +} +.swagger-section .swagger-ui-wrap span.blank, +.swagger-section .swagger-ui-wrap span.empty { + color: #888888; + font-style: italic; +} +.swagger-section .swagger-ui-wrap .markdown h3 { + color: #547f00; +} +.swagger-section .swagger-ui-wrap .markdown h4 { + color: #666666; +} +.swagger-section .swagger-ui-wrap .markdown pre { + font-family: "Anonymous Pro", "Menlo", "Consolas", "Bitstream Vera Sans Mono", "Courier New", monospace; + background-color: #fcf6db; + border: 1px solid #e5e0c6; + padding: 10px; + margin: 0 0 10px 0; +} +.swagger-section .swagger-ui-wrap .markdown pre code { + line-height: 1.6em; +} +.swagger-section .swagger-ui-wrap div.gist { + margin: 20px 0 25px 0 !important; +} +.swagger-section .swagger-ui-wrap ul#resources { + font-family: "Droid Sans", sans-serif; + font-size: 0.9em; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource { + border-bottom: 1px solid #dddddd; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource:hover div.heading h2 a, +.swagger-section .swagger-ui-wrap ul#resources li.resource.active div.heading h2 a { + color: black; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource:hover div.heading ul.options li a, +.swagger-section .swagger-ui-wrap ul#resources li.resource.active div.heading ul.options li a { + color: #555555; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource:last-child { + border-bottom: none; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading { + border: 1px solid transparent; + float: none; + clear: both; + overflow: hidden; + display: block; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading ul.options { + overflow: hidden; + padding: 0; + display: block; + clear: none; + float: right; + margin: 14px 10px 0 0; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading ul.options li { + float: left; + clear: none; + margin: 0; + padding: 2px 10px; + border-right: 1px solid #dddddd; + color: #666666; + font-size: 0.9em; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading ul.options li a { + color: #aaaaaa; + text-decoration: none; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading ul.options li a:hover { + text-decoration: underline; + color: black; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading ul.options li a:hover, +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading ul.options li a:active, +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading ul.options li a.active { + text-decoration: underline; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading ul.options li:first-child, +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading ul.options li.first { + padding-left: 0; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading ul.options li:last-child, +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading ul.options li.last { + padding-right: 0; + border-right: none; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading ul.options:first-child, +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading ul.options.first { + padding-left: 0; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading h2 { + color: #999999; + padding-left: 0; + display: block; + clear: none; + float: left; + font-family: "Droid Sans", sans-serif; + font-weight: bold; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading h2 a { + color: #999999; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading h2 a:hover { + color: black; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation { + float: none; + clear: both; + overflow: hidden; + display: block; + margin: 0 0 10px; + padding: 0; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.heading { + float: none; + clear: both; + overflow: hidden; + display: block; + margin: 0; + padding: 0; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.heading h3 { + display: block; + clear: none; + float: left; + width: auto; + margin: 0; + padding: 0; + line-height: 1.1em; + color: black; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.heading h3 span.path { + padding-left: 10px; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.heading h3 span.path a { + color: black; + text-decoration: none; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.heading h3 span.path a:hover { + text-decoration: underline; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.heading h3 span.http_method a { + text-transform: uppercase; + text-decoration: none; + color: white; + display: inline-block; + width: 50px; + font-size: 0.7em; + text-align: center; + padding: 7px 0 4px; + -moz-border-radius: 2px; + -webkit-border-radius: 2px; + -o-border-radius: 2px; + -ms-border-radius: 2px; + -khtml-border-radius: 2px; + border-radius: 2px; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.heading h3 span { + margin: 0; + padding: 0; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.heading ul.options { + overflow: hidden; + padding: 0; + display: block; + clear: none; + float: right; + margin: 6px 10px 0 0; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.heading ul.options li { + float: left; + clear: none; + margin: 0; + padding: 2px 10px; + font-size: 0.9em; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.heading ul.options li a { + text-decoration: none; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.heading ul.options li.access { + color: black; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.content { + border-top: none; + padding: 10px; + -moz-border-radius-bottomleft: 6px; + -webkit-border-bottom-left-radius: 6px; + -o-border-bottom-left-radius: 6px; + -ms-border-bottom-left-radius: 6px; + -khtml-border-bottom-left-radius: 6px; + border-bottom-left-radius: 6px; + -moz-border-radius-bottomright: 6px; + -webkit-border-bottom-right-radius: 6px; + -o-border-bottom-right-radius: 6px; + -ms-border-bottom-right-radius: 6px; + -khtml-border-bottom-right-radius: 6px; + border-bottom-right-radius: 6px; + margin: 0 0 20px; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.content h4 { + font-size: 1.1em; + margin: 0; + padding: 15px 0 5px; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.content div.sandbox_header { + float: none; + clear: both; + overflow: hidden; + display: block; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.content div.sandbox_header a { + padding: 4px 0 0 10px; + display: inline-block; + font-size: 0.9em; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.content div.sandbox_header input.submit { + display: block; + clear: none; + float: left; + padding: 6px 8px; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.content div.sandbox_header span.response_throbber { + background-image: url('../images/throbber.gif'); + width: 128px; + height: 16px; + display: block; + clear: none; + float: right; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.content form input[type='text'].error { + outline: 2px solid black; + outline-color: #cc0000; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.content form select[name='parameterContentType'] { + max-width: 300px; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation div.content div.response div.block pre { + font-family: "Anonymous Pro", "Menlo", "Consolas", "Bitstream Vera Sans Mono", "Courier New", monospace; + padding: 10px; + font-size: 0.9em; + max-height: 400px; + overflow-y: auto; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.heading { + background-color: #f9f2e9; + border: 1px solid #f0e0ca; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.heading h3 span.http_method a { + background-color: #c5862b; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.heading ul.options li { + border-right: 1px solid #dddddd; + border-right-color: #f0e0ca; + color: #c5862b; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.heading ul.options li a { + color: #c5862b; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.content { + background-color: #faf5ee; + border: 1px solid #f0e0ca; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.content h4 { + color: #c5862b; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.content div.sandbox_header a { + color: #dcb67f; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.heading { + background-color: #fcffcd; + border: 1px solid black; + border-color: #ffd20f; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.heading h3 span.http_method a { + text-transform: uppercase; + background-color: #ffd20f; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.heading ul.options li { + border-right: 1px solid #dddddd; + border-right-color: #ffd20f; + color: #ffd20f; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.heading ul.options li a { + color: #ffd20f; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.content { + background-color: #fcffcd; + border: 1px solid black; + border-color: #ffd20f; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.content h4 { + color: #ffd20f; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.content div.sandbox_header a { + color: #6fc992; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.heading { + background-color: #f5e8e8; + border: 1px solid #e8c6c7; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.heading h3 span.http_method a { + text-transform: uppercase; + background-color: #a41e22; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.heading ul.options li { + border-right: 1px solid #dddddd; + border-right-color: #e8c6c7; + color: #a41e22; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.heading ul.options li a { + color: #a41e22; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.content { + background-color: #f7eded; + border: 1px solid #e8c6c7; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.content h4 { + color: #a41e22; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.content div.sandbox_header a { + color: #c8787a; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.heading { + background-color: #e7f6ec; + border: 1px solid #c3e8d1; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.heading h3 span.http_method a { + background-color: #10a54a; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.heading ul.options li { + border-right: 1px solid #dddddd; + border-right-color: #c3e8d1; + color: #10a54a; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.heading ul.options li a { + color: #10a54a; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.content { + background-color: #ebf7f0; + border: 1px solid #c3e8d1; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.content h4 { + color: #10a54a; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.content div.sandbox_header a { + color: #6fc992; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.heading { + background-color: #FCE9E3; + border: 1px solid #F5D5C3; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.heading h3 span.http_method a { + background-color: #D38042; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.heading ul.options li { + border-right: 1px solid #dddddd; + border-right-color: #f0cecb; + color: #D38042; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.heading ul.options li a { + color: #D38042; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.content { + background-color: #faf0ef; + border: 1px solid #f0cecb; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.content h4 { + color: #D38042; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.content div.sandbox_header a { + color: #dcb67f; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.heading { + background-color: #e7f0f7; + border: 1px solid #c3d9ec; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.heading h3 span.http_method a { + background-color: #0f6ab4; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.heading ul.options li { + border-right: 1px solid #dddddd; + border-right-color: #c3d9ec; + color: #0f6ab4; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.heading ul.options li a { + color: #0f6ab4; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.content { + background-color: #ebf3f9; + border: 1px solid #c3d9ec; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.content h4 { + color: #0f6ab4; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.content div.sandbox_header a { + color: #6fa5d2; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.options div.heading { + background-color: #e7f0f7; + border: 1px solid #c3d9ec; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.options div.heading h3 span.http_method a { + background-color: #0f6ab4; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.options div.heading ul.options li { + border-right: 1px solid #dddddd; + border-right-color: #c3d9ec; + color: #0f6ab4; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.options div.heading ul.options li a { + color: #0f6ab4; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.options div.content { + background-color: #ebf3f9; + border: 1px solid #c3d9ec; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.options div.content h4 { + color: #0f6ab4; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.options div.content div.sandbox_header a { + color: #6fa5d2; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.content, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.content, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.content, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.content, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.content, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.content { + border-top: none; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.heading ul.options li:last-child, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.heading ul.options li:last-child, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.heading ul.options li:last-child, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.heading ul.options li:last-child, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.heading ul.options li:last-child, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.heading ul.options li:last-child, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.heading ul.options li.last, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.heading ul.options li.last, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.heading ul.options li.last, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.heading ul.options li.last, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.heading ul.options li.last, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.heading ul.options li.last { + padding-right: 0; + border-right: none; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations ul.options li a:hover, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations ul.options li a:active, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations ul.options li a.active { + text-decoration: underline; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations ul.options li:first-child, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations ul.options li.first { + padding-left: 0; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations:first-child, +.swagger-section .swagger-ui-wrap ul#resources li.resource ul.endpoints li.endpoint ul.operations.first { + padding-left: 0; +} +.swagger-section .swagger-ui-wrap p#colophon { + margin: 0 15px 40px 15px; + padding: 10px 0; + font-size: 0.8em; + border-top: 1px solid #dddddd; + font-family: "Droid Sans", sans-serif; + color: #999999; + font-style: italic; +} +.swagger-section .swagger-ui-wrap p#colophon a { + text-decoration: none; + color: #547f00; +} +.swagger-section .swagger-ui-wrap h3 { + color: black; + font-size: 1.1em; + padding: 10px 0 10px 0; +} +.swagger-section .swagger-ui-wrap .markdown ol, +.swagger-section .swagger-ui-wrap .markdown ul { + font-family: "Droid Sans", sans-serif; + margin: 5px 0 10px; + padding: 0 0 0 18px; + list-style-type: disc; +} +.swagger-section .swagger-ui-wrap form.form_box { + background-color: #ebf3f9; + border: 1px solid #c3d9ec; + padding: 10px; +} +.swagger-section .swagger-ui-wrap form.form_box label { + color: #0f6ab4 !important; +} +.swagger-section .swagger-ui-wrap form.form_box input[type=submit] { + display: block; + padding: 10px; +} +.swagger-section .swagger-ui-wrap form.form_box p.weak { + font-size: 0.8em; +} +.swagger-section .swagger-ui-wrap form.form_box p { + font-size: 0.9em; + padding: 0 0 15px; + color: #7e7b6d; +} +.swagger-section .swagger-ui-wrap form.form_box p a { + color: #646257; +} +.swagger-section .swagger-ui-wrap form.form_box p strong { + color: black; +} +.swagger-section .swagger-ui-wrap .operation-status td.markdown > p:last-child { + padding-bottom: 0; +} +.swagger-section .title { + font-style: bold; +} +.swagger-section .secondary_form { + display: none; +} +.swagger-section .main_image { + display: block; + margin-left: auto; + margin-right: auto; +} +.swagger-section .oauth_body { + margin-left: 100px; + margin-right: 100px; +} +.swagger-section .oauth_submit { + text-align: center; +} +.swagger-section .api-popup-dialog { + z-index: 10000; + position: absolute; + width: 500px; + background: #FFF; + padding: 20px; + border: 1px solid #ccc; + border-radius: 5px; + display: none; + font-size: 13px; + color: #777; +} +.swagger-section .api-popup-dialog .api-popup-title { + font-size: 24px; + padding: 10px 0; +} +.swagger-section .api-popup-dialog .api-popup-title { + font-size: 24px; + padding: 10px 0; +} +.swagger-section .api-popup-dialog p.error-msg { + padding-left: 5px; + padding-bottom: 5px; +} +.swagger-section .api-popup-dialog button.api-popup-authbtn { + height: 30px; +} +.swagger-section .api-popup-dialog button.api-popup-cancel { + height: 30px; +} +.swagger-section .api-popup-scopes { + padding: 10px 20px; +} +.swagger-section .api-popup-scopes li { + padding: 5px 0; + line-height: 20px; +} +.swagger-section .api-popup-scopes .api-scope-desc { + padding-left: 20px; + font-style: italic; +} +.swagger-section .api-popup-scopes li input { + position: relative; + top: 2px; +} +.swagger-section .api-popup-actions { + padding-top: 10px; +} +.swagger-section .access { + float: right; +} +.swagger-section .auth { + float: right; +} +.swagger-section .api-ic { + height: 18px; + vertical-align: middle; + display: inline-block; + background: url(../images/explorer_icons.png) no-repeat; +} +.swagger-section .api-ic .api_information_panel { + position: relative; + margin-top: 20px; + margin-left: -5px; + background: #FFF; + border: 1px solid #ccc; + border-radius: 5px; + display: none; + font-size: 13px; + max-width: 300px; + line-height: 30px; + color: black; + padding: 5px; +} +.swagger-section .api-ic .api_information_panel p .api-msg-enabled { + color: green; +} +.swagger-section .api-ic .api_information_panel p .api-msg-disabled { + color: red; +} +.swagger-section .api-ic:hover .api_information_panel { + position: absolute; + display: block; +} +.swagger-section .ic-info { + background-position: 0 0; + width: 18px; + margin-top: -6px; + margin-left: 4px; +} +.swagger-section .ic-warning { + background-position: -60px 0; + width: 18px; + margin-top: -6px; + margin-left: 4px; +} +.swagger-section .ic-error { + background-position: -30px 0; + width: 18px; + margin-top: -6px; + margin-left: 4px; +} +.swagger-section .ic-off { + background-position: -90px 0; + width: 58px; + margin-top: -4px; + cursor: pointer; +} +.swagger-section .ic-on { + background-position: -160px 0; + width: 58px; + margin-top: -4px; + cursor: pointer; +} +.swagger-section #header { + background-color: #89bf04; + padding: 14px; +} +.swagger-section #header a#logo { + font-size: 1.5em; + font-weight: bold; + text-decoration: none; + background: transparent url(../images/logo_small.png) no-repeat left center; + padding: 20px 0 20px 40px; + color: white; +} +.swagger-section #header form#api_selector { + display: block; + clear: none; + float: right; +} +.swagger-section #header form#api_selector .input { + display: block; + clear: none; + float: left; + margin: 0 10px 0 0; +} +.swagger-section #header form#api_selector .input input#input_apiKey { + width: 200px; +} +.swagger-section #header form#api_selector .input input#input_baseUrl { + width: 400px; +} +.swagger-section #header form#api_selector .input a#explore { + display: block; + text-decoration: none; + font-weight: bold; + padding: 6px 8px; + font-size: 0.9em; + color: white; + background-color: #547f00; + -moz-border-radius: 4px; + -webkit-border-radius: 4px; + -o-border-radius: 4px; + -ms-border-radius: 4px; + -khtml-border-radius: 4px; + border-radius: 4px; +} +.swagger-section #header form#api_selector .input a#explore:hover { + background-color: #547f00; +} +.swagger-section #header form#api_selector .input input { + font-size: 0.9em; + padding: 3px; + margin: 0; +} +.swagger-section #content_message { + margin: 10px 15px; + font-style: italic; + color: #999999; +} +.swagger-section #message-bar { + min-height: 30px; + text-align: center; + padding-top: 10px; +} diff --git a/openecomp-be/tools/swagger-ui/css/style.css b/openecomp-be/tools/swagger-ui/css/style.css new file mode 100644 index 0000000000..fc21a31db5 --- /dev/null +++ b/openecomp-be/tools/swagger-ui/css/style.css @@ -0,0 +1,250 @@ +.swagger-section #header a#logo { + font-size: 1.5em; + font-weight: bold; + text-decoration: none; + background: transparent url(../images/logo.png) no-repeat left center; + padding: 20px 0 20px 40px; +} +#text-head { + font-size: 80px; + font-family: 'Roboto', sans-serif; + color: #ffffff; + float: right; + margin-right: 20%; +} +.navbar-fixed-top .navbar-nav { + height: auto; +} +.navbar-fixed-top .navbar-brand { + height: auto; +} +.navbar-header { + height: auto; +} +.navbar-inverse { + background-color: #000; + border-color: #000; +} +#navbar-brand { + margin-left: 20%; +} +.navtext { + font-size: 10px; +} +.h1, +h1 { + font-size: 60px; +} +.navbar-default .navbar-header .navbar-brand { + color: #a2dfee; +} +/* tag titles */ +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading h2 a { + color: #393939; + font-family: 'Arvo', serif; + font-size: 1.5em; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading h2 a:hover { + color: black; +} +.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading h2 { + color: #525252; + padding-left: 0px; + display: block; + clear: none; + float: left; + font-family: 'Arvo', serif; + font-weight: bold; +} +.navbar-default .navbar-collapse, +.navbar-default .navbar-form { + border-color: #0A0A0A; +} +.container1 { + width: 1500px; + margin: auto; + margin-top: 0; + background-image: url('../images/shield.png'); + background-repeat: no-repeat; + background-position: -40px -20px; + margin-bottom: 210px; +} +.container-inner { + width: 1200px; + margin: auto; + background-color: rgba(223, 227, 228, 0.75); + padding-bottom: 40px; + padding-top: 40px; + border-radius: 15px; +} +.header-content { + padding: 0; + width: 1000px; +} +.title1 { + font-size: 80px; + font-family: 'Vollkorn', serif; + color: #404040; + text-align: center; + padding-top: 40px; + padding-bottom: 100px; +} +#icon { + margin-top: -18px; +} +.subtext { + font-size: 25px; + font-style: italic; + color: #08b; + text-align: right; + padding-right: 250px; +} +.bg-primary { + background-color: #00468b; +} +.navbar-default .nav > li > a, +.navbar-default .nav > li > a:focus { + color: #08b; +} +.navbar-default .nav > li > a, +.navbar-default .nav > li > a:hover { + color: #08b; +} +.navbar-default .nav > li > a, +.navbar-default .nav > li > a:focus:hover { + color: #08b; +} +.text-faded { + font-size: 25px; + font-family: 'Vollkorn', serif; +} +.section-heading { + font-family: 'Vollkorn', serif; + font-size: 45px; + padding-bottom: 10px; +} +hr { + border-color: #00468b; + padding-bottom: 10px; +} +.description { + margin-top: 20px; + padding-bottom: 200px; +} +.description li { + font-family: 'Vollkorn', serif; + font-size: 25px; + color: #525252; + margin-left: 28%; + padding-top: 5px; +} +.gap { + margin-top: 200px; +} +.troubleshootingtext { + color: rgba(255, 255, 255, 0.7); + padding-left: 30%; +} +.troubleshootingtext li { + list-style-type: circle; + font-size: 25px; + padding-bottom: 5px; +} +.overlay { + position: absolute; + top: 0; + left: 0; + width: 100%; + height: 100%; + z-index: 1000; +} +.block.response_body.json:hover { + cursor: pointer; +} +.backdrop { + color: blue; +} +#myModal { + height: 100%; +} +.modal-backdrop { + bottom: 0; + position: fixed; +} +.curl { + padding: 10px; + font-family: "Anonymous Pro", "Menlo", "Consolas", "Bitstream Vera Sans Mono", "Courier New", monospace; + font-size: 0.9em; + max-height: 400px; + margin-top: 5px; + overflow-y: auto; + background-color: #fcf6db; + border: 1px solid #e5e0c6; + border-radius: 4px; +} +.curl_title { + font-size: 1.1em; + margin: 0; + padding: 15px 0 5px; + font-family: 'Open Sans', 'Helvetica Neue', Arial, sans-serif; + font-weight: 500; + line-height: 1.1; +} +.footer { + display: none; +} +.swagger-section .swagger-ui-wrap h2 { + padding: 0; +} +h2 { + margin: 0; + margin-bottom: 5px; +} +.markdown p { + font-size: 15px; + font-family: 'Arvo', serif; +} +.swagger-section .swagger-ui-wrap .code { + font-size: 15px; + font-family: 'Arvo', serif; +} +.swagger-section .swagger-ui-wrap b { + font-family: 'Arvo', serif; +} +#signin:hover { + cursor: pointer; +} +.dropdown-menu { + padding: 15px; +} +.navbar-right .dropdown-menu { + left: 0; + right: auto; +} +#signinbutton { + width: 100%; + height: 32px; + font-size: 13px; + font-weight: bold; + color: #08b; +} +.navbar-default .nav > li .details { + color: #000000; + text-transform: none; + font-size: 15px; + font-weight: normal; + font-family: 'Open Sans', sans-serif; + font-style: italic; + line-height: 20px; + top: -2px; +} +.navbar-default .nav > li .details:hover { + color: black; +} +#signout { + width: 100%; + height: 32px; + font-size: 13px; + font-weight: bold; + color: #08b; +} diff --git a/openecomp-be/tools/swagger-ui/css/typography.css b/openecomp-be/tools/swagger-ui/css/typography.css new file mode 100644 index 0000000000..27c3751ac2 --- /dev/null +++ b/openecomp-be/tools/swagger-ui/css/typography.css @@ -0,0 +1,26 @@ +/* droid-sans-regular - latin */ +@font-face { + font-family: 'Droid Sans'; + font-style: normal; + font-weight: 400; + src: url('../fonts/droid-sans-v6-latin-regular.eot'); /* IE9 Compat Modes */ + src: local('Droid Sans'), local('DroidSans'), + url('../fonts/droid-sans-v6-latin-regular.eot?#iefix') format('embedded-opentype'), /* IE6-IE8 */ + url('../fonts/droid-sans-v6-latin-regular.woff2') format('woff2'), /* Super Modern Browsers */ + url('../fonts/droid-sans-v6-latin-regular.woff') format('woff'), /* Modern Browsers */ + url('../fonts/droid-sans-v6-latin-regular.ttf') format('truetype'), /* Safari, Android, iOS */ + url('../fonts/droid-sans-v6-latin-regular.svg#DroidSans') format('svg'); /* Legacy iOS */ +} +/* droid-sans-700 - latin */ +@font-face { + font-family: 'Droid Sans'; + font-style: normal; + font-weight: 700; + src: url('../fonts/droid-sans-v6-latin-700.eot'); /* IE9 Compat Modes */ + src: local('Droid Sans Bold'), local('DroidSans-Bold'), + url('../fonts/droid-sans-v6-latin-700.eot?#iefix') format('embedded-opentype'), /* IE6-IE8 */ + url('../fonts/droid-sans-v6-latin-700.woff2') format('woff2'), /* Super Modern Browsers */ + url('../fonts/droid-sans-v6-latin-700.woff') format('woff'), /* Modern Browsers */ + url('../fonts/droid-sans-v6-latin-700.ttf') format('truetype'), /* Safari, Android, iOS */ + url('../fonts/droid-sans-v6-latin-700.svg#DroidSans') format('svg'); /* Legacy iOS */ +} diff --git a/openecomp-be/tools/swagger-ui/fonts/droid-sans-v6-latin-700.eot b/openecomp-be/tools/swagger-ui/fonts/droid-sans-v6-latin-700.eot new file mode 100644 index 0000000000000000000000000000000000000000..d8524983ad8d296be95cb5b469efd1987d6e04e3 GIT binary patch literal 22922 zcmZsCQ;;QG5AA8&wr$&|ZQHhc+O}=mnzn75)3!D3p8Nf8_g3BHAyq4@QhC@_$==zC z)dm3SwEzIn{}deXpM`^l1cL?#1qBBI^nd~Y&;U85J5a#BE-^ru`al2wqyPj!{6D)M z%&GZ5`~M0$00?jaI0CEzX8+Mt0mc9afa`x0Xn^Q{sNH`k06-7W0GR*Ba{Z6x_@AE` zzye?dF#o5-026@wf9U^s|3g^-tpD)||GzPb|F4JufT*gZ(*K(Y000K~MGoMR0Vp>E z7?M$EFQO-mHZ&)#WL+GcoJrMrP3W1@SvQZim+$w-EQRyC*2sl9OOp#iuEC=DNFU0Y zu=jPv$K@pC>&OgLbsHAuV+;hb2z4e&N67~s+_XK5wd$(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HsO?g~^aF7CrEY<>h#y`e2o b()wT*kWXAeMzX)G0;aHJLU2Us_FHkFnk)~p literal 0 HcmV?d00001 diff --git a/openecomp-be/tools/swagger-ui/fonts/droid-sans-v6-latin-700.svg b/openecomp-be/tools/swagger-ui/fonts/droid-sans-v6-latin-700.svg new file mode 100644 index 0000000000..a54bbbbf25 --- /dev/null +++ b/openecomp-be/tools/swagger-ui/fonts/droid-sans-v6-latin-700.svg @@ -0,0 +1,411 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/openecomp-be/tools/swagger-ui/fonts/droid-sans-v6-latin-700.ttf b/openecomp-be/tools/swagger-ui/fonts/droid-sans-v6-latin-700.ttf new file mode 100644 index 0000000000000000000000000000000000000000..15896c441fd59e5c2e9bdab90816661de06cdcba GIT binary patch literal 40513 zcma&P31E{|)&_jZ3gEnK##Z%cX=d=_UTv_5;$g1No_e$)LPLh$tnl`n!f zRQGUm;rp(F*SU+9ue)sbYZDK`-=RND^Rkum=l0Iso`cYanQ)E0%jaIUim?zQyr%ti zub8`hfo)@%2BGWdcl54Wxpv(HFKMa}+OZ5?f4XYTf>jGv|K)mww%-f=orefoKm0L% zhdYEAWI^fV_ye{NZD(za%NDXFZ2h*~HtszJzslf^3^p@;3}G0|sCT_j@G*ifBX}{v z#LZ&F_OOJ-vU?1KL5a}NTR4aqtg!fwh zr}d@g_nN-KrqCevw47{twe`K$vqO%TLoYMUpS>k4!Mo_~tC$6qU7XH$=VUB8f1nr#ikT=# zb1WJ$Ik80oZ|E#ehAS&30aGo;MzbZV#;h;8_};!9<5$g_6)c#)WOmrdWwg(p_}%8&c zvvP2btH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^W}f|CjW_=%5p=*;*!=~hPZ0bV{-}H;-9GI8fNS0j zc-QofNN=Id8~+>rX2Kht@)RaMf>Yw-(T6rC(|AqjVPOgT`^QTkc<=H1-n(4-Q}bu^ zA2RA*_8#`!lkVZWq?F#iRZ4GM_tO7YN~v@S&YmfyH77@(Ty~P25|@siwAi&;FHaoH zFJ_lApoukm(*-50+m6r ziullBgEIh$A*R>x~XO-@**3FgX-6V)|WC?+HT1ThS3U7Uv) yy5B_CKRXj351DIFRBKbCI@r%x9uuajIAyfuLyr-o(llW?N&#Xznd9G|M%I@id9cF( literal 0 HcmV?d00001 diff --git a/openecomp-be/tools/swagger-ui/fonts/droid-sans-v6-latin-700.woff2 b/openecomp-be/tools/swagger-ui/fonts/droid-sans-v6-latin-700.woff2 new file mode 100644 index 0000000000000000000000000000000000000000..1e726a7cfce4130243a3de4bb2bd412000658896 GIT binary patch literal 11480 zcmV;}EGN@5Obdf300bZff@BASXB${fCF7WtxE&xs zRc*p3N+K!A{{LG79WsQXDWLODB*KIh(S&J+COQza7W2$AXQBRic7T|Nb()j#@Ctrj`j*A1nF zCwy1>G#Xh3Oq_5TDB!kVY4^&&dt3M`(6cPBI0A;>YNRE87t=(M$U+9fO29RGNnhdwDTbCnDS7~tuOI842pJbIXK>@ewn$%?og({_-m!TSJY+w zWy>R6%eGD~PVzI^j6NXw3xKnSv#n;0#%xZP6{@NeN>nLlF%@1VlvQAG0|I$a!R?fL`9hJie6K31-a!Pel>1KmkG^TFw4%S(&4d zi6X4Q>>E_Y(@aS<+FlF1dFMkXHRFCEA78EL2(e4{b@^2VHL7p*bL15<7Sb9MA1_1F z*EJYFGAp^B{F;iXivb$E2e127yyd6}WUz<;>1dh(#j` zyE$^A5)C2d#-*NJ2iDtQ+(r{&bGF!O+wAty&1}{R0-|U{VIPY;QH|c1a3)ETB-a{O zGFQjVEXu9LDHz*U?QmV#r;ZztbST!gjG@{@{NHP9dpp|Mu6B3r4tA)+9pQ>(YBg3k zYhxkyiQ{l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LtC}lK3qZ2z>lUz>@5co!J}fVh9k5f$J{q~^_beugs5?; zzC!z_*V-< zSjvg`8#ejf)R#}LP^#39PRsTvho_gfk1xy*?jI0{2tuOJm|$!O4lnav2n`F5 zh>VJkiH(a-Nc@Ta+nYkA(HTq@o5STL@skBYQHoe1mB|&UN>y4q5gD0TOTN*e(+L~A z>@uj&Rtu&R&iak{{AIwnwa(rDw9TU5e*OLbeuZB7b~m+VnD#$?J>8cs-?)11`m3BD zZhp5%?#B^7|M-*c&AT4?c?E^~q8*A$ORV9IP+3t`{ko>Ew!X1p*`(&C7OmdCKkC-) ydw2Fbz~Hd+2OV;u+exP!PxqocJf2Lmd{$+bm1~O2vTaUrWm$P;$!X3jE&~8Zn1K`k literal 0 HcmV?d00001 diff --git a/openecomp-be/tools/swagger-ui/fonts/droid-sans-v6-latin-regular.eot b/openecomp-be/tools/swagger-ui/fonts/droid-sans-v6-latin-regular.eot new file mode 100644 index 0000000000000000000000000000000000000000..ac2698e85aee584b0f47c0cccff8a8b9b16a5c66 GIT binary patch literal 22008 zcmZ^qRZJY-)3BGtVR3hNTio5FVS{--d2|12^b95ez95C{VWNP+?Y5CBSQe}RBK19E^E{eSWQ zNg)(~{C}1P(rfuY`+o%+AO&y-xB%<`mj7Xz05gCyz~esz6`%pI0@wh&0FM9p-2d}1 z19blLxc?Wm`;T}2k7ft30>J+%Il%ls&h9_*e>vFyQ_lbR|6gVRKtfYi?f+H*06+u2 zRsr})0V+BGmSxPDvzQ6f^)HjQitaA1Zj{;r=FDsv923fz#-h) z{H*jrO?;xb^zvtyVI5;9sUT2`KnE@{nfrUC4hl z()Hv{t$sUkY_@_+FGhbMp-@sjTz4vULZxPNx4O`2R2%gAt(s3Bfyr-Malq$Y&12u& zxezl)Z>RG;s*P!zJ_3GXHDLSvTg_WRQc!k>dyUqtVArJrq5VkN1Tmv+1YR;BS1C;# zQdlynGv~Bh4I4=(=B7^O{>60@Ec0s?fu=Dubk-8GEKYPHzM3+ju_E)ai&Z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xZD%?~>hIR?-`RXv4o{>K4b zmhZMxTpF8NQT9l6scJ9H0Tf~V{X;(<} zK$qppI>Ra+U9#4(2L-y7F%hi7XwFY=jp3piiu>AvT=IQjWY-ohDS<_`&YMeCO~aII zH&CY<@7h-coq&SG=H0bn9`KN#hqNT5!6e%q?sKzCpBgYs*B6lrt$aLOqTnPiHy#e= zXpwFYOp10}rW#_Ft4t>gu3Rx;MN%z3!?2BGoX2SOu?kQC*I6k4Wq?_?)uV)IZpWU9 M4w+BmWsNjR(0tp4%K!iX literal 0 HcmV?d00001 diff --git a/openecomp-be/tools/swagger-ui/fonts/droid-sans-v6-latin-regular.svg b/openecomp-be/tools/swagger-ui/fonts/droid-sans-v6-latin-regular.svg new file mode 100644 index 0000000000..d9f2a214f9 --- /dev/null +++ b/openecomp-be/tools/swagger-ui/fonts/droid-sans-v6-latin-regular.svg @@ -0,0 +1,403 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/openecomp-be/tools/swagger-ui/fonts/droid-sans-v6-latin-regular.ttf b/openecomp-be/tools/swagger-ui/fonts/droid-sans-v6-latin-regular.ttf new file mode 100644 index 0000000000000000000000000000000000000000..fb8cea662b2434571debae37fa6ba09fc5f24776 GIT binary patch literal 39069 zcmb4s2|$$Bwg0`}GW+t)zA-z)Fbps-0}RMAAD}QIvI(dtFe;+rf{JUbL1T^4Bvl(@ zjM;3Ordib_h8UYhjaj>7c{c6K%S#QfP4n7jv2D_3k>P*tH-iw9_kaICW|(2-&iCEr z+;e{Cch0#%7$KyAUku{vr_ZQE9Qrqec0UL28tYq{=ls2Eb`Sjh8-%py>gROSAOn&i zbm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)uD(R5Y{57WRdCDz8{CX{WfxYXaK+o?=wPHZuqq`|Z zBTK2J0X>j%z3&Q|7oc!CExjqoKCPtE0AxS5FC7k03hsgS?6qG>#{!{4uh@^Ui3sx7 zyH}p<>kvjCj1oEp_uhR#H+B`^O1+aG?xpvRX;L3C{BJ1_BoCK+O=)mdjv{2;c_m7H z)v1L@zfkleZL-H2LCx16eUhV!o;}ygZCa6KeUaqeQPt?H-GC97*+9Z#rLS;#v#gGcW>a6cE(qSeH}Ia`$kVd z_Q=$ryAU{S0VDD2ry0dl3>f7*L|>zWzD5UqjSk*=S>bO7ZBz$+j1I=~X4<+A+W!vP z{|?&!4%+_?+W!vPuMXP&4%+?>+WrpO{tnvy4qDgg;&tC9Vjn9&a4_9=ZK}-ZuE(Us=#{@joAj&y4^8 literal 0 HcmV?d00001 diff --git a/openecomp-be/tools/swagger-ui/fonts/droid-sans-v6-latin-regular.woff b/openecomp-be/tools/swagger-ui/fonts/droid-sans-v6-latin-regular.woff new file mode 100644 index 0000000000000000000000000000000000000000..abf19899f75a0e8ab8e2d41caeecd8d764d3f08c GIT binary patch literal 24868 zcmYhh18^tL_XQd!yRmIYNYh&BCZQHhOXXAWg8!zAA|Glc$Q)gz*slI)0&(zed z?mMn>qM|^+KtIiZ1PJlJYg*n9|DW<7`~NpFVG&UvAYi{A4eftG09p`}ms9%D(tv;< zNPvKl`tCGkbj6fZ1c87cyMFq>{12!=zvYzZ7=N^}AFlfY{k+9y6C)b~dmtbviXU$I zgD4vVvkfB`CxRa>>4)F{jQhdi!z*oSZ)O7o^eYSq2#ow^3~8E-4qy5+em-R$!hS?an{rJ_6`mrPU51ngae#hR<(Fq7hNBf6s{NSWu0G`XEb13RWIpglfW{;##5g`#$4Ar97Xe>dHO+F0rtibqS)#6v zUZwBf(KFH!``Y@yD=!DhX+qQ6$9zn5>I`dKODtQwUaMBtpSK4NAAIr8@gS28A1`_= z%@yw)E8UKIUx|+Th)v7VcMt07YoUPmSS9H%!7kat}Nx?faQ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CEX%f0Gc~C9$`TBfKXi4`aFFf+BxFkwLXkKceinob>>`qfxlzHb# z(dx&exUwoHHleE|S4wQ2%6U006M` zYumPsk#6A*)GqLe2>1m-oG%h0NhxU=Svh$HMI~hwRW)@DO)YI5T|IpRLnC7oQ!{f5 zODk&|TRVFPM<-_&S2uSLPcLtue?joD1qA>A0B|xtW^dWH?X|s|^|D=;Y}>Z^GSB(t zb2FM~s+s0mXsMOf+Gwkt_B!aOlg_&6s+;b5=&6_9`sk~l{stImkimu+YM9|h7-^Kz z#u#gy{kEBHjtkcMXs)Fe*86=srmwy`>!nxTd+n%WPCDhf<4(9?o{KIyU!!)tN;VM)wCmU)SB(@) zpzOO<@2n8+3X13)}zO8@`>cmW(w1B@J99G~BNyK~=Hy*>M08P#^@IJ?bh z%_L`AQEj_DE3Rj@+^CA#SjVWg{SJQ{siyybP{Gf9ANWr8d`96Xgv5)~#jj_X)Unkg zu2C`US}}qVP}ea1#aBE*!=v|)$e(+0e8qhf-rswlgv6uN4fk23`aB4(E!Px{=4%C7 zgGN)e$>?=k9Ou0Sy=1%xba6L$H_mnsc9WLw1Kq?J60cI@yZ@i5Y8?+d2wmI`-j0EG zt)1*_$8`2k`($?cdF6cmd765D7E_m>!@xNlIUL7RcUpH6YHFR^x}uemR(xv3j0T7X zTxmc@1KJu6HIVEE%&3Q`$CY|?)FZndasuL9@sWau83dQ9;7SE}#qtWJLR1)1%dO>u z<$Ae6DFZ9h%7}5Wbi9<%sVDPGAs0B z#)AN0AO?Yni+aG*BjTw4?wLIR7-ZIIZEh>n+szdD|F&J;xR83NVY3uT8*NNBAc;A8 X8CoUMY*lMRVpH6ur?CLJX!hLz`Fb1d literal 0 HcmV?d00001 diff --git a/openecomp-be/tools/swagger-ui/fonts/droid-sans-v6-latin-regular.woff2 b/openecomp-be/tools/swagger-ui/fonts/droid-sans-v6-latin-regular.woff2 new file mode 100644 index 0000000000000000000000000000000000000000..9f93f74c3bede4b96290650f7a21c98eb1e01351 GIT binary patch liter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>146Md_>R4 z!u>5=`S7V-{`@gg{jH0pRsZ@@;|b7t{*f zTxxn`=nE2*h096my`sWG+naqon#T~4vN7~vRwkGeKFKQTn7Gpb#{>j0dA#mRARJ%a zzQol{v#Om+O-=2%Fv0Y~gGy)vpM9AqW9XL-=oW^Z+x!S}SI}|@5c!VDmi8ewHa32K z)2@4CYr*}RgtUqVY|*H5EK)9Yu1|M2cZT!b(=1Utg1JZn<5dsm`yYj9Kkf^8yy3Yg zaE2*7UHxoOBAFG*y(CvR16B7+A@%d?g9?C&`Q9QHOLfg~5%voT$!GCxQ={S`LnT7m zpg{#8H_#n38oZ3kLmMqPoCfi#4cZr3v=TwI z1!Z3QHIc@&M_)oMjgD`H_HAu{c<?!IOz=bkOm7%z z4W?M!@dLv%rtxc$2caN+9%|ypiut<#UBz{-mP^nFUnJ6D&G@&JOkG7sxm3|I0!Xp` zO#aBOcHBu+p6xL2bsPfr_{Sy&gg@nz1DTThd-LL0lm*;3S!&>5M)5rJSK{u-3>*QsSd9TCi=W z^jBhA2T?~}Hq+d9A|%a(S|i??&!N{Ax0QJ}`e|9Md_V0@HRO}XJOWd!YKiAXJ1cve z6AsPFs91vGZ%2y`PBYqgjH(`b?;@eqUmdDe$l9aRx2uVk33`-UfZqGJ8SqJM# zl|}kEH%KP?w{aMmwfg9I^d&9{hh{t?-#2g9-EG{M{;a#pOxb8uZdf+Qa-!dB98WV^ zZev=N>|1Tnkqtdfor;+pIAUWMOg(>@sZ_cj+1;L(C%zw=_eAR6qDkyxds3sbb!`Qq z#FSJgE$bd7H!girtmrzJEu5=0!c j9;CNtxH7ifUPA5%K$9x5f6##bPEh|I%Ktq64_M$Y9Er-S literal 0 HcmV?d00001 diff --git a/openecomp-be/tools/swagger-ui/images/explorer_icons.png b/openecomp-be/tools/swagger-ui/images/explorer_icons.png new file mode 100644 index 0000000000000000000000000000000000000000..ed9d2fffb64a2e6e282b90e489d83fc4ddfac3cd GIT binary patch literal 5763 zcmZ{mbyU<(_s2g-OG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Z%4>8(W#wYqhSwb{^F1i1co+>ms!v9G((c|!6!Br*$KF7Lq(dCUz-WoSDnG~5`*r0M&3~wpxl8`$St;*iTWaKbDB-3v1JC{?23TYCT+R3eoNkmKI(o=Rp`f)hrV_4LBw#sF|Recbj>QtxPq2*gb(r6~X`+j^eNEDye(y-YTjI+DCs z$B#LA)cuuuN6U~VwE=0{mIr0`PZ(jcxfC}#UeFtuFC+E_zR}(BlI>iYaU%@M?z3&n zBNggSED_Q7+V;AGjDEgeCh+FdHN1^M05;N5qKWsqf*uLt>i4zjBCtZMV#nMr6WB4c z=vr0rzOeQVz^{X9P8HnlY`af#YlZq#=Q&Y*mYv-!2tkEbO*WU}SLO$uZ4a1R9AR^7 z6;RFc;6DPCDr6%-kgPMrx$=&Vurh2 zAIb#ob$uk3m;u1$Y^S|3XbKoB8KkAbSF@dL|HmLb?4IMCqjgA=+Ca%DtEpsWDL8I~ z*+@r^B)gnmZuuu^aI{7!9pw^{XDGWbnwZHi)7EOyFke#$uRCZW#IQgfT&B|c_c~(; fcq^qAFU9`_7RU2E7DPsA00000NkvXXu0mjf!rmha literal 0 HcmV?d00001 diff --git a/openecomp-be/tools/swagger-ui/images/favicon-32x32.png b/openecomp-be/tools/swagger-ui/images/favicon-32x32.png new file mode 100644 index 0000000000000000000000000000000000000000..32f319f89bd07e691de2ccaf21632bb9793a9cd9 GIT binary patch literal 1654 zcmV-+28sEJP)Z zYjBlU6^5U+_c^%{LI@BBNTw~6nu{hdI!rrEwGFgm#aci_3sGk}<7m?sf9eb^ z&gef46cL=-R%Vz2t>aV&tTwa+k{T7cTawZs4M`*flAN4x@8yqkX_Av0()aswzFB*( z_g(v2XYI9wX~KJNyap8@D?yj3`UN7k2td_e5i#!rt)NGYgj$R-e!9LVh4Vp9;GzxA zMK7v)oerFfUJTsuv(5*(Q~8(4BX%1_Ls=xV0tMmqzMUI4PvXOov* zN@+ngMR`jQiMjRax>fZ#BX;*hCo--8?_I7}_iH1eH6lVJdXsn0?&9d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nc@KSJTfS+;@4SL}@UgYJ}w)Q)V=$7{=rRQ;RAgzi>VS}wfAf#wGK z2d~@`@yyISSY5T9%ChzGtaqnG%mc=liQDoKB63yzUJ+Xt8%%ES&Y7Jwo!-IKzH^fj z=jW7BTfT+b^39}&XT}GU;0+^o{j>&?k41Rn)ol`yZ6ims&fdS%-gS)L{`TapmX$u6 zyqTqx=2ufZ=iU*cneSC~&lw5r`oD)&=Y!n94L=*WXvefB)7Ws@5xC*4w>6xOb0Q(H zL4_bI75%KLUtq)*#v*lBL~MLK=dE~!3#Q}ufBOd*=m{K;N&o-=07*qoM6N<$g6kDD A00000 literal 0 HcmV?d00001 diff --git a/openecomp-be/tools/swagger-ui/images/favicon.ico b/openecomp-be/tools/swagger-ui/images/favicon.ico new file mode 100644 index 0000000000000000000000000000000000000000..36c02749fc35ea81f64db36be809972c795b5298 GIT binary patch literal 1150 zcmds#yGjF55Qaw-#Lmh#mOg-BCH5w$!CT@ri7|;mML{i;;5IgC1PdEQ!A=n?u{GIj zF1y*Yxjul8U?bR#GZWVY5iA80CTGs_2|eCz_tq7qMJkKtuPTS)4($G>h5HI2ySL@yluvZD$otD~zY<6uNsL_SmT>(5c5! zRU=p`Ok=4yjm5kl^{iL4%63bec~uFMP6%(VcSVEvH>Vb-*a}+aywqYom-V4VJqT+r zNN>!lYE(4XC-#Y~p{i?WS%H?B0jXaq_=Vw_Y_*I|Ek;~O>aeD*mYA0wt}gc4{HG4j zRB3EtrOCF1)#kR$$G!8MhVErP)3Jv~%LYh>Io*B9ej7>BO3Gfd&$G;GohAgw$Gz0g`yXE<>FZYEbw(mR3 zcZz#j^HJaQPTabx#`hSr2S0J0G0GXeyWK@avogo;=HY&a*;HrVZ+>3SjF26X&Ha}9 im(P*@L9S`t09seO8;#ry-Cx*x0bV@-?_=$J<~{&hLxwH@ literal 0 HcmV?d00001 diff --git a/openecomp-be/tools/swagger-ui/images/logo_small.png b/openecomp-be/tools/swagger-ui/images/logo_small.png new file mode 100644 index 0000000000000000000000000000000000000000..5496a65579ae903d4008f9d268fac422ef9d3679 GIT binary patch literal 770 zcmV+d1O5DoP)K11rQipnJ)eVnTSzHNF zN8ab&RhE5cC$$4FI-PZXx$pga@8yN)KS}L2Us~^y$(x-xioWbnFcV+~b9ig=!ft8Q z0RD+rpA8910Smyc0GviVUOPGiY6YM@-r6Nn8S&~cxHl27$l)-R$1(!Xx045RDy;_& zeXkG{;_#i9rz0B6149#Ddj=KM6MV^rTD%ylzGdCBX<^=^@I0X3SCR7OMbn}sUKdeF zKO-flaJa%@kJ27@Rod?J9=+Qx5|=PtG8n> zy~9rIu}+48M}FW5Bbqw3t#po?c?kmG!FX32W(dOjzTb+U@64MzHItoeB!M0Jcd}|E z>ekW`<~FjR_ZVVJkF|_htH&v!({Oad?xax?0K0sLwBY%nr46DpCmIIaa?@|Y&?n0q z@kJlMy`pE2HtEgASNd~xNzt$Kn7w#^Fy5oi`e$bUE*+f>Vk5z7=-2pj68afrqli$_ zvqe##5V?a)QU_-s9+s?mJYT5m`MQDRH4cYs^L1lCW;Dua5Ln9lG0BC@9DJQHA(}y&Z}$apb{kU zbezR}b^|O%6i+$BFsT3zqAe8wg9`vfiRp#{)z2bsJw`vBQL7Bt!IexM3$Hsf0tHK3 z+R=x{lR$K`s;7__?ASPW=3?*xgCpGaiadSEpoi0pw-_V#OXM8Ap{4qlG08x0ig9IY z3Ijqh(t1_=g#jocuqyJO=729e9OSiNDSrhR0Gc5G)(QGH?*IS*07*qoM6N<$f<~fU A82|tP literal 0 HcmV?d00001 diff --git a/openecomp-be/tools/swagger-ui/images/pet_store_api.png b/openecomp-be/tools/swagger-ui/images/pet_store_api.png new file mode 100644 index 0000000000000000000000000000000000000000..f9f9cd4aeb35a108c4b2f1dddb59977d56c595d8 GIT binary patch literal 824 zcmV-81IPS{P)n=Rd;8mVwQNY4k4xJQ%YT}s;WA7;r!W@XgqjG_4og} z8w>{OB9REiMa8-B85td+y}bji^~2KA`Md4j-u{zw=H%Da@83%_8q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P?cB4?KRdvj&>@zN_HP5m0E=+A=efDBI*IG*Gy%%< zz@yc%2XvGm)QQv5k^ZC6!9MwX8BCmQ{3eAX|GTwn#>(PS6PoB=$Pwn*?wz?%Tx2gwJ4apoy`A15D=>?%}hj`fV*p=6XW=YR(sp))`dxTnqHE&{&; zPdeO}SVkf*6_$c45W3Z}u|Z&a8{r!6ZNY62S>5{jAd)Hkjg@h%@c)c#BvZK2lmGw| z`Vh+%ECkF{t=)XpF3Z1bj=Pe9LpHbnQwjeTU#=4hB76#52DU2P2Ouj~^lRWwRd%eN zBw_z%FL0CUlk!`s2!`>QG&H__i_)I9=AuA=jn40z>;@hRsg)>J(58cx;l;h_zE*-R7Wbz6Ff#1Mss*)zTImU4`2@?a7y;v4 zH=lJ_PM5Rkw*AU`Cmq6aa>chASJ&Z3Ebj`y;w$MM!fa6`13VU7Kc|T5Xl#7ecj?mp zREV-nBJ6C)`?&}QDe_(KM>BrlN|iF{7-90j+J>N0^vY=LK;8!^9Y_m*aRPX{!S6ag zgRw(13pJvt`;{^S-vgUk?8pV_Vh4a4P7~}uHT)ENFMqd71QIOl8Q6+24TM_+158z) z54U-*C{M)S&!2Bfu&`?Ti6;WojY;%6+I;uCof+*T2iUMz!7Eg<{}#DJSx)C$5f zP(oSf>_s1t06cJ-U3?<9poS4O{Go>H>hro^ks;r3mm1Ehfq?m(_YE8UiVUgG%W9ZY z!@O^}KR%JW*0e=66rUYj5BP~=x%$^x92-m_ + + + + API Docs + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

+ +
+ +
Custom Headers
+
+ +
+
+ Reset + Add +
+ +
+
 
+
+ + diff --git a/openecomp-be/tools/swagger-ui/lang/en.js b/openecomp-be/tools/swagger-ui/lang/en.js new file mode 100644 index 0000000000..9ed12ccffb --- /dev/null +++ b/openecomp-be/tools/swagger-ui/lang/en.js @@ -0,0 +1,73 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +'use strict'; + +/* jshint quotmark: double */ +window.SwaggerTranslator.learn({ + "Warning: Deprecated":"Warning: Deprecated", + "Implementation Notes":"Implementation Notes", + "Response Class":"Response Class", + "Status":"Status", + "Parameters":"Parameters", + "Parameter":"Parameter", + "Value":"Value", + "Description":"Description", + "Parameter Type":"Parameter Type", + "Data Type":"Data Type", + "Response Messages":"Response Messages", + "HTTP Status Code":"HTTP Status Code", + "Reason":"Reason", + "Response Model":"Response Model", + "Request URL":"Request URL", + "Response Body":"Response Body", + "Response Code":"Response Code", + "Response Headers":"Response Headers", + "Hide Response":"Hide Response", + "Headers":"Headers", + "Try it out!":"Try it out!", + "Show/Hide":"Show/Hide", + "List Operations":"List Operations", + "Expand Operations":"Expand Operations", + "Raw":"Raw", + "can't parse JSON. Raw result":"can't parse JSON. Raw result", + "Model Schema":"Model Schema", + "Model":"Model", + "apply":"apply", + "Username":"Username", + "Password":"Password", + "Terms of service":"Terms of service", + "Created by":"Created by", + "See more at":"See more at", + "Contact the developer":"Contact the developer", + "api version":"api version", + "Response Content Type":"Response Content Type", + "fetching resource":"fetching resource", + "fetching resource list":"fetching resource list", + "Explore":"Explore", + "Show Swagger Petstore Example Apis":"Show Swagger Petstore Example Apis", + "Can't read from server. It may not have the appropriate access-control-origin settings.":"Can't read from server. It may not have the appropriate access-control-origin settings.", + "Please specify the protocol for":"Please specify the protocol for", + "Can't read swagger JSON from":"Can't read swagger JSON from", + "Finished Loading Resource Information. Rendering Swagger UI":"Finished Loading Resource Information. Rendering Swagger UI", + "Unable to read api":"Unable to read api", + "from path":"from path", + "server returned":"server returned" +}); diff --git a/openecomp-be/tools/swagger-ui/lang/es.js b/openecomp-be/tools/swagger-ui/lang/es.js new file mode 100644 index 0000000000..bd948fc27b --- /dev/null +++ b/openecomp-be/tools/swagger-ui/lang/es.js @@ -0,0 +1,72 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +'use strict'; + +/* jshint quotmark: double */ +window.SwaggerTranslator.learn({ + "Warning: Deprecated":"Advertencia: Obsoleto", + "Implementation Notes":"Notas de implementación", + "Response Class":"Clase de la Respuesta", + "Status":"Status", + "Parameters":"Parámetros", + "Parameter":"Parámetro", + "Value":"Valor", + "Description":"Descripción", + "Parameter Type":"Tipo del Parámetro", + "Data Type":"Tipo del Dato", + "Response Messages":"Mensajes de la Respuesta", + "HTTP Status Code":"Código de Status HTTP", + "Reason":"Razón", + "Response Model":"Modelo de la Respuesta", + "Request URL":"URL de la Solicitud", + "Response Body":"Cuerpo de la Respuesta", + "Response Code":"Código de la Respuesta", + "Response Headers":"Encabezados de la Respuesta", + "Hide Response":"Ocultar Respuesta", + "Try it out!":"Pruébalo!", + "Show/Hide":"Mostrar/Ocultar", + "List Operations":"Listar Operaciones", + "Expand Operations":"Expandir Operaciones", + "Raw":"Crudo", + "can't parse JSON. Raw result":"no puede parsear el JSON. Resultado crudo", + "Model Schema":"Esquema del Modelo", + "Model":"Modelo", + "apply":"aplicar", + "Username":"Nombre de usuario", + "Password":"Contraseña", + "Terms of service":"Términos de Servicio", + "Created by":"Creado por", + "See more at":"Ver más en", + "Contact the developer":"Contactar al desarrollador", + "api version":"versión de la api", + "Response Content Type":"Tipo de Contenido (Content Type) de la Respuesta", + "fetching resource":"buscando recurso", + "fetching resource list":"buscando lista del recurso", + "Explore":"Explorar", + "Show Swagger Petstore Example Apis":"Mostrar Api Ejemplo de Swagger Petstore", + "Can't read from server. It may not have the appropriate access-control-origin settings.":"No se puede leer del servidor. Tal vez no tiene la configuración de control de acceso de origen (access-control-origin) apropiado.", + "Please specify the protocol for":"Por favor, especificar el protocola para", + "Can't read swagger JSON from":"No se puede leer el JSON de swagger desde", + "Finished Loading Resource Information. Rendering Swagger UI":"Finalizada la carga del recurso de Información. Mostrando Swagger UI", + "Unable to read api":"No se puede leer la api", + "from path":"desde ruta", + "server returned":"el servidor retornó" +}); diff --git a/openecomp-be/tools/swagger-ui/lang/ja.js b/openecomp-be/tools/swagger-ui/lang/ja.js new file mode 100644 index 0000000000..895353c525 --- /dev/null +++ b/openecomp-be/tools/swagger-ui/lang/ja.js @@ -0,0 +1,73 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +'use strict'; + +/* jshint quotmark: double */ +window.SwaggerTranslator.learn({ + "Warning: Deprecated":"警告: 廃止予定", + "Implementation Notes":"実装メモ", + "Response Class":"レス�?ンスクラス", + "Status":"ステータス", + "Parameters":"パラメータ群", + "Parameter":"パラメータ", + "Value":"値", + "Description":"説明", + "Parameter Type":"パラメータタイプ", + "Data Type":"データタイプ", + "Response Messages":"レス�?ンスメッセージ", + "HTTP Status Code":"HTTPステータスコード", + "Reason":"�?�由", + "Response Model":"レス�?ンスモデル", + "Request URL":"リクエストURL", + "Response Body":"レス�?ンスボディ", + "Response Code":"レス�?ンスコード", + "Response Headers":"レス�?ンスヘッダ", + "Hide Response":"レス�?ンスを隠�?�", + "Headers":"ヘッダ", + "Try it out!":"実際�?�実行!", + "Show/Hide":"表示/�?�表示", + "List Operations":"�?作一覧", + "Expand Operations":"�?作�?�展開", + "Raw":"Raw", + "can't parse JSON. Raw result":"JSON�?�解釈�?��??�?��?�ん. 未加工�?��?果", + "Model Schema":"モデルスキーマ", + "Model":"モデル", + "apply":"実行", + "Username":"ユーザ�??", + "Password":"パスワード", + "Terms of service":"サービス利用�?約", + "Created by":"Created by", + "See more at":"See more at", + "Contact the developer":"開発者�?�連絡", + "api version":"API�?ージョン", + "Response Content Type":"レス�?ンス コンテンツタイプ", + "fetching resource":"リソース�?��?�得", + "fetching resource list":"リソース一覧�?��?�得", + "Explore":"Explore", + "Show Swagger Petstore Example Apis":"SwaggerペットストアAPI�?�表示", + "Can't read from server. It may not have the appropriate access-control-origin settings.":"サー�?�?�ら読�?�込�?�?��?�ん. �?�切�?�access-control-origin設定を�?�?��?��?��?��?��?�能性�?��?�り�?��?�.", + "Please specify the protocol for":"プロトコルを指定�?��?��??�?��?��?�", + "Can't read swagger JSON from":"次�?�らswagger JSONを読�?�込�?�?��?�ん", + "Finished Loading Resource Information. Rendering Swagger UI":"リソース情報�?�読�?�込�?��?�完了�?��?��?��?�. Swagger UIを�??画�?��?��?��?��?�", + "Unable to read api":"APIを読�?�込�?�?��?�ん", + "from path":"次�?�パス�?�ら", + "server returned":"サー�?�?�ら�?�返答" +}); diff --git a/openecomp-be/tools/swagger-ui/lang/pt.js b/openecomp-be/tools/swagger-ui/lang/pt.js new file mode 100644 index 0000000000..a74b4a3d01 --- /dev/null +++ b/openecomp-be/tools/swagger-ui/lang/pt.js @@ -0,0 +1,73 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +'use strict'; + +/* jshint quotmark: double */ +window.SwaggerTranslator.learn({ + "Warning: Deprecated":"Aviso: Depreciado", + "Implementation Notes":"Notas de Implementação", + "Response Class":"Classe de resposta", + "Status":"Status", + "Parameters":"Parâmetros", + "Parameter":"Parâmetro", + "Value":"Valor", + "Description":"Descrição", + "Parameter Type":"Tipo de parâmetro", + "Data Type":"Tipo de dados", + "Response Messages":"Mensagens de resposta", + "HTTP Status Code":"Código de status HTTP", + "Reason":"Razão", + "Response Model":"Modelo resposta", + "Request URL":"URL requisição", + "Response Body":"Corpo da resposta", + "Response Code":"Código da resposta", + "Response Headers":"Cabeçalho da resposta", + "Headers":"Cabeçalhos", + "Hide Response":"Esconder resposta", + "Try it out!":"Tente agora!", + "Show/Hide":"Mostrar/Esconder", + "List Operations":"Listar operações", + "Expand Operations":"Expandir operações", + "Raw":"Cru", + "can't parse JSON. Raw result":"Falha ao analisar JSON. Resulto cru", + "Model Schema":"Modelo esquema", + "Model":"Modelo", + "apply":"Aplicar", + "Username":"Usuário", + "Password":"Senha", + "Terms of service":"Termos do serviço", + "Created by":"Criado por", + "See more at":"Veja mais em", + "Contact the developer":"Contate o desenvolvedor", + "api version":"Versão api", + "Response Content Type":"Tipo de conteúdo da resposta", + "fetching resource":"busca recurso", + "fetching resource list":"buscando lista de recursos", + "Explore":"Explorar", + "Show Swagger Petstore Example Apis":"Show Swagger Petstore Example Apis", + "Can't read from server. It may not have the appropriate access-control-origin settings.":"Não é possível ler do servidor. Pode não ter as apropriadas configurações access-control-origin", + "Please specify the protocol for":"Por favor especifique o protocolo", + "Can't read swagger JSON from":"Não é possível ler o JSON Swagger de", + "Finished Loading Resource Information. Rendering Swagger UI":"Carregar informação de recurso finalizada. Renderizando Swagger UI", + "Unable to read api":"Não foi possível ler api", + "from path":"do caminho", + "server returned":"servidor retornou" +}); diff --git a/openecomp-be/tools/swagger-ui/lang/ru.js b/openecomp-be/tools/swagger-ui/lang/ru.js new file mode 100644 index 0000000000..ce117fd84e --- /dev/null +++ b/openecomp-be/tools/swagger-ui/lang/ru.js @@ -0,0 +1,72 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +'use strict'; + +/* jshint quotmark: double */ +window.SwaggerTranslator.learn({ + "Warning: Deprecated":"Ворнинг: Депрекейтед", + "Implementation Notes":"Заметки", + "Response Class":"Пример ответа", + "Status":"Стату�?", + "Parameters":"Параметры", + "Parameter":"Параметр", + "Value":"Значение", + "Description":"Опи�?ание", + "Parameter Type":"Тип параметра", + "Data Type":"Тип данных", + "HTTP Status Code":"HTTP код", + "Reason":"Причина", + "Response Model":"Структура ответа", + "Request URL":"URL запро�?а", + "Response Body":"Тело ответа", + "Response Code":"HTTP код ответа", + "Response Headers":"Заголовки ответа", + "Hide Response":"Спр�?тать ответ", + "Response Messages":"Что может прийти в ответ", + "Try it out!":"Попробовать!", + "Show/Hide":"Показать/Скрыть", + "List Operations":"Операции кратко", + "Expand Operations":"Операции подробно", + "Raw":"В �?ыром виде", + "can't parse JSON. Raw result":"�?е удает�?�? ра�?пар�?ить ответ:", + "Model Schema":"Структура", + "Model":"Опи�?ание", + "apply":"применить", + "Username":"Им�? пользовател�?", + "Password":"Пароль", + "Terms of service":"У�?лови�? и�?пользовани�?", + "Created by":"Разработано", + "See more at":"Еще тут", + "Contact the developer":"Св�?зать�?�? �? разработчиком", + "api version":"Вер�?и�? API", + "Response Content Type":"Content Type ответа", + "fetching resource":"Получение ре�?ур�?а", + "fetching resource list":"Получение ре�?ур�?ов", + "Explore":"Поехали", + "Show Swagger Petstore Example Apis":"Показать примеры �?ПИ", + "Can't read from server. It may not have the appropriate access-control-origin settings.":"�?е удает�?�? получить ответ от �?ервера. Возможно, кака�?-то лажа �? на�?тройками до�?тупа", + "Please specify the protocol for":"Пожалуй�?та, укажите протогол дл�?", + "Can't read swagger JSON from":"�?е получает�?�? прочитать swagger json из", + "Finished Loading Resource Information. Rendering Swagger UI":"Загрузка информации о ре�?ур�?ах завершена. Рендерим", + "Unable to read api":"�?е удало�?ь прочитать api", + "from path":"по адре�?у", + "server returned":"�?ервер �?казал" +}); diff --git a/openecomp-be/tools/swagger-ui/lang/tr.js b/openecomp-be/tools/swagger-ui/lang/tr.js new file mode 100644 index 0000000000..359583e4b4 --- /dev/null +++ b/openecomp-be/tools/swagger-ui/lang/tr.js @@ -0,0 +1,73 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +'use strict'; + +/* jshint quotmark: double */ +window.SwaggerTranslator.learn({ + "Warning: Deprecated":"Uyarı: Deprecated", + "Implementation Notes":"Gerçekleştirim Notları", + "Response Class":"Dönen Sınıf", + "Status":"Statü", + "Parameters":"Parametreler", + "Parameter":"Parametre", + "Value":"Değer", + "Description":"Açıklama", + "Parameter Type":"Parametre Tipi", + "Data Type":"Veri Tipi", + "Response Messages":"Dönüş Mesajı", + "HTTP Status Code":"HTTP Statü Kodu", + "Reason":"Gerekçe", + "Response Model":"Dönüş Modeli", + "Request URL":"İstek URL", + "Response Body":"Dönüş İçeriği", + "Response Code":"Dönüş Kodu", + "Response Headers":"Dönüş Üst Bilgileri", + "Hide Response":"Dönüşü Gizle", + "Headers":"Üst Bilgiler", + "Try it out!":"Dene!", + "Show/Hide":"Göster/Gizle", + "List Operations":"Operasyonları Listele", + "Expand Operations":"Operasyonları Aç", + "Raw":"Ham", + "can't parse JSON. Raw result":"JSON çözümlenemiyor. Ham sonuç", + "Model Schema":"Model Şema", + "Model":"Model", + "apply":"uygula", + "Username":"Kullanıcı Adı", + "Password":"Parola", + "Terms of service":"Servis şartları", + "Created by":"Oluşturan", + "See more at":"Daha fazlası için", + "Contact the developer":"Geliştirici ile İletişime Geçin", + "api version":"api versiyon", + "Response Content Type":"Dönüş İçerik Tipi", + "fetching resource":"kaynak getiriliyor", + "fetching resource list":"kaynak listesi getiriliyor", + "Explore":"Keşfet", + "Show Swagger Petstore Example Apis":"Swagger Petstore Örnek Api'yi Gör", + "Can't read from server. It may not have the appropriate access-control-origin settings.":"Sunucudan okuma yapılamıyor. Sunucu access-control-origin ayarlarınızı kontrol edin.", + "Please specify the protocol for":"Lütfen istenen adres için protokol belirtiniz", + "Can't read swagger JSON from":"Swagger JSON bu kaynaktan okunamıyor", + "Finished Loading Resource Information. Rendering Swagger UI":"Kaynak baglantısı tamamlandı. Swagger UI gösterime hazırlanıyor", + "Unable to read api":"api okunamadı", + "from path":"yoldan", + "server returned":"sunucuya dönüldü" +}); diff --git a/openecomp-be/tools/swagger-ui/lang/translator.js b/openecomp-be/tools/swagger-ui/lang/translator.js new file mode 100644 index 0000000000..9232ac18a6 --- /dev/null +++ b/openecomp-be/tools/swagger-ui/lang/translator.js @@ -0,0 +1,59 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +'use strict'; + +/** + * Translator for documentation pages. + * + * To enable translation you should include one of language-files in your index.html + * after . + * For example - + * + * If you wish to translate some new texsts you should do two things: + * 1. Add a new phrase pair ("New Phrase": "New Translation") into your language file (for example lang/ru.js). It will be great if you add it in other language files too. + * 2. Mark that text it templates this way New Phrase or . + * The main thing here is attribute data-sw-translate. Only inner html, title-attribute and value-attribute are going to translate. + * + */ +window.SwaggerTranslator = { + + _words:[], + + translate: function(sel) { + var $this = this; + sel = sel || '[data-sw-translate]'; + + $(sel).each(function() { + $(this).html($this._tryTranslate($(this).html())); + + $(this).val($this._tryTranslate($(this).val())); + $(this).attr('title', $this._tryTranslate($(this).attr('title'))); + }); + }, + + _tryTranslate: function(word) { + return this._words[$.trim(word)] !== undefined ? this._words[$.trim(word)] : word; + }, + + learn: function(wordsMap) { + this._words = wordsMap; + } +}; diff --git a/openecomp-be/tools/swagger-ui/lang/zh-cn.js b/openecomp-be/tools/swagger-ui/lang/zh-cn.js new file mode 100644 index 0000000000..e1fde6e7cc --- /dev/null +++ b/openecomp-be/tools/swagger-ui/lang/zh-cn.js @@ -0,0 +1,73 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +'use strict'; + +/* jshint quotmark: double */ +window.SwaggerTranslator.learn({ + "Warning: Deprecated":"警告:已过时", + "Implementation Notes":"实现备注", + "Response Class":"�?应类", + "Status":"状�?", + "Parameters":"�?�数", + "Parameter":"�?�数", + "Value":"值", + "Description":"�??述", + "Parameter Type":"�?�数类型", + "Data Type":"数�?�类型", + "Response Messages":"�?应消�?�", + "HTTP Status Code":"HTTP状�?�?", + "Reason":"原因", + "Response Model":"�?应模型", + "Request URL":"请求URL", + "Response Body":"�?应体", + "Response Code":"�?应�?", + "Response Headers":"�?应头", + "Hide Response":"�?�?�?应", + "Headers":"头", + "Try it out!":"试一下�?", + "Show/Hide":"显示/�?�?", + "List Operations":"显示�?作", + "Expand Operations":"展开�?作", + "Raw":"原始", + "can't parse JSON. Raw result":"无法解�?JSON. 原始结果", + "Model Schema":"模型架构", + "Model":"模型", + "apply":"应用", + "Username":"用户�??", + "Password":"密�?", + "Terms of service":"�?务�?�款", + "Created by":"创建者", + "See more at":"查看更多:", + "Contact the developer":"�?�系开�?�者", + "api version":"api版本", + "Response Content Type":"�?应Content Type", + "fetching resource":"正在获�?�资�?", + "fetching resource list":"正在获�?�资�?列表", + "Explore":"�?览", + "Show Swagger Petstore Example Apis":"显示 Swagger Petstore 示例 Apis", + "Can't read from server. It may not have the appropriate access-control-origin settings.":"无法从�?务器读�?�。�?�能没有正确设置access-control-origin。", + "Please specify the protocol for":"请指定�??议:", + "Can't read swagger JSON from":"无法读�?�swagger JSON于", + "Finished Loading Resource Information. Rendering Swagger UI":"已加载资�?信�?�。正在渲染Swagger UI", + "Unable to read api":"无法读�?�api", + "from path":"从路径", + "server returned":"�?务器返回" +}); diff --git a/openecomp-be/tools/swagger-ui/lib/backbone-min.js b/openecomp-be/tools/swagger-ui/lib/backbone-min.js new file mode 100644 index 0000000000..f082fcffca --- /dev/null +++ b/openecomp-be/tools/swagger-ui/lib/backbone-min.js @@ -0,0 +1,35 @@ +/*- + * ============LICENSE_START======================================================= + * SDC + * ================================================================================ + * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ============LICENSE_END========================================================= + */ + +// Backbone.js 1.1.2 + +(function(t,e){if(typeof define==="function"&&define.amd){define(["underscore","jquery","exports"],function(i,r,s){t.Backbone=e(t,s,i,r)})}else if(typeof exports!=="undefined"){var i=require("underscore");e(t,exports,i)}else{t.Backbone=e(t,{},t._,t.jQuery||t.Zepto||t.ender||t.$)}})(this,function(t,e,i,r){var s=t.Backbone;var n=[];var a=n.push;var o=n.slice;var h=n.splice;e.VERSION="1.1.2";e.$=r;e.noConflict=function(){t.Backbone=s;return this};e.emulateHTTP=false;e.emulateJSON=false;var u=e.Events={on:function(t,e,i){if(!c(this,"on",t,[e,i])||!e)return this;this._events||(this._events={});var r=this._events[t]||(this._events[t]=[]);r.push({callback:e,context:i,ctx:i||this});return this},once:function(t,e,r){if(!c(this,"once",t,[e,r])||!e)return this;var s=this;var n=i.once(function(){s.off(t,n);e.apply(this,arguments)});n._callback=e;return this.on(t,n,r)},off:function(t,e,r){var s,n,a,o,h,u,l,f;if(!this._events||!c(this,"off",t,[e,r]))return this;if(!t&&!e&&!r){this._events=void 0;return this}o=t?[t]:i.keys(this._events);for(h=0,u=o.length;h").attr(t);this.setElement(r,false)}else{this.setElement(i.result(this,"el"),false)}}});e.sync=function(t,r,s){var n=T[t];i.defaults(s||(s={}),{emulateHTTP:e.emulateHTTP,emulateJSON:e.emulateJSON});var a={type:n,dataType:"json"};if(!s.url){a.url=i.result(r,"url")||M()}if(s.data==null&&r&&(t==="create"||t==="update"||t==="patch")){a.contentType="application/json";a.data=JSON.stringify(s.attrs||r.toJSON(s))}if(s.emulateJSON){a.contentType="application/x-www-form-urlencoded";a.data=a.data?{model:a.data}:{}}if(s.emulateHTTP&&(n==="PUT"||n==="DELETE"||n==="PATCH")){a.type="POST";if(s.emulateJSON)a.data._method=n;var o=s.beforeSend;s.beforeSend=function(t){t.setRequestHeader("X-HTTP-Method-Override",n);if(o)return o.apply(this,arguments)}}if(a.type!=="GET"&&!s.emulateJSON){a.processData=false}if(a.type==="PATCH"&&k){a.xhr=function(){return new ActiveXObject("Microsoft.XMLHTTP")}}var h=s.xhr=e.ajax(i.extend(a,s));r.trigger("request",r,h,s);return h};var k=typeof window!=="undefined"&&!!window.ActiveXObject&&!(window.XMLHttpRequest&&(new XMLHttpRequest).dispatchEvent);var T={create:"POST",update:"PUT",patch:"PATCH","delete":"DELETE",read:"GET"};e.ajax=function(){return e.$.ajax.apply(e.$,arguments)};var $=e.Router=function(t){t||(t={});if(t.routes)this.routes=t.routes;this._bindRoutes();this.initialize.apply(this,arguments)};var S=/\((.*?)\)/g;var H=/(\(\?)?:\w+/g;var A=/\*\w+/g;var I=/[\-{}\[\]+?.,\\\^$|#\s]/g;i.extend($.prototype,u,{initialize:function(){},route:function(t,r,s){if(!i.isRegExp(t))t=this._routeToRegExp(t);if(i.isFunction(r)){s=r;r=""}if(!s)s=this[r];var n=this;e.history.route(t,function(i){var a=n._extractParameters(t,i);n.execute(s,a);n.trigger.apply(n,["route:"+r].concat(a));n.trigger("route",r,a);e.history.trigger("route",n,r,a)});return this},execute:function(t,e){if(t)t.apply(this,e)},navigate:function(t,i){e.history.navigate(t,i);return this},_bindRoutes:function(){if(!this.routes)return;this.routes=i.result(this,"routes");var t,e=i.keys(this.routes);while((t=e.pop())!=null){this.route(t,this.routes[t])}},_routeToRegExp:function(t){t=t.replace(I,"\\$&").replace(S,"(?:$1)?").replace(H,function(t,e){return e?t:"([^/?]+)"}).replace(A,"([^?]*?)");return new RegExp("^"+t+"(?:\\?([\\s\\S]*))?$")},_extractParameters:function(t,e){var r=t.exec(e).slice(1);return i.map(r,function(t,e){if(e===r.length-1)return t||null;return t?decodeURIComponent(t):null})}});var N=e.History=function(){this.handlers=[];i.bindAll(this,"checkUrl");if(typeof window!=="undefined"){this.location=window.location;this.history=window.history}};var R=/^[#\/]|\s+$/g;var O=/^\/+|\/+$/g;var P=/msie [\w.]+/;var C=/\/$/;var j=/#.*$/;N.started=false;i.extend(N.prototype,u,{interval:50,atRoot:function(){return this.location.pathname.replace(/[^\/]$/,"$&/")===this.root},getHash:function(t){var e=(t||this).location.href.match(/#(.*)$/);return e?e[1]:""},getFragment:function(t,e){if(t==null){if(this._hasPushState||!this._wantsHashChange||e){t=decodeURI(this.location.pathname+this.location.search);var i=this.root.replace(C,"");if(!t.indexOf(i))t=t.slice(i.length)}else{t=this.getHash()}}return t.replace(R,"")},start:function(t){if(N.started)throw new Error("Backbone.history has already been started");N.started=true;this.options=i.extend({root:"/"},this.options,t);this.root=this.options.root;this._wantsHashChange=this.options.hashChange!==false;this._wantsPushState=!!this.options.pushState;this._hasPushState=!!(this.options.pushState&&this.history&&this.history.pushState);var r=this.getFragment();var s=document.documentMode;var n=P.exec(navigator.userAgent.toLowerCase())&&(!s||s<=7);this.root=("/"+this.root+"/").replace(O,"/");if(n&&this._wantsHashChange){var a=e.$('
+
+ +
+
+
+
+
+
+

%T@FqUZAuPjrVJ_ksVo2MZS&v2M>#IMjIYBG4J9W)CO8@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